Visual Tools
Calculators
Tables
Mathematical Keyboard
Converters
Other Tools

Factoring Calculator

How to use Factoring Calculator
  1. Pick a tab at the top of the card: Factor for one number, Laws for a factoring pattern, GCD & LCM for two numbers. Learn more about the three tabs
  2. In Factor, type a whole number in the Number box or click a chip; the factorization appears at once, no Calculate button. Learn more about prime factoring
  3. Pick a View: Prime for the prime factorization, Complete for every divisor and the factor pairs, Tree for the factor tree. Learn more about the complete view
  4. Read the Result card: the factorization, the exponent form, the divisor count, the sum of divisors and the type; the copy icon copies a line. Learn more about the results
  5. Click Add to history to keep a factorization in the Recent strip, Reset to return to 60 in the Prime view. Learn more about history and Reset
  6. In Laws, pick a pattern, type a and b, and read the step-by-step expansion. Learn more about the Laws tab
  7. In GCD & LCM, type Number A and Number B to see both prime factorizations, the GCD, the LCM and the coprime flag. Learn more about the GCD and LCM tab
  8. Read the How this works panel on the right and, in Factor, the Nearby numbers table under it. Learn more about the panel

Factor a number
View
60=22⋅3⋅560 = 2^{2} \cdot 3 \cdot 5
Result
Factorization of 60
60=22⋅3⋅560 = 2^{2} \cdot 3 \cdot 5
Prime factorization
22⋅3⋅52^{2} \cdot 3 \cdot 5
Exponent form
2^2 * 3 * 5
Divisor count τ(n)
12
Sum of divisors σ(n)
168
Type
Abundant (σ-n > n)
Neighbors (click to set)
57
4 div
58
4 div
59
prime
60
12 div
61
prime
62
4 div
63
6 div
Apply a factoring pattern
72−327^2 - 3^2
Step-by-step
1
Start: 72−32\text{Start: } 7^2 - 3^2
2
=(7−3)(7+3)= (7 - 3)(7 + 3)
3
=4⋅10=40= 4 \cdot 10 = 40
GCD & LCM
Number A
60=22⋅3⋅560 = 2^{2} \cdot 3 \cdot 5
&
Number B
84=22⋅3⋅784 = 2^{2} \cdot 3 \cdot 7
GCD
gcd⁡=22⋅3=12\gcd = 2^{2} \cdot 3 = 12
LCM
lcm=22⋅3⋅5⋅7=420\mathrm{lcm} = 2^{2} \cdot 3 \cdot 5 \cdot 7 = 420
a \u00B7 b = gcd \u00B7 lcm
60⋅84=12⋅420=504060 \cdot 84 = 12 \cdot 420 = 5040
How this works

Prime view

Writes the number as a product of primes with exponents, found by trial division up to n\sqrt{n}, and lists the divisor count, the sum of divisors and the type. Learn more about prime factorization · All factoring views

What just happened

Every integer greater than 1 has a unique prime factorization (Fundamental Theorem of Arithmetic). For 60:
60=22⋅3⋅560 = 2^{2} \cdot 3 \cdot 5

Divisor count

If n=p1a1⋅p2a2⋯n = p_1^{a_1} \cdot p_2^{a_2} \cdots, the number of divisors is the product (a1+1)(a2+1)⋯(a_1+1)(a_2+1)\cdots. Each exponent contributes one more choice.
τ(60)=3⋅2⋅2=12\tau(60) = 3 \cdot 2 \cdot 2 = 12

Worth knowing

Abundant
Proper divisors sum to more than 60 (108). The smallest abundant number is 12.
Nearby numbers
nPrime factorizationdiv #
555⋅115 \cdot 114
5623⋅72^{3} \cdot 78
573⋅193 \cdot 194
582⋅292 \cdot 294
595959prime2
6022⋅3⋅52^{2} \cdot 3 \cdot 512
616161prime2
622⋅312 \cdot 314
6332⋅73^{2} \cdot 76
64262^{6}7
655⋅135 \cdot 134
662⋅3⋅112 \cdot 3 \cdot 118































Getting Started with the Factoring Calculator

DemoThe three tabs
Step 0 of 3
The calculator is one card with three tabs across the top. Factor works on a single whole number: it shows the prime factorization, every divisor or a factor tree, depending on the view you pick. Laws applies one of five factoring patterns, such as the difference of squares, to two numbers aa and bb and shows the steps. GCD & LCM takes two numbers and shows their prime factorizations, their greatest common divisor and their least common multiple. The Factor tab is open when the page loads, with 6060 already typed.

Every tab is live: there is no Calculate button, the result updates as you type or click. The left column holds the controls and the result; the right column holds the How this works panel, which explains the current view or pattern, and, in the Factor tab, a Nearby numbers table. Switching tabs keeps what you typed in the other tabs, so you can move between them freely. Start with the chips under the view buttons, for example 360360 or 10241024, to see a factorization without typing. What the three tabs have in common is explained in What Are Factors.

Using Prime Factoring Mode

Demo360, the 1024 chip, Add to history
Step 0 of 3
Click Prime in the View row of the Factor tab (it is selected when the page loads) and type a whole number in the Number box, or click one of the chips: 1212, 2424, 6060, 100100, 120120, 360360, 720720, 10241024 and 1,000,0001{,}000{,}000. The line under the box shows the factorization at once, 60=22⋅3⋅560 = 2^{2} \cdot 3 \cdot 5, and the Result card repeats it as Prime factorization and Exponent form, followed by the Divisor count τ(n)\tau(n), the Sum of divisors σ(n)\sigma(n) and the Type: perfect, abundant or deficient. For 360=23⋅32⋅5360 = 2^{3} \cdot 3^{2} \cdot 5 the card reads τ=24\tau = 24, σ=1,170\sigma = 1{,}170, abundant; for 1024=2101024 = 2^{10} it reads τ=11\tau = 11, σ=2,047\sigma = 2{,}047, deficient, plus the line Perfect square 1024=32\sqrt{1024} = 32.

A prime such as 1717 gives the line "17 is prime", the status Prime, the divisors 11 and 1717 and the sum 1818. Click Add to history to keep the current factorization in the Recent strip under the card, which holds the last eight; clicking a chip adds its number there as well. Reset returns to 6060 in the Prime view. The rule behind the factorization is explained in Prime Factorization.

Using Complete Factoring Mode

DemoEvery divisor of 60, then of 36, then a click on 12
Step 0 of 3
Click Complete in the View row to list every divisor of the number. The chips change to 1616, 2424, 3636, 4848, 6060 and 100100, and under the Result card a block All divisors (prime ones highlighted, click to set) appears: for 6060 the twelve divisors 1,2,3,4,5,6,10,12,15,20,30,601, 2, 3, 4, 5, 6, 10, 12, 15, 20, 30, 60, with 22, 33 and 55 highlighted. Each divisor is a button: click 1212 and the calculator factors 1212 instead, so you can walk down a number through its divisors. Below the divisors the Factor pairs block lists every pair that multiplies to the number, 1×601 \times 60 up to 6×106 \times 10.

The Result card keeps showing the prime factorization, the divisor count and the sum of divisors in this view, so the count you read, τ(60)=12\tau(60) = 12, matches the number of buttons in the divisor block. For 36=22⋅3236 = 2^{2} \cdot 3^{2} there are nine divisors, 1,2,3,4,6,9,12,18,361, 2, 3, 4, 6, 9, 12, 18, 36; an odd count is the mark of a perfect square, and the card adds the line 36=6\sqrt{36} = 6. Negative numbers, 00 and 11 have no divisor block, since the list is only built for a positive composite number. How the count follows from the exponents is explained in Complete Factoring and Divisor Counting.

Understanding Factor Pairs

DemoFactor pairs of 24, 16 and 20
Step 0 of 3
In the Complete view, the Factor pairs block under the divisors shows two numbers that multiply to the number you typed. For 1212 it lists 1×121 \times 12, 2×62 \times 6 and 3×43 \times 4; for 2424 it lists 1×241 \times 24, 2×122 \times 12, 3×83 \times 8 and 4×64 \times 6; for 2020 it lists 1×201 \times 20, 2×102 \times 10 and 4×54 \times 5. Each pair is one way to arrange that many items in a rectangle: 3×43 \times 4 means three rows of four, or four rows of three.

The pairs are read off the divisor list: the smallest divisor goes with the largest, the second smallest with the second largest, and so on, which is why a number with twelve divisors has six pairs. A perfect square has a pair that repeats one number: 1616 gives 1×161 \times 16, 2×82 \times 8 and 4×44 \times 4. Factor pairs are the quickest way to answer area questions, such as which whole-number dimensions a rectangle of area 2424 can have, and to check a factorization by multiplying back. What a factor is, and why pairs always come in twos, is explained in What Are Factors.

Using the Factor Tree View

DemoThe tree of 60, the tree of 72, a prime
Step 0 of 3
Click Tree in the View row to draw the factor tree of the number. The chips change to 1212, 1818, 2424, 3636, 6060 and 7272. The tree starts with the number at the top and splits it into its smallest prime factor and the remaining cofactor, then splits the cofactor the same way until only primes are left: 6060 becomes 22 and 3030, 3030 becomes 22 and 1515, 1515 becomes 33 and 55, so the leaves read 2,2,3,52, 2, 3, 5 and the Result card confirms 60=22⋅3⋅560 = 2^{2} \cdot 3 \cdot 5. For 7272 the tree has four levels: 72→2⋅36→2⋅18→2⋅9→3⋅372 \to 2 \cdot 36 \to 2 \cdot 18 \to 2 \cdot 9 \to 3 \cdot 3.

A prime such as 1717 is a single node, since there is nothing to split, and 00, 11 and negative numbers draw no tree. The tree always uses the smallest prime first, so it is one of several valid trees for the same number; every tree ends with the same multiset of primes, which is why the factorization is unique. The Result card, the Neighbors strip and the How this works panel work in this view exactly as in the Prime view. Reading a tree and why every tree agrees is explained in Factor Trees.

Working with Negative Numbers

Demo−12, −60, back to 60
Step 0 of 3
Type a minus sign before the number, for example −12-12, and the Factor tab pulls the sign out as a factor of −1-1: the line reads −12=−1⋅22⋅3-12 = -1 \cdot 2^{2} \cdot 3, the Result card shows that Prime factorization, the Exponent form −1∗22∗3-1 * 2^2 * 3 and the note Divisors (of |n| = 12), and the How this works panel opens a Negative numbers block explaining the convention. The divisor count, the sum of divisors and the type are not shown for a negative number, and the Complete and Tree views have no divisor block or tree for it; switch back to a positive number to see them.

This is the usual convention: prime factorization is defined for positive integers, and a negative integer is written as −1-1 times the factorization of its absolute value. The divisors of a negative number are the divisors of ∣n∣|n| with both signs, so −12-12 has the same twelve divisors as 1212 once the signs are counted. Try −60-60 to get −1⋅22⋅3⋅5-1 \cdot 2^{2} \cdot 3 \cdot 5, then type 6060 again. The rule is explained in Prime Factorization.

Reading Results and Error Messages

DemoZero, one, a number too large, Reset
Step 0 of 4
The Result card changes with the status of the number. For a composite number it lists the prime factorization, the exponent form, τ(n)\tau(n), σ(n)\sigma(n) and the type, with a copy icon on each line that copies that value; the icon turns into a tick for a moment after the click. For a prime it lists the status Prime, the two divisors and their sum. Special cases are named rather than refused: 00 gives the status Zero with "every nonzero integer" as divisors, 11 gives 1 (neither prime nor composite) with one divisor, and an empty box gives Waiting for input. A number above one billion gives Too large for this demo and the line "Number too large for the demo (≤ 10⁹)"; letters are ignored, so the box waits for a number.

Under the card, Neighbors (click to set) shows the three numbers on either side of yours with a badge, "prime" or the divisor count, and clicking one factors it. Add to history keeps the current factorization in the Recent strip, which holds eight entries; Reset returns to 6060 in the Prime view without clearing the strip. Why 00 and 11 stand apart is explained in What Are Prime Numbers.

Using the Laws Tab

DemoDifference of squares, sum of cubes with new numbers, GCF extraction
Step 0 of 3
Click Laws at the top of the card to apply a factoring pattern to numbers. The five buttons on the left name the patterns with their formulas: Difference of squares a2−b2=(a−b)(a+b)a^2 - b^2 = (a-b)(a+b), Sum of cubes, Difference of cubes, Perfect square trinomial and GCF extraction ka+kb=k(a+b)ka + kb = k(a + b). Pick one, type whole numbers in the a and b boxes, and the expression line shows the pattern with your numbers, for example 72−327^2 - 3^2, while the Step-by-step list expands it: start, factored form, numbers, so 72−32=(7−3)(7+3)=4⋅10=407^2 - 3^2 = (7 - 3)(7 + 3) = 4 \cdot 10 = 40.

Each pattern keeps its own pair of numbers, opening with 7,37, 3 for the difference of squares, 2,32, 3 for the sum of cubes, 5,25, 2 for the difference of cubes, 3,43, 4 for the perfect square trinomial and 12,1812, 18 for GCF extraction. With a=5a = 5, b=2b = 2 the sum of cubes gives (5+2)(25−10+4)=7⋅19=133(5 + 2)(25 - 10 + 4) = 7 \cdot 19 = 133; GCF extraction with 1212 and 1818 finds gcd⁡=6\gcd = 6 and writes 12+18=6(2+3)=3012 + 18 = 6(2 + 3) = 30, and reports "nothing to extract" when the two numbers are coprime. An empty box shows "Enter integer values for a and b". The How this works panel explains the chosen pattern, why it works and its common mistake. The patterns themselves are explained in Factoring Patterns.

Using the GCD and LCM Tab

Demo60 and 84, a coprime pair, a refused value
Step 0 of 3
Click GCD & LCM at the top of the card and type two positive whole numbers in Number A and Number B, which open with 6060 and 8484. Under each box its prime factorization appears, 60=22⋅3⋅560 = 2^{2} \cdot 3 \cdot 5 and 84=22⋅3⋅784 = 2^{2} \cdot 3 \cdot 7, and two cards give the answers with their own factorizations: GCD =22⋅3=12= 2^{2} \cdot 3 = 12 and LCM =22⋅3⋅5⋅7=420= 2^{2} \cdot 3 \cdot 5 \cdot 7 = 420. A third line checks the identity a⋅b=gcd⁡⋅lcma \cdot b = \gcd \cdot \mathrm{lcm}: 60⋅84=12⋅420=5,04060 \cdot 84 = 12 \cdot 420 = 5{,}040.

When the two numbers share no prime factor a Coprime flag appears above the cards, as for 88 and 1515: gcd⁡=1\gcd = 1 and lcm=8⋅15=120\mathrm{lcm} = 8 \cdot 15 = 120. A box that holds 00, a negative number or letters shows "enter a positive integer" under it and the cards disappear until both boxes are valid. The How this works panel on the right stacks the two factorizations, states the rule, minimum exponent for the GCD and maximum exponent for the LCM, and repeats the identity with your numbers. The rule and the identity are explained in GCD and LCM from Prime Factorizations.

The How This Works Panel and the Nearby Numbers Table

DemoA perfect number, a perfect square, the Laws panel
Step 0 of 3
The right column of the card opens with the How this works panel, whose blocks change with the tab and the number. In the Factor tab a composite number gives What just happened, with the factorization, Divisor count, with the product of the exponents plus one, τ(36)=3⋅3=9\tau(36) = 3 \cdot 3 = 9, and Worth knowing, which flags a perfect square (36=6236 = 6^2), a perfect cube, a perfect number (σ(28)−28=28\sigma(28) - 28 = 28) or says whether the number is abundant or deficient. A prime, a negative number, 00, 11 and an out-of-range number each get their own block. In the Laws tab the panel names the pattern, explains Why it works with a worked example and warns of a Common mistake; in the GCD & LCM tab it reads the two factorizations, states The rule and The identity, and flags coprime pairs.

The first block of the panel is a short note on the current view or pattern with a link to the section of this page that explains it. In the Factor tab the panel is followed by Nearby numbers, a table of twelve numbers around yours with their prime factorizations, a "prime" tag and the divisor count, your number highlighted; it is a quick way to compare neighbours such as 35=5⋅735 = 5 \cdot 7 and 36=22⋅3236 = 2^{2} \cdot 3^{2}. What the divisor count and the sum of divisors measure is explained in Complete Factoring and Divisor Counting.

What Are Factors

Factors are whole numbers that divide evenly into another number with no remainder. If a×b=ca \times b = c, then aa and bb are both factors of cc. For example, since 3×4=123 \times 4 = 12, both 33 and 44 are factors of 1212.

Think of factors as building blocks. The number 1212 can be built by multiplying 1×121 \times 12, 2×62 \times 6, or 3×43 \times 4. Each of these numbers—1,2,3,4,6,121, 2, 3, 4, 6, 12—is a factor of 1212. Every number has at least two factors: 11 and itself.

Factors are different from multiples. Multiples are what you get when you multiply a number: multiples of 33 are 3,6,9,12,15...3, 6, 9, 12, 15.... Factors go the other direction: factors of 1212 are the numbers you multiply to get 1212.

For more detailed explanations of factor properties, prime numbers, and divisibility rules, see factors and multiples and divisibility.

Prime Factoring vs Complete Factoring

Prime factoring breaks a number into prime number building blocks. Prime factors are the smallest possible factors (except 11). The number 1212 has prime factors 2,2,32, 2, 3 because 2×2×3=122 \times 2 \times 3 = 12, and you cannot break it down further.

Complete factoring finds all numbers that divide evenly into your input, not just primes. For 1212, complete factors are 1,2,3,4,6,121, 2, 3, 4, 6, 12. This includes composite numbers (like 44 and 66) that can themselves be factored further.

Use prime factoring when simplifying radicals (12=4×3=23\sqrt{12} = \sqrt{4 \times 3} = 2\sqrt{3}), finding GCF or LCM, or working with fractions. Use complete factoring when finding divisors, calculating area dimensions, or solving divisibility problems.

Prime factoring is unique—every number has exactly one prime factorization (ignoring order). Complete factoring gives you all possibilities. Both are valuable, just for different purposes. See prime numbers and GCD and LCM for deeper understanding.

The Factor tab offers the three views as its three ways of factoring: Prime Factorization for the Prime view, Complete Factoring and Divisor Counting for the Complete view and Factor Trees for the Tree view. All three rest on the same fact, the unique prime factorization taught in Prime factorization.

Prime Factorization

The prime factorization of a positive integer writes it as a product of primes, grouped with exponents: 60=22⋅3⋅560 = 2^{2} \cdot 3 \cdot 5, 360=23⋅32⋅5360 = 2^{3} \cdot 3^{2} \cdot 5, 1024=2101024 = 2^{10}. The Fundamental Theorem of Arithmetic says every integer greater than 11 has exactly one such factorization apart from the order of the factors, which is why the Prime view, the Complete view and the Tree view always agree.

The calculator finds it by trial division: divide by 22 as often as possible, then by 33, 55 and so on up to n\sqrt{n}; whatever is left above 11 is the last prime. For 360360: three divisions by 22 leave 4545, two by 33 leave 55, and 55 is prime. A common mistake is to stop at a composite factor, writing 360=8⋅45360 = 8 \cdot 45 and calling it done; the factorization is finished only when every factor is prime. Negative numbers are written as −1-1 times the factorization of ∣n∣|n|, and 00 and 11 have none.

The method and the theorem are taught in Prime factorization in the divisibility lesson and in Prime factorization in the prime numbers lesson.

Complete Factoring and Divisor Counting

Complete factoring lists every divisor of a number, not only the primes. From the prime factorization the list follows without any further division: a divisor of 60=22⋅3⋅560 = 2^{2} \cdot 3 \cdot 5 uses 22 zero, one or two times, 33 zero or one time and 55 zero or one time, so there are 3⋅2⋅2=123 \cdot 2 \cdot 2 = 12 divisors. In general τ(n)=(a1+1)(a2+1)⋯\tau(n) = (a_1 + 1)(a_2 + 1) \cdots for n=p1a1p2a2⋯n = p_1^{a_1} p_2^{a_2} \cdots, the formula the How this works panel shows under Divisor count.

The sum of the divisors σ(n)\sigma(n) sorts numbers into three types: perfect when the proper divisors add up to the number itself (2828: 1+2+4+7+14=281 + 2 + 4 + 7 + 14 = 28), abundant when they add up to more (1212: 1+2+3+4+6=161 + 2 + 3 + 4 + 6 = 16) and deficient when to less (1616: 1+2+4+8=151 + 2 + 4 + 8 = 15). Perfect squares have an odd divisor count because the square root pairs with itself. The common mistake is to count 11 and the number itself out; both are divisors and both belong in τ(n)\tau(n) and σ(n)\sigma(n).

Divisors and their counting are taught in Factors and multiples and the quick tests for small divisors in Divisibility rules.

Factor Trees

A factor tree splits a number into two factors, then splits each composite factor again, until every branch ends in a prime. The leaves, read left to right, are the prime factorization. The calculator always splits off the smallest prime first: 72→2⋅3672 \to 2 \cdot 36, 36→2⋅1836 \to 2 \cdot 18, 18→2⋅918 \to 2 \cdot 9, 9→3⋅39 \to 3 \cdot 3, so the leaves are 2,2,2,3,32, 2, 2, 3, 3 and 72=23⋅3272 = 2^{3} \cdot 3^{2}.

Any valid split works: starting 72→8⋅972 \to 8 \cdot 9 gives a different tree with the same leaves. That every tree ends with the same primes is the content of the Fundamental Theorem of Arithmetic. The tree is a picture of the trial division behind the Prime view, which is why the two views never disagree. The common mistake is to leave a composite leaf such as 99 unsplit; a tree is finished only when every leaf is prime. A prime number is a tree of one node.

Factor trees are the usual way to introduce Prime factorization; the prime numbers lesson shows the same procedure in Prime factorization.

What Are Prime Numbers

Prime numbers are whole numbers greater than 11 that have exactly two factors: 11 and themselves. The number 77 is prime because only 11 and 77 divide evenly into it. You cannot create 77 by multiplying two smaller whole numbers (other than 1×71 \times 7).

The first few prime numbers are: 2,3,5,7,11,13,17,19,23,29...2, 3, 5, 7, 11, 13, 17, 19, 23, 29.... Notice that 22 is the only even prime—all other even numbers are divisible by 22, so they have at least three factors (11, 22, and themselves).

Numbers that aren't prime are called composite numbers. The number 1212 is composite because it has many factors: 1,2,3,4,6,121, 2, 3, 4, 6, 12. Composite numbers can be broken down into prime factors: 12=2×2×312 = 2 \times 2 \times 3.

The number 11 is special—it's neither prime nor composite. By definition, primes must have exactly two factors, but 11 has only one factor (itself). For comprehensive coverage of prime numbers, see prime numbers and the sieve of Eratosthenes.

Factoring Patterns

The Laws tab applies five patterns that turn a sum or difference into a product. All five are identities: true for every aa and bb, which is what makes them usable backwards, from the expanded form to the factored form. They are Difference of Squares, a2−b2=(a−b)(a+b)a^2 - b^2 = (a - b)(a + b); Sum of Cubes, a3+b3=(a+b)(a2−ab+b2)a^3 + b^3 = (a + b)(a^2 - ab + b^2); Difference of Cubes, a3−b3=(a−b)(a2+ab+b2)a^3 - b^3 = (a - b)(a^2 + ab + b^2); Perfect Square Trinomials, a2+2ab+b2=(a+b)2a^2 + 2ab + b^2 = (a + b)^2; and GCF Extraction, ka+kb=k(a+b)ka + kb = k(a + b).

The calculator checks each pattern on numbers: with a=7a = 7, b=3b = 3 the difference of squares gives 49−9=4⋅10=4049 - 9 = 4 \cdot 10 = 40 on both sides. Numbers are a test, not a proof; the proof is the expansion of the right-hand side shown under Why it works. The common strategy is to pull out the GCF first, then look for one of the other four shapes.

The patterns and the order to try them are taught in Factoring strategy and What is factoring; the identities are collected in Summary of algebraic identities.

Difference of Squares

Two squares subtracted factor as a sum times a difference: a2−b2=(a−b)(a+b)a^2 - b^2 = (a - b)(a + b). Expanding the right side, a2+ab−ab−b2a^2 + ab - ab - b^2, the cross terms cancel, which is why the pattern has no middle term and is recognised by that absence. With a=7a = 7, b=3b = 3: 49−9=(7−3)(7+3)=4⋅10=4049 - 9 = (7 - 3)(7 + 3) = 4 \cdot 10 = 40.

The common mistake is to factor a sum of squares the same way; over the real numbers a2+b2a^2 + b^2 does not factor. The pattern also explains quick mental products such as 19⋅21=202−1=39919 \cdot 21 = 20^2 - 1 = 399.

The pattern is taught in Difference of squares and, as an identity, in Sums and differences of powers.

Sum of Cubes

A sum of two cubes does factor, unlike a sum of squares: a3+b3=(a+b)(a2−ab+b2)a^3 + b^3 = (a + b)(a^2 - ab + b^2). Multiplying out, a3−a2b+ab2+a2b−ab2+b3a^3 - a^2 b + ab^2 + a^2 b - ab^2 + b^3, the four middle terms cancel in pairs. With a=2a = 2, b=3b = 3: 8+27=(2+3)(4−6+9)=5⋅7=358 + 27 = (2 + 3)(4 - 6 + 9) = 5 \cdot 7 = 35; with a=5a = 5, b=2b = 2: 125+8=7⋅19=133125 + 8 = 7 \cdot 19 = 133.

The common mistake is the sign of the middle term of the trinomial: the sum of cubes uses −ab-ab, the difference of cubes +ab+ab. The mnemonic SOAP, Same, Opposite, Always Positive, gives the three signs in order. The trinomial factor does not factor further over the real numbers.

See Sum and difference of cubes and the identity in Cubes of binomials.

Difference of Cubes

The mirror of the sum of cubes: a3−b3=(a−b)(a2+ab+b2)a^3 - b^3 = (a - b)(a^2 + ab + b^2). The same cancellation happens with the opposite signs. With a=5a = 5, b=2b = 2: 125−8=(5−2)(25+10+4)=3⋅39=117125 - 8 = (5 - 2)(25 + 10 + 4) = 3 \cdot 39 = 117.

The common mistake is again the middle sign: here the trinomial takes +ab+ab. SOAP applies: the binomial takes the Same sign as the original expression, the middle term the Opposite sign, the last term is Always Positive. Note that a3−b3a^3 - b^3 with a=ba = b is 00, and the pattern gives 00 too, since the first factor vanishes.

See Sum and difference of cubes and Sums and differences of powers.

Perfect Square Trinomials

A trinomial of the form a2+2ab+b2a^2 + 2ab + b^2 is the square of a binomial: (a+b)2(a + b)^2. Expanding (a+b)(a+b)(a + b)(a + b) by the distributive law gives a2+ab+ab+b2a^2 + ab + ab + b^2, and the two cross terms combine into 2ab2ab. With a=3a = 3, b=4b = 4: 9+24+16=(3+4)2=499 + 24 + 16 = (3 + 4)^2 = 49.

To recognise the pattern, check that the first and last terms are squares and that the middle term is exactly twice the product of their roots; x2+5x+4x^2 + 5x + 4 fails the test and is not a perfect square. The common mistake is to force the pattern when the middle coefficient is wrong. With a minus sign in the middle the pattern is a2−2ab+b2=(a−b)2a^2 - 2ab + b^2 = (a - b)^2.

See Perfect square trinomials and the identity in Squares of binomials.

GCF Extraction

Extracting the greatest common factor runs the distributive law backwards: ka+kb=k(a+b)ka + kb = k(a + b). For numbers the calculator finds k=gcd⁡(a,b)k = \gcd(a, b); with a=12a = 12, b=18b = 18, gcd⁡=6\gcd = 6 and 12+18=6⋅2+6⋅3=6(2+3)=6⋅5=3012 + 18 = 6 \cdot 2 + 6 \cdot 3 = 6(2 + 3) = 6 \cdot 5 = 30. When the two numbers are coprime there is nothing to extract, and the tool says so.

This is the first move in almost every factoring problem, because a common factor left inside makes every later pattern harder to see. The common mistake is to pull out only part of the common factor, say 22 instead of 66 above, which leaves 2(6+9)2(6 + 9) with a factor of 33 still shared inside. Use the full GCD.

See Greatest common factor in the factoring lesson and the distributive property it relies on.

GCD and LCM from Prime Factorizations

The greatest common divisor and the least common multiple of two numbers can both be read from their prime factorizations, prime by prime. The GCD takes the smaller exponent of each prime that appears in both; the LCM takes the larger exponent of each prime that appears in either. For 60=22⋅3⋅560 = 2^{2} \cdot 3 \cdot 5 and 84=22⋅3⋅784 = 2^{2} \cdot 3 \cdot 7: gcd⁡=22⋅3=12\gcd = 2^{2} \cdot 3 = 12 and lcm=22⋅3⋅5⋅7=420\mathrm{lcm} = 2^{2} \cdot 3 \cdot 5 \cdot 7 = 420.

The two are tied by the identity a⋅b=gcd⁡(a,b)⋅lcm(a,b)a \cdot b = \gcd(a, b) \cdot \mathrm{lcm}(a, b), here 60⋅84=5,040=12⋅42060 \cdot 84 = 5{,}040 = 12 \cdot 420, because each prime's two exponents are split into a minimum and a maximum whose sum is the same. Numbers with no shared prime are coprime: gcd⁡(8,15)=1\gcd(8, 15) = 1 and the LCM is the plain product 120120. The common mistake is to multiply the two numbers and call the product the LCM; that is right only for coprime pairs.

The rule and the identity are taught in GCD and LCM, building on Prime factorization.