◄ WORLD V · SONNY 5DART 312 · a helldive at the net

EXPONENTIAL MOVING AVERAGE one number that remembers everything and stores nothing — the past decays

An average that forgets gracefully. The exponential moving average carries a single number and blends each arrival: e ← e + α(x−e). Old samples do not vanish — they decay geometrically, their weight halving (at α=½) with every new value. So a single register holds a weighted memory of the entire stream, with no window to store and no history to keep. A correct windowed average must retain the last k values; the EMA retains one, and its memory reaches infinitely far back, just fainter. The analog version is an RC circuit; the digital version runs in every sensor, tracker, and trading screen.

THE TECHNIQUE e ← e + α(x−e); one register, infinite fading memory

A short stream. The demo folds each value into one register with α=½ — the whole past is remembered, nothing is stored: live demo


HISTORY & CREDIT exponential smoothing · Brown / Holt, 1950s

“To weight recent data you need a window.” — the EMA weights all of history, most-recent-heaviest, in a single number: the window is infinite and the storage is one. cited

1956 · Robert G. Brown — exponential smoothing for inventory forecasting.
1957–60 · Charles Holt and Peter Winters — extended it to trend and seasonality (Holt–Winters).
kin · the discrete twin of the RC low-pass filter; the same recurrence.
now · TCP RTT estimation, moving-average trading lines, sensor smoothing, momentum in optimizers.

Every sample echoes forever, each echo half the last. Total memory of the stream, held in one number. Brown / Holt-Winters

RECOMMEND FOR I-13 the fading average, one register, on the compiler

On the canonical compiler, streaming [10,20,30] with α=½ lands on ema = 22.5 — one register, the earlier values decayed but never discarded:

$ i13 run op_ema.i13 # e <- e + (x-e)/2 RUN OK · 89 step(s) · peak stack 5 · call depth 4 ema = 22.5 -- weighted memory of [10,20,30] in one number
Recommend: the EMA is a bounded summary that never lies about how much it remembers — a single register whose memory of the stream is infinite but fading. i13 folds [10,20,30] to 22.5 in one register. The supplement to correctness: a correct moving average over a window must store k values; the EMA stores one and still weights all of history. Kin to Kahan (the keeper on dart's cousin axis) only superficially — Kahan conserves a lost remainder, the EMA chooses to forget geometrically. A forgetting mechanism, honestly bounded.