Signals and Systems Principles for Data Scientists
Hands-on labs for the parts of Signals and Systems (Oppenheim, Willsky and Nawab) that matter most in data science work, with each lab naming the book sections it teaches. Basic math is the only prerequisite, every term is defined where it first appears, and every number on this page is computed from real datasets.
Each lab poses one work question, lets you run it on a real dataset, explains the method in plain words, and ends with two graded questions. Labs are self-contained and follow the book’s chapter order: read them in any order, or start with Lab 2, which builds the vocabulary the others use. In the Concepts strip below, each number jumps to a lab teaching that concept.
LAB 1InvertibilityZeros
Can I recover the daily numbers from a smoothed feed?
A vendor ships the feed pre-smoothed: a 7-day average of daily views of the Wikipedia article “Black Friday (shopping)” [4], delivered as whole numbers. An analyst asks the natural question: can the daily values be computed back out? The algebra says yes. The arithmetic disagrees, and the disagreement is permanent.
Ship, recover, and inspect the miss
Undoing swaps zeros for poles
Definitions
invertible
a calculation whose input can be computed back from its output
H(z)
a calculation’s weights written as one formula
zero
a period the calculation deletes outright; the 7-day average has zeros at the weekly cycles
unit circle
the sizes of z equal to 1 on a pole map; a pole strictly inside it fades, a pole on it never does
pole of the inverse
undoing is 1/H(z), so every zero becomes a pole; a pole on the unit circle never lets an error fade
On paper the average is invertible: today = 7 × (today’s average) − the previous six days. With exact numbers and a known start, that recursion returns the data perfectly. The feed grants neither.
Run the recursion anyway and follow its mistake. The six days before the feed began are unknowable, so the recovery starts from a guess for each of them. Every later day inherits those guesses: today’s error is the previous six days’ errors added up and sign-flipped, plus up to a few views from the rounding. Adding up and flipping sign never shrinks anything. So the starting mistake never dies out; it circles through the week, the artifact in the error view above.
A deeper loss sits underneath. Seven equal weights cover one full week, so any weekly up-and-down cancels inside every window: the shipped values carry zero trace of it. The weekly rhythm was multiplied by zero before the feed left the vendor, and no later calculation can rebuild what was multiplied by zero.
The book gives both facts one vocabulary. Written as one formula, the average is H(z) = (1 + z⁻¹ + … + z⁻⁶)/7: z⁻¹ means one day earlier, and each counted day contributes one 1/7 term. The cancelled weekly cycles are the formula’s zeros. The recovery recursion amounts to dividing by H(z), and dividing turns each zero into a pole of the inverse, sitting on the unit circle. Recovering the deleted rhythm would mean dividing by zero, and a pole on the circle is the formal reason the surviving errors never fade. Buy the raw feed.
In the textbook [3]: sections 1.6.2 and 2.3.5 (invertibility) and 10.4 (poles and zeros in the z-plane; inversion swaps them).
Answer it
LAB 2CausalityStabilityLaplace and z
Can I use this processed value for the decision I am making?
A signal is an ordered series of values, such as the daily views of a web page. A system is any fixed calculation applied to it, such as a moving average or a running total. This lab shows how to tell whether a processed value is available for a live decision, valid only in hindsight, or growing because of the calculation itself.
The dataset for this whole lab: daily views of the Wikipedia article “Black Friday (shopping)”, September 1 to December 31, 2025 [4]. About a thousand a day in September, a climb through November, then 82,814 on Black Friday itself.
Follow Black Friday through every calculation
You are building a smoothed-views feature from this data. Averaging nearby days cancels random jumps; taking one day from each side keeps the estimate centered on the day it describes, the standard trend estimate in forecasting [1], while an average of past days only lags. Every output value is a weighted count of real days: follow one day, Black Friday’s 82,814, and watch where and for how long it gets counted.
The test, and where Laplace fits
Definitions
weight
how much of one day is counted inside one output value (1/7 in a 7-day average)
influence
the full list of weights one day receives across all output values, the right plot above
memory multiplier
the factor yesterday’s output is multiplied by inside a running calculation
z⁻¹
shorthand for “one day earlier”; multiplying a formula by z⁻¹ delays it one day
H(z)
the calculation’s influence list written as one formula in z; plugging in z = 1 totals the weights
pole
the value of z where H’s denominator hits zero; for these rules it equals the memory multiplier
unit circle
the sizes of z equal to 1 on the pole map; a pole inside it (size below 1) fades
causal
needs no future days; noncausal needs them (the centered average above); unrelated to causal inference (whether X causes Y)
BIBO stable
limited input always gives limited output, however long it runs
The test needs no chart: add up the sizes of one day’s weights (all positive here, so plain adding is the same thing). In the trailing 7-day average, a day counts 1/7 for seven days; the weights add to 1, so the output stays bounded. The centered average’s weights also add to 1, but three of them sit on future days, so it cannot run live. The fading average’s weights are 0.15, then 0.15×0.85, then 0.15×0.85², and so on; they add to exactly 1, bounded. The running total’s weights are 1 + 1 + 1, forever; the sum is infinite, so steady ordinary input eventually pushes the output past any limit.
For running calculations you do not even need the sum, only the update rule. The fading average is smoothedtoday = 0.15 × viewstoday + 0.85 × smoothedyesterday. That 0.85 is the memory multiplier: every day, whatever remains of Black Friday’s 82,814 is multiplied by 0.85, so its influence has to die out. The running total’s rule is totaltoday = 1.00 × totalyesterday + viewstoday: multiplier 1.00, nothing ever fades. The verdict is the size of that one number. Size below 1: influence fades and the output stays bounded. Exactly 1: nothing fades and the output accumulates forever. Above 1: the output explodes. Every multiplier on this page is positive, so its size is just the number.
Laplace-style analysis packs that entire reasoning into one formula. Write z⁻¹ for “one day earlier”. The fading average’s rule, smoothed = 0.15 × views + 0.85 × (smoothed one day earlier), rearranges to smoothed × (1 − 0.85 z⁻¹) = 0.15 × views, so H(z) = 0.15 / (1 − 0.85 z⁻¹). The denominator hits zero at z = 0.85. That value is the pole, and it is exactly the memory multiplier: read off the rule, no simulation needed.
Bounded, from the formula: plug in z = 1, which means a steady day repeated forever. H(1) = 0.15 / (1 − 0.85) = 1, so a steady 1,000 views settles the fading average at exactly 1,000 × 1 = 1,000. The running total is H(z) = 1 / (1 − z⁻¹): its pole sits at z = 1 itself, H(1) divides by zero, and the same steady 1,000 views grows without limit. The general rule for causal calculations like these: every pole strictly inside the unit circle keeps output bounded. The textbook states the same rule for causal systems in continuous time: every pole strictly in the left half of the s-plane [3]. The two versions are linked by z = esT. A multiplier of 0.85 per day is the sampled form of a continuous decay at rate ln 0.85 ≈ −0.16 per day.
Available live, from the formula: the centered average’s transform is H(z) = (z³ + z² + z + 1 + z⁻¹ + z⁻² + z⁻³) / 7, and the positive powers of z are future days sitting in plain sight: three of its inputs do not exist on the value’s own date. SciPy’s own documentation shows the bounded test failing in floating point: running a 13th-order filter as a single stage through lfilter, “the numerical error pushes some poles outside of the unit circle”, a rounding error nudging a multiplier past 1. Chaining second-order stages, which is what sosfilt does, avoids it [2].
Timing and boundedness are separate columns: the centered average is bounded yet not live, and the running total is live yet not bounded.
In the textbook [3]: sections 2.3.6 and 2.3.7 (causality and stability from the impulse response), 9.7 (both read off the system function) and 10.7 (the sampled-data version used here).
Using this in your data work
For a live feature, use only observations available at decision time. For a retrospective trend, later observations are legitimate, but do not feed the reconstructed value to a model as if it had been known on its date. For a bounded summary, pick a calculation whose weights total a finite number and whose memory multiplier stays below 1; expect a running total to grow.
Answer it
LAB 3CorrelationConvolution
Does this series lead that one?
Growth claims metric A predicts metric B three days out and wants it wired into the model. Sometimes such a lead is real calendar structure; often it is two series sharing a rhythm. Shift one against the other and measure, in a window with an event and in a window without one. Below, two real pages: “Black Friday (shopping)” [4] and “Cyber Monday” [7].
Shift and compare, in two windows
Correlation counts co-movement, from any cause
Definitions
cross-correlation
the match between two series as one is shifted day by day (r, from −1 to 1)
lead
the shift with the best match; positive means the second series follows the first
In the holiday window the best match is at +3 days: Cyber Monday’s curve is Black Friday’s, three days later. That lead is real calendar structure: Cyber Monday IS the Monday after. In the quiet window nothing happens, yet r stays near 0.9 at shift 0 and ripples every 7 days at the other shifts. A shared climb and a shared weekly rhythm make any two such series move together. Correlation measures moving together, not connection. Before believing a lead, remove what is shared: subtract the same weekday last week from each series, and difference away the climb.
In the textbook [3]: chapter 2 (convolution; correlation is its mirror image, developed in the chapter’s problems).
Answer it
Chapter 3Fourier seriesLabs 4 to 5
LAB 4Fourier seriesHarmonics
What rhythms are in my data that I cannot see?
Before building a forecast you need an inventory: which repeating patterns does this series actually contain, daily, weekly, both, neither? Guessing wrong wastes features and windows. The periodogram measures it, period by period: how strong is that cycle in the data? Below, two real series: daily views of “Black Friday (shopping)” [4] and hourly views of all English Wikipedia [5].
Measure ten candidate periods at once
The measurement twin of the gain curve
Definitions
periodogram
cycle strength measured from the data, period by period (trend removed first); this page’s version checks ten chosen periods and plots each fitted wave’s size, where the standard tool scans all periods and squares the sizes
harmonic
a rhythm’s companions at half, a third, ... of its period; any non-sine shape needs them
This chart and a gain chart answer two different questions. The periodogram looks at the data and asks: which rhythms are in here, and how strong is each? A gain curve looks at a calculation and asks: how much of each rhythm would it let through? A feature ends up with a rhythm only when the answer to both is more than zero.
The two peaks here are one rhythm, not two. The weekly pattern is not a smooth wave: the weekend drop is sharp. A sharp-cornered pattern is built from a main wave (7 days) plus a faster helper wave (3.5 days), its harmonic. A 7-day average deletes both of those periods, so the whole weekly shape disappears, corners and all.
In the textbook [3]: sections 3.3 and 3.6 (Fourier series: a repeating shape as a fundamental plus harmonics).
Answer it
LAB 5First-order systemsTime constant
How do I choose the fade rate?
The 15% in the team’s fading average was copied from an old notebook, and nobody can say what it promises. The real requirement is a staleness budget: after the world shifts level, the feature must catch up within an agreed number of days, and that number picks the rate for you. Below, daily views of the Wikipedia article “Black Friday (shopping)” [4]: the November climb is a real level shift to track.
the kept fraction, 1 − fade: the daily multiplier on whatever the average remembers
time constant
days until a level shift is 63% absorbed: −1/ln(pole); 95% takes about three of them
Read the promise off the pole. A fade of 5% keeps 95% of yesterday, so a level shift is 95% absorbed only after about 59 days; 15% delivers it in about 19 days; 30% in about 8. To go the other way, start from the deadline: 95% within a week means a time constant near 2.3 days, pole e−1/2.3 ≈ 0.65, fade 35%. The same knob sets how much day-to-day noise survives: faster tracking, noisier feature. The rate was never a style choice; it is a promise about staleness.
In the textbook [3]: sections 6.5.1 and 6.6.1 (first-order systems and their time constants).
Answer it
Chapters 5 and 6Frequency responseLabs 6 to 9
LAB 6DTFT propertiesZeros
Why is the week-over-week chart so noisy?
Leadership tracks the business week-over-week, and the chart is so jumpy that people have stopped trusting it. The very subtraction that removes the weekly rhythm, today minus the same day last week, is what made it jumpy. Below it runs on daily views of “Black Friday (shopping)” [4].
Subtract last week, watch what remains
Why the subtraction deletes the week
Definitions
week-over-week difference
today minus 7 days ago; as a formula, 1 − z⁻⁷ (z⁻¹ means one day earlier)
gain at a period
how much of a cycle’s size survives the calculation; 2 means doubled
zero
a period the formula deletes outright
Week-over-week subtraction takes today’s value and subtracts the value from seven days earlier. Any cycle that fits the week exactly sits at the same point of its rhythm on both days. The two values match, so the subtraction leaves nothing. That covers the weekly rhythm and every faster cycle that repeats a whole number of times inside a week. A steady level disappears for the same reason. Steady growth does not. Last week’s value is lower by a fixed amount, so what survives is one week’s worth of climb, the same number every day.
The cost is noise. Each result now carries the random wiggle of two days instead of one. At period 14 those two days sit at opposite extremes of the cycle, so subtracting one from the other doubles it. Averaging deletes by blurring. Subtraction deletes by adding noise. Deseasonalized is not denoised.
In the formula from the definitions above, 1 − z⁻⁷, the deleted periods are the zeros and the doubling at period 14 is a gain of 2.
In the textbook [3]: section 5.3 (properties of the discrete-time Fourier transform, differencing included) and 10.4 (zeros placed on the unit circle).
Answer it
LAB 7Frequency responseZeros
Why did the 7-day average erase the weekly pattern?
Your model’s main input is a 7-day-averaged version of daily traffic, and a reviewer notices the model behaves as if weekends do not exist. Nobody deseasonalized on purpose. The smoothing window did it: the choice of window silently decides which rhythms reach your features.
Smooth the data, watch the rhythm
The smoothers below are live (trailing): each day’s value uses only that day and earlier days. They run over the quiet September and October weeks of daily views of the Wikipedia article “Black Friday (shopping)” [4].
Where the deletion comes from
Definitions
cycle, period
a pattern repeating every fixed number of days; the period is that number (weekly rhythm: period 7)
gain at a period
how much of a cycle’s size survives the calculation; the right plot computes it for every period from each calculation’s H(z), its weights written as one formula
zero
a value where H(z) itself equals zero: the calculation deletes that cycle outright (poles sustain, zeros delete)
Seven equal weights cover exactly one full week. Every day of the weekly rhythm is counted once, so the days above the line cancel the days below and the seven of them sum to nothing. The pattern is deleted, not reduced. A shorter window covers only part of a cycle, so the cancellation is incomplete and some rhythm survives: 75% through the 3-day window, 36% through the 5-day, 18% through the fading average.
The formula named in the definitions above, H(z), is (1 + z⁻¹ + … + z⁻⁶)/7 for the 7-day average, where z⁻¹ means one day earlier, and the weekly period is its zero.
The practical rule: choosing a smoothing window is choosing which rhythms your feature keeps. If a model downstream needs day-of-week effects, a 7-day-averaged feature carries none of them. Deseasonalize deliberately, not by accident.
In the textbook [3]: section 10.4 (reading the frequency response geometrically from poles and zeros) and 6.2 (the magnitude of the frequency response).
Answer it
LAB 8PhaseGroup delay
How many days late is my smoothed trend?
Marketing asks why the “trend has turned” alert fired days after the turn everyone saw with their own eyes. The alert reads a smoothed curve, and every live smoothed curve runs behind reality by a measurable number of days. Slide it back until it matches the honest estimate and you have measured the alert’s staleness. Below: daily views of the Wikipedia article “Black Friday (shopping)” [4], smoothed both ways.
Slide the live curve until it matches
Lag can be read off the weights
Definitions
lag
how many days a live curve runs behind the honest centered estimate
centered 7-day average
the mean of 3 past days, the day itself and 3 future days: the honest estimate of a day’s level, itself computable only 3 days later
The trailing 7-day window covers today and the 6 days before it. Its center of weight therefore sits 3 days back, (7 − 1)/2. That makes the trailing average the centered average, exactly 3 days late, and it is why the slider finds a perfect match at 3. The fading average’s weights have an average age of 0.85/0.15 ≈ 5.7 days. But those weights are lopsided, so no single shift matches exactly: the curve is late and misshapen.
The practical rule: a trend alert built on an N-day trailing window fires about (N − 1)/2 days after the turn it detects. Decide whether that staleness is affordable before choosing the window.
In the textbook [3]: section 6.2 (phase, linear phase and group delay: lag is the phase side of the frequency response).
Answer it
LAB 9Ideal filtersCausality
Why does my filtered series react before the event?
An analyst presents deseasonalized demand rising the week before each campaign, and procurement wants to pre-order on the signal. The series was cleaned with a sharp filter. Before buying inventory on “anticipation”, check whether the filter fabricated it. Below, daily views of “Black Friday (shopping)” [4] play the part: the Nov 28 spike is the launch.
Two filters meet Black Friday
Sharp in frequency means wide in time
Definitions
ringing
the swings a sharp cutoff adds around any jump, on both sides of it
causal
uses no future days; a causal filter cannot react before its inputs arrive
The rows above are the mechanism. Cutting periods sharply forces a filter to spread its weights across many days, and a symmetric filter spreads them onto both sides of the day it dates. That has two costs, both visible in the sharp row. Weights on days after day 0 mean the filter needs days that have not happened yet, so it cannot run live, and its output moves before an event does. And the weights rise and dip below zero, so a lone spike is printed back onto the series as waves on both sides of itself. The gentle 7-day average buys honesty with blur. When a deseasonalized series seems to anticipate events, suspect the filter before suspecting the world.
In the textbook [3]: sections 6.3 and 6.4 (ideal frequency-selective filters, their noncausal time behavior, and the nonideal trade-offs).
Answer it
Chapters 7 and 8Sampling and modulationLabs 10 to 13
LAB 10Zero-order holdInterpolation
Is it safe to fill the missing days?
The warehouse is running four days behind: it is Nov 25 and the loads for Nov 22 to 25 have not arrived, but the report is due now. Backfill, and with what? Every fill is itself a calculation, with its own timing and its own influence on everything downstream. Below: daily views of “Black Friday (shopping)” [4]; the late days are shown dashed, as they eventually arrived.
Three ways to face the hole
Every fill is itself a calculation
Definitions
fill (imputation)
manufactured values standing in for days not yet arrived; a fill has its own influence and its own timing
Hold-last can run while you wait, but it is stale: it freezes whatever the last loaded day happened to be. The straight line needs the value on the far side of the gap, which has not arrived. It counts a future day backward: future-data leakage dressed up as an imputation. A report written after the fact can use it; a live system cannot, and neither can a backtest that simulates live decisions. Whichever fill you choose, mark the filled days, because downstream calculations count them as if they were observed.
In the textbook [3]: sections 7.1 (the zero-order hold: hold-last is exactly it) and 7.2 (reconstruction by interpolation).
Answer it
LAB 11SamplingAliasing
Is my sampling rate lying to me?
A capacity dashboard fed by a nightly job shows a smooth month-long wave, and the team starts planning hardware around it. Before anyone budgets for a wave, check whether the sampling schedule manufactured it.
Sample the same two months three ways
The gray band is all 1,464 hours of English Wikipedia’s total views, November and December 2025 [5]; its thickness is the daily rhythm. The colored line is what a report sees: one sample every so many hours, joined.
Where the phantom wave comes from
Definitions
sampling interval
the time between recorded samples; the report only ever sees the samples
alias
a fast cycle that reappears in sampled data disguised as a slower one
the sampling rule
record more than two samples per cycle you need to see; exactly two per cycle can land where the wave crosses its average and capture nothing, and faster cycles do not vanish, they alias [6]
The daily cycle repeats every 24 hours. Sampled every 25 hours, each sample lands one hour later in the cycle than the last, so the samples crawl through the whole cycle once every 24 samples: 24 × 25 = 600 hours, about 25 days. The report renames a daily rhythm as a monthly-looking wave. Sampled every 24 hours instead, each sample lands at the same hour: the daily cycle drops out cleanly, and the slower truths that remain, the weekend dips and the late-December slide, are real.
The undersampled cycle carries no information at its new period: the 25-day wave says nothing about any 25-day behavior. Before trusting a slow trend in sampled data, check what faster rhythms the sampling could have renamed.
One consequence for any later analysis: the sampling interval is the clock every period is measured in. Undersample and the clock itself lies: periods get relabeled before any further calculation begins, so period-based reasoning is only trustworthy on honestly sampled data.
In the textbook [3]: sections 7.1 and 7.3 (impulse-train sampling, and the effect of undersampling: aliasing).
Answer it
LAB 12SamplingDecimation
Can I sample slower without lying?
Storage costs force a metric down from hourly to one record per day, and downstream teams still need to trust the slow trends. Done as snapshots, the reduction can fabricate waves. Done with an averaging step first, the fabricated wave disappears. Below: hourly views of all English Wikipedia, November and December 2025 [5], recorded by a job that drifts to every 25 hours.
The same drifting job, with and without the fix
Delete first, then sample
Definitions
anti-alias step
removing cycles faster than your sampling can carry, before sampling [6]
alias
a fast cycle that reappears in sampled data disguised as a slower one
gain at a period
how much of a cycle’s size survives a calculation
zero
a period a calculation deletes outright; the 24-hour average has one at exactly 24 hours
z⁻¹
shorthand for “one hour earlier”; each extra power steps one more hour back
Averaging 24 hourly values covers exactly one day. The hours above the day’s level cancel the hours below, so the daily rhythm sums to nothing and the average carries none of it. The same cancellation happens for any cycle that repeats a whole number of times within a day: 12 hours, 8 hours, and so on. Here the deletion is the point. It removes the daily alias this lab just demonstrated. It does not remove everything, because any faster variation that survives the average can still alias.
On the hourly clock that average is (1 + z⁻¹ + … + z⁻²³)/24, and each period it cancels is one of its zeros.
In general the bar is higher. A purpose-built anti-alias filter removes everything faster than half the sampling rate, because any surviving fast cycle, not just a daily one, gets renamed [6]. Aggregate, then sample. Never snapshot a signal that still holds any cycle shorter than two sampling intervals.
In the textbook [3]: sections 7.3 and 7.5 (aliasing, and reducing a sampling rate safely by filtering first: decimation).
Answer it
LAB 13Amplitude modulationEnvelopes
Is my weekly rhythm a count or a percentage?
A forecast tuned on quiet spring weeks falls apart in December: its errors grow exactly when traffic grows. The model assumed the weekly swing is a fixed number of views. In this data, daily views of “Black Friday (shopping)” [4], September into November, the swing is a share of the level, and that difference decides how the model should be built.
The swing, week by week
Multiplication, and how logs undo it
Definitions
envelope
the slow curve a rhythm’s size rides on; here, the November climb
multiplicative rhythm
swing proportional to the level; additive would be a fixed swing
centered 7-day level
the average of a day and the three days each side: the week’s own trend line through that day
swing
within one week, the highest daily rise above that level minus the deepest dip below it; measuring against the level keeps a climbing week’s climb out of the swing
This is amplitude modulation wearing retail clothes: the weekly rhythm multiplies the trend instead of adding to it. Logarithms turn multiplication into addition. On a log scale the rhythm becomes roughly a constant size, and the standard rhythm tools, gain curves and weekly differences, work cleanly. Model percentage rhythms on logs, or the errors will grow whenever the level does.
In the textbook [3]: sections 8.1 and 8.2 (amplitude modulation and demodulation: a slow envelope multiplying a faster signal).
Answer it
Chapters 9 and 10Laplace and zLabs 14 to 16
LAB 14PolesStability
Why did my mean-reversion bet fail?
The metric sits 3% below its long-run average and the plan writes itself: bet on the bounce. Tried on a year of the euro-dollar exchange rate, 256 trading days of ECB daily reference rates [8], the plan has no edge, and one fitted number says why before any backtest could.
Fit tomorrow on today, twice
The data has a pole of its own
Definitions
pole of a series
the tomorrow-on-today slope: how much of today’s level carries into tomorrow
unit circle
the boundary at size 1 that a pole is measured against; inside it shocks fade, on its rim they never do
random walk
pole at 1: shocks never fade and the level has no home to return to
mean reversion
pole well inside 1: shocks fade and the level is pulled back toward a home
Fit tomorrow on today and read the slope: 0.997, a pole on the rim of the unit circle. A pole there means today’s value is the whole forecast and “below average” is a description, not a signal: measured on this year, the ten days after a below-average day moved +0.12% on average, and after an above-average day +0.78%. A year of daily rates cannot statistically separate 0.997 from 1.000; these results neither establish a mean-reversion edge nor rule one out. What they refute is counting on the bounce. The same fit on the daily changes gives −0.03, a pole at zero: each step is forgotten immediately, so the steps mean-revert even though the level never does. Before betting on reversion, fit the data’s own pole; only a pole well inside the circle pulls anything home.
In the textbook [3]: sections 9.7.2 and 10.7 (pole location and stability), applied here to the data’s own fitted pole rather than a calculation’s.
Answer it
LAB 15System functionsCascades
What did I build by chaining two smoothers?
A vendor delivers “smoothed” data, your pipeline smooths again for safety, and the resulting feature ignores real changes for two weeks. Nobody chose that behavior; the chain did. Stacked calculations multiply, and what they multiply is H(z). Chained below on daily views of “Black Friday (shopping)” [4].
One smoother, the other, then both
Products keep every factor’s zeros, and add the lags
Definitions
cascade
one calculation’s output feeding another; the combined formula is the product H₁(z) × H₂(z)
H(z)
a calculation’s weights written as one formula
zero
a period a calculation deletes outright
lag
how many days a live curve runs behind the honest centered estimate
A product is zero wherever either factor is zero. So a chain inherits every deletion: the 7-day window’s zero at period 7 survives any further smoothing. Gains multiply: at a 10-day cycle the window lets 37% through, the fading average keeps 25% of that, and just over 9% survives the chain. Lags add: about 3 days from the window plus about 6 from the fading average. A chain deletes at least as much, and answers at least as late, as its links. Before smoothing a feed, ask what smoothing it already carries. Double-smoothing is the quiet default of pipelines.
In the textbook [3]: sections 9.8 and 10.8 (system function algebra: a series connection multiplies the system functions).
Answer it
LAB 16Unilateral transformsInitial conditions
Why is the dashboard wrong after every restart?
After every redeploy, the anomaly detector pages for days and then calms down on its own. Nothing is wrong with the traffic. The metric it watches carries state, and the restart wiped it: the feature runs wrong until its memory refills. Below, the fading average of daily “Black Friday (shopping)” views [4] is restarted mid-series.
Restart the fading average on Nov 1
A restart error is just another spike
Definitions
fading average
output = 0.15 × today + 0.85 × yesterday’s output; each day’s influence fades 15% a day
state
what a running calculation carries between days; the fading average’s state is yesterday’s output
warm-up
the period after a restart while the state’s error fades
pole
the daily multiplier on whatever remains; at 1.00 nothing ever fades
The gap between the two curves shrinks 15% every day. A restart error fades exactly the way a spike’s influence fades: multiplied by 0.85 each day. Starting from zero throws away a state of 3,688, the Oct 31 output. Since 0.8528 ≈ 0.01, the two copies agree within 1% after about a month.
Each common calculation has its own warm-up. The 7-day average is exactly right 7 days after a restart: the window simply refills. The fading average is never exactly caught up, only within tolerance. The running total never recovers: its multiplier is 1.00, so the error never fades and the missing history becomes a permanent offset. Check restart behavior before trusting any stateful feature’s first weeks.
In the textbook [3]: sections 9.9 and 10.9 (the unilateral transforms: initial conditions and the response they alone produce).