public class Interpolation
extends java.lang.Object
Modifier and Type | Method | Description |
---|---|---|
static double |
lagrange(double x,
double[] xd,
double[] yd) |
Lagrange polynomial interpolation at a single point x.
|
static double |
linear(double x,
double x0,
double x1,
double y0,
double y1) |
Linear interpolation at a single point x.
|
public static double linear(double x, double x0, double x1, double y0, double y1)
x
- doublex0
- doublex1
- doubley0
- doubley1
- doublepublic static double lagrange(double x, double[] xd, double[] yd)
x
- doublexd
- double[] the x datayd
- double[] the y data