switched variable name useLCDM to less confusing useComoving; make it sample-level rather than dataset-level

This commit is contained in:
P.M. Sutter 2013-12-19 12:38:05 -06:00
parent 34a32bfd2c
commit f268820a2e
8 changed files with 25 additions and 26 deletions

View file

@ -115,7 +115,7 @@ void loadData(const string& fname, NYU_VData & data)
}
void generateGalaxiesInCube(NYU_VData& data, ParticleData& output_data,
bool useLCDM)
bool useComoving)
{
double d2r = M_PI/180;
@ -163,7 +163,7 @@ void generateGalaxiesInCube(NYU_VData& data, ParticleData& output_data,
double ra = data[i].ra*d2r, dec = data[i].dec*d2r;
Position& p = output_data.pos[i];
if (useLCDM) {
if (useComoving) {
//double pos = gsl_interp_eval(interp, redshifts, dL, data[i].cz, acc);
gsl_integration_qng(&expanF, 1.e-6, data[i].cz/LIGHT_SPEED,
1.e-6,
@ -587,7 +587,7 @@ int main(int argc, char **argv)
// We compute a cube holding all the galaxies + the survey surface mask
cout << "Placing galaxies..." << endl;
generateGalaxiesInCube(data, output_data, args_info.useLCDM_flag);
generateGalaxiesInCube(data, output_data, args_info.useComoving_flag);
generateSurfaceMask(args_info, mask, pixel_list, full_mask_list,
data, output_data);

View file

@ -14,4 +14,4 @@ option "zMax" - "Maximum redshift of data" double required
option "output" - "Filename of particle datafile" string required
option "params" - "Output parameters of the datacube" string required
option "useLCDM" - "Convert to real space using LCDM cosmology" flag off
option "useComoving" - "Convert to real space using LCDM cosmology" flag off

View file

@ -724,7 +724,7 @@ int main(int argc, char **argv) {
voids[iVoid].redshiftInMpc = voids[iVoid].redshiftInMpc;
if (args.useLCDM_flag) {
if (args.useComoving_flag) {
redshift = gsl_interp_eval(interp, dL, redshifts,
voids[iVoid].redshiftInMpc, acc);
//printf("HELLO %e %e\n", redshift, args.zMax_arg);

View file

@ -23,7 +23,7 @@ option "numVoids" - "Number of voids" int required
option "isObservation" - "We are working with observational data" flag off
option "useLCDM" - "Void positions are in comoving coordinates" flag off
option "useComoving" - "Void positions are in comoving coordinates" flag off
option "zMin" - "Minimum redshift of sample" double optional default="0.0"
option "zMax" - "Maximum redshift of sample" double optional default="10.0"