Results 1 to 2 of 2

Thread: Convert Cartesian Distance to Sperical

  1. #1
    Member
    Joined
    Nov 2006
    Posts
    136

    Convert Cartesian Distance to Sperical

    I apologize if this is posted in the in the wrong place (i figure either here or calculus)

    Assume unit radius

    this is what i know - I have a latitude and longitude and I can convert these to Cartesian coordinates like this

    first convert lat and lon to radians by multiplying by pi/180, then

    $\displaystyle x = cos(lat) * cos(lon)$

    $\displaystyle y = cos(lat) * sin(lon)$

    $\displaystyle z = sin(lat)$

    To convert back to lat lon i do this

    $\displaystyle r=\sqrt(x^2 + y^2 + z^2)$

    $\displaystyle lat = asin(z/r)*(180/pi)$
    $\displaystyle lon = atan2(y, x)*(180/pi)$

    What I am trying to figure out is

    If i give you a distance between two points defined in cartesian space on a unit radius sphere how do i convert that distance to lat lon in degrees

    Hope this makes some sense

    Chogo
    Follow Math Help Forum on Facebook and Google+

  2. #2
    Member
    Joined
    Nov 2006
    Posts
    136

    Re: Convert Cartesian Distance to Sperical

    I have figured this out so please disregard the thread

    to convert from chordal distance to greater circle

    2*arcsin(distance/2)*Radius
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. Replies: 0
    Last Post: Jun 13th 2012, 01:23 PM
  2. Replies: 2
    Last Post: Mar 16th 2012, 04:52 AM
  3. Replies: 1
    Last Post: Mar 15th 2012, 11:58 AM
  4. Replies: 6
    Last Post: Apr 30th 2010, 01:19 PM
  5. Replies: 3
    Last Post: Sep 1st 2008, 03:21 AM

Search Tags


/mathhelpforum @mathhelpforum