The parser in the Mathematics VIs supports all elements that Formula Nodes support with the following exceptions:

  • Variables—Only a, a0, …, a9, … z, z0, …, z9, are valid.
  • Logical, conditional, inequality, equality—?:, |, ||, &, &&, !=, ==,<, >, <=, and >= are not valid.
  • Functions—atan2, max, min, mod, pow, rem, and sizeOfDim are not valid. You can use these functions in a Formula Node or use their corresponding LabVIEW functions.

The following table lists functions that the parser in the Mathematics VIs supports but Formula Nodes do not.

Function Corresponding LabVIEW VI Description
ci(x) Cosine Integral Evaluates the cosine integral for any real nonnegative number x.
gamma(x) Gamma Evaluates the gamma function or incomplete gamma function for x.
rand( ) Random Number (0 – 1) Produces a floating-point number between 0 and 1 exclusively.
si(x) Sine Integral Evaluates the sine integral for any real number x.
spike(x) Spike Generates the spike function for any real number x.
square(x) Square Generates the square function for any real number x.
step(x) Step Generates the step function for any real number x.

To use these functions with a Formula Node, place their corresponding VIs on the block diagram and wire their outputs to the Formula Node. For example, use the Cosine Integral VI in place of ci.

The following table lists cases where Formula Nodes and the parser in the Mathematics VIs use different syntax.

Element Formula Node Parser VI Routine
π pi pi(1) =π, pi(2) = 2π, 2pi or 2(pi) return an error
Exponentiation ** ^
int Rounds to the nearest integer. Rounds to the next smaller integer.

The precedence of operators is the same for the Mathematics VIs as in Formula Nodes. Refer to Formula Parsing VIs for more information about specific Formula Parsing VIs.

The parser in the Mathematics VIs uses the following syntax:

function (argument)