Numerical Methods

149_Quadratic Interpolation

elif 2024. 4. 27. 22:44

In the previous post, errors occurred because curves were approximated as straight lines. One way to improve the estimates is to introduce some curvature to the line connecting the points. When three data points. When three data points are available, this can be accomplished using a second-degree polynomial.

 

 

The equation can be summarized as follows.

 

 

Therefore, the above equation represents the form of the unique second-degree polnomial that connects the three points. The values of the coefficients can be determined using the following steps.

 

 

Similarly to linear interpolation, ${b_1}$ represents the slope of the line connecting ${x_0}$ and ${x_1}$. Thus, the first two terms of the first equation are equivalent to the linear interpolation from ${x_0}$ to ${x_1}$ as specified in the previous equation, and the last term, ${b_2}(x - {x_0})(x - {x_1})$, introduces quadratic curvature to the formula. This additional term allows the polynomial to better fit data points that display a nonlinear trend.

Look at how interpolate between three points through an example. As with the previous example, find the value of $\ln 2$ through interpolation.

 

 

Here, ${b_0}$ is zero. Therefore, it can be calculated as follows.

 

 

When these calculated values are substituted into the first equation, a quadratic equation results.

 

 

This value show an error of about 18.4% compared to the actual value of 0.6931472. Therefore, the curvature introduced in the form of a parabola provides a better interpolation result compared to the previous result using a straight line.

'Numerical Methods' 카테고리의 다른 글

151_Lagrange Interpolation Polynomials  (0) 2024.04.29
150_Newton's Interpolation Polynomials  (0) 2024.04.28
148_Linear Interpolation  (0) 2024.04.26
147_Nonlinear Regression  (1) 2024.04.25
146_Polynomial Regression  (0) 2024.04.24