What order of operations does the Expression Evaluator use?
The evaluator follows the standard PEMDAS/BODMAS order: Parentheses first, then Exponents (^), then Multiplication and Division (left to right), then Addition and Subtraction (left to right). You can always use parentheses to force a specific evaluation order. See also our Scientific Calculator.
How do I write exponents in an expression?
Use the caret symbol ^ to denote exponentiation. For example, 2^10 evaluates to 1024, and 3^2 evaluates to 9. Exponents are evaluated right-to-left, so 2^3^2 = 2^(3^2) = 2^9 = 512.
Which mathematical functions are supported?
The evaluator supports Abs, Sqrt, Cbrt, Sin, Cos, Tan, Asin, Acos, Atan, Log (natural), Log10, Exp, Floor, Ceil, Round, and Sign. Function names are case-insensitive — you can write sqrt(9) or Sqrt(9). Trig functions expect angles in radians.
Can I use Pi or Euler's number (e) in my expression?
Yes. You can write PI or pi to use the value of π (≈ 3.14159265), and E or e to use Euler's number (≈ 2.71828182). For example, PI * 5^2 calculates the area of a circle with radius 5.
What happens if my expression contains a syntax error?
If the expression cannot be parsed — for example due to unmatched parentheses, an unknown function name, or invalid characters — the evaluator will return an error message explaining what went wrong. Check your brackets and function names, then try again.
Does the evaluator handle division by zero?
Attempting to divide by zero (e.g. 5/0) returns Infinity or -Infinity as defined by IEEE 754 floating-point arithmetic, and the result is flagged accordingly. Similarly, operations like Sqrt(-1) return NaN (Not a Number) since the result is complex.
Is the modulo operator supported?
Yes, use the % symbol for the modulo (remainder) operation. For example, 17 % 5 returns 2, because 17 = 3×5 + 2. Modulo works on both positive and negative numbers.