COS 350 - Data Structures and Algorithms
Homework Assignments
Larry Latour
Spring, 2009
Homework
- Homework Packet #1:
- Handout ppgs. 308-311 - 2,6,12,18,26,48,50
- Handout ppgs. 321-322 - 8,11,18,20,24
- Homework Packet #2:
- Counting primitive operations: R1.10-R1.14
- Analyzing recursive algorithms: C1.5, C1.6
- Average Case Analysis: Handout questions 1-4
- Asymptotic notation: R1.5-R1.8, C1.7, C1.8, C1.10, C1.14, C1.15, C1.21, C1.22, C1.25, C1.27
- Amortization: C1.2, C1.3, C1.32
- Experimentation: R1.29, R1.30
- Homework Packet #3
- Greedy algorithms: C5.3 (Describe the algorithm but don't implement it)
- Divide and Conquer Algorithms:
- R5.4 - Analyze a. through e., and show all work
- Implement and test an algorithm power(x,n) that runs in O(log n) time. Verify the big-O of this algorithm through testing.
- Consider question R5.6. Implement Strassen's algorithm for nXn matrices, n<=16. Verify the big-O of Strassen's algorithm (in Theorem 5.13) through testing.
- Dynamic Programming:
- Implement the algorithm in R5.10. Verify the big-O of this algorithm through testing.
- Homework Packet #4
- R2.19-R2.24, C2.12, C2.32, C2.35, C3.18, C3.19
- Homework Packet #5
- P6.1 - Implement as a class in Java/C++/other OO language and demonstrate that the class has been properly tested.
- R6.7, C6.9
- C6.12, C6.13 - Implement and test both of these using the graph ADT defined in project P6.1
- C6.18 - I would clarify this question by changing the sentence to - "A maximal independent set M is an independent set such that there is NO additional vertex that can be added to M such that it would remain an independent set."
- C6.19 - find the algorithm and justify the big-O time. Remember, when analyzing big-O time you can disregard the constant.
- Homework Packet #6
- R6.9,R6.10
- R7.1,R7.2,R7.3,R7.6,R7.7,R7.8
- C7.3
Last updated: 1/04/09