Results 1 to 6 of 6

Math Help - Calculating the distance between two points on the Earth

  1. #1
    Junior Member NowIsForever's Avatar
    Joined
    May 2010
    From
    Norman, OK
    Posts
    43
    Thanks
    1

    Calculating the distance between two points on the Earth

    I wish to write a program that computes the distance between two points on the Earth's surface. Later I would want to turn it into a Java applet, so that also is a consideration. The reference surface I would like to use would be the fairly simple oblate spheroid.

    Arc lengths can be calculated either analytically or numerically. I would much prefer an analytic solution since that would, I assume, be the better choice for a Java applet. It is intuitively evident to me that a minimal arc connecting two points on this ellipsoid would coincide with the intersection of the ellipsoid and the plane passing through the center and the two points. Is this correct? If not, is it close enough for "government work?"

    Any ideas would be appreciated.

    Charles
    Follow Math Help Forum on Facebook and Google+

  2. #2
    Junior Member
    Joined
    May 2010
    Posts
    27
    I don't have much math help to offer here.
    I recently worked with as3 and the google maps API, and they have a java API also (but I'm not in particular familiar with it) . You can retrieve Lat and Long from mouse clicks.

    So that would perhaps be a nice interface?

    Developer Guide: Java - Google Maps Data API - Google Code
    Follow Math Help Forum on Facebook and Google+

  3. #3
    Junior Member
    Joined
    May 2010
    Posts
    27
    How's it going?

    I found this.
    Calculate distance and bearing between two Latitude/Longitude points using Haversine formula in JavaScript

    ..and he mentions this formula for the distance on a sphere
    Haversine formula - Wikipedia, the free encyclopedia


    R = earth’s radius (mean radius = 6,371km)
    Δlat = lat2− lat1
    Δlong = long2− long1
    a = sin²(Δlat/2) + cos(lat1).cos(lat2).sin²(Δlong/2)
    c = 2.atan2(√a, √(1−a))
    d = R.c
    Follow Math Help Forum on Facebook and Google+

  4. #4
    Junior Member NowIsForever's Avatar
    Joined
    May 2010
    From
    Norman, OK
    Posts
    43
    Thanks
    1
    ellensius,

    I have also posted this problem on Drexel's Math Forum. Here's the link and my latest reply:

    Math Forum Discussions

    > If you are using an oblate spheroid to get a bit of extra accuracy, are you willing to lose accuracy by
    > approximating geodesics?


    Negative, and that now makes this a very interesting problem aside from its utility. I see two ways to go about this. (1) By studying numerical solutions to various end point problems, I could use relaxation techniques to see if I can find an approximate formula that gives accuracy to any desired degree, or (2) I could investigate how to solve the problem using the calculus of variations.
    Follow Math Help Forum on Facebook and Google+

  5. #5
    Junior Member
    Joined
    May 2010
    Posts
    27
    I'm sorry if I misunderstood anything. I do think it sound interesting. Thats why I reply.

    However:

    Since the radius of a oblate spheroid vary only in relation to the rotational axis.

    Isn't it possible to use an approximation between two calculations of the 'Haversine formula' or the 'spherical laws of cosines'? So each distance calculation use different radius depending how close or far away they are from pole and equator respectively? And a brute approximation would be to sum the two results and divide by 2.

    Actually, Isn't it possible to 'integral'(I'm not sure what this is called) between two functions? or calculate a weighted approximation between the two result using the area under a graph as percentage for the difference in length?
    Follow Math Help Forum on Facebook and Google+

  6. #6
    Junior Member NowIsForever's Avatar
    Joined
    May 2010
    From
    Norman, OK
    Posts
    43
    Thanks
    1
    My current thought is that I would like to simulate the stretching of a rubber band between any two given points, and then do that numerous times to see if I can find patterns in the results. If lucky I might be able to generate an infinite series that would converge to a close approximate to the real geodesic.
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. Replies: 7
    Last Post: June 7th 2012, 05:04 AM
  2. Calculating Distance between 2 circles
    Posted in the Geometry Forum
    Replies: 6
    Last Post: June 20th 2011, 05:47 PM
  3. calculating distance between members of a set
    Posted in the Discrete Math Forum
    Replies: 2
    Last Post: March 28th 2010, 08:11 AM
  4. Calculating distance road
    Posted in the Geometry Forum
    Replies: 3
    Last Post: April 21st 2009, 11:31 PM
  5. Formula for calculating the distance....
    Posted in the Geometry Forum
    Replies: 5
    Last Post: September 18th 2007, 08:38 PM

Search Tags


/mathhelpforum @mathhelpforum