recurrence relations...daniel h. luecking recurrence relations feb. 17, 20213/18 the rules are as...
TRANSCRIPT
![Page 1: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/1.jpg)
Recurrence Relations
Daniel H. Luecking
Feb. 17, 2021
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 1 / 18
![Page 2: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/2.jpg)
Combinatorics problems that lead to recurrence relations
The Towers of Hanoi problem is to take a stack of disks and move themall to another stack using only certain allowed moves. The questions are:(1) can this be done? and (2) how can it be done? and (3) how manymoves does it take?
Here is a picture of a possible starting point with 13 disks:
The goal is to move all the disks from the first pole to the last.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 2 / 18
![Page 3: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/3.jpg)
Combinatorics problems that lead to recurrence relations
The Towers of Hanoi problem is to take a stack of disks and move themall to another stack using only certain allowed moves. The questions are:(1) can this be done? and (2) how can it be done? and (3) how manymoves does it take?
Here is a picture of a possible starting point with 13 disks:
The goal is to move all the disks from the first pole to the last.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 2 / 18
![Page 4: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/4.jpg)
The rules are as follows:
There are three poles, two of them empty.
The disks all have a hole in the center and they are stacked on thefirst pole. The disks have different sizes and they are stacked in orderof size with the largest on the bottom.
One disk at a time may be moved from the top of one stack andplaced on any of the other two poles.
It is not allowed to place a disk on top of a smaller disk.
The game ends when all the disks are on the third pole
If we suppose there are n disks, then we can show this is possible asfollows. It is certainly possible if n = 0 (zero moves required) or if n = 1(one move required).
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 3 / 18
![Page 5: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/5.jpg)
The rules are as follows:
There are three poles, two of them empty.
The disks all have a hole in the center and they are stacked on thefirst pole. The disks have different sizes and they are stacked in orderof size with the largest on the bottom.
One disk at a time may be moved from the top of one stack andplaced on any of the other two poles.
It is not allowed to place a disk on top of a smaller disk.
The game ends when all the disks are on the third pole
If we suppose there are n disks, then we can show this is possible asfollows. It is certainly possible if n = 0 (zero moves required) or if n = 1(one move required).
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 3 / 18
![Page 6: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/6.jpg)
The rules are as follows:
There are three poles, two of them empty.
The disks all have a hole in the center and they are stacked on thefirst pole. The disks have different sizes and they are stacked in orderof size with the largest on the bottom.
One disk at a time may be moved from the top of one stack andplaced on any of the other two poles.
It is not allowed to place a disk on top of a smaller disk.
The game ends when all the disks are on the third pole
If we suppose there are n disks, then we can show this is possible asfollows. It is certainly possible if n = 0 (zero moves required) or if n = 1(one move required).
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 3 / 18
![Page 7: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/7.jpg)
The rules are as follows:
There are three poles, two of them empty.
The disks all have a hole in the center and they are stacked on thefirst pole. The disks have different sizes and they are stacked in orderof size with the largest on the bottom.
One disk at a time may be moved from the top of one stack andplaced on any of the other two poles.
It is not allowed to place a disk on top of a smaller disk.
The game ends when all the disks are on the third pole
If we suppose there are n disks, then we can show this is possible asfollows. It is certainly possible if n = 0 (zero moves required) or if n = 1(one move required).
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 3 / 18
![Page 8: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/8.jpg)
The rules are as follows:
There are three poles, two of them empty.
The disks all have a hole in the center and they are stacked on thefirst pole. The disks have different sizes and they are stacked in orderof size with the largest on the bottom.
One disk at a time may be moved from the top of one stack andplaced on any of the other two poles.
It is not allowed to place a disk on top of a smaller disk.
The game ends when all the disks are on the third pole
If we suppose there are n disks, then we can show this is possible asfollows. It is certainly possible if n = 0 (zero moves required) or if n = 1(one move required).
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 3 / 18
![Page 9: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/9.jpg)
The rules are as follows:
There are three poles, two of them empty.
The disks all have a hole in the center and they are stacked on thefirst pole. The disks have different sizes and they are stacked in orderof size with the largest on the bottom.
One disk at a time may be moved from the top of one stack andplaced on any of the other two poles.
It is not allowed to place a disk on top of a smaller disk.
The game ends when all the disks are on the third pole
If we suppose there are n disks, then we can show this is possible asfollows. It is certainly possible if n = 0 (zero moves required) or if n = 1(one move required).
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 3 / 18
![Page 10: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/10.jpg)
If it can be done with n − 1 disks, it can be done with n disks: move thetop n− 1 disks to the second pole (exchanging the roles of poles 2 and 3).
Then move the bottom disk to the third pole. Then move the remainingn − 1 disks onto the third pole (exchanging the roles of poles 1 and 2).
This proves it can always be done.
How can it be done? That is, what sequence of moves are required?Pretty much the only way to do this is to write a computer program thatgenerates the moves: feed it the order of the poles and the number ofdisks, have it call itself with n reduced.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 4 / 18
![Page 11: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/11.jpg)
If it can be done with n − 1 disks, it can be done with n disks: move thetop n− 1 disks to the second pole (exchanging the roles of poles 2 and 3).Then move the bottom disk to the third pole.
Then move the remainingn − 1 disks onto the third pole (exchanging the roles of poles 1 and 2).
This proves it can always be done.
How can it be done? That is, what sequence of moves are required?Pretty much the only way to do this is to write a computer program thatgenerates the moves: feed it the order of the poles and the number ofdisks, have it call itself with n reduced.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 4 / 18
![Page 12: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/12.jpg)
If it can be done with n − 1 disks, it can be done with n disks: move thetop n− 1 disks to the second pole (exchanging the roles of poles 2 and 3).Then move the bottom disk to the third pole. Then move the remainingn − 1 disks onto the third pole (exchanging the roles of poles 1 and 2).
This proves it can always be done.
How can it be done? That is, what sequence of moves are required?Pretty much the only way to do this is to write a computer program thatgenerates the moves: feed it the order of the poles and the number ofdisks, have it call itself with n reduced.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 4 / 18
![Page 13: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/13.jpg)
If it can be done with n − 1 disks, it can be done with n disks: move thetop n− 1 disks to the second pole (exchanging the roles of poles 2 and 3).Then move the bottom disk to the third pole. Then move the remainingn − 1 disks onto the third pole (exchanging the roles of poles 1 and 2).
This proves it can always be done.
How can it be done? That is, what sequence of moves are required?
Pretty much the only way to do this is to write a computer program thatgenerates the moves: feed it the order of the poles and the number ofdisks, have it call itself with n reduced.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 4 / 18
![Page 14: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/14.jpg)
If it can be done with n − 1 disks, it can be done with n disks: move thetop n− 1 disks to the second pole (exchanging the roles of poles 2 and 3).Then move the bottom disk to the third pole. Then move the remainingn − 1 disks onto the third pole (exchanging the roles of poles 1 and 2).
This proves it can always be done.
How can it be done? That is, what sequence of moves are required?Pretty much the only way to do this is to write a computer program thatgenerates the moves: feed it the order of the poles and the number ofdisks, have it call itself with n reduced.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 4 / 18
![Page 15: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/15.jpg)
This program is based on the method just discussed:
def TOH (a,b,c,n) // a = starting pole, c = ending poleif n=1: move a disk from a to c;
else:
call TOH(a,c,b,n-1);
move a disc from a to c;
call TOH(b,a,c,n-1)
endif
enddef
TOH(1,2,3,20) // if n = 20
Be warned: this generates 220 − 1 moves, more than 1 million.
How many moves does it take? Let an be the number of moves for ndisks. The above process requires an−1 moves to get the top n − 1 disksfrom pole 1 to 2, then 1 move to get the bottom disk from 1 to 3 andthen an−1 moves to get the other n − 1 disks from 2 to 3.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 5 / 18
![Page 16: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/16.jpg)
This program is based on the method just discussed:
def TOH (a,b,c,n) // a = starting pole, c = ending poleif n=1: move a disk from a to c;
else:
call TOH(a,c,b,n-1);
move a disc from a to c;
call TOH(b,a,c,n-1)
endif
enddef
TOH(1,2,3,20) // if n = 20
Be warned: this generates 220 − 1 moves, more than 1 million.
How many moves does it take? Let an be the number of moves for ndisks.
The above process requires an−1 moves to get the top n − 1 disksfrom pole 1 to 2, then 1 move to get the bottom disk from 1 to 3 andthen an−1 moves to get the other n − 1 disks from 2 to 3.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 5 / 18
![Page 17: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/17.jpg)
This program is based on the method just discussed:
def TOH (a,b,c,n) // a = starting pole, c = ending poleif n=1: move a disk from a to c;
else:
call TOH(a,c,b,n-1);
move a disc from a to c;
call TOH(b,a,c,n-1)
endif
enddef
TOH(1,2,3,20) // if n = 20
Be warned: this generates 220 − 1 moves, more than 1 million.
How many moves does it take? Let an be the number of moves for ndisks. The above process requires an−1 moves to get the top n − 1 disksfrom pole 1 to 2, then 1 move to get the bottom disk from 1 to 3 andthen an−1 moves to get the other n − 1 disks from 2 to 3.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 5 / 18
![Page 18: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/18.jpg)
That is
an = 2an−1 + 1, n ≥ 1
a0 = 0.
The solution is an = 2n − 1. It’s not hard to work out that a1 = 1, a2 = 3,a3 = 7, a4 = 15 and so on, so this is an easy guess (for CompSci majors).You should test your understanding by checking that this formula works.
The chip stacking problem
You have a lot of poker chips (colored disks) all either blue or white. Howmany ways can you stack n of then so that no white chip is directly onanother white chip?
An equivalent problem is: how many different bitstrings (strings consistingonly of 0’s and 1’s) of length n contain no consecutive 1’s?
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 6 / 18
![Page 19: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/19.jpg)
That is
an = 2an−1 + 1, n ≥ 1
a0 = 0.
The solution is an = 2n − 1. It’s not hard to work out that a1 = 1, a2 = 3,a3 = 7, a4 = 15 and so on, so this is an easy guess (for CompSci majors).
You should test your understanding by checking that this formula works.
The chip stacking problem
You have a lot of poker chips (colored disks) all either blue or white. Howmany ways can you stack n of then so that no white chip is directly onanother white chip?
An equivalent problem is: how many different bitstrings (strings consistingonly of 0’s and 1’s) of length n contain no consecutive 1’s?
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 6 / 18
![Page 20: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/20.jpg)
That is
an = 2an−1 + 1, n ≥ 1
a0 = 0.
The solution is an = 2n − 1. It’s not hard to work out that a1 = 1, a2 = 3,a3 = 7, a4 = 15 and so on, so this is an easy guess (for CompSci majors).You should test your understanding by checking that this formula works.
The chip stacking problem
You have a lot of poker chips (colored disks) all either blue or white. Howmany ways can you stack n of then so that no white chip is directly onanother white chip?
An equivalent problem is: how many different bitstrings (strings consistingonly of 0’s and 1’s) of length n contain no consecutive 1’s?
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 6 / 18
![Page 21: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/21.jpg)
That is
an = 2an−1 + 1, n ≥ 1
a0 = 0.
The solution is an = 2n − 1. It’s not hard to work out that a1 = 1, a2 = 3,a3 = 7, a4 = 15 and so on, so this is an easy guess (for CompSci majors).You should test your understanding by checking that this formula works.
The chip stacking problem
You have a lot of poker chips (colored disks) all either blue or white. Howmany ways can you stack n of then so that no white chip is directly onanother white chip?
An equivalent problem is: how many different bitstrings (strings consistingonly of 0’s and 1’s) of length n contain no consecutive 1’s?
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 6 / 18
![Page 22: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/22.jpg)
Let an be the number of stacks of n chips with no consecutive white chips.We consider what the top chip might be. It might be white or blue.
If it is blue then the one beneath it can be any color and there are an−1
possibilities.
If the top one is a white chip, the one below it must be blue and belowthat can be anything. Thus there are an−2 possibilities.
That is
an = an−1 + an−2, n ≥ 2
a0 = 1, a1 = 2.
So the sequence an looks like 1, 2, 3, 5, 8, 13, . . . .
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 7 / 18
![Page 23: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/23.jpg)
Let an be the number of stacks of n chips with no consecutive white chips.We consider what the top chip might be. It might be white or blue.
If it is blue then the one beneath it can be any color and there are an−1
possibilities.
If the top one is a white chip, the one below it must be blue and belowthat can be anything. Thus there are an−2 possibilities.
That is
an = an−1 + an−2, n ≥ 2
a0 = 1, a1 = 2.
So the sequence an looks like 1, 2, 3, 5, 8, 13, . . . .
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 7 / 18
![Page 24: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/24.jpg)
Let an be the number of stacks of n chips with no consecutive white chips.We consider what the top chip might be. It might be white or blue.
If it is blue then the one beneath it can be any color and there are an−1
possibilities.
If the top one is a white chip, the one below it must be blue and belowthat can be anything. Thus there are an−2 possibilities.
That is
an = an−1 + an−2, n ≥ 2
a0 = 1, a1 = 2.
So the sequence an looks like 1, 2, 3, 5, 8, 13, . . . .
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 7 / 18
![Page 25: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/25.jpg)
Let an be the number of stacks of n chips with no consecutive white chips.We consider what the top chip might be. It might be white or blue.
If it is blue then the one beneath it can be any color and there are an−1
possibilities.
If the top one is a white chip, the one below it must be blue and belowthat can be anything. Thus there are an−2 possibilities.
That is
an = an−1 + an−2, n ≥ 2
a0 = 1, a1 = 2.
So the sequence an looks like 1, 2, 3, 5, 8, 13, . . . .
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 7 / 18
![Page 26: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/26.jpg)
Let an be the number of stacks of n chips with no consecutive white chips.We consider what the top chip might be. It might be white or blue.
If it is blue then the one beneath it can be any color and there are an−1
possibilities.
If the top one is a white chip, the one below it must be blue and belowthat can be anything. Thus there are an−2 possibilities.
That is
an = an−1 + an−2, n ≥ 2
a0 = 1, a1 = 2.
So the sequence an looks like 1, 2, 3, 5, 8, 13, . . . .
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 7 / 18
![Page 27: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/27.jpg)
Our next section will give us the tools to find the formula
an =5 + 3
√5
10
(1 +√
5
2
)n
+5− 3
√5
10
(1−√
5
2
)n
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 8 / 18
![Page 28: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/28.jpg)
Linear recurrence relations
The following is a perfectly valid recurrence relation:
an = an−1 · an−2.
and there are ways to solve problems involving it.
However we will focus,for the moment, only on recurrence relations like the following
an = 3an−1
an = 2an−1 − 5n2an−2
an = 4an−1 + 2an−2 + 5an−3
These are called linear recurrence relations. The definition of linear is thatthey can be written in the following form (this is for second order):
an + b(n)an−1 + c(n)an−2 = h(n)
where b, c and h are explicit functions of n that make no reference to anyterms of the unknown sequence ak . If the function h(n) on the right sideis just 0, the recurrence relation is called homogeneous.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 9 / 18
![Page 29: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/29.jpg)
Linear recurrence relations
The following is a perfectly valid recurrence relation:
an = an−1 · an−2.
and there are ways to solve problems involving it. However we will focus,for the moment, only on recurrence relations like the following
an = 3an−1
an = 2an−1 − 5n2an−2
an = 4an−1 + 2an−2 + 5an−3
These are called linear recurrence relations. The definition of linear is thatthey can be written in the following form (this is for second order):
an + b(n)an−1 + c(n)an−2 = h(n)
where b, c and h are explicit functions of n that make no reference to anyterms of the unknown sequence ak . If the function h(n) on the right sideis just 0, the recurrence relation is called homogeneous.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 9 / 18
![Page 30: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/30.jpg)
Linear recurrence relations
The following is a perfectly valid recurrence relation:
an = an−1 · an−2.
and there are ways to solve problems involving it. However we will focus,for the moment, only on recurrence relations like the following
an = 3an−1
an = 2an−1 − 5n2an−2
an = 4an−1 + 2an−2 + 5an−3
These are called linear recurrence relations. The definition of linear is thatthey can be written in the following form (this is for second order):
an + b(n)an−1 + c(n)an−2 = h(n)
where b, c and h are explicit functions of n that make no reference to anyterms of the unknown sequence ak . If the function h(n) on the right sideis just 0, the recurrence relation is called homogeneous.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 9 / 18
![Page 31: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/31.jpg)
Linear recurrence relations
The following is a perfectly valid recurrence relation:
an = an−1 · an−2.
and there are ways to solve problems involving it. However we will focus,for the moment, only on recurrence relations like the following
an = 3an−1
an = 2an−1 − 5n2an−2
an = 4an−1 + 2an−2 + 5an−3
These are called linear recurrence relations. The definition of linear is thatthey can be written in the following form (this is for second order):
an + b(n)an−1 + c(n)an−2 = h(n)
where b, c and h are explicit functions of n that make no reference to anyterms of the unknown sequence ak .
If the function h(n) on the right sideis just 0, the recurrence relation is called homogeneous.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 9 / 18
![Page 32: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/32.jpg)
Linear recurrence relations
The following is a perfectly valid recurrence relation:
an = an−1 · an−2.
and there are ways to solve problems involving it. However we will focus,for the moment, only on recurrence relations like the following
an = 3an−1
an = 2an−1 − 5n2an−2
an = 4an−1 + 2an−2 + 5an−3
These are called linear recurrence relations. The definition of linear is thatthey can be written in the following form (this is for second order):
an + b(n)an−1 + c(n)an−2 = h(n)
where b, c and h are explicit functions of n that make no reference to anyterms of the unknown sequence ak . If the function h(n) on the right sideis just 0, the recurrence relation is called homogeneous.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 9 / 18
![Page 33: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/33.jpg)
There is a theory of linear recurrence relations that helps us build solutionsout of simpler parts.
For this discussion we will refer to an = f (n) as asolution if it just satisfies the recurrence equation, ignoring any initialcondition(s).
Theorem
If an = f (n) is a solutions of a homogeneous linear recurrence relation,then for any constant C so is an = Cf (n). If an = g(n) is also a solution,then so is an = f (n) + g(n).
For example, consider
an − 5an−1 + 6an−2 = 0
which is homogeneous and linear. Let us check that both an = 3n andan = 2n are solutions.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 10 / 18
![Page 34: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/34.jpg)
There is a theory of linear recurrence relations that helps us build solutionsout of simpler parts. For this discussion we will refer to an = f (n) as asolution if it just satisfies the recurrence equation, ignoring any initialcondition(s).
Theorem
If an = f (n) is a solutions of a homogeneous linear recurrence relation,then for any constant C so is an = Cf (n). If an = g(n) is also a solution,then so is an = f (n) + g(n).
For example, consider
an − 5an−1 + 6an−2 = 0
which is homogeneous and linear. Let us check that both an = 3n andan = 2n are solutions.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 10 / 18
![Page 35: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/35.jpg)
There is a theory of linear recurrence relations that helps us build solutionsout of simpler parts. For this discussion we will refer to an = f (n) as asolution if it just satisfies the recurrence equation, ignoring any initialcondition(s).
Theorem
If an = f (n) is a solutions of a homogeneous linear recurrence relation,then for any constant C so is an = Cf (n). If an = g(n) is also a solution,then so is an = f (n) + g(n).
For example, consider
an − 5an−1 + 6an−2 = 0
which is homogeneous and linear. Let us check that both an = 3n andan = 2n are solutions.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 10 / 18
![Page 36: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/36.jpg)
There is a theory of linear recurrence relations that helps us build solutionsout of simpler parts. For this discussion we will refer to an = f (n) as asolution if it just satisfies the recurrence equation, ignoring any initialcondition(s).
Theorem
If an = f (n) is a solutions of a homogeneous linear recurrence relation,then for any constant C so is an = Cf (n). If an = g(n) is also a solution,then so is an = f (n) + g(n).
For example, consider
an − 5an−1 + 6an−2 = 0
which is homogeneous and linear.
Let us check that both an = 3n andan = 2n are solutions.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 10 / 18
![Page 37: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/37.jpg)
There is a theory of linear recurrence relations that helps us build solutionsout of simpler parts. For this discussion we will refer to an = f (n) as asolution if it just satisfies the recurrence equation, ignoring any initialcondition(s).
Theorem
If an = f (n) is a solutions of a homogeneous linear recurrence relation,then for any constant C so is an = Cf (n). If an = g(n) is also a solution,then so is an = f (n) + g(n).
For example, consider
an − 5an−1 + 6an−2 = 0
which is homogeneous and linear. Let us check that both an = 3n andan = 2n are solutions.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 10 / 18
![Page 38: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/38.jpg)
For the first, we simply put
an = 3n, an−1 = 3n−1, an−2 = 3n−2
into the recurrence relation to get
3n − 5 · 3n−1 + 6 · 3n−2 = 0
We can rearrange the left side:
(32 − 5 · 31 + 6)3n−2 = 0 or (9− 5 · 3 + 6)3n−2 = 0
and clearly the last one says 0 · 3n−2 = 0, which is always true. Similarcalculations with an = 2n lead to
(22 − 5 · 2 + 6)2n−2 = 0
which is also true.
With these solutions we can build new solutions: an = 2(3n) andan = −(2n) and an = 2(3n)− (2n). Note that if we add initial conditionsa0 = 1 and a1 = 4, then only the last of these satisfies them both.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 11 / 18
![Page 39: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/39.jpg)
For the first, we simply put
an = 3n, an−1 = 3n−1, an−2 = 3n−2
into the recurrence relation to get
3n − 5 · 3n−1 + 6 · 3n−2 = 0
We can rearrange the left side:
(32 − 5 · 31 + 6)3n−2 = 0 or (9− 5 · 3 + 6)3n−2 = 0
and clearly the last one says 0 · 3n−2 = 0, which is always true.
Similarcalculations with an = 2n lead to
(22 − 5 · 2 + 6)2n−2 = 0
which is also true.
With these solutions we can build new solutions: an = 2(3n) andan = −(2n) and an = 2(3n)− (2n). Note that if we add initial conditionsa0 = 1 and a1 = 4, then only the last of these satisfies them both.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 11 / 18
![Page 40: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/40.jpg)
For the first, we simply put
an = 3n, an−1 = 3n−1, an−2 = 3n−2
into the recurrence relation to get
3n − 5 · 3n−1 + 6 · 3n−2 = 0
We can rearrange the left side:
(32 − 5 · 31 + 6)3n−2 = 0 or (9− 5 · 3 + 6)3n−2 = 0
and clearly the last one says 0 · 3n−2 = 0, which is always true. Similarcalculations with an = 2n lead to
(22 − 5 · 2 + 6)2n−2 = 0
which is also true.
With these solutions we can build new solutions: an = 2(3n) andan = −(2n) and an = 2(3n)− (2n). Note that if we add initial conditionsa0 = 1 and a1 = 4, then only the last of these satisfies them both.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 11 / 18
![Page 41: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/41.jpg)
For the first, we simply put
an = 3n, an−1 = 3n−1, an−2 = 3n−2
into the recurrence relation to get
3n − 5 · 3n−1 + 6 · 3n−2 = 0
We can rearrange the left side:
(32 − 5 · 31 + 6)3n−2 = 0 or (9− 5 · 3 + 6)3n−2 = 0
and clearly the last one says 0 · 3n−2 = 0, which is always true. Similarcalculations with an = 2n lead to
(22 − 5 · 2 + 6)2n−2 = 0
which is also true.
With these solutions we can build new solutions: an = 2(3n) andan = −(2n) and an = 2(3n)− (2n).
Note that if we add initial conditionsa0 = 1 and a1 = 4, then only the last of these satisfies them both.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 11 / 18
![Page 42: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/42.jpg)
For the first, we simply put
an = 3n, an−1 = 3n−1, an−2 = 3n−2
into the recurrence relation to get
3n − 5 · 3n−1 + 6 · 3n−2 = 0
We can rearrange the left side:
(32 − 5 · 31 + 6)3n−2 = 0 or (9− 5 · 3 + 6)3n−2 = 0
and clearly the last one says 0 · 3n−2 = 0, which is always true. Similarcalculations with an = 2n lead to
(22 − 5 · 2 + 6)2n−2 = 0
which is also true.
With these solutions we can build new solutions: an = 2(3n) andan = −(2n) and an = 2(3n)− (2n). Note that if we add initial conditionsa0 = 1 and a1 = 4, then only the last of these satisfies them both.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 11 / 18
![Page 43: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/43.jpg)
A further part of the theory of recurrence relations is the following
Theorem
For any homogeneous linear recurrence relation of order k there exist abasic set of solutions an = f1(n), an = f2(n),. . . ,an = fk(n)
such that everysolution has the form
an = C1f1(n) + C2f2(n) + · · ·+ Ck fk(n)
for some constants C1, C2,. . .Ck .
For our example an − 5an−1 + 6an−2 the basic solutions are an = 3n andan = 2n. Thus, all solutions look like an = C13n + C22n. This is called ageneral solution: It satisfies the recurrence relation for any choice of C1
and C2, but satisfies any given initial condition for only one choice.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 12 / 18
![Page 44: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/44.jpg)
A further part of the theory of recurrence relations is the following
Theorem
For any homogeneous linear recurrence relation of order k there exist abasic set of solutions an = f1(n), an = f2(n),. . . ,an = fk(n) such that everysolution has the form
an = C1f1(n) + C2f2(n) + · · ·+ Ck fk(n)
for some constants C1, C2,. . .Ck .
For our example an − 5an−1 + 6an−2 the basic solutions are an = 3n andan = 2n. Thus, all solutions look like an = C13n + C22n. This is called ageneral solution: It satisfies the recurrence relation for any choice of C1
and C2, but satisfies any given initial condition for only one choice.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 12 / 18
![Page 45: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/45.jpg)
A further part of the theory of recurrence relations is the following
Theorem
For any homogeneous linear recurrence relation of order k there exist abasic set of solutions an = f1(n), an = f2(n),. . . ,an = fk(n) such that everysolution has the form
an = C1f1(n) + C2f2(n) + · · ·+ Ck fk(n)
for some constants C1, C2,. . .Ck .
For our example an − 5an−1 + 6an−2 the basic solutions are an = 3n andan = 2n.
Thus, all solutions look like an = C13n + C22n. This is called ageneral solution: It satisfies the recurrence relation for any choice of C1
and C2, but satisfies any given initial condition for only one choice.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 12 / 18
![Page 46: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/46.jpg)
A further part of the theory of recurrence relations is the following
Theorem
For any homogeneous linear recurrence relation of order k there exist abasic set of solutions an = f1(n), an = f2(n),. . . ,an = fk(n) such that everysolution has the form
an = C1f1(n) + C2f2(n) + · · ·+ Ck fk(n)
for some constants C1, C2,. . .Ck .
For our example an − 5an−1 + 6an−2 the basic solutions are an = 3n andan = 2n. Thus, all solutions look like an = C13n + C22n.
This is called ageneral solution: It satisfies the recurrence relation for any choice of C1
and C2, but satisfies any given initial condition for only one choice.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 12 / 18
![Page 47: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/47.jpg)
A further part of the theory of recurrence relations is the following
Theorem
For any homogeneous linear recurrence relation of order k there exist abasic set of solutions an = f1(n), an = f2(n),. . . ,an = fk(n) such that everysolution has the form
an = C1f1(n) + C2f2(n) + · · ·+ Ck fk(n)
for some constants C1, C2,. . .Ck .
For our example an − 5an−1 + 6an−2 the basic solutions are an = 3n andan = 2n. Thus, all solutions look like an = C13n + C22n. This is called ageneral solution: It satisfies the recurrence relation for any choice of C1
and C2, but satisfies any given initial condition for only one choice.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 12 / 18
![Page 48: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/48.jpg)
If the general solution is an = C13n + C22n and the initial conditions area0 = 1 and a1 = 4 then putting n = 0 and n = 1 into the solution gives us
a0 = 1 = C1 + C2
a1 = 4 = 3C1 + 2C2
Solving this for C1 and C2 gives C1 = 2, C2 = −1.
This gives us the general scheme for solving homogeneous linearrecurrence relations:
Find the basic set of solutions.
Build the general solution from them.
Solve for the constants using the initial conditions.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 13 / 18
![Page 49: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/49.jpg)
If the general solution is an = C13n + C22n and the initial conditions area0 = 1 and a1 = 4 then putting n = 0 and n = 1 into the solution gives us
a0 = 1 = C1 + C2
a1 = 4 = 3C1 + 2C2
Solving this for C1 and C2 gives C1 = 2, C2 = −1.
This gives us the general scheme for solving homogeneous linearrecurrence relations:
Find the basic set of solutions.
Build the general solution from them.
Solve for the constants using the initial conditions.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 13 / 18
![Page 50: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/50.jpg)
If the general solution is an = C13n + C22n and the initial conditions area0 = 1 and a1 = 4 then putting n = 0 and n = 1 into the solution gives us
a0 = 1 = C1 + C2
a1 = 4 = 3C1 + 2C2
Solving this for C1 and C2 gives C1 = 2, C2 = −1.
This gives us the general scheme for solving homogeneous linearrecurrence relations:
Find the basic set of solutions.
Build the general solution from them.
Solve for the constants using the initial conditions.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 13 / 18
![Page 51: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/51.jpg)
If the general solution is an = C13n + C22n and the initial conditions area0 = 1 and a1 = 4 then putting n = 0 and n = 1 into the solution gives us
a0 = 1 = C1 + C2
a1 = 4 = 3C1 + 2C2
Solving this for C1 and C2 gives C1 = 2, C2 = −1.
This gives us the general scheme for solving homogeneous linearrecurrence relations:
Find the basic set of solutions.
Build the general solution from them.
Solve for the constants using the initial conditions.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 13 / 18
![Page 52: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/52.jpg)
If the general solution is an = C13n + C22n and the initial conditions area0 = 1 and a1 = 4 then putting n = 0 and n = 1 into the solution gives us
a0 = 1 = C1 + C2
a1 = 4 = 3C1 + 2C2
Solving this for C1 and C2 gives C1 = 2, C2 = −1.
This gives us the general scheme for solving homogeneous linearrecurrence relations:
Find the basic set of solutions.
Build the general solution from them.
Solve for the constants using the initial conditions.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 13 / 18
![Page 53: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/53.jpg)
Finding the basic solutions: We will do this completely only for secondorder equations with constant coefficients.
This means the recurrencerelation looks like an + ban−1 + can−2 = 0, with constants b and c .
For a first order equation: an − ban−1 = 0, the basic solution is an = bn
and the general solution is C1bn. The constant is determined by the initial
condition.
For higher order equations one might speculate that one or more of thebasic solutions has a similar structure. That is, we might suppose that onesolution is a geometric series an = rn for some r .
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 14 / 18
![Page 54: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/54.jpg)
Finding the basic solutions: We will do this completely only for secondorder equations with constant coefficients. This means the recurrencerelation looks like an + ban−1 + can−2 = 0, with constants b and c .
For a first order equation: an − ban−1 = 0, the basic solution is an = bn
and the general solution is C1bn. The constant is determined by the initial
condition.
For higher order equations one might speculate that one or more of thebasic solutions has a similar structure. That is, we might suppose that onesolution is a geometric series an = rn for some r .
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 14 / 18
![Page 55: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/55.jpg)
Finding the basic solutions: We will do this completely only for secondorder equations with constant coefficients. This means the recurrencerelation looks like an + ban−1 + can−2 = 0, with constants b and c .
For a first order equation: an − ban−1 = 0, the basic solution is an = bn
and the general solution is C1bn.
The constant is determined by the initialcondition.
For higher order equations one might speculate that one or more of thebasic solutions has a similar structure. That is, we might suppose that onesolution is a geometric series an = rn for some r .
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 14 / 18
![Page 56: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/56.jpg)
Finding the basic solutions: We will do this completely only for secondorder equations with constant coefficients. This means the recurrencerelation looks like an + ban−1 + can−2 = 0, with constants b and c .
For a first order equation: an − ban−1 = 0, the basic solution is an = bn
and the general solution is C1bn. The constant is determined by the initial
condition.
For higher order equations one might speculate that one or more of thebasic solutions has a similar structure. That is, we might suppose that onesolution is a geometric series an = rn for some r .
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 14 / 18
![Page 57: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/57.jpg)
Finding the basic solutions: We will do this completely only for secondorder equations with constant coefficients. This means the recurrencerelation looks like an + ban−1 + can−2 = 0, with constants b and c .
For a first order equation: an − ban−1 = 0, the basic solution is an = bn
and the general solution is C1bn. The constant is determined by the initial
condition.
For higher order equations one might speculate that one or more of thebasic solutions has a similar structure.
That is, we might suppose that onesolution is a geometric series an = rn for some r .
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 14 / 18
![Page 58: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/58.jpg)
Finding the basic solutions: We will do this completely only for secondorder equations with constant coefficients. This means the recurrencerelation looks like an + ban−1 + can−2 = 0, with constants b and c .
For a first order equation: an − ban−1 = 0, the basic solution is an = bn
and the general solution is C1bn. The constant is determined by the initial
condition.
For higher order equations one might speculate that one or more of thebasic solutions has a similar structure. That is, we might suppose that onesolution is a geometric series an = rn for some r .
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 14 / 18
![Page 59: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/59.jpg)
That can be checked: put an = rn in the equation (as usual alsoan−1 = rn−1 and an−2 = rn−2).
This gives
rn + brn−1 + crn−2 = 0 or (r2 + br + c)rn−2 = 0
Now if r = 0 the solution an = 0 gives us nothing to work with, so weassume r 6= 0. Then we can divide the last equation by rn−2 to get thecharactristic equation
r2 + br + c = 0
If an = rn is to be a solution then r must be a root of this equation:
r =−b ±
√b2 − 4c
2(1)
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 15 / 18
![Page 60: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/60.jpg)
That can be checked: put an = rn in the equation (as usual alsoan−1 = rn−1 and an−2 = rn−2). This gives
rn + brn−1 + crn−2 = 0 or (r2 + br + c)rn−2 = 0
Now if r = 0 the solution an = 0 gives us nothing to work with, so weassume r 6= 0. Then we can divide the last equation by rn−2 to get thecharactristic equation
r2 + br + c = 0
If an = rn is to be a solution then r must be a root of this equation:
r =−b ±
√b2 − 4c
2(1)
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 15 / 18
![Page 61: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/61.jpg)
That can be checked: put an = rn in the equation (as usual alsoan−1 = rn−1 and an−2 = rn−2). This gives
rn + brn−1 + crn−2 = 0 or (r2 + br + c)rn−2 = 0
Now if r = 0 the solution an = 0 gives us nothing to work with, so weassume r 6= 0.
Then we can divide the last equation by rn−2 to get thecharactristic equation
r2 + br + c = 0
If an = rn is to be a solution then r must be a root of this equation:
r =−b ±
√b2 − 4c
2(1)
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 15 / 18
![Page 62: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/62.jpg)
That can be checked: put an = rn in the equation (as usual alsoan−1 = rn−1 and an−2 = rn−2). This gives
rn + brn−1 + crn−2 = 0 or (r2 + br + c)rn−2 = 0
Now if r = 0 the solution an = 0 gives us nothing to work with, so weassume r 6= 0. Then we can divide the last equation by rn−2 to get thecharactristic equation
r2 + br + c = 0
If an = rn is to be a solution then r must be a root of this equation:
r =−b ±
√b2 − 4c
2(1)
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 15 / 18
![Page 63: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/63.jpg)
That can be checked: put an = rn in the equation (as usual alsoan−1 = rn−1 and an−2 = rn−2). This gives
rn + brn−1 + crn−2 = 0 or (r2 + br + c)rn−2 = 0
Now if r = 0 the solution an = 0 gives us nothing to work with, so weassume r 6= 0. Then we can divide the last equation by rn−2 to get thecharactristic equation
r2 + br + c = 0
If an = rn is to be a solution then r must be a root of this equation:
r =−b ±
√b2 − 4c
2(1)
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 15 / 18
![Page 64: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/64.jpg)
Here’s an example:an − an−1 − 6an−1 = 0.
The above process gives us the characteristic equation
r2 − r − 6 = 0.
Which has roots r = 3 and r = −2. That means both an = 3n andan = (−2)n are solutions and the general solution is an = C13n + C2(−2)n.
[Note that (−2)n is not −2n. The first sequence is 1,−2, 4,−8, 16, . . .while the second is −1,−2,−4,−8,−16, . . . .]
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 16 / 18
![Page 65: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/65.jpg)
Here’s an example:an − an−1 − 6an−1 = 0.
The above process gives us the characteristic equation
r2 − r − 6 = 0.
Which has roots r = 3 and r = −2.
That means both an = 3n andan = (−2)n are solutions and the general solution is an = C13n + C2(−2)n.
[Note that (−2)n is not −2n. The first sequence is 1,−2, 4,−8, 16, . . .while the second is −1,−2,−4,−8,−16, . . . .]
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 16 / 18
![Page 66: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/66.jpg)
Here’s an example:an − an−1 − 6an−1 = 0.
The above process gives us the characteristic equation
r2 − r − 6 = 0.
Which has roots r = 3 and r = −2. That means both an = 3n andan = (−2)n are solutions and the general solution is an = C13n + C2(−2)n.
[Note that (−2)n is not −2n. The first sequence is 1,−2, 4,−8, 16, . . .while the second is −1,−2,−4,−8,−16, . . . .]
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 16 / 18
![Page 67: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/67.jpg)
Here’s an example:an − an−1 − 6an−1 = 0.
The above process gives us the characteristic equation
r2 − r − 6 = 0.
Which has roots r = 3 and r = −2. That means both an = 3n andan = (−2)n are solutions and the general solution is an = C13n + C2(−2)n.
[Note that (−2)n is not −2n. The first sequence is 1,−2, 4,−8, 16, . . .while the second is −1,−2,−4,−8,−16, . . . .]
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 16 / 18
![Page 68: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/68.jpg)
Continuing with the same example, let’s give it initial conditions:
an − an−1 − 6an−2 = 0, n ≥ 2
a0 = 0, a1 = 5
From the general solution an = C13n + C2(−2)n and the initial conditionswe get equations for C1 and C2:
C1 +C2 = 0
3C1−2C2 = 5
which gives C1 = 1 and C2 = −1 so that an = 3n − (−2)n is the solutionto the initial value problem.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 17 / 18
![Page 69: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/69.jpg)
Continuing with the same example, let’s give it initial conditions:
an − an−1 − 6an−2 = 0, n ≥ 2
a0 = 0, a1 = 5
From the general solution an = C13n + C2(−2)n and the initial conditionswe get equations for C1 and C2:
C1 +C2 = 0
3C1−2C2 = 5
which gives C1 = 1 and C2 = −1 so that an = 3n − (−2)n is the solutionto the initial value problem.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 17 / 18
![Page 70: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/70.jpg)
Continuing with the same example, let’s give it initial conditions:
an − an−1 − 6an−2 = 0, n ≥ 2
a0 = 0, a1 = 5
From the general solution an = C13n + C2(−2)n and the initial conditionswe get equations for C1 and C2:
C1 +C2 = 0
3C1−2C2 = 5
which gives C1 = 1 and C2 = −1 so that an = 3n − (−2)n is the solutionto the initial value problem.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 17 / 18
![Page 71: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/71.jpg)
A second example:
an − 4an−2 = 0
a0 = 1, a1 = 1
Here we get r2 − 4 = 0 and roots 2 and −2. The general solution isan = C12n + C2(−2)n. From
C1 +C2 = 1
2C1−2C2 = 1
we get C1 = 3/4 and C2 = 1/4 so that an = (3/4)2n + (1/4)(−2)n.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 18 / 18
![Page 72: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/72.jpg)
A second example:
an − 4an−2 = 0
a0 = 1, a1 = 1
Here we get r2 − 4 = 0 and roots 2 and −2.
The general solution isan = C12n + C2(−2)n. From
C1 +C2 = 1
2C1−2C2 = 1
we get C1 = 3/4 and C2 = 1/4 so that an = (3/4)2n + (1/4)(−2)n.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 18 / 18
![Page 73: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/73.jpg)
A second example:
an − 4an−2 = 0
a0 = 1, a1 = 1
Here we get r2 − 4 = 0 and roots 2 and −2. The general solution isan = C12n + C2(−2)n.
From
C1 +C2 = 1
2C1−2C2 = 1
we get C1 = 3/4 and C2 = 1/4 so that an = (3/4)2n + (1/4)(−2)n.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 18 / 18
![Page 74: Recurrence Relations...Daniel H. Luecking Recurrence Relations Feb. 17, 20213/18 The rules are as follows: There are three poles, two of them empty. The disks all have a hole in the](https://reader035.vdocuments.us/reader035/viewer/2022071418/61169920ab1ebb7b914fea16/html5/thumbnails/74.jpg)
A second example:
an − 4an−2 = 0
a0 = 1, a1 = 1
Here we get r2 − 4 = 0 and roots 2 and −2. The general solution isan = C12n + C2(−2)n. From
C1 +C2 = 1
2C1−2C2 = 1
we get C1 = 3/4 and C2 = 1/4 so that an = (3/4)2n + (1/4)(−2)n.
Daniel H. Luecking Recurrence Relations Feb. 17, 2021 18 / 18