COMP3001/3901 Algorithms Lecture 1 Introduction COMP3001/3901 Algorithms • Two lectures – Tuesday (10 -11 am in Carslaw Theatre 157) – Wednesday (10 -11 am in Chemistry Theatre 1) • One tutorial • http://www.it.usyd.edu.au/~shhong/comp3001.html • Dr. Seokhee Hong ([email protected], Madsen G86, 9351-6092) • Consultation time: Wednesday 3-4pm. Textbook & References Introduction to Algorithms, second edition by Cormen, Leiserson, Rivest & Stein, MIT Press, 2001 Solving a Computational Problem Step 1. Problem definition & specification – specify input, output and constraints Step 2. Algorithm design & analysis • The Design and Analysis of Computer Algorithms, by Aho, Hopcroft and Ullman • Algorithmics: Theory & Practice, by Brassard & Bratley • Fundamentals of data structures in C(C++), by Horowitz, Sahni and Anderson-Freed – devise a correct & efficient algorithm This course Step 3. Implementation (coding) Step 4. Testing Step 5. Verification • Algorithms, by Sedgewick Aim • Primary aim: Develop thinking ability – problem solving skills (algorithm design and application) – formal thinking (proof techniques & analysis) • Secondary aim: have fun with algorithms To achieve the aim, we will… • Examine interesting problems • Devise algorithms for solving them • Prove their correctness • Analyze their runtime performance • Study advanced data structures & core algorithms • Learn problem-solving techniques • Applications in real-world problems 1 Specific Goals • Be familiar with a collection of core algorithms • Be fluent in algorithm design paradigms: divide & conquer, greedy algorithms, dynamic programming. • Be able to analyze the correctness and runtime performance of a given algorithm • Be familiar with the inherent complexity (lower bounds & intractability) of some problems • Be familiar with advanced data structures • Be able to apply techniques in practical problems Assessment • Assignments (20%): 2 assignments (10% each) • Tutorial (10%) • Written exam (70%): closed book • Assignments – Week 6: September 4 – Week 12: October 23 – Submit to your tutor. – Exact deadline: tutorial? Or same deadline? Assignments • Late policy: within one week (-50%) – No submission allowed after one week. • Plagiarism is not allowed. – For details, see USyd code of practice on plagiarism. – http://www.usyd.edu.au/su/planning/policy/exams/14_0pla.html • Be neat, clear, precise and formal – you will be graded on correctness, time complexity, simplicity, elegance & clarity. Assumed Knowledge • We assume that you know the basic material in the following chapters: chapter 2, 3, 4, 6, 7, 10, 11, 12 (from DDS, 2001) – – – – – – – – – Basic notation: asymptotic notation Recursion and recurrence: analyze time complexity Sorting: heap sort, quick sort Elementary data structures: stack, queue, linked list Hash tables Priority queues: heaps Search trees: BST Trees & tree traversal Graphs & graph traversal Planned Course Outline Algorithm Analysis • Introduction (week1) • Divide and Conquer (week 1,2) • Dynamic Programming (week 3,4) • Greedy Method (week 5,6) • Graph Algorithm (week 7,8) • Asymptotic Notation • Recurrence Relations • Proof Techniques • Inherent Complexity • GOAL: • Advanced Data Structure (week 9,10) – Know how to write a problem specification. • Advanced Topics (week 11,12) – Know how to measure the efficiency of an algorithm. • Review (week 13) – Know the difference between upper and lower bounds for an algorithm. – Be able to prove the correctness of an algorithm. • Note: topics are subject to change. 2 Algorithm Design Paradigms • Divide and Conquer Divide and Conquer • Merge sort • Closest pair • Selection • Dynamic Programming • Greedy Methods Greedy Algorithms • GOAL: – Know when the divide-and-conquer paradigm is an appropriate one, and the general structure of such algorithms. – Be able to characterize their complexity using techniques for solving recurrences. – Memorize the common case solutions for recurrence relations. Dynamic Programming • Huffman Codes • Minimum Spanning Trees • Shortest Paths • Longest common subsequences • Matrix chain multiplication • Optimal binary search tree • GOAL: – Know when to use greedy algorithms and their essential characteristics. – Be able to prove the correctness of a greedy algorithm in solving an optimization problem. – Understand where minimum spanning trees and shortest path computations arise in practice. • GOAL – Know what problem characteristics make it appropriate to use dynamic programming and how it differs from divideand-conquer. – Be able to move systematically from one to the other. Graph Algorithms • Basic Graph Algorithms: biconnected components • Minimum Spanning Trees • Shortest Paths • GOAL – Know how graphs arise, their definition and implications. – Be able to use the adjacency matrix representation of a graph and the edge list representation appropriately. – Understand and be able to use the techniques as seen in the basic graph algorithms. Advanced Data Structures • Heap structures: Binomial heaps, Fibonacci heaps • Search trees: 2-3 trees, Red-Black trees • Quad tree • GOAL – Know the fundamental ideas behind maintaining balance in insertions/deletion. – Be able to use these ideas in other balanced tree data structures. – Understand what they can represent and why they are useful. – Know the special features of the data structure listed above. 3 Advanced Topics How to Succeed in this Course • Case Studies of Real-World Problems: Geometric Algorithms – Computational geometry – Graph drawing • Do suggested pre-reading before class. • NP-completeness • Approximation algorithm if time permits. • Review after each class. • Attend each class. • Think in class. • Do pre-work before tutorial. • Attend each tutorial. • GOAL: See how core algorithms can be put to use in real-world applications and geometric problems. Tutorial • Each student must attend one tutorial per week, as allocated by the University timetable system. • Tutorials commence in week 2 (no tutorial in week 1). • Attendance at your assigned tutorials is very important. • You should have read and answered the "pre-work" before you come to the tutorial. • All tutorial activity is done in groups of up to 3 people. • It is important to be able to explain your ideas to others and to contribute effectively to a collaborative solution. • The tutor will discuss the solution and comment on issues raised by the exercise. • Start early on assignments. • Be formal and precise. Basic Courtesy • Write your assignments neatly & formally. • Please do not read newspapers and other materials in class. • When coming to the class late or leaving early, please take an aisle seat quietly. • Remain quiet, except asking questions or answering questions posed by instructors. – no whispers or private conversation. THANK YOU!!! • You must submit 1 page result to your tutor (10%). COMP3901 Advanced Course • This Advanced unit covers all the material of COMP3001, plus extra topics. • The two units share the same lectures, but have different tutorials and assessment. • There will be some lectures on advanced topics in the tutorials. Communications • Pls check the course website regularly, at least once per week. • Lecture notes will be available either on the website or at the University Copy Centre (this will be posted on the web). – Note that the lecture notes will not contain everything. – You need to attend class to add your own notes. – Some topics are subject to change. • Tutorials will be available on the web. – pls download & print it and Think! • To contact me, send an email or pls use consultation hour. • Suggested Reading for Week 1: chapter 2, 3, 4. 4
© Copyright 2026 Paperzz