iCosmos › CMB lab

CMB lab

Change the cosmological parameters and watch the temperature power spectrum of the cosmic microwave background move against the Planck 2018 measurements, with the whole simulated sky beside it.

The lab needs JavaScript: it computes the spectrum and the simulated sky in your browser as you move the sliders.

Guided tasks

Five short investigations. Each starts from a universe that is wrong in one way and gives you one slider. The page checks the result from the spectrum itself and explains the physics when you get there. Printable worksheet with answers.

  1. Weigh the baryons. This universe has too much ordinary matter. Bring the second peak back to its measured height relative to the first.
  2. Find the dark matter. This universe has too little dark matter. Use the third peak to find how much there really is.
  3. Measure the curvature. This universe is open (Ωk = +0.08). Change the curvature until the first peak is where Planck sees it.
  4. Tilt and the damping tail. The primordial tilt ns is too low here. Use the points beyond ℓ = 1000 as well as those below ℓ = 500 to set it.
  5. The geometric degeneracy. Can the CMB tell a flat universe from a curved one? Find curved universes that Planck’s spectrum cannot distinguish from the flat one, including one with H0 = 73.

What the cosmic microwave background is

About 370 000 years after the Big Bang the universe had cooled enough for electrons and protons to form neutral hydrogen. Light stopped scattering and has travelled freely ever since, cooling with the expansion to 2.7255 K today. This is the cosmic microwave background (CMB). Its temperature is the same in every direction to a few parts in 100 000; the tiny differences, typically about 100 microkelvin and up to a few hundred, are the imprint of the density fluctuations from which all later structure grew.

How to read the spectrum

The power spectrum sorts the temperature differences by angular size. The multipole ℓ corresponds to an angle of about 180°/ℓ, so ℓ = 200 is about one degree. The vertical axis, Dℓ = ℓ(ℓ + 1)Cℓ/2π in μK², is the variance of the temperature per logarithmic interval of ℓ: how much structure of that size contributes. The flat part on the left comes from scales that were larger than the horizon at decoupling. The peaks are sound waves in the early plasma caught at different phases of oscillation: the first, near ℓ = 220, is the scale that had just compressed once; the second had compressed and rarefied; and so on. Beyond ℓ ≈ 1000 the peaks fade because photon diffusion erased the smallest fluctuations (Silk damping). The spectrum shown is lensed: on the way to us the light was deflected slightly by the matter in between, which smooths the peaks and troughs a little.

The points are the Planck 2018 measurements with their 68 % uncertainties. At low ℓ the uncertainties are large because there are only a few independent patterns of that size on the whole sky (cosmic variance); this, not the instrument, limits any measurement there.

What each parameter does

Ωbh2, the density of ordinary matter: more baryons make the plasma heavier, so compressions go deeper. The odd peaks (1st, 3rd) rise relative to the even ones, the peaks move to slightly higher ℓ because sound travels more slowly in a heavier plasma, and the damping tail moves to smaller scales.

Ωch2, the density of dark matter (set here through Ωm): less dark matter means radiation matters more at decoupling, which drives the oscillations harder and raises all the peaks; the third peak is the most sensitive and shows that most matter is not made of baryons. Because the lab keeps H0 fixed when you change Ωm, the matter density Ωmh2 changes too, so the peaks also shift a little.

Curvature and dark energy (Ωk, ΩΛ) change only the distance to the last-scattering surface and so the angle the sound horizon subtends: the whole pattern of peaks slides left (closed universe) or right (open universe). The acoustic scale ℓA from the calculator’s engine is marked on the plot. H0 changes this distance too, but at fixed Ωm it also changes the matter and baryon densities Ωmh2 and Ωbh2, so the peak heights change as well.

ns, the tilt of the primordial spectrum: below 1 there is slightly more power on large scales than on small ones, so the spectrum tilts. As, the primordial amplitude, scales everything up or down. τ, the optical depth to reionisation: electrons freed when the first stars formed scattered some CMB photons again, which lowers the spectrum by a factor e−2τ on all but the largest scales (ℓ ≳ 50); the largest scales are almost unaffected. In temperature alone τ is nearly interchangeable with As, because only the combination Ase−2τ is well measured; the reionisation bump appears in polarisation, which the lab does not show.

How the lab computes the spectrum

An exact calculation solves the coupled equations of photons, baryons, dark matter and neutrinos for thousands of wavenumbers, which takes seconds per model in the CAMB Boltzmann code. To respond while you drag a slider, the lab uses an emulator: a small neural network trained on thousands of CAMB runs that span the parameter ranges below. It reproduces CAMB (run at its default accuracy, itself good to a few tenths of a percent) within the accuracy published on the validation page, and it refuses, with a message, to calculate outside the range it was trained on. The curve is therefore an approximation with a measured error, not an exact calculation.

The emulator follows Planck’s baseline conventions: one neutrino of 0.06 eV, Neff = 3.046 and TCMB = 2.7255 K, so with Planck’s best-fit parameters it agrees with Planck’s published theory curve to within the CAMB check on the validation page. (The “Planck 2018” starting model uses the published mean values with BAO, which differ slightly from that best fit, so its residual against the dashed curve is small but not zero.) The rest of iCosmos treats neutrinos as massless; this is why numbers here and in the calculator can differ in the last digits. The lab covers ΛCDM with curvature inside the ranges listed on the validation page (for example H0 from 55 to 85 and Ωk between −0.12 and +0.12); outside them it shows a message instead of a curve, while the rest of iCosmos has no such limit. It does not include polarisation, other kinds of dark energy or non-standard radiation.

The whole sky

Under the plots is the entire sky as your model would make it. A fixed list of random numbers, set by the seed, is scaled by your spectrum, one number for each pattern (spherical harmonic) the sky can hold, and the patterns are added up. Because the random numbers do not change when you move a slider, the same hot and cold regions stay where they are and only their sizes and contrast change, exactly as the spectrum says. “New random sky” draws a different list.

While a slider moves the map is built from the coarse patterns only (multipoles up to ℓ = 128, features down to about 1.4°), which takes about a hundredth of a second. When you stop, a sharper map with the finer patterns (to ℓ = 768, features down to about 0.2°) is computed in the background and replaces it a second or two later. Both are the same sky at different sharpness.

The oval is the Mollweide projection: the whole sphere unrolled so that equal areas of sky cover equal areas of the picture. The globe wraps the same map on a ball you can turn. It keeps the left–right sense of the oval, which is the sky as we see it from inside; a real globe of the sky viewed from outside would be the mirror image.

“Seen by” blurs the sky to what each satellite could resolve: COBE (1989–1993) about 7°, WMAP (2001–2010) about 0.2°, Planck (2009–2013) about 5 arcminutes. COBE saw only the largest blotches, many times larger than the one-degree scale of the first peak, and its real maps were also noisy. WMAP resolved the first acoustic peaks, Planck the finer ones. The blurring is applied to the spectrum before the sky is made; instrument noise is not simulated. Because this map stops at ℓ = 768 (about 0.2°), the Planck setting looks almost the same as no blur at all: Planck’s 5′ beam matters mainly beyond ℓ ≈ 1000, which only the square sample below shows.

You can also switch to the real sky: Planck’s 2018 map of the CMB temperature. It does not match your simulation spot for spot, and it should not. The theory predicts only the statistics of the pattern: how much structure there is at each angular size. Our sky is one random outcome with those statistics, and the simulation is another. What can be compared is the character of the two maps: the typical spot size and the contrast. Planck’s picture has had the Milky Way’s own emission removed, and the strip behind the Galactic plane and a few bright sources filled in by the Planck team; small traces of foreground remain. It is shown here to ℓ = 768, like the simulation, and rounded to steps of about 4 μK. The simulation contains nothing but the CMB.

The sample at full resolution

Below the whole sky is a small square patch (10° × 10° by default) drawn at the full resolution of the spectrum, to ℓ = 2500 with a 5′ beam, finer than the whole-sky map can show. It is a separate random realisation, not a piece cut out of the map above. The same random numbers filtered with the Planck 2018 spectrum are shown next to it. The colour scale of both views is fixed at ±300 μK, unless “automatic colour scale” is ticked, so that changes in amplitude are visible.

Data and credit

Measurements: Planck 2018 (PR3) temperature power spectrum, Planck Collaboration 2020, A&A 641, A5 (likelihoods and spectra) and A6 (cosmological parameters), from the Planck Legacy Archive (IRSA mirror), licence CC BY-NC 3.0 IGO. Credit: ESA, Planck Collaboration. Based on observations obtained with Planck (http://www.esa.int/Planck), an ESA science mission with instruments and contributions directly funded by ESA Member States, NASA, and Canada. Spectra for training: CAMB (Lewis, Challinor & Lasenby 2000). The equations and accuracy are on the Reference and Validation pages.

The observed whole-sky map is the Planck 2018 (PR3) SMICA CMB temperature map (Planck Collaboration 2020, A&A 641, A4), from the Planck Legacy Archive (IRSA mirror). Credit: ESA, Planck Collaboration. Licence CC BY-NC 3.0 IGO (https://creativecommons.org/licenses/by-nc/3.0/igo/). Modified by iCosmos: dipole removed, limited to ℓ ≤ 768, smoothed for the WMAP and COBE settings, and reduced to 8-bit images.

Open the iCosmos cosmology calculator

iCosmos 4.11.1 · updated