Repairing real records

Session 8 · Fri Oct 16 · Book section 2.9

🩹

Today’s question

The archive hands you a broken record.

What may you repair — and what must stay broken?

This lecture in the literature

📖 The textbook: what filters and instrument responses actually do to a seismogram.

Scherbaum, F. (1996). Of Poles and Zeros: Fundamentals of Digital Seismology. Kluwer Academic Publishers.

Doing it right: how filter and baseline choices change the ground-motion numbers engineers build on.

Boore, D. M. & Bommer, J. J. (2005). Processing of strong-motion accelerograms: needs, options and consequences. Soil Dynamics and Earthquake Engineering, 25, 93–115.

A celebrated earthquake precursor, undone two decades later — the anomaly lived in the instrument, not the Earth.

Fraser-Smith, A. C., et al. (1990). Low-frequency magnetic field measurements near the epicenter of the Ms 7.1 Loma Prieta earthquake. Geophysical Research Letters, 17, 1465–1468. — Thomas, J. N., Love, J. J. & Johnston, M. J. S. (2009). On the reported magnetic precursor of the 1989 Loma Prieta earthquake. Physics of the Earth and Planetary Interiors, 173, 207–215.

Processing choices are science choices — the literature has celebrated artifacts and retracted precursors to prove it.

One healthy record, injured on purpose

  • Station UW.RATT (Washington), 100 Hz vertical — the M8.2 Chignik, Alaska earthquake, 2021-07-29
  • We add the injuries ourselves: a zero-filled gap, a 0.5 s clock error
  • The unbroken record stays as ground truth — every repair gets graded

Same honesty pattern as Wednesday’s b-value: plant the truth, then grade the method.

Two filters, one P wave

Causal filtering pushes the onset later (phase delay). Zero-phase keeps the time but leaks energy before the onset. Neither is wrong — each answers a different need.

The gap that rings

Zero-filling creates two step discontinuities. A step is broadband — the filter answers with its own ringing, and inside the gap it draws plausible-looking wiggles that are pure artifact.

The repair, graded

185× edge ringing vs local in-band signal — filtered across the gap

1.7× same measure after segment-wise filtering

Measured 0–2 s from the gap edges against the intact-record truth: ringing of 12,998 counts over a local signal of 70 counts RMS. Beyond 2 s, the segment-wise error falls to ~0.

Two orders of magnitude, and the residual damage is confined to ~2 s of filter memory — flag that guard interval in your metadata.

The clock that lies

A 0.5 s timing error leaves the waveform perfect and corrupts only the timestamps — invisible to the eye, fatal for phase picks. Cross-correlation reads it back exactly: +0.50 s.

Repair means confining the damage

  • Filter artifacts near onsets: know your filter — never interpret precursory wiggles
  • Gaps: filter segment-wise, leave the gap NaN — declared missing, not repaired
  • Guard intervals at segment edges, written into the metadata
  • Clock errors: measure with cross-correlation, correct the timestamps, log the correction

An honest record carries its scars and its repair log — that log becomes the data card in 2.13.

Three pathologies, three repairs

Pathology What it does The repair Where you’ll meet it
Filter phase moves or decorates the onset pick causal vs zero-phase for the task early warning vs tomography picks
Zero-filled gap edge ringing 185× local signal segment-wise filtering + guard interval telemetry dropouts, careless merges
Clock error timestamps lie, waveform looks fine cross-correlation lag, then correct + log GPS clock failures, ocean-bottom sensors

The unbroken record graded every number in this table — plant truth before you trust a repair.

Now run it yourself — open 2.9

  1. pixi run jupyter lab2.9_filtering_data.ipynb
  2. Reproduce the gap experiment; then move the gap under the surface waves and re-grade the ringing
  3. Change the band to 0.1–1 Hz: how long does the guard interval get?
  4. Add sub-sample precision to the clock recovery (parabola through the correlation peak)
  5. Your team’s data: which of the three pathologies applies? Write the one-line repair policy.

Monday: synthetic data with known truth, the detection floor (2.10–2.11) · Reading-arc stage 1 due Wed Oct 21