Encyclopedia Cosmology Cosmology Grand Potential Potential Gibbs Duhem
ARTICLE 5 claims 5 theorems
Cosmology Grand Potential Potential Gibbs Duhem
A standard thermodynamics identity turns out to be a simple consequence of the chain rule when pressure is treated as a potential.
The Gibbs-Duhem identity
The Gibbs-Duhem relation is a classical result in thermodynamics. For a system in equilibrium at zero chemical potential, it says that the pressure and temperature change together according to p′ = s·T′, where p is pressure, s is entropy density, and T is temperature. In words, the rate at which pressure changes along a temperature path equals the entropy density times the rate of temperature change. The relation is one of the standard equilibrium identities used to connect thermodynamic quantities.
In the framework's machine-checked library of formal theorems, the declaration potential_gibbs_duhem establishes that this identity is not an independent physical postulate. It derives from a single structural assumption: that pressure is a differentiable function of temperature, with entropy density defined as its derivative, s = dP/dT. Under that definition, the Gibbs-Duhem relation is exactly the chain rule applied to the composition P(T(t)). The library proves: if P has derivative s at T(t), and T has derivative T′ at t, then the composite function P(T(u)) has derivative s(T(t))·T′ at t. This is the chain rule, nothing more.
The same structural move also derives the Euler relation T·s = ρ + P, where ρ is energy density defined as the Legendre transform ρ = T·s − P. Both identities follow algebraically from the potential structure. The library then shows that the fundamental relation dρ = T·ds follows as well, since differentiating ρ = T·s − P gives ρ′ = T·s′. These three classical identities collapse into one statement: the fluid has a pressure potential with s = dP/dT, which is the definition of local equilibrium at zero chemical potential.
The payoff comes in cosmology. Earlier work had assumed Euler and Gibbs-Duhem as separate hypotheses to prove that comoving entropy is conserved in an expanding universe. With the potential structure, the library proves entropy conservation from the continuity equation alone, with the two identities now derived rather than assumed. The capstone result derives the neutrino dilution ratio (Tν/Tγ)³ = 4/11 from the pressure potential plus boundary data, and the effective entropy degrees of freedom g*s = 43/11. The radiation equation of state p = ρ/3 also emerges as a theorem of the grand-canonical ensemble, not an input.
What the declaration does not claim is equally important. It does not prove that any particular physical system actually has a pressure potential; that remains a modeling assumption for each specific fluid. The statistical-mechanical pressure of a massless Bose/Fermi gas is shown to satisfy the structure, but the grand-canonical form of the pressure at the boundaries is an input, even though its integrals are derived. The Friedmann equations behind the continuity equation are discharged separately. The declaration establishes a conditional theorem: if a fluid has a pressure potential, then the Gibbs-Duhem relation and its consequences follow.
THEOREM potential_gibbs_duhem · IndisputableMonolith/Cosmology/GrandPotential.lean
/-- **Gibbs–Duhem relation (derived).** Along any temperature trajectory
`T(t)`, the pressure obeys `p′ = s(T)·T′`: this is the chain rule applied to
`s = dP/dT`, not an independent postulate. -/
theorem potential_gibbs_duhem
{P s T : ℝ → ℝ} {T' t : ℝ}
(hP : HasDerivAt P (s (T t)) (T t))
(hT : HasDerivAt T T' t) :
HasDerivAt (fun u => P (T u)) (s (T t) * T') t := by
simpa [Function.comp] using hP.comp t hT
THEOREM potential_euler · IndisputableMonolith/Cosmology/GrandPotential.lean
/-- **Euler relation (derived).** `T·s = ρ + P` is an algebraic identity of
the Legendre-transform structure — not an independent equilibrium postulate. -/
theorem potential_euler (P s : ℝ → ℝ) (x : ℝ) :
x * s x = energyOf P s x + P x := by
simp only [energyOf]
ring
THEOREM energy_deriv · IndisputableMonolith/Cosmology/GrandPotential.lean
/-- **Fundamental relation `dρ = T·ds` (derived).** The energy density of a
potential fluid has temperature derivative `ρ′(T) = T·s′(T)`:
differentiating `ρ = T·s − P` gives `s + T·s′ − s`. -/
theorem energy_deriv
{P s : ℝ → ℝ} {sT x : ℝ}
(hP : HasDerivAt P (s x) x)
(hs : HasDerivAt s sT x) :
HasDerivAt (energyOf P s) (x * sT) x := by
have hid : HasDerivAt (fun y : ℝ => y) 1 x := hasDerivAt_id x
have hxs : HasDerivAt (fun y => y * s y) (1 * s x + x * sT) x := hid.mul hs
have h : HasDerivAt (fun y => y * s y - P y)
(1 * s x + x * sT - s x) x := hxs.sub hP
have hval : 1 * s x + x * sT - s x = x * sT := by ring
rw [hval] at h
exact h
THEOREM potential_entropy_conserved · IndisputableMonolith/Cosmology/GrandPotential.lean
/-- **THEOREM (entropy conservation from the potential alone).** For a fluid
whose pressure is a differentiable potential with `s = dP/dT` — the definition
of local equilibrium at zero chemical potential — the FRW continuity equation
forces `d/dt (s·a³) = 0`. The Euler and Gibbs–Duhem hypotheses of
`EntropyConservationFRW.comoving_entropy_conserved` are *derived* here
(`potential_euler`, `potential_gibbs_duhem`), not assumed. -/
theorem potential_entropy_conserved
{P s : ℝ → ℝ} {T a : ℝ → ℝ} {sT T' a' t : ℝ}
(hTt : T t ≠ 0)
(hP : HasDerivAt P (s (T t)) (T t))
(hs : HasDerivAt s sT (T t))
(hT : HasDerivAt T T' t) (ha : HasDerivAt a a' t)
(hcont : a t * (T t * sT * T')
= -3 * a' * (energyOf P s (T t) + P (T t))) :
HasDerivAt (fun u => s (T u) * a u ^ 3) 0 t :=
EntropyConservationFRW.comoving_entropy_conserved hTt
(potential_energy_deriv hP hs hT)
(potential_gibbs_duhem hP hT)
(potential_entropy_deriv hs hT)
ha hT
(fun u => potential_euler P s (T u))
rfl
hcont
THEOREM dilution_from_potential · IndisputableMonolith/Cosmology/GrandPotential.lean
/-- **CAPSTONE (dilution from the potential).** `(T_ν/T_γ)³ = 4/11` from:
the coupled sector has a pressure potential with `s = dP/dT` (local
equilibrium, the *only* thermodynamic input), both sectors satisfy their FRW
continuity equations, and the boundary data (plasma dof `2+4 → 2` across e±
annihilation, shared temperature at decoupling). Compared with
`EntropyConservationFRW.dilution_from_frw`, the Euler and Gibbs–Duhem
hypotheses are gone — they are theorems of the potential structure. -/
theorem dilution_from_potential
{P s : ℝ → ℝ} {T a Tν : ℝ → ℝ} {sT T' a' Tν' ρν' : ℝ → ℝ}
{t₁ t₂ : ℝ} {T₁ Tγ αν : ℝ}
(hTt : ∀ t, T t ≠ 0) (hαν : αν ≠ 0) (hTνt : ∀ t, Tν t ≠ 0)
(ha₂ : a t₂ ≠ 0) (hTγ : Tγ ≠ 0)
(hP : ∀ t, HasDerivAt P (s (T t)) (T t))
(hs : ∀ t, HasDerivAt s (sT t) (T t))
(hT : ∀ t, HasDerivAt T (T' t) t) (ha : ∀ t, HasDerivAt a (a' t) t)
(hTν : ∀ t, HasDerivAt Tν (Tν' t) t)
(hρν : ∀ t, HasDerivAt (fun u => αν * Tν u ^ 4) (ρν' t) t)
(hcont : ∀ t, a t * (T t * sT t * T' t)
= -3 * a' t * (energyOf P s (T t) + P (T t)))
(hcontν : ∀ t, a t * ρν' t
= -3 * a' t * (αν * Tν t ^ 4 + αν * Tν t ^ 4 / 3))
(hbefore : s (T t₁) = NeutrinoDilution.radiationEntropy 2 4 T₁)
(hafter : s (T t₂) = NeutrinoDilution.radiationEntropy 2 0 Tγ)
(hshare : Tν t₁ = T₁) :
(Tν t₂ / Tγ) ^ 3 = 4 / 11 := by
-- Adiabaticity of the coupled sector: derived from the potential structure.
have hcons : NeutrinoDilution.radiationEntropy 2 4 T₁ * a t₁ ^ 3
= NeutrinoDilution.radiationEntropy 2 0 Tγ * a t₂ ^ 3 := by
have h := potential_entropy_constant hTt hP hs hT ha hcont t₁ t₂
rw [hbefore, hafter] at h
exact h
-- Free streaming of the neutrino sector (derived in EntropyConservationFRW).
have hfree : a t₂ * Tν t₂ = a t₁ * T₁ := by
have h := EntropyConservationFRW.radiation_aT_constant hαν hTνt hTν ha
hρν hcontν t₂ t₁
rw [hshare] at h
exact h
exact NeutrinoDilution.dilution_from_entropy_conservation ha₂ hTγ hcons hfree
What this page does not claim
The declaration does not prove that any particular physical system has a pressure potential; that remains a modeling assumption. The grand-canonical form of the plasma pressure at the boundaries is an input, though its integrals are derived. The Friedmann equations behind the continuity equation are discharged separately, not derived here.
Verify this page
Every tagged claim above names its theorem. To check one yourself rather than trust this page, elaborate the source module with Lean 4 and audit its axiom basis:
$ lake env lean IndisputableMonolith/Cosmology/GrandPotential.lean
expected axiom basis: [propext, Classical.choice, Quot.sound] (the Lean kernel's standard three; no RS-specific axioms)
A page whose claims cannot be reproduced this way does not ship. In production, every anchor links to the exact declaration in the public source release, and this block carries the build receipt for the page itself.
Derived articles
This page is generated by a question-recursion engine: the questions its answers raise become the next pages. The current agenda, with open targets marked red:
- What physical systems beyond the massless Bose/Fermi plasma satisfy the pressure potential structure?
- How does the potential structure generalize to nonzero chemical potential?
- What boundary data beyond the e± annihilation step are needed for the dilution result?
- Does the potential structure extend to interacting fluids beyond the ideal gas case?
MACHINE LAYER · GROUNDED CLAIM TABLE · CLICK TO EXPAND
THEOREM potential_gibbs_duhem · IndisputableMonolith/Cosmology/GrandPotential.lean
/-- **Gibbs–Duhem relation (derived).** Along any temperature trajectory `T(t)`, the pressure obeys `p′ = s(T)·T′`: this is the chain rule applied to `s = dP/dT`, not an independent postulate. -/ theorem potential_gibbs_duhem {P s T : ℝ → ℝ} {T' t : ℝ} (hP : HasDerivAt P (s (T t)) (T t)) (hT : HasDerivAt T T' t) : HasDerivAt (fun u => P (T u)) (s (T t) * T') t := by simpa [Function.comp] using hP.comp t hTThe Gibbs-Duhem relation is exactly the chain rule applied to the composition P(T(t)). potential_gibbs_duhem · IndisputableMonolith/Cosmology/GrandPotential.leanTHEOREM potential_euler · IndisputableMonolith/Cosmology/GrandPotential.lean
/-- **Euler relation (derived).** `T·s = ρ + P` is an algebraic identity of the Legendre-transform structure — not an independent equilibrium postulate. -/ theorem potential_euler (P s : ℝ → ℝ) (x : ℝ) : x * s x = energyOf P s x + P x := by simp only [energyOf] ringThe Euler relation T·s = ρ + P is an algebraic identity of the Legendre-transform structure. potential_euler · IndisputableMonolith/Cosmology/GrandPotential.leanTHEOREM energy_deriv · IndisputableMonolith/Cosmology/GrandPotential.lean
/-- **Fundamental relation `dρ = T·ds` (derived).** The energy density of a potential fluid has temperature derivative `ρ′(T) = T·s′(T)`: differentiating `ρ = T·s − P` gives `s + T·s′ − s`. -/ theorem energy_deriv {P s : ℝ → ℝ} {sT x : ℝ} (hP : HasDerivAt P (s x) x) (hs : HasDerivAt s sT x) : HasDerivAt (energyOf P s) (x * sT) x := by have hid : HasDerivAt (fun y : ℝ => y) 1 x := hasDerivAt_id x have hxs : HasDerivAt (fun y => y * s y) (1 * s x + x * sT) x := hid.mul hs have h : HasDerivAt (fun y => y * s y - P y) (1 * s x + x * sT - s x) x := hxs.sub hP have hval : 1 * s x + x * sT - s x = x * sT := by ring rw [hval] at h exact hThe fundamental relation dρ = T·ds follows from differentiating ρ = T·s − P. energy_deriv · IndisputableMonolith/Cosmology/GrandPotential.leanTHEOREM potential_entropy_conserved · IndisputableMonolith/Cosmology/GrandPotential.lean
/-- **THEOREM (entropy conservation from the potential alone).** For a fluid whose pressure is a differentiable potential with `s = dP/dT` — the definition of local equilibrium at zero chemical potential — the FRW continuity equation forces `d/dt (s·a³) = 0`. The Euler and Gibbs–Duhem hypotheses of `EntropyConservationFRW.comoving_entropy_conserved` are *derived* here (`potential_euler`, `potential_gibbs_duhem`), not assumed. -/ theorem potential_entropy_conserved {P s : ℝ → ℝ} {T a : ℝ → ℝ} {sT T' a' t : ℝ} (hTt : T t ≠ 0) (hP : HasDerivAt P (s (T t)) (T t)) (hs : HasDerivAt s sT (T t)) (hT : HasDerivAt T T' t) (ha : HasDerivAt a a' t) (hcont : a t * (T t * sT * T') = -3 * a' * (energyOf P s (T t) + P (T t))) : HasDerivAt (fun u => s (T u) * a u ^ 3) 0 t := EntropyConservationFRW.comoving_entropy_conserved hTt (potential_energy_deriv hP hs hT) (potential_gibbs_duhem hP hT) (potential_entropy_deriv hs hT) ha hT (fun u => potential_euler P s (T u)) rfl hcontFor a fluid whose pressure is a differentiable potential with s = dP/dT, the FRW continuity equation forces d/dt (s·a³) = 0. potential_entropy_conserved · IndisputableMonolith/Cosmology/GrandPotential.leanTHEOREM dilution_from_potential · IndisputableMonolith/Cosmology/GrandPotential.lean
/-- **CAPSTONE (dilution from the potential).** `(T_ν/T_γ)³ = 4/11` from: the coupled sector has a pressure potential with `s = dP/dT` (local equilibrium, the *only* thermodynamic input), both sectors satisfy their FRW continuity equations, and the boundary data (plasma dof `2+4 → 2` across e± annihilation, shared temperature at decoupling). Compared with `EntropyConservationFRW.dilution_from_frw`, the Euler and Gibbs–Duhem hypotheses are gone — they are theorems of the potential structure. -/ theorem dilution_from_potential {P s : ℝ → ℝ} {T a Tν : ℝ → ℝ} {sT T' a' Tν' ρν' : ℝ → ℝ} {t₁ t₂ : ℝ} {T₁ Tγ αν : ℝ} (hTt : ∀ t, T t ≠ 0) (hαν : αν ≠ 0) (hTνt : ∀ t, Tν t ≠ 0) (ha₂ : a t₂ ≠ 0) (hTγ : Tγ ≠ 0) (hP : ∀ t, HasDerivAt P (s (T t)) (T t)) (hs : ∀ t, HasDerivAt s (sT t) (T t)) (hT : ∀ t, HasDerivAt T (T' t) t) (ha : ∀ t, HasDerivAt a (a' t) t) (hTν : ∀ t, HasDerivAt Tν (Tν' t) t) (hρν : ∀ t, HasDerivAt (fun u => αν * Tν u ^ 4) (ρν' t) t) (hcont : ∀ t, a t * (T t * sT t * T' t) = -3 * a' t * (energyOf P s (T t) + P (T t))) (hcontν : ∀ t, a t * ρν' t = -3 * a' t * (αν * Tν t ^ 4 + αν * Tν t ^ 4 / 3)) (hbefore : s (T t₁) = NeutrinoDilution.radiationEntropy 2 4 T₁) (hafter : s (T t₂) = NeutrinoDilution.radiationEntropy 2 0 Tγ) (hshare : Tν t₁ = T₁) : (Tν t₂ / Tγ) ^ 3 = 4 / 11 := by -- Adiabaticity of the coupled sector: derived from the potential structure. have hcons : NeutrinoDilution.radiationEntropy 2 4 T₁ * a t₁ ^ 3 = NeutrinoDilution.radiationEntropy 2 0 Tγ * a t₂ ^ 3 := by have h := potential_entropy_constant hTt hP hs hT ha hcont t₁ t₂ rw [hbefore, hafter] at h exact h -- Free streaming of the neutrino sector (derived in EntropyConservationFRW). have hfree : a t₂ * Tν t₂ = a t₁ * T₁ := by have h := EntropyConservationFRW.radiation_aT_constant hαν hTνt hTν ha hρν hcontν t₂ t₁ rw [hshare] at h exact h exact NeutrinoDilution.dilution_from_entropy_conservation ha₂ hTγ hcons hfreeThe neutrino dilution (Tν/Tγ)³ = 4/11 follows from the pressure potential plus boundary data. dilution_from_potential · IndisputableMonolith/Cosmology/GrandPotential.lean