VPInterpolation interp2 Method Virtual Photonics - VTS Library
Virtual Photonics
Interpolation in two dimensions

Namespace: Vts.Common.Math
Assembly: Vts (in Vts.dll) Version: 1.0.12.0 (1.0.12)
Syntax

public static double interp2(
	IList<double> x,
	IList<double> y,
	double[,] f,
	double xi,
	double yi
)

Parameters

x
Type: OnlineSystem.Collections.Generic IList OnlineDouble 
The known independent values
y
Type: OnlineSystem.Collections.Generic IList OnlineDouble 
The known independent values
f
Type:  OnlineSystem Double 
The known dependent values
xi
Type: OnlineSystem Double
x value to at which to interpolate
yi
Type: OnlineSystem Double
y value to at which to interpolate

Return Value

Type: OnlineDouble
The interpolated value (clamped to boundary values if xi are of range)
Remarks

Assumptions: 1) x and y are monotonically increasing, and 2) xi and yi are inclusive to x and y respectively for interpolated results, otherwise return NaN
See Also