Error Messages Explained
This calculator distinguishes eleven different error conditions rather than showing a single generic "Error". Here is what each one means.
Last updated: August 2026 · Written and verified by Akash Pandey
Most calculators collapse every failure into one word. That is unhelpful: "syntax error" tells you something is wrong but not what. The engine here classifies each failure so the message can point at the actual problem.
The full list
| Message | What triggers it | How to fix it |
|---|---|---|
| Enter an expression. | You pressed = with nothing typed. | Type something first. |
| The “%” needs an operation. | A percent sign with nothing to apply it to, such as a bare 15% or (50%). | Give it an operation: 200 × 15% or 200 + 15%. |
| Check your parentheses. | A bracket-matching failure reported by the parser itself. In practice this is hard to reach - unclosed brackets are auto-balanced, and a stray closing bracket surfaces as "unexpected symbol" instead. | Count the openers and closers. |
| Expression looks unfinished. | The expression ends where a value was expected - a trailing 2 +, for example. | Complete the final operation. |
| Unexpected symbol in expression. | A character the parser cannot place - most often a stray closing bracket such as 2)+3, or formatting picked up from a paste. | Remove the stray character, or paste as plain text. |
| Unknown name: … | An identifier the calculator does not recognise, such as a stray xyz or 2 + abc. | Check the spelling against the function reference. |
| Wrong number of arguments for a function. | Too few or too many arguments, such as sqrt(1, 2, 3) or abs(1, 2). | Check how many the function needs - sqrt takes one, nCr and nPr take two. |
| Undefined result — check for division by zero or an out-of-range value. | The result is infinite: division by zero, log(0), or an overflow such as 200!. | Check for a zero denominator or an argument outside the function's domain. |
| Result is undefined for this input. | The result is not a number at all: √(−4), asin(2), (−8)^0.5, nCr(5, 7), or 7 mod 0. | The input is outside the function's real domain. See the notes below. |
| Expression is incomplete. | The expression evaluates to a function rather than a value - typically a function name with no arguments, such as a lone sin. | Give the function an argument. |
| Invalid expression. | A parse failure that matches none of the above. | Clear with AC and re-enter. |
The two "undefined" messages are different
This distinction is deliberate and worth understanding, because it tells you which kind of problem you have.
- "Undefined result — check for division by zero…" means the computation produced an infinity. The operation was valid but the numbers ran off the end -
1 ÷ 0, or a factorial so large it overflows. - "Result is undefined for this input" means the computation produced "not a number". The input was outside what the function can accept at all - the square root of a negative, or an inverse sine of 2.
The first says the answer is too big to represent; the second says there is no real answer.
Cases that are undefined here on purpose
| Input | Result | Why |
|---|---|---|
| √(−4) | undefined | No real square root of a negative number. Use ∛ for real cube roots of negatives. |
| asin(2) | undefined | Sine never exceeds 1, so no angle has this sine. |
| log(0) | undefined | No power of 10 produces 0. |
| log(−5) | undefined | No real power of 10 produces a negative number. |
| 7 mod 0 | undefined | Deliberate: math.js would return 7, but modulo by zero is mathematically undefined. |
| (−3)! | invalid expression | Factorials count arrangements; there is no arrangement of −3 objects. Note that decimals are accepted, via the gamma function - 3.5! ≈ 11.6317. |
| nCr(5, 7) | undefined | You cannot choose 7 items from 5. |
| nCr(5.5, 2) | undefined | Deliberate: integer domain only, rather than a gamma-function generalisation. |
Things that are not errors
- Unclosed brackets while typing. The live preview balances them so you keep seeing a running result. Pressing = evaluates that balanced form.
- A very long string of digits. Results above 2⁵³ − 1 switch to scientific notation - a display choice, not an error. See floating-point arithmetic.
- 0.1 + 0.2 showing exactly 0.3. The result is rounded to 12 significant digits, which removes floating-point noise.
Frequently Asked Questions
Why does the calculator say my percentage needs an operation?
Because a percentage is meaningless without something to apply it to. A bare 15% could mean 0.15 or 15% of some earlier value; rather than guess, the calculator waits. Write 200 × 15% or 200 + 15%.
What is the difference between the two undefined messages?
One means the result was infinite - the numbers overflowed or you divided by zero. The other means the result was not a number at all, because the input was outside the function's domain.
Why is the square root of a negative number undefined?
Because no real number squared gives a negative result. The answer exists in the complex numbers, which this calculator does not cover. Cube roots of negatives are fine - use the ∛ key.
Why does 7 mod 0 give an error instead of 7?
Modulo by zero is mathematically undefined. The underlying library returns the dividend, which is misleading, so this calculator deliberately overrides it to report an error.
I get "unexpected symbol" after pasting. Why?
Pasted text often carries characters that look like operators but are not - typographic minus signs, non-breaking spaces, or invisible formatting. Retype the expression, or paste it as plain text.