
$$ \begin{array}{rclll} n^3-(n-1)^3 &= &3n^2 &-3n &+1\\ (n-1)^3-(n-2)^3 &= &3(n-1)^2 &-3(n-1) &+1\\ (n-2)^3-(n-3)^3 &= &3(n-2)^2 &-3(n-2) &+1\\ \vdots &=& &\vdots & \\ 3^3-2^3 &= &3(3^2) &-3(3) &+1\\ 2^3-1^3 &= &3(2^2) &-3(2) &+1\\ 1^3-0^3 &= &3(1^2) &-3(1) &+1\\ \underline{\hphantom{(n-2)^3-(n-3)^3}} & &\underline{\hphantom{3(n-2)^2}} &\underline{\hphantom{-3(n-2)}} &\underline{\hphantom{+1}}\\ n^3-0^3 &= & 3f_2(n) &-3f_1(n) &+n \end{array} $$
Can somebody explain me how these results are disposed intuitively? I didn't understand why $$(n-1)^3 -(n-2)^3$$ became equals to $$3(n-1)^2 - 3(n-1) + 1$$
How do this transformation was done?
Thanks!
$(x-1)^3=x^3-3x^2+3x-1$; now set $x=n-1$.