# Formula for 3D Rotation

Formula for 3D Rotation

This Demonstration explains a formula for the rotation of the vector around the axis given by the unit vector through the angle .

r

ω

α

The formula is , using the dot and cross product of vectors.

(r.ω)ω+(r-(r.ω)ω)cos(α)+(ω×r)sin(α)

The resultant vector is .

OD=OB+BC+CD

The vector is the orthogonal projection of the vector onto the vector .

OB=(r.ω)ω

r=OA

ω

The vector is the result of the rotation of the vector around through the angle .

BD

BA=r-(r.ω)ω

ω

α

The vector is the orthogonal projection of onto .

BC=(r-(r.ω)ω)cos(α)

BD

BA

CD

BD

ω×r=ω×(r-(r.ω)ω)

|CD|=|BD|sin(α)=|BA|sin(α)=|r-(r.ω)ω|sin(α)=|ω×(r-(r.ω)ω)|sin(α)=|ω×r|sin(α)