<s>[INST] Generalize the formula :$1=1, 3+5=8, 7+9+11=27, 13+15+17+19=64$ So the solution of this is $n^3$, as $1=1^3, 3+5=2^3, 7+9+11=3^3$
So I find that the $n+1 = m^2+3m+2 + (n_m)(m+1)$ where $n_m$ is the largest number in the previous equation and $m$ is the number of terms in last equation. How can I prove by induction that the solution is $n^3$, do I have to prove $(n+1)^3$ is equal to that or any other method or I prove that $(n+1)^3-n = 2m^2+2m+2+n_m$ (the differience between $(n+1)$ and $n$
 [/INST] The sequence is
$$1=1 \  , \ 3+5 = 8 \ , \ 7+9+11 = 27 \ , \ \dots$$
So you can see that
$$a_n = \sum_{k=1}^{1+2+...+n} (2k-1) - \sum_{k=1}^{n-1} a_k =$$
$$\sum_{k=0}^{n(n+1)/2} (2k-1) - a_{n-1} =\frac{1}{4}n^2(n+1)^2 - \sum_{k=1}^{n-1} a_k$$
because you can view the $n$-th term as the sum of $1+2+\dots+n$ odd numbers minus the sum of all the other previous terms ($27 = 1+3+5+7+9+11 - (1)-(3+5)$).
So the base step is clear, now for the inductive one we use strong induction (we say it works from $1$ to $n-1$) then
$$a_{n} = \frac{1}{4}n^2(n+1)^2 - \sum_{k=1}^{n-1} k^3 = \frac{1}{4}n^2(n+1)^2 -\frac{1}{4}(n-1)^2n^2 = n^3$$
so the formula is proven.
</s>