Store & Delay Samples — Giving DSP a Memory

Addition and multiplication can operate on the sample we have now. But many processors also need something that happened earlier. To do that, DSP must store a value and use it later.

This is the third big idea: DELAY / STORE gives the system a memory.

1. Meet the little DSP diagram

x[n]
current sample
→
z−1
→
x[n−1]
previous sample

z−1 means: delay the signal by one sample. Nothing mystical happens inside the box. A value arrives, it is remembered, and one sample later it appears at the output.

→
A signal/value moves along this path.
z−1
Remember for one sample.
z−D
Delay by D samples.

2. Watch samples move through memory

Press Next sample. The highlighted input moves forward while the output shows the value from D samples earlier.

WRITE / NOW — incoming samples and current position
DELAYED READ — which stored sample are we reading?
1 sample back
x[n] = +0.70
DELAY →
x[n−1] = —

Changing D simply asks for a value further back in the stored history.

3. From samples to time

A sample delay is tiny. How tiny depends on the sample rate.

480 samples ÷ 48,000 samples/sec = 10.000 ms
1 sample @ 48 kHz
≈ 0.0208 ms
48 samples
1 ms
480 samples
10 ms
4,800 samples
100 ms
24,000 samples
500 ms

4. Hear memory become delay

A continuous tone is not ideal for demonstrating echo, so this section uses a short percussive pulse once per second. At very short times the delayed copy colours the sound; increase the delay and the second hit separates into a clear echo.

DRY NOW + STORED PAST → HEARD TOGETHER

5. One box can become a delay line

x[n]
→
z−1
→
z−1
→
z−1
→
x[n−3]

Three one-sample memories in sequence give a three-sample delay. In practice, longer delays are implemented efficiently with buffers rather than drawing thousands of little boxes.

This connects directly to sampling: a delay line is memory containing recent audio. The difference is that instead of loading a recording and choosing where to read it, we continuously write the incoming signal into memory and read an older part back out.

6. You can now read a basic DSP diagram

x[n]
→
z−D
→
× 0.5
→
+
→
y[n]

You already know every symbol here: delay/store an earlier signal, multiply it by 0.5, then add it somewhere. We will use exactly this small vocabulary to build familiar processors.

7. What memory unlocks

Delay / echo
Use an older copy of the signal.
Feedback
Return some output into stored history.
Flanging / chorus
Continuously move a short delay time.
Filters
Combine current and previous samples.
Physical modelling
Circulate energy through delay and loss.
Reverb
Build networks containing many memories and feedback paths.