Updating transformation function to ensure proper range of input angle
and to ensure proper equations based on the final input value of omega
(w) since the equations are slightly different depending on the value
of omega (w).
Removing an assert condition