CosmoBolognaLib
Free Software C++/Python libraries for cosmological calculations
PosteriorDistribution.h
Go to the documentation of this file.
1 /********************************************************************
2  * Copyright (C) 2014 by Federico Marulli and Alfonso Veropalumbo *
3  * federico.marulli3@unibo.it *
4  * *
5  * This program is free software; you can redistribute it and/or *
6  * modify it under the terms of the GNU General Public License as *
7  * published by the Free Software Foundation; either version 2 of *
8  * the License, or (at your option) any later version. *
9  * *
10  * This program is distributed in the hope that it will be useful, *
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of *
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
13  * GNU General Public License for more details. *
14  * *
15  * You should have received a copy of the GNU General Public *
16  * License along with this program; if not, write to the Free *
17  * Software Foundation, Inc., *
18  * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
19  ********************************************************************/
20 
33 #ifndef __POSTERIORDIST__
34 #define __POSTERIORDIST__
35 
36 #include "Distribution.h"
37 
38 
39 // ===================================================================================================
40 
41 
42 namespace cbl {
43 
44  namespace statistics {
45 
54 
55  public:
56 
61 
68 
78  PosteriorDistribution (const glob::DistributionType posteriorType, const double value) : Distribution(posteriorType, value) {}
79 
93  PosteriorDistribution (const glob::DistributionType distributionType, const std::vector<double> discrete_values, const std::vector<double> weights, const int seed=1) : Distribution(distributionType, discrete_values, weights, seed) {}
94 
112  PosteriorDistribution (const glob::DistributionType distributionType, const std::vector<double> var, const std::vector<double> dist, const int nbin, const std::string interpolationType, const int seed=1) : Distribution(distributionType, var, dist, nbin, interpolationType, seed) {}
113 
120 
122 
123  };
124  }
125 }
126 
127 #endif
The class Distribution.
The class CombinedDistribution.
Definition: Distribution.h:124
DistributionType distributionType() const
return the distribution type
Definition: Distribution.h:316
Distribution()
default constructor
Definition: Distribution.h:215
The class PosteriorDistribution.
~PosteriorDistribution()=default
default destructor
PosteriorDistribution(const glob::DistributionType distributionType, const std::vector< double > discrete_values, const std::vector< double > weights, const int seed=1)
constructor
PosteriorDistribution(const glob::DistributionType posteriorType, const double value)
constructor of a constant distribution
PosteriorDistribution(const glob::DistributionType distributionType, const std::vector< double > var, const std::vector< double > dist, const int nbin, const std::string interpolationType, const int seed=1)
constructor
DistributionType
the distribution type
Definition: Distribution.h:51
The global namespace of the CosmoBolognaLib
Definition: CAMB.h:38