This preview shows pages 1–11. Sign up to view the full content.
This preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
Unformatted text preview: CS 473: Algorithms Chandra Chekuri chekuri@cs.illinois.edu 3228 Siebel Center University of Illinois, UrbanaChampaign Fall 2009 Chekuri CS473ug Merge Sort Quick Sort Part I Divide and Conquer Chekuri CS473ug Merge Sort Quick Sort Divide and Conquer Paradigm Divide and Conquer is a common and useful type of recursion Approach Chekuri CS473ug Merge Sort Quick Sort Divide and Conquer Paradigm Divide and Conquer is a common and useful type of recursion Approach Break problem instance into smaller instances  divide step Chekuri CS473ug Merge Sort Quick Sort Divide and Conquer Paradigm Divide and Conquer is a common and useful type of recursion Approach Break problem instance into smaller instances  divide step Recursively solve problem on smaller instances Chekuri CS473ug Merge Sort Quick Sort Divide and Conquer Paradigm Divide and Conquer is a common and useful type of recursion Approach Break problem instance into smaller instances  divide step Recursively solve problem on smaller instances Combine solutions to smaller isntances to obtain a solution to the original instance  conquer step Chekuri CS473ug Merge Sort Quick Sort Divide and Conquer Paradigm Divide and Conquer is a common and useful type of recursion Approach Break problem instance into smaller instances  divide step Recursively solve problem on smaller instances Combine solutions to smaller isntances to obtain a solution to the original instance  conquer step Chekuri CS473ug Merge Sort Quick Sort Divide and Conquer Paradigm Divide and Conquer is a common and useful type of recursion Approach Break problem instance into smaller instances  divide step Recursively solve problem on smaller instances Combine solutions to smaller isntances to obtain a solution to the original instance  conquer step Question: Why is this not plain recursion? Chekuri CS473ug Merge Sort Quick Sort Divide and Conquer Paradigm Divide and Conquer is a common and useful type of recursion Approach Break problem instance into smaller instances  divide step Recursively solve problem on smaller instances Combine solutions to smaller isntances to obtain a solution to the original instance  conquer step Question: Why is this not plain recursion? In divide and conquer, each smaller instance is typically at least a constant factor smaller than the original instance which leads to efficienct running times Chekuri CS473ug Merge Sort Quick Sort Divide and Conquer Paradigm Divide and Conquer is a common and useful type of recursion Approach Break problem instance into smaller instances  divide step Recursively solve problem on smaller instances Combine solutions to smaller isntances to obtain a solution to the original instance  conquer step Question: Why is this not plain recursion?...
View Full
Document
 Fall '08
 Chekuri,C
 Algorithms, Quick Sort

Click to edit the document details