Hyperiso 1.0.3
Modular flavour-physics calculations, Wilson coefficients and statistical inference
Loading...
Searching...
No Matches
GaussianCopula.h
Go to the documentation of this file.
1#ifndef GAUSSIANCOPULA_H
2#define GAUSSIANCOPULA_H
3
4#include "ICopula.h"
5#include "GenericCopula.h"
6#include "Matrix.h"
7#include "AbstractConfig.h"
8
41
63class GaussianCopula final : public GenericCopula {
64public:
74 explicit GaussianCopula(unsigned int seed, RealMatrix R);
75
79 std::vector<Vector> sample_u(std::size_t n) override;
80
84 Vector sample_u() override;
85
97 double log_density(Vector u) override;
98
105 RealMatrix dlog_density(std::vector<double> u) override;
106
113 RealMatrix ddlog_density(std::vector<double> u) override;
114
124 LogDensityDiff log_c_dc_ddc(std::vector<double> u) override;
125
126
127private:
128
129 RealMatrix R;
130 RealMatrix R_inv;
131 RealMatrix L;
132 double logdet;
133};
134
135#endif // GAUSSIANCOPULA_H
Base type for lightweight configuration structures.
Base class providing RNG infrastructure for concrete copulas.
Abstract interface for multivariate copulas.
Lightweight dense real-matrix utilities built on top of STL storage and GSL backends.
Gaussian copula based on a correlation matrix.
Vector sample_u() override
Draws a single sample from the copula.
LogDensityDiff log_c_dc_ddc(std::vector< double > u) override
Computes the log-density and its first and second derivatives.
double log_density(Vector u) override
Evaluates the log-density of the copula at a point in the unit cube.
RealMatrix ddlog_density(std::vector< double > u) override
Computes the Hessian of the Gaussian copula log-density.
RealMatrix dlog_density(std::vector< double > u) override
Computes the gradient of the Gaussian copula log-density.
Partial base implementation of a copula with RNG support.
std::vector< double > Vector
Polymorphic base class for configuration types.
Configuration object for a Gaussian copula.