Neigborhood
2 views (last 30 days)
Show older comments
Hello, I have set of n 3d Points P=[p1,...,pn]
where,
pi=[pix,piy,piz] represent the 3D coordinates of a point , i want to estimate a normal vector ni=[nix,niy,niz] from a set of points in neighborhood Qi=[qi1,qi2,...,qik]
I want to know how can find Q matrix for any point giving some value of k ,like f k=5
4 Comments
Answers (1)
Jan
on 17 Aug 2011
4 Comments
Jan
on 18 Aug 2011
@developer: It would be helpful, if you mention where this function is coming from. Although I do not have the chance to look in its documentation (did you do this already?), I guess that this function uses the same input as all other KNN function from the FEX: "a" is the set of points you are searching in, "b" is the set of points you want to find the nearest neighbors of. E.g. imagine any normally distributed random points and you want to find the 10 points nearest to the origin: kNearestNeighbors(randn(1000, 3), [0,0,0], 10) - or perhaps with transposed inputs.
I assume, that for your case "b" equals "a". There might be a method to tell the function that both sets are equal.
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!