Table
-
class Table
Table values are assumed to be equally spaced and vary from 0 to 1.
Subclassed by feasst::Table1D, feasst::Table2D, feasst::Table3D, feasst::Table4D, feasst::Table5D, feasst::Table6D
Public Functions
-
virtual double minimum() const = 0
Return the minimum of all elements.
-
virtual double maximum() const = 0
Return the maximum of all elements.
-
double bin_spacing(const int num)
Return the bin spacing for a given number of elements.
-
virtual void write(const std::string file_name) const
Write to file.
-
virtual double minimum() const = 0
-
class Table1D : public feasst::Table
This is a one-dimensional implementation of a table.
Public Functions
-
Table1D(argtype args = argtype())
args:
num: number of values (default: 1).
default_value: initialize data to this constant (default: 0).
-
int num() const
Return the number of values.
-
double bin_to_value(const int bin) const
For a given dimension, return the value of a bin.
-
int value_to_nearest_bin(const double value) const
The inverse of above.
-
void set_data(const int dim0, const double value)
Set data.
-
const std::vector<double> &data() const
Return the data.
-
double linear_interpolation(const double value0) const
Return linear interpolation of data given normalized values.
-
double forward_difference_interpolation(const double value0) const
Return the Newton-Gregory forward difference interpolation. See Allen and Tildesley, 5.2.2, Booth 1972
-
double minimum() const
Return the minimum of all elements.
-
double maximum() const
Return the maximum of all elements.
-
Table1D(argtype args = argtype())
-
class Table2D : public feasst::Table
This is a two-dimensional implementation of a table.
Public Functions
-
Table2D(argtype args = argtype())
args:
num0: number of values in first dimension (default: 1).
num1: number of values in second dimension (default: 1).
default_value: initialize data to this constant (default: 0).
-
int num0() const
Return the number of values in the first dimension.
-
int num1() const
Return the number of values in the second dimension.
-
int num(const int dim) const
Return the number of values in a given dimension.
-
double bin_to_value(const int dim, const int bin) const
For a given dimension, return the value of a bin.
-
int value_to_nearest_bin(const int dim, const double value) const
The inverse of above.
-
void set_data(const int dim0, const int dim1, const double value)
Set data.
-
const vec2 &data() const
Return the data.
-
double linear_interpolation(const double value0, const double value1) const
Return linear interpolation of data given normalized values for each dimension that range from 0 to 1, inclusive.
-
double minimum() const
Return the minimum of all elements.
-
double maximum() const
Return the maximum of all elements.
-
Table2D(argtype args = argtype())
-
class Table3D : public feasst::Table
This is a three-dimensional implementation of a table.
Public Functions
-
Table3D(argtype args = argtype())
args:
num0: number of values in first dimension (default: 1).
num1: number of values in second dimension (default: 1).
num2: number of values in third dimension (default: 1).
default_value: initialize data to this constant (default: 0).
-
int num0() const
Return the number of values in the first dimension.
-
int num1() const
Return the number of values in the second dimension.
-
int num2() const
Return the number of values in the third dimension.
-
int num(const int dim) const
Return the number of values in a given dimension.
-
double bin_to_value(const int dim, const int bin) const
For a given dimension, return the value of a bin.
-
int value_to_nearest_bin(const int dim, const double value) const
The inverse of above.
-
void set_data(const int dim0, const int dim1, const int dim2, const double value)
Set data.
-
const vec3 &data() const
Return the data.
-
double linear_interpolation(const double value0, const double value1, const double value2) const
Return linear interpolation of data given normalized values for each dimension that range from 0 to 1, inclusive.
-
double minimum() const
Return the minimum of all elements.
-
double maximum() const
Return the maximum of all elements.
-
void write(const std::string file_name) const
Write to file.
-
Table3D(const std::string file_name)
Read from file.
-
Table3D(argtype args = argtype())
-
class Table4D : public feasst::Table
This is a four-dimensional implementation of a table.
Public Functions
-
Table4D(argtype args = argtype())
args:
num0: number of values in first dimension (default: 1).
num1: number of values in second dimension (default: 1).
num2: number of values in third dimension (default: 1).
num3: number of values in fourth dimension (default: 1).
default_value: initialize data to this constant (default: 0).
-
int num0() const
Return the number of values in the first dimension.
-
int num1() const
Return the number of values in the second dimension.
-
int num2() const
Return the number of values in the third dimension.
-
int num3() const
Return the number of values in the fourth dimension.
-
int num(const int dim) const
Return the number of values in a given dimension.
-
double bin_to_value(const int dim, const int bin) const
For a given dimension, return the value of a bin.
-
int value_to_nearest_bin(const int dim, const double value) const
The inverse of above.
-
void set_data(const int dim0, const int dim1, const int dim2, const int dim3, const double value)
Set data.
-
const vec4 &data() const
Return the data.
-
double linear_interpolation(const double value0, const double value1, const double value2, const double value3) const
Return linear interpolation of data given normalized values for each dimension that range from 0 to 1, inclusive.
-
double minimum() const
Return the minimum of all elements.
-
double maximum() const
Return the maximum of all elements.
-
void write(const std::string file_name) const
Write to file.
-
Table4D(const std::string file_name)
Read from file.
-
Table4D(argtype args = argtype())
-
class Table5D : public feasst::Table
This is a five-dimensional implementation of a table.
Public Functions
-
Table5D(argtype args = argtype())
args:
num0: number of values in first dimension (default: 1).
num1: number of values in second dimension (default: 1).
num2: number of values in third dimension (default: 1).
num3: number of values in fourth dimension (default: 1).
num4: number of values in fourth dimension (default: 1).
default_value: initialize data to this constant (default: 0).
-
int num0() const
Return the number of values in the first dimension.
-
int num1() const
Return the number of values in the second dimension.
-
int num2() const
Return the number of values in the third dimension.
-
int num3() const
Return the number of values in the fourth dimension.
-
int num4() const
Return the number of values in the fifth dimension.
-
int num(const int dim) const
Return the number of values in a given dimension.
-
double bin_to_value(const int dim, const int bin) const
For a given dimension, return the value of a bin.
-
int value_to_nearest_bin(const int dim, const double value) const
The inverse of above.
-
void set_data(const int dim0, const int dim1, const int dim2, const int dim3, const int dim4, const double value)
Set data.
-
const fvec5 &data() const
Return the data.
-
double linear_interpolation(const double value0, const double value1, const double value2, const double value3, const double value4) const
Return linear interpolation of data given normalized values for each dimension that range from 0 to 1, inclusive.
-
double minimum() const
Return the minimum of all elements.
-
double maximum() const
Return the maximum of all elements.
-
void write(const std::string file_name) const
Write to file.
-
Table5D(const std::string file_name)
Read from file.
-
Table5D(argtype args = argtype())
-
class Table6D : public feasst::Table
This is a six-dimensional implementation of a table.
Public Functions
-
Table6D(argtype args = argtype())
args:
num0: number of values in first dimension (default: 1).
num1: number of values in second dimension (default: 1).
num2: number of values in third dimension (default: 1).
num3: number of values in fourth dimension (default: 1).
num4: number of values in fourth dimension (default: 1).
num5: number of values in fourth dimension (default: 1).
default_value: initialize data to this constant (default: 0).
-
int num0() const
Return the number of values in the first dimension.
-
int num1() const
Return the number of values in the second dimension.
-
int num2() const
Return the number of values in the third dimension.
-
int num3() const
Return the number of values in the fourth dimension.
-
int num4() const
Return the number of values in the fifth dimension.
-
int num5() const
Return the number of values in the sixth dimension.
-
int num(const int dim) const
Return the number of values in a given dimension.
-
double bin_to_value(const int dim, const int bin) const
For a given dimension, return the value of a bin.
-
int value_to_nearest_bin(const int dim, const double value) const
The inverse of above.
-
void set_data(const int dim0, const int dim1, const int dim2, const int dim3, const int dim4, const int dim5, const double value)
Set data.
-
const fvec6 &data() const
Return the data.
-
double linear_interpolation(const double value0, const double value1, const double value2, const double value3, const double value4, const double value5) const
Return linear interpolation of data given normalized values for each dimension that range from 0 to 1, inclusive.
-
double minimum() const
Return the minimum of all elements.
-
double maximum() const
Return the maximum of all elements.
-
void write(const std::string file_name) const
Write to file.
-
Table6D(const std::string file_name)
Read from file.
-
Table6D(argtype args = argtype())