Let $n=km \in \mathbb N$, show $\left(2^{k}+1\right)\left(2^{k m-k}-2^{k m-2 k}+2^{k m-3 k}-2^{k m-4 k}+\cdots+1\right)=\left(2^{k m}+1\right)$ Let $n=km,k,m \in \mathbb N$ and let $m$ be odd.
Show $\left(2^{k}+1\right)\left(2^{k m-k}-2^{k m-2 k}+2^{k m-3 k}-2^{k m-4 k}+\cdots+1\right)=\left(2^{k m}+1\right)$.
Important: Remember to consider where you use that $m$ is odd. (I can't figure out where I'm using this property of $m$(?!))
Here are my calculations
$$\begin{array}{r}{\left(2^{k}+1\right)\left(2^{k m-k}-2^{k m-2 k}+2^{k m-3 k}-2^{k m-4 k}+\cdots+1\right)=} \\ {2^{k m}-2^{k m-k}+2^{k m-2 k}-2^{k m-3 k}+\cdots+2^{k}} \\ {+\left(2^{k m-k}-2^{k m-2 k}+2^{k m-3 k}-2^{k m-4 k}+\cdots+1\right)=} \\ {\cdot \cdot+1=} \\ {2^{k m}+1}\end{array}$$
The calculations are simple enough.
 A: If we multiply we get:
$$2^{km} + (2^{km-1} - 2^{km-1}) - (2^{km-2} - 2^{km - 2}) + ... - (2^{k} - 2^{k}) + 1 = 2^{km} + 1$$
because the terms are pairwise canceling. If $m$ was even, you would have a different sign at the end, so it would be $2^{km} - 1$.
A: $m$ is odd is used in the base case $m = 1$ of the inductive proof below (OP has  $\,x = 2^k$). If $m$ is even then the division terminates at $\,m=0\,$ leaving remainder $\,x^m+1\,\bmod\, x+1\, =\, (-1)^m+1 = \color{#0a0}2\,$ (vs. $0$) yielding an additional final term $\,\color{#0a0}2/(x+1),\,$ e.g. $\ (x^2+1)/(x+1)\, =\, x-1 + \color{#0a0}2/(x-1)$
Base case: $\, m = 1:\ \dfrac{x+1}{x+1} = \color{#c00}1$
$\!\begin{align}\text{Inductive step:}\ \ \ \ \ \dfrac{x^m+1}{x+1} &=\ x^{m-1} - x^{m-2} + \dfrac{x^{m-2}+1}{x+1}\\[.2em] &=\, x^{m-1}-x^{m-2} + (x^{m-3}-x^{m-4} + \cdots +\color{#c00} 1)\ \ \rm by\ induction\end{align}$
That this was not clear seems to indicate that you have not adequately understood the induction implied by the informal ellipses used in your sketched proof. One of the purposes of formal inductive proofs is to help prevent our intuition from leading us astray in this manner.
