2
votes

Someone already showed how to find a fitting plane from a set of points in 3D here 3D Least Squares Plane

I just wonder if there is an algorithm to progressively find the best fitting plane point after point? Let's say I have a best fitting plane for n-1 points, is there an easy way to calculate the new fitting plane considering the n-th point?

Thanks

2
what do you mean by best fit? what criteria makes it best? with fitting you can use n-1 points plane fit as a start point for the search of n point plane to significantly lower the iterations needed for the same accuracy ... You can use any method like approximation search minimizing your criteria error. Some forms of fits allows direct computation instead of approximation (like averaging all the normals ...) etc but all depends on what the "best fit" means. for you.Spektre
Srry for not being clear, by "best fit" I mean a plane that minimize the total sum of distances to all pointsHuyNA
I believe the term is "ordinary least squares" fitHuyNA

2 Answers

1
votes

Sure, just look at the general definition. Lets assume---for simplification reasons---the case of a line. You'd have some (matrix equation)

[ 1 <x> ] [a] = [ <y> ] [ <x> <x^2> ] [b] [ <xy>]

that needs to be solved. The result can be expressed in terms the according means. So you only need to know how, e.g. <xy> changes when you go from n to n+1. I.e. sum x_i y_i= n <x y> and the new one would be

<xy>_new= (n<xy>_old+x_new * y_new)/(n+1)

Now you just need to write down the according equations for the plane.

P.S.: Once again a pity that MathJax isn't working here

1
votes

Poppinga-09 has what you are looking for (section II). It will not only give you the new plane but also the new MSE. The follow-up Birk-09 also models sensor noise, if that is applicable to your case.