46 using namespace measure;
47 using namespace measure::threept;
48 using namespace modelling;
49 using namespace measure::threept;
57 if (threept->threePType()==measure::threept::ThreePType::_angular_connected_)
60 else if (threept->threePType()==measure::threept::ThreePType::_angular_reduced_)
63 else if (threept->threePType()==measure::threept::ThreePType::_comoving_connected_)
66 else if (threept->threePType()==measure::threept::ThreePType::_comoving_reduced_)
69 else ErrorCBL(
"no such type of object, or error in the input parameters!",
"Create",
"Modelling_ThreePointCorrelation.cpp");
80 if (threePType==measure::threept::ThreePType::_angular_connected_)
83 else if (threePType==measure::threept::ThreePType::_angular_reduced_)
86 else if (threePType==measure::threept::ThreePType::_comoving_connected_)
89 else if (threePType==measure::threept::ThreePType::_comoving_reduced_)
92 else ErrorCBL(
"no such type of object, or error in the input parameters!",
"Create",
"Modelling_ThreePointCorrelation.cpp");
102 m_data_model.Q_DM = Q_DM;
111 m_data_model.cosmology = make_shared<cosmology::Cosmology>(cosmology);
112 m_data_model.r1 = r1;
113 m_data_model.r2 = r2;
114 m_data_model.theta = theta;
115 m_data_model.model = model;
116 m_data_model.kk = kk;
117 m_data_model.Pk_matter = Pk_matter;
124 void cbl::modelling::threept::Modelling_ThreePointCorrelation::set_data_model_zeta_RSD (
const double r1,
const double r2,
const cosmology::Cosmology cosmology,
const double redshift,
const string method_Pk,
const bool NL,
const int max_ll,
const double k_min,
const double k_max,
const int step_k,
const double r_min,
const double r_max,
const int step_r,
const bool force_realSpace,
const bool use_k,
const bool store_output,
const string output_root,
const int norm,
const double prec)
126 m_data_model.cosmology = make_shared<cosmology::Cosmology>(cosmology);
128 m_data_model.r1 = r1;
129 m_data_model.r2 = r2;
130 m_data_model.redshift = redshift;
131 m_data_model.method_Pk = method_Pk;
132 m_data_model.NL = NL;
133 m_data_model.k_min = k_min;
134 m_data_model.k_max = k_max;
135 m_data_model.step_k = step_k;
137 m_data_model.r_min = r_min;
138 m_data_model.r_max = r_max;
139 m_data_model.step_r = step_r;
140 m_data_model.rr =
linear_bin_vector(m_data_model.step_r, m_data_model.r_min, m_data_model.r_max);
141 m_data_model.store_output = store_output;
142 m_data_model.output_root = output_root;
143 m_data_model.norm = norm;
144 m_data_model.prec = prec;
145 m_data_model.force_realSpace = force_realSpace;
146 m_data_model.max_ll = max_ll;
147 m_data_model.use_k = use_k;
151 m_data_model.sigma8_z = m_data_model.cosmology->sigma8(m_data_model.redshift);
154 coutCBL <<
"sigma8 is not set, computing from the power spectrum, method_Pk = "+m_data_model.method_Pk << endl;
155 m_data_model.sigma8_z = m_data_model.cosmology->sigma8_Pk(m_data_model.method_Pk, m_data_model.redshift, m_data_model.store_output, m_data_model.output_root);
157 m_data_model.linear_growth_rate_z = m_data_model.cosmology->linear_growth_rate(m_data_model.redshift, 1.);
159 m_data_model.Pk_matter = m_data_model.cosmology->Pk_matter(m_data_model.kk, m_data_model.method_Pk, m_data_model.NL, m_data_model.redshift, m_data_model.store_output, m_data_model.output_root, m_data_model.norm, m_data_model.k_min, m_data_model.k_max, m_data_model.prec);
#define coutCBL
CBL print message.
The class Modelling_ThreePointCorrelation.
The class Modelling_ThreePointCorrelation_angular_connected.
The class Modelling_ThreePointCorrelation_angular_reduced.
The class Modelling_ThreePointCorrelation_comoving_connected.
The class Modelling_ThreePointCorrelation_comoving_reduced.
The class Modelling_ThreePointCorrelation_angular_connected.
The class Modelling_ThreePointCorrelation_angular_reduced.
The class Modelling_ThreePointCorrelation_comoving_connected.
The class Modelling_ThreePointCorrelation_comoving_reduced.
void set_data_model_zeta_RSD(const double r1, const double r2, const cbl::cosmology::Cosmology cosmology, const double redshift, const std::string method_Pk="CAMB", const bool NL=false, const int max_ll=5, const double k_min=1.e-4, const double k_max=100, const int step_k=500, const double r_min=1.e-4, const double r_max=200, const int step_r=200, const bool force_realSpace=false, const bool use_k=false, const bool store_output=true, const std::string output_root=cbl::par::defaultString, const int norm=-1, const double prec=1.e-4)
set the data model for the three-point correlation function (see Slepian, Eisenstein 2017)
static std::shared_ptr< Modelling_ThreePointCorrelation > Create(const std::shared_ptr< measure::threept::ThreePointCorrelation > threep)
static factory used to construct modelling of three-point correlation functions of any type
void set_data_model(const std::vector< double > Q_DM)
set the data model for the three-point correlation function
void set_data_Q_nonlocal(const cosmology::Cosmology cosmology, const double r1, const double r2, const std::vector< double > theta, const std::string model, const std::vector< double > kk, const std::vector< double > Pk_matter)
set the data model for the three-point correlation function with non-local contributions
ThreePType
the three-point correlation function type
The global namespace of the CosmoBolognaLib
std::vector< T > logarithmic_bin_vector(const size_t nn, const T min, const T max)
fill a std::vector with logarithmically spaced values
std::vector< T > linear_bin_vector(const size_t nn, const T min, const T max)
fill a std::vector with linearly spaced values
int ErrorCBL(const std::string msg, const std::string functionCBL, const std::string fileCBL, const cbl::glob::ExitCode exitCode=cbl::glob::ExitCode::_error_)
throw an exception: it is used for handling exceptions inside the CosmoBolognaLib