mirror of
https://bitbucket.org/cosmicvoids/vide_public.git
synced 2025-07-07 08:41:11 +00:00
Updated again cosmotoolbox
This commit is contained in:
parent
e41c26a46c
commit
e44d51442d
14 changed files with 195 additions and 332 deletions
16
external/cosmotool/src/powerSpectrum.cpp
vendored
16
external/cosmotool/src/powerSpectrum.cpp
vendored
|
@ -1,3 +1,4 @@
|
|||
#include <cassert>
|
||||
#include <vector>
|
||||
#include <algorithm>
|
||||
#include <iostream>
|
||||
|
@ -21,7 +22,7 @@ using namespace std;
|
|||
#define POWER_BDM 7
|
||||
#define POWER_TEST 8
|
||||
|
||||
#define POWER_SPECTRUM HU_WIGGLES
|
||||
#define POWER_SPECTRUM POWER_EFSTATHIOU
|
||||
|
||||
namespace Cosmology {
|
||||
|
||||
|
@ -651,4 +652,17 @@ double computeCorrel2(double powNorm, double topHatRad1, double topHatRad2)
|
|||
#endif
|
||||
}
|
||||
|
||||
double vvCorrection(double P_deltadelta, double k)
|
||||
{
|
||||
static const double alpha0 = -12480.5, alpha1 = 1.824, alpha2 = 2165.87, alpha3=1.796;
|
||||
if (k > 0.3)
|
||||
return 0;
|
||||
double r =(alpha0*sqrt(P_deltadelta) + alpha1*P_deltadelta*P_deltadelta)/(alpha2 + alpha3*P_deltadelta);
|
||||
assert(P_deltadelta > 0);
|
||||
|
||||
if (r < 0)
|
||||
return 0;
|
||||
return r;
|
||||
}
|
||||
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue