[aprssig] Proximity detection
Andrew Rich
vk4tec at people.net.au
Wed Aug 22 11:54:09 EDT 2007
Bit hard to do in a PIC chip Wes
----------------------------------------------------------------------------
Andrew Rich VK4TEC
vk4tec at people.net.au
http://www.tech-software.net
-----Original Message-----
From: johnstonwes at gmail.com [mailto:johnstonwes at gmail.com]On Behalf Of Wes
Johnston, AI4PX
Sent: Thursday, 23 August 2007 1:31 AM
To: vk4tec at people.net.au; TAPR APRS Mailing List
Subject: Re: [aprssig] Proximity detection
Or you could use cosine corrected Pythagorean theorem....
dist=sqrt( (COS(average latitude) x [delta longitude] ^2 ) + [delta
latitude]^2).
of course the answer you get is in degrees and you have to convert that to
miles or km. 1 degree = 60 miles, 1 degree = 111km
I've checked it with a spread sheet years ago, and it works to within .1
of a mile out to 100 miles at 33° latitude. It does NOT work for great
circle distances... it will choke on antipodal points for example. But it's
good for your general vicinity.
Wes
On 8/22/07, Andrew Rich <vk4tec at people.net.au> wrote:
Gudday
If you get a micro, and you know from a GPS where you are, and then you
pick up another position, one would assume you can then apply a basic "is
there anyone in my box" calculation ?
For example
I am at
2734.44 15206.20 and another object is at
2734.45 15206.20 - does not match - outside the box
2734.44 15206.20 and another object is at
2734.44 15206.20 - match - inside the box
I spose the size of the area depends on how many significant digits of
the position you use ?
You could make it tighter by comparing more digits, and wider if you
compare less ?
Comments ?
------------------------------------------------------------------------
----
Andrew Rich VK4TEC
vk4tec at people.net.au
http://www.tech-software.net
_______________________________________________
aprssig mailing list
aprssig at lists.tapr.org
https://lists.tapr.org/cgi-bin/mailman/listinfo/aprssig
--
In theory there is no difference between practice and theory.
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.5.484 / Virus Database: 269.12.1/965 - Release Date: 21/08/2007
4:02 PM
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.tapr.org/pipermail/aprssig_lists.tapr.org/attachments/20070823/32a419f2/attachment.html>
More information about the aprssig
mailing list