---
title: "Supplying photons to an expanding volume"
description: "Escaped photons grow the ionized volume while recombination consumes part of the supply; a comoving box keeps the hydrogen count fixed."
canonical_url: "https://sandboxphysics.com/stories/reionization/photons-in-an-expanding-box/"
language: "en"
page_type: "story"
alternate_languages:
  zh-CN: "https://sandboxphysics.com/zh/stories/reionization/photons-in-an-expanding-box/"
last_modified: "2026-11-12"
---

[Starlight and intergalactic hydrogen](https://sandboxphysics.com/stories/reionization/)

# Supplying photons to an expanding volume

Sandbox Physics · 2026-11-12

Maintaining ionization requires photons for both previously neutral hydrogen and hydrogen that has recombined. In an expanding region, keep track of a fixed number of hydrogen nuclei, then compare the ionizations supplied each second with the ionizations lost. This gives an equation for the changing ionized volume.

Read [What does half ionized mean?](https://sandboxphysics.com/stories/reionization/ionized-volume-and-local-fraction/) first. The mathematical background is fractions, exponential functions and units. We introduce a derivative through changes over a short interval; solving a numerical differential equation is not a prerequisite. The aims are to build the volume equation, solve a constant-coefficient example and interpret an existing synthetic record.

## From a short interval to a rate

Use uniform-density gas with two phases, one nearly fully ionized and the other nearly neutral. Let $N_{\mathrm H}$ be the total number of hydrogen nuclei and $Q$ the ionized volume filling factor. The current number of ions is then $N_{\mathrm I}=QN_{\mathrm H}$.

Write the rate of ionizing photons entering the intergalactic gas as $S$, in $\mathrm{s^{-1}}$. These photons have already escaped their galaxies. The teaching box joins opposite faces, so no separate loss through its boundary is subtracted; the escape fraction refers to leaving a galaxy. Count one primary hydrogen ionization per photon, leaving secondary ionizations and propagation time out of this calculation.

At the given ionized-gas temperature, let $\alpha_{\mathrm B}$ be the Case-B recombination coefficient. A prescribed dimensionless multiplier $C$ represents a common increase in recombination cost from unresolved structure; it does not generate resolved dense clumps. The effective rate per ion is $\alpha_{\mathrm B}C\bar n_{\mathrm H}$, where $\bar n_{\mathrm H}$ is the current proper number density.

Over a short interval $\Delta t$ with slowly changing rates,

$$
\Delta Q\simeq\left(\frac{S}{N_{\mathrm H}}-\alpha_{\mathrm B}C\bar n_{\mathrm H}Q\right)\Delta t.
$$

Divide by the interval and make it progressively shorter. The limiting rate is $\mathrm dQ/\mathrm dt$. Define $s=S/N_{\mathrm H}$ and $t_{\mathrm{rec}}=1/(\alpha_{\mathrm B}C\bar n_{\mathrm H})$ to obtain

$$
\frac{\mathrm dQ}{\mathrm dt}=s-\frac{Q}{t_{\mathrm{rec}}}.
$$

Here $s$ is the photon supply per nucleus per second, and $t_{\mathrm{rec}}$ is a time in seconds. Both terms change a fraction per second. The loss is proportional to $Q$ because it acts on the amount of the fully ionized phase. The previous chapter's local $x^2$ equation follows a different object. With this common recombination cost, rearranging sources at fixed total supply and history does not change the volume equation. If real dense structure changes the recombination losses, that effect must also be calculated. [Madau, Haardt and Rees, 1999, §3.1](https://arxiv.org/abs/astro-ph/9809058v1)

## A complete constant-density example

Hold density, temperature and $C$ fixed. Start neutral and supply photons at a constant rate with $s\,t_{\mathrm{rec}}=0.8$: every recombination time brings 0.8 photons per hydrogen nucleus. With dimensionless time $u=t/t_{\mathrm{rec}}$,

$$
\frac{\mathrm dQ}{\mathrm du}=0.8-Q.
$$

At first, recombination costs almost nothing because little gas is ionized. As the ionized volume grows, maintaining it consumes more of the supply. The distance from equilibrium, $0.8-Q$, decreases at a rate proportional to itself. It therefore decays exponentially, giving

$$
Q(u)=0.8(1-\mathrm e^{-u}).
$$

The initial value is zero. Its derivative is $0.8\mathrm e^{-u}=0.8-Q$, which checks the rate equation. After one recombination time,

$$
Q(1)\simeq0.505696.
$$

The source has supplied 0.8 photons per nucleus, but only about 0.506 ionizations per nucleus remain. The difference, about 0.294, corresponds to net recombinations during the interval. Starting neutral, the cumulative escaped photons $N_\gamma$, current ions, net recombinations $N_{\mathrm{rec}}$ and surplus photons $N_{\mathrm{spare}}$ obey

$$
N_\gamma=N_{\mathrm I}+N_{\mathrm{rec}}+N_{\mathrm{spare}}.
$$

There is no surplus in this example. A sufficiently strong source can fill the region, bringing $Q$ to one. It stays there while the supply continues to replace recombinations. Additional photons enter the surplus count; a radiation-transport model would specify their later paths.

Photons supplied

Retained ionizations

Recombinations

After one recombination time in the constant-density example, the supply is $0.8$, retained ionizations are about $0.506$, and cumulative recombinations are about $0.294$. All counts are per hydrogen nucleus. The bar lengths use the unrounded saved values.

## Expansion changes the recombination time

A fixed comoving volume $V_{\mathrm c}$ follows the same expanding region. Comoving coordinates divide out the overall expansion. At scale factor $a$, its proper volume is $V_{\mathrm p}=a^3V_{\mathrm c}$, while its number density falls as

$$
\bar n_{\mathrm H}(a)=\bar n_{\mathrm H,0}a^{-3},\qquad
N_{\mathrm H}=\bar n_{\mathrm H}(a)V_{\mathrm p}=\bar n_{\mathrm H,0}V_{\mathrm c}.
$$

Dilution changes encounter rates without removing hydrogen nuclei from the comoving region. At fixed temperature and $C$, the recombination time grows as $a^3$. Put that time dependence into the volume equation. Adding a separate loss of hydrogen to $Q$ from this same expansion would count the dilution twice.

A numerical calculation also needs the relation between $a$ and time. One explicit choice is a flat matter-plus-cosmological-constant background:

$$
H(a)=H_0\sqrt{\Omega_{\mathrm m}a^{-3}+1-\Omega_{\mathrm m}},\qquad
\frac{\mathrm dt}{\mathrm da}=\frac{1}{aH(a)}.
$$

$H$ is the fractional growth rate of the scale factor, and $H_0$ is its value at $a=1$. The dimensionless $\Omega_{\mathrm m}$ weights the matter term; the constant term represents the cosmological constant. Prescribe $H_0=67.4\,\mathrm{km\,s^{-1}\,Mpc^{-1}}$ and $\Omega_{\mathrm m}=0.315$, neglecting radiation over redshifts seven to ten. The expansion history is an additional input here. The ionized-phase temperature is fixed at $10^4\,\mathrm K$. The Hui–Gnedin Case-B fit then gives approximately $2.592\times10^{-19}\,\mathrm{m^3\,s^{-1}}$ for the recombination coefficient. This ionized-gas temperature is separate from the neutral-hydrogen spin temperature. [Hui and Gnedin, Appendix A](https://arxiv.org/abs/astro-ph/9612232v1)

## Reading an existing synthetic record

![Four directly advanced counters from the same default synthetic record. Proper time starts at source-on at redshift ten; the common recombination budget separates retained ionizations, recombinations and surplus.](https://sandboxphysics.com/figures/reionization/photon-counters-en-desktop.svg)

Four directly advanced counters from the same default synthetic record. Proper time starts at source-on at redshift ten; the common recombination budget separates retained ionizations, recombinations and surplus.

Take a uniform comoving cube 20 Mpc on a side with present-equivalent hydrogen number density $0.190922\,\mathrm{m^{-3}}$. It contains about $4.48743\times10^{70}$ hydrogen nuclei. Synthetic constant sources produce $4.00\times10^{55}\,\mathrm{s^{-1}}$ ionizing photons. An escape fraction of 0.2 gives $S=8.00\times10^{54}\,\mathrm{s^{-1}}$; choose $C=3$.

About 103 million years after the sources turn on at redshift ten, normalize the saved global counts to a hundred hydrogen nuclei:

**Table 3.1** Counts per hundred hydrogen nuclei at this epoch.

| Per hundred hydrogen nuclei | Count |
| --- | --- |
| Escaped photons supplied | $57.9216$ |
| Cumulative net recombinations | $12.1202$ |
| Current retained ionizations | $45.8015$ |
| Surplus photon count | $0$ |

The counts satisfy $57.9216\simeq45.8015+12.1202$, with each displayed value rounded separately. The current ionized volume is about 45.8%; roughly one fifth of the supplied photon count has gone into replacing recombinations. The same record checks its clock:

$$
t=\frac{0.5792161\,(4.4874332\times10^{70})}{8.00\times10^{54}\,\mathrm{s^{-1}}}
\simeq3.249\times10^{15}\,\mathrm s\simeq103\,\mathrm{Myr}.
$$

Use $1\,\mathrm{Myr}=10^6\times31557600\,\mathrm s$. Before rounding, 102.954 million years have elapsed since source turn-on. The scale factor at that epoch is about 0.103693, with its usual normalization to one today. The excerpt and its input provenance are in the [companion data](https://sandboxphysics.com/stories/reionization/materials/teaching-values.json). This volume calculation determines how much gas can be maintained in the ionized phase. A spatial prescription is still needed to place that volume.

## Change a condition

1. Start neutral, neglect recombination and supply 0.6 photons per nucleus. Find $Q$. Explain why knowing only that photon count cannot determine $Q$ once recombination is allowed.
2. At fixed temperature and $C$, double the scale factor. What happens to the nuclei count, proper number density and recombination time? Does it follow that $Q$ becomes eight times larger?
3. Two source populations give the same $Q$. Must their escape fractions be equal? What else is needed?

For the first problem, all supplied photons add ionizations and the volume has not filled, so $Q=0.6$. Recombination introduces another cumulative count. The same photon supply can leave fewer ionizations at the time of interest.

For the second, the nuclei count stays fixed, number density drops by a factor of eight and the recombination time grows eightfold. The resulting $Q$ depends on the entire supply and loss history. A change in an instantaneous timescale cannot simply be applied as a volume multiplier.

For the third, the intrinsic photon production, duration and recombination history also matter. Greater supply and greater recombination can occur together and yield the same $Q$. Even with that history fixed, the ionized volume can occupy different spatial arrangements. Bubble merging and 21 cm statistics will take up that remaining spatial information.

## Sources

1. [Madau, Haardt and Rees, 1999, §3.1](https://arxiv.org/abs/astro-ph/9809058v1)
2. [Hui and Gnedin, Appendix A](https://arxiv.org/abs/astro-ph/9612232v1)

## Keep reading

Starlight and intergalactic hydrogen · Reading path

### Photons, ionized volume and a radio signal

1. [Article **How starlight changes intergalactic hydrogen**](https://sandboxphysics.com/stories/reionization/starlight-and-hydrogen/)
2. [Article **What does half ionized mean?**](https://sandboxphysics.com/stories/reionization/ionized-volume-and-local-fraction/)
3. [You are here **Supplying photons to an expanding volume**](https://sandboxphysics.com/stories/reionization/photons-in-an-expanding-box/)
4. [Article **Where the photons go when ionized bubbles meet**](https://sandboxphysics.com/stories/reionization/when-ionized-bubbles-overlap/)
5. [Article **Reading ionized bubbles through neutral hydrogen**](https://sandboxphysics.com/stories/reionization/reading-a-neutral-hydrogen-map/)
6. [Article **Recompute a fixed-source ionization history**](https://sandboxphysics.com/stories/reionization/recompute-a-fixed-source-history/)
7. [Article **Reading HERA's 21 cm upper limits**](https://sandboxphysics.com/stories/reionization/reading-hera-upper-limits/)
