Science & DSP Architecture

How PhosphorVox grows sound

A technical reference for acousticians, sound designers, and speech pathologists. Every parameter is physically grounded in published research.

1. Kelly–Lochbaum Transmission-Line Acoustic Waveguide

PhosphorVox simulates the vocal tract as a 1D acoustic transmission line discretized into cylindrical waveguide sections (44 sections at 48 kHz). At each junction between adjacent sections, forward and backward acoustic pressure waves scatter according to the Kelly–Lochbaum reflection equations governed by cross-sectional area ratios:

rᵢ = (Aᵢ − Aᵢ₊₁) / (Aᵢ + Aᵢ₊₁) where: Aᵢ = cross-sectional area of tract section i rᵢ = scattering reflection coefficient (−1 < rᵢ < 1) P⁺ᵢ₊₁ = (1 + rᵢ)·P⁺ᵢ − rᵢ·P⁻ᵢ₊₁ P⁻ᵢ = rᵢ·P⁺ᵢ + (1 − rᵢ)·P⁻ᵢ₊₁

In the native C++ DSP engine, this physical waveguide approach guarantees zero heap allocations on the real-time audio thread using pre-allocated block buffers, and naturally models anatomical formant resonances, dynamic tract elongation, velum/nasal branch coupling, and lip radiation impedance without artificial filter tracking. In the browser Web Audio worklet, processing runs within the JavaScript engine with pre-allocated Float64Array scratch buffers to eliminate allocation churn during continuous block rendering.

Sounding Model Architecture: The physical sounding model consists strictly of the 44-section 1D Kelly-Lochbaum scattering network driven by the glottal flow source (LF / Rosenberg) and an acoustic lip radiation filter. All acoustic propagation and formant resonances are generated directly by this waveguide; higher-level features such as paleo morphometry, cavity pressure, and saliva latching operate as preset configurations and score-path parameter modulations, rather than separate multi-dimensional CFD solvers.

2. Glottal Source Models

The voiced source supports three waveform types:

  • Rosenberg pulse — piecewise-cosine approximation of the glottal flow derivative, the standard for formant synthesis
  • LF (Liljencrants-Fant) model — more physiologically accurate with control over return phase skew and spectral tilt
  • Sawtooth harmonics — efficient additive synthesis using up to 40 harmonics with 1/n² rolloff

For unvoiced sounds (fricatives, plosive bursts), a white noise source is shaped by bandpass IIR filters positioned at the constriction point.

3. Articulatory Targets & IPA Mapping

The core sounding model is driven by articulatory control parameters that map directly to the cross-sectional radii of the 44 waveguide sections. A database of 65 IPA glyph mappings defines target articulatory configurations (tongue tip/dorsum height and position, lip aperture, velum opening, and glottal state). When transitioning between phonemes, a spring-bank coarticulation model interpolates targets over 60–120 ms, simulating the mechanical inertia of the articulators.

Reference values are drawn from:

  • Peterson & Barney (1952) — American English vowel formant measurements
  • Hillenbrand et al. (1995) — Extended vowel formant database
  • Ladefoged & Maddieson (1996) — World phonetic inventory

4. Paleo-Acoustic Morphometry (Preset Control Layer)

The archaic humanoid presets scale the vocal tract geometry based on published fossil anatomical reconstructions. The sounding engine remains the 44-section Kelly-Lochbaum waveguide; rather than running a 3D finite-element mesh, these presets map calibrated cross-sectional diameters and tract length ratios into the waveguide's diameter constraints:

  • Homo neanderthalensis — Based on the Kebara 2 hyoid reconstruction (Lieberman, 1998; McCarthy et al., 2019): elevated larynx, shortened pharynx (~4.5 cm vs modern ~6 cm), elongated oral cavity, 15% nasal leakage through widened nasal aperture
  • Homo denisova — Modeled from Xiahe mandible CT data (Dediu & Moisik, 2019): deep mandibular cavity, wide dental arch, enlarged oral volume (~75 mL), shifted F2 vowel space

Disclaimer: All archaic reconstructions are speculative physical modeling based on fossil cranial proportions, not acoustic recordings. These are research presets that scale waveguide section diameters, not definitive paleo-linguistic statements.

VOCAL TRACT CROSS-SECTION — Modern Homo sapiens vs Neanderthal (Kebara 2)
HOMO SAPIENS Nasal Palate Oral Cavity Pharynx L ~6.0 cm 90° basicranium 12 cm scale H. NEANDERTHALENSIS Kebara 2 reconstruction Wide Nasal (+15%) Flat palate Elongated Oral Pharynx L 15% nasal leak ~4.5 cm Flat basicranium 12 cm scale
Based on Lieberman (1998) Kebara 2 hyoid reconstruction and McCarthy et al. (2019) virtual endocast analysis.

5. False-Fold Aerodynamic Coupling

For throat singing (Kargyraa style), a secondary pair of resonant filters is placed below the primary glottis, operating at half the fundamental frequency. This models the ventricular folds (false vocal folds) vibrating as a secondary sound source, producing the characteristic sub-harmonic bass drone.

The coupling is controlled by an aerodynamic pressure threshold — when intraoral pressure exceeds 0.8 kPa, false-fold oscillation engages with a soft-clipping waveshaper to simulate mucosal wave distortion.

6. Jev 1.13 Motor Cortex (Score-Path Sequencing)

The groove decision layer operates on a 16th-note step grid. The acoustic sounding model remains the Kelly-Lochbaum waveguide; cavity aerodynamics, lung volume depletion, and saliva latching operate as score-path control triggers rather than continuous 3D fluid simulations at every slider. At each step, the Jev engine evaluates:

  • Current BPM and step position
  • Lung volume (depletes with each voiced gesture, recovers on rests)
  • Polytropic intraoral pressure during plosive closures (governs burst release timing)
  • Saliva bridge surface-tension latching (delays aperture opening until release threshold)
  • Last articulatory landmark (lips, alveolar, velar, glottal, etc.)
  • Genre style and emotion valence/arousal

With an OpenRouter API key, Jev sends these parameters to an LLM for non-deterministic groove decisions. Without a key, a deterministic local fallback table provides genre-appropriate patterns with zero latency.

7. Spectral Analysis Pipeline

The built-in analysis module provides:

  • Radix-2 FFT — In-place Cooley-Tukey on Float64Array buffers (zero allocation)
  • Hann-windowed STFT — 2048-point or 4096-point, configurable hop size
  • Spectral centroid — Magnitude-weighted frequency center for timbre tracking
  • Band energy — Per-band dB measurement for formant validation
  • Autocorrelation pitch detection — 60–800 Hz range for real-time voice tracking

The acoustic accuracy benchmark (tools/spectrogram_accuracy_benchmark.mjs) validates all formant parameters against published literature with 26 verification gates.

SPECTRAL FORMANT PROFILE — 48 kHz / 2048-pt FFT (Hann Window)
kHz
5.0 ┤───────────────────────────────────────────────────────────── [Burst F4]
4.0 ┤               ░░░░░░                      ░░░░░░            [Velar snap]
3.0 ┤─── [F3] ──── ░██████░ ─────────────────── ░██████░ ───────── (2850 Hz)
2.0 ┤───────────────────────── ░██████░ ────────────────────────── [F2: 1980 Hz]
1.0 ┤────────────────────────────────────────── ░██████░ ───────── [F1: 720 Hz]
0.5 ┤─── [F1: 280 Hz] ─────────────────────────────────────────── [Subharmonic 2:1]
0.0 ┴─────┬────────────┬────────────┬────────────┬────────────┬───
        /i/ (Front)  /a/ (Open)   /u/ (Back)   K-Snare     Kargyraa
Verified against Peterson & Barney (1952) and Hillenbrand et al. (1995) reference datasets.

8. Clinical Acoustic Telemetry (Post-Synthesis Output Analysis)

The clinical mode runs real-time post-synthesis digital signal analysis on the output PCM waveform to extract standard voice metrics (the underlying physical sounding model remains the Kelly-Lochbaum waveguide and glottal source):

  • Jitter (%) — Cycle-to-cycle F0 perturbation, computed over the last 50 pitch periods
  • Shimmer (%) — Amplitude perturbation, peak-to-peak variation across periods
  • HNR (dB) — Harmonics-to-noise ratio via autocorrelation peak analysis
  • Subglottal pressure (kPa) — Estimated from intraoral pressure during plosive closures

Research & Educational Instrument — FDA Class I Exempt. Not intended for standalone medical diagnosis.