From theta to the two numbers z and w

Drag the slider: the orange arrow is the way the robot faces (theta). The message stores the turn as z = sin(theta ÷ 2) and w = cos(theta ÷ 2).

theta = rad ( degrees)