Course Review 15-211 Fundamental Structures of Computer Science Margaret Reid-Miller 28 April 2005.

Slides:



Advertisements
Similar presentations
CS16: Data Structures & Algorithms | Spring 2014 Midterm Review 3/16/
Advertisements

CSCE 411H Design and Analysis of Algorithms Set 8: Greedy Algorithms Prof. Evdokia Nikolova* Spring 2013 CSCE 411H, Spring 2013: Set 8 1 * Slides adapted.
22C:19 Discrete Structures Trees Spring 2014 Sukumar Ghosh.
Lecture 12: Revision Lecture Dr John Levine Algorithms and Complexity March 27th 2006.
S. J. Shyu Chap. 1 Introduction 1 The Design and Analysis of Algorithms Chapter 1 Introduction S. J. Shyu.
1 Divide-and-Conquer The most-well known algorithm design strategy: 1. Divide instance of problem into two or more smaller instances 2. Solve smaller instances.
Lecture 17 Review. What I’ve taught ≠ What you’ve learnt.
Review. What to know You are responsible for all material covered in lecture, the readings, or the programming assignments There will also be some questions.
CS333 Algorithms
Jan Welcome to the Course of Advanced Algorithm Design (ACS-7101/3)
CSCE 210 Data Structures and Algorithms
Midterm 2 Overview Fawzi Emad Chau-Wen Tseng Department of Computer Science University of Maryland, College Park.
DAST, Spring © L. Joskowicz 1 Data Structures – LECTURE 1 Introduction Motivation: algorithms and abstract data types Easy problems, hard problems.
Chapter 4: Divide and Conquer The Design and Analysis of Algorithms.
Chapter 9: Greedy Algorithms The Design and Analysis of Algorithms.
CSIS-385: Analysis of Algorithms Dr. Eric Breimer.
Data Structures, Spring 2004 © L. Joskowicz 1 Data Structures – LECTURE 3 Recurrence equations Formulating recurrence equations Solving recurrence equations.
CSIS-385: Analysis of Algorithms Dr. Eric Breimer.
Greedy Algorithms Reading Material: Chapter 8 (Except Section 8.5)
Course Review COMP171 Spring Hashing / Slide 2 Elementary Data Structures * Linked lists n Types: singular, doubly, circular n Operations: insert,
CS 206 Introduction to Computer Science II 04 / 29 / 2009 Instructor: Michael Eckmann.
CS 206 Introduction to Computer Science II 12 / 10 / 2008 Instructor: Michael Eckmann.
UMass Lowell Computer Science Analysis of Algorithms Prof. Karen Daniels Fall, 2000 Final Review Wed. 12/13.
Greedy Algorithms Like dynamic programming algorithms, greedy algorithms are usually designed to solve optimization problems Unlike dynamic programming.
Recurrences / HW: 2.4 Quiz: 2.1, 4.1, 4.2, 5.2, 7.3, 7.4 Midterm: 8 given a recursive algorithm, state the recurrence solve a recurrence, using Master.
Data Structures, Spring 2004 © L. Joskowicz 1 DAST – Final Lecture Summary and overview What we have learned. Why it is important. What next.
The Design and Analysis of Algorithms
DAST, Spring © L. Joskowicz 1 Data Structures – LECTURE 1 Introduction Motivation: algorithms and abstract data types Easy problems, hard problems.
Design and Analysis of Algorithms - Chapter 41 Divide and Conquer The most well known algorithm design strategy: 1. Divide instance of problem into two.
Instructor: Dr. Sahar Shabanah Fall Lectures ST, 9:30 pm-11:00 pm Text book: M. T. Goodrich and R. Tamassia, “Data Structures and Algorithms in.
Teaching Teaching Discrete Mathematics and Algorithms & Data Structures Online G.MirkowskaPJIIT.
CS112A1 Spring 2008 Practice Final. ASYMPTOTIC NOTATION: a)Show that log(n) and ln(n) are the same in terms of Big-Theta notation b)Show that log(n+1)
Lecture 10: Class Review Dr John Levine Algorithms and Complexity March 13th 2006.
Nirmalya Roy School of Electrical Engineering and Computer Science Washington State University Cpt S 223 – Advanced Data Structures Course Review Midterm.
10/20/20151 CS 3343: Analysis of Algorithms Review for final.
+ Review CS302 Spring 2013 David Kauchak. + Admin Final posted on the course web page on Monday due Sunday at 11:59pm time-boxed (3-4 hours) You may use:
INTRODUCTION. What is an algorithm? What is a Problem?
December 4, Algorithms and Data Structures Lecture XV Simonas Šaltenis Aalborg University
CS Data Structures II Review & Final Exam. 2 Topics Review Final Exam.
Christopher Moh 2005 Competition Programming Analyzing and Solving problems.
CS223 Advanced Data Structures and Algorithms 1 Review for Final Neil Tang 04/27/2010.
1 BIM304: Algorithm Design Time: Friday 9-12am Location: B4 Instructor: Cuneyt Akinlar Grading –2 Midterms – 20% and 30% respectively –Final – 30% –Projects.
Runtime O(VE), for +/- edges, Detects existence of neg. loops
Course Review Fundamental Structures of Computer Science Margaret Reid-Miller 29 April 2004.
CSE 340: Review (at last!) Measuring The Complexity Complexity is a function of the size of the input O() Ω() Θ() Complexity Analysis “same order” Order.
CS6045: Advanced Algorithms Sorting Algorithms. Heap Data Structure A heap (nearly complete binary tree) can be stored as an array A –Root of tree is.
Review I. Final exam Date TBD. Don ’ t be late! Open book, open notes No calculators or any electronics Worth 50% of final grade.
 Saturday, April 20, 8:30-11:00am in B9201  Similar in style to written midterm exam  May include (a little) coding on paper  About 1.5 times as long.
2016/3/13Page 1 Semester Review COMP3040 Dept. Computer Science and Technology United International College.
Course Review Fundamental Structures of Computer Science Ananda Guna May 04, 2006.
Welcome to the Course of Advanced Algorithm Design
Data Structures and Algorithms
CSE 326: Data Structures: Advanced Topics
Topics Covered after Mid-Term
Major Design Strategies
Courtsey & Copyright: DESIGN AND ANALYSIS OF ALGORITHMS Courtsey & Copyright:
Data Structures and Algorithms
CS 3343: Analysis of Algorithms
Design and Analysis of Computer Algorithm (CS575-01)
CS 3343: Analysis of Algorithms
Design and Analysis of Algorithms (07 Credits / 4 hours per week)
OVERVIEW 1-st Midterm: 3 problems 2-nd Midterm 3 problems
CS 3343: Analysis of Algorithms
CS 3343: Analysis of Algorithms
CS 3343: Analysis of Algorithms
CS 3343: Analysis of Algorithms
Major Design Strategies
Design and Analysis of Algorithms (04 Credits / 4 hours per week)
Review for Final Neil Tang 05/01/2008
Major Design Strategies
Presentation transcript:

Course Review Fundamental Structures of Computer Science Margaret Reid-Miller 28 April 2005

What was this course about? How to solve computing problems. Problem analysis, to abstract away details and divide into smaller subproblems. Mathematical foundations for precise formulations of problems and solutions. Data structures and algorithms to solve problems correctly and efficiently. Java programming and modular software construction for good implementations.

Data Structures - Lists - Trees - Tries - Priority Queues - Hash Table Really not basic DS, more conceptual. - Graphs - Equiv. Relations - FSMs - Geometry - Polynomials

Algorithms - Searching - Hashing - Sorting - Compression - String Matching Complexity. Correctness. Applications. - Graph Algorithms - Dynamic Programming - Games - Polynomial Comp. - Comp. Geometry

Programming Object oriented programming. Correctness (loop invariants, induction). Time and space complexity. Debugging (test harness).

Studying for the Final Exam Review all material first Lectures, programs, quizzes Do sample finals – under time restrictions Old finals are in blackboard/assignments Types and difficulty of problems may be similar (some topics not covered)

Solving Recurrences, Asymptotics Solve T(n) = 3 T(n/3) + 1 Prove the correctness By induction Invariants  Hold initially  Preserved after each iteration of loop or method call Or other methods Big-Oh, little-oh, Big-Omega, Theta Master Theorem

Sorting and lower bounds

Insertion Sort Selection Sort Heapsort Mergesort Quicksort Radix Sort

Binary Trees 1.Traverse the tree inorder 2.Do exactly two rotations so that the tree is balanced 3. Consider a binary tree of height h a.What are the max and min number of nodes? b.What are the max and min number of leaves? 4. Perfect, full, complete trees

Balanced Binary Trees

Dictionaries

Hashing Describe why hashing a string to sum of its characters is not a good idea. Assume S = a 1 a 2 ….a n is a string Define H(S) =  a i 2 i-1 (i=1..n) Describe a way to efficiently calculate H(S)

Priority Queues and Heaps Suppose you implement a priority queue using following Unsorted array Linked list (smallest at front) Heap What is the complexity in each case for deleteMin insert

Binary heaps

Compression

LZW compression

Data Compression Encode “I AM SAM SAM I AM SAM SAM” using Huffman compression LZW In each case calculate the compression ratio Is it possible to apply Huffman after applying LZW? If so apply Huffman to output generated by LZW above

Graphs What is breadth first traversal? What is depth first traversal? What data structures can be used to implement each one? Reachability Connected components Topological sort

Graphs

Adjacency lists and matrices Traversal (DFS, BFS) Reachability (DFS, BFS, Warshall) Shortest Paths (Dijkstra, Bellman- Ford) MST (Prim, Kruskal)

Greedy Algorithms Find the Shortest Path from Node 1 to every other node

Dynamic Programming Dependent subproblems, recursive solutions, memoizing, explicit tables. Knapsack Longest Common Subsequence Matrix Multiplication Floyd-Warshall-Kleene

Dynamic Programming Consider a sequence of n numbers, A = {a 1, a 2, a 3,..., a n }. A subsequence of a given sequence is just the given sequence with 0 or more of the elements removed. Let's find an algorithm that finds the subsequence, A' = {a i1, a i2, a i3,...a ik } of A that maximizes a i1 - a i2 + a i a ik (i.e. the sign alternates).

Game trees

Games 2-person, deterministic, complete information,... Backtracking MiniMax Alpha-beta pruning Heuristics, iterative deepening, move order, tricks,...

Union-find

String matching

Polynomials Horner’s method Lagrange interpolants secret sharing Karatsuba Alg Integer & polynomial multiplication FFT method for polynomial multiplication Schwartz: Is polynomial identically zero?

Computational Geometry

Points, lines, rays, line segments Intersection, turns Membership in region Convex hull Divide-and-Conquer (QuickHull,...) Lower Bound

Final Exam Thursday, May 5, 8:30 –11:30 am McConomy (*not* in WeH 7500) Sugary stuff will be provided... Make sure not to be late.

Final Exam Closed book, no calculators, cell phones, pagers, IM, … You can bring 1 (one) page of notes. Bring fluids

Conclusion Review all material Do all sample quizzes and finals Good luck!!