Of Notes
Simple Polynomial Curve Fitting
We start with a simple idea of how to fit a polynomial. We consider an underlying functions
This data is
Our goal is to make predictions of
Although this is a polynomial its called a linear model since the coefficients
We obtain our unknowns by minimizing an error function. The most common method is the sum of squares of erros between predictions and data:
We get
First rewrite this as a matrix problem where:
Then we get that
Now we can take the derivative of this with respect to
But since
When we set the gradient to zero we get the Normal Equations.
We can now evaluate the model on new data
We might also use the Root Mean Square Error (RMSE) which is defined as: