<s>[INST] $(1−x^n) = (1−x)(1 + x + x^2 +\cdots + x^{n−1})$ Is this expression generally true?
$$(1−x^n) = (1−x)(1 + x + \cdots + x^{n−1})$$
The closest Identity I could find in "Mathematical Handbook of Formulas and Tables", Schaum's Outline is:
$$x^{2n+1} - y^{2n+1} = (x-y)(x^{2n} +x^{2n-1}y + x^{2n+2}y^2 + \cdots +y^{2n})$$
Which I could almost believe is the same thing if I set x=1.
$$1 - y^{2n+1} = (1-y)(1 +y + y^2 + \cdots + y^{2n})$$
let $N=2n+1$
$$1 - y^N = (1-y)(1 +y + y^2 + \cdots + y^{N-1})$$
But doesn't this restrict N to be an odd number?  I was just asking because i saw this identity being used in a case where N could be an even or odd number, which made me think its generally true.  I'm just not sure how to prove it.
 [/INST] Here are the formulæ I learnt in med-school:
$$x^n-y^n=(x-y)(x^{n-1}+x^{n-2}y+x^{n-3}y^2+\dots+xy^{n-2}+y^{n-1}),$$
in other words, it is $x-y$ times the sum of all homogeneous monomials in $x$ and $y$, with total degree $n-1$.
The sum of two powers requires an odd exponent:
$$x^{2n+1}+y^{2n+1}=(x+y)(x^{2n}-x^{2n-1}y+x^{2n-2}y^2-\dots+x^2y^{2n-2}-xy^{2n-1}+y^{2n}).$$
</s>