Re: Locating Nearest Neighbors in space (fast)
- From: Christer Ericson <christer_ericson@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Sat, 10 Sep 2005 05:38:02 GMT
In article <dfps46$585$1@xxxxxxxxxxxxxxxxxxxxx>, karlk@xxxxxxxxxxx
says...
> Does anyone know a fast algorithm to do this, preferably one that doesn't
> require fancy knowledge of data structures etc since I'm not a professional
> programmer. Thanks.
The canonical data structure for nearest neighbor queries (in low
dimensions, at least) is the k-d tree. Given a k-d tree of your
query points, you can implement an efficient nearest neighbor
query in about 10 lines of code. K-d trees are a sufficiently fast
and simple solution that I would not waste my time on other solutions.
--
Christer Ericson
http://realtimecollisiondetection.net/
.
- References:
- Prev by Date: Re: year 11 maths survey
- Next by Date: Re: Locating Nearest Neighbors in space (fast)
- Previous by thread: Re: Locating Nearest Neighbors in space (fast)
- Next by thread: Re: Locating Nearest Neighbors in space (fast)
- Index(es):