 Login  |   Contact  |   About Us       Tuesday, May 17, 2022  ~ Cubic Spline Method ~ Newton Method ~ Lagrange Method ~ Barycentric Method ~ Bilinear Method

 "Interpolation Solutions" Bilinear Interpolation Method
 X = (0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9)
 Y = (0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9)

 Results Z = 2.7, 3.4, 4.1, 4.8, 5.5, 6.2, 6.9, 7.6, 8.3 3.4, 3.4, 4.65, 5.2, 5.75, 6.2, 6.85, 7.4, 7.95 4.1, 3.4, 5.2, 5.6, 6, 6.2, 6.8, 7.2, 7.25 4.8, 3.4, 5.75, 6, 6.25, 6.2, 6.75, 7, 7.25 5.5, 3.4, 6.3, 6.4, 6.5, 6.2, 6.7, 6.8, 6.9 6.2, 3.4, 6.85, 6.8, 6.75, 6.2, 6.65, 6.6, 6.55 6.9, 3.4, 7.4, 7.2, 7, 6.2, 6.6, 6.4, 6.2 7.6, 3.4, 7.95, 7.6, 7.25, 6.2, 6.55, 6.2, 5.85

 Grid Values = { , , , } [ Initial GridValues X: {0,10} ] [ Initial GridValues Y: {10,5} ]

IMPLEMENTATION
Bilinear Interpolation

The bilinear interpolation is an extension of the linear interpolation for interpolating functions of two variables, z = f(x,y), on a regular grid. This type of interpolation plays an important role in computer vision and image processing. It is a texture mapping method that produces a reasonably realistic image, and is also known as bilinear texture mapping.

Algorithm Creation

The bilinear interpolation uses four vertex values sorrounding each rectangular unit cell to obtain any value inside the unit cell. To get the value at (x,y), and the vertices of the unit cell are located at (x0,y0),(x0,y1),(x1,y0), and (x1,y1), where they have the given function values z00,z01, z10, and z11, respectively.

The linear interpolation on the top row of neighbors, between (x0,y0) and (x1,y0), estimates the value f(x1,y0) at (x1, y0) as:

 f(x,y0) = x1 - x / x1 - x0 z00 + x - x0 / x1 - x0 * z10

Likewise, the linear interpolation on the bottom row of neighbors follow the same concept. Testing the Bilinear Interpolation Method

In order to test the Bilinear Interpolation method as defined above, a new TestBilinear() static method has been added and executed. Supporting code and methods are not shown.

In order to test the bilinear interpolation, a two-dimensional data mapping grid with four points was defined: (0,0), (0,1), (1,0), and (1,1), which have the values 0, 10, 10, and 5, respectively. The user can manipulate grid values to test the bilinear method.

static void TestBilinear();
{
ListBox1.Items.Clear();
ListBox2.Items.Clear();
ListBox3.Items.Clear();
double[] xarray = new double[] { 0,1 };
double[] yarray = new double[] { 0,1 };
double[] x = new double;
double[] y = new double;
MatrixR z = new MatrixR(9, 9);;
VectorR vx = new VectorR(x);
VectorR vy = new VectorR(y);
for (int i = 0; i < 9; i++)
{
for (int j = 0; j < 9; j++)
{
z[i, j] = Interpolation.Bilinear(xarray, yarray, zarray, x[i], y[j]);
}
}

 Other Implementations...

 Object-Oriented Implementation Graphics and Animation Sample Applications Ore Extraction Optimization Vectors and Matrices Complex Numbers and Functions Ordinary Differential Equations - Euler Method Ordinary Differential Equations 2nd-Order Runge-Kutta Ordinary Differential Equations 4th-Order Runge-Kutta Higher Order Differential Equations Nonlinear Systems Numerical Integration Numerical Differentiation Function Evaluation  Math, Analysis,
expertise..."

EIGENVALUE
SOLUTIONS...

> Rayleigh-Quotient Method

> Cubic Spline Method

 Applied Mathematical Algorithms ComplexFunctions NonLinear Differentiation Integration
 About Us KMP Software Engineering is an independent multidisciplinary engineering consulting company specializing in mathematical algorithms. Areas of Expertise SpecialFunctions VectorsMatrices OptimizationMethods ComplexNumbers Interpolation CurveFitting NonLinearSystems LinearEquations DistributionFunctions NumericalDifferentiation NumericalIntegration DifferentialEquations Smalltalk FiniteBoundary Eigenvalue Graphics UnderstandingMining MiningMastery MineralNews MineralCommodities MineralForum Crystallography Services NumericalModeling WebServices MainframeServices OutsourceServices LINKED IN KMP ARTICLES Brand Login Contact