Class tensor_grid2 (o2scl)

O2scl : Class List

template<class vec_t = std::vector<double>, class vec_size_t = std::vector<size_t>>
class o2scl::tensor_grid2 : public o2scl::tensor_grid<std::vector<double>, std::vector<size_t>>

Rank 2 tensor with a grid.

Public Functions

tensor_grid2()

Create an empty tensor.

tensor_grid2(size_t sz, size_t sz2)

Create a rank 2 tensor of size (sz,sz2)

~tensor_grid2()
double &get(size_t ix1, size_t ix2)

Get the element indexed by (ix1,ix2)

const double &get(size_t ix1, size_t ix2) const

Get the element indexed by (ix1,ix2)

void set(size_t ix1, size_t ix2, double val)

Set the element indexed by (ix1,ix2) to value val.

template<class range_t = ub_range, class data_range_t = ubvector_range, class index_range_t = ubvector_size_t_range>
double interp(double x, double y)

Interpolate (x,y) and return the results.

double interp_linear(double x, double y)

Interpolate (x,y) and return the results.