queso-0.53.0
|
A class for handling hybrid (transformed) Gaussians with bounds. More...
#include <InvLogitGaussianJointPdf.h>
Public Member Functions | |
Constructor/Destructor methods | |
InvLogitGaussianJointPdf (const char *prefix, const BoxSubset< V, M > &domainBoxSubset, const V &lawExpVector, const V &lawVarVector) | |
Constructor. More... | |
InvLogitGaussianJointPdf (const char *prefix, const BoxSubset< V, M > &domainBoxSubset, const V &lawExpVector, const M &lawCovMatrix) | |
Constructor. More... | |
~InvLogitGaussianJointPdf () | |
Destructor. More... | |
Math methods | |
double | actualValue (const V &domainVector, const V *domainDirection, V *gradVector, M *hessianMatrix, V *hessianEffect) const |
Actual value of the (transformed) Gaussian PDF. More... | |
double | lnValue (const V &domainVector, const V *domainDirection, V *gradVector, M *hessianMatrix, V *hessianEffect) const |
Logarithm of the value of the (transformed) Gaussian PDF (scalar function). More... | |
double | computeLogOfNormalizationFactor (unsigned int numSamples, bool updateFactorInternally) const |
Computes the logarithm of the normalization factor. More... | |
void | updateLawExpVector (const V &newLawExpVector) |
Updates the mean of the Gaussian (not transformed) with the new value newLawExpVector . More... | |
void | updateLawCovMatrix (const M &newLawCovMatrix) |
Updates the lower triangular matrix from Cholesky decomposition of the covariance matrix to the new value newLowerCholLawCovMatrix . More... | |
const M & | lawCovMatrix () const |
Returns the covariance matrix; access to protected attribute m_lawCovMatrix. More... | |
const V & | lawExpVector () const |
Access to the vector of mean values of the Gaussian (not transformed) 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 |
Sets a value to be used in the normalization style (stored in the protected attribute m_normalizationStyle.) More... | |
void | setLogOfNormalizationFactor (double value) const |
Sets a logarithmic value to be used in the normalization factor (stored in the protected attribute m_normalizationStyle.) More... | |
Public Member Functions inherited from QUESO::BaseScalarFunction< V, M > | |
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... | |
Private Attributes | |
V * | m_lawExpVector |
V * | m_lawVarVector |
bool | m_diagonalCovMatrix |
const M * | m_lawCovMatrix |
const BoxSubset< V, M > & | m_domainBoxSubset |
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... | |
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... | |
A class for handling hybrid (transformed) Gaussians with bounds.
This class allows the mathematical definition of a Gaussian PDF in dimensions of a VectorSubset that are unbounded, and a logit
transformed Gaussian PDF in dimensions that have a lower or upper (or both) bound. For the bounded directions, the PDF is
where logit
is defined as
Definition at line 58 of file InvLogitGaussianJointPdf.h.
QUESO::InvLogitGaussianJointPdf< V, M >::InvLogitGaussianJointPdf | ( | const char * | prefix, |
const BoxSubset< V, M > & | domainBoxSubset, | ||
const V & | lawExpVector, | ||
const V & | lawVarVector | ||
) |
Constructor.
Constructs a new object, given a prefix and the domain of the PDF, a vector of mean values, lawExpVector
(for the Gaussian, not the transformed Gaussian), and a vector of covariance values lawVarVector
(an alternative representation for a diagonal covariance matrix).
Definition at line 33 of file InvLogitGaussianJointPdf.C.
QUESO::InvLogitGaussianJointPdf< V, M >::InvLogitGaussianJointPdf | ( | const char * | prefix, |
const BoxSubset< V, M > & | domainBoxSubset, | ||
const V & | lawExpVector, | ||
const M & | lawCovMatrix | ||
) |
Constructor.
Constructs a new object, given a prefix and the image set of the vector realizer, a vector of mean values, lawExpVector
(for the Gaussian, not the transformed Gaussian), and a covariance matrix, lawCovMatrix
.
Definition at line 51 of file InvLogitGaussianJointPdf.C.
QUESO::InvLogitGaussianJointPdf< V, M >::~InvLogitGaussianJointPdf | ( | ) |
Destructor.
Definition at line 68 of file InvLogitGaussianJointPdf.C.
|
virtual |
Actual value of the (transformed) Gaussian PDF.
This method calls lnValue() and applies the exponential to it.
Implements QUESO::BaseJointPdf< V, M >.
Definition at line 91 of file InvLogitGaussianJointPdf.C.
|
virtual |
Computes the logarithm of the normalization factor.
This routine calls BaseJointPdf::commonComputeLogOfNormalizationFactor().
Implements QUESO::BaseJointPdf< V, M >.
Definition at line 207 of file InvLogitGaussianJointPdf.C.
References QUESO::BaseJointPdf< V, M >::commonComputeLogOfNormalizationFactor().
const M & QUESO::InvLogitGaussianJointPdf< V, M >::lawCovMatrix | ( | ) | const |
Returns the covariance matrix; access to protected attribute m_lawCovMatrix.
Definition at line 245 of file InvLogitGaussianJointPdf.C.
Referenced by QUESO::MetropolisHastingsSG< P_V, P_M >::alpha(), and QUESO::TransformedScaledCovMatrixTKGroup< V, M >::setPreComputingPosition().
const V & QUESO::InvLogitGaussianJointPdf< V, M >::lawExpVector | ( | ) | const |
Access to the vector of mean values of the Gaussian (not transformed) and private attribute: m_lawExpVector.
Definition at line 77 of file InvLogitGaussianJointPdf.C.
Referenced by QUESO::MetropolisHastingsSG< P_V, P_M >::alpha().
const V & QUESO::InvLogitGaussianJointPdf< V, M >::lawVarVector | ( | ) | const |
Access to the vector of variance values and private attribute: m_lawVarVector.
Definition at line 84 of file InvLogitGaussianJointPdf.C.
Referenced by QUESO::MetropolisHastingsSG< P_V, P_M >::alpha().
|
virtual |
Logarithm of the value of the (transformed) Gaussian PDF (scalar function).
The ln(value) comes from a summation of the Gaussian density:
where the may recovered via this->lawVarVector()
, in case of diagonal matrices or via this->m_lawCovMatrix
, otherwise.
Implements QUESO::BaseJointPdf< V, M >.
Definition at line 107 of file InvLogitGaussianJointPdf.C.
void QUESO::InvLogitGaussianJointPdf< V, M >::updateLawCovMatrix | ( | const M & | newLawCovMatrix | ) |
Updates the lower triangular matrix from Cholesky decomposition of the covariance matrix to the new value newLowerCholLawCovMatrix
.
This method deletes old expected values (allocated at construction or last call to this method).
Definition at line 236 of file InvLogitGaussianJointPdf.C.
void QUESO::InvLogitGaussianJointPdf< V, M >::updateLawExpVector | ( | const V & | newLawExpVector | ) |
Updates the mean of the Gaussian (not transformed) with the new value newLawExpVector
.
This method deletes old expected values (allocated at construction or last call to this method).
Definition at line 227 of file InvLogitGaussianJointPdf.C.
|
private |
Definition at line 150 of file InvLogitGaussianJointPdf.h.
|
private |
Definition at line 153 of file InvLogitGaussianJointPdf.h.
|
private |
Definition at line 151 of file InvLogitGaussianJointPdf.h.
|
private |
Definition at line 148 of file InvLogitGaussianJointPdf.h.
|
private |
Definition at line 149 of file InvLogitGaussianJointPdf.h.