queso-0.57.1
|
A class for handling Log-Normal joint PDFs. More...
#include <LogNormalJointPdf.h>
Public Member Functions | |
Constructor/Destructor methods | |
LogNormalJointPdf (const char *prefix, const VectorSet< V, M > &domainSet, const V &lawExpVector, const V &lawVarVector) | |
Constructor. More... | |
~LogNormalJointPdf () | |
Destructor. More... | |
Math methods | |
double | actualValue (const V &domainVector, const V *domainDirection, V *gradVector, M *hessianMatrix, V *hessianEffect) const |
Actual value of the Log-Normal PDF (scalar function). More... | |
double | lnValue (const V &domainVector, const V *domainDirection, V *gradVector, M *hessianMatrix, V *hessianEffect) const |
Logarithm of the value of the Log-Normal PDF (scalar function). More... | |
virtual void | distributionMean (V &meanVector) const |
Mean value of the underlying random variable. More... | |
virtual void | distributionVariance (M &covMatrix) const |
Covariance matrix of the underlying random variable. More... | |
double | computeLogOfNormalizationFactor (unsigned int numSamples, bool updateFactorInternally) const |
Computes the logarithm of the normalization factor. More... | |
const V & | lawExpVector () const |
Access to the vector of mean values and private attribute: m_lawExpVector. More... | |
const V & | lawVarVector () const |
Access to the vector of variance values and private attribute: m_lawVarVector. More... | |
Public Member Functions inherited from QUESO::BaseJointPdf< V, M > | |
BaseJointPdf (const char *prefix, const VectorSet< V, M > &domainSet) | |
Default constructor. More... | |
virtual | ~BaseJointPdf () |
Destructor. More... | |
virtual void | setNormalizationStyle (unsigned int value) const |
void | setLogOfNormalizationFactor (double value) const |
Sets a logarithmic value to be used in the normalization factor (stored in the protected attribute m_normalizationStyle.) More... | |
virtual void | print (std::ostream &os) const |
Print method. Non-pure for backwards compatibility. More... | |
Public Member Functions inherited from QUESO::BaseScalarFunction< V, M > | |
void | setFiniteDifferenceStepSize (double fdStepSize) |
Sets the step size for finite differencing gradients. More... | |
void | setFiniteDifferenceStepSize (unsigned int i, double fdStepSize) |
BaseScalarFunction (const char *prefix, const VectorSet< V, M > &domainSet) | |
Default constructor. More... | |
virtual | ~BaseScalarFunction () |
Destructor. More... | |
const VectorSet< V, M > & | domainSet () const |
Access to the protected attribute m_domainSet: domain set of the scalar function. More... | |
virtual double | lnValue (const V &domainVector) const |
Returns the logarithm of the function at domainVector . More... | |
virtual double | lnValue (const V &domainVector, V &gradVector) const |
Returns the logarithm of the function and its gradient at domainVector . More... | |
virtual double | lnValue (const V &domainVector, V &gradVector, const V &domainDirection, V &hessianEffect) const |
Protected Attributes | |
V * | m_lawExpVector |
V * | m_lawVarVector |
bool | m_diagonalCovMatrix |
Protected Attributes inherited from QUESO::BaseJointPdf< V, M > | |
unsigned int | m_normalizationStyle |
double | m_logOfNormalizationFactor |
Protected Attributes inherited from QUESO::BaseScalarFunction< V, M > | |
const BaseEnvironment & | m_env |
std::string | m_prefix |
const VectorSet< V, M > & | m_domainSet |
Domain set of the scalar function. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from QUESO::BaseJointPdf< V, M > | |
double | commonComputeLogOfNormalizationFactor (unsigned int numSamples, bool updateFactorInternally) const |
Common method (to the derived classes) to compute the logarithm of the normalization factor. More... | |
A class for handling Log-Normal joint PDFs.
This class allows the mathematical definition of a Log-Normal Joint PDF.
Definition at line 50 of file LogNormalJointPdf.h.
QUESO::LogNormalJointPdf< V, M >::LogNormalJointPdf | ( | const char * | prefix, |
const VectorSet< V, M > & | domainSet, | ||
const V & | lawExpVector, | ||
const V & | lawVarVector | ||
) |
Constructor.
Constructs a new object of the class, given a prefix and the domain of the PDF, a vector of mean values, lawExpVector
, and a vector of covariance values lawVarVector
(an alternative representation for a diagonal covariance matrix).
Definition at line 33 of file LogNormalJointPdf.C.
References QUESO::BaseEnvironment::displayVerbosity(), QUESO::LogNormalJointPdf< V, M >::lawExpVector(), QUESO::LogNormalJointPdf< V, M >::lawVarVector(), QUESO::BaseScalarFunction< V, M >::m_env, QUESO::BaseScalarFunction< V, M >::m_prefix, and QUESO::BaseEnvironment::subDisplayFile().
QUESO::LogNormalJointPdf< V, M >::~LogNormalJointPdf | ( | ) |
|
virtual |
Actual value of the Log-Normal PDF (scalar function).
This method calls lnValue() and applies the exponential to its result.
Implements QUESO::BaseJointPdf< V, M >.
Definition at line 88 of file LogNormalJointPdf.C.
References QUESO::queso_require_equal_to_msg.
|
virtual |
Computes the logarithm of the normalization factor.
This routine calls BaseJointPdf::commonComputeLogOfNormalizationFactor().
Implements QUESO::BaseJointPdf< V, M >.
Definition at line 261 of file LogNormalJointPdf.C.
References QUESO::BaseJointPdf< V, M >::commonComputeLogOfNormalizationFactor().
|
virtual |
Mean value of the underlying random variable.
Reimplemented from QUESO::BaseJointPdf< V, M >.
Definition at line 215 of file LogNormalJointPdf.C.
|
virtual |
Covariance matrix of the underlying random variable.
Reimplemented from QUESO::BaseJointPdf< V, M >.
Definition at line 235 of file LogNormalJointPdf.C.
const V & QUESO::LogNormalJointPdf< V, M >::lawExpVector | ( | ) | const |
Access to the vector of mean values and private attribute: m_lawExpVector.
Definition at line 74 of file LogNormalJointPdf.C.
Referenced by QUESO::LogNormalJointPdf< V, M >::LogNormalJointPdf().
const V & QUESO::LogNormalJointPdf< V, M >::lawVarVector | ( | ) | const |
Access to the vector of variance values and private attribute: m_lawVarVector.
Definition at line 81 of file LogNormalJointPdf.C.
Referenced by QUESO::LogNormalJointPdf< V, M >::LogNormalJointPdf().
|
virtual |
Logarithm of the value of the Log-Normal PDF (scalar function).
The logarithm of the value of the Log-Normal density of diagonal covariance matrix (sigma^2) comes from the summation:
\[ lnValue =- \sum_i \frac{1}{domainVector_i * \sqrt{2 \pi * lawVarVector_i}} exp(-\frac{(\ln( domainVector_i) - lawExpVector_i)^2}{2 lawVarVector_i}) \]
as long as \( domainVector_i > 0 \) for all \( i \).
Reimplemented from QUESO::BaseScalarFunction< V, M >.
Definition at line 142 of file LogNormalJointPdf.C.
|
protected |
Definition at line 103 of file LogNormalJointPdf.h.
|
protected |
Definition at line 101 of file LogNormalJointPdf.h.
|
protected |
Definition at line 102 of file LogNormalJointPdf.h.