Scientific Calculator

0
History
No history yet. Successful calculations are saved in this browser only.
Everything is calculated in your browser. Your input is never uploaded to the server and no account is required.

Trigonometry, logarithms, powers, factorials and angle modes

How to use a scientific calculator online: from expression to result

A scientific calculator is an online expression calculator supporting arithmetic, parentheses, powers and roots, factorials, trigonometric functions, logarithms, and percentages.

The expression is first split into numbers, operators, and function names, then organized according to operator precedence before evaluation. Parentheses and functions can therefore be nested. The entire calculation runs in the browser, and your input is never uploaded to the server.

How is operator precedence handled?

Multiplication and division are performed before addition and subtraction, while parentheses take precedence over other operations. For example, 2+3×4 gives 14, while (2+3)×4 gives 20. Exponentiation has higher precedence than multiplication and division and is right-associative, so 2^3^2 is evaluated as 2 to the ninth power. The percentage key follows common calculator semantics: 50% alone equals 0.5, while 500+20% uses 20% of 500 and gives 600.

How do I enter negative numbers, square roots and cube roots?

A minus sign can be used directly as a unary operator at the beginning of an expression or inside parentheses, such as -5+3 and 2×(-3). The square root button inserts a root expression with an opening parenthesis; enter the radicand and close the parenthesis. Switching to 2nd changes the square root function to the cube root function. Negative numbers are supported because negative real numbers have real cube roots.

Should trigonometric functions use degrees or radians?

The DEG button switches between degree and radian modes. In degree mode, sin 30 returns 0.5 and inverse trigonometric functions return results in degrees, such as asin(0.5) returning 30. In radian mode, both trigonometric arguments and inverse-function results use radians. Switching modes does not change the structure of the expression; it changes how trigonometric values are converted.

What are the limits of factorials and powers?

Factorial accepts only non-negative integers. Entering 2.5! produces an error because factorial requires an integer. Factorials above 170 exceed the range of double-precision floating-point numbers, so the calculator reports an oversized result. Exponents may be fractional or negative, so a square root can also be represented as a power of 0.5, such as 9^0.5 = 3.

Why does 0.1 + 0.2 display as 0.3?

Computers represent decimal fractions in binary, so 0.1 and 0.2 cannot be represented exactly. Direct floating-point addition can therefore produce 0.30000000000000004. The calculator rounds intermediate results to 12 significant digits, so the displayed result is 0.3. Integer results are not rewritten, so large integers such as 2 to the 53rd power remain fully displayed.

Is the expression executed as code?

No. The expression passes through separate lexical analysis, syntax analysis, and evaluation stages. User input is never executed as a script and no calculation data is sent to the server. Calculation history is stored only in the browser localStorage, with up to 8 entries, and can be cleared individually.

What calculations does a scientific calculator support, and how are expressions parsed?

A scientific calculator combines arithmetic, parentheses, powers and roots, factorials, trigonometric and inverse trigonometric functions, common logarithms and natural logarithms in one keyboard. You can click the keys or edit the expression directly, then press equals to calculate the result.
  • Supports addition, subtraction, multiplication, division, parentheses and percentage calculations using mathematical precedence, such as 2+3×4 = 14 and 500+20% = 600
  • Supports square, cube and arbitrary powers, as well as square roots and cube roots, including real cube roots of negative numbers
  • Supports sin, cos and tan plus asin, acos and atan, with switching between degree DEG and radian RAD modes
  • Factorial accepts only non-negative integers, and factorials up to 170 do not overflow to infinity
  • Integer results preserve every digit, such as the exact 16-digit value of 2 to the 53rd power; decimals are rounded to 12 significant digits, so 0.1 + 0.2 displays as 0.3
  • Calculation history is stored only in the local browser, with up to 8 entries that can be recalled; input is never uploaded
For dedicated percentage, fraction or ratio calculations, use the percentage calculator, fraction calculator or ratio calculator. This page focuses on expressions and function calculations.
Comments 0
No comments yet. Be the first to comment!
avatar
Comment content cannot be empty
0/255