You are a guest. Restricted access. Read more.

# Operators

## Built in operators

All common arithmetic operators are supported. Boolean operators are also fully supported. Boolean expressions are evaluated to be either 1 or 0 (true or false respectively).

An indicates that the operator can be used with the specific type of variable. Refer to the grammar for detailed information about operator precedence.

Operators DoubleComplexStringVector
Power^ Â  Â
Boolean Not! Â  Â  Â
Unary Plus, Unary Minus+x, -x Â  Â
Modulus% Â  Â  Â
Division/ Â
Multiplication* Â
Addition, Subtraction+, - (only +) Â
Less or Equal, More or Equal⇐, >= Â  Â  Â
Less Than, Greater Than<, > Â  Â  Â
Not Equal, Equal!=, == Â
Boolean And&& Â  Â  Â
Boolean Or|| Â  Â  Â

# Functions

Note that you can always add new custom functions. Each of the following functions can be applied to objects of the types indicated.

Operator  Notation DoubleComplexStringVector
Sinesin(x) Â  Â
Cosinecos(x) Â  Â
Tangenttan(x) Â  Â
Arc Sineasin(x) Â  Â
Arc Cosineacos(x) Â  Â
Arc Tangentatan(x) Â  Â
Arc Tangent (with 2 parameters)atan2(y, x) Â  Â  Â
Hyperbolic Sinesinh(x) Â  Â
Hyperbolic Cosinecosh(x) Â  Â
Hyperbolic Tangenttanh(x) Â  Â
Inverse Hyperbolic Sineasinh(x) Â  Â
Inverse Hyperbolic Cosineacosh(x) Â  Â
Inverse Hyperbolic Tangentatanh(x) Â  Â
Natural Logarithmln(x) Â  Â
Logarithm base 10log(x) Â  Â
Exponential (e^x)exp(x) Â  Â
Absolute Value / Magnitudeabs(x) Â  Â
Random number (between 0 and 1)rand() Â  Â  Â  Â
Modulusmod(x,y) = x % y Â  Â  Â
Square Rootsqrt(x) Â  Â
Sumsum(x,y,z) Â
Ifif(cond,trueval,falseval) Â  Â  Â
Str (number to string)str(x)
Binomial coefficientsbinom(n,i) Integer values

Â Â DoubleComplexStringVector
Complex Modulus (Absolute Value)cmod© Â  Â