Difference between revisions of "Tensor index notation"

From Conservapedia
Jump to: navigation, search
m (DavidB4 moved page Suffix notation to Tensor index notation: moving as agreed upon by FredericBernard and SamHB)
(Einstein Summation Convention: clean up, typos fixed: so called → so-called)
 
(12 intermediate revisions by one other user not shown)
Line 1: Line 1:
'''Suffix notation''', also known as index notation or multi-index notation, is a method of notation which is of use when dealing with [[tensor]]s.<ref>[http://www.brown.edu/Departments/Engineering/Courses/En221/Notes/Index_notation/Index_notation.htm Tensor index notation] from brown.edu</ref> Particular examples of tensors include [[vector]]s and [[matrix|matrices]], and suffix notation can greatly simplify algebraic manipulations involving these types of mathematical object.
+
'''Tensor index notation''' is a method of notation which is of use when dealing with [[tensor]]s.<ref>[http://www.brown.edu/Departments/Engineering/Courses/En221/Notes/Index_notation/Index_notation.htm Tensor index notation] from brown.edu</ref> Particular examples of tensors include [[vector]]s and [[matrix|matrices]], and index notation can greatly simplify algebraic manipulations involving these types of mathematical object.
  
The components of a vector (with respect to some co-ordinate system) might be written <math>\boldsymbol{x}=(x_1,x_2,x_3)</math>. More concisely, we could write <math>x_i</math> for the components of the vector, where <math>i=1,2,3</math>. To motivate this notation, we will consider the equation <math>Ax=b</math> for some matrix <math>A</math> and vectors <math>x,b</math>. We will use the convention that if <math>A</math> is a matrix, then <math>(A)_{ij}=a_{ij}</math> is the element of that matrix in the ith row and jth column. One way of thinking of vector equations is as a shorthand for a set of simultaneous equations - each component of the vectors gives an equation. Explicitly, consider the set of three equations for the three unknowns <math>x_1, x_2, x_3</math>:
+
The components of a vector (with respect to some co-ordinate system) might be written <math>\vec{\boldsymbol{x}}=(x_1,x_2,x_3)</math>.
 +
::{| cellspacing="0" cellpadding="0" style="margin:2em 2em 1em 0em; width:80%"
 +
| style="vertical-align:top; border:1px solid Indigo; background-color:Lavender;" |
 +
<div style="border-bottom:1px solid Indigo; background-color:#c0c0fa; padding:0.0em 0.5em 0.0em 0.5em; font-size:110%; font-weight:bold;">'''REALLY CORRECT TENSOR INDEX NOTATION'''</div>
 +
<div style="padding:0.4em 1em 0.3em 1em;">
 +
While elementary treatments of linear algebra and matrix algebra are normally done with subscripts everywhere, proper tensor index notation involves subscripts and superscripts placed very carefully.  While the exact reasons for this are beyond the scope of these articles, the articles will show what correct placement looks like.  Proper index notation is actually simpler once one gets used to it and understands it.  For now, the fundamental principle, is that:
 +
:'''Indices of vectors are written as superscripts.'''
 +
Get used to seeing things written that way.
 +
 
 +
Vectors are "contravariant first-rank tensors".  Contravariant tensors have their indices written as superscripts, while covariant tensors have their indices written as subscripts.
 +
 
 +
So, the components of the above vector could be written <math>\vec{\boldsymbol{x}}=(x^1,x^2,x^3)</math>.
 +
 
 +
But doesn't writing the vector components as superscripts lead to ambiguity with raising something to a power?  Not really.  Proper tensor/vector equations '''almost never raise a vector component to a power.'''  When one must do so, the convention is to put the power in parentheses.  So <math>x^2</math> is the second component of a vector, <math>x^{(2)}</math> is the number x squared, and <math>x^{2^{(2)}}</math> or <math>(x^2)^2</math> is the second component squared.
 +
</div>
 +
|}
 +
More concisely, we could write <math>x_i</math> for the components of the vector, where <math>i=1,2,3</math>. To motivate this notation, we will consider the equation <math>\boldsymbol{A}\,\vec{\boldsymbol{x}}=\vec{\boldsymbol{b}}</math> for some matrix <math>\boldsymbol{A}</math> and vectors <math>\vec{\boldsymbol{x}}</math> and <math>\vec{\boldsymbol{b}}</math>. We will use the convention that if <math>\boldsymbol{A}</math> is a matrix, then <math>(\boldsymbol{A})_{ij}=a_{ij}</math> is the element of that matrix in the ith row and jth column. One way of thinking of vector equations is as a shorthand for a set of simultaneous equations - each component of the vectors gives an equation. Explicitly, consider the set of three equations for the three unknowns <math>x_1, x_2, x_3</math>:
  
 
:<math>
 
:<math>
Line 15: Line 31:
 
</math>
 
</math>
  
 
+
This can be rewritten in a matrix/vector form as equation <math>\boldsymbol{A}\,\vec{\boldsymbol{x}}=\vec{\boldsymbol{b}}</math>:
This can be rewritten in a matrix/vector form as equation <math>Ax=b</math>:
+
  
 
:<math>
 
:<math>
Line 37: Line 52:
 
</math>
 
</math>
  
Comparison of these two forms should convince you that the "go along the column and down the rows" rule for multiplying a matrix and a vector is sensible. We can also write the above system of equations more succinctly in suffix notation. We notice that in any of the three equations, the first index on the <math>a_{ij}</math> elements is fixed whilst the second varies from 1 to 3. Thus:
+
Comparison of these two forms should convince you that the "go along the column and down the rows" rule for multiplying a matrix and a vector is sensible. We can also write the above system of equations more succinctly in index notation. We notice that in any of the three equations, the first index on the <math>a_{ij}</math> elements is fixed whilst the second varies from 1 to 3. Thus:
  
 
:<math>
 
:<math>
Line 57: Line 72:
 
</math>
 
</math>
  
When you see such an equation, remember that it is a shorthand notation for writing three equations at once, for <math>i=1,2,3</math> (in 3D). The major advantage with suffix notation is that objects such as <math>a_{ij}</math> as [[scalar]]s and therefore [[Commutative property|commute]] (ab=ba). Tensors themselves however can represent objects such as [[matrices]] and do not in general commute.
+
When you see such an equation, remember that it is a shorthand notation for writing three equations at once, for <math>i=1,2,3</math> (in 3D). The major advantage with index notation is that objects such as <math>a_{ij}</math> as [[scalar]]s and therefore [[Commutative property|commute]] (ab=ba). Tensors themselves however can represent objects such as [[matrices]] and do not in general commute.
 +
::{| cellspacing="0" cellpadding="0" style="margin:2em 2em 1em 0em; width:80%"
 +
| style="vertical-align:top; border:1px solid Indigo; background-color:Lavender;" |
 +
<div style="border-bottom:1px solid Indigo; background-color:#c0c0fa; padding:0.0em 0.5em 0.0em 0.5em; font-size:110%; font-weight:bold;">'''REALLY CORRECT TENSOR INDEX NOTATION'''</div>
 +
<div style="padding:0.4em 1em 0.3em 1em;">
 +
We can rewrite the preceding paragraphs in strict tensor form, by using the convention that if <math>\boldsymbol{A}</math> is a matrix, then <math>\boldsymbol{A}^i_j</math> is the element of that matrix in the ith row and jth column.  So the equations, in terms of the correct vector components are:
 +
:<math>
 +
a^1_1 x^1+a^1_2 x^2+a^1_3 x^3 = b^1
 +
</math>
  
 +
:<math>
 +
a^2_1 x^1+a^2_2 x^2+a^2_3 x^3 = b^2
 +
</math>
 +
 +
:<math>
 +
a^3_1 x^1+a^3_2 x^2+a^3_3 x^3 = b^3
 +
</math>
 +
 +
Or, more succinctly:
 +
 +
:<math>
 +
\sum_{j=1}^3 a^1_j x^j = b^1
 +
</math>
 +
 +
:<math>
 +
\sum_{j=1}^3 a^2_j x^j = b^2
 +
</math>
 +
 +
:<math>
 +
\sum_{j=1}^3 a^3_j x^j = b^3
 +
</math>
 +
 +
Or just
 +
 +
:<math>
 +
\sum_{j=1}^3 a^i_j x^j = b^i
 +
</math>
 +
for all <math>i</math> from 1 to 3.
 +
</div>
 +
|}
 
==Einstein Summation Convention==
 
==Einstein Summation Convention==
Suffix notation greatly simplifies the manipulation of [[tensor]]s. A commonly used convention when dealing with tensors is the so called "Einstein summation convention." Any index (suffix) that is repeated exactly twice is assumed to be summed over and the sum symbols are not written.<ref>[http://mathworld.wolfram.com/EinsteinSummation.html Einstein Summation Convention at mathworld.wolfram.com]</ref> In the example above, the sum:
+
Index notation greatly simplifies the manipulation of [[tensor]]s. A commonly used convention when dealing with tensors is the so-called "Einstein summation convention." Any index that is repeated exactly twice is assumed to be summed over and the sum symbols are not written.<ref>[http://mathworld.wolfram.com/EinsteinSummation.html Einstein Summation Convention at mathworld.wolfram.com]</ref> In the example above, the sum:
  
 
:<math>
 
:<math>
Line 68: Line 121:
 
can be written simply as <math>a_{ij}x_j=b_i</math>. There are three rules when using this convention:
 
can be written simply as <math>a_{ij}x_j=b_i</math>. There are three rules when using this convention:
  
:Any repeated suffix is implicitly summed over, as above.
+
:Any repeated index is implicitly summed over, as above.
:Each suffix cannot appear more than twice in any term, so <math>a_{ij}=b_{ik}c_{kl}d_{lj}</math> is valid but <math>a_{ij}=b_{ik}c_{kk}d_{kj}</math> is not as it has more than two k's.
+
:Each index cannot appear more than twice in any term, so <math>a_{ij}=b_{ik}c_{kl}d_{lj}</math> is valid but <math>a_{ij}=b_{ik}c_{kk}d_{kj}</math> is not as it has more than two k's.
:Each term must contain the same non-repeated suffixes, so <math>a_{ij}x_j + b_{ij}x_j</math> is valid but <math>a_{ij}x_j + b_{lj}x_j</math> is not as the first term does not have the suffix l.
+
:Each term must contain the same non-repeated indices, so <math>a_{ij}x_j + b_{ij}x_j</math> is valid but <math>a_{ij}x_j + b_{lj}x_j</math> is not as the first term does not have the index l.
 +
::{| cellspacing="0" cellpadding="0" style="margin:2em 2em 1em 0em; width:80%"
 +
| style="vertical-align:top; border:1px solid Indigo; background-color:Lavender;" |
 +
<div style="border-bottom:1px solid Indigo; background-color:#c0c0fa; padding:0.0em 0.5em 0.0em 0.5em; font-size:110%; font-weight:bold;">'''REALLY CORRECT TENSOR INDEX NOTATION'''</div>
 +
<div style="padding:0.4em 1em 0.3em 1em;">
 +
The rules for really correct tensor notation, including Einstein Summation, are as follows:
 +
:Einstein summation must be over one subscript and one superscript.
 +
 
 +
:Indices that appear in terms to be added or subtracted, or on opposite sides of and equals sign, must match: subscript for subscript, and superscript for superscript.
 +
 
 +
:For any index left over after summation, there is an implicit "for all" in the equation.
 +
So the above equation becomes just
 +
:<math>
 +
b^i = a^i_j x^j
 +
</math>
 +
That is the really proper way to express that vector <math>\vec{\boldsymbol{b}}</math> is the result of applying the linear transformation <math>\boldsymbol{A}</math> to the vector <math>\vec{\boldsymbol{x}}</math>
 +
</div>
 +
|}
  
In general, the indices may superscript of subscript depending on whether the tensors are covariant or contravariant.
+
In general, the indices are subscript or superscript depending on whether the tensors are covariant or contravariant, respectively.
  
 
==References==
 
==References==

Latest revision as of 02:27, September 28, 2018

Tensor index notation is a method of notation which is of use when dealing with tensors.[1] Particular examples of tensors include vectors and matrices, and index notation can greatly simplify algebraic manipulations involving these types of mathematical object.

The components of a vector (with respect to some co-ordinate system) might be written .

REALLY CORRECT TENSOR INDEX NOTATION

While elementary treatments of linear algebra and matrix algebra are normally done with subscripts everywhere, proper tensor index notation involves subscripts and superscripts placed very carefully. While the exact reasons for this are beyond the scope of these articles, the articles will show what correct placement looks like. Proper index notation is actually simpler once one gets used to it and understands it. For now, the fundamental principle, is that:

Indices of vectors are written as superscripts.

Get used to seeing things written that way.

Vectors are "contravariant first-rank tensors". Contravariant tensors have their indices written as superscripts, while covariant tensors have their indices written as subscripts.

So, the components of the above vector could be written .

But doesn't writing the vector components as superscripts lead to ambiguity with raising something to a power? Not really. Proper tensor/vector equations almost never raise a vector component to a power. When one must do so, the convention is to put the power in parentheses. So is the second component of a vector, is the number x squared, and or is the second component squared.

More concisely, we could write for the components of the vector, where . To motivate this notation, we will consider the equation for some matrix and vectors and . We will use the convention that if is a matrix, then is the element of that matrix in the ith row and jth column. One way of thinking of vector equations is as a shorthand for a set of simultaneous equations - each component of the vectors gives an equation. Explicitly, consider the set of three equations for the three unknowns :

This can be rewritten in a matrix/vector form as equation :

Comparison of these two forms should convince you that the "go along the column and down the rows" rule for multiplying a matrix and a vector is sensible. We can also write the above system of equations more succinctly in index notation. We notice that in any of the three equations, the first index on the elements is fixed whilst the second varies from 1 to 3. Thus:

Even more succinctly, we can write this as the single expression

When you see such an equation, remember that it is a shorthand notation for writing three equations at once, for (in 3D). The major advantage with index notation is that objects such as as scalars and therefore commute (ab=ba). Tensors themselves however can represent objects such as matrices and do not in general commute.

REALLY CORRECT TENSOR INDEX NOTATION

We can rewrite the preceding paragraphs in strict tensor form, by using the convention that if is a matrix, then is the element of that matrix in the ith row and jth column. So the equations, in terms of the correct vector components are:

Or, more succinctly:

Or just

for all from 1 to 3.

Einstein Summation Convention

Index notation greatly simplifies the manipulation of tensors. A commonly used convention when dealing with tensors is the so-called "Einstein summation convention." Any index that is repeated exactly twice is assumed to be summed over and the sum symbols are not written.[2] In the example above, the sum:

can be written simply as . There are three rules when using this convention:

Any repeated index is implicitly summed over, as above.
Each index cannot appear more than twice in any term, so is valid but is not as it has more than two k's.
Each term must contain the same non-repeated indices, so is valid but is not as the first term does not have the index l.
REALLY CORRECT TENSOR INDEX NOTATION

The rules for really correct tensor notation, including Einstein Summation, are as follows:

Einstein summation must be over one subscript and one superscript.
Indices that appear in terms to be added or subtracted, or on opposite sides of and equals sign, must match: subscript for subscript, and superscript for superscript.
For any index left over after summation, there is an implicit "for all" in the equation.

So the above equation becomes just

That is the really proper way to express that vector is the result of applying the linear transformation to the vector

In general, the indices are subscript or superscript depending on whether the tensors are covariant or contravariant, respectively.

References

See also