Getting heading from velocity East and Velocity North?

Discussion in 'General GPS Discussion' started by Bruce E. Stemplewski, Apr 6, 2006.

  1. Another thought I had was to use velocity East and Velocity North to
    determine heading. I'm no math wiz so I don't even know if this is
    possible. Is it? If so where can I find the algorithm?
     
    Bruce E. Stemplewski, Apr 6, 2006
    #1
  2. Bruce E. Stemplewski

    Bob L Guest

    heading = atan2(Ve, Vn) in radians atan2 is a four quadrant arctangent

    http://www.cplusplus.com/ref/cmath/atan2.html
     
    Bob L, Apr 6, 2006
    #2
  3. Since most GPS units already compute the heading ( actually the track )
    internally from the velocities, why bother to do it externally ?


    --
    Regards,

    Adrian Jansen adrianjansen at internode dot on dot net
    Design Engineer J & K Micro Systems
    Microcomputer solutions for industrial control
    Note reply address is invalid, convert address above to machine form.
     
    Adrian Jansen, Apr 6, 2006
    #3
  4. The Garmin protocol does not give heading. Plus you would have to
    download the whole track log to do it.
     
    Bruce E. Stemplewski, Apr 7, 2006
    #4
  5. Thanks just got the same thing from an astrophysicist friend of mine.

    Here is the whole thing in C

    double heading = atan2(v_e, v_n); // This function returns the
    angle, in radians, between -pi and pi.
    heading *= 180.0 / M_PI; // Convert from radians to
    degrees. Now heading is in the range [-180, 180]
    if (heading < 0.0) heading += 360.0; // Get rid of negative headings.
     
    Bruce E. Stemplewski, Apr 7, 2006
    #5
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.