CAMB - Plotting density constrast
-
- Posts: 28
- Joined: July 18 2013
- Affiliation: University of Oslo
CAMB - Plotting density constrast
Hey.
I would like to plot the density contrast of neutrinos as a function of time/redshift/scale factor.
However, when I am in puting the quantities grho/dgrho, where grho = a^2 kappa rho and dgrho = a^2 kappa \delta\rho, in MassiveNuVarsOut, or MassiveNuVars, or even directly from the integration in Nu_Integrate_L012, do I get that it jumps around in the scale factor. It even outputs the same scale factor with different number? Why is this, and how does then this actually works? Is it because of some numerical scheme to make it go faster, or do one spline the values? Or is it just that the "integration" is not done and one get several numbers for the density contrast at the same scale factor?
I have tried to go backwards and it seems that it jumps around (meaning not in chronological order) even in cmbmain.f90 in DoSourcek.
Could anyone explain why CAMB act this way? And more importantly, how can I plot the density contrast of the neutrinos, or any of the other components like baryons, dark matter? Is there an intrinsic function that will do this for me, or a flag?
Thanks in advanced for any help or clarifying of this problem.
Sincerly,
Paul
I would like to plot the density contrast of neutrinos as a function of time/redshift/scale factor.
However, when I am in puting the quantities grho/dgrho, where grho = a^2 kappa rho and dgrho = a^2 kappa \delta\rho, in MassiveNuVarsOut, or MassiveNuVars, or even directly from the integration in Nu_Integrate_L012, do I get that it jumps around in the scale factor. It even outputs the same scale factor with different number? Why is this, and how does then this actually works? Is it because of some numerical scheme to make it go faster, or do one spline the values? Or is it just that the "integration" is not done and one get several numbers for the density contrast at the same scale factor?
I have tried to go backwards and it seems that it jumps around (meaning not in chronological order) even in cmbmain.f90 in DoSourcek.
Could anyone explain why CAMB act this way? And more importantly, how can I plot the density contrast of the neutrinos, or any of the other components like baryons, dark matter? Is there an intrinsic function that will do this for me, or a flag?
Thanks in advanced for any help or clarifying of this problem.
Sincerly,
Paul
-
- Posts: 1943
- Joined: September 23 2004
- Affiliation: University of Sussex
- Contact:
Re: CAMB - Plotting density constrast
Use the fixq parameter, which sets the k value you want to output evolution for. e.g. look in cmbmain.f90 and modify the output code to put out what variables you want.
(you get jumps in Runge-Kutta integration because it is adaptive step size)
(you get jumps in Runge-Kutta integration because it is adaptive step size)
-
- Posts: 28
- Joined: July 18 2013
- Affiliation: University of Oslo
CAMB - Plotting density constrast
Hey again. And thank you very much Antony.
Just another question, what does the frixq parameter stand for, and how does this relates to the wavenumber k?
As I understand does the Example code for plotting out variable evolution with fixq only do the perturbation part, or does it give out the background aswell?
Paul
Just another question, what does the frixq parameter stand for, and how does this relates to the wavenumber k?
As I understand does the Example code for plotting out variable evolution with fixq only do the perturbation part, or does it give out the background aswell?
Paul
-
- Posts: 1943
- Joined: September 23 2004
- Affiliation: University of Sussex
- Contact:
Re: CAMB - Plotting density constrast
q is used instead of k in parts of the code (for non-flat models). You can write out whatever you like.
-
- Posts: 28
- Joined: July 18 2013
- Affiliation: University of Oslo
CAMB - Plotting density constrast
Hey again.
I don't know why, but I am getting an error creating the text file: Error creating file evolve_q005.txt when I want to do my independent plottings. However, have I no idea what might be wrong.
Paul
I don't know why, but I am getting an error creating the text file: Error creating file evolve_q005.txt when I want to do my independent plottings. However, have I no idea what might be wrong.
Paul
-
- Posts: 29
- Joined: June 10 2012
- Affiliation: University of Mexico
CAMB - Plotting density constrast
Dear Paul.
I had the same problem, but when I removed
-openmp
in the FLAGS of the Makefile, the problem was solved
Regards
I had the same problem, but when I removed
-openmp
in the FLAGS of the Makefile, the problem was solved
Regards