quiz6 - a n = 6 a n-1-9 a n-2 + 4 n ; a = 4 ,a 1 = 4 Well...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
Name: Math 55 Quiz 6 SOLUTIONS July 17, 2009 GSI: Rob Bayer You have until 4:00 to complete this quiz. You must show your work. 1. (3 pts) Find a recurrence relation for the number of ways to make n cents using only pennies and nickels: Any such sequence of change either is n - 1 cents followed by a penny, or n - 5 cents followed by a nickel. Thus, the recurrence relation is: a n = a n - 1 + a n - 5 ; a 0 = a 1 = a 2 = a 3 = a 4 = 1 2. (3 pts) Find the solution to the recurrence relation a n = 5 a n - 1 + 14 a n - 2 ; a 0 = 0 ,a 1 = 25 We solve r 2 - 5 r - 14 = 0 and get r = 7 , - 2. Thus, the general solution is c 1 7 n + c 2 ( - 2) n . The initial conditions tell us that c 1 + c 2 = 0 and that 7 c 1 - 2 c 2 = 25. Solving this gives c 1 = 25 9 ,c 2 = - 25 9 Thus, the solution is a n = 25 9 (7 n - ( - 2) n ) 3. (4 pts) Find the solution to the recurrence relation
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: a n = 6 a n-1-9 a n-2 + 4 n ; a = 4 ,a 1 = 4 Well start by solving r 2-6 r + 9 = 0 and get r = 3 , 3. Thus, the homogeneous part has solution c 1 3 n + c 2 n 3 n . We now guess p n = An + B and plug in: An + B-6( A ( n-1) + B ) + 9( A ( n-2) + B ) = 4 n ( A-6 A + 9 A ) n + ( B + 6 A-6 B-18 A + 9 B ) = 4 n 4 An + (4 B-12 A ) = 4 n So A = 1 which makes B = 3. Thus, the general solution is a n = c 1 3 n + c 2 n 3 n + n + 3. Plugging in initial conditions will give 4 = c 1 +3 so c 1 = 1 and 4 = 3 c 1 +3 c 2 +4, so c 2 =-1. Thus, the solution is a n = 3 n-n 3 n + n + 3...
View Full Document

This note was uploaded on 08/31/2009 for the course MATH 55 taught by Professor Strain during the Summer '08 term at University of California, Berkeley.

Ask a homework question - tutors are online