fix bug in quaternion multiply; add some helper functions
fix 3D vector rotation
add helper function
fix indentation
add some quaternion functions