---
title: The Friedmann Equations and Cosmic Dynamics
draft: false
module: Cosmic Expansion and Dynamics
moduleNumber: 11
lessonNumber: 3
order: 1103
summary: >
  The scale factor obeys the Friedmann equation, the acceleration equation, and the
  fluid equation, only two of which are independent. An equation of state fixes how
  each component behaves under expansion, so radiation dilutes as the inverse fourth
  power of the scale factor, matter as the inverse cube, and vacuum energy not at all.
  The critical density defines the density parameters, and the deceleration parameter
  encodes whether gravity or dark energy is winning.
topics: [Cosmology]
sources:
  - book: Ryden
    ref: "Ch. 4 — Cosmic Dynamics; Ch. 5 — Model Universes"
  - book: Carroll & Ostlie
    ref: "Ch. 29 — Cosmology; §29.3 The Friedmann Equations"
  - book: Maoz
    ref: "Ch. 9 — The Big Bang and the Expansion of the Universe"
---

The metric of the previous lesson contains an undetermined function, the scale factor
$a(t)$. What fixes it is the content of the universe acting through gravity. In general
relativity the connection between geometry and content is the Einstein field equation;
specialized to the Robertson-Walker metric it collapses to two ordinary differential
equations for $a(t)$, the **Friedmann equations**, supplemented by a thermodynamic
**fluid equation** that describes how each component's energy density changes as the
universe expands. This lesson assembles these equations, introduces the equation of
state that distinguishes radiation, matter, and vacuum energy, works out how each
component's density scales with $a$, and defines the critical density, the density
parameters $\Omega_i$, and the deceleration parameter that together summarize the
dynamical state of the cosmos.

## The Friedmann equation

The Newtonian energy argument of the first lesson already produced the correct form.
Retaining the relativistic result, in which the source of gravity is the total energy
density $\varepsilon = \rho c^{2}$ rather than the mass density alone, the **Friedmann
equation** is

$$
\left(\frac{\dot a}{a}\right)^{2}
  = \frac{8\pi G}{3 c^{2}}\,\varepsilon - \frac{k c^{2}}{a^{2}} ,
$$

or equivalently, writing it with mass density $\rho = \varepsilon/c^{2}$,

$$
H^{2} = \left(\frac{\dot a}{a}\right)^{2}
  = \frac{8\pi G}{3}\,\rho - \frac{k c^{2}}{a^{2}} .
$$

This is a first-order equation relating the expansion rate $H = \dot a/a$ to the density
and the curvature. It expresses energy conservation for the expansion: the "kinetic"
term $H^{2}$ is balanced against the "potential" term set by the density and a constant
of integration fixed by the curvature $k$. Given the density as a function of $a$, this
equation determines the entire expansion history.[^ry-friedmann]

$$
% caption: The Friedmann equation as an energy balance: the expansion rate squared is
% the gravitating density term minus the curvature term. Their competition sets the fate.
\begin{tikzpicture}[scale=1.0, font=\footnotesize]
\definecolor{acc}{HTML}{4A6FA5}
% central balance
\node[anchor=center] at (0,1.0) {H squared};
\node[black, anchor=center] at (0,0.5) {expansion};
% left: density drives
\draw[->, very thick] (2.3,0.75) -- (0.9,0.75);
\node[anchor=west] at (2.4,0.75) {density: drives expansion};
% right: curvature opposes (for k>0)
\draw[->, black, very thick] (-2.3,0.75) -- (-0.9,0.75);
\node[black, anchor=east] at (-2.4,0.75) {curvature term};
% equation reminder below
\node[black, anchor=north] at (0,-0.1) {H squared = (8 pi G / 3) rho  minus  k c squared / a squared};
\end{tikzpicture}
$$

## The fluid equation and the acceleration equation

The Friedmann equation alone is not closed: we need to know how $\varepsilon$ changes as
$a$ changes. That comes from the first law of thermodynamics applied to a comoving
volume. Take a sphere of comoving radius, physical volume $V \propto a^{3}$, containing
energy $E = \varepsilon V$. Cosmic expansion is adiabatic — there is no heat flow across
a comoving boundary in a homogeneous universe, since every neighboring region is
identical — so $\d E = -P\,\d V$. With $E = \varepsilon a^{3}$ (up to a constant volume
factor) and $V \propto a^{3}$,

$$
\d(\varepsilon a^{3}) = -P\,\d(a^{3}) .
$$

Expanding the derivatives and dividing by $\d t$ gives the **fluid equation**:

$$
\dot\varepsilon + 3\,\frac{\dot a}{a}\big(\varepsilon + P\big) = 0 .
$$

The first term is the dilution of energy density by the growing volume; the second is
the work done by the pressure as the universe expands. Differentiating the Friedmann
equation with respect to time and eliminating $\dot\varepsilon$ with the fluid equation
yields the second-order **acceleration equation**:

$$
\frac{\ddot a}{a} = -\frac{4\pi G}{3 c^{2}}\big(\varepsilon + 3P\big) .
$$

Three features stand out. There is no curvature term $k$: the acceleration depends only
on the contents. Gravity decelerates the expansion, since $\ddot a < 0$ whenever
$\varepsilon + 3P > 0$. Third and least intuitive, **pressure gravitates**: it is the combination
$\varepsilon + 3P$, not the energy density alone, that sources the deceleration. A
component with sufficiently negative pressure, $P < -\varepsilon/3$, makes $\ddot a > 0$
and drives the expansion to accelerate. This is the loophole that dark energy exploits.

Of the three equations — Friedmann, fluid, acceleration — only two are independent; any
one follows from the other two. In practice one solves the fluid equation for
$\varepsilon(a)$ and substitutes into the Friedmann equation.

> **Theorem (The acceleration equation).** In a Robertson-Walker universe the scale
> factor obeys $\ddot a/a = -\tfrac{4\pi G}{3c^{2}}(\varepsilon + 3P)$. Deceleration is
> sourced by $\varepsilon + 3P$; a component with $P < -\varepsilon/3$ accelerates the
> expansion.

## The equation of state

To close the system we relate pressure to energy density through an **equation of
state**. For the components of cosmological interest the relation is linear,

$$
P = w\,\varepsilon ,
$$

with a dimensionless constant $w$ characteristic of each component. Three values matter:

- **Matter** (nonrelativistic "dust" — galaxies, cold dark matter, baryons): the random
  thermal pressure is utterly negligible compared to the rest-energy density, so $w = 0$.
- **Radiation** (photons, and any relativistic species such as neutrinos in the early
  universe): an isotropic gas of massless particles has $P = \tfrac{1}{3}\varepsilon$, so
  $w = \tfrac{1}{3}$.
- **Vacuum energy** (the cosmological constant $\Lambda$): a Lorentz-invariant vacuum has
  $P = -\varepsilon$, so $w = -1$. This is the negative-pressure component that
  accelerates expansion.

The value $w = \tfrac{1}{3}$ for radiation follows from kinetic theory: for a relativistic
gas the pressure is one-third of the energy density because momentum and energy are
proportional for massless particles and the isotropic average of one Cartesian component
is one-third. The value $w = -1$ for vacuum energy follows from requiring the stress-energy
to look the same to every observer — only a term proportional to the metric itself is
Lorentz invariant, and it carries $P = -\varepsilon$.[^ry-eos]

$$
% caption: The equation-of-state parameter w for the three cosmic components on a
% number line: vacuum at w = -1, matter at w = 0, radiation at w = +1/3. The dividing
% value w = -1/3 separates the accelerating regime from the decelerating one.
\begin{tikzpicture}[scale=1.0, font=\footnotesize]
\definecolor{acc}{HTML}{4A6FA5}
% number line
\draw[->, black] (-3.6,0) -- (3.6,0) node[right, black!70] {w};
\foreach \x in {-3,-1,0,3}
  \draw[black] (\x,0.1) -- (\x,-0.1);
% vacuum at w = -1
\fill[black] (-3,0) circle (0.09);
\node[black, anchor=south] at (-3,0.2) {vacuum};
% matter at w = 0
\fill[black] (0,0) circle (0.09);
\node[black, anchor=south] at (0,0.2) {matter};
% radiation at w = 1/3
\fill[black] (3,0) circle (0.09);
\node[black, anchor=south] at (3,0.2) {radiation};
% divider at w = -1/3
\draw[black, densely dashed] (-1,0.7) -- (-1,-0.75);
\node[black, anchor=north, align=center] at (-1,-0.9) {accelerate : decelerate};
\end{tikzpicture}
$$

## How each component dilutes

With $P = w\varepsilon$ the fluid equation becomes a simple ODE for $\varepsilon(a)$:

$$
\dot\varepsilon + 3\,\frac{\dot a}{a}\,(1 + w)\,\varepsilon = 0
\quad\Longrightarrow\quad
\frac{\d\varepsilon}{\varepsilon} = -3(1 + w)\,\frac{\d a}{a} ,
$$

which integrates to

$$
\varepsilon(a) = \varepsilon_0\, a^{-3(1 + w)} .
$$

Inserting the three values of $w$ gives the scaling laws that govern the whole thermal
history:

- **Matter** ($w = 0$): $\varepsilon_m \propto a^{-3}$. The energy density falls as the
  volume grows — pure dilution of a fixed number of particles.
- **Radiation** ($w = \tfrac{1}{3}$): $\varepsilon_r \propto a^{-4}$. One factor of
  $a^{-3}$ from dilution and one more from the redshift of each photon's energy,
  $\varepsilon_{\text{photon}} \propto 1/\lambda \propto a^{-1}$.
- **Vacuum** ($w = -1$): $\varepsilon_\Lambda \propto a^{0} = \text{const}$. The vacuum
  energy density does not dilute — as space grows, each new volume comes with the same
  energy density, since it is a property of space itself.

These differing exponents mean the balance of the universe shifts with time. At early
times, when $a$ is small, radiation with its steep $a^{-4}$ dominates. As the universe
expands, radiation falls below matter at the epoch of **matter-radiation equality**, and
the universe becomes matter-dominated. Much later, when matter has diluted enough, the
constant vacuum energy takes over and the universe enters an accelerating,
vacuum-dominated phase. The order — radiation, then matter, then vacuum — is dictated
entirely by the exponents.[^co-friedmann]

$$
% caption: Log-log energy density versus scale factor. Radiation falls steepest, matter
% shallower, vacuum flat; the dominant component changes at each crossover.
\begin{tikzpicture}[scale=1.0, font=\footnotesize]
\definecolor{acc}{HTML}{4A6FA5}
\draw[->, black] (0,0) -- (8.6,0) node[right, black!70] {log scale factor};
\draw[->, black] (0,0) -- (0,4.4) node[above, black!70] {log energy density};
% radiation: slope -4 (steepest), solid
\draw[very thick] (0.4,4.1) -- (5.2,0.3);
\node[anchor=south west] at (0.4,3.8) {radiation};
% matter: slope -3, dashed neutral
\draw[black, very thick, densely dashed] (0.4,3.4) -- (6.6,0.3);
\node[black, anchor=west] at (2.2,2.35) {matter};
% vacuum: flat, dotted neutral
\draw[black, very thick, densely dotted] (0.4,1.2) -- (8.2,1.2);
\node[black, anchor=south] at (6.9,1.25) {vacuum};
% crossovers
\draw[black, densely dotted] (2.55,0) -- (2.55,3.6);
\node[black, anchor=north, align=center] at (2.55,-0.1) {eq};
\draw[black, densely dotted] (6.05,0) -- (6.05,1.5);
\node[black, anchor=north, align=center] at (6.05,-0.1) {Lambda};
\end{tikzpicture}
$$

## The critical density and the density parameters

The Friedmann equation ties the total density to the geometry. Setting $k = 0$ defines
the **critical density** — the density that makes the universe spatially flat at a given
expansion rate:

$$
\rho_{\text{crit}}(t) = \frac{3 H^{2}}{8\pi G} .
$$

At the present epoch, with $H_0 = 70\ \text{km}\,\text{s}^{-1}\,\text{Mpc}^{-1}$,

$$
\rho_{\text{crit},0} = \frac{3 H_0^{2}}{8\pi G}
\approx 9.2 \times 10^{-27}\ \text{kg}\,\text{m}^{-3}
\approx 5.5\ \frac{\text{protons}}{\text{m}^{3}} ,
$$

an extraordinarily low density — a handful of hydrogen atoms per cubic meter averaged
over the cosmos. Each component's density is then measured as a fraction of critical
through the dimensionless **density parameter**

$$
\Omega_i \equiv \frac{\rho_i}{\rho_{\text{crit}}}
= \frac{8\pi G\,\rho_i}{3 H^{2}} .
$$

Dividing the Friedmann equation by $H^{2}$ recasts it as a sum rule among the density
parameters and a curvature term:

$$
1 = \Omega_m + \Omega_r + \Omega_\Lambda - \frac{k c^{2}}{a^{2} H^{2}}
\equiv \Omega_{\text{tot}} + \Omega_k ,
$$

with $\Omega_k \equiv -k c^{2}/(a^{2} H^{2})$ the curvature contribution. The geometry
follows directly from the total: $\Omega_{\text{tot}} > 1$ means $k > 0$ (closed),
$\Omega_{\text{tot}} = 1$ means $k = 0$ (flat), and $\Omega_{\text{tot}} < 1$ means
$k < 0$ (open). Measuring the total density is thus equivalent to measuring the curvature.
The observed values from Planck are $\Omega_{m,0} \approx 0.31$ (of which only about
$0.05$ is ordinary baryonic matter, the rest cold dark matter), $\Omega_{\Lambda,0}
\approx 0.69$, and $\Omega_{r,0} \approx 9 \times 10^{-5}$, summing to
$\Omega_{\text{tot},0} = 1.000 \pm 0.005$ — a flat universe.[^ry-omega]

$$
% caption: The present-epoch energy budget as fractions of the critical density: dark
% energy the largest share, then dark matter, then baryons, radiation negligible.
\begin{tikzpicture}[scale=1.0, font=\footnotesize]
\definecolor{acc}{HTML}{4A6FA5}
% pie: Lambda 69, dark matter 26, baryons 5. Start at 90 deg, go clockwise.
% Lambda: 0.69 -> 248.4 deg. from 90 to 90-248.4 = -158.4
\fill[acc!18] (0,0) -- (90:2.2) arc (90:-158.4:2.2) -- cycle;
% dark matter: 0.26 -> 93.6 deg, from -158.4 to -252
% baryons: 0.05 -> 18 deg, from -252 to -270 (=90)
\draw[black] (0,0) -- (90:2.2);
\draw[black] (0,0) -- (-158.4:2.2);
\draw[black] (0,0) -- (-252:2.2);
\draw[black] (0,0) circle (2.2);
% labels
\node[black!70, anchor=west] at (2.5,1.4) {dark energy: 69 percent};
\node[black!70, anchor=west] at (2.5,0.4) {dark matter: 26 percent};
\node[black!70, anchor=west] at (2.5,-0.6) {baryons: 5 percent};
\node[black!70, anchor=west] at (2.5,-1.6) {radiation: tiny};
\end{tikzpicture}
$$

## The deceleration parameter

A single dimensionless number summarizes whether the expansion is speeding up or slowing
down. The **deceleration parameter** is defined by

$$
q \equiv -\frac{\ddot a\, a}{\dot a^{2}} = -\frac{\ddot a/a}{H^{2}} ,
$$

with the minus sign chosen so that a decelerating universe (the historical expectation)
has $q > 0$. Substituting the acceleration equation and expressing densities through the
density parameters gives a compact formula. For a mix of components each with equation of
state $w_i$,

$$
q = \frac{1}{2}\sum_i \Omega_i\,(1 + 3 w_i)
= \Omega_r + \frac{1}{2}\Omega_m - \Omega_\Lambda ,
$$

using $w_r = \tfrac{1}{3}$, $w_m = 0$, $w_\Lambda = -1$. Radiation and matter contribute
positive deceleration; vacuum energy contributes acceleration with a coefficient twice as
strong per unit density. With the observed present values $\Omega_{m,0} \approx 0.31$ and
$\Omega_{\Lambda,0} \approx 0.69$, the radiation term negligible,

$$
q_0 \approx \tfrac{1}{2}(0.31) - 0.69 \approx -0.53 ,
$$

a **negative** deceleration parameter: the expansion is accelerating today. This is the
quantitative statement of the 1998 supernova discovery, treated in the dark-energy
lesson. Earlier in cosmic history, before vacuum energy dominated, $q$ was positive and
the expansion decelerated; the transition from $q > 0$ to $q < 0$ occurred at redshift
$z \approx 0.6$, when the accelerating vacuum term overtook the decelerating matter term.

## Summary

The scale factor is governed by three equations, two independent: the Friedmann equation
$H^2 = 8\pi G\rho/3 - kc^2/a^2$ relating expansion rate to density and curvature, the
fluid equation $\dot\varepsilon + 3H(\varepsilon + P) = 0$ enforcing adiabatic energy
conservation, and the acceleration equation $\ddot a/a = -\tfrac{4\pi G}{3c^2}(\varepsilon
+ 3P)$ in which pressure gravitates. A linear equation of state $P = w\varepsilon$ fixes
each component's dilution, $\varepsilon \propto a^{-3(1+w)}$, giving radiation $a^{-4}$,
matter $a^{-3}$, and vacuum energy constant, so the universe passes from radiation to
matter to vacuum domination. The critical density $\rho_{\text{crit}} = 3H^2/8\pi G$
defines the density parameters $\Omega_i$, whose sum fixes the geometry, and the
deceleration parameter $q = \Omega_r + \tfrac{1}{2}\Omega_m - \Omega_\Lambda \approx
-0.53$ today records that the expansion now accelerates. The next lesson integrates these
equations for specific mixtures to produce the
[benchmark cosmological
models](/astrophysics-cosmology/cosmology-expansion-and-dynamics/cosmological-models-and-distances)
and the distance-redshift relations they predict.

[^ry-friedmann]: Ryden, *Introduction to Cosmology*, Ch. 4 — Cosmic Dynamics: the Friedmann equation and its energy interpretation.
[^ry-eos]: Ryden, Ch. 4 — the equation of state $P = w\varepsilon$ for matter, radiation, and the cosmological constant.
[^co-friedmann]: Carroll & Ostlie §29.3 — the scaling of each component's density with the scale factor and the sequence of dominant eras.
[^ry-omega]: Ryden, Ch. 4–5 — the critical density, the density parameters, and the flatness constraint; Planck 2018 values, https://arxiv.org/abs/1807.06209.
