## Help with CAMB

Use of Cobaya. camb, CLASS, cosmomc, compilers, etc.
Clara Rojas
Posts: 30
Joined: May 11 2005
Affiliation: Yachay TECH University

### Help with CAMB

Dear Antony,

I hope this message finds you well.

I was trying to perform some calculations with CAMB by introducing a variation of the 𝑁_eff parameter (ΔNeff). In the "Neutrinos and Dark Radiation" sections, specifically subsection 3 of the CAMB notes under "further examples," there are instructions in the last paragraph:

Consider 2 massless active and 1 massive active neutrino all at the standard temperature (3.046/3)1/4Tν, where the massive active neutrino has mi = 0.06eV and hence contributes Ωaνh^2 = 0.00064. If there is also one sterile (at a different temperature) contributing ∆Neff to the total so that Neff = 3.046 + ∆Neff, and the total density parameter Ωνh^2 = 0.00064 + Ωsνh^2, then use: share delta neff = F, massless neutrinos = 2.0307, nu mass eigenstates = 2, massive neutrinos = 1 1, nu mass degeneracies = 1.0153 ∆Neff, nu mass fractions = X Y where X =0.00064/Ωνh^2 and Y = Ωsνh^2/Ωνh^2.

However, I am unsure how to incorporate the density parameters specified there, and also the way that massive neutrinos have to be written (massive neutrinos = 1 1), are those 1 separate by spacing? Because in this format the code give us an error (it could be because we choose arbitrary values for the density parameters as well).

My aim is to achieve something similar to what is done in this paper: https://arxiv.org/pdf/1606.09199.

Best regards,
Clara
Antony Lewis
Posts: 1970
Joined: September 23 2004
Affiliation: University of Sussex
Contact:

### Re: Help with CAMB

From python,

Code: Select all

nu_mass_numbers 
etc can just be assigned as lists or numpy arrays. You set the

Code: Select all

nu_mass_fractions
to determine how $\Omega_\nu h^2$ is divided between eigenstates.
Clara Rojas
Posts: 30
Joined: May 11 2005
Affiliation: Yachay TECH University

### Re: Help with CAMB

Dear Antony,

Best regards,
Clara
Clara Rojas
Posts: 30
Joined: May 11 2005
Affiliation: Yachay TECH University

### Re: Help with CAMB

Dear Antony,

I hope that you are well.

We have tried running CAMB using your suggestions to set massive_neutrinos and nu_mass_fractions as a list and as an array.
We use, for example:

massive_neutrinos = [1,1]
massive_neutrinos = np.array([1,1]).

The same notation for mass_fractions.

We obtained the following error:

At line 443 of file ../camb.f90
Fortran runtime error: Bad real number in item 1 of list input

Thanks and Best Regards,
Clara
Clara Rojas
Posts: 30
Joined: May 11 2005
Affiliation: Yachay TECH University

### Re: Help with CAMB

Dear Antony,

Thank you for your time. The code is running now. We had another mistake.

Thanks very much,
Clara
Clara Rojas
Posts: 30
Joined: May 11 2005
Affiliation: Yachay TECH University

### Re: Help with CAMB

Dear Antony,

Hello again!

Here's how we have configured the .ini file:

#number of distinct mass eigenstates
nu_mass_eigenstates = 2
#array of the integer number of physical neutrinos per eigenstate, e.g. massive_neutrinos = 2 1
massive_neutrinos = 1 1
#specify whether all neutrinos should have the same temperature, specified from fractional part of massless_neutrinos
share_delta_neff = F
#nu_mass_fractions specifies how Omeganu_h2 is shared between the eigenstates
#i.e. to indirectly specify the mass of each state; e.g. nu_mass_factions= 0.75 0.25
nu_mass_fractions = 0.5 0.5
#if share_delta_neff = F, specify explicitly the degeneracy for each state (e.g. for sterile with different temperature to active)
#(massless_neutrinos must be set to degeneracy for massless, i.e. massless_neutrinos does then not include Deleta_Neff from massive)
#if share_delta_neff=T then degeneracies is not given and set internally
#e.g. for massive_neutrinos = 2 1, this gives equal temperature to 4 neutrinos: nu_mass_degeneracies = 2.030 1.015, massless_neutrinos = 1.015
nu_mass_degeneracies = 0.0153 0.451

And when the CAMB is running we obtain the following error message, and the test_files do not generates:

Error in dverk, x = 4.7527141126152139E-003 xend= 208.53669368419270
Error in dverk, x = 4.7527141126152139E-003 xend= 209.18630913179797
Error in dverk, x = 4.7527141126152139E-003 xend= 209.83592457940327
Error in dverk, x = 4.7527141126152139E-003 xend= 210.48554002700854
Error in dverk, x = 4.7527141126152139E-003 xend= 211.13515547461381
Error in dverk, x = 4.7527141126152139E-003 xend= 211.78477092221908
Error in dverk, x = 4.7527141126152139E-003 xend= 212.43438636982435
Error in dverk, x = 4.7527141126152139E-003 xend= 213.08400181742965
Error in dverk, x = 4.7527141126152139E-003 xend= 213.73361726503492
Error in dverk, x = 4.7527141126152139E-003 xend= 214.38323271264019
Error in dverk, x = 4.7527141126152139E-003 xend= 215.03284816024546

Please, can you tell us what is the error in our .ini file?

Thanks and best regards,
Clara
Antony Lewis
Posts: 1970
Joined: September 23 2004
Affiliation: University of Sussex
Contact:

### Re: Help with CAMB

Not necessarily an error in the settings, likely something to do with the rather different physics of the very low degeneracy eigenstate with high mass. You can try turning off approximations, increasing accuracy, and plotting mode evolution to get a handle on what's going on.
Clara Rojas
Posts: 30
Joined: May 11 2005
Affiliation: Yachay TECH University

### Re: Help with CAMB

Hi Antony,

Thanks very much for your suggestion, the problem was solved.

Best Regards,
Clara