Class emulator_interpm_idw_table (o2scl)

O2scl : Class List

template<class vec2_t = boost::numeric::ublas::vector<double>, class vec_t = boost::numeric::ublas::vector<double>>
class emulator_interpm_idw_table : public o2scl::emulator_unc<boost::numeric::ublas::vector<double>, boost::numeric::ublas::vector<double>, boost::numeric::ublas::vector<double>>

Emulate data stored in a table object with interpm_idw.

This class is experimental.

Note

Currently, this emulator only works if the data object from the MCMC class is a vector type so that it knows how to find the “log weight” output

Public Functions

inline emulator_interpm_idw_table()

Create an emulator.

inline void set(size_t np, size_t n_out, size_t ix_log_wgt, table<> &t, std::vector<std::string> &list_in, std::vector<std::string> &list_out)

Set the emulator.

Set the emulator using a table containing np parameters and n_out output quantities. The variable ix_log_wgt should be the index of the log_weight among all of the output variables, from 0 to n_out-1. The list, list, should include the column names of the parameters and then the output quantities (including the log weight column), in order.

inline virtual int eval_unc(size_t n, const vec_t &p, double &log_wgt, double &log_wgt_unc, vec2_t &dat, vec2_t &dat_unc)

Evaluate the emulator at the point p returning log_wgt and dat and their uncertainties.

Public Members

o2scl::interpm_idw<boost::numeric::ublas::vector<double>, o2scl::const_matrix_view_table<>, o2scl::matrix_view_table<>> ii

The internal interpolation object.

Protected Attributes

const_matrix_view_table cmvt_x

The view of the user-specified table.

matrix_view_table cmvt_y

The view of the user-specified table.

size_t ix

Index of the “log weight” in the MCMC data vector.