tensor[Jacobian]  compute the Jacobian and its inverse of a coordinate transformation
tensor[transform]  transform a tensor given the backward transformation, the Jacobian of the backward transformation and its inverse.

Calling Sequence


Jacobian(Y, Finv, yJx, xJy)
transform(Tx, Finv, yJx, xJy)


Parameters


Y



list of n names of coordinate variables

Finv



list of n functions in the y's that gives the transformation from the ycoordinate system to another one, say, the xcoordinate system

yJx



output parameter of Jacobian(), but an input to transform(); tensor_type of character , and having the Jacobian matrix of the transformation from the x's to y's as components, yJx must have its components expressed in terms of the y's

xJy



output parameter of Jacobian(), but an input to transform(); tensor_type of character , and having the transpose of the Jacobian matrix of the transformation from the y's to x's (namely, Finv) as components, xJy must have its components expressed in terms of the y's

Tx



any tensor_type of rank1 or higher





Description


Important: The tensor package has been deprecated. Use the superseding commands DifferentialGeometry[Transformation] and Physics[TransformCoordinates] instead.
•

Given a tensor_type Tx, that represents a tensor T in its xcoordinate representation, transform() constructs Ty, the representation of the same tensor in another coordinate system, say, the ycoordinate system.

•

transform() needs as input parameters, apart from T of course, the inverse transformation Finv, (that is, the x's expressed as functions of the y's), the jacobian (tensor_type) of Finv expressed in terms of the y's and its inverse (tensor_type).

•

yJx must have character , and more visually, components:

•

xJy MUST have character , and components:


Note: Note the transposition here in xJy! This is due to the fact xJy (and also yJx) is primarily used by tensor[transform], and tensor[transform] uses tensor[change_basis] to perform component manipulations, and tensor[change_basis] requires that the transformation matrix that acts on covariant indices (where xJy indeed does, since in tensor[transform], the transformation is from the x's to the y's) have this transposed arrangement.

•

The function Jacobian() can thus be used to generate the two Jacobians needed by transform(). Note that the xJy produced by Jacobian() is already in that transposed arrangement required by transform(). You need to be concerned about that fact only when they are to construct the jacobian(s) themselves.

–

Jacobian: Each of its components is merely a partial derivative of one of the x's w.r.t. one of the y's and Jacobian() uses the simplifier `tensor/partial_diff/simp` to simplify each of these derivatives.

–

transform: When Tx is of rank zero, only substitutions (of the x's with the y's) are needed. In this case, transform() uses the simplifier `tensor/raise/simp` to simplify the (scalar) component of the result after the substitutions.


When Tx is of rank one or higher, transform() first makes the substitutions and then invokes tensor[change_basis] to carry out the transformation according to the tensorial rule, and hence it, in case of a nonzero rank tensor, transform() uses also `tensor/raise/simp` as simplifier; `tensor/raise/simp` is the simplifier used by change_basis().

•

These two functions are part of the tensor package, and can be used in the form Jacobian(..), and transform(..) only after performing the command with(tensor), or with(tensor, Jacobian) or with(tensor, transform). The functions can always be accessed in the long form tensor[Jacobian] or tensor[transform].



Examples


Important: The tensor package has been deprecated. Use the superseding commands DifferentialGeometry[Transformation] and Physics[TransformCoordinates] instead.
>


Declare the coordinate variables in the two systems. Note that declaration of Polar is not necessary in the following computations.
Express the coordinates in the first system in terms of the those in the second.
>


Define the RobertsonWalker covariant metric in the first system.
>


 (1) 
Form the two jacobians.
>


>


 (2) 
>


 (3) 
Now compute the transformed covariant metric in the second system.
>


 (4) 
>


 (5) 

