# this precision file obtained as follows:
# - computing adiabatic scalar unlensed ClT only (ndf15 integrator with AMD)
# - for each precision parameter varied individually, Deltachi2(Planck) between high-precision limit and selected value = 1.e-3  

a_ini_over_a_today_default = 1.e-14
back_integration_stepsize = 7.e-3
tol_background_integration = 1.e-2
tol_ncdm_bg = 1.e-5

recfast_z_initial=1.e4

recfast_Nz0=10000
tol_thermo_integration=1.e-2

recfast_Heswitch=6
recfast_fudge_He=0.86

recfast_Hswitch = 1 #_TRUE_
recfast_fudge_H = 1.14
recfast_delta_fudge_H = -0.035
recfast_AGauss1 = -0.14
recfast_AGauss2 =  0.05
recfast_zGauss1 =  7.28
recfast_zGauss2 =  6.75
recfast_wGauss1 =  0.18
recfast_wGauss2 =  0.33

recfast_z_He_1 = 8000.
recfast_delta_z_He_1 = 50.
recfast_z_He_2 = 5000.
recfast_delta_z_He_2 = 100.
recfast_z_He_3 = 3500.
recfast_delta_z_He_3 = 50.
recfast_x_He0_trigger = 0.995
recfast_x_He0_trigger2 = 0.995
recfast_x_He0_trigger_delta = 0.01
recfast_x_H0_trigger = 0.995
recfast_x_H0_trigger2 = 0.995
recfast_x_H0_trigger_delta = 0.01

recfast_H_frac=1.e-3

reionization_z_start_max = 50.
reionization_sampling=1.e-2
reionization_optical_depth_tol=1.e-2
reionization_start_factor=8.

thermo_rate_smoothing_radius=50

k_scalar_min_tau0=3. # 2 for 0.1
k_scalar_max_tau0_over_l_max=1.2
k_scalar_step_sub=0.1
k_scalar_step_super=0.0025 #
k_scalar_step_transition=0.2 # was 0.2

k_tensor_min_tau0=1.4
k_tensor_max_tau0_over_l_max=2.
k_tensor_step_sub=0.05
k_tensor_step_super=0.0025
k_tensor_step_transition=0.2

start_small_k_at_tau_c_over_tau_h = 0.0015
start_large_k_at_tau_h_over_tau_k = 0.07
tight_coupling_trigger_tau_c_over_tau_h=0.015
tight_coupling_trigger_tau_c_over_tau_k=0.09
start_sources_at_tau_c_over_tau_h = 0.01
tight_coupling_approximation=5 #(int)second_order_CRS;

l_max_g=10
l_max_pol_g=6
l_max_ur=12
l_max_ncdm=6
l_max_g_ten=20
l_max_pol_g_ten=20

tol_tau_approx=1.e-3
tol_perturb_integration=5.e-4 #1.e-2 for evolver rk (0)
perturb_sampling_stepsize=0.2 # much more for 0.1

radiation_streaming_approximation = 2
radiation_streaming_trigger_tau_over_tau_k = 30.
radiation_streaming_trigger_tau_c_over_tau = 2.

ur_fluid_approximation = 2
ur_fluid_trigger_tau_over_tau_k = 15.

ncdm_fluid_approximation = 2
ncdm_fluid_trigger_tau_over_tau_k = 12.

tol_ncdm = 1.e-2

l_logstep=1.3
l_linstep=50

bessel_x_step=0.8
bessel_j_cut=1.e-5
bessel_tol_x_min =1.e-4
bessel_file_name=bessel.dat

k_per_decade_primordial = 10.
  
k_step_trans_scalars=0.0045 #can be 0.004 for chi2=0.1 and 1, not higher
k_step_trans_tensors=0.004

transfer_cut=1 #0=none,1=osc,2=cl #segfault with zero, watch it!
transfer_cut_threshold_osc=0.01 # 6 for 0.1, 8 for 1
transfer_cut_threshold_cl=1.e-8 # not robust if tilted or if one Delta_l(k) oscillation tangents zero

evolver=1

l_switch_limber = 40.
accurate_lensing=0
num_mu_minus_lmax = -50
delta_l_max = 50 #250 should be enough for 0.1
