|
Hyperiso 1.0.3
Modular flavour-physics calculations, Wilson coefficients and statistical inference
|
#include "MCEngine.h"#include "StatisticProgress.h"#include "ParameterRuntimeContext.h"#include <algorithm>#include <atomic>#include <exception>#include <fstream>#include <iomanip>#include <limits>#include <mutex>#include <sstream>#include <thread>
Go to the source code of this file.
Functions | |
| RealMatrix | symmetrize_covariance_matrix2 (RealMatrix cov) |
| RealMatrix | inverse_covariance_with_ridge2 (RealMatrix cov, double ridge_rel, double ridge_abs) |
| MCObservableCovariance | covariance_from_obs_samples (const ObsSamples &S, const std::vector< BinnedObservableId > &ids, double ridge_rel, double ridge_abs) |
| Builds a regularized empirical covariance matrix from observable samples. | |
| std::vector< BinnedObservableId > | covariance_ids_from_first_sample (const ObsSamples &S) |
| Extracts the observable ordering from the first Monte Carlo sample. | |
| MCObservableCovariance covariance_from_obs_samples | ( | const ObsSamples & | S, |
| const std::vector< BinnedObservableId > & | ids, | ||
| double | ridge_rel = 1e-8, |
||
| double | ridge_abs = 1e-12 |
||
| ) |
Builds a regularized empirical covariance matrix from observable samples.
The samples are read in the order specified by ids. The empirical covariance is converted to a dimensionless correlation matrix, a ridge of max(ridge_rel, ridge_abs) is added to its diagonal, and the inverse is transformed back to covariance units. The returned covariance itself remains the raw empirical estimate.
| S | Monte Carlo observable samples. |
| ids | Observable identifiers defining the covariance ordering. |
| ridge_rel | Relative ridge factor. |
| ridge_abs | Minimum dimensionless ridge floor. |
| std::invalid_argument | if the sample set is empty, if ids is empty, or if fewer than two samples are provided. |
Definition at line 102 of file MCEngine.cpp.
| std::vector< BinnedObservableId > covariance_ids_from_first_sample | ( | const ObsSamples & | S | ) |
Extracts the observable ordering from the first Monte Carlo sample.
| S | Monte Carlo observable samples. |
| std::invalid_argument | if S is empty. |
Definition at line 164 of file MCEngine.cpp.
| RealMatrix inverse_covariance_with_ridge2 | ( | RealMatrix | cov, |
| double | ridge_rel, | ||
| double | ridge_abs | ||
| ) |
Definition at line 43 of file MCEngine.cpp.
| RealMatrix symmetrize_covariance_matrix2 | ( | RealMatrix | cov | ) |
Definition at line 15 of file MCEngine.cpp.