Pulsar Synthesis Engine — User Guide
Pulsar-style synthesis from a selected Praat Sound. The engine creates periodic, chirped/jittered, or Poisson onset times; converts them to a band-limited impulse train; convolves that train with the selected Sound; then applies a per-IOI Hann duty gate, global fades, and optional amplitude modulation.
Scope and signal flow
The selected Sound acts as a timbre / convolution kernel. The engine does not repeatedly copy that Sound directly at every onset. Its implemented signal flow is:
→ sinc-band-limited impulse train
→ convolution with selected h(t)
→ per-IOI Hann duty gate
→ global fade / optional AM
→ optional target-peak normalization
This is related to Curtis Roads' pulsar synthesis framework, but it is important to distinguish the implementation from the simplest canonical pulsar model. In the classic description, a pulsar contains a pulsaret followed by silence within a period. Here, the selected Sound is first excited by the complete impulse train through convolution, and the duty-cycle window is applied after convolution. Therefore Duty cycle controls how much of the convolved response remains audible inside each realized inter-onset interval.
Quick start
- Select exactly one Sound in Praat. It will become the timbre kernel.
- Run
Pulsar_Synthesis_Engine.praat. - Choose a preset or select Custom.
- For Custom, choose Periodic or Stochastic Poisson and set Duration, Period or Density, and Duty cycle.
- Use Edit details for jitter, chirp, AM, fades, sample rate, output peak, and random seed.
- Run the script. The final Sound remains selected and is optionally played.
Onset modes
Periodic
With no chirp and no jitter, events are spaced by the selected Period:
For example, a 10 ms period corresponds to a 100 Hz repetition rate.
Periodic chirp
When chirp is enabled, the period is interpolated linearly through time:
Because repetition frequency is 1/p(t), a linear period trajectory is generally not a linear frequency glide.
Periodic jitter
Jitter perturbs each current period independently:
In the chirp/jitter path, realized periods shorter than two samples are clamped to two samples and counted in the QC statistics.
Stochastic Poisson
Mode B uses Praat's homogeneous Poisson-process generator. Density is the expected pulse rate λ in pulses per second, and the expected inter-onset interval is:
The actual pulse count and inter-onset intervals vary from realization to realization. Very short or low-density settings can produce few pulses, and a Poisson realization can theoretically contain none.
Random seed
Random seed = 0 leaves onset randomness unpredictable. A positive seed makes the stochastic onset stage reproducible. In v1.1.1 the fixed seed is scoped to onset generation only; immediately afterward Praat's global random generator is returned to a safely unpredictable state.
The onset process is the only stochastic stage. The convolution, gating, fades, and AM are deterministic once the onset times are known.
Selected Sound, sample rate, and convolution
The script requires one non-silent Sound with positive duration. It extracts the complete selected Sound with a rectangular window and zero-shifts the working copy so its response begins at each impulse time.
Sample rate
If the selected kernel uses a different sampling frequency from the requested output rate, the working copy is resampled to the output rate with Praat's Resample: ..., 50 setting before convolution.
Band-limited impulse train
The PointProcess is converted using Praat's To Sound (pulse train) command. This produces the sinc-band-limited excitation train used by the convolution stage.
Convolution
The pulse train and kernel are convolved with Praat's sum amplitude convention and zero outside the input domains. The sum convention is appropriate for treating the selected Sound as a finite impulse response excited by a pulse train.
Convolution naturally extends the time domain. The script then extracts exactly 0 ... Duration, so any kernel response extending beyond the requested end is discarded.
Channel behavior
The pulse train is mono. Praat's convolution rules preserve the channel count of a multichannel kernel when the other Sound is mono. Therefore:
- mono kernel → mono output;
- stereo kernel → stereo output;
- multichannel kernel → the same number of output channels.
Each kernel channel is convolved with the same mono pulse train; the relative channel structure of the selected kernel is retained through the convolution stage.
Per-IOI Hann duty gate
For every realized onset, the script measures the following inter-onset interval. The active duration is:
The active window begins at the onset and is shaped by a raised-cosine/Hann gate:
with zero outside the active region. Duty cycle is restricted to 0 < duty ≤ 1, so the requested gate never intentionally extends beyond its own IOI.
For the final pulse, the script reuses the previous IOI when available. With only one pulse, it falls back to the requested Period in Periodic mode or 1/Density in Poisson mode.
Kernel tails and duty cycle
The convolution happens before gating. If the selected kernel lasts longer than the duty window, its convolved tail is intentionally cut by the gate. The Info/QC report shows kernel duration / mean active window; values above 1 indicate this truncation is expected.
Very short windows
Active windows using fewer than four samples are counted and reported. Windows below one sample are raised to one sample where the current IOI allows it. This is a resolution safeguard, not a change to the onset process.
Global envelope and amplitude modulation
Fades
Global fade-in and fade-out use half-cosine curves after duty gating. Each requested fade is capped at 45% of the total Duration.
AM
When enabled, the complete gated output is multiplied by:
With depth from 0 to 1, the gain ranges from 1-depth to 1+depth. At depth 1 the trough reaches zero.
Controls
Main page
| Control | Default | Meaning |
|---|---|---|
| Preset | Periodic Tone | Custom plus six predefined configurations. |
| Synthesis mode | Periodic | Used directly in Custom; non-Custom presets can override it. |
| Duration | 3 s | Final requested output duration; valid range >0 to 120 s. |
| Period | .01 s | Periodic onset interval for Custom Periodic mode. |
| Density | 100 /s | Poisson intensity for Custom Stochastic mode. |
| Duty cycle | .5 | Fraction of each realized IOI occupied by the Hann gate; >0 to 1. |
| Edit details | off | Opens jitter/chirp/AM/fade/sample-rate/normalization-seed controls. |
| Normalize output | on | When on, any nonzero result is peak-scaled to Output peak. |
| Draw visualization | on | Draws the mechanism-first four-panel QC display. |
| Play result | on | Plays the final selected Sound. |
Details page
| Control | Default | Validation / behavior |
|---|---|---|
| Periodic IOI jitter ratio | 0 | 0–.95; Gaussian standard deviation equals currentPeriod × ratio. |
| Enable periodic chirp | off | Periodic mode only; linearly changes period through time. |
| Chirp end period | .005 s | Positive endpoint for the period trajectory. |
| Enable amplitude modulation | off | Applies global sinusoidal AM after gating/fades. |
| AM rate | 4 Hz | Non-negative. |
| AM depth | .5 | 0–1. |
| Fade in / out | .05 / .10 s | Non-negative; each capped to 45% of Duration. |
| Sample rate | 44100 Hz | 8000–192000 Hz. |
| Output peak | .95 | Target peak when Normalize output is enabled; >0 to 1. |
| Random seed | 0 | 0 = unpredictable; positive = reproducible stochastic onsets. |
Presets
Presets override the mode-specific variables listed here. They do not override Duration, Sample rate, Output peak, Random seed, Normalize output, Draw visualization, or Play result.
| Preset | Mode / timing | Duty | Other overrides |
|---|---|---|---|
| Periodic Tone | Periodic; 10 ms period (100 Hz) | .50 | jitter 0; no chirp; no AM; fades .03/.10 s. |
| Rhythmic Pulse | Periodic; .25 s period (4 Hz) | .15 | jitter .05; no chirp; no AM; fades .02/.05 s. |
| Stochastic Cloud | Poisson; density 100/s | .50 | no chirp/AM; fades .05/.10 s. |
| Chirp Sweep | Periodic; 20 ms → 2 ms period | .50 | jitter .01; chirp on; no AM; fades .04/.12 s. |
| Tremolo Web | Poisson; density 150/s | .40 | AM 6 Hz, depth .7; fades .08/.15 s. |
| Noise Burst | Poisson; density 400/s | .80 | no AM; fades .01/.04 s. |
Sampling and runtime safety
Requested periodic-rate guard
For Periodic mode, the shortest requested endpoint period (start or chirp end) is checked so its reciprocal does not exceed 95% of Nyquist:
In the chirp/jitter event loop, any realized IOI below two samples is clamped to two samples.
12,000-pulse runtime guard
Version 1.1.1 limits a realization to 12,000 pulses. This is important because the duty gate is assembled with one Formula (part) operation per event.
- Poisson mode performs a preflight check using
Density × Duration, then also checks the realized PointProcess. - Periodic mode without chirp/jitter checks the expected count before synthesis.
- Chirp/jitter mode enforces the limit while constructing the process.
If the limit would be exceeded, the script stops with a message asking for lower density, longer period, or shorter duration rather than attempting an impractically large gate.
Output and normalization
| Property | Behavior |
|---|---|
| Input | Exactly one non-silent Sound used as the kernel. |
| Duration | Exactly the requested Duration after convolution is cropped to 0…Duration. |
| Sample rate | Exactly the selected output rate; the kernel is resampled when necessary. |
| Channels | Follows the selected kernel's channel count. |
| Normalize output = on | Every nonzero result is peak-scaled to Output peak. This can scale either up or down. |
| Normalize output = off | No final peak scaling; the level produced by convolution, gating, fades, and AM is retained. |
| Randomness | Only onset timing can be stochastic: Poisson timing or Periodic jitter. The positive seed is reproducible and scoped to onset generation. |
| Object name | Pulsar_<preset>_<mode>. |
Visualization and QC
The v1.1 visualization is mechanism-first rather than an eight-panel result overview.
| Panel | What it shows |
|---|---|
| A — Onset Process | Realized IOIs through time against the model: fixed period, linearly changing period for chirp, or the Poisson expected IOI 1/λ. |
| B — Pulsar Geometry | One representative realized IOI with the actual Hann gate and the boundary between active time and silence. |
| C — Timbre + Post Control | The selected/resampled kernel waveform plus the global fade envelope and, when active, the AM gain curve. |
| D — Measured Output | The final measured output waveform after convolution, duty gate, fades, AM, and optional normalization. |
The QC summary reports the onset model, pulse count, realized rate, mean IOI and CV when available, Duty cycle, mean active window, kernel/active ratio, under-resolved gate count, output channel count, final peak/RMS, pre-normalization peak, and sample rate.
Further reading
- Roads, C. (2001). “Sound Composition with Pulsars.” Journal of the Audio Engineering Society, 49(3), 134–147. AES record. This is the direct primary reference for pulsar synthesis and explicitly discusses convolution with sampled sounds.
- Roads, C. (2002). Microsound. MIT Press. Hardcover ISBN 978-0-262-18215-7. MIT Press.
- Gabor, D. (1947). “Acoustical Quanta and the Theory of Hearing.” Nature, 159, 591–594. DOI: 10.1038/159591a0.