Prove the sum of cubes formula:
13+23+⋯+(n−1)3+n3=4n2(n+1)2.
In fact, it is only necessary to prove that 9797 cannot be expressed as the sum of cubes of several consecutive positive integers.
Assume there exist m,n∈N, such that
9797=(m+1)3+(m+2)3+⋯+(n−1)3+n3.
Then 9797=(13+23+⋯+n3)−
(13+23+⋯+m3)=4n2(n+1)2−4m2(m+1)2.
Thus, n2(n+1)2−m2(m+1)2=4×9797.
Using the difference of squares formula, factorize to get
(n(n+1)+m(m+1))(n(n+1)−m(m+1))=4×9797.
Set n(n+1)+m(m+1)=2×97s(s∈N+), n(n+1)−m(m+1)=2×97t(t∈N).
Then n(n+1)−m(m+1)
=(n+m+1)(n−m)=2×97t.
Consider two cases.
(1) {n+m+1=2×97rn−m=97t−r,(r∈N+,t⩾r).
Solving, we get {m=22×97r−97t−r−1,n=22×97r+97t−r−1.
Thus, n(n+1)+m(m+1)
=4(2×97r+97t−r)2+(2×97r−97t−r)2−2
=972r+2972t−2r−1=2×97s.
Therefore, 2×972r+972t−2r−1=4×97s.
Since s⩾1,r⩾1, we have 2t−2r=0 (otherwise, the left side of equation (1) cannot be divisible by 97).
Thus, 972r=2×97s, which is impossible.
(2) {n+m+1=97r,n−m=2×97t−r(r∈N+,t⩾r).
Solving, we get {m=297r−2×97t−r−1,n=297r+2×97t−r−1.
Thus, n(n+1)+m(m+1)
=4(97r+2×97t−r)2+(97r−2×97t−r)2−2=2972r−1+972t−2r=2×97s.
Therefore, 972r−1+2×972t−2r=4×97s.
Since s⩾1,r⩾1, we have 2t−2r=0 (otherwise, the left side of equation (2) cannot be divisible by 97).
Thus, 972r+1=2×97s, which is impossible.
In conclusion, 9797 cannot be expressed as the sum of cubes of several consecutive positive integers.