consistent handling of comoving coords in sims

This commit is contained in:
P.M. Sutter 2014-02-12 04:52:58 -06:00
parent ea8b92ea62
commit e5cc6297fa
5 changed files with 43 additions and 36 deletions

View file

@ -163,7 +163,7 @@ int main(int argc, char **argv) {
gsl_function expanF;
expanF.function = &expanFun;
struct my_expan_params expanParams;
expanParams.Om = 0.27;
expanParams.Om = args.omegaM_arg;
expanParams.w0 = -1.0;
expanParams.wa = 0.0;
expanF.params = &expanParams;
@ -741,7 +741,12 @@ int main(int argc, char **argv) {
} else {
voids[iVoid].redshiftInMpc = voids[iVoid].barycenter[2];
voids[iVoid].redshift = voids[iVoid].barycenter[2]/LIGHT_SPEED*100.;
if (args.useComoving_flag) {
voids[iVoid].redshift = gsl_interp_eval(interp, dL, redshifts,
voids[iVoid].redshiftInMpc, acc);
} else {
voids[iVoid].redshift = voids[iVoid].barycenter[2]/LIGHT_SPEED*100.;
}
nearestEdge = 1.e99;

View file

@ -25,6 +25,8 @@ option "isObservation" - "We are working with observational data" flag off
option "useComoving" - "Void positions are in comoving coordinates" flag off
option "omegaM" - "Omega_M for redshift convertion" double optional default="0.27"
option "zMin" - "Minimum redshift of sample" double optional default="0.0"
option "zMax" - "Maximum redshift of sample" double optional default="10.0"