Approximation of n points to the curve with the best fit

后端 未结 2 426
闹比i
闹比i 2020-12-21 22:16

I have a list of n points(2D): P1(x0,y0), P2(x1,y1), P3(x2,y2) … Points satisfy the condition that each point has unique coordinates and also the coordinates of each point

2条回答
  •  眼角桃花
    2020-12-21 23:10

    Taking B as an independent parameter, you can solve the fitting for A using least-squares, and compute the fitting residual.

    The residue function is complex, with numerous minima of different value, and an irregular behavior. Anyway, if the Xi are integer, the function is periodic, with a period related to the LCM of the Xi.

    The plots below show the fitting residue for B varying from 0 to 2 and from 0 to 10, with the given sample points.

    enter image description here enter image description here

提交回复
热议问题