CAMB: halofit matter power spectrum derivative

Use of Healpix, camb, CLASS, cosmomc, compilers, etc.
Post Reply
Matthew Digman
Posts: 7
Joined: February 03 2017
Affiliation: The Ohio State University

CAMB: halofit matter power spectrum derivative

Post by Matthew Digman » September 29 2017

Hey,
I was running a test involving python camb 0.1.6.1's Takahashi halofit matter power spectrum, and I notice that there is a large spike around kh=0.005 h Mpc−1 in the second derivative of the matter power spectrum with respect to k, shown here: Image

I assume the spike itself is because the implementation of halofit switches to using the linear power spectrum for kh below Min_kh_nonlinear = 0.005, which creates a discontinuity, but I would not expect that to produce an extended feature like this, unless something is smoothing it out. Is camb applying a smoothing to the halofit output, or is this feature something else?

Antony Lewis
Posts: 1353
Joined: September 23 2004
Affiliation: University of Sussex
Contact:

Re: CAMB: halofit matter power spectrum derivative

Post by Antony Lewis » September 29 2017

It depends on what function you are using. You can either get the raw k sampling, or a spline object which does bicubic spline interpolation on P(k,z) over the sampled points. The raw k sampling may not be very fine by default.

Matthew Digman
Posts: 7
Joined: February 03 2017
Affiliation: The Ohio State University

CAMB: halofit matter power spectrum derivative

Post by Matthew Digman » September 29 2017

Ok, I see that increasing set_accuracy does decrease the width of the spike, as expected. Thanks!

Antony Lewis
Posts: 1353
Joined: September 23 2004
Affiliation: University of Sussex
Contact:

Re: CAMB: halofit matter power spectrum derivative

Post by Antony Lewis » September 29 2017

You can change just the k sampling by setting kper_logint using set_matter_power.

Matthew Digman
Posts: 7
Joined: February 03 2017
Affiliation: The Ohio State University

CAMB: halofit matter power spectrum derivative

Post by Matthew Digman » September 30 2017

Oh, awesome. I hadn't realized that was different from setting npoints.

Post Reply