Skip to content

Math

Math

The Math node applies a selected arithmetic, trigonometric, or comparison operation to two input values. Values can be provided via incoming connections or slider parameters.

Availability

This node requires Pro.

Common uses

  • Use clamp to keep results between 0 and 1.
  • Connect grayscale maps to apply operations per-pixel.

Input ports

  • a

  • b

  • Takes two input values (either parameters or connections).

Output ports

  • out

  • Outputs the calculated result (r channel).

Parameters

ParameterTypeDefaultRange or values
Operationenumaddadd, subtract, multiply, divide, power, logarithm, sqrt, inversesqrt, absolute, exponent, minimum, maximum, lessThan, greaterThan, sign, round, floor, ceil, truncate, fraction, modulo, snap, pingpong, sine, cosine, tangent, arcsine, arccosine, arctangent, arctan2, radians, degrees
Value 1float0.5-10 to 10
Value 2float0.5-10 to 10
Clampboolfalse-

Behavior

  • Evaluates standard math operations.
  • If map inputs are provided, runs per-pixel.

Common mistakes

  • Division by zero defaults to 0 safely.
  • Using non-grayscale maps might yield unexpected results.

View the shared source content