Let Y = a1 + a2x + a3x2 ( 2nd order polynomial ).
Here, m = 3 ( because to fit a curve we need at least 3 points ).
Since the order of the polynomial is 2, therefore we will have 3 simultaneous equations as below.
Polynomial Regression Formula
To learn more, see what is Polynomial Regression
Now we have to evaluate the values which are required according to the above equations.
Let us find the value of x2, x3, x4, yx, and yx2.
Put the values in the above 3 equations as below.
4a1 + 10a2 + 30a3 = 62 …. ( 1 )
10a1 + 30a2 + 100a3 = 190 …. ( 2 )
30a1 + 100a2 + 354a3 = 644 … ( 3 )
In order to solve the above 3 simultaneous equations, we will write the above equations in the form of matrices as below.
Now by using back substitution we can find the values of a1, a2, and a3.
Here, 4a3 = 4 , a3 = 1
And, a2 + 5a3 = 7 , a2 = 2
Also, a1 + 2.5a2 + 7.5a3 = 15.5 , a1 = 3
Therefore, a1 = 3, a2 = 2, a3 = 1.
The Quadratic equation becomes:
Y = 3 + 2x + x2, or
Y = x2 + 2x + 3
- Newtons Interpolation
- Lagrange’s Interpolation
- Bisection method
- Regula falsi method
- Linear Regression