MathorynMathematical Formula Database

Algebra

Difference of n-th Powers

This identity factors an−bna^n-b^n for any positive integer nn and always contains the factor a−ba-b. It generalises the difference of squares and of cubes, is used to factor polynomials, to prove divisibility results and to derive the geometric series sum.

an−bn=(a−b)(an−1+an−2b+⋯+abn−2+bn−1)a^n-b^n=(a-b)\left(a^{n-1}+a^{n-2}b+\cdots+ab^{n-2}+b^{n-1}\right)
LaTeXa^n-b^n=(a-b)\left(a^{n-1}+a^{n-2}b+\cdots+ab^{n-2}+b^{n-1}\right)

Variables

a, ba,\ b
any numbers or expressions
nn
positive integer exponent

Example

Factor 25−12^5-1 using the identity.

  1. Take a=2, b=1, n=5a=2,\ b=1,\ n=5.
  2. 25−1=(2−1)(24+23+22+2+1)2^5-1=(2-1)(2^4+2^3+2^2+2+1).
  3. =1⋅(16+8+4+2+1)=1\cdot(16+8+4+2+1).

Answer: 25−1=312^5-1=31.

Related formulas