Docsity

Homework I for Math Algorithm and Systems Analysis | CSE 21, Assignments of Computer Science

Toggle sidebar
bg1
CSE21 Homework 1
Due: January 18, 2005
This is an individual homework assignment. Please answer all questions to the best of your
ability, showing all work.
For uniform grading, each question should be graded by only one reader. So please
make sure that each problem is on a separate piece of paper, and that each piece of
paper has your name and student ID number on it.
1. Fn(n= 0,1,2, . . .) are the Fibonacci numbers. Prove by mathematical induction: Fn<(7
4)n
for all n≥1.
2. Find an explicit formula for the sequence a0,a1,a2, .. . , that satisfies
an= 4an−1+ 8an−2, for all integers n≥2
with initial conditions a0= 2 and a1= 2.
3. Consider two dimensional space. If we draw a line it will divide it into two regions. Two lines
would split the space into four regions. Three lines can divide it (if the third is not parallel to
either of the previous two lines) into seven regions. Let P n be the maximum number of regions
into which nlines could divide a plane, where nis a positive integer.
(a) Derive a recurrence relation for Pkin terms of Pk−1for all integers k≥2.
(b) Use the iteration method to guess and prove an explicit formula for Pn.
4. Let A=µ1 1
1 0
Compute Anfor n= 2,3,4,5. Give a general (explicit) formula for the entries in the matrix
and prove your answer correct.
5. A circular disk is cut into ndistinct sectors, each shaped like a piece of pie and all meeting at
the center point of the disk. Each sector is to be painted red, green, yellow or blue in such a
way that no two adjacent sectors are painted the same color. Let Snbe the number of ways to
paint the disk.
(a) Find a recurrence relation for Skin terms of Sk−1and Sk−2for each integer k≥4.
(b) Find an explicit formula for Snfor n≥2.
6. Let anbe the number of the n-bit binary numbers that satisfy the following condition: None
of the binary numbers contains 11 in its binary representation. E.g. The 4-bit binary number
0101 satisfies the condition, while 0110 does not.
Find a recurrence relation for anand solve it.
1

Partial preview of the text

Download Homework I for Math Algorithm and Systems Analysis | CSE 21 and more Assignments Computer Science in PDF only on Docsity!

CSE21 Homework 1

Due: January 18, 2005

This is an individual homework assignment. Please answer all questions to the best of your ability, showing all work.

For uniform grading, each question should be graded by only one reader. So please make sure that each problem is on a separate piece of paper, and that each piece of paper has your name and student ID number on it.

  1. Fn (n = 0, 1 , 2 ,.. .) are the Fibonacci numbers. Prove by mathematical induction: Fn < ( 74 )n for all n ≥ 1.
  2. Find an explicit formula for the sequence a 0 , a 1 , a 2 ,... , that satisfies

an = 4an− 1 + 8an− 2 , for all integers n ≥ 2

with initial conditions a 0 = 2 and a 1 = 2.

  1. Consider two dimensional space. If we draw a line it will divide it into two regions. Two lines would split the space into four regions. Three lines can divide it (if the third is not parallel to either of the previous two lines) into seven regions. Let P n be the maximum number of regions into which n lines could divide a plane, where n is a positive integer.

(a) Derive a recurrence relation for Pk in terms of Pk− 1 for all integers k ≥ 2. (b) Use the iteration method to guess and prove an explicit formula for Pn.

  1. Let A =

Compute An^ for n = 2, 3 , 4 , 5. Give a general (explicit) formula for the entries in the matrix and prove your answer correct.

  1. A circular disk is cut into n distinct sectors, each shaped like a piece of pie and all meeting at the center point of the disk. Each sector is to be painted red, green, yellow or blue in such a way that no two adjacent sectors are painted the same color. Let Sn be the number of ways to paint the disk.

(a) Find a recurrence relation for Sk in terms of Sk− 1 and Sk− 2 for each integer k ≥ 4. (b) Find an explicit formula for Sn for n ≥ 2.

  1. Let an be the number of the n-bit binary numbers that satisfy the following condition: None of the binary numbers contains 11 in its binary representation. E.g. The 4-bit binary number 0101 satisfies the condition, while 0110 does not. Find a recurrence relation for an and solve it.