HomeAll CategoriesCalculator with Steps | Free Online Math Solver

Calculator with Steps | Free Online Math Solver

Calculator: Free Online Math Solver with Steps

A free online calculator that shows the working. Type any sum, fraction, power, root or trig value and get the exact answer, the decimal, and every step in the order of operations. It also solves equations and draws graphs.

Math SolverStep by StepExact AnswerEquation SolverGraphingFree

By Reegan (Reegan Pushbanathan), StatsUnlock · Last updated: 12 November 2026

⚡ 0. Quick Answer

This calculator works out any math expression in the correct order of operations and shows the exact answer with every step.

Example: 2 + 3 × (4 − 1)² ÷ 6. Brackets give 3, the power gives 9, then 3 × 9 = 27, 27 ÷ 6 = 9/2, and 2 + 9/2 = 13/2, which is 6.5.

Brackets → Powers → × ÷ (left to right) → + − (left to right)

Rule of thumb: a power is done before a minus sign, so −3² = −9. Type (−3)^2 if you want 9.

Key Takeaways

  • This calculator gives the exact answer first (13/2, 7√3, π/6) and the decimal second, so nothing is rounded too early.
  • The order of operations is fixed: brackets, powers, × ÷, + −, with × ÷ and + − worked left to right.
  • 0.1 + 0.2 = 3/10 exactly here, because typed decimals are turned into fractions before any arithmetic.
  • Trig needs the right angle mode: sin(30) = 1/2 in DEG but −0.988 in RAD.
  • Every answer is checked twice: once with exact arithmetic and once with an independent decimal calculation.

📚 1. What Is a Calculator with Steps?

A calculator with steps is a math calculator that shows how it reached the answer, one operation at a time, instead of only printing a number. A math solver calculator goes one step further and also solves equations such as 2x² − 4x − 6 = 0.

You use it to check homework, to learn the order of operations, to get exact fractions and surds that a basic calculator turns into long decimals, and to solve or graph equations quickly. On the headline problem, 2 + 3 × (4 − 1)² ÷ 6, a simple calculator that works strictly left to right gives 22.5. The correct answer is 6.5, because the power and the brackets come first.

Who uses it: school students from Grade 6 to Grade 12 (CBSE, ICSE, IGCSE, GCSE, A level, SAT, ACT), first-year university students in algebra and calculus, teachers building answer keys, engineers and programmers who need an exact result, and parents checking homework.

1.1 Basic calculator vs scientific calculator vs this math solver

FeatureBasic (simple) calculatorScientific calculatorThis calculator with steps
Order of operationsOften left to right onlyYesYes, and each step is shown
Exact fractions (13/2)NoSome modelsAlways, reduced to lowest terms
Exact surds (7√3) and π (π/6)NoSome modelsYes
Very large numbers (25!, 70!)OverflowsRounds to 10 digitsEvery digit, exactly
Solve equationsNoEquation mode on someLinear, quadratic, polynomial, numeric
GraphsNoNo (graphing models only)Yes, with roots and turning points
Checks its own answerNoNoYes, Verified badge
Best forShopping totalsExams where it is allowedLearning, checking and exact answers
Order of operations ladderFour rungs: brackets, powers, multiply and divide, add and subtract, applied to 2 + 3 times (4 minus 1) squared divided by 6, giving 13/2.2 + 3 × (4 − 1)² ÷ 61Brackets4 − 1 = 32Powers3² = 93× and ÷, left to right3 × 9 = 27, 27 ÷ 6 = 9/24+ and −, left to right2 + 9/2 = 13/2Answer: 13/2 = 6.5
Figure 1. The order of operations ladder for 2 + 3 × (4 − 1)² ÷ 6. Each rung is done before the one below it, and the expression shrinks to 13/2.

🧮 2. Enter Your Problem

= Type a sum such as 8+2
M = empty

Type it the way you write it: 3/4 + 5/6, 2(3+4), sqrt(48), 2^10, 25!, sin(30), log(1000), ncr(10,3). Spaces are optional. Use ^ for powers and * or a space-free 2x style for multiply.

History tape (last 20, tap to reuse)

Linear, quadratic and polynomial equations up to degree 30 are solved exactly where an exact answer exists (fractions, surds, complex roots). Other equations, such as 2^x = 10 or sin(x) = 0.5, are solved numerically between x = −100 and 100. If there is no “=”, the expression is set equal to 0.

This is a free graphing calculator online. Trig functions use the angle mode below, so choose RAD for graphs such as y = sin(x) over −2π to 2π.

Teachers use this to build an answer key. Lines with “=” or x are solved as equations, the rest are calculated. Download Doc then gives every answer with its working.

📊 3. Results and Step-by-Step Solution

Answer
___
Press Calculate to see the exact answer, the decimal answer and every step.

🧠 4. Understanding Your Answer, In Detail

4.1 What your answer means

___ Solve a problem above to fill this in.

4.2 The order the calculator followed

___ Solve a problem above to fill this in.

4.3 Exact answer or decimal: which one to write

___ Solve a problem above to fill this in.

An exact answer such as 13/2, 2√2 or π/3 has no rounding at all. A decimal is a rounded copy. Write the exact form when a question says “exact”, “simplest form” or “in surd form”. Write a decimal when the question gives a number of decimal places or significant figures, or when the answer is a measurement.

4.4 How the answer was checked

___ Solve a problem above to fill this in.

4.5 Why 0.1 + 0.2 is exactly 0.3 here

Most computer calculators store numbers in binary floating point, where 0.1 cannot be stored exactly, so 0.1 + 0.2 comes out as 0.30000000000000004. This calculator reads 0.1 as the fraction 1/10 and 0.2 as 2/10 before adding, so the answer is exactly 3/10. Goldberg (1991) explains why binary floating point behaves this way.

4.6 What the angle mode changes

sin, cos and tan read the angle in the mode you choose. In DEG, sin(30) = 1/2 exactly. In RAD, sin(30) means 30 radians, which is about 1,719°, so the answer is −0.988. If a trig answer looks wrong, the angle mode is the first thing to check. In RAD mode, write π in the angle (sin(pi/6) = 1/2) to get exact values.

4.7 When there is no real answer

Some inputs have no real value: √(−4), ln(0), log of a negative number, tan(90°) and anything divided by 0. The calculator stops and says why, instead of printing NaN or Infinity. For √(−4) it also tells you the complex answer, 2i. In the equation solver, a negative discriminant gives a pair of complex roots such as −1 ± 2i.

4.8 How this links to the next topic

Order of operations is the base of algebra. Once it is solid, the next steps are simplifying expressions, solving linear equations, then quadratics. For a full quadratic working with the discriminant and vertex, use the quadratic formula calculator. For comparing two values, the greater than sign calculator shows which is bigger and why.

✍ 5. How to Write the Answer

▶ Solve a problem above to fill all five cards with your own answer.

1. Exam or homework answer (full working)
2 + 3 × (4 − 1)² ÷ 6 = 2 + 3 × 3² ÷ 6 = 2 + 3 × 9 ÷ 6 = 2 + 27 ÷ 6 = 2 + 9/2 = 13/2
📌 Conventions
  • Write one operation per line, so a marker can follow you and give method marks.
  • Keep fractions until the last line. Convert to a decimal only if the question asks.
  • Box or underline the final answer.
2. Final answer only
13/2 (= 6.5)
📌 Conventions
  • For equations write x = −1 or x = 3, or the set {−1, 3}.
  • Leave surds as surds (7√3) unless decimals are asked for.
  • Give 3 significant figures for measurements unless told otherwise.
3. Teacher’s answer key line
2 + 3 × (4 − 1)^2 ÷ 6   →   13/2 = 6.5
📌 Conventions
  • Use Batch mode to build a full key, then Download Doc.
  • Give both exact and decimal forms so any correct form gets the mark.
4. Report or lab write-up sentence
The value of 2 + 3 × (4 − 1)^2 ÷ 6 was 13/2 = 6.5, calculated exactly and checked with an independent decimal calculation.
📌 Conventions
  • State the units of every measured quantity.
  • Round only the reported value, never the inputs.
5. Plain text for a forum or chat
2 + 3*(4 - 1)^2 / 6 = 13/2
📌 Conventions
  • Use ^ for powers, * for multiply, / for divide and sqrt() for roots.
  • Put brackets around every fraction: (5/6)/(2/3), not 5/6/2/3.

∑ 6. Formulas Used

①
Order of Operations (PEMDAS / BODMAS / BIDMAS)
Brackets → Exponents → × ÷ left to right → + − left to right
P / BParentheses or Brackets: ( ), [ ], { } and the inside of | |
E / O / IExponents, Orders or Indices: powers and roots, worked right to left (2^3^2 = 2^9 = 512)
MD / DMMultiply and divide have equal rank. Work them left to right
ASAdd and subtract have equal rank. Work them left to right
Example2 + 3 × (4 − 1)² ÷ 6 = 2 + 3 × 9 ÷ 6 = 2 + 9/2 = 13/2
②
Fraction Arithmetic, Reduced by the GCD
a/b + c/d = (ad + bc) / bd  ·  a/b ÷ c/d = ad / bc
a, cNumerators, any integers
b, dDenominators, non-zero integers
ReduceDivide top and bottom by gcd(top, bottom), found with Euclid’s algorithm: 27/6 → gcd 3 → 9/2
DecimalsA typed decimal becomes a fraction first: 0.75 = 75/100 = 3/4
③
Powers and Roots
am × an = am+n  ·  a−n = 1/an  ·  a1/n = n√a
aThe base, a real number
m, nExponents. Whole-number powers stay exact, even 2^1000
a⁰a⁰ = 1 for any a, and 0⁰ is taken as 1 by convention
Rule−3² = −(3²) = −9, but (−3)² = 9
④
Simplifying a Square Root (Surd)
√(k² × m) = k√m  ·  √48 = √(16 × 3) = 4√3
k²The largest perfect square that divides the number
mWhat is left. It has no square factor, so it stays under the root
Like surdsAdd only same-root terms: 4√3 + 3√3 = 7√3
Rationalise1/(1 + √2) = (√2 − 1)/((√2)² − 1) = √2 − 1
⑤
Exact Trig Values and Angle Modes
sin 30° = 1/2  ·  sin 45° = √2/2  ·  sin 60° = √3/2  ·  180° = π rad
θThe angle, in degrees (DEG), radians (RAD) or gradians (GRAD, 400 per turn)
cos θcos θ = sin(θ + 90°)
tan θsin θ ÷ cos θ. Undefined when cos θ = 0 (90°, 270°)
Convertradians = degrees × π ÷ 180
⑥
Quadratic Formula (Equation Solver)
x = (−b ± √(b² − 4ac)) ÷ 2a
a, b, cCoefficients of ax² + bx + c = 0, with a ≠ 0
DDiscriminant b² − 4ac: positive gives 2 real roots, 0 gives 1, negative gives 2 complex roots
Example2x² − 4x − 6 = 0: D = 64, x = (4 ± 8) ÷ 4, so x = 3 or x = −1
⑦
The Check: Exact vs Independent Decimal
| exact − decimal check | ÷ max(1, |exact|) < 10−9 ⇒ Verified
exactThe answer from fraction, surd and π arithmetic, with no rounding
decimalThe same expression worked again in 64-bit floating point, a separate method
EquationsEach root is substituted back. Exact roots must give exactly 0

🔀 7. Order of Operations Flowchart, Step by Step

This flowchart shows how the calculator works out an expression step by step, from what you type to the checked answer. Every box uses the same worked example as the Excel, R, Python and by-hand sections: 2 + 3 × (4 − 1)² ÷ 6.

Start or result Data step Calculation step Yes or no check
StartThe expression you type2 + 3*(4 - 1)^2 / 6
1
Read the numbers and operators2 + 3 × (4 − 1)^2 ÷ 6Typed decimals become fractions here, so 0.5 would become 1/2.
CheckIs every bracket closed and every operator between two numbers?
YesOne ( and one ). Carry on.
No, stopThe calculator says what to add, for example “Add ) to match every (”.
2
Work out the brackets4 − 1 = 3Expression now: 2 + 3 × 3² ÷ 6
3
Work out the powers3² = 9Expression now: 2 + 3 × 9 ÷ 6
4
Multiply and divide, left to right3 × 9 = 27, then 27 ÷ 6 = 9/227/6 is reduced by gcd(27, 6) = 3. Expression now: 2 + 9/2
CheckIs there a minus sign in front of a power, like −3^2?
NoNot in this example. Carry on.
YesThe power goes first: −3^2 = −9. Use (−3)^2 for 9.
5
Add and subtract, left to right2 + 9/2 = 4/2 + 9/2 = 13/2Exact answer: 13/2
6
Convert to a decimal and a mixed number13 ÷ 2 = 6.5 = 6 1/2The decimal is exact here because 2 divides a power of 10.
CheckDoes an independent decimal calculation agree?
YesFloating point gives 6.5. Difference 0. Verified.
No, stopThe answer is flagged so you never copy a wrong value.
Result2 + 3 × (4 − 1)² ÷ 6 = 13/2 = 6.5Exact fraction VerifiedA left-to-right calculator would give 22.5, which is wrong.

Sections 9, 10 and 11 do the same calculation in Excel, R and Python, and Section 14 shows it by hand and on Casio and TI calculators.

📝 8. How to Use This Calculator

  1. Choose a tab. Calculator for sums and expressions, Solve Equation for anything with x and “=”, Graph for y = f(x), Batch for many problems at once.
  2. Type your problem or pick a sample. The Sample problem list has ten worked problems, from simple order of operations to a trap question.
  3. Use the keypad if you are on a phone. Keys insert sin(, sqrt(, ^, π and the other symbols at the cursor.
  4. Set the angle mode. DEG for degrees, RAD for radians. Only sin, cos, tan and their inverses use it.
  5. Choose decimal places. 2, 4, 6 or 10 places. The exact answer is never rounded.
  6. Press Calculate (or Enter). Nothing is worked out until you press it.
  7. Read the answer box. Exact answer first, decimal under it, and badges for the answer type and the Verified check.
  8. Follow the steps. Each step is one operation, with the rule it used and the expression after it.
  9. Look at the four charts. They show the value after each step, the operations used, the function or number line, and your history tape.
  10. Download the working. Download Doc saves every step as a text file. Download PDF prints a clean copy.

📈 9. How to Do Calculations in Excel

Excel is a powerful calculator once you know its rules. Every formula starts with =, and Excel follows the order of operations with one famous exception, explained in 9.4. Here is the headline problem, 2 + 3 × (4 − 1)² ÷ 6, worked in a sheet.

The whole thing in one cell: =2+3*(4-1)^2/6 returns 6.5. To see it as a fraction, use Format Cells → Fraction → Up to two digits, which shows 6 1/2.

9.1 The functions you need

You wantExcelNote
Power=4^3 or =POWER(4,3)Both give 64
Square root=SQRT(48)Decimal only: 6.92820323. Excel has no surd form
nth root=32^(1/5)Brackets around 1/5 are essential
Pi=PI()15 significant figures
Sine of degrees=SIN(RADIANS(30))Excel trig is always in radians
Logs=LOG(1000), =LN(5), =LOG(8,2)LOG is base 10 unless you give a base
Factorial=FACT(10)Every digit shown only up to 17!; #NUM! after 170!
Combinations=COMBIN(10,3), =PERMUT(10,3)120 and 720
GCD and LCM=GCD(84,36), =LCM(4,6)12 and 12
Remainder=MOD(-7,3)2: the sign follows the divisor
Rounding=ROUND(x,2), ROUNDUP, ROUNDDOWNROUND is half away from zero
Absolute value=ABS(-5)5
Solve an equationData → What-If Analysis → Goal SeekNumeric only; one root per run

9.2 Step by step

1Type the pieces into cells

Put 2 in A2, 3 in B2, 4 in C2, 1 in D2 and 6 in E2. Keeping numbers in cells lets you change one and see the answer update.

Excel screenshot: 2A spreadsheet showing cell A2 with the formula 2.calculator.xlsx - ExcelA2fx2ABCDE1firsttimesabdivisor223416

The five numbers of the worked example in row 2: 2, 3, 4, 1, 6.

2Work out the bracket

In F2 type =C2-D2. It returns 3.

Excel screenshot: =C2-D2A spreadsheet showing cell F2 with the formula =C2-D2.calculator.xlsx - ExcelF2fx=C2-D2ABCDEF1firsttimesabdivisora-b2234163

F2 holds the bracket: 4 − 1 = 3.

3Square it and do the × ÷

In G2 type =B2*F2^2/E2. Excel squares first, then multiplies and divides left to right: 3 × 9 ÷ 6 = 4.5.

Excel screenshot: =B2*F2^2/E2A spreadsheet showing cell G2 with the formula =B2*F2^2/E2.calculator.xlsx - ExcelG2fx=B2*F2^2/E2ABCDEFG1firsttimesabdivisora-b3x9/622341634.5

G2 = 4.5, which is the 9/2 of the exact working.

4Add the first term

In H2 type =A2+G2. It returns 6.5, the same as the one-cell formula.

Excel screenshot: =A2+G2A spreadsheet showing cell H2 with the formula =A2+G2.calculator.xlsx - ExcelH2fx=A2+G2ABCDEFGH1firsttimesabdivisora-b3x9/6answer22341634.56.5

H2 = 6.5. Format it as a fraction to see 13/2 written as 6 1/2.

5Check it with one formula

In I2 type =2+3*(4-1)^2/6=H2. Excel shows TRUE when both agree.

Excel screenshot: =2+3*(4-1)^2/6=H2A spreadsheet showing cell I2 with the formula =2+3*(4-1)^2/6=H2.calculator.xlsx - ExcelI2fx=2+3*(4-1)^2/6=H2ABCDEFGHI1firsttimesabdivisora-b3x9/6answercheck22341634.56.5TRUE

I2 = TRUE: the step-by-step cells and the single formula match.

9.3 The awkward cases

  • Square root of a negative number: =SQRT(-4) gives #NUM!. Use =IMSQRT(-4), which returns the text 2i.
  • Big numbers lose digits: Excel keeps 15 significant digits, so =FACT(25) shows 1.55112E+25 and the exact 15511210043330985984000000 is lost. This calculator gives every digit.
  • Trig in degrees: =SIN(30) is −0.988 because Excel reads 30 as radians. Wrap the angle in RADIANS().
  • Fractions typed into a cell: typing 3/4 into a cell often turns it into a date (3 April). Type 0 3/4 or =3/4 instead.

9.4 Why Excel might disagree with R, Python or your textbook

SituationWhat happensFix
=-3^2Excel gives 9. It applies the minus sign before the power. R, Python, this calculator and every textbook give −9Write =-(3^2) for −9 or =(-3)^2 for 9
=0.1+0.2=0.3Excel shows TRUE because it rounds the display to 15 digits, but stores 0.30000000000000004Compare with =ROUND(a-b,10)=0
=ROUND(2.5,0)3 in Excel; round(2.5) is 2 in R and Python (half to even)Say which rounding rule you used
=MOD(-7,3)2 in Excel and R; −1 in C, Java and JavaScriptUse the language’s floor-mod function
=LOG(100)2 in Excel (base 10); log(100) in R is 4.605 (base e)Use log10() in R and math.log10() in Python
=2^3^2Excel gives 64, working left to right: (2^3)^2. Maths, R and Python give 2^9 = 512Add brackets: =2^(3^2)

9.5 Charting it in Excel

To graph a function, put x values in column A (for example −5 to 5 in steps of 0.1) and =A2^2-4 in column B, then Insert → Scatter with Smooth Lines. Never use a Line chart for a function, because it spaces the x values evenly whatever they are. Then set both axes to cross at 0 (Format Axis → Vertical axis crosses at 0) so the roots are easy to read.

9.6 Excel errors you will probably hit

ErrorCauseFix
#NUM!Square root or log of a negative number, or a result above about 10^308Check the sign; use IMSQRT for complex roots
#DIV/0!Dividing by 0 or by an empty cellWrap in =IFERROR(A2/B2,"")
#VALUE!Text in a cell used as a numberRemove spaces and units such as “cm”
#NAME?A misspelled function, such as =SQR(4)Use SQRT, POWER, PI()
#SPILL!A formula returning many values is blocked by filled cellsClear the cells below or to the right

📈 10. How to Do Calculations in R

R is a full scientific calculator at its prompt. It follows the textbook order of operations, including −3^2 = −9 and 2^3^2 = 512. The script below works the headline example step by step, prints the exact fraction, checks it, and saves a 300 dpi chart of the value after each step.

Copy the whole block into RStudio, Posit Cloud or a file run with Rscript calc.R. Change only the line expr_txt <- ... to calculate something else. It uses base R plus MASS, which ships with every R installation.

10.1 The complete script

# StatsUnlock calculator: order of operations in R
library(MASS)                       # fractions() shows exact fractions

expr_txt <- "2 + 3*(4 - 1)^2 / 6"   # change this line

# 1. Evaluate the whole expression
value <- eval(parse(text = expr_txt))

# 2. The same thing, one operation at a time
s1 <- 4 - 1            # brackets     -> 3
s2 <- s1^2             # powers       -> 9
s3 <- 3 * s2           # multiply     -> 27
s4 <- s3 / 6           # divide       -> 4.5
s5 <- 2 + s4           # add          -> 6.5
step_values <- c(s1, s2, s3, s4, s5)

# 3. Report
cat("Expression :", expr_txt, "\n")
cat("Decimal    :", format(value, digits = 15), "\n")
cat("Exact      :", as.character(fractions(value)), "\n")
cat("Steps      :", step_values, "\n")

# 4. Check: the step-by-step result must equal the one-line result
residual <- abs(value - s5)
cat("Check      : residual =", residual,
    if (residual < 1e-9) "(Verified)\n" else "(CHECK FAILED)\n")

# 5. Traps worth seeing once
cat("-3^2 =", -3^2, "  (-3)^2 =", (-3)^2, "  2^3^2 =", 2^3^2, "\n")
cat("sin(30 deg) =", sinpi(30 / 180), "  log10(1000) =", log10(1000), "\n")

# 6. Figure: value after each step, saved at 300 dpi
png("calculator_steps.png", width = 1800, height = 1200, res = 300)
barplot(step_values, names.arg = c("( )", "^2", "x 3", "/ 6", "+ 2"),
        col = c(rep("#2563eb", 4), "#16a34a"),
        main = "2 + 3(4 - 1)^2 / 6, step by step", ylab = "Value")
abline(h = 0, col = "#475569")
dev.off()

10.2 What each part does

CodeWhat it does
eval(parse(text = ...))Turns the text into R code and runs it, so you can keep the expression as a string
fractions(value)Finds the simplest fraction for a decimal: 6.5 → 13/2. It approximates, so check irrational answers
s1 ... s5Each line is one rung of the order of operations
abs(value - s5)The check. Below 10^−9 means both routes agree
sinpi(30/180)sin of 30° with no rounding error from π; R’s sin() wants radians
png(..., res = 300)Opens a 300 dpi image file; dev.off() closes and saves it

R traps: log() is the natural log (use log10()); round(2.5) is 2 (half to even); doubles lose exact integers above 2^53, so factorial(25) is not exact (use the gmp package and factorialZ(25)); %% is the remainder and %/% is integer division.

10.3 What the figure shows

Five bars: 3, 9, 27, 4.5 and 6.5. The value jumps to 27 after the multiply and drops to 4.5 after the divide, then the final add gives 6.5 (green). It is a picture of the expression being simplified one rule at a time.

10.4 Common R problems and fixes

ProblemFix
Error: unexpected symbol in “2x”R needs the multiply sign: 2*x
sqrt(-4) gives NaN with a warningUse sqrt(as.complex(-4)), which gives 0+2i
sin(30) gives −0.988R uses radians: sin(30*pi/180) or sinpi(30/180)
0.1 + 0.2 == 0.3 is FALSEUse isTRUE(all.equal(0.1 + 0.2, 0.3))
factorial(171) is InfUse lfactorial() for the log, or gmp::factorialZ() for exact digits
There is no package called MASSRun install.packages("MASS") once

10.5 Useful one-liners

  • choose(10, 3) gives 120; factorial(5) gives 120.
  • polyroot(c(-6, -4, 2)) solves 2x² − 4x − 6 = 0 (coefficients in ascending order): 3 and −1.
  • uniroot(function(x) 2^x - 10, c(0, 10))$root gives 3.3219.
  • curve(x^2 - 4, -5, 5); abline(h = 0) draws a quick graph.
  • signif(pi, 3) gives 3.14; format(1e6, big.mark = ",") gives 1,000,000.

📈 11. How to Do Calculations in Python

Python is an exact calculator if you use the right tools. fractions.Fraction keeps answers as exact fractions, and SymPy gives surds and π in exact form. The script works the headline example, prints the exact and decimal answers, checks them, and saves a 300 dpi figure.

fractionsStandard library: exact rational numbers
sympyExact surds, π, and equation solving
matplotlibThe 300 dpi figure

Install once with pip install sympy matplotlib. It runs in a terminal (python calc.py), in Jupyter, or in Google Colab.

11.1 The complete script

# StatsUnlock calculator: order of operations in Python
from fractions import Fraction as F
import sympy as sp
import matplotlib
matplotlib.use("Agg")
import matplotlib.pyplot as plt

expr_txt = "2 + 3*(4 - 1)**2 / 6"   # change this line (use ** for powers)

# 1. Exact, one operation at a time
s1 = F(4) - 1          # brackets  -> 3
s2 = s1 ** 2           # powers    -> 9
s3 = 3 * s2            # multiply  -> 27
s4 = s3 / 6            # divide    -> 9/2 (exact, not 4.5)
s5 = 2 + s4            # add       -> 13/2
steps = [s1, s2, s3, s4, s5]

# 2. Whole expression: exact with SymPy, decimal with floats
exact = sp.nsimplify(sp.sympify(expr_txt, rational=True))
decimal = eval(expr_txt)

print("Expression :", expr_txt)
print("Steps      :", [str(s) for s in steps])
print("Exact      :", exact)
print("Decimal    :", decimal)

# 3. Check: exact steps, SymPy and floats must all agree
residual = abs(float(s5) - decimal) + abs(float(exact) - decimal)
print("Check      : residual =", residual, "(Verified)" if residual < 1e-9 else "(CHECK FAILED)")

# 4. Traps worth seeing once
print("-3**2 =", -3**2, " (-3)**2 =", (-3)**2, " 2**3**2 =", 2**3**2, " 3^2 =", 3 ^ 2, "(XOR, not a power)")
print("0.1 + 0.2 =", 0.1 + 0.2, " but F('0.1') + F('0.2') =", F("0.1") + F("0.2"))
print("sqrt(48) =", sp.sqrt(48), " sin(30 deg) =", sp.sin(sp.pi / 6))

# 5. Figure: value after each step, saved at 300 dpi
fig, ax = plt.subplots(figsize=(6, 4))
ax.bar(["( )", "^2", "x 3", "/ 6", "+ 2"], [float(s) for s in steps],
       color=["#2563eb"] * 4 + ["#16a34a"])
ax.set_title("2 + 3(4 - 1)^2 / 6, step by step")
ax.set_ylabel("Value")
fig.savefig("calculator_steps.png", dpi=300, bbox_inches="tight")
print("Saved calculator_steps.png")

11.2 What each part does

CodeWhat it does
F(4) - 1Starts an exact fraction calculation, so 27/6 stays 9/2 instead of 4.5
sympify(..., rational=True)Reads the text as maths with exact numbers; nsimplify tidies the form
eval(expr_txt)Ordinary float calculation, used as the independent check
3 ^ 2Bitwise XOR, which gives 1. Use ** for powers. This is the most common beginner bug in maths code
F("0.1")Exact one tenth. F(0.1) without quotes copies the float error
savefig(dpi=300)Writes the figure at print quality

Python traps: 1/3 is a float (use F(1, 3)); round(2.5) is 2 (half to even); math.sqrt(-1) raises an error while cmath.sqrt(-1) gives 1j; math.sin wants radians, so use math.sin(math.radians(30)).

11.3 What the figure shows

The same five bars as the R figure: 3, 9, 27, 4.5 and 6.5, with the final answer in green. Both scripts print Exact 13/2 and Decimal 6.5, matching the calculator above.

11.4 Common Python problems and fixes

ProblemFix
SyntaxError on 2xWrite 2*x
ModuleNotFoundError: sympyRun pip install sympy
Answer 0.30000000000000004Use Fraction or decimal.Decimal for exact decimal work
3^2 prints 1^ is XOR; use 3**2
OverflowError in math.factorial(...) / floatKeep it an int: Python integers have unlimited size
No window appearsThe script saves a PNG; in Jupyter add plt.show()

11.5 Useful one-liners

  • import math; math.comb(10, 3) gives 120 and math.factorial(25) gives every digit.
  • sp.solve(2*x**2 - 4*x - 6, x) (after x = sp.symbols("x")) gives [−1, 3].
  • sp.sqrt(48) + sp.sqrt(27) gives 7*sqrt(3).
  • math.gcd(84, 36) gives 12; pow(2, 100, 7) gives 2^100 mod 7.
  • f"{12345.678:,.2f}" gives 12,345.68.

📋 12. Reference Tables

12.1 Order of operations names around the world

NameWhere it is usedLetters
PEMDASUSAParentheses, Exponents, Multiplication, Division, Addition, Subtraction
BODMASIndia, UK, Pakistan, NigeriaBrackets, Orders (or Of), Division, Multiplication, Addition, Subtraction
BIDMASUKBrackets, Indices, Division, Multiplication, Addition, Subtraction
BEDMASCanadaBrackets, Exponents, Division, Multiplication, Addition, Subtraction
GEMDASPhilippines, parts of the USAGrouping, Exponents, Multiplication, Division, Addition, Subtraction

How to use this table: all five give the same answer. M and D have equal rank, and so do A and S; the letter order does not mean multiply comes before divide.

12.2 Exact trig values

Angle (deg)Radianssincostan
0°0010
30°π/61/2√3/2√3/3
45°π/4√2/2√2/21
60°π/3√3/21/2√3
90°π/210undefined
180°π0−10

How to use this table: these are the values the calculator returns exactly. Other angles return a 15-digit decimal.

12.3 Fraction, decimal and percent equivalents

FractionDecimalPercentFractionDecimalPercent
1/20.550%1/80.12512.5%
1/30.333…33.3%3/80.37537.5%
2/30.666…66.7%1/100.110%
1/40.2525%1/200.055%
3/40.7575%1/250.044%
1/50.220%1/1000.011%

How to use this table: a fraction ends as a decimal only if its denominator has no prime factors other than 2 and 5.

12.4 Perfect squares and the square roots they simplify

RootSimplifiedRootSimplifiedRootSimplified
√82√2√273√3√505√2
√122√3√324√2√726√2
√183√2√453√5√755√3
√202√5√484√3√987√2

How to use this table: look for the largest of 4, 9, 16, 25, 36, 49, 64, 81, 100 that divides the number.

12.5 Powers of 2 and 10

n2n10nPrefix
381,000kilo (k)
6641,000,000mega (M)
101,02410,000,000,000(2^10 is a binary kilo)
−31/80.001milli (m)
−61/640.000001micro (µ)

How to use this table: log(10^n) = n and log2(2^n) = n exactly, which the calculator uses for exact log answers.

12.6 Operator symbols this calculator accepts

TypeMeaningExample
+ −Add, subtract (also − for negative)5 − −2 = 7
* × or nothingMultiply2(3 + 4) = 14
/ ÷Divide27/6 = 9/2
^ or **Power2^10 = 1024
! and %Factorial, percent5! = 120, 12.5% × 80 = 10
| |, abs( )Absolute value|−5| = 5
sqrt, cbrt, root(x, n)Rootsroot(32, 5) = 2
ln, log, log2, log(x, b)Logarithmslog(8, 2) = 3
ncr, npr, gcd, lcm, modCounting and number theoryncr(10, 3) = 120

How to use this table: functions need brackets, and functions with two inputs use a comma.

📈 13. Example Results

Eight worked problems, each different from the headline example, covering the cases students meet most and the traps that cost marks.

1
Textbook

Order of operations with four operators

The classic first exercise.

Problem: 8 + 2 × 5 − 12 ÷ 4

Answer: 15
StepWorking
1Multiply: 2 × 5 = 10
2Divide: 12 ÷ 4 = 3
3Then left to right: 8 + 10 − 3 = 15
Steps for 8 + 2 times 5 minus 12 divided by 4Multiply gives 10, divide gives 3, and the final add and subtract give 15.102×5312÷4158+10−3
Figure 2. Order of operations with four operators.

What it means: Multiplication and division are done before addition and subtraction, wherever they sit in the line.

How to write it: 8 + 2 × 5 − 12 ÷ 4 = 8 + 10 − 3 = 15

2
Exam style with fractions

A fraction sum divided by a fraction

Typical GCSE and CBSE Grade 8 question.

Problem: (2/3 + 1/4) ÷ (5/6)

Answer: 11/10 = 1 1/10 = 1.1
StepWorking
1Bracket: 2/3 + 1/4 = 8/12 + 3/12 = 11/12
2Divide by a fraction: multiply by its reciprocal, 11/12 × 6/5
3= 66/60 = 11/10
Fractions on a number line11/12 and 5/6 sit just below 1; the answer 11/10 is just above 1.01211/125/611/10
Figure 3. A fraction sum divided by a fraction.

What it means: The answer is a little more than 1 because 11/12 is a little more than 5/6.

How to write it: (2/3 + 1/4) ÷ 5/6 = 11/12 × 6/5 = 11/10

3
Decimals

Why 0.1 × 3 − 0.3 is exactly 0

The floating-point trap.

Problem: 0.1 × 3 − 0.3

Answer: 0 (exactly). A float calculator gives 5.55 × 10−17
StepWorking
10.1 = 1/10, so 1/10 × 3 = 3/10
23/10 − 3/10 = 0
The answer zero on a number lineThe exact answer is zero; binary floating point gives a tiny non-zero value.-1010 exact
Figure 4. Why 0.1 × 3 − 0.3 is exactly 0.

What it means: Exact fractions remove the tiny binary error, so comparisons like “is it 0?” work.

How to write it: 0.1 × 3 − 0.3 = 3/10 − 3/10 = 0

4
Real world

Price after a 15% discount and 18% GST

Shopping in India, or any sales tax.

Problem: 2400 × 0.85 × 1.18

Answer: 12036/5 = 2407.20
StepWorking
115% off: 2400 × 0.85 = 2040
2Add 18% tax: 2040 × 1.18 = 2407.2
Price after discount and taxThe price falls to 2040 after the discount and rises to 2407.20 after tax.2400Price2040After 15%2407.2After GST
Figure 5. Price after a 15% discount and 18% GST.

What it means: A 15% discount followed by 18% tax is not the same as 3% tax: the final price is 2407.20, slightly above the start.

How to write it: Final price = 2400 × 0.85 × 1.18 = 2407.20

5
Special case: surds

Adding and subtracting square roots

Needs simplifying before you can combine.

Problem: √50 − √18 + √8

Answer: 4√2 ≈ 5.656854
StepWorking
1√50 = 5√2, √18 = 3√2, √8 = 2√2
2Like surds: 5√2 − 3√2 + 2√2
3= 4√2
Simplifying root 50, root 18 and root 8Each root is rewritten as a whole number times root 2: 5 root 2, 3 root 2 and 2 root 2, which combine to 4 root 2.√50 = 5√2√18 = 3√2√8 = 2√25 − 3 + 2 = 4so 4√2
Figure 6. Adding and subtracting square roots.

What it means: Roots only combine after each is written with the same number under the root.

How to write it: √50 − √18 + √8 = 4√2

6
Undefined

tan 90° and dividing by zero

When there is no answer.

Problem: tan(90) in DEG, and 5 ÷ (3 − 3)

Answer: No answer: both are undefined
StepWorking
1tan 90° = sin 90° ÷ cos 90° = 1 ÷ 0
23 − 3 = 0, so 5 ÷ 0
Graph of tan x with an asymptote at 90 degreestan x rises to infinity just before 90 degrees and comes up from minus infinity just after, so tan 90 degrees has no value.x = 90°, undefined0°180°
Figure 7. tan 90° and dividing by zero.

What it means: The calculator stops and explains, instead of printing Infinity or NaN.

How to write it: tan 90° is undefined; 5 ÷ 0 is undefined

7
Large numbers

2 to the power 64, every digit

Programmers and the chessboard puzzle.

Problem: 2^64

Answer: 18446744073709551616 ≈ 1.8447 × 1019
StepWorking
1Exponent with whole numbers: exact integer arithmetic
22^64 = 18446744073709551616 (20 digits)
Digits in powers of 2Number of digits in 2 to the 10, 20, 32, 53 and 64. Beyond 2 to the 53 ordinary decimals lose whole-number precision.4 digits2^107 digits2^2010 digits2^3216 digits2^5320 digits2^64
Figure 8. 2 to the power 64, every digit.

What it means: Above 2^53 ordinary decimals cannot store every whole number, so Excel would show 1.84467E+19.

How to write it: 2^64 = 18,446,744,073,709,551,616

8
Trap

5/6 ÷ 2/3 typed on one line

The most common fraction typing error.

Problem: 5/6/2/3 vs (5/6)/(2/3)

Answer: 5/4 = 1.25 (not 5/36)
StepWorking
1Flat: ((5/6) ÷ 2) ÷ 3 = 5/36
2With brackets: 5/6 × 3/2 = 5/4
Two readings of 5/6 divided by 2/3Without brackets the calculator divides left to right and gets 5/36; with brackets round each fraction it gets 5/4.Typed flat: 5/6/2/3(5/6) ÷ 2 = 5/12(5/12) ÷ 3 = 5/36= 0.1389With brackets(5/6) ÷ (2/3)= 5/6 × 3/2= 5/4 = 1.25
Figure 9. 5/6 ÷ 2/3 typed on one line.

What it means: A slash is a divide sign, so a calculator reads a long line of slashes left to right.

How to write it: (5/6) ÷ (2/3) = 5/4

✏️ 14. How to Do the Order of Operations by Hand, Step by Step

This is the pen and paper method a teacher expects to see, worked on the same example as Sections 7, 9, 10 and 11: 2 + 3 × (4 − 1)² ÷ 6.

14.1 The written method

  1. Copy the expression exactly. 2 + 3 × (4 − 1)² ÷ 6. Underline anything inside brackets.
  2. Work out the brackets. 4 − 1 = 3. Rewrite: 2 + 3 × 3² ÷ 6.
  3. Work out the powers. 3² = 9. Rewrite: 2 + 3 × 9 ÷ 6.
  4. Multiply and divide from left to right. 3 × 9 = 27 first, then 27 ÷ 6. Rewrite: 2 + 27/6.
  5. Simplify the fraction. gcd(27, 6) = 3, so 27/6 = 9/2.
  6. Add and subtract from left to right. 2 = 4/2, so 4/2 + 9/2 = 13/2.
  7. Convert if asked. 13/2 = 6 1/2 = 6.5.
  8. Check. Work backwards: 6.5 − 2 = 4.5, and 4.5 × 6 = 27 = 3 × 9. It checks.

14.2 On a scientific calculator

CalculatorKeysWhat you see
Casio fx-991EX / fx-570EX (ClassWiz)2 + 3 × ( 4 − 1 ) x² ÷ 6 =, then S⇔D13/2 in natural display, then 6.5
Casio fx-570MS / fx-991MS2 + 3 × ( 4 − 1 ) x² ÷ 6 =, then a b/c6.5, then 6⌢1⌢2 (6 and 1/2)
TI-84 Plus CE2 + 3 × ( 4 − 1 ) x² ÷ 6 ENTER, then MATH 1 (▶Frac) ENTER6.5, then 13/2

All three follow the order of operations, so you can type the whole line at once. The mistake to avoid is the minus key: use the subtraction key between numbers and the (−) negative key for a negative number, especially on the TI-84. Key labels and menus can differ between versions, so check your model’s manual if a key is missing.

14.3 Practice problems with answers

1. 8 + 2 × 5

18. Multiply first: 2 × 5 = 10, then 8 + 10.

2. (8 + 2) × 5

50. The bracket comes first.

3. 20 ÷ 4 × 5

25. Left to right: 20 ÷ 4 = 5, then 5 × 5.

4. 3/4 + 2/3

17/12 = 1 5/12. Common denominator 12: 9/12 + 8/12.

5. −2² + (−2)²

0. −2² = −4 and (−2)² = 4.

6. √75 − √12

3√3. 5√3 − 2√3.

7. 2^3^2

512. Powers stack from the top: 3² = 9 first, then 2^9.

8. 6 ÷ 2(1 + 2)

9 when read as 6 ÷ 2 × 3 left to right. Some books give 1. Write (6 ÷ 2)(1 + 2) or 6 ÷ (2(1 + 2)) to remove the doubt.

9. sin 30° + cos 60°

1. Each is exactly 1/2.

10. 5 ÷ (3 − 3)

No answer. Division by 0 is undefined.

14.4 Mistakes that lose marks

  • Working strictly left to right and adding before multiplying: 2 + 3 × 4 is 14, not 20.
  • Thinking M comes before D because of the letter order in PEMDAS. They are equal; go left to right.
  • Squaring a negative without brackets: −3² = −9.
  • Typing 5/6 ÷ 2/3 on one line. It means ((5/6) ÷ 2) ÷ 3 = 5/36, not 5/4.
  • Rounding in the middle: 1/3 written as 0.33 and multiplied by 3 gives 0.99, not 1.
  • Forgetting the calculator is in RAD when the question uses degrees.

🎯 15. When to Use This Calculator

Use it when
  • You need an exact fraction, surd or π answer
  • You want to see each step to learn or check working
  • The numbers are very large (factorials, big powers)
  • You need to solve or graph an equation quickly
  • You are building an answer key (Batch mode)
Use something else when
  • Your exam allows only a handheld calculator: practise on it too
  • You need calculus (derivatives, integrals) with steps
  • You need statistics on a data set: use a statistics tool
  • You need matrices or systems of several unknowns
  • You need equations in two variables, such as x and y

15.1 Four real examples

  • Homework check: a Grade 7 student gets 22.5 for 2 + 3 × (4 − 1)² ÷ 6. The steps show the power was skipped, and the right answer is 6.5.
  • Exact surds for an exam: √48 + √27 must be written as 7√3, not 12.124. The calculator gives both.
  • Interest: 1000 × 1.05³ = 9261/8 = 1157.625 exactly, so you know the amount to the cent before rounding.
  • Physics: −4.9t² + 20t + 1.5 = 0 (type it with x) gives the time a ball lands, t ≈ 4.1553 s.

15.2 Which tab to use

Your problemTabWhy
Numbers only, no xCalculatorExact value with order-of-operations steps
Has x and an “=”Solve EquationExact roots, discriminant, check by substitution
y = something with xGraphShape, roots, turning points, table of values
A worksheet of problemsBatchAll answers with working in one download
Quadratic with full vertex-form workingQuadratic formula calculatorA page built only for quadratics

🔧 16. Common Mistakes and Troubleshooting

My answer is 22.5 but the calculator says 6.5

Cause: working left to right without the order of operations. Fix: brackets first, then powers, then × ÷, then + −. Read the steps list to see each rung.

I typed −3^2 and got −9, but I wanted 9

Cause: the power is done before the minus sign. Fix: type (−3)^2. Excel is the odd one out and gives 9 for =−3^2.

sin(30) gives −0.988 instead of 0.5

Cause: the angle mode is RAD. Fix: switch to DEG, or type sin(pi/6) in RAD mode.

My fraction answer does not match the book

Cause: 5/6 ÷ 2/3 typed on one line is read as ((5/6) ÷ 2) ÷ 3. Fix: put brackets round each fraction: (5/6)/(2/3) = 5/4.

I got a decimal but the book has a surd

Cause: you used a decimal input such as 1.414 instead of sqrt(2). Fix: type roots with sqrt( ) so the exact form survives. The answer box shows the surd first.

The calculator says “Unknown name”

Cause: letters it does not know, or two names joined, such as “ab”. Fix: use the names in Table 12.6, and put * between letters you mean to multiply.

It says the expression contains x

Cause: x is the unknown, so there is no single value. Fix: use the Solve Equation tab with an “=”, or the Graph tab.

My handheld calculator says Math ERROR

Cause: division by 0, the root of a negative number, or a number too large (above 10^100 on most Casio models). Fix: check the inputs. This page shows the exact cause and works with numbers far beyond 10^100.

The equation solver says “No solution”

Cause: the x terms cancel and leave a false statement, such as 2x + 1 = 2x + 3. Fix: nothing to fix; the equation really has no solution. If both sides are identical, it says “True for every x”.

Excel shows #NUM! for a square root

Cause: SQRT of a negative number. Fix: use IMSQRT, or check the sign of what is inside the root.

⚖ 17. Assumptions and Limitations

17.1 Assumptions

  1. Real numbers. Answers are real unless the solver finds complex roots, which are shown as a ± bi. Check: the badge says “No real solution” when only complex roots exist.
  2. Typed decimals are exact. 0.333 means 333/1000, not 1/3. If you mean one third, type 1/3.
  3. Implicit multiplication has the same rank as ×. 1/2x means (1/2) × x. Some handheld calculators give implied multiplication a higher rank, so type 1/(2x) when that is what you mean.
  4. Angles follow the mode you pick. Only trig functions use it.
  5. x is the only variable. The equation solver and the graph use x.

17.2 Limitations

  1. Exact forms cover fractions, single surds and multiples of π. Mixtures such as π + √2, and anything with e, are given as 15-digit decimals with an amber badge.
  2. Factorials up to 5000! and powers up to a few hundred thousand digits stay exact; beyond that the page stops with a message.
  3. Polynomials up to degree 30. Rational roots are exact; the rest are found numerically to about 12 significant figures.
  4. Non-polynomial equations are solved numerically between x = −100 and 100. Roots outside that range, or roots where the curve touches 0 without crossing, can be missed. Use the Graph tab to look.
  5. No calculus, matrices or two-variable systems. Use a dedicated tool for those.

🏁 18. Conclusion

This calculator is built for the moment a number alone is not enough. It works in the correct order of operations, keeps every answer exact for as long as possible, shows each step, and checks itself with a second, independent calculation.

What the answer is. ___ Solve a problem above.

What it tells you. ___

Watch out for. ___

Next steps. ___

On the headline problem, 2 + 3 × (4 − 1)² ÷ 6, the order of operations gives 13/2 = 6.5, and a strict left-to-right calculator gives 22.5. That gap is the reason the steps matter. The same discipline explains −3² = −9, why 5/6 ÷ 2/3 needs brackets, and why sin(30) depends on the angle mode.

For exams, practise the same problems on your own handheld calculator with the keystrokes in Section 14, and use the exact form whenever a question asks for it. When you are ready for more, the Solve Equation and Graph tabs take the same skills into algebra. Bookmark this free online calculator and come back whenever you need the working, not just the answer.

❓ 19. Frequently Asked Questions

Q1. Is this calculator free to use?

Yes, this calculator is completely free, with no sign-up, no app and no limit on the number of problems. Every step, the exact answer, the graphs and the downloads are free.

Q2. What is the correct order of operations?

The correct order is brackets, then exponents (powers and roots), then multiplication and division from left to right, then addition and subtraction from left to right. PEMDAS, BODMAS and BIDMAS are names for the same rule.

Q3. Does multiplication come before division?

No, multiplication and division have equal rank, so you work them from left to right. 20 ÷ 4 × 5 = 5 × 5 = 25, not 20 ÷ 20 = 1.

Q4. Why is −3 squared equal to −9?

−3² is −9 because the power is done before the minus sign, so it means −(3 × 3). To square negative three, write (−3)², which is 9. Excel is an exception and returns 9 for =−3^2.

Q5. How do I type fractions in this calculator?

Type a fraction with a slash, such as 3/4, and put brackets round it when you divide by it, such as (5/6)/(2/3). The answer comes back as a reduced fraction, a mixed number and a decimal.

Q6. Why does 0.1 + 0.2 give 0.30000000000000004 on some calculators?

Computers store numbers in binary, and 0.1 has no exact binary form, so a tiny error appears. This calculator converts 0.1 and 0.2 into the fractions 1/10 and 1/5 first, so it gives exactly 3/10.

Q7. How do I simplify a square root?

Take out the largest perfect square factor: √48 = √(16 × 3) = 4√3. Type sqrt(48) and the calculator does this for you, then adds like surds, so √48 + √27 = 7√3.

Q8. Should my calculator be in degrees or radians?

Use degrees (DEG) when angles are given with the ° sign, as in most school geometry, and radians (RAD) when angles involve π or in calculus. sin(30) is 0.5 in DEG but −0.988 in RAD.

Q9. Can this calculator solve equations?

Yes. The Solve Equation tab solves linear, quadratic and polynomial equations exactly, including surd and complex roots, and solves other equations such as 2^x = 10 numerically. Each root is checked by substitution.

Q10. Is this a graphing calculator online?

Yes. The Graph tab plots any y = f(x) you type, marks the roots, the y-intercept and the turning points, and gives a table of values and a slope graph.

Q11. What is 6 ÷ 2(1 + 2)?

Following the standard rule, 6 ÷ 2(1 + 2) = 6 ÷ 2 × 3 = 9, working left to right. Some textbooks and calculators give implied multiplication a higher rank and get 1, which is why good writing uses extra brackets.

Q12. What is 0 to the power 0?

Most calculators, and this one, give 0⁰ = 1, the convention used in algebra, the binomial theorem and computing. In calculus, 0⁰ is called an indeterminate form when it comes from a limit.

Q13. Why is dividing by zero undefined?

Division by zero is undefined because no number times 0 gives a non-zero result, so a ÷ 0 has no answer. The calculator stops and says so instead of printing Infinity.

Q14. How big a number can this calculator handle?

Whole numbers have no fixed size limit here, so 70! shows all 101 digits. Factorials are allowed up to 5000!, which has 16,326 digits. Handheld calculators stop at about 10^100.

Q15. How do I do order of operations in Excel?

Type the expression after an equals sign, such as =2+3*(4-1)^2/6, which gives 6.5. Excel follows the usual order with one exception: =−3^2 gives 9, so write =−(3^2) for −9.

Q16. How do I use R as a calculator?

Type the expression at the R prompt, such as 2 + 3*(4 - 1)^2 / 6, and press Enter to get 6.5. MASS::fractions() shows it as 13/2, and sinpi(30/180) gives sin 30° exactly.

Q17. How do I get exact fractions in Python?

Use from fractions import Fraction, then Fraction(27, 6) returns 9/2. For surds and π use SymPy: sympy.sqrt(48) returns 4*sqrt(3). Remember that ** is the power operator in Python, not ^.

Q18. How do I turn a decimal into a fraction on a Casio fx-991EX?

Press the S⇔D key after the answer to switch between the fraction form and the decimal form. On the older fx-991MS, press the a b/c key to get a mixed number.

Q19. What is the difference between a simple calculator and a scientific calculator?

A simple or basic calculator does + − × ÷ and percent, often left to right. A scientific calculator follows the order of operations and adds powers, roots, trig, logs and memory. This page does both and shows the steps.

Q20. Can I use this calculator on my phone?

Yes. The page works in any phone browser, with large keypad buttons, and the inputs do not zoom the screen. Add it to your home screen to use it like an app.

📑 20. Cite This Tool

APA 7th edition
Pushbanathan, R. (2026). Calculator: Free online math solver with steps [Interactive calculator]. StatsUnlock. https://statsunlock.com/calculator/
BibTeX
@misc{statsunlock_calculator_2026, author={Pushbanathan, Reegan}, title={Calculator: Free Online Math Solver with Steps}, year={2026}, publisher={StatsUnlock}, url={https://statsunlock.com/calculator/}, note={Interactive calculator}}
Working sentence (fills in after you solve)
Calculations were done with the StatsUnlock Calculator (Pushbanathan, 2026), using exact rational arithmetic: ___.

🔗 21. Related Tools

📖 22. Glossary of Terms

TermPlain-English meaning
Absolute valueThe size of a number without its sign: |−5| = 5.
Angle modeWhether trig functions read angles in degrees, radians or gradians.
AnsThe last answer, ready to use in the next calculation.
BODMAS / PEMDASMemory aids for the order of operations.
Complex numberA number a + bi, where i² = −1. Needed when a square root is negative.
DenominatorThe bottom number of a fraction.
Discriminantb² − 4ac in a quadratic. Its sign tells you how many real roots there are.
Exact answerAn answer with no rounding, written as a fraction, surd or multiple of π.
ExponentThe small raised number in a power: in 3², the exponent is 2.
Factorialn! = 1 × 2 × … × n. 5! = 120 and 0! = 1.
Floating pointHow computers store decimals in binary, with about 15 to 17 significant digits.
GCDGreatest common divisor, the largest number dividing two numbers. Used to reduce fractions.
Implicit multiplicationMultiplying without a sign, as in 2x or 3(4 + 1).
Mixed numberA whole number and a proper fraction: 6 1/2.
nCrThe number of ways to choose r items from n, order not mattering.
NumeratorThe top number of a fraction.
Order of operationsThe agreed order for working out an expression: brackets, powers, × ÷, + −.
RadianAn angle unit: a full turn is 2π radians, and 180° = π.
RationaliseRemove a root from the bottom of a fraction by multiplying by the conjugate.
Root (of an equation)A value of x that makes the equation true.
Scientific notationWriting a number as a × 10^n with 1 ≤ |a| < 10.
SurdA root that cannot be simplified to a whole number, such as √3.

📚 23. References

Peer-reviewed sources for the methods in this calculator: exact and floating-point arithmetic, elementary function evaluation, polynomial root finding, and research on how students learn the order of operations.

  1. Aberth, O. (1973). Iteration methods for finding all zeros of a polynomial simultaneously. Mathematics of Computation, 27(122), 339–344. https://doi.org/10.1090/S0025-5718-1973-0329236-7
  2. Blinn, J. F. (2006). How to solve a cubic equation, part 1: The shape of the discriminant. IEEE Computer Graphics and Applications, 26(3), 84–93. https://doi.org/10.1109/MCG.2006.60
  3. Bokhove, C., & Drijvers, P. (2010). Digital tools for algebra education: Criteria and evaluation. International Journal of Computers for Mathematical Learning, 15(1), 45–62. https://doi.org/10.1007/s10758-010-9162-x
  4. Brent, R. P. (1976). Fast multiple-precision evaluation of elementary functions. Journal of the ACM, 23(2), 242–251. https://doi.org/10.1145/321941.321944
  5. Clinger, W. D. (1990). How to read floating point numbers accurately. ACM SIGPLAN Notices, 25(6), 92–101. https://doi.org/10.1145/93548.93557
  6. Ellington, A. J. (2006). The effects of non-CAS graphing calculators on student achievement and attitude levels in mathematics: A meta-analysis. School Science and Mathematics, 106(1), 16–26. https://doi.org/10.1111/j.1949-8594.2006.tb18067.x
  7. Goldberg, D. (1991). What every computer scientist should know about floating-point arithmetic. ACM Computing Surveys, 23(1), 5–48. https://doi.org/10.1145/103162.103163
  8. Gunnarsson, R., Sönnerhed, W. W., & Hernell, B. (2016). Does it help to use mathematically superfluous brackets when teaching the rules for the order of operations? Educational Studies in Mathematics, 92(1), 91–105. https://doi.org/10.1007/s10649-015-9667-2
  9. Higham, N. J. (1993). The accuracy of floating point summation. SIAM Journal on Scientific Computing, 14(4), 783–799. https://doi.org/10.1137/0914050
  10. Jenkins, M. A., & Traub, J. F. (1970). A three-stage variable-shift iteration for polynomial zeros and its relation to generalized Rayleigh iteration. Numerische Mathematik, 14(3), 252–263. https://doi.org/10.1007/BF02163334
  11. Kahan, W. (1965). Pracniques: Further remarks on reducing truncation errors. Communications of the ACM, 8(1), 40. https://doi.org/10.1145/363707.363723
  12. Kerner, I. O. (1966). Ein Gesamtschrittverfahren zur Berechnung der Nullstellen von Polynomen. Numerische Mathematik, 8(3), 290–294. https://doi.org/10.1007/BF02162564
  13. Kieran, C. (1981). Concepts associated with the equality symbol. Educational Studies in Mathematics, 12(3), 317–326. https://doi.org/10.1007/BF00311062
  14. Lanczos, C. (1964). A precision approximation of the gamma function. Journal of the Society for Industrial and Applied Mathematics, Series B: Numerical Analysis, 1, 86–96. https://doi.org/10.1137/0701008
  15. Lehmer, D. H. (1938). Euclid’s algorithm for large numbers. The American Mathematical Monthly, 45(4), 227–233. https://doi.org/10.1080/00029890.1938.11990797
  16. Steele, G. L., & White, J. L. (1990). How to print floating-point numbers accurately. ACM SIGPLAN Notices, 25(6), 112–126. https://doi.org/10.1145/93548.93559
  17. Vaiyavutjamai, P., & Clements, M. A. (2006). Effects of classroom instruction on students’ understanding of quadratic equations. Mathematics Education Research Journal, 18(1), 47–77. https://doi.org/10.1007/BF03217429
  18. Volder, J. E. (1959). The CORDIC trigonometric computing technique. IRE Transactions on Electronic Computers, EC-8(3), 330–334. https://doi.org/10.1109/TEC.1959.5222693
  19. Zazkis, R., & Rouleau, A. (2018). Order of operations: On convention and met-before acronyms. Educational Studies in Mathematics, 97(2), 143–162. https://doi.org/10.1007/s10649-017-9789-9
  20. Ziv, A. (1991). Fast evaluation of elementary mathematical functions with correctly rounded last bit. ACM Transactions on Mathematical Software, 17(3), 410–423. https://doi.org/10.1145/114697.116813
STATS UNLOCK · statsunlock.com · Calculator: Free Online Math Solver with Steps
RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular

Statistical Models

Important Plots & Charts

Calculators and Converters