feat(Cosmology): comoving distance, redshift, Hubble-Lemaitre law, transverse distance and horizons - #1639
feat(Cosmology): comoving distance, redshift, Hubble-Lemaitre law, transverse distance and horizons#1639KevorkianPhilippe wants to merge 58 commits into
Conversation
Adds to Physlib/Cosmology/FLRW/Solutions.lean the de Sitter scale factor deSitterScaleFactor, its time derivatives, and the lemmas deSitterScaleFactor_firstOrderFriedmann, deSitterScaleFactor_secondOrderFriedmann, hubbleConstant_deSitterScaleFactor and decelerationParameter_deSitterScaleFactor, resolving the first TODO of the file. Also deriv_comp_val, the time derivative of a curve given as a function of the time coordinate. Generated with Claude Code under human supervision (see AI-POLICY.md). Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
Adds to Physlib/Cosmology/FLRW/Solutions.lean the power-law scale factor powerLawScaleFactor with its derivatives, Hubble and deceleration parameters, the density powerLawDensity it imposes, and the radiation-dominated (radiationScaleFactor, radiationDensity, radiationPressure) and Einstein-de Sitter (einsteinDeSitterScaleFactor, einsteinDeSitterDensity) instances with their Friedmann lemmas, q and H(t0), resolving two TODOs of the file. Also deriv_eq_of_hasDerivAt. Generated with Claude Code under human supervision (see AI-POLICY.md). Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
Adds to Physlib/Cosmology/FLRW/Solutions.lean the Milne scale factor milneScaleFactor with its Friedmann lemmas (k = -1, empty universe) and q = 0, the density cosmologicalConstantDensity, and the equilibrium relations of the Einstein static universe: einsteinStatic_density (rho = 2 rho_Lambda), einsteinStatic_curvature (k c^2 / a^2 = 4 pi G rho) and einsteinStatic_curvature_pos. The curvature of the Milne model and the instability of the static universe stay as narrowed TODOs. Generated with Claude Code under human supervision (see AI-POLICY.md). Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
…edmann equations Adds to Physlib/Cosmology/FLRW/MatterContent.lean the predicate ContinuityEquation, the derivative of the first-order Friedmann equation (deriv_firstOrderFriedmann), the derivation of the continuity equation from the two Friedmann equations (continuityEquation_of_friedmann) and the converse derivation of the second-order equation from the first-order and continuity equations (secondOrderFriedmann_of_continuityEquation), resolving two TODOs of the file. Also hasDerivAt_mk_of_differentiableAt, the bridge from a time derivative to HasDerivAt. Generated with Claude Code under human supervision (see AI-POLICY.md). Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
…cosmological constant as a fluid Adds to Physlib/Cosmology/FLRW/MatterContent.lean barotropicPressure, the density scaling law density_scaling with its converse continuityEquation_of_scaling and the dust, radiation and vacuum specialisations, and cosmologicalConstantDensity and cosmologicalConstantPressure with firstOrderFriedmann_iff_lambdaFluid, secondOrderFriedmann_iff_lambdaFluid and cosmologicalConstantPressure_eq_barotropic, resolving three TODOs. Moves cosmologicalConstantDensity from Solutions.lean, which now imports MatterContent. Generated with Claude Code under human supervision (see AI-POLICY.md). Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
… function and age Adds to Physlib/Cosmology/FLRW/DensityParameters.lean criticalDensity, densityParameter, curvatureDensityParameter and lambdaDensityParameter, the closure relation densityParameter_add_lambda_add_curvature (and its Lambda = 0 form), the reduced Hubble function reducedHubble of the standard model with sq_hubbleConstant_eq_reducedHubble and hubbleConstant_eq_reducedHubble, the age of the universe age with age_eq, and the equality scale factors equalityScaleFactorRadiationMatter and equalityScaleFactorMatterLambda with their specifications, resolving the seven TODOs of the file. Generated with Claude Code under human supervision (see AI-POLICY.md). Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
…ion parameter, eternal expansion and Big-Bang bound Adds to Physlib/Cosmology/FLRW/Dynamics.lean the four energy conditions with their implications, deriv_deriv_pos_iff (acceleration iff the strong energy condition fails), decelerationParameter_eq_sum (q = 1/2 sum Omega_i (1 + 3 w_i)) and its LambdaCDM form, deriv_ne_zero_of_friedmann and deriv_pos_of_friedmann (eternal expansion for k <= 0), deriv_deriv_nonpos_of_friedmann, scaleFactor_nonpos_of_decelerating and exists_scaleFactor_eq_zero (the Big-Bang bound t0 - 1/H0 and the existence of a zero of the scale factor), and deSitterScaleFactor_pos, resolving the five TODOs of the file. Generated with Claude Code under human supervision (see AI-POLICY.md). Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
…ansverse distance and horizons Adds to Physlib/Cosmology/FLRW/Distances.lean the comoving distance comovingDistance with deriv_comovingDistance (fundamental theorem of calculus), the redshift with deriv_redshift and the change-of-variables relation deriv_comovingDistance_eq_mul_deriv_redshift, the proper distance with the Hubble-Lemaitre law deriv_properDistance, the Hubble radius with deriv_properDistance_eq_iff, spatialGeometryOfCurvature and transverseComovingDistance with its three closed forms, the particle and event horizons and particleHorizon_einsteinDeSitter. Removes the change-of-variable TODO of Basic.lean, which deriv_eq_mul_hubbleConstant, deriv_redshift and deriv_comovingDistance_eq_mul_deriv_redshift resolve. Generated with Claude Code under human supervision (see AI-POLICY.md). Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
|
Thank you for this pull-request (PR). If this is your first PR, welcome to the community! Below is what will happen next. Please read carefully if you are not familiar with the process. You may open other PRs while this one is being reviewed, and can stack PRs on top of each other, so don't let these steps slow you down.
Tip: The easiest way to get have a fast review is to submit a PR that is small and self-contained, and has clear documentation explaining why things are the way they are in your chages. If you have any problems or questions, please reach out to the community on the Zulip. |
Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
…ive bridges next to their definition Applies the review remarks of leanprover-community#1642 across the series: no isolated general-purpose lemma, and lemmas about the time derivative live in SpaceAndTime/Time/Derivatives.lean. Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
…ive bridges next to their definition Applies the review remarks of leanprover-community#1642 across the series: no isolated general-purpose lemma, and lemmas about the time derivative live in SpaceAndTime/Time/Derivatives.lean. Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
…ive bridges next to their definition Applies the review remarks of leanprover-community#1642 across the series: no isolated general-purpose lemma, and lemmas about the time derivative live in SpaceAndTime/Time/Derivatives.lean. Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
…ive bridges next to their definition Applies the review remarks of leanprover-community#1642 across the series: no isolated general-purpose lemma, and lemmas about the time derivative live in SpaceAndTime/Time/Derivatives.lean. Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
…ive bridges next to their definition Applies the review remarks of leanprover-community#1642 across the series: no isolated general-purpose lemma, and lemmas about the time derivative live in SpaceAndTime/Time/Derivatives.lean. Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
…ive bridges next to their definition Applies the review remarks of leanprover-community#1642 across the series: no isolated general-purpose lemma, and lemmas about the time derivative live in SpaceAndTime/Time/Derivatives.lean. Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
…ive bridges next to their definition Applies the review remarks of leanprover-community#1642 across the series: no isolated general-purpose lemma, and lemmas about the time derivative live in SpaceAndTime/Time/Derivatives.lean. Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
…munity#1632, on which this branch is stacked)
…munity#1632, on which this branch is stacked)
…ity#1632, on which this branch is stacked)
…ity#1632, on which this branch is stacked)
…utions The general power-law solution a = (t / t0) ^ n is stated inline in the lemmas, quantified over n; the defs powerLawScaleFactor, powerLawDensity, radiationDensity, radiationPressure and einsteinDeSitterDensity and the two _eq glue lemmas are removed, the densities and the pressure now appear in the theorem statements, and radiationScaleFactor and einsteinDeSitterScaleFactor are defined directly. Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
…ns is a Time t0 : Time instead of a real number in the power-law, radiation-dominated and Einstein-de Sitter solutions (so H(t0) is stated at t0 itself), and docstrings saying that t0 is the normalisation epoch a(t0) = 1, that the Big Bang sits at the origin t.val = 0 of the time chart, and that the values for t.val <= 0 are junk. Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
# Conflicts: # Physlib/Cosmology/FLRW/Solutions.lean
…in of the time chart Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
The density of the Einstein static universe is stated as rho = Lambda c^2 / (4 pi G); the def cosmologicalConstantDensity is dropped from this file, the cosmological constant as a w = -1 fluid being the matter-content TODO of Physlib.Cosmology.FLRW.MatterContent. Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
# Conflicts: # Physlib/Cosmology/FLRW/Solutions.lean # Physlib/SpaceAndTime/Time/Derivatives.lean
# Conflicts: # Physlib/Cosmology/FLRW/MatterContent.lean # Physlib/Cosmology/FLRW/Solutions.lean
# Conflicts: # Physlib/Cosmology/FLRW/Solutions.lean
# Conflicts: # Physlib/Cosmology/FLRW/Solutions.lean
# Conflicts: # Physlib/Cosmology/FLRW/Solutions.lean
… t0 : Time Follows the review of leanprover-community#1633: einsteinDeSitterScaleFactor now takes the normalisation epoch as a Time and is defined directly, without powerLawScaleFactor. Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
…tOrderFriedmann at t : Time Review of leanprover-community#1635 by doxtor6. Time.hasDerivAt_mk_of_differentiableAt is stated at t : Time (derivative at t.val) instead of at the constructor form with a real parameter, so that callers no longer destructure t; deriv_firstOrderFriedmann is stated at t : Time as well and destructures inside its proof, and the two theorems of MatterContent.lean no longer do. Time.deriv_comp_val is dropped: it is the special case f := fun s => g s.val of Time.deriv_eq_of_hasDerivAt, which replaces it in Solutions.lean (its only user). The two surviving bridges are listed in the key results of Time/Derivatives.lean. Nits: continuityEquation_of_friedmann only needs G ≠ 0; the non-vanishing hypothesis of secondOrderFriedmann_of_continuityEquation is named ha'; the overview names the bridge the proofs actually use. Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
…rgy equation, API map Review of leanprover-community#1635 by doxtor6. The non-independence TODO is narrowed rather than deleted (derive it from the contracted Bianchi identity once the FLRW metric exists), and a TODO records the bridge to fluid dynamics: ContinuityEquation is the fluid energy equation for the Hubble flow, which needs an energy equation in Physlib.FluidDynamics first. The FLRW TODO of Basic.lean and the overview of MatterContent.lean record the design point that the two Friedmann equations are the primitive pair (where the scale factor is stationary, the first-order and continuity equations leave the pressure unconstrained). API-map.yaml: the continuity-equation requirement is split from the equation of state and marked done. Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
…sity_scaling, API map Follows the review of leanprover-community#1635: no statement of the API exposes the constructor form of a time any more. hasDerivAt_mul_rpow_of_continuityEquation, a helper stated on the real curve obtained through the time chart and used once, is inlined into density_scaling. API-map.yaml: the equation-of-state requirement is marked done and the cosmological constant as a fluid is recorded. Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
…eanprover-community#1634) into flrw-dynamics-6
…ard model Follows the review of leanprover-community#1635, which asked for API-map.yaml to track what each PR of the series completes: two requirements for DensityParameters.lean (critical density, density parameters and closure relation; reduced Hubble function, age and equality scale factors), and the overview no longer lists that module as containing only TODO items. Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
…ng bound Follows the review of leanprover-community#1635, which asked for API-map.yaml to track what each PR of the series completes: two requirements for Dynamics.lean (energy conditions, acceleration criterion and deceleration parameter; eternal expansion and the Big-Bang bound), and the overview no longer lists that module as containing only TODO items. Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
leanprover-community#1634) into flrw-distances-8
…distances and the horizons Follows the review of leanprover-community#1635, which asked for API-map.yaml to track what each PR of the series completes: two requirements for Distances.lean (comoving distance, redshift and the Hubble-Lemaitre law; transverse comoving distance and the horizons), and the overview no longer lists that module as containing only TODO items. Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
AI disclosure
AI disclosure. This PR was generated with Claude Fable 5.1 (Claude Code) under my
supervision, following
AI-POLICY.mdandAGENTS.md. I have read every definition and lemmastatement and vouch that they state what the docstrings say. The statements were fixed before
the proofs were written and checked symbolically (sympy) against the Friedmann equations of
Physlib.Cosmology.FLRW.Basic; no textbook is cited, the TODO items of the file are thespecification.
Stacked on #1638 (
flrw-dynamics-7): the diff includes the earlier commits of this series; only the last commit is new here.Resolves six of the ten TODOs of
Physlib/Cosmology/FLRW/Distances.leanand thechange-of-variable TODO of
Basic.lean(the only change toBasic.lean: that TODO is removed).Declarations added (namespace
Cosmology.FLRW.FriedmannEquation):comovingDistance:χ = c ∫_t^{t₀} dτ / a;deriv_comovingDistance:∂ₜ χ = - c / a(fundamental theorem of calculus,
acontinuous and positive).redshift:1 + z = a(t₀) / a(t);one_add_redshift;deriv_redshift:∂ₜ z = -(1 + z) H;deriv_eq_mul_hubbleConstant:∂ₜ a = a H;deriv_comovingDistance_eq_mul_deriv_redshift:∂ₜ χ = (c / (a(t₀) H)) ∂ₜ z, the relationdχ = c dz / Hbehind the distance integrals inz.properDistance,deriv_properDistance(Hubble-Lemaître law∂ₜ D = H D);hubbleRadius,deriv_properDistance_eq_iff(recession velocitycexactly atR_H).spatialGeometryOfCurvature,transverseComovingDistance, and the closed formstransverseComovingDistance_of_pos,_zero,_of_neg(curvature radius1 / √|K|).particleHorizon,eventHorizon,particleHorizon_einsteinDeSitter(3 c t₀^(2/3) t^(1/3)).Not included, said in the module docstring: the redshift law
E ∝ 1 / aof a photon (needs themetric and null geodesics) and
χ(z)as an integral inz(needsHas a function ofz).Reviewer map: A (FTC), B (redshift and change of variables), C, D (conventions of
SpatialGeometry), E.Update (Sept 11). Applied the review remarks of #1642 across the series: no isolated general-purpose lemma (the one-off
HasDerivAtandrpowhelpers are inlined in the proofs that used them), and the three small bridges betweenTime.derivand Mathlib'sHasDerivAtnow live next to the definition of the time derivative, inPhyslib/SpaceAndTime/Time/Derivatives.lean(deriv_comp_val,deriv_eq_of_hasDerivAt,hasDerivAt_mk_of_differentiableAt, each introduced by the first PR of the series that needs it). Section letters shifted accordingly.Update (Sept 17). Merged the review of #1635 (statements at
t : Time,Time.deriv_comp_valdropped in favour ofTime.deriv_eq_of_hasDerivAt);API-map.yamlnow records what this PR completes.🤖 Generated with Claude Code