25 #include <queso/GenericScalarCovarianceFunction.h>
30 template<
class V,
class M>
34 double (*covRoutinePtr)(
const V& positionVector1,
const V& positionVector2,
const void* routineDataPtr),
35 const void* routinesDataPtr)
38 m_covRoutinePtr (covRoutinePtr),
39 m_routineDataPtr (routinesDataPtr)
54 template<
class V,
class M>
57 if ((m_env.subDisplayFile()) && (m_env.displayVerbosity() >= 54)) {
58 *m_env.subDisplayFile() <<
"Entering GenericScalarCovarianceFunction<V,M>::destructor()"
59 <<
": prefix = " << m_prefix
63 if ((m_env.subDisplayFile()) && (m_env.displayVerbosity() >= 54)) {
64 *m_env.subDisplayFile() <<
"Leaving GenericScalarCovarianceFunction<V,M>::destructor()"
65 <<
": prefix = " << m_prefix
70 template<
class V,
class M>
74 if ((m_env.subDisplayFile()) && (m_env.displayVerbosity() >= 54)) {
75 *m_env.subDisplayFile() <<
"Entering GenericScalarCovarianceFunction<V,M>::value()"
79 queso_require_msg(m_covRoutinePtr,
"m_covRoutinePtr = NULL");
81 double result = m_covRoutinePtr(positionVector1, positionVector2, m_routineDataPtr);
83 if ((m_env.subDisplayFile()) && (m_env.displayVerbosity() >= 54)) {
84 *m_env.subDisplayFile() <<
"Leaving GenericScalarCovarianceFunction<V,M>::value()"
double value(const V &positionVector1, const V &positionVector2) const
Calculates the value of the generic covariance function.
A templated class for handling sets.
GenericScalarCovarianceFunction(const char *prefix, const VectorSet< V, M > &domainSet, double(*covRoutinePtr)(const V &positionVector1, const V &positionVector2, const void *routineDataPtr), const void *routinesDataPtr)
Default constructor.
A templated (base) class to accommodate scalar covariance functions (of random variables).
const BaseEnvironment & m_env
unsigned int displayVerbosity() const
virtual ~GenericScalarCovarianceFunction()
Virtual destructor.
std::ofstream * subDisplayFile() const
Access function for m_subDisplayFile (displays file on stream).