CMP++: Uncertainty Quantification & Bayesian Calibration
Loading...
Searching...
No Matches
cmp::prior Namespace Reference

Classes

class  FromDistribution
 Adapts a univariate probability distribution to act as a prior on a single coordinate. More...
 
class  Prior
 Base class for prior probability distributions. More...
 
class  Product
 Represents the product (sum of logs) of two independent prior distributions. More...
 
class  Uniform
 Represents an improper flat (uniform) prior. More...
 

Functions

template<typename DistType >
std::shared_ptr< Priormake (const DistType &dist, size_t paramIndex)
 Helper template function to create a FromDistribution prior.
 
std::shared_ptr< Prioroperator* (std::shared_ptr< Prior > p1, std::shared_ptr< Prior > p2)
 Multiplies two prior distributions (returns a Product prior).
 

Function Documentation

◆ make()

template<typename DistType >
std::shared_ptr< Prior > cmp::prior::make ( const DistType &  dist,
size_t  paramIndex 
)

Helper template function to create a FromDistribution prior.

Template Parameters
DistTypeThe type of the univariate distribution.
Parameters
distThe distribution.
paramIndexThe index of the parameter coordinate.
Returns
Shared pointer to the created Prior.

◆ operator*()

std::shared_ptr< cmp::prior::Prior > cmp::prior::operator* ( std::shared_ptr< Prior p1,
std::shared_ptr< Prior p2 
)

Multiplies two prior distributions (returns a Product prior).

Parameters
p1First prior distribution.
p2Second prior distribution.
Returns
Shared pointer to the Product prior.