TITLE: Can someone show me why this factorization is true?
QUESTION [11 upvotes]: $$x^n - y^n = (x - y)(x^{n-1} + x^{n-2}y + \dots + xy^{n-2} + y^{n-1})$$
Can someone perhaps even use long division to show me how this factorization works? I honestly don't see anyway to "memorize this". I like to see some basic intuition behind this

REPLY [5 votes]: One reason the result looks difficult is because it seems to involve two variables.
But if you divide both sides by $y^n$, it can be rewritten as
$$ \eqalign{\frac{x^n}{y^n} - 1 &= \left(\frac{x - y}{y}\right) \left( \frac{x^{n-1} + x^{n-2} y + \ldots + x y^{n-2} + y^{n-1}}{y^{n-1}}\right)\cr
 &= \left(\frac{x}{y} - 1 \right) \left(\frac{x^{n-1}}{y^{n-1}} + \frac{x^{n-2}}{y^{n-2}} + \ldots + \frac{x}{y} + 1 \right)} $$
With $x/y = r$, this says
$$ r^n - 1 = (r - 1)(r^{n-1} + r^{n-2} + \ldots + r + 1)$$
Now $$ r (r^{n-1} + r^{n-2} + \ldots + r + 1) = r^{n} + r^{n-1} + \ldots + r^2 + r$$
Subtract $1(r^{n-1} + \ldots + r + 1) = r^{n-1} + \ldots + r + 1$ and you see that the terms in $r, r^2, \ldots, r^{n-1}$ all cancel, leaving
$$ (r - 1)(r^{n-1} + r^{n-2} + \ldots + r + 1) = r^n - 1$$