gravitational
Gravitational waves from nanohertz to terahertz, in one place: what they carry, how they travel, how sensitive every kind of detector is, and how far a detector can see. Strain conventions, noise curves, inspirals and binary pulsars, the black hole a merger leaves and how it rings, neutron-star tides, memory, the graviton's mass and number, stochastic backgrounds, high-frequency limits, lensing and cosmological distances, and the gravity of lab sources, each tested against published numbers. Pure Rust, SI units.
Install
Example: how far can Advanced LIGO see two neutron stars?
use ;
use ;
let = ;
let horizon = horizon;
let range = horizon / HORIZON_TO_RANGE;
println!;
Example: the strongest and the weakest
The brightest events radiate about a thousandth of the Planck luminosity c⁵/G; the oldest
confirmed prediction is the slow decay of a binary pulsar's orbit. A detectable wave holds about
10³⁶ gravitons per wavelength-sized cell, yet matter is so transparent that water absorbs it
over 10¹¹ Gpc.
use ;
use ;
assert!; // GW150914 at its peak
let pbdot = peters_pbdot;
println!; // −2.402e-12; measured −2.40263(5)e-12
println!; // 3.9e36
let water = viscous_damping.unwrap;
println!; // 2.6e11
Example: the ceiling on high-frequency waves
Any gravitational-wave background from the early Universe counts as extra radiation, so Big Bang nucleosynthesis and the CMB cap it. No detector built or proposed above 10 kHz reaches the cap.
use ;
let ceiling = hc_from_omega;
println!; // 1.3e-30
for limit in REGISTRY
Example: a gravity sensor as a wave detector
A wave of strain h stretches a baseline L, so two free masses feel a tidal acceleration ½ω²hL. Gradiometers, atom interferometers and satellite pairs all measure that; the baseline decides how well.
use ;
// AION-km: two strontium clouds 2 km apart (Badurina et al. 2020).
let aion = AtomGwDetector ;
println!; // 2.1e-21
// A GOCE-class gradiometer (10 mE/√Hz) read the same way: 5e-11 per √Hz at 0.1 Hz.
assert!;
What is inside
| Module | What it computes |
|---|---|
strain |
Ω_GW ↔ S_h ↔ h_c, with the one-sided and two-sided conventions made explicit (Moore, Cole & Berry 2015) |
cosmology |
Flat ΛCDM comoving, angular-diameter and time-delay distances; the six H0LiCOW lenses give back H₀ = 73.3 (Wong et al. 2020); Cosmology with curvature, CPL dark energy, radiation and exact massive neutrinos, the transverse and between-redshift angular-diameter distances, and PLANCK18 (icosmo, Kayser and astropy's Mathematica values; Planck's 100θ*) |
curves |
Advanced LIGO and Einstein Telescope fits (Sathyaprakash & Schutz 2009); LISA with galactic confusion (Robson, Cornish & Liu 2019); tabulated curves |
inspiral |
Chirp mass, time to merger, ISCO, the energy spectrum, matched-filter SNR, horizon and range (Chen et al. 2021); the Kerr ISCO with its energy and angular momentum, and the equatorial photon orbit (Bardeen, Press & Teukolsky 1972); the spin-aware ISCO frequency kerr_f_isco (Isoyama et al. 2014) |
energy |
The Planck luminosity, strain from luminosity, the circular-binary flux and the multipole flux coefficients (Blanchet), Peters' eccentricity enhancement and binary-pulsar decay, the Shapiro range, shape and delay (Kramer et al. 2021), the advance of periastron and the geodetic precession (Will 2014); the next-to-leading-order Shapiro delay, with lensing and Kopeikin & Schäfer's retardation (checked against an exact moving-mass delay), and the aberration terms (Kramer et al. 2021) |
ringdown |
Kerr quasinormal modes for l = 2, 3, 4, every m, three overtones, from the fits of Berti, Cardoso & Will 2006, checked against their exact tables; ringing frequency and damping time; qnm_exact, Leaver's continued fraction in Cook & Zalutskiy's form, Berti's Schwarzschild digits to 10⁻¹⁶ and all 693 BCW06 entries |
remnant |
The final spin (Hofmann, Barausse & Rezzolla 2016), the radiated energy (Barausse, Morozova & Rezzolla 2012) and the horizon area of a merger's black hole, for aligned spins; the precessing final spin and generic-spin radiated energy |
tides |
Neutron-star tidal deformability Λ and the binary Λ̃ the waveform measures, with GW170817's bounds (LVC 2019); the relativistic Love number from TOV and Postnikov's Riccati equation, with Read et al.'s SLy and AP4 piecewise polytropes |
lensing |
The isothermal sphere's Einstein radius (O'Riordan et al. 2025), microlensing magnification, centroid shift and lens mass (Sahu et al. 2025), the NFW halo (Wright & Brainerd 2000), and a registry of time-delay H₀ labelled assertive or conservative (TDCOSMO 2025); the critical surface density, NFW normalisation and Dutton–Macciò concentration, Lee et al.'s exact finite-source magnification, the H₀ measurements by method, and the OGLE-2011-BLG-0462 mass history |
memory |
The leading-order memory of a binary (Favata 2010) and its ramp in pulsar timing |
propagation |
Speed bounds from GW170817, graviton Compton wavelength, dispersion and delay with the current mass bounds, point-lens lensing in geometrical and wave optics (Takahashi & Nakamura 2003), viscous absorption with its validity check (Baym et al. 2017) |
quanta |
Graviton counts and occupation numbers, stimulated and spontaneous single-graviton rates and the optimal bar mass (Tobar et al. 2024), and a bar's absorption cross-section (Aguiar 2011) |
sgwb |
Power-law-integrated sensitivity curves (Thrane & Romano 2013), Hellings–Downs, pulsar-timing backgrounds (NANOGrav 2023), and the energy scale and background of inflation |
hf |
The cosmological ceiling, magnetic conversion of waves to photons (Ejlli et al. 2019), the plasma cut-off, cavity noise, source lines, and a registry of limits with their status (Aggarwal et al. 2025) |
detectors |
Gravity sensors as wave detectors: atom-interferometer strain response (Graham et al. 2016, Eq. 9), and the strain noise of gradiometers, optical clocks (Kolkowitz et al. 2016) and satellite pairs |
ultralight |
Ultralight dark matter as an oscillating signal: the Compton frequency mc²/h, the mass window of the mid-band between LISA and the ground detectors (MAGIS-100, AION), and the coherence length |
laboratory |
A beam's gravitational near field (Rätzel et al. 2016), waves from spinning bodies, wave energy flux, and the Newtonian calibrators of LIGO (Ross et al. 2021) and Virgo (Estevez et al. 2018) |
Applications
- Detector design. Horizon and range decide a detector's event rate, which is how
next-generation designs are argued;
examples/detector_range.rsworks it through. - Testing general relativity.
examples/binary_pulsar.rsreproduces the Hulse–Taylor orbital decay from published orbital elements. - Bounding a background.
sgwbandhfconvert between the strain, spectral density and energy-density conventions papers quote, andhf::REGISTRYcarries the published limits with their status. - Sizing a laboratory source.
laboratory::quadrupole_strainsays what a lab source radiates, andexamples/lab_hfgw.rssets it against the best detectors. - Multi-messenger timing.
propagationgives the speed bounds, dispersion and lensing delays.
How it is checked
Every formula is tested against numbers published in, or recomputed from, the papers above:
- Detectors: the LISA curve at five frequencies; the published peak strains of AION-10, AION-100, AION-km and AICE; Kolkowitz et al.'s clock strain.
- Binaries: the binary-neutron-star chirp mass, time to merger and ISCO; the decay of B1913+16 (to its quoted mass precision) and of the double pulsar; GW170817's spectral fluence; the double pulsar's periastron advance (to its 2PN term), Mercury's 42.98″ per century, S2's 12.1′ per orbit, the lunar de Sitter precession and Gravity Probe B's geodetic drift.
- Energy and quanta: the Planck luminosity; Blanchet's flux coefficients exactly; Tobar et al.'s rates and bar masses; Carney et al.'s occupation number; Aguiar's LSU bar cross-section.
- Propagation: GW170817's speed bounds; the graviton Compton wavelength against Bernus et al.; lensing magnifications and delays; viscous damping in water and air, and its refusal for a mantle.
- Backgrounds: NANOGrav's energy density; Hellings–Downs values; inflation's energy scale for r = 0.036, 0.034 and 0.01.
- The lab: the petawatt beam; the Misner–Thorne–Wheeler spinning rod; LIGO's rotor force (19.10 pN by direct summation) and Virgo's x f² = 3.3×10⁻¹⁴ m Hz²; Ejlli et al.'s photon-rate prefactor; an ADMX-like cavity.
All formulas are written from the papers, not translated from other codes, so the crate stays MIT-licensed. The research behind the newer modules is in the report on where gravity physics is still open.
One of eight crates in physica:
physica (all of them, plus cross-domain analogies) ·
metrology (constants) ·
geopotential (the gravity field) ·
gravimetry (missions and GRACE) ·
gravitational (waves) ·
gravitics (frontier gravity) ·
magnetics (magnetism and MHD) ·
plasmoid (fusion plasma).