CMSC 142: Design and Analysis of Algorithms
Course Description
The module introduces formal techniques to support the design and analysis of
algorithms, focusing on both the underlying mathematical theory and practical
considerations of efficiency. The aim of this module is to learn how to develop efficient
algorithms for simple computational tasks and reasoning about the correctness of
them. Through the complexity measures, different range of behaviors of algorithms
and the notion of tractable and intractable problems will be understood.
Course Learning Outcomes
After completion of the course, the student should be able to:
- Learn good principles of algorithm design.
- Learn how to analyze algorithm and estimate their worst-case and average-case behavior (in easy cases)
- Become familiar with fundamental data structures and with the way these data structures can best be
implemented become accustomed to the description of algorithms in both functional and procedural styles.
- Learn how to apply theoretical knowledge in practice.
- Synthesize an efficient algorithm in common engineering design situations.
Course Outline
UNIT 1. Introduction to Algorithms
- The role of algorithms in computing
- Defining algorithms
- Algorithms as a Technology
- Design and Analysis of Algorithms
- Growth of functions (asymptotic notation, standard notation, and common functions)
UNIT 2. Sorting and Searching
- Bogosort
- Stoogesort
- Insertion sort
- Selection sort
- Bubble sort
- Shell sort
- Merge sort
- Heapsort
- Asymptotic Analysis of Sorting Algorithms
- Running Time and Memory
- Sequential Search
- Binary Search
- Hashing
UNIT 3. Divide and Conquer Algorithms
- Divide and Conquer Algorithms (ex. Counting inversions, finding the median)
- Recurrence relations
UNIT 4. Dynamic Programming
- Elements of Dynamic Programming
- Knapsack Algorithms
- Longest Common Subsequence
- Longest Increasing Subsequence
- Minimum Edit Distance
UNIT 5. Greedy Algorithms
- Introduction to Greedy Algorithms
- Activity Selection
- Fractional Knapsack
- Set Cover
- While Loop
- Huffman Encoding
UNIT 6. Graphs
- Introduction to Graphs
- Graph Representations
- Breadth fast search and depth first search algorithms
UNIT 7. Minimum Spanning Tree
- Prim’s Algorithm
- Kruskal’s Algorithm
UNIT 8. Single source shortest path algorithms
- Single-source path in DAGs
- Dijkstra's algorithm
- Bellman-Ford Algorithm
UNIT 9. All-Pairs Shortest Paths
- Floyd-Warshall algorithm
- Johnson's Algorithm
UNIT 10. Maximum Flow
- Flow Networks
- Ford-Fulkerson Method
- Maximum bipartite matching
UNIT 11. NP-Completeness
- Polynomial Time
- Polynomial Time Verification
- NP-Completeness and Readability
UNIT 12. Approximation problems
- The vertex-cover problem
- The traveling salesman problem
- Set-Covering Problem
- Randomization and linear programming
- The subset-sum problem