Skip to content
Rotation Converter3D ORIENTATION / TECHNICAL REFERENCE

Conventions and frame mappings

Orientation data requires a frame direction, vector convention, component order, and angle convention. These definitions specify the converter’s choices.

Passive and active rotations

A passive transformation changes a fixed vector’s coordinates from frame AA to frame BB: vB=CB←AvAv_B=C_{B\leftarrow A}v_A. Its inverse is CA←B=CB←ATC_{A\leftarrow B}=C_{B\leftarrow A}^{\mathsf T}.

An active rotation moves a vector within a fixed frame. For the same axis and angle, R=CTR=C^{\mathsf T}. A positive active quarter-turn about ZZ maps [1,0,0]T[1,0,0]^{\mathsf T} to [0,1,0]T[0,1,0]^{\mathsf T}. The paired passive matrix maps it to [0,−1,0]T[0,-1,0]^{\mathsf T}.

Identify world, body, sensor, and camera frames from the data source. Transposing a valid orthogonal mapping reverses its direction; frame assignments remain the user’s responsibility.

Passive:vB=CB←AvAActive:vrotated=RvR=CT\begin{aligned}\text{Passive:}\quad v_B&=C_{B\leftarrow A}v_A \\ \text{Active:}\quad v_{\mathrm{rotated}}&=Rv \\ R&=C^{\mathsf T}\end{aligned}
Column-vector conventions used throughout the reference.

Elementary passive matrices

For angle aa in radians, let c=cos⁡(a)c=\cos(a) and s=sin⁡(a)s=\sin(a). These matrices define positive passive rotations about XX, YY, and ZZ. Their transposes define the paired active rotations. Their signs determine the Euler, quaternion, and axis-angle formulas.

CX(a)=[1000cs0−sc]CY(a)=[c0−s010s0c]CZ(a)=[cs0−sc0001]\begin{aligned}C_X(a)&=\begin{bmatrix}1&0&0\\0&c&s\\0&-s&c\end{bmatrix} \\ C_Y(a)&=\begin{bmatrix}c&0&-s\\0&1&0\\s&0&c\end{bmatrix} \\ C_Z(a)&=\begin{bmatrix}c&s&0\\-s&c&0\\0&0&1\end{bmatrix}\end{aligned}
Elementary rotations; c=cos⁡(a)c = \cos (a) and s=sin⁡(a)s = \sin (a).

Euler products and sequential composition

Sequence ijkijk gives C=Ck(γ)Cj(β)Ci(α)C=C_k(\gamma)C_j(\beta)C_i(\alpha). Thus ZYX\mathrm{ZYX} angles Z=10∘Z=10^\circ, Y=20∘Y=20^\circ, X=30∘X=30^\circ give CX(30∘)CY(20∘)CZ(10∘)C_X(30^\circ)C_Y(20^\circ)C_Z(10^\circ). The rightmost factor acts first on a column vector. This product specifies the convention.

Sequence mode starts with identity and multiplies each new step on the left. Step 1 is the rightmost factor. Changing step order generally changes the result because matrix multiplication is noncommutative.

Adjacent frame labels must agree: CD←BCB←AC_{D\leftarrow B}C_{B\leftarrow A} maps AA coordinates to DD. Invert transposes a step; this gives its inverse when the step is orthogonal. Scale and shear remain in the transposed matrix.

Each step retains its input method’s convention. Individual Entry follows Passive/Active. Paste Text constructs passive non-matrix steps. Check these paths when mixing methods in Active mode.

v1=C1v0v2=C2v1=C2C1v0vn=Cn⋯C2C1v0Cfinal=Cn⋯C2C1\begin{aligned}v_1&=C_1v_0 \\ v_2&=C_2v_1=C_2C_1v_0 \\ v_n&=C_n\cdots C_2C_1v_0 \\ C_{\mathrm{final}}&=C_n\cdots C_2C_1\end{aligned}
Accumulation order in Passive sequence mode. The same left-multiplication rule applies to raw step matrices in Active mode.

Input and output behavior in Active mode

Let CC be the passive matrix constructed from quaternion, Euler, or axis-angle parameters, MM the stored matrix, and DD the displayed matrix. Passive output uses D=MD=M; Active output uses D=MTD=M^{\mathsf T}. Quaternion and axis-angle outputs are extracted from DD.

Interactive parameters give M=CM=C in Passive mode and M=CTM=C^{\mathsf T} in Active mode. Bulk Import and sequence Paste Text give M=CM=C. Matrix input stores the entered matrix unchanged in both modes.

Passive Euler output extracts sequence ijkijk and displays [α,β,γ][\alpha,\beta,\gamma]. Active output extracts the reversed sequence kjikji, then reverses the values for display. Active values [a,b,c][a,b,c] in selector order i,j,ki,j,k therefore satisfy D=Ci(a)Cj(b)Ck(c)D=C_i(a)C_j(b)C_k(c).

Interactive Active ZYX\mathrm{ZYX} input [10,20,30][10,20,30] degrees with selector 321321 displays [−1.116055,22.242181,28.451775][-1.116055,22.242181,28.451775]. Pasting the same numbers in Active mode displays [−10,−20,−30][-10,-20,-30]. Each result follows its input transpose and extraction path.

Eigen and Python Euler exports include an Order comment with the extraction sequence. In Active mode it reverses the selector; displayed values follow selector order and the product above. Changing Passive/Active updates output interpretation of stored MM. Reconvert to apply the choice to the input path.

One non-matrix orientation CC, or an entered matrix AA, through the current interface.
Input methodModeStored MMDisplayed DD
Interactive parametersPassiveCCCC
Interactive parametersActiveCTC^{\mathsf T}CC
Bulk parametersPassiveCCCC
Bulk parametersActiveCCCTC^{\mathsf T}
Entered matrix AAPassiveAAAA
Entered matrix AAActiveAAATA^{\mathsf T}

Interpreting the visualization

Dashed axes show the fixed reference frame. Solid red, green, and blue axes show rotated XX, YY, and ZZ. The renderer draws rows of its animation matrix in Passive mode and columns in Active mode. Animation uses its own matrix, separate from output DD.

Manual animation follows the Euler decomposition in the output sequence. Sequence-mode results use this same decomposition. Near the singular-branch tolerance, reconstructing the animation matrix from extracted angles can shift its endpoint slightly.

Dragging and NED/NWU presets change the camera view. Establish imported data’s frame conventions from its source.