I'm trying to prove that every non-prime natural number greater than $1$ can is equal to a sum of consecutive even or odd numbers.
This can be resumed in :
« $p,m,n \in ℕ$» , «$p > 1$» , «$n > 0$» and «$ m>0$».
The problem is :
Prove that « $p = n+(n+2)+(n+4)+...+(n+2m)$ ».
So far, I only managed to prove it for number such as $p = 2a+2$ with $a \in ℕ$.
Can you please help me ?
Let $p = ab$.
wlog let $a \le b$.
Set $m = a - 1$, and $n = b - m = b + 1 - a$.
Now the sum of your series = $(n+m)(m+1) = ab = p.$