Converting from Euler angles to quaternion for covariance estimate

1.3k Views Asked by At

I am working on a graph optimization problem (g2o for SLAM) to optimize poses of a robot. The optimizer expects a 6x6 information matrix for the robot poses $[x, y, z, q_x, q_y, q_z, q_w]$. Here the first 3 terms are the translation and the last 4 are the rotation in the form of a quaternion.

I have an estimate of the information matrix from a Hessian, but the Hessian is computed over $[x, y, z, \theta_z, \theta_y, \theta_x]$, which uses a different rotation convention (Euler angles).

So, is it possible to convert the rotation components of the Hessian from Euler angles to quaternions?

1

There are 1 best solutions below

0
On

I found this, explaining what I want to do: https://stats.stackexchange.com/questions/119780/what-does-the-covariance-of-a-quaternion-mean

While the link talks about the reverse transformation, the approach is the same.