Layer 3 is the binaural beat plus a noise floor (brown, pink, or white). It is the only audio layer AmberRoom currently generates. If you press Begin and put on headphones, this is what you hear: two pure sine tones, slightly detuned per ear, sitting on top of a steady noise floor.
Free tier ships only this layer. Pro adds Layer 1 (real instrument samples) and Layer 2 (AI ambient pad) on top. The math here is the same in both tiers; the difference is whether there's anything over the math.
What runs in your browser
Two oscillators, one channel-merger, one gain node, all stitched together in the Web Audio API. The code lives in lib/audio/binaural.ts and lib/audio/noise.ts. About 120 lines total.
Binaural oscillators
Carrier frequency is fixed at 200 Hz (low-fatigue at low volume, sits below most environmental noise). The left ear plays 200 − Δ/2 Hz; the right ear plays 200 + Δ/2 Hz. The brain perceives a phantom beat at exactly Δ Hz, which is the value the recipe engine targets — 2.5 Hz for sleep, 6 Hz for anxiety, 10 Hz for focus, etc.
Both oscillators are pure sines. No harmonic content, no waveshaping. The frequency difference IS the signal.
Noise floor
We pre-generate an 8-second buffer and loop it. Two seconds (the obvious choice) creates an audible loop seam in pink and brown noise because the slow-varying spectral content reveals the repetition. Eight seconds is past the threshold where the human ear starts pattern-matching.
- White noise: Math.random() * 2 - 1 — flat spectrum, the simplest case.
- Pink noise: Voss-McCartney 7-row filter — the textbook 1/f approximation. Used for sleep recipes (warmer than white).
- Brown noise: leaky-integrator approximation of 1/f². Used for anxiety, grief, focus — warmest of the three.
Why no clicks at start/stop
Setting an oscillator's gain to its target value at t = 0 creates an instantaneous step function — audible as a pop. We use a 600ms linear gain ramp on start and a 400ms ramp on stop. The orchestrator awaits both fades before tearing down the audio context.
Why it's free
Procedural audio costs nothing to generate, distribute, or license. Two sine oscillators are essentially free to compute. The only "asset" is ~120 lines of code. This is why every AmberRoom user — free or paid — gets the binaural science layer.
What it can't do
- Without headphones, the binaural illusion collapses. Speakers blend the two tones before they reach your ears. We detect this (Web Audio channel-count probe) and fall back to isochronic tones — same frequency target, different mechanism, slightly less effective.
- It can't sound warm on its own. Two pure sines plus noise is clinical by design. The warmth comes from Layer 1 (real bowls) and Layer 2 (ambient pad). We are transparent that free is the science, Pro is the room.
- It doesn't dynamically retune. Once a session starts, the binaural frequency is fixed. Per-second adjustment based on biometric feedback is a planned V2 feature.
The honest gap
Layer 3 alone is genuinely useful for the conditions where pure entrainment is the active ingredient (insomnia onset, focus, tinnitus masking with notch filtering). It is insufficient for the conditions where the warmth, harmonic richness, and authentic instrument timbre carry the experience (anxiety, grief, meditation depth). AmberRoom's product claims those use cases too — and they need Layer 1 to actually deliver. Sample library acquisition is the highest-priority next investment.