# Conventions and Notations¶

## Kinematics¶

A quaternion is defined as \(\mathbf{q} = [w, x, y, z]^T\). \([x, y, z]^T\) is the (scaled) axis of rotation and \(w\) is cosine of half of the angle.

Unless otherwise stated explicitly, every quantities in RaiSim is expressed in the world frame and relative to the world frame.

The world frame has zero acceleration and zero velocity

For articulated systems, the base angular velocity is defined in the world frame (many other simulators use the base frame). For details, read Joints

We represent a position vector in a Cartesian coordinate as \(^Wr\), where \(^W\) is the frame in which the vector is expressed.
In this document, \(W\) represents the **world frame** which is an inertial frame (zero acceleration).
Unless otherwise stated explicitly, all vector quanties in RaiSim are expressed in the world frame.

A position vector can be expressed in any frame. To express the vector in a different frame, we use a linear transformation as shown below

In this document, symbol \(^B\) represents the **body frame**, which is assigned to every bodies in RaiSim.
\(^{WB}R\) is called **body rotation matrix**.
**Note that the body rotation matrix maps a vector expressed in the body frame to a vector expressed in the world frame**