<s>[INST] Prove polynomial identity $x^k-1=(x-1)(x^{k-1}+x^{k-2}+\ldots+1).$ I am confused, as not clear except by multiplying both terms on the r.h.s, and showing that all cancel out except the two on the l.h.s., as below:
$(x)(x^{k-1}+x^{k-2}+\ldots+1) - (x^{k-1}+x^{k-2}+\ldots+1)= x^k -1$
 [/INST] This one cries out for a simple proof by induction:
If $k = 1$ we evidently have
$x^1 - 1 = (x^1 - 1)(1), \tag 1$
and if $k = 2$:
$x^2 - 1 = (x -1)(x + 1) = (x - 1)\left ( \displaystyle \sum_0^1 x^i \right ); \tag 2$
if we now suppose that the formula holds for some positive $m \in \Bbb Z$,
$x^m - 1 = (x - 1) \left ( \displaystyle \sum_0^{m - 1} x^i \right ), \tag 3$
then
$x^{m + 1} - 1 = x^{m + 1} - x^m + x^m - 1$
$= x^m(x - 1) + (x - 1) \left ( \displaystyle \sum_0^{m - 1} x^i \right ) = (x - 1) \left ( x^m +  \displaystyle \sum_0^{m - 1} x^i \right ) = (x - 1) \left ( \displaystyle \sum_0^m x^i \right ), \tag 4$
which shows that the formula
$x^k - 1 = (x - 1) \left ( \displaystyle \sum_0^{k -1} x^i \right ) \tag 5$
is valid for all positive integers $k$.
</s>