# Math - Vectors (scripting commands)

- [matrixMultiply](../../commands/matrixMultiply.md): Returns resulting matrix from the multiplication of two matrices. First matrix must be of the size n × k, while the second must be of the size k × m, i.e `columns` matrix1 == `rows` matrix2.
- [matrixTranspose](../../commands/matrixTranspose.md): Returns transposed version of the given matrix. The matrix is an Array of rows. Each row is an Array of corresponding column values for the row. The minimum number of rows is 1.
- [setVectorDir](../../commands/setVectorDir.md): Set object's direction vector. Up vector will remain unchanged.
- [setVectorDirAndUp](../../commands/setVectorDirAndUp.md): Sets orientation of an object. The command takes 2 vector arrays, one for vectorDir and one for vectorUp.
- [setVectorUp](../../commands/setVectorUp.md): Set object's up vector. Direction of the object remain unchanged. Default object's vectorUp is [0,0,1].
- [vectorAdd](../../commands/vectorAdd.md): Adds two arrays of numbers. Replaces BIS_fnc_vectorAdd.
- [vectorCos](../../commands/vectorCos.md): Cosine of angle between two 3D or 2D vectors.
- [vectorCrossProduct](../../commands/vectorCrossProduct.md): Cross product of two 3D vectors.
- [vectorDiff](../../commands/vectorDiff.md): Subtracts one 3D vector from another. (vector1 - vector2)
- [vectorDir](../../commands/vectorDir.md): Returns an object's direction vector in world space.
- [vectorDirVisual](../../commands/vectorDirVisual.md): Returns an object's direction vector in world space and render time scope.
- [vectorDistance](../../commands/vectorDistance.md): Returns Euclidean distance between two points.
- [vectorDistanceSqr](../../commands/vectorDistanceSqr.md): Squared distance between two 3D vectors.
- [vectorDotProduct](../../commands/vectorDotProduct.md): Dot product of two 3D vectors.
- [vectorFromTo](../../commands/vectorFromTo.md): Unit vector, equal to direction from vector1 to vector2. In other words this command produces normalised vector between given 2 points.
- [vectorLinearConversion](../../commands/vectorLinearConversion.md): Interpolates vector between the given *vectorFrom* and *vectorTo* value according to the given range value.
- [vectorMagnitude](../../commands/vectorMagnitude.md): Magnitude of a 3D vector.
- [vectorMagnitudeSqr](../../commands/vectorMagnitudeSqr.md): Squared magnitude of a 3D vector.
- [vectorModelToWorld](../../commands/vectorModelToWorld.md): Converts vector direction from model to world space.
- [vectorModelToWorldVisual](../../commands/vectorModelToWorldVisual.md): Converts vector from model to world space in render time scope.
- [vectorMultiply](../../commands/vectorMultiply.md): Multiplies an array of numbers by a scalar or another array of numbers.
- [vectorNormalized](../../commands/vectorNormalized.md): Returns normalised vector (unit vector, vectorMagnitude == 1) of given vector. If given vector is 0 result is a 0 vector as well.
- [vectorSide](../../commands/vectorSide.md): Returns an object's side vector in world space.
- [vectorSideVisual](../../commands/vectorSideVisual.md): Returns an object's side vector in world space and render time scope.
- [vectorUp](../../commands/vectorUp.md): Returns an object's up vector in world space.
- [vectorUpVisual](../../commands/vectorUpVisual.md): Returns an object's up vector in world space and render time scope.
- [vectorWorldToModel](../../commands/vectorWorldToModel.md): Converts vector direction from world to model space.
- [vectorWorldToModelVisual](../../commands/vectorWorldToModelVisual.md): Converts vector direction from world to model space in render time scope.
