Cascading Echoes — User Guide
Iterative random-delay feedback processor creating complex echo patterns, stereo diffusion, and reverb-like tails.
What this does
This script creates cascading echo effects through iterative random-delay feedback processing. Unlike simple delay effects with fixed repetition times, this script applies multiple passes of randomly-varying delays, creating complex, diffuse echo patterns that range from tight reflections to long ambient tails. The result sounds like acoustic reflections in irregular spaces — natural, unpredictable, and spatially rich.
Key Features:
- Iterative Processing — Multiple feedback passes (3-7 iterations) build complexity
- Random Delay Times — Each iteration uses random delay within specified range
- Stereo Diffusion — Independent left/right processing creates wide spatial field
- 4 Presets — Short tight, long ambient, wide stereo, plus custom control
- Configurable Decay — Separate amplitude decay rates for left/right channels
- Automatic Tail Extension — Adds silent duration for echoes to decay naturally
Technical Implementation: The script: (1) Extends input sound by concatenating silent tail (tail_duration_seconds), (2) For stereo, splits into L/R channels for independent processing, (3) Applies iterations loop: each iteration k adds feedback with random delay (delay ~ U[delay_min, delay_max]) and amplitude decay^k, (4) Formula: output[n] = input[n] + amplitude × (input[n+delay] - input[n]), which adds delayed signal while compensating DC offset, (5) Stereo uses different delay ranges (L: delay_min-max, R: stereo_delay_min-max) creating decorrelation, (6) Peak normalization to 0.99 prevents clipping, (7) Channels recombined if stereo. The random delay per iteration means each echo pattern unique. The subtraction term (input[n+delay] - input[n]) is a high-pass filter preventing DC buildup from feedback accumulation.
Quick start
- In Praat, select a Sound object (this script processes existing audio, doesn't generate).
- Run script… →
Cascading Echoes.praat. - Choose Preset (start with "Default (balanced)" to understand effect).
- Click OK — script processes sound and plays result automatically.
- For custom control, choose "Custom" preset and adjust all parameters.
Echo & Delay Theory
🔊 The Physics of Echoes
Natural echoes: Sound reflects off surfaces, returns delayed and attenuated
Echo perception: Delays <20ms = coloration/timbre, 20-50ms = distinct echo, >50ms = clear separation
Reverberation: Many echoes arriving so densely they blur into continuous decay
Digital delay: Store samples in buffer, recall after specified time with reduced amplitude
Delay Time Perception
| Delay Range | Perception | Musical Effect |
|---|---|---|
| 1-5ms | Comb filtering, phasing | Timbre change, not heard as echo |
| 5-20ms | Early reflections, doubling | Thickening, chorus-like, spatial depth |
| 20-50ms | Slap-back echo | Distinct echo starts, rhythmic bounce |
| 50-200ms | Clear distinct echo | Rhythmic delay, separated repetition |
| 200-500ms | Long delay | Dub/reggae style, clear musical space |
| 500ms+ | Very long echo | Canyon-like, dramatic spatial effect |
Sample-Based Delay Calculation
Delay times specified in samples, not milliseconds. Conversion:
delay_ms = (delay_samples / sample_rate) × 1000
At 44100 Hz sampling rate:
- 50 samples = 1.13 ms (comb filtering range)
- 200 samples = 4.54 ms (chorus/doubling)
- 500 samples = 11.34 ms (slapback threshold)
- 2200 samples = 50 ms (rhythmic delay)
- 22050 samples = 500 ms (half-second echo)
Feedback & Iteration
Traditional delay: single delay line with feedback (output fed back to input)
This script's approach: Multiple iterations, each adding one echo with new random delay
Iteration Mathematics
For iteration k (k = 1, 2, 3, ..., iterations):
- Delay time: d[k] ~ U[delay_min, delay_max] — independent random each iteration
- Amplitude: a[k] = decay^k — exponential decrease (decay < 1)
- Echo contribution: signal[n] + a[k] × signal[n + d[k]]
Example with 3 iterations, decay=0.8:
- Iteration 1: a=0.8, delay=random(50-500) → first echo at 80% volume
- Iteration 2: a=0.64, delay=random(50-500) → second echo at 64% volume
- Iteration 3: a=0.512, delay=random(50-500) → third echo at 51% volume
Result: Three distinct echoes at unpredictable times, each quieter than previous.
Why Random Delays?
Fixed delays: Regular rhythmic pattern, can sound mechanical or musical (intentional)
Random delays: Irregular pattern mimics natural acoustic spaces (reflections from walls at different distances)
Benefits of randomization:
- Diffusion: Echoes spread across time, preventing comb filtering artifacts
- Naturalness: Real spaces have irregular geometry → irregular reflection times
- Density: Multiple random delays create denser echo field than regular spacing
- Spectral smoothness: Random spacing avoids resonant frequencies of fixed delays
Stereo Decorrelation
Stereo version uses different delay ranges for L/R channels:
- Left channel: delay_min to delay_max (e.g., 50-500 samples)
- Right channel: stereo_delay_min to stereo_delay_max (e.g., 60-550 samples)
Effect of different ranges: Left and right echoes occur at different times, creating:
- Spatial width: Sound appears to come from wider area than mono
- Depth perception: Brain interprets time differences as spatial position
- Immersion: Less "inside the head" (mono), more "in a space" (stereo)
DC Offset Compensation
The formula includes subtraction: self + amplitude × (self[col+delay] - self[col])
Why subtract self[col]? Prevents DC (0 Hz) buildup. Without subtraction:
- Each iteration adds constant offset
- Multiple iterations = accumulated offset
- Result: signal drifts away from zero, can clip or distort
With subtraction: Only AC (changing) components reinforced, DC blocked. Acts as implicit high-pass filter.
Presets (4 Effect Types)
1. Default (balanced) Versatile
Tail duration: 1 second
Iterations: 5 passes
Delay range (L): 50-500 samples (1.13-11.34 ms @ 44.1kHz)
Delay range (R): 60-550 samples (1.36-12.47 ms @ 44.1kHz)
Decay (L/R): 0.8 / 0.75
Character: Balanced, moderate echo density, natural spatial spread
Echo pattern:
- Iteration 1: 80%/75% amplitude, random delay 1-11ms
- Iteration 2: 64%/56% amplitude, different random delay
- Iteration 3: 51%/42% amplitude
- Iteration 4: 41%/32% amplitude
- Iteration 5: 33%/24% amplitude — tail fades naturally
Delay characteristics: Delays in early reflection range (1-12ms), creates thickening/doubling rather than distinct echoes. L/R slightly offset (10-50 sample difference) creates subtle stereo width.
Use cases:
- General-purpose ambience addition
- Vocal thickening (adds presence without distinct echo)
- Subtle spatial enhancement
- When you want "space" without obvious delay effect
- Natural room sound simulation
Best with: Vocals, acoustic instruments, percussion (not overly dense sources). Works on any duration. Good starting point for understanding the effect before customizing.
2. Short & Tight Focused
Tail duration: 0.5 second
Iterations: 3 passes (fewer = less dense)
Delay range (L): 30-180 samples (0.68-4.08 ms @ 44.1kHz)
Delay range (R): 35-220 samples (0.79-4.99 ms @ 44.1kHz)
Decay (L/R): 0.9 / 0.88 (slower decay = longer sustain)
Character: Tight, focused, minimal diffusion — controlled ambience
Echo pattern:
- Iteration 1: 90%/88% amplitude (strong echo)
- Iteration 2: 81%/77% amplitude
- Iteration 3: 73%/68% amplitude — still prominent
Delay characteristics: Very short delays (0.6-5ms) stay in comb filtering/chorus range. Higher decay values mean echoes sustain longer relative to their number. Short tail (0.5s) keeps effect compact — doesn't extend source significantly.
Sonic effect: Adds body and thickness without washing out transients. Echoes too short to hear as discrete repetitions — fuse into timbral enhancement. Creates "big" or "wide" quality without losing definition.
Use cases:
- Thickening drums without losing punch
- Vocal presence boost
- Adding weight to thin sources
- When you need space but must preserve clarity
- Tight stereo width enhancement
- Pop/rock vocal production (subtle thickness)
Best with: Rhythmic material (drums, percussion, plucked strings), vocals needing body, anything where transient preservation is critical. Avoid on already-dense or reverberant sources.
Technical note: Delays <5ms can cause comb filtering (frequency-dependent cancellation). This is intentional here — creates spectral character. If unwanted, use longer delay ranges.
3. Long Ambient Tail Spacious
Tail duration: 2.5 seconds
Iterations: 7 passes (maximum complexity)
Delay range (L): 120-1200 samples (2.72-27.21 ms @ 44.1kHz)
Delay range (R): 150-1500 samples (3.40-34.01 ms @ 44.1kHz)
Decay (L/R): 0.85 / 0.82
Character: Long, spacious, reverb-like tail with distinct echo character
Echo pattern:
- Iteration 1: 85%/82% amplitude, delay 3-34ms
- Iteration 2: 72%/67% amplitude
- Iteration 3: 61%/55% amplitude
- Iteration 4: 52%/45% amplitude
- Iteration 5: 44%/37% amplitude
- Iteration 6: 38%/30% amplitude
- Iteration 7: 32%/25% amplitude — long gradual fade
Delay characteristics: Wide range (3-34ms) spans from early reflections to distinct echoes. 7 iterations create dense echo field. L/R range difference (30 samples) creates significant stereo decorrelation. Long tail (2.5s) allows full decay of all echoes.
Sonic effect: Lush, enveloping space similar to large hall reverb but with more distinct echo character. Initial sound followed by cascading reflections that blur together at tail. Creates dramatic depth and size.
Use cases:
- Ambient music (Eno-style atmospheres)
- Cinematic soundscapes
- Vocals for ethereal quality
- Synth pads (adds movement and evolution)
- Solo instruments (epic, concert hall feeling)
- Creating "large space" impression
Best with: Sources with space to breathe — sparse arrangements, solo instruments, vocals, synth textures. Avoid on dense mixes (creates mud). Ideal for material that benefits from drama and spaciousness.
Comparison to reverb: Traditional reverb: thousands of echoes arriving densely, exponential decay. This preset: 7 distinct but overlapping echoes with random spacing. Result: reverb-like but with more character, less smooth, more "room with personality" than "generic hall."
4. Wide Stereo Delay Spatial
Tail duration: 1.5 seconds
Iterations: 6 passes
Delay range (L): 60-600 samples (1.36-13.61 ms @ 44.1kHz)
Delay range (R): 200-1800 samples (4.54-40.82 ms @ 44.1kHz)
Decay (L/R): 0.78 / 0.72 (asymmetric decay)
Character: Extreme stereo separation, dramatic spatial width, ping-pong-like but diffuse
Echo pattern:
- Left channel: Delays 1.4-13.6ms, decay 0.78 → relatively tight, faster fading
- Right channel: Delays 4.5-40.8ms, decay 0.72 → wider spread, faster fading
- Asymmetry: Right delays 3-27ms longer than left on average
Delay characteristics: Huge L/R range difference creates stereo width. Left stays in early reflection zone (1-14ms), right extends into distinct echo range (up to 41ms). Asymmetric decay (0.78 vs 0.72) means echoes fade at different rates per channel.
Sonic effect: Sound appears to "bounce" between speakers irregularly. Not regular ping-pong (which alternates L-R-L-R), but chaotic spatial movement. Creates impression of wide, three-dimensional space. Mono compatibility poor — collapses to unpredictable timbre.
Use cases:
- Electronic music spatial effects
- Psychedelic/experimental production
- Headphone-optimized mixes (immersive stereo)
- Stereo field width maximization
- Sound design (sci-fi spaces, otherworldly ambiences)
- Creating "headphone experience" distinct from speaker playback
Best with: Mono sources that need dramatic spatialization (synth leads, vocals, percussion). Less effective on already-stereo sources (creates confusion). Ideal for headphone listening.
Caution: Poor mono compatibility. When summed to mono, L/R delays create unpredictable phase cancellation. Test in mono if release requires mono compatibility (broadcast, phone speakers). Consider "Default" or "Short & Tight" for mono-safe alternatives.
Parameters (Custom Mode)
Core Settings
| Parameter | Type | Default | Description |
|---|---|---|---|
| Preset | menu | Default | Preset configurations (see Presets section) |
| tail_duration_seconds | positive | 1 | Length of silent tail added for echo decay |
| iterations | natural | 5 | Number of echo passes (more = denser) |
| play_after_processing | boolean | Yes | Automatically play processed sound |
Delay Parameters (Samples)
| Parameter | Type | Default | Description |
|---|---|---|---|
| delay_min | positive | 50 | Minimum delay for left channel (samples) |
| delay_max | positive | 500 | Maximum delay for left channel (samples) |
| stereo_delay_min | positive | 60 | Minimum delay for right channel (samples) |
| stereo_delay_max | positive | 550 | Maximum delay for right channel (samples) |
Amplitude Decay
| Parameter | Type | Default | Range | Description |
|---|---|---|---|---|
| decay_left | positive | 0.8 | 0.1-0.99 | Amplitude multiplier per iteration, left channel |
| decay_right | positive | 0.75 | 0.1-0.99 | Amplitude multiplier per iteration, right channel |