Arithmetic
Twelve nodes for arithmetic and mathematical operations. Use them to combine, reshape, and constrain signals between other nodes.
Add
Outputs the sum of two values.
| Port | Direction | Type | Default | Description |
|---|---|---|---|---|
| A | Input | Scalar | 0.0 | First value |
| B | Input | Scalar | 0.0 | Second value |
| Out | Output | Scalar | — | A + B |
Subtract
Outputs the difference of two values.
| Port | Direction | Type | Default | Description |
|---|---|---|---|---|
| A | Input | Scalar | 0.0 | Value to subtract from |
| B | Input | Scalar | 0.0 | Value to subtract |
| Out | Output | Scalar | — | A − B |
Multiply
Outputs the product of two values.
| Port | Direction | Type | Default | Description |
|---|---|---|---|---|
| A | Input | Scalar | 0.0 | First value |
| B | Input | Scalar | 0.0 | Second value |
| Out | Output | Scalar | — | A × B |
Divide
Outputs the quotient of two values. Division by zero returns 0.
| Port | Direction | Type | Default | Description |
|---|---|---|---|---|
| A | Input | Scalar | 0.0 | Dividend |
| B | Input | Scalar | 0.0 | Divisor |
| Out | Output | Scalar | — | A ÷ B |
Power
Raises a value to an exponent.
| Port | Direction | Type | Default | Description |
|---|---|---|---|---|
| Base | Input | Scalar | 0.0 | Base value |
| Exponent | Input | Scalar | 2.0 | Power to raise to |
| Out | Output | Scalar | — | Base ^ Exponent |
Min
Outputs the smaller of two values.
| Port | Direction | Type | Default | Description |
|---|---|---|---|---|
| A | Input | Scalar | 0.0 | First value |
| B | Input | Scalar | 0.0 | Second value |
| Out | Output | Scalar | — | Minimum of A and B |
Max
Outputs the larger of two values.
| Port | Direction | Type | Default | Description |
|---|---|---|---|---|
| A | Input | Scalar | 0.0 | First value |
| B | Input | Scalar | 0.0 | Second value |
| Out | Output | Scalar | — | Maximum of A and B |
Mod
Outputs the remainder after division. Mod by zero returns 0.
| Port | Direction | Type | Default | Description |
|---|---|---|---|---|
| A | Input | Scalar | 0.0 | Dividend |
| B | Input | Scalar | 0.0 | Divisor |
| Out | Output | Scalar | — | A mod B |
Clamp
Restricts a value to a range.
| Port | Direction | Type | Default | Description |
|---|---|---|---|---|
| Value | Input | Scalar | 0.0 | Value to constrain |
| Min | Input | Scalar | 0.0 | Lower bound |
| Max | Input | Scalar | 1.0 | Upper bound |
| Out | Output | Scalar | — | Value clamped to Min–Max |
Sin
Outputs the sine of the input, where 1.0 = one full turn.
| Port | Direction | Type | Default | Description |
|---|---|---|---|---|
| Value | Input | Scalar | 0.0 | Input in turns (0–1 = one cycle) |
| Out | Output | Scalar | — | sin(Value × 2π) |
Cos
Outputs the cosine of the input, where 1.0 = one full turn.
| Port | Direction | Type | Default | Description |
|---|---|---|---|---|
| Value | Input | Scalar | 0.0 | Input in turns (0–1 = one cycle) |
| Out | Output | Scalar | — | cos(Value × 2π) |
Abs
Outputs the absolute value.
| Port | Direction | Type | Default | Description |
|---|---|---|---|---|
| Value | Input | Scalar | 0.0 | Input value |
| Out | Output | Scalar | — |
Tips
- Multiply is the most common math node. Use it to gate a signal (multiply by 0 or 1), scale amplitude, or combine two modulation sources.
- Clamp is useful after Multiply Add to ensure a signal stays within bounds.
- Sin and Cos expect input in turns (0–1), not radians. A Phasor cycling 0–1 produces one full sine cycle.
- Power with Exponent 2 squares the input, useful for creating curves from linear ramps.
- Mod creates repeating patterns from ascending signals. Feed a Phasor into Mod with B = 0.25 for four repeats per cycle.
Related
- Multiply Add: combined scale + offset in one node
- Oscillator: generates waveforms directly instead of building from Sin/Cos
- From Polar: uses Sin/Cos internally for coordinate conversion