473,241 Members | 1,627 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,241 software developers and data experts.

|FAQ| Zip code related questions

Q: How to find the distance between two zip codes/cities?
Q: How to find list of cities/zip codes that are with in the particular
radius from given city/zip code?

A: In spherical trigonometry, we have haversine formula, which provides
relationship between the radius of the sphere and any two points on the
sphere (longitude and latitude of the points). So, if we take the earth
as a sphere and have longitude and latitude of any two cities, we can
find the distance approximately.

Developed countries like U.S. have census data that contains the zip
code, longitude and latitude of a particular city (along with
population data); this in turn helped a lot to find the distance
between any two cities or any two zip codes using the database. Not to
mention, even many commercial zip code databases are available for that
purpose.

Once we have the Zip code database, it's merely a calculation over the
data.

Refer:
1. http://www.census.gov/cgi-bin/geo/gisfaq?Q5.1 (Down now, alternative
is http://www.movable-type.co.uk/scripts/GIS-FAQ-5.1.html )
2. http://en.wikipedia.org/wiki/Haversine_formula haversine formula
3. http://www.census.gov/geo/www/gazetteer/places2k.html 2000 U.S.
Gazetteer
4. http://www.phpclasses.org/phpziplocator
5. http://www.phparchitect.com/sample.p...show=316&mid=9

++++
@todo Grammar fix

Jul 28 '05 #1
1 1636
ZIP Code Database with Latitude and Longitude
http://www.zipcodeworld.com

Free PHP Sample Codes
http://www.zipcodeworld.com/developers.htm

Aug 6 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Jan Roland Eriksson | last post by:
Archive-name: www/stylesheets/newsgroup-faq Posting-Frequency: twice a week (mondays and thursdays) Last-modified: March 10, 2001 Version: 1.95 URL: http://css.nu/faq/ciwas-mFAQ.html Maintainer:...
6
by: Jan Roland Eriksson | last post by:
For those interested, read and rip it up as you wish :-) ===== Archive-name: www/stylesheets/newsgroup-faq Posting-Frequency: twice a week (mondays and thursdays) Last-modified: July 20, 2004...
2
by: Jan Roland Eriksson | last post by:
Archive-name: www/stylesheets/newsgroup-faq Posting-Frequency: once a week Last-modified: 2004-07-26 Version: 2.00 URL: <http://css.nu/faq/ciwas-mFAQ.html> Maintainer: Jan Roland Eriksson...
0
by: Jan Roland Eriksson | last post by:
Archive-name: www/stylesheets/newsgroup-faq Posting-Frequency: once a week Last-modified: 2004-07-26 Version: 2.00 URL: <http://css.nu/faq/ciwas-mFAQ.html> Maintainer: Jan Roland Eriksson...
0
by: Jan Roland Eriksson | last post by:
Archive-name: www/stylesheets/newsgroup-faq Posting-Frequency: once a week Last-modified: 2004-07-26 Version: 2.00 URL: <http://css.nu/faq/ciwas-mFAQ.html> Maintainer: Jan Roland Eriksson...
4
by: Richard Cornford | last post by:
For the last couple of months I have been trying to get the next round of updates to the FAQ underway and been being thwarted by a heavy workload (the project I am working on has to be finished an...
0
by: Juan T. Llibre | last post by:
Welcome to the ASP.NET FAQ. The online version of this FAQ is at http://asp.net.do/faq/ Thank you for reading this FAQ! Use it to improve your online experience. The Microsoft Public...
6
by: Juan T. Llibre | last post by:
Welcome to the ASP.NET FAQ. The online version of this FAQ is at http://asp.net.do/faq/ Bookmark it! Thank you for reading this FAQ! Use it to improve your online experience. The Microsoft...
0
by: abbasky | last post by:
### Vandf component communication method one: data sharing ​ Vandf components can achieve data exchange through data sharing, state sharing, events, and other methods. Vandf's data exchange method...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 7 Feb 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:30 (7.30PM). In this month's session, the creator of the excellent VBE...
0
by: fareedcanada | last post by:
Hello I am trying to split number on their count. suppose i have 121314151617 (12cnt) then number should be split like 12,13,14,15,16,17 and if 11314151617 (11cnt) then should be split like...
0
by: stefan129 | last post by:
Hey forum members, I'm exploring options for SSL certificates for multiple domains. Has anyone had experience with multi-domain SSL certificates? Any recommendations on reliable providers or specific...
0
Git
by: egorbl4 | last post by:
Скачал я git, хотел начать настройку, а там вылезло вот это Что это? Что мне с этим делать? ...
1
by: davi5007 | last post by:
Hi, Basically, I am trying to automate a field named TraceabilityNo into a web page from an access form. I've got the serial held in the variable strSearchString. How can I get this into the...
0
by: MeoLessi9 | last post by:
I have VirtualBox installed on Windows 11 and now I would like to install Kali on a virtual machine. However, on the official website, I see two options: "Installer images" and "Virtual machines"....
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.