Class funct_multip_string (o2scl)

O2scl : Class List

class funct_multip_string

Evaluate a one-dimensional function from a string at multiprecision.

Note

Experimental.

Warning

This class only supports a limited number of data types, including double, long double, and cpp_dec_float types with 25, 35, 50, or 100 digits. It is designed to be used with the funct_multip class.

Typedefs for multiprecision types

typedef boost::multiprecision::number<boost::multiprecision::cpp_dec_float<25>> cpp_dec_float_25
typedef boost::multiprecision::number<boost::multiprecision::cpp_dec_float<35>> cpp_dec_float_35
typedef boost::multiprecision::cpp_dec_float_50 cpp_dec_float_50
typedef boost::multiprecision::cpp_dec_float_100 cpp_dec_float_100

The function evaluation objects

calc_utf8<double> c
calc_utf8<long double> c_ld
calc_utf8<cpp_dec_float_25> c_25
calc_utf8<cpp_dec_float_35> c_35
calc_utf8<cpp_dec_float_50> c_50
calc_utf8<cpp_dec_float_100> c_100

The variable lists

std::map<std::string, double> vars
std::map<std::string, long double> vars_ld
std::map<std::string, cpp_dec_float_25> vars_25
std::map<std::string, cpp_dec_float_35> vars_35
std::map<std::string, cpp_dec_float_50> vars_50
std::map<std::string, cpp_dec_float_100> vars_100
bool compiled

If true, then the most recent function has been compiled in all of the function evaluation objects.

std::string st_form

The expression to be evaluated.

std::string st_var

The variable.

int verbose

Verbosity parameter.

bool err_nonconv

If true, call the error handler if the function evaluation fails.

inline funct_multip_string()
inline virtual ~funct_multip_string()
inline int set_function(std::string expr, std::string var)

Set the function to compute.

template<class fp_t>
inline fp_t operator()(fp_t x)

Compute the function at the value x.

funct_multip_string(const funct_multip_string&)
funct_multip_string &operator=(const funct_multip_string&)