mirror of
https://bitbucket.org/cosmicvoids/vide_public.git
synced 2025-07-05 07:41:11 +00:00
Merge branch 'master' of /home/guilhem/Dropbox/gitRoot/zobovPerso
This commit is contained in:
commit
8477cecbee
1 changed files with 4 additions and 4 deletions
|
@ -76,7 +76,7 @@ struct TotalExpansion
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
Interpolate make_cosmological_redshift(double OM, double OL, double z0, double z1)
|
Interpolate make_cosmological_redshift(double OM, double OL, double z0, double z1, int N = 1000)
|
||||||
{
|
{
|
||||||
TotalExpansion e_computer;
|
TotalExpansion e_computer;
|
||||||
double D_tilde, Q, Qprime;
|
double D_tilde, Q, Qprime;
|
||||||
|
@ -85,12 +85,12 @@ Interpolate make_cosmological_redshift(double OM, double OL, double z0, double z
|
||||||
e_computer.Omega_M = OM;
|
e_computer.Omega_M = OM;
|
||||||
e_computer.Omega_L = OL;
|
e_computer.Omega_L = OL;
|
||||||
|
|
||||||
pairs.resize(100);
|
pairs.resize(N);
|
||||||
ofstream f("comoving_distance.txt");
|
ofstream f("comoving_distance.txt");
|
||||||
|
|
||||||
for (int i = 0; i < 100; i++)
|
for (int i = 0; i < N; i++)
|
||||||
{
|
{
|
||||||
double z = z0 + (z1-z0)/100*i;
|
double z = z0 + (z1-z0)/N*i;
|
||||||
|
|
||||||
pairs[i].second = z;
|
pairs[i].second = z;
|
||||||
pairs[i].first = gslIntegrate(e_computer, 0, z, 1e-3);
|
pairs[i].first = gslIntegrate(e_computer, 0, z, 1e-3);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue