Interpolation Dr. Mihail October 26, 2015 (Dr. Mihail) Interpolation October 26, 2015 1 / 11
Definitions 1 Interpolation: method of constructing new data points from sampling or experimentation. (Dr. Mihail) Interpolation October 26, 2015 2 / 11
Case study Spoze we have x f(x) 0 0 1 0.8415 2 0.9093 3 0.1411 4 -0.7568 5 -0.9589 6 -0.2794 (Dr. Mihail) Interpolation October 26, 2015 3 / 11
Case study Piecewise constant (Dr. Mihail) Interpolation October 26, 2015 4 / 11
Case study Piecewise linear (Dr. Mihail) Interpolation October 26, 2015 5 / 11
Case study Piecewise linear Given two data points, say ( x a , y a ) and ( x b , y b ), the interpolant function is given by: y = y a + ( y b − y a ) x − x a x b − x a (Dr. Mihail) Interpolation October 26, 2015 6 / 11
Case study Polynomial f ( x ) = − 0 . 0001521 x 6 − 0 . 003130 x 5 +0 . 07321 x 4 − 0 . 3577 x 3 +0 . 2255 x 2 +0 . 9038 x (Dr. Mihail) Interpolation October 26, 2015 7 / 11
Other methods Interpolation Methods Piecewise polynomial Spline Barycentric coordinates for interpolating on a triangle or tetrahedron Gaussian process And others... (Dr. Mihail) Interpolation October 26, 2015 8 / 11
2D functions Extend concept to multivariate functions (Dr. Mihail) Interpolation October 26, 2015 9 / 11
Bilinear interpolation Problem setting Suppose you have a function f ( x , y ). You know the value of that function for a limited number of points (e.g., 4 points). Your goal is to approximate the function at arbitrary points ( x , y ). (Dr. Mihail) Interpolation October 26, 2015 10 / 11
Bilinear interpolation We first do linear interpolation along the X-axis: R 1 = f ( x , y 1 ) ≈ x 2 − x f ( Q 11 ) + x − x 1 f ( Q 21 ) x 2 − x 1 x 2 − x 1 R 2 = f ( x , y 2 ) ≈ x 2 − x f ( Q 12 ) + x − x 1 f ( Q 22 ) x 2 − x 1 x 2 − x 1 (Dr. Mihail) Interpolation October 26, 2015 11 / 11
Bilinear interpolation We then do linear interpolation along the Y-axis: f ( x , y ) ≈ y 2 − y f ( x , y 1 ) + y − y 1 f ( x , y 2 ) y 2 − y 1 y 2 − y 1 1 f ( x , y ) ≈ ( f ( Q 11 )( x 2 − x )( y 2 − y )+ f ( Q 21 )( x − x 1 )( y 2 − y )+ f ( Q 12 )( x 2 − x )( y − y 1 )+ f ( Q 22 )( x − x 1 )( y − y 1 )) ( x 2 − x 1 )( y 2 − y 1 ) (Dr. Mihail) Interpolation October 26, 2015 12 / 11
Recommend
More recommend