Add a Vector Transform node (
) to define variables representing the components of an input vector transformed to another coordinate system in a 3D vector space. You add it by right-clicking the
Definitions node and choosing
Variable Utilities>Vector Transform. If
Group by Type has been selected for the
Definitions branch, then you can also add it by right-clicking the
Variable Utilities node and choosing
Vector Transform.
Use the Name field to select a namespace for the input and output vector components, as well as for components of the transformation matrix.
In the Domain Selection section, select the domains in which this transformation is valid.
In addition, the Settings window for a
Vector Transform node contains the following sections:
Choose a Coordinate System in which this vector is represented. For a manually entered vector, the default is the
Global spatial system. When using
Replace Expression, the default is inferred from the properties of the selected vector.
If the selected coordinate system is a relative system such that its reference frame cannot be deduced from its definition, select an appropriate
Reference frame. This selection is only shown when a relative input system is selected.
If the relation between the input and output coordinate system is not a pure rotation, the Treat components as drop down is shown. Select whether the input vector components are covariant or contravariant. When using
Replace Expression, the default is inferred from the properties of the selected vector.
Select the Coordinate system in which the transformed vector will be represented. If the selected system is a relative system, also select a
Reference frame.
The components of the transformed vector in the selected system become available as variables <name>.v<xi>, where
<name> is the name of the node set in the
Name field, and
<xi> is the coordinate with index
i in the output coordinate system. The components of the input vector also become available as variables
<name>.u<i>. For example, if the
Vector Transform node has the name
vectr1, the first component of an input vector being transformed to the spatial frame becomes
vectr1.u1, while the first component of the output vector becomes
vectr1.vx. Both vectors also become available as vector objects which can be evaluated using a matrix evaluation node under
Derived Values or selected as input for another Vector Transform.
The transformation matrix also becomes available as <name>.
T. This matrix is the composition of all transformation matrices used. For example, if the indices were changed between covariant and contravariant at the same time as the coordinate system was changed, it is the product of the metric and a coordinate transformation matrix.
Choose Transform as, which determines how the input vector transforms between the chosen coordinate systems. If the option
Generalized vector density is chosen, the choices of
Input volume reference and
Output volume reference for the change in volume between coordinate systems become available.
Since you can use this option to choose the reference systems for the determinant of the Jacobian, it can be used to transform vectors as either vector densities or vector capacities. It can even be used to take into account the volume change between other coordinate systems. The Vector option transforms vectors as normal tensors, not taking into account the volume change. There are two other possible options: choosing the
Flux Vector option automatically sets the volume references as for a vector density using the volume references implied by the selected input and output systems; analogously, choosing the
Directed Area Element option automatically sets the volume references as for a vector capacity using the selected input and output systems.
As a default, the output vector will have the same type of base as the input vector. You can force the representation of the output vector to be covariant or contravariant, independent of the form of the input vector. In order to do this, change Component Change from its default value
None. Depending on how the indices were set in the
Input section, the other options can be
Covariant->Contravariant and
Contravariant->Covariant. The index on the vector components will be raised or lowered accordingly.
When choosing anything other than None, the choice of which metric to use for the transformation becomes available. Here, choose the metric as either
Spatial or
Material.