Recipe
Python
Beginner
10 min
The Saha equation with brentq: the temperature at which hydrogen recombined
Afterwards you can solve the Saha equation for the ionized fraction of hydrogen at any temperature and density and find where it is one half with brentq.
Numerical calculus
Physics