Math
Precision, ranges, decibels, pitch, scales and the arithmetic every node shares. 13 nodes. Filter them in Explore.
- Decibels
@maru/math-decibels
Canonical f64 decibel-to-linear gain and RBJ amplitude conversions with ECMAScript edge behavior.
Math- JavaScript: Available
- WebAssembly: Builds
- C: Builds
- Native macOS: Builds
- Native Windows: Not checked
- Native Linux: Not checked
- Rust: Not checked
- GPU: Experimental
- Cortex-M: Experimental
- Float clamp
@maru/math-float-clamp
NaN-ignoring IEEE fmin/fmax clamp with newlib signed-zero ties, as DaisySP fclamp computes it for the CHOMPI firmware.
Math- JavaScript: Available
- WebAssembly: Not checked
- C: Builds
- Native macOS: Not checked
- Native Windows: Not checked
- Native Linux: Not checked
- Rust: Not checked
- GPU: Experimental
- Cortex-M: Experimental
- Grid coordinates
@maru/math-grid-coordinates
Allocation-free square/61-key hex key addressing shared by controller Processors (Isomorphic Keyboard, Exquis Controller).
Math- JavaScript: Available
- WebAssembly: Not checked
- C: Builds
- Native macOS: Not checked
- Native Windows: Not checked
- Native Linux: Not checked
- Rust: Not checked
- GPU: Experimental
- Cortex-M: Experimental
- Hash
@maru/math-hash
Reviewed allocation-free 32-bit hash primitives, including the SDK step hash and the distinct Velocity/Humanize finalizer.
Math- JavaScript: Available
- WebAssembly: Not checked
- C: Builds
- Native macOS: Not checked
- Native Windows: Not checked
- Native Linux: Not checked
- Rust: Not checked
- GPU: Experimental
- Cortex-M: Experimental
- Integer
@maru/math-integer
Maru compiler-safe signed 32-bit multiplication with Math.imul-compatible low-word results.
Math- JavaScript: Available
- WebAssembly: Not checked
- C: Builds
- Native macOS: Not checked
- Native Windows: Not checked
- Native Linux: Not checked
- Rust: Not checked
- GPU: Experimental
- Cortex-M: Experimental
- PCM16
@maru/math-pcm16
libDaisy f2s16/s162f signed 16-bit PCM conversions with exact f32 semantics: the +/-0.999985 clamp, truncation toward zero and the f32 1/32767 scale.
Math- JavaScript: Available
- WebAssembly: Not checked
- C: Builds
- Native macOS: Not checked
- Native Windows: Not checked
- Native Linux: Not checked
- Rust: Not checked
- GPU: Experimental
- Cortex-M: Experimental
- Permutation six
@maru/math-permutation-six
Fixed six-element permutation rank and unrank shared by serial DSP and host presentation.
Math- JavaScript: Available
- WebAssembly: Not checked
- C: Builds
- Native macOS: Not checked
- Native Windows: Not checked
- Native Linux: Not checked
- Rust: Not checked
- GPU: Experimental
- Cortex-M: Experimental
- Pitch
@maru/math-pitch
Pitch-ratio math for sample players and tuned voices: exp2 through the natural exponential (`Math.exp(x * ln 2)`, the expression Maru compiler lowers directly), semitone and cent…
Math- JavaScript: Available
- WebAssembly: Not checked
- C: Builds
- Native macOS: Not checked
- Native Windows: Not checked
- Native Linux: Not checked
- Rust: Not checked
- GPU: Experimental
- Cortex-M: Experimental
- Precision
@maru/math-precision
Explicit F64 numeric intent and the allocation-free identity helper asF64.
Math- JavaScript: Available
- WebAssembly: Not checked
- C: Builds
- Native macOS: Not checked
- Native Windows: Not checked
- Native Linux: Not checked
- Rust: Not checked
- GPU: Experimental
- Cortex-M: Experimental
- Quantizer
@maru/math-quantizer
Sampled-curve amplitude quantizer reproducing the 2048-point WaveShaper bitcrush staircase exactly at every 1..16 bit depth.
Math- JavaScript: Available
- WebAssembly: Builds
- C: Builds
- Native macOS: Builds
- Native Windows: Not checked
- Native Linux: Not checked
- Rust: Not checked
- GPU: Experimental
- Cortex-M: Experimental
- Range
@maru/math-range
Audio SDK-compatible f64 range policy: signed zero follows ECMAScript Math.min/Math.max, reversed bounds select the maximum, clamp propagates NaN and bounds infinities…
Math- JavaScript: Available
- WebAssembly: Builds
- C: Builds
- Native macOS: Builds
- Native Windows: Not checked
- Native Linux: Not checked
- Rust: Not checked
- GPU: Experimental
- Cortex-M: Experimental
- Ring stack
@maru/math-ring-stack
Ring stacks of a heptatonic scale: line-of-thirds order, hinge, signed positions -3..+3, the diatonic stack at a position and height as pitch classes or close intervals, ring…
Math- JavaScript: Available
- WebAssembly: Not checked
- C: Builds
- Native macOS: Not checked
- Native Windows: Not checked
- Native Linux: Not checked
- Rust: Not checked
- GPU: Experimental
- Cortex-M: Experimental
- Scale
@maru/math-scale
Static scale masks, key/enable-mask/reference-A mapping and a hysteretic nearest-note quantizer with pass-through.
Math- JavaScript: Available
- WebAssembly: Not checked
- C: Builds
- Native macOS: Not checked
- Native Windows: Not checked
- Native Linux: Not checked
- Rust: Not checked
- GPU: Experimental
- Cortex-M: Experimental