- Audio
- Control
Math
Purpose
Section titled “Purpose”Math combines up to four control signals into one. For common cases the Operation menu covers it: add, multiply, min, max, mix, absolute value, differentiate, integrate, sample-hold, quantize, wrap, and fold. For everything else there is Expression, a small compiled RPN language with arithmetic, comparison, selection, integration, differentiation, delay, sample-hold, and slew. Programs run within fixed instruction and state budgets, and an invalid edit keeps the last good program running instead of breaking the signal.
Wire control signals into a through d and take the result from out. Pick an Operation for simple combinations, or type an Expression to replace it. Unwired inputs read as zero, except b, which reads the Constant parameter, so a b * with only a wired scales a signal by a knob.
Inputs and outputs
Section titled “Inputs and outputs”- Input 0-3: a, b, c, d — the control signals to combine. All optional.
- Output 0: out — the computed result.
Controls
Section titled “Controls”- Operation —
add,multiply,min,max,mix(blend a to b by c),abs,differentiate,integrate,sample_hold(hold a on c’s rising edge),quantize,wrap, orfold. - Constant — the
kvalue in expressions, the fallback for the unwiredbinput, and the step size forquantize. - Min and Max — the range used by
quantize,wrap, andfold. - Slew — output smoothing time in seconds, applied after the computation.
- Expression — RPN program. When non-empty and valid, it replaces the Operation menu. Tokens:
a b c d k time phase, numeric literals,+ - * / min max abs sign clamp wrap fold mix < > select integrate differentiate delay sample_hold slew.
- RPN reads left to right with a stack:
a b + 0.5 *averages two inputs;a 0.5 > b c selectswitches between b and c on a threshold of a. - An expression that fails to compile is simply not installed; the previous program keeps running, so live edits cannot glitch a performance.
timeandphasetokens give expressions a clock without wiring one in.
Inputs
-
arow -
brow -
crow -
drow
Outputs
-
outrow
Parameters
Section titled “Parameters”op('math').par.Constant - Default:
0.5- Range:
- -100000 to 100000
op('math').par.Min - Default:
0- Range:
- -100000 to 100000
op('math').par.Max - Default:
1- Range:
- -100000 to 100000
op('math').par.Slew - Default:
0- Range:
- 0 to 60
op('math').par.Expression - Default:
"" (Empty String)