Closed rgspo closed 5 years ago
Hi,
I cannot exactly tell what you are doing without your python code but looking at the documentation of np.gradient I think the numpy function (by default) just takes the derivative with respect to the index and not 'time' or anything.
Did you check that you are passing the correct 'x' value (i.e. time / conformal time) to np.gradient?
Cheers, Stefan
Hi Stefan,
Thank you for your answer. It was exactly what you said, the spacing of my values was not exact. Now, it looks much better.
Cheers, Rafaela
Hi,
I plotted H and H_prime in classy and compared H_prime with the numpy.gradient() function. Qualitatively, both derivatives look the same but there is a huge discrepancy in the order of magnitude (1e20 <-> 1e31) .
H_analytic_derivatives.pdf
Since H_prime is calculated in conformal time and H in physical time, I thought a rescaling with 1/a would fix the problem. But it just made it worse.
Has anyone else encountered the same problem and can help me with it?
Thank you, Rafaela