1. ## Difference equation

Consider s(n)=1+3^3+5^3+...+(2n-1)^3. What first order difference equation does s(n) satisfy?

2. Originally Posted by bryan06
Consider s(n)=1+3^3+5^3+...+(2n-1)^3. What first order difference equation does s(n) satisfy?
s(n)-s(n-1)=(2n-1)^3

3. thank you so much!!but is this the same as S(n)=(2n^2 -1)n^2 because i got this from the answer book but have no clue how to do it...is it possible if you could kindly talk me through some of the steps??thanksss!!

Originally Posted by alexmahone
s(n)-s(n-1)=(2n-1)^3

4. Originally Posted by bryan06
thank you so much!!but is this the same as S(n)=(2n^2 -1)n^2 because i got this from the answer book but have no clue how to do it...is it possible if you could kindly talk me through some of the steps??thanksss!!
Let's try to prove the general formula for s(n) using induction.

$s(n-1)=[2(n-1)^2-1](n-1)^2$

$s(n)=[2(n-1)^2-1](n-1)^2+(2n-1)^3$ (Using the difference equation)

$=(2n^2-4n+2-1)(n-1)^2+8n^3-1-6n(2n-1)$

$=(2n^2-4n+1)(n^2-2n+1)+8n^3-1-12n^2+6n$

$=2n^4-4n^3+n^2-4n^3+8n^2-2n+2n^2-4n+1+8n^3-1-12n^2+6n$

$=2n^4-n^2$

$=(2n^2-1)n^2$

QED