Thanks Thanks:  4
Showing results 1 to 8 of 8

Thread: Distance Based Neighbour Audit

  1. #1
    Member Reputation: 68
    Join Date
    2011-10-05
    Location
    Google Earth
    Posts
    117


    Question Distance Based Neighbour Audit

    Dear Experts,

    Does anyone have an excel formula to calculate the distance between two cells based on decimal (Long,Lat) points?

    I found the below formula but it's not working on excel :

    =RadiusEarth*((2*ASIN(SQRT((SIN((RADIANS(C2)-RADIANS(E2))/2)^2)+COS(RADIANS(C2))*COS(RADIANS(E2))*(SIN((RADIANS(D2)-RADIANS(F2))/2)^2)))))

    Can you please help?

  2. # ADS
    Circuit advertisement
    Join Date
    Always
    Location
    Advertising world
    Posts
    Many
     

  3. #2
    Senior Member Reputation: 302
    Join Date
    2010-07-21
    Location
    on the Pacific Rim of Southeast Asia
    Posts
    412


    1 out of 1 members found this post helpful.

    Default Re: Distance Based Neighbour Audit

    Quote Originally Posted by white_Noise View Post
    Dear Experts, Does anyone have an excel formula to calculate the distance between two cells based on decimal (Long,Lat) points? I found the below formula but it's not working on excel : Hello,, try this one.. just =RadiusEarth*((2*ASIN(SQRT((SIN((RADIANS(C2)-RADIANS(E2))/2)^2)+COS(RADIANS(C2))*COS(RADIANS(E2))*(SIN((RADIANS(D2)-RADIANS(F2))/2)^2))))) Can you please help?
    Hello,, try this one.. just input the longtitude and laitude bro... DONT FORGET TO ADD REPUTATION.. cheers..!! http://www.mediafire.com/download.php?35rvjo58pqxf9e1
    Last edited by ninoy_122184; 2011-11-29 at 09:36 PM
    password is onepiece

    hit THANKS and REP is highly appreciated..cheers!!

  4. Thanks aygo, kevin_h811 thanked for this post
  5. #3
    Senior Member Reputation: 307
    Join Date
    2010-04-06
    Location
    Moon
    Posts
    384


    Default Re: Distance Based Neighbour Audit

    I have your solution but it's not Xcel: let's assume that you have the following columns in Xcel: Source, Long_Source, Lat_Source, Target, Long_Target, Lat_Target
    Open the Xcel in Mapinfo
    Do the following query: Select Source, Destination,Distance(Long_Source, Lat_Source, Long_Target, Lat_Target, "km") from YOUR_XCEL into Query1

    The Query tab has now all the distances - just copy them to Xcel.

    Hope it solves your problem man

  6. Thanks redendo, mohyedeen_alkousy thanked for this post
  7. #4
    Member Reputation: 96
    Join Date
    2010-08-03
    Posts
    260


    Default Re: Distance Based Neighbour Audit

    Quote Originally Posted by white_Noise View Post
    Dear Experts,

    Does anyone have an excel formula to calculate the distance between two cells based on decimal (Long,Lat) points?

    I found the below formula but it's not working on excel :

    =RadiusEarth*((2*ASIN(SQRT((SIN((RADIANS(C2)-RADIANS(E2))/2)^2)+COS(RADIANS(C2))*COS(RADIANS(E2))*(SIN((RADIANS(D2)-RADIANS(F2))/2)^2)))))

    Can you please help?
    you can use this formula:
    =ACOS(COS(RADIANS(90-Lat1)) *COS(RADIANS(90-Lat2)) +SIN(RADIANS(90-Lat1)) *SIN(RADIANS(90-Lat2)) *COS(RADIANS(Long1-Long2))) *6371

    and my final version that uses Excel cell references is:


    =ACOS(COS(RADIANS(90-A2)) *COS(RADIANS(90-A3)) +SIN(RADIANS(90-A2)) *SIN(RADIANS(90-A3)) *COS(RADIANS(B2-B3))) *6371

    PS. To calculate distances in miles, substitute R (6371) with 3958.756 (and for nautical miles, use 3440.065).

  8. #5
    Member Reputation: 68
    Join Date
    2011-10-05
    Location
    Google Earth
    Posts
    117


    Default Re: Distance Based Neighbour Audit

    Quote Originally Posted by ninoy_122184 View Post
    Hello,, try this one.. just input the longtitude and laitude bro... DONT FORGET TO ADD REPUTATION.. cheers..!! http://www.mediafire.com/download.php?35rvjo58pqxf9e1
    thanks buddy, works perfectly..

  9. #6
    Junior Member Reputation: 10
    Join Date
    2011-10-31
    Posts
    3


    Default Re: Distance Based Neighbour Audit

    password please !

  10. #7
    Senior Member Reputation: 302
    Join Date
    2010-07-21
    Location
    on the Pacific Rim of Southeast Asia
    Posts
    412


    Default Re: Distance Based Neighbour Audit

    Quote Originally Posted by abbas nameer View Post
    password please !
    password is onepiece

    DONT FORGET TO CLICK THE REPUTATION IF THE DOCUMENT IS USEFUL BUDDY..
    password is onepiece

    hit THANKS and REP is highly appreciated..cheers!!

  11. #8
    Member Reputation: 19
    Join Date
    2011-06-20
    Posts
    20


    Default Re: Distance Based Neighbour Audit

    hi if B and C are source cell lat long and D and E are neighbour cell lat long then use below formula

    =1.1519*1.609*60*SQRT((B5-D5)^2+((C5-E5)*COS((B5+D5)*PI()/360))^2)

    if it is use full add reputation

Bookmarks

Bookmarks

Posting Rules

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •