Sign up ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

If I have two LatLongs, what is the best way to determine if the first one is within a 10 mile radius of the second?

share|improve this question
Duplicate of:… –  Rowland Shaw Jul 30 '10 at 12:07
Voting to close as an exact duplicate. –  whuber Mar 10 '11 at 2:11

1 Answer 1

up vote 4 down vote accepted

The following thread provides algorithms for calculating distance between lat/long coordinate pairs.

After that, just do a conditional, like: if (distance <= 10):

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.