feat(physics): add cosmology module (FLRW model + distances + cosmic …#10
Open
backlundtransform wants to merge 1 commit into
Open
feat(physics): add cosmology module (FLRW model + distances + cosmic …#10backlundtransform wants to merge 1 commit into
backlundtransform wants to merge 1 commit into
Conversation
…time)
New Physics.Cosmology namespace — the next Tier 1 piece of the astro expansion.
- FlrwModel: a flat/curved FLRW cosmology specified by H0 (km/s/Mpc) and the
density parameters (curvature fixed by flatness). Provides:
* expansion history E(z) and H(z), scale factor, critical density ρ_c = 3H²/8πG;
* cosmological distances — comoving, transverse-comoving (sinh/sin for curvature),
luminosity, angular-diameter — and the distance modulus, via composite-Simpson
integration of dz/E(z);
* cosmic time — age of the universe, age at redshift z, and lookback time, via
the scale-factor integral.
* FlrwModel.Planck2018() factory for the concordance flat ΛCDM parameters.
- PhysicsConstants: add Megaparsec, CMB temperature, and the Planck mass/length/time.
- Document the module in Physics/README.md.
Validated against known values: age ≈ 13.8 Gyr, present critical density
≈ 8.5e-27 kg/m³, comoving distance at z=1 ≈ 3402 Mpc, distance modulus ≈ 44.2 at
z=1, exact Etherington duality D_L = (1+z)²·D_A. 13 new tests, all passing.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
…time)
New Physics.Cosmology namespace — the next Tier 1 piece of the astro expansion.
Validated against known values: age ≈ 13.8 Gyr, present critical density ≈ 8.5e-27 kg/m³, comoving distance at z=1 ≈ 3402 Mpc, distance modulus ≈ 44.2 at z=1, exact Etherington duality D_L = (1+z)²·D_A. 13 new tests, all passing.