Skip to content

Commit

Permalink
fix equation bug
Browse files Browse the repository at this point in the history
  • Loading branch information
jvshields committed Oct 28, 2024
1 parent a4da85f commit fbf01bf
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -873,7 +873,8 @@ def _calc_vald_vdw_unsoeld_approx(
temperature
), # This is just saying hydrogen density is 1. We multiply by hydrogen density later for all types of vdW broadening
)
return vdW[:, np.newaxis] * approx_gamma

return approx_gamma * vdW[:, np.newaxis]


def _calc_vald_vdW_abo(vdW, temperature, atomic_mass):
Expand All @@ -886,7 +887,8 @@ def _calc_vald_vdW_abo(vdW, temperature, atomic_mass):
vdW_int = vdW.astype(int)
sigma = (vdW_int * BOHR_RADIUS * BOHR_RADIUS)[:, np.newaxis]
alpha = (vdW - vdW_int)[:, np.newaxis]
inverse_reduced_mass = (1 / 1.008 * AMU_CGS) + (1 / atomic_mass)

inverse_reduced_mass = 1 / (1.008 * AMU_CGS) + (1 / atomic_mass)
vbar = np.sqrt(8 * BOLTZMANN_CONSTANT * temperature / PI * inverse_reduced_mass)
return (
2
Expand Down

0 comments on commit fbf01bf

Please sign in to comment.