Hi Felix,<br><br>You are right, I checked and its not in the git.<br>And, I had only partially implemented the solution in my code.<br><br>So, I wrote HALF a test example, maybe someone (you?) could help out by:<br>* adding some code to test that it actually works<br>

* generalising it so it can be added into kdtree.hpp, rather than stuck in an example<br><br>the generalisation would mean adjusting the code so it tests using kdtree&#39;s distance calculator, templating it, and adding some methods so users can just call find_nearest_k() or whatever rather than having to use find_nearest_if()<br>

<br>I&#39;ve put it in a branch (branched off master):<br><a href="http://git.debian.org/?p=libkdtree/libkdtree.git;a=shortlog;h=refs/heads/paulharris/find_nth">http://git.debian.org/?p=libkdtree/libkdtree.git;a=shortlog;h=refs/heads/paulharris/find_nth</a><br>

<br>look here, under examples, test_kdtree_nth.cpp (click blob or raw)<br><a href="http://git.debian.org/?p=libkdtree/libkdtree.git;a=tree;h=refs/heads/paulharris/find_nth;hb=refs/heads/paulharris/find_nth">http://git.debian.org/?p=libkdtree/libkdtree.git;a=tree;h=refs/heads/paulharris/find_nth;hb=refs/heads/paulharris/find_nth</a><br>

<br><br>I&#39;m sorry the code isn&#39;t finished, I suppose thats why I didn&#39;t commit my previous half-done attempt.<br>I added a lot of comments to explain the theory behind the predicate, I believe it should work fine.<br>

<br>Best Regards,<br>Paul<br><br><br><br><div class="gmail_quote">On 23 November 2010 17:11,  <span dir="ltr">&lt;<a href="mailto:mailinglist@kroegerissendorf.de">mailinglist@kroegerissendorf.de</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi,<br>
I searched for the file in the git repository (<a href="http://git.debian.org/?p=libkdtree/libkdtree.git;a=summary" target="_blank">http://git.debian.org/?p=libkdtree/libkdtree.git;a=summary</a>), but didn&#39;t find the file test_kdtree_nth.cpp. There were only 3 .cpp files. Could you send that file to me by mail, please?<br>


<br>
Felix Kroeger<div><div></div><div class="h5"><br>
<br>
<br>
Quoting Paul &lt;<a href="mailto:elegant_dice@yahoo.com" target="_blank">elegant_dice@yahoo.com</a>&gt;:<br>
<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi Mr Mailinglist, is this a real email address?<br>
<br>
Look in the examples folder, there is a test_kdtree_nth.cpp file, that<br>
should give you a head start.<br>
If you can&#39;t find the file, check the git repository.<br>
<br>
thanks<br>
Paul<br>
<br>
<br>
On 11 November 2010 17:24, &lt;<a href="mailto:mailinglist@kroegerissendorf.de" target="_blank">mailinglist@kroegerissendorf.de</a>&gt; wrote:<br>
<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi,<br>
is there a way to find more than the nearest neighbour of a node in kdtree?<br>
I would like to find N neighbours (e.g. 5), which are the nearest<br>
neighbours to a given point.<br>
Can anyone help me?<br>
<br>
_______________________________________________<br>
libkdtree-devel mailing list<br>
<a href="mailto:libkdtree-devel@lists.alioth.debian.org" target="_blank">libkdtree-devel@lists.alioth.debian.org</a><br>
<a href="http://lists.alioth.debian.org/mailman/listinfo/libkdtree-devel" target="_blank">http://lists.alioth.debian.org/mailman/listinfo/libkdtree-devel</a><br>
<br>
</blockquote>
<br>
</blockquote>
<br>
<br>
</div></div></blockquote></div><br>