# How to convert a quaternion in polar form, back to rectangular form?

After a lot of digging in google, I found this(eqn. 36, pg. 2849) paper, which gives a 'real' polar form of a quaternion. It states that, any quaternion q can be represented as $$q=\vert{q}\vert{e^{i\phi'}e^{k\psi}e^{j\theta}}$$ where phase $$(\phi,\theta,\psi)$$ is almost uniquely defined in the interval $$[-\pi,\pi)\times[-\pi/2,\pi/2)\times[-\pi/4,\pi/4]$$.

The formulas which they gave for getting those three phase angles were quite complex, and I'm wondering is there actually a way to convert a quaternion in polar form, back to rectangular form. If so, how?

Also, how to convert octonions to polar form?

• So this comes down really to what $x_1, x_2, x_3$ you select for the Euler angles they define at the bottom of the page earlier Jan 20, 2022 at 20:14
• How do you visualize octonions in polar form anyway? There are many ways to parse the dimensions on a $7$-sphere. Jan 20, 2022 at 20:25

## 1 Answer

I think that is better to avoid Euler angles. If you know how the polar form of a quaternion is found starting from the rectangular form (see here), then you can reverse the process. If we start with $$q=\rho e^{\alpha \mathbf i+\beta \mathbf j +\gamma \mathbf k}=|q|e^{\mathbf v}$$ we can found $$\sin \theta= \frac{|\mathbf v|}{|z|}$$ and $$\mathbf n=\frac{\mathbf v}{|\mathbf v|}$$

so that: $$q= \rho e^{\mathbf v}=\rho e^{\theta \mathbf n}=\rho(\cos \theta +\mathbf n \sin \theta)$$,

That is the rectangular form.

• Is this transformation surjective and injective? Jan 21, 2022 at 3:57