Re: [Re: calculating distance based on zip/postal codes]

by Jan Theodore Galkowski <jtgalkowski(at)alum.mit.edu>

 Date:  Mon, 15 May 2000 20:14:36 -0400
 To:  Susan Duncan <sduncan(at)malico.com>
 Cc:  hwg-business <hwg-business(at)hwg.org>
 References:  localhost
  todo: View Thread, Original
At 06:53 PM 05/15/2000 -0400, Susan Duncan wrote:
>I've been following all the messages and links and my mind is swimming,
but hopefully I'll
>make sense of it all.  I'm not using this for shipping.  It is for a
personal's site so that
>they can determine how far people are away from each other.  No system is
perfect, even
>stating a city doesn't help as from one end to the other can easily be a
45 minute drive.

Well, for this application, you might be able to use the arccosine rule.
You just treat latitude and longitude as if they were rectangular cartesian
coordinates and calculate a distance:  If the result is smaller than some
threshold amount, you simply announce the people are "close".  Otherwise you
use the arccosine rules.  This idea will work for any place having latitudes
closer to the equator than the arctic or antarctic circles.

   --jtg

>
>--
>          Making the Web Work for You (tm)
>
>Susan Duncan (sduncan(at)malico.com) Voice: (613) 744-3283
>Director, Internet Development      Fax: (613) 744-1825
>http://www.malico.com         Toll Free: (877) WEB-PROS
>http://www.OttawaWEB.COM
>MALICO - Graphic Design and Internet Development
>Founders: Ottawa-Hull Chapter-Int'l Webmasters Association
>
>
>

HTML: hwg-business mailing list archives, maintained by Webmasters @ IWA