Build with this node

Start with a prompt in Studio, or copy it into your own coding agent.

Ask Studio

@maruaudio/dsp/acoustics/shoebox-ism is the image-source model for a rectangular room, ported from pyroomacoustics' image_source_shoebox. It mirrors the source through the six walls up to a reflection order, walking the L1 ball in upstream's order (z, y, x), and records each image's position, per-axis reflection index, order, per-band attenuation and direction to each microphone. shoeboxIsmAmplitudes gives the amplitude at a microphone: attenuation over distance, optional air absorption, a cardioid-family pattern and a direct-path gain or mask.

Parameters

beginShoeboxIsm(state, roomSize, absorption, scattering, nBands, hybrid, source, mics, nMics, maxOrder) latches one room:

InputAccepts
maxOrderClamped to 17 (7,175 images), reported in orderClamped; negative turns the model off
nBands, nMicsUp to 9 bands; up to 2 microphones
absorption, scatteringEnergy coefficients per wall and band, walls west, east, south, north, floor, ceiling; not range-checked
hybridWith any scattering above 0, transmission is multiplied by √(1 − s)
sourceMust lie inside the room, 0 ≤ p ≤ L per axis

It returns 0 or a status (bad bands, microphones, room or order, or source outside); on error the state holds no images.

Lifecycle

createShoeboxIsm allocates one state sized for the maxima → beginShoeboxIsm → shoeboxIsmStep(budget) until shoeboxIsmDone, or shoeboxIsmRun; shoeboxIsmSeek(index) moves the cursor → shoeboxIsmAmplitudes. Each image is a pure function of its cursor, so any chunking matches a one-shot run.

When to use it

The early reflections of a simulated rectangular room, a budget at a time.

Limits

  • Rectangular rooms only; f64 where upstream is f32 (about 1e-6 relative at order 17). An outside microphone gets zero amplitude.

Algorithm properties and proofs

No Lean 4 proof is mapped to this node.

Explore proofs alongside performance

Dependencies

Dependents

Used by