3.6. Directional indices

From the abstract point of view, covariant (contravariant) indices of tensors represent slots where vectors (covectors) can be "contracted". It is interesting sometimes to write that contraction explicitly: xTensor` uses the head Dir to denote that kind of "directional index". The introduction of a special head is a technical decision: we expect this feature to be seldom used and therefore it makes no sense to force xTensor` to check continuously whether a given slot contains an abstract index or a vector. All definitions concerning directional-indices are associated to Dir, and hence they are not even considered unless the head Dir is found.

Dir                        Head denoting directional slots in tensors

Directional indices.

This is the usual representation for a contraction:

In[167]:=

v[-b] S[a, b]

Out[167]=

S_  ^ab v_b^

But it can also be given as (note the different results of the validation routine below)

In[168]:=

S[a, Dir[v[-c]] ]

Out[168]=

S_  ^av

In[169]:=

Validate[%]

Out[169]=

S_  ^av

Directional slots containing vectors are represented downstairs, and slots containing covectors are represented upstairs:

In[170]:=

S[a, Dir[v[c]] ]

Out[170]=

S_ ( v)^a

In[171]:=

Validate[%]

Validate :: error : Invalid character of index in tensor v

Validate :: error : Invalid character of index in tensor S

Out[171]=

ERROR[S_ ( v)^a ]

In[172]:=

U[a, b, Dir[v[-c]] ]

Out[172]=

U_   ^abv

In[173]:=

Validate[%]

Validate :: error : Invalid character of index in tensor U

Out[173]=

ERROR[U_   ^abv]

It has the expected properties for a tensorial slot:

In[174]:=

DefTensor[w[a], M3]

** DefTensor: Defining tensor w[a] .

In[175]:=

S[a, Dir[3v[-c] + w[-c]] ]

Out[175]=

3 S_  ^av + S_  ^aw

In[176]:=

UndefTensor[w]

** UndefTensor: Undefined tensor w

In particular, xTensor` understands the whole expression as a vector, and not as a 2-tensor:

In[177]:=

UpVectorQ[S[a, Dir[v[-c]]]]

Out[177]=

True

It is important to realize that the free index c in Dir[v[c]] is completely irrelevant except for its sign and the tangent bundle it belongs to. It is there for consistency reasons: it identifies the argument of Dir as an upvector on TangentM3. I call those indices "ultraindices".

If you find annoying to write Dir[v[c]] many times, you can name this expression:

In[178]:=

dirv = Dir[v[c]] ;

S[a, dirv]

Out[179]=

S_ ( v)^a

Finally, there is a function to convert the Dir indices into normal contractions:

In[180]:=

SeparateDir[%]//ScreenDollarIndices

Out[180]=

S_ ( b)^a  v_ ^b


Created by Mathematica  (May 16, 2008) Valid XHTML 1.1!