Home Search

DriveWorks Pro 22
VectorRotateAroundAxis

Send Feedback

VectorRotateAroundAxis

This function rotates the start position, around the axis formed by the two axis positions, by the given angle in degrees and returns the result as a pipe-bar delimited list.

Syntax

VectorRotateAroundAxis([Start Position], [Axis Position 1], [Axis Position 2], [Angle])

Where:

Start Position is a pipe-bar delimited list representing the start position vector (X|Y|Z).

Axis Position 1 is a pipe-bar delimited list representing the first axis position vector (X|Y|Z).

Axis Position 2 is a pipe-bar delimited list representing the second axis position vector (X|Y|Z).

Angle is the angle in degrees the start position will be rotated around the axis by.

Examples

RuleResult
VectorRotateAroundAxis("1|2|3","3|2|1","4|3|2",45)Will return the vector 2.4|0.37|3.23 (values have been rounded for clarity).
Floating Point Precision

Due to floating point precision, some calculations may not be as precise as expected.

This can be avoided by following the advice in the topic Info: Floating Point Precision.


Please see How To: Understanding Vector Functions for more information on Vectors, all the Vector functions provided in DriveWorks and use case examples.