It is known that the observation data is as shown in the following table, and the minimum squares fit function is obtained according to the subordinate scheme, and the deviation is equal to the squad and the proportion of the fitting curve. X: 0 0.2 0.6 1.0 1.3 1.6 1.7 1.8 1.0 3.5 -2.0 -1.0 2.0 3.5 4.0 7.0 7.5 9.9 x: 2.9 3.1 3.4 3.8 4.1 4.4 4.7 4.8 4.9 5.0 5.1 5.3 Y: 10.9 11.9 13.5 13.0 11.9 9.0 6.5 4.0 1.5 0.0 -2.5 -5.0
% Using a discrete orthogonal polynomial, a polynomial% x, y - represents the node coordinate% W - indicates the weight coefficient% N - indicates the highest number of discrete orthogonal polynomes to be fitted. PolyApproximate () - is a custom function, can solve the polynomial coefficient% of its return value C is a polynomial factor, Error is a partial square and x = [0 0.2 0.6 1.0 1.3 1