Calculators and units TOOL

Expression calculator

Calculate expressions with parentheses, arithmetic and powers.

Use +, −, *, /, %, ^, parentheses, pi, e, sqrt, abs, sin, cos, tan, log and ln. Trigonometric functions use radians.

Expression calculator · How to use

Calculate expressions with parentheses, arithmetic and powers.

Example

(2 + 3) * 4 → 20

Things to know

Use parentheses, arithmetic and powers. This tool does not execute general program code.

Your files and results are never sent to a server. Everything is processed in this browser.

How to calculate an expression with parentheses

Type the full formula when you want to see and recheck it instead of pressing calculator keys one step at a time. Powers, multiplication and division are evaluated before addition and subtraction, which helps when checking an invoice total or values plugged into a formula.

When to use this tool

  • Double-check an invoice total of unit price times quantity
  • Plug values into a formula with roots and powers
  • Look up common and natural logarithms
  • Evaluate pasted text that uses the × and ÷ signs

Step-by-step instructions

  1. Type the formula in Expression, for example (2 + 3) * 4.
  2. Use functions such as sqrt(), log() and sin(), and the constants pi and e, as needed.
  3. Choose Calculate to see the calculation result.

Frequently asked questions

Does % calculate a percentage?

No. Here % is the remainder operator, so 10 % 3 is 1. For 15 percent of 50,000, enter 50000 * 15 / 100 or use the percentage calculator. Thousands separators such as commas cause an error.

Why is sin(30) not 0.5?

Trigonometric functions use radians. For 30 degrees, enter sin(30 * pi / 180). log is the base-10 logarithm and ln is the natural logarithm.

Can I skip the multiplication sign, as in 2(3+4)?

No. Write 2 * (3 + 4) with an explicit *. Powers are evaluated right to left, so 2^3^2 is 512, and -2^2 is -4. Division by zero or any result that is not a finite number shows an error.

Save only the tools you need.