21cmfast / 21cmFAST

Official repository for 21cmFAST: a code for generating fast simulations of the cosmological 21cm signal
MIT License
58 stars 37 forks source link

Imprecise numerical factor for Lyman-alpha coupling [BUG] #325

Closed jordanflitter closed 1 year ago

jordanflitter commented 1 year ago

Hello,

In SpinTemperatureBox.c, line 1485 says xa_tilde_prefactor = 1.66e11/(1.0+zp).

I believe that the numerical prefactor, 1.66e11, is imprecise and should be in fact 1.81e11. Let me explain. In Hirata's 2006 paper (astro-ph/0507102), the Lyman-alpha coupling coefficient is defined in Eq. (38). The CMB temperature in that expression results (1.+zp) in the denominator, while the rest of the expression (not including S_alpha nor J_alpha) should correspond to the numerical prefactor. However, plugging

A_10 = 2.85e-15 Hz gamma = 50.2 MHz lambda_alpha = 1.216e-5 cm T_cmb0 = 2.728 K T_star = 0.068 K

yields 1.81e11 (in units of cm^2, to match the units of J_alpha). If my calculations are correct, then the Lyman-alpha coupling in the code is weaker by 10% than what is should be.

Jordan

BradGreig commented 1 year ago

Hi @jordanflitter thanks for mentioning this. I had a brief look at this and it all looks reasonable. Where does your gamma = 50.2 MHz come from? Have you performed the full calculation. All my searches in the literature kept returning 50 MHz (I didn't calculate anything).

Also, interestingly it seems A_10 = 2.87e-15 seems to be preferred now for the spontaneous emission (although still some variation in the literature). Not that that would change much.

Rather than hard coding this to be a specific value, it might be better off calculating it based of the constants in the listed paper. That way it is more trivial to deal with.

jordanflitter commented 1 year ago

Dear @BradGreig , thank you for checking my numbers :)

Indeed, most papers in the literature do cite gamma = 50 MHz. Since I wanted to understand where the discrepancy in the numerical prefactor comes from, I wanted to verify that it doesn't come from gamma. I used Eq. (17) from Mittal & Kulkarni (arXiv: 2009.10746). Given the oscillator strength F_alpha= 0.4182, the rest of the terms in that equation are known physical constants, and after plugging all the numbers I obtained 50.2 MHz.

And I agree with you, I also think that it might be better to calculate that value from the physical constants, as it's a global prefactor that is the same for all the cells in the box.

BradGreig commented 1 year ago

This has been updated as part of #322.