Page 1 of 2   1 2 > last >>
Bookmark this page: Add Hi  I want to calculate distance   to Yahoo MyWeb Add Hi  I want to calculate distance   to Google Bookmarks Add Hi  I want to calculate distance   to Windows Live Add Hi  I want to calculate distance   to Del.icio.us Digg Hi  I want to calculate distance  ! Add Hi  I want to calculate distance   to Netscape
  •  
  • Subject
  • Author
  • Date
If you were  Registered and logged in, you could reply and use other advanced thread options
Posted by Deepak on November 12, 2009, 7:41 am


Hi all,
I am new in this group.
I want to calculate distance between two latitude,longitude.

could any one the formula..

Please help me..
Thanks

Posted by Roger Mills on November 12, 2009, 8:18 am


In an earlier contribution to this discussion,

> Hi all,
> I am new in this group.
> I want to calculate distance between two latitude,longitude.
> could any one the formula..
> Please help me..
> Thanks

Approx how far apart are the points, and how accurate do you need the answer
to be?
--
Cheers,
Roger
______
Email address maintained for newsgroup use only, and not regularly
monitored.. Messages sent to it may not be read for several weeks.
PLEASE REPLY TO NEWSGROUP!



Posted by Sam Wormley on November 12, 2009, 11:49 am


Deepak wrote:

> I want to calculate distance between two latitude,longitude.

Aviation Formulary V1.44
http://williams.best.vwh.net/avform.html

Posted by HIPAR on November 12, 2009, 2:19 pm


> Hi all,
> I am new in this group.
> I want to calculate distance between two latitude,longitude.
> could any one the formula..
> Please help me..
> Thanks

Assuming you are looking for the shortest distance between
start and finish points anywhere on the globe, this is a spherical
earth formula from Aviation Formulary coded in Pascal:

{Distance calculations from (Lat1, Lon1) to (Lat2, Lon2)}

function GcDis(const Lat1, Lon1, Lat2, Lon2: Double): Double;
begin
Result :=3D 2*ArcSin(Sqrt(Sqr(Sin((Lat1-Lat2)/2)) +
Cos(Lat1)*Cos(Lat2)*Sqr(Sin((Lon1-Lon2)/2))));
end

You need to convert lat and lon to radians and then convert the
result from radians to your distance units. The spherical earth
model can be in error by several percent depending on the the
direction between the start and finish points.

This formula is very well behaved for small distance and handles
special cases properly.

There is a more complex formula available using the method of
Andoyer-Lambert that is more accurate for a ellipsoid shaped
earth. I have Pascal Code for it.

If the ultimate accuracy is required, you will need an iterative
algorithm such as the one developed by Thaddeus Vincenty.

Have fun.

--- CHAS

Posted by Don B on November 13, 2009, 5:55 am


There is a free piece of software from Mentor Software called
Forward/Inverse that will do what you want to do. I don't have their
site bookmarked, but you should be able to Google them.

Page 1 of 2   1 2 > last >>