Cross 2D/3D• Cross[vector1, vector2] returns the cross product of the direction vectors of the two Mech vector objects. • In Modeler2D, Cross returns a scalar. • In Modeler3D, Cross returns a vector. • Mech's overloading of the built-in Cross symbol has no effect on its usage in other Mathematica code. • See also: Cross, Direction, Dot, Magnitude, SkewSym, Unit. Further Examples Load the Modeler2D package. The cross product of two 2D vectors is defined as a scalar by Mech. This is really the Z component of the cross product {a, b, 0}{c, d, 0}.
Out[2]= | |
Out[3]= | |
Cross can handle Mech vector objects directly, and take advantage of possible simplifications. Consider the cross product of two vectors in the same local reference frame.
Out[4]= | |
Out[5]= | |
Out[6]= | |
Dot can also handle Mech vector objects directly for the same advantage.
Out[7]= | |
Out[8]= | |
Out[9]= | |
|