5. Recursion and Iteration
Sign In
5, 17, 53, 161, 485
a_1&=5 a_(n+1)&=3a_n+2 To do so, we will use a table. To find a_2 we will substitute 1 for n in the above formula. To find a_3 we will substitute 2 for n, and so on.
| n | a_(n+1)=3a_n+2 | 3a_n+2 | a_(n+1) |
|---|---|---|---|
| - | a_1= 5 | - | - |
| 1 | a_(1+1)=3a_1+2 ⇕ a_2=3a_1+2 |
a_2=3 a_1+2 ⇓ a_2=3( 5)+2 |
a_2= 17 |
| 2 | a_(2+1)=3a_2+2 ⇕ a_3=3a_2+2 |
a_3=3 a_2+2 ⇓ a_3=3( 17)+2 |
a_3= 53 |
| 3 | a_(3+1)=3a_3+2 ⇕ a_4=3a_3+2 |
a_4=3 a_3+2 ⇓ a_4=3( 53)+2 |
a_4= 161 |
| 4 | a_(4+1)=3a_4+2 ⇕ a_5=3a_4+2 |
a_5=3 a_4+2 ⇓ a_5=3( 161)+2 |
a_5= 485 |
The first five terms of the sequence are 5, 17, 53, 161, and 485.