added BAO wiggles

This commit is contained in:
Eleni 2022-12-01 17:03:02 +01:00
parent e2a2c7287c
commit cd926a0834
2 changed files with 26 additions and 1 deletions

View File

@ -212,6 +212,26 @@ double CosmoPower::powerHuWiggles(double k)
return normPower * pow(k,n) * T_k * T_k;
}
double CosmoPower::sample_BAO(double k)
{
// BAO wiggle parameterization for reconstruction
// Babic et al. 2022, https://arxiv.org/abs/2203.06177
// No-wiggle transfer function
double ps_no_wiggle = powerHuBaryons(k);
// Wiggle parameterization
double A = 0;
double r_s = 10;
double k_D = 2 * M_PI / 100;
double param = 1 + A * sin(k * r_s) * exp(- k / k_D);
return ps_no_wiggle * param;
}
double CosmoPower::primordialPowerSpectrum(double k)
{
//Primordial power spectrum, needed for PNG
@ -444,6 +464,9 @@ void CosmoPower::setFunction(CosmoFunction f)
case POWER_SUGIYAMA:
eval = &CosmoPower::powerSugiyama;
break;
case SAMPLE_WIGGLES:
eval = &CosmoPower::sample_BAO;
break;
case POWER_BDM:
eval = &CosmoPower::powerBDM;
break;

View File

@ -89,7 +89,8 @@ namespace CosmoTool {
POWER_SUGIYAMA,
POWER_BDM,
POWER_TEST,
HU_WIGGLES_ORIGINAL
HU_WIGGLES_ORIGINAL,
SAMPLE_WIGGLES
};
CosmoPower();
@ -122,6 +123,7 @@ namespace CosmoTool {
double powerBDM(double k);
double powerTest(double k);
double powerHuWigglesOriginal(double k);
double sample_BAO(double k);
};
};