3
$\begingroup$

I am struck with a mathematical problem. I want to convert the iPhone device's attitude information which is available in one of the following forms:

  1. Quaternion
  2. Rotation Matrix
  3. Roll, Pitch and Yaw component

To, Altitude and Azimuth. Where:

  • Altitude should be between: 0 to 90 deg and / or 0 to -90 deg. which depicts the altitude of the object pointed by the device in the sky.

enter image description here

  • Azimuth between 0 to 360 deg. which depicts the direction. North being 0 deg, South being 180 deg. etc. enter image description here

I am no expert at mathematics, so guys help me in figuring out this problem. I have already posted this question in sister website without much help. Probably because it involves too much of mathematics.

Thanks & Regards,

Raj

  • 0
    I think what @Raj was asking here is how to figure out the sign of whatever comes out of the arctangent. In computer science, this is where the `atan2` function comes in handy. You usually give it the numerator and denominator as arguments, and it figures out the correct quadrant/octant for you.2014-09-04

0 Answers 0