49 #include "../utility/numutil.h"
57 "respond to a request for a value lookup" );
68 "Minimum value of x. x below this will result in y[0] being returned.",
74 "Maximum value of x. x above this will result in y[last] being"
88 "Interpolates using the input as x value.",
92 "Handles process call, updates internal time stamp.",
95 "Handles reinit call.",
100 static Finfo* procShared[] = {
104 "Shared message for process and reinit",
105 procShared,
sizeof( procShared ) /
sizeof(
const Finfo* )
113 static Finfo* interpolFinfos[] = {
123 static string doc[] =
126 "Author",
"Upinder Bhalla, Subhasis Ray, 2014, NCBS",
127 "Description",
"Interpol: Interpolation class. "
128 "Handles lookup from a 1-dimensional array of real-numbered values."
129 "Returns 'y' value based on given 'x' value. "
130 "Can either use interpolation or roundoff to the nearest index.",
138 sizeof( interpolFinfos ) /
sizeof (
Finfo* ),
141 sizeof(doc) /
sizeof(
string));
160 cerr <<
"Error: Interpol::setXmin: Xmin ~= Xmax : Assignment failed\n";
174 cerr <<
"Error: Interpol::setXmax: Xmin ~= Xmax : Assignment failed\n";
static const Cinfo * interpolCinfo
bool almostEqual(float x, float y, float epsilon)
void setXmin(double value)
double interpolate(double x, double xmin, double xmax) const
void handleInput(double x)
void process(const Eref &e, ProcPtr p)
static SrcFinfo1< double > * lookupOut()
void reinit(const Eref &e, ProcPtr p)
static const Cinfo * initCinfo()
static const Cinfo * initCinfo()
void setXmax(double value)