This is an expression calculator, not a four-function one. Rather than accumulating a running total as you press keys, it holds the whole expression on the top line and re-evaluates it from scratch after every press. Two consequences are worth knowing before you trust a result: precedence is applied to the entire expression at once, and the trigonometric keys work in radians, not degrees.
Operator precedence and how the expression is read
The expression is evaluated with standard mathematical precedence. Parentheses go first, then multiplication and division, then addition and subtraction, with equal-precedence operations running left to right. So 2 + 3 × 4 gives 14, not 20. If you meant the other reading, press ( and ) to force it: (2 + 3) × 4 = 20.
A few behaviours follow from the live-preview design:
- Half-finished expressions show “Error”. The moment you press sin, the expression contains an unclosed bracket, so the preview reads Error until you type the argument and close it. That is the preview being honest, not a fault.
- There is no implicit multiplication. Typing 2 then π produces an invalid expression. You must press × between them.
- DEL removes one character at a time. Operators are stored with a space on each side, so clearing a stray + usually takes two presses, and backing out of sin( takes four.
- AC clears the expression but keeps the history list. Only reloading the page empties the history.
Radians, not degrees — the most common surprise
The sin, cos and tan keys take their argument in radians, and there is no DEG/RAD toggle. Enter sin(90) expecting 1 and you get 0.8939966636, because 90 radians is roughly 14.3 full turns around the circle and lands nowhere near a right angle.
To work in degrees, convert inline by multiplying by π and dividing by 180:
- sin( 90 × π ÷ 180 ) = 1
- cos( 60 × π ÷ 180 ) = 0.5
- Or use the shorter form for the common angles: sin( π ÷ 2 ) = 1
If you are converting a batch of angles rather than one, the angle converter handles degrees, radians and gradians directly. Note also that the display rounds to ten decimal places, which is why sin(π) reads as a clean 0 rather than the 1.22×10−16 that binary arithmetic actually produces.
What each function key does
- sin, cos, tan — open the function and wait for an argument in radians. Close the bracket yourself.
- √ — square root. A negative argument returns NaN, since there is no complex-number support.
- x² — squares the number immediately to its left. This one has a sharp edge, described below.
- log — base-10 logarithm. log(100) = 2.
- ln — natural logarithm, base e. ln(e) = 1. Both log(0) and ln(0) return −Infinity.
- π and e — insert the two constants at full machine precision (π ≈ 3.14159265, e ≈ 2.71828183), each wrapped in its own brackets so it never breaks the surrounding expression.
- n! — factorial of the whole number immediately to its left. 5! = 120, 0! = 1.
There are no memory keys on this layout. The history panel under the keypad does that job instead: pressing = files the expression and its answer at the top of the list, which holds the last 20 entries, and clicking any row reloads that expression and runs it again. Pressing = also leaves the answer in the input line, so you can keep operating on it.
Rounding and floating-point surprises
Every result is computed in binary double-precision and then rounded to ten decimal places before display. That hides most of the familiar noise — 0.1 + 0.2 shows as 0.3, not 0.30000000000000004 — but a few limits remain visible:
- x² only attaches to a literal number. 5 x² gives 25 as expected, but pressing x² after a closing bracket does not square anything. (2 + 3)x² returns 7, because the leftover caret falls through to a bitwise operation. Square a bracketed expression by multiplying it by itself instead.
- Large factorials lose exactness. 18! is the largest factorial below the exact-integer limit of 253; above that, results are the nearest representable value rather than the true integer, and 171! and beyond overflow to Infinity.
- Division by zero returns Infinity rather than an error message, matching the underlying floating-point standard.
- Ten decimal places is the display limit. A result whose meaningful digits sit further right will be shown as 0.
For routine percentage work, the dedicated percentage calculator is quicker than assembling the expression by hand here.
How to use the scientific calculator
- Tap the digit and operator keys to build your expression. It appears on the small grey line at the top of the display, with the running answer in large type below it.
- For a function, press sin, cos, tan, √, log or ln first, then the argument, then ) to close it.
- Doing trigonometry in degrees? Multiply the angle by π and divide by 180 inside the brackets.
- Use DEL to remove the last character, or AC to clear back to 0.
- Press = to commit the calculation. It joins the history list and becomes the starting value for your next expression.
- Click any history row to reload and re-run that calculation.
The keypad is the only input method — typing digits on a physical keyboard will not register.
Frequently Asked Questions
Can I switch the trig functions to degrees?
No, there is no DEG mode. Multiply your angle by π and divide by 180 inside the function to convert on the spot.
Why does the display say “Error” while I am still typing?
The preview re-evaluates after every key press, so any incomplete expression — an open bracket, a trailing operator — is temporarily unevaluable. Finish the expression and the answer appears.
What is the difference between log and ln here?
log is base 10 and ln is base e, the usual convention in scientific work. For any other base, use the change-of-base identity: logb(x) = ln(x) ÷ ln(b).
Why did squaring a bracketed expression give a strange answer?
The x² key only recognises a plain number directly before it. Applied after a bracket or a constant it is not interpreted as a power at all. Multiply the expression by itself instead: (2 + 3) × (2 + 3).
Does it handle negative numbers and fractions?
Yes for both, using the − and . keys. Factorial is the exception: it expects a whole number, and a decimal argument will not evaluate.
How many digits of accuracy can I rely on?
Results are rounded to ten decimal places for display, over arithmetic carrying roughly 15 to 17 significant digits. Anything inside that range is reliable; very large integers and very small residuals are where the limits show.
Sources
- IEEE 754 binary64 (double-precision) floating point — the numeric format behind every result, and the source of the exact-integer limit at 253, the Infinity overflow behaviour, and NaN for the square root of a negative number.
- ECMAScript standard library conventions — log is implemented as the base-10 logarithm and ln as the natural logarithm, matching the standard mathematical naming.