# Express Sn as a function of n.

• October 5th 2011, 02:43 PM
jessaray
Express Sn as a function of n.
I need to figure out this function before I can do the actual problem that concerns the function. I don't know why I'm having so much trouble with this, but I just can't figure it out!

S(0) = 1, S(1) = 0, and S(n+1) = 3S(n) – 2S(n-1)
Express S(n) as a function of n.

And the letters/numbers in parenthesis are supposed to be subscripts of each S.

These are the first 6 numbers in the sequence.
S(0) = 1
S(1) = 0
S(2) = -2
S(3) = -6
S(4) = -14
S(5) = -30
S(6) = -62

Any help?
• October 5th 2011, 03:11 PM
TheEmptySet
Re: Express Sn as a function of n.
Quote:

Originally Posted by jessaray
I need to figure out this function before I can do the actual problem that concerns the function. I don't know why I'm having so much trouble with this, but I just can't figure it out!

S(0) = 1, S(1) = 0, and S(n+1) = 3S(n) – 2S(n-1)
Express S(n) as a function of n.

And the letters/numbers in parenthesis are supposed to be subscripts of each S.

These are the first 6 numbers in the sequence.
S(0) = 1
S(1) = 0
S(2) = -2
S(3) = -6
S(4) = -14
S(5) = -30
S(6) = -62

Any help?

What have you tried? As always there is a bit of trial and error when looking for a pattern. Starting with $S_2$ what is the difference between the sucessive terms? Look and see if you can see a pattern.
• October 5th 2011, 06:39 PM
Prove It
Re: Express Sn as a function of n.
Quote:

Originally Posted by jessaray
I need to figure out this function before I can do the actual problem that concerns the function. I don't know why I'm having so much trouble with this, but I just can't figure it out!

S(0) = 1, S(1) = 0, and S(n+1) = 3S(n) – 2S(n-1)
Express S(n) as a function of n.

And the letters/numbers in parenthesis are supposed to be subscripts of each S.

These are the first 6 numbers in the sequence.
S(0) = 1
S(1) = 0
S(2) = -2
S(3) = -6
S(4) = -14
S(5) = -30
S(6) = -62

Any help?

You have $\displaystyle S_0 = 1, S_1 = 0, S_{n+1} = 3S_n - 2S_{n-1}$

Assume there's a solution of the form $\displaystyle S_n = r^n$, then substituting into the recurrence relationship will give

\displaystyle \begin{align*} r^{n+1} &= 3r^n - 2r^{n-1} \\ r^{n-1}r^2 &= 3r^{n-1}r - 2r^{n-1} \\ r^2 &= 3r - 2 \\ r^2 - 3r + 2 &= 0 \\ (r - 1)(r - 2) &= 0 \\ r = 1\textrm{ or }r &= 2 \end{align*}

So the solution is

\displaystyle \begin{align*} S_n &= C_11^n + C_22^n \\ S_n &= C_1 + C_2 2^n \end{align*}

and now using the initial conditions $\displaystyle S_0 = 1$ and $\displaystyle S_1 = 0$, we find

$\displaystyle 1 = C_1 + C_2 2^0 \implies 1 = C_1 + C_2$ and $\displaystyle 0 = C_1 + C_22^1 \implies 0 = C_1 + 2C_2$.

Solving these equations simultaneously gives

$\displaystyle C_1 = 2, C_2 = -1$

and therefore the solution is

$\displaystyle S_n = 2 - 2^n$
• October 6th 2011, 08:14 AM
TheEmptySet
Re: Express Sn as a function of n.
Quote:

Originally Posted by TheEmptySet
What have you tried? As always there is a bit of trial and error when looking for a pattern. Starting with $S_2$ what is the difference between the sucessive terms? Look and see if you can see a pattern.

Just for completeness I will finish what I had hinted at.
There is a pattern here. the difference between

$S_3-S_2=4=2^2$
$S_4-S_3=8=2^3$
$S_5-S_4=16=2^4$
$S_6-S_5=32=2^5$

So know we know the solution is of the form mentioned in Prove It's post.