# AC64 propagation fit and repeat statistics

Two questions, two frozen inputs:

1. Does one bright CHIME burst (FRB 20180725A) hide a plasma-lens echo?
   A constrained propagation fit on the frozen Catalog 1 dynamic spectrum.
2. Could a lens produce the repeat pattern of FRB 20180916B?
   Interval statistics from the frozen Catalog 2 rows, and what a lens would need.

## Run

    python3 reproduce.py          # recompute and compare with expected-outputs.json (exit 0 on pass)
    python3 reproduce.py --write  # overwrite expected-outputs.json

Tested with Python 3.9.6, numpy 2.0.2 and scipy 1.13.1. A full run takes under a minute.
Put chime-frb20180725a-intensity.json and r3-catalog2-rows.csv in the same folder as the scripts.

## Files

| File | Kind | Role |
| --- | --- | --- |
| chime-frb20180725a-intensity.json | observed | CHIME/FRB Catalog 1 intensity cutout of FRB 20180725A, 64 channels x 38 bins, frozen by the AC06 tutorial. |
| r3-catalog2-rows.csv | observed | The 142 FRB 20180916B rows of chimefrbcat2.csv (release 20251231), 22 columns. |
| propagation_fit.py | analysis | One burst (H0) against one burst plus a lens copy. The copy is chromatic (delay as nu^-2) or achromatic. |
| repeat_statistics.py | analysis | Waiting times, sub-burst offsets, hour angles, a Weibull fit, a window-only Poisson check, the 16.35-day fold and the lens a given delay would need. |
| reproduce.py | driver | Runs both scripts and compares every number with expected-outputs.json. |
| expected-outputs.json | output | Values of the last --write run and the software versions. |
| provenance.json | record | Sources, checksums, data kinds and the CHIME citation. |

## Units and conventions

- Propagation fit: time in ms, frequency in MHz, DM in pc cm^-3. Delays are quoted at 600 MHz.
  Dispersion constant 4.148808 ms GHz^2 per pc cm^-3. Scattering tau(nu) = tau_600 (nu / 600 MHz)^-4.
- Catalog 2 arrival times: column mjd_400, topocentric UTC referenced to 400.1953125 MHz.
  They are not barycentric. The published period (CHIME/FRB 2020, arXiv:2001.10275v5) was
  found with barycentric times at infinite frequency, so the fold here is a consistency check,
  not a re-measurement.
- Rows with excluded_flag = 1 (non-nominal telescope operation) are dropped. One event per TNS name;
  sub-burst offsets are measured from the earliest sub-burst of the event.
- Lens requirements use Cordes et al. 2017 (arXiv:1703.06580v1): alpha = 3430 DM D_kpc / (nu_GHz a_AU)^2
  (Eq. 3), t_DM0 = 4.149 ms DM / nu_GHz^2 (Eq. 14), EM = a n_e (Eq. 25) and
  tau_ff = 3.4e-7 nu^-2.1 T4^-1.32 EM (Eq. 26) with T4 = 1. The longest gain-one echo sits at u^2 = 1/2,
  with delay t_DM0 alpha / (2e). The lens is taken as three Fresnel scales wide, a = 3 r_F, so geometric
  optics still applies.

## Results

Propagation fit (H0): arrival 12.61 ms, width sigma 0.601 ms, tau_600 1.147 ms, residual DM 0.101,
chi^2 2478.8 for 1940 degrees of freedom (reduced 1.28). 54 channels are used and 10 are fully masked.

| Copy model | max delta chi^2 | white-noise null 95th / 99th | false alarm probability |
| --- | --- | --- | --- |
| chromatic, delay 0.5 to 9.5 ms at 600 MHz | 0.63 | 5.55 / 7.74 | 0.67 |
| achromatic, delay 0.5 to 20 ms | 1.33 | 7.51 / 11.45 | 0.81 |

No echo is detected. The best grid point sits on the grid edge (smallest ratio 0.05), as expected when
there is no signal.

Injections (chromatic copy added to the best H0 model, white noise from the off-pulse scatter):

| injected delay, ratio | delta chi^2 | recovered delay, ratio | refit tau_600 |
| --- | --- | --- | --- |
| 4.0 ms, 0.50 | 23.8 | 4.3 ms, 0.15 | 3.36 ms |
| 4.0 ms, 0.15 | 5.97 | 4.8 ms, 0.05 | 2.01 ms |
| 0.5 ms, 0.50 | 6.32 | 8.3 ms, 0.05 | 1.32 ms |

The first row is the key failure case: the delay is found, but the refit scattering tail absorbs most of
the copy, so the ratio comes back three times too small. A scattering tail and a delayed copy are partly
degenerate at this time resolution. The last row shows a copy closer than the 0.98 ms sampling is not
resolved at all.

Repeat statistics: 104 events from 131 nominal rows, MJD 58410.34 to 60125.65.

- Waiting times from 36.3 s to 112.7 days, median 14.9 days. 22 are under an hour, 21 between an hour and
  a day, 60 longer than a day. Sub-burst offsets inside one event: 0.10 to 68 ms (27 offsets).
- Every arrival is within 0.42 h (95th percentile) of transit: CHIME sees the source only while it
  crosses the beam. Any gap statistic mixes the source with this window.
- A Weibull fit to all gaps gives k = 0.42. Purely random bursts seen only through the same windows
  give k = 0.60 to 0.84 (central 90 percent of 200 trials), so k = 0.42 means the bursts are more
  clustered than the window alone explains.
- Folding at 16.35 days puts 91 percent of events inside the published +-2.7 day window. The period
  uncertainty grows to about one cycle at the last event, so later data cannot be phased with the
  2020 ephemeris alone. A Rayleigh scan over 15.5 to 17.5 days peaks at 16.33 days.
- A lens that delays a copy by the shortest gap (36 s) needs alpha of about 4e5 and a source about 1.7e5
  lens radii off axis; free-free optical depth at 600 MHz is 0.37 (D = 1 pc) or 0.012 (D = 1 kpc).
  For a one-day echo it is 871 or 27.5; for the median gap, 13000 or 412. A lens dark enough to absorb
  its own echo cannot make it.

## Failure cases and limits

- The white-noise null ignores correlated residuals; the reduced chi^2 of 1.28 shows the burst model is
  not perfect. Rescaling the noise to the fit changes the false alarm probabilities only slightly
  (0.68 and 0.86).
- Only one copy is tested, with one ratio for all channels. Real lens gains change with frequency.
- The catalog times are topocentric and at 400 MHz. Barycentric correction changes times by up to
  about 8 minutes over a year, which matters for the fold but not for the gap distribution.
- The lens requirement assumes a single Gaussian lens, T = 10^4 K and a = 3 r_F. Other lens shapes or
  hotter gas change the numbers; they do not change that one lens gives at most three fixed delays.

## Citation

CHIME/FRB data: please cite the CHIME/FRB Collaboration, First CHIME/FRB Fast Radio Burst Catalog (2021),
DOI 10.11570/21.0007, for the cutout, and the Second CHIME/FRB Catalog, DOI 10.11570/25.0066, for the
Catalog 2 rows. No broader license is asserted for either data set.
