cgv
|
#include <mfunc.h>
Public Types | |
typedef cgv::math::vec< X > | pnt_type |
points must have get_nr_independent_variables() components | |
typedef cgv::math::vec< X > | vec_type |
vectors must have get_nr_independent_variables() components | |
Public Member Functions | |
virtual | ~mfunc () |
virtual destructor | |
virtual unsigned | get_nr_independent_variables () const =0 |
return the number of independent variables that are mapped by the function | |
virtual T | evaluate (const pnt_type &p) const =0 |
interface for evaluation of the multivariate function | |
virtual vec_type | evaluate_gradient (const pnt_type &p) const |
interface class for multivariate function with two template arguments:
|
inlinevirtual |
interface for evaluation of the gradient of the multivariate function. default implementation uses central differences to approximate the gradient, with an epsilon of 1e-5.