Reconstructing the gravitational-wave background detection — the way NANOGrav did it — watching the quadrupolar correlation curve emerge, pair by pair, from data that shows nothing in any single pulsar.
A GW background imprints no signal on any individual pulsar — only on the correlations between pairs. This project makes that emergence visible.
A pulsar timing array detects a gravitational-wave background not in any individual pulsar, but in the correlations between pairs of pulsars. A real GW background imprints a specific quadrupolar pattern — the Hellings–Downs curve — on how strongly two pulsars' timing residuals correlate as a function of the angle between them.
No clock error, ephemeris error, or per-pulsar noise process can imitate that shape. This is what makes the NANOGrav 15-year result a genuine detection and not a systematic artifact.
This repository does two things: first, it injects a known GWB plus NANOGrav-realistic noise into 67 synthetic pulsars and recovers the HD curve from scratch. Second, it runs the NANOGrav collaboration's own optimal-statistic code on the real 15-year data — the real white-noise parameters and the real MCMC presampled chain.
The pipeline follows the genuine NANOGrav methodology, step by step. See docs/METHODS.md for the full physics and statistics walkthrough.
Each pulsar's residuals still carry spin, astrometric, and binary parameters. These are removed analytically by projecting onto the null space of the timing-model design matrix — the same linear operation enterprise performs internally.
Pulsars are observed at different, irregular epochs, so residuals are projected onto a common Fourier basis, inverse-variance weighted by TOA uncertainties.
For every pulsar pair, the optimal statistic forms a noise-marginalized estimate of the correlation ρab. This is an estimator of A² · Γab, where Γab is the Hellings–Downs value for that pair and A² the GW background amplitude.
The real intrinsic red noise of each pulsar is marginalized over using a presampled MCMC chain (curn_14f_pl_vg.core) from the NANOGrav release. This step separates a genuine detection from an artifact.
Converting a power-spectral density to a time-domain realization requires careful FFT normalization. The simulation includes an assertion verifying that the realized RMS matches the integrated PSD — getting the factor of N wrong would silently rescale every noise component.
Simulation and real-data results are consistent with the published NANOGrav 15-year detection.
Injects a known GWB + NANOGrav-realistic noise, then recovers the Hellings–Downs curve and amplitude posterior. Detection significance is higher than the real ~3.5–4σ because the noise model is known exactly — the idealized upper bound.
Reproduces the published 2,211-pair Hellings–Downs detection at ~3.5–4σ on the real NANOGrav 15-year data, real white-noise parameters, and real presampled red-noise MCMC chain.
S/N grows with the number of pulsar pairs (≈ N²). A subset genuinely yields a lower-significance curve — that is real physics, not a bug.
| Available RAM | Pulsars | Pairs | Significance | Notes |
|---|---|---|---|---|
| ≥ 7.5 GB | 67 (full) | 2,211 | ~3.5–4σ | Published result |
| 5–7.5 GB | 45 | 990 | reduced | Subset |
| 3.5–5 GB | 30 | 435 | reduced | Subset |
| < 3.5 GB | 22 | 231 | reduced | Minimum useful |
Two paths: a self-contained simulation (~2 minutes, no data needed), and the full real-data pipeline with the NANOGrav 15-year dataset.
This repository contains no NANOGrav data. setup.sh downloads it from the NANOGrav collaboration's public repository. If you use the data, please cite:
enterprise_extensions