Open kgage opened 8 years ago
It would be possible to change the output of the calculate_power function to allow for calculations of the power spectrum at multiple redshifts. In theory, a dictionary with keys of 'k', num_1, num_2, ... num_n should work. Is this something that should be looked into?
Let's fix the existing bug now and keep the multiple-redshift option in mind as a possible future feature (unless there is a reason why we need it now?)
Currently, when attempting to get the power spectrum at a redshift other than z=0 raises a CosmoSevereError such as
CLASS (and therefore classy) has a parameter z_pk that gives the redshifts where the mass power spectrum should be calculated. The calculate_power function in cosmotools.py does not include a line to override the default value of zero if the redshift asked for is nonzero.
This can be fixed by including
in the function definition.
For future reference, the z_pk variable will accept multiple redshift values as a string of comma separated numbers: