FA-91665 / Digital signal filters / Member archive
Forward-backward filter pads with an even mirror · case 05
A ramp input gets a kink at the edges and the filtered ends droop.
Case contract
Input [taps, samples] (integers). Zero-phase filtering: pad = min(3 (len(taps) - 1), len - 1); extend with odd reflection about each end (2 x[0] - x[i] for i = pad..1 before, 2 x[-1] - x[n-1-i] for i = 1..pad after); filter forward with zero initial state, reverse, filter again, reverse, and return the middle len samples.
Why this case matters
Forward-backward filtering is used for offline zero-phase smoothing; padding and reversal slips create edge transients and phase shift.
One recorded failure
Sample boundary fixtureThis sample comes from the broken implementation of a controlled reproducer.
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| regression: random filtfilt 14 | [27, 8] | [-53, -12] | Failed |
MEMBER ARCHIVE
The complete case is available to members.
This record includes three runnable implementations, regression fixtures, execution results, and source hashes.
Member access is invitation-based. Sign in with your invited account to inspect the sources.
Sign in to the archive ↗