public class MultivariateArrayGrid extends Object implements MultivariateGrid
MultivariateGrid
, backed by the given
MultiDimensionalCollection
instance.Constructor and Description |
---|
MultivariateArrayGrid(MultiDimensionalCollection<Double> y,
double[]... x)
Create a new instance where the dependent variable is specified by a
MultiDimensionalCollection and the independent variables form the specified grid. |
Modifier and Type | Method and Description |
---|---|
int |
dimension()
Get the total number of dimensions of the grid.
|
int |
size(int i)
Get the size of the grid in the given dimension xi.
|
double[] |
x(int i)
Get all the values of the independent variable xi as an array.
|
double |
x(int i,
int j)
Get the value of the independent variable xi at the given index.
|
double |
y(int... indices)
Get the value of the dependent variable y at the given indices in the grid.
|
public MultivariateArrayGrid(MultiDimensionalCollection<Double> y, double[]... x)
MultiDimensionalCollection
and the independent variables form the specified grid.y
- the values of the dependent variablex
- each element specifies the grid of independent variables along one dimensionpublic double y(int... indices)
MultivariateGrid
y
in interface MultivariateGrid
indices
- the indices of the independent variables in the gridpublic double x(int i, int j)
MultivariateGrid
x
in interface MultivariateGrid
i
- the dimension index of the independent variable xij
- the index of the value in the specified dimension xipublic double[] x(int i)
MultivariateGrid
x
in interface MultivariateGrid
i
- the dimension index of the independent variable xipublic int size(int i)
MultivariateGrid
size
in interface MultivariateGrid
i
- the dimension index of the independent variable xipublic int dimension()
MultivariateGrid
dimension
in interface MultivariateGrid
Copyright © 2010-2020 NM FinTech Ltd.. All Rights Reserved.