4-Channel Canon

Quadraphonic version of the canon generator: repeat a source as multiple time‑staggered voices, each optionally transposed and stretched, routed across four output channels (FL, FR, RL, RR).

Author: Shai Cohen Affiliation: Department of Music, Bar-Ilan University, Israel Version: 0.1 (2025) Praat
Contents:

What this does

Functionally identical to the 8‑Channel Canon but adapted to a quad layout. Generates up to four canon voices, places them on four channels, and supports the same entry timing, transposition, stretch (augmentation/diminution), reversing, normalization, and dry/wet mix.

Quick start

  1. Select a mono or stereo Sound.
  2. Run script…4-Channel Canon.praat.
  3. Set Voices (e.g., 4), Entry spacing (ms) (e.g., 400), and choose Routing pattern (Ring).
  4. Optional: Transpose (semitones) and Stretch factor per voice.
  5. Enable Normalize and set Mix (dry/wet). Press OK.

Praat dialog (labels mirrored)

The table mirrors typical Praat-style labels, aligned with the 8‑Channel Canon. If any label differs in your actual dialog, let me know to update 1:1.

Label (as in Praat)TypeDefaultDescription
Voicesinteger4Number of canon voices (1–4)
Entry spacing (ms)real400Delay between successive voices
Time modeoptionmsms | samples | sync
BPMreal120Used when Time mode=sync
Note valueoption1/41/1, 1/2, 1/4, 1/8, 1/16, dotted, triplet
Transpose (semitones)CSV0Per-voice semitone offsets (e.g., 0,5,7,12)
Stretch factorCSV1.0Per-voice time scaling
Reverse voicesCSV (0/1)0Reverse playback per voice
Voice gain (dB)CSV0Per-voice trims
Routing patternoptionRingStraight | Pairs | Ring | Custom map
Custom map (voice→channel)text""CSV of channel indices (0–3 or 1–4)
Spread to neighborsreal0.0Leak each voice to adjacent channels
Mix (dry/wet)real1.00=dry only, 1=only canon
NormalizebooleanyesPeak normalize output to target
Target peakreal0.99Normalization target
ReportbooleannoPrint entry times, routing, gains
CSV fields accept ≤4 values; shorter lists repeat the last value.

Voice→Channel routing

PatternDescription
StraightVoice v → channel v mod 4.
PairsVoices alternate between FL↔FR and RL↔RR.
RingVoices occupy consecutive channels around the quad ring; later entries rotate onward.
Custom mapExplicit mapping via Custom map.

Typical quad order: FL (0), FR (1), RL (2), RR (3) — confirm with your interface.

Additional parameters

ParameterDefaultDescription
Entry offset (ms)0Global offset before the first voice
Trim tail (ms)0Remove trailing silence after rendering
Anti-clip headroom (dB)0Pre-mix attenuation to prevent overload
Pitch modeVarispeedVarispeed (fast) | Phase-vocoder (pitch-preserving)
Crossfade at entries (ms)10Small fade in/out to avoid clicks

Presets

🔁 Strict 4-voice canon

Voices=4; Entry spacing=400 ms; Transpose=0,0,0,0; Stretch=1; Routing=Ring; Mix=1.0; Normalize=yes

🎼 Spiral canon (quad)

Voices=4; Entry spacing=1/8 (sync); Transpose=0,3,7,10; Pitch mode=Phase-vocoder; Normalize=yes

⏱️ Augmentation/Diminution

Voices=4; Stretch=0.75,1.0,1.25,1.5; Entry spacing=360 ms; Routing=Pairs

🦀 Crab canon (quad)

Voices=2; Reverse voices=0,1; Entry spacing=0; Transpose=0,0; Custom map=0;3; Spread=0.1

Workflow & Tips

Math

Entry times

Let V voices, spacing Δ (s). Voice v enters at t_v = t_0 + v·Δ. In sync mode, Δ = k · (60/BPM).

Transpose & stretch

Semitone s → pitch ratio r_p = 2^{s/12}. Stretch a scales time. Varispeed: pitch and duration change; Phase‑vocoder: duration only.

Routing

For Ring, channel index c_v = (c_0 + v) mod 4. Pairs group Front (0,1) and Rear (2,3).