Intro to Computer Algorithms Lecture 1 Phillip G. Bradford Computer Science University of Alabama.

Slides:



Advertisements
Similar presentations
Lecture 1: Introduction – Ch 1
Advertisements

CS 253: Algorithms Syllabus Chapter 1 Appendix A.
UMass Lowell Computer Science Analysis of Algorithms Prof. Karen Daniels Spring, 2009 Tuesday, 28 April Number-Theoretic Algorithms Chapter 31.
Announcements: Homework 1 returned. Comments from Kevin? Homework 1 returned. Comments from Kevin? Matlab: tutorial available at
UMass Lowell Computer Science Analysis of Algorithms Prof. Karen Daniels Fall, 2002 Tuesday, 26 November Number-Theoretic Algorithms Chapter 31.
Design and Analysis of Algorithms - Chapter 1
What is an algorithm? An algorithm is a sequence of unambiguous instructions for solving a problem, i.e., for obtaining a required output for any legitimate.
EE 220 (Data Structures and Analysis of Algorithms) Instructor: Saswati Sarkar T.A. Prasanna Chaporkar, Programming.
CSC 2300 Data Structures & Algorithms January 30, 2007 Chapter 2. Algorithm Analysis.
The Design and Analysis of Algorithms
UMass Lowell Computer Science Analysis of Algorithms Prof. Karen Daniels Fall, 2001 Lecture 7 Tuesday, 11/6/01 Number-Theoretic Algorithms Chapter.
UNIVERSITY OF SOUTH CAROLINA Department of Computer Science and Engineering Design and Analysis of Algorithms - Chapter 11 Algorithm An algorithm is a.
TK3043 Analysis and Design of Algorithms Introduction to Algorithms.
CS1101: Programming Methodology Aaron Tan.
Introduction Dr. Ying Lu RAIK 283: Data Structures & Algorithms.
Piyush Kumar (Lecture 1: Introduction)
COMP 170 L2 Page 1 L05: Inverses and GCDs l Objective: n When does have an inverse? n How to compute the inverse? n Need: Greatest common dividers (GCDs)
CS223 Algorithms D-Term 2013 Instructor: Mohamed Eltabakh WPI, CS Introduction Slide 1.
Extended Euclidean Algorithm Presented by Lidia Abrams Anne Cheng.
Mathematics in OI Prepared by Ivan Li. Mathematics in OI Greatest Common Divisor Finding Primes High Precision Arithmetic Partial Sum and Differencing.
CS 390 Introduction to Theoretical Computer Science.
Course Web Page Most information about the course (including the syllabus) will be posted on the course wiki:
Intro to Computer Algorithms Lecture 11 Phillip G. Bradford Computer Science University of Alabama.
Introduction to Algorithms By Mr. Venkatadri. M. Two Phases of Programming A typical programming task can be divided into two phases: Problem solving.
CS 403: Programming Languages Lecture 1 Fall 2003 Department of Computer Science University of Alabama Joel Jones.
Intro to Computer Algorithms Lecture 16 Phillip G. Bradford Computer Science University of Alabama.
MA/CSSE 473 Day 02 Some Numeric Algorithms and their Analysis.
Copyright © 2007 Pearson Addison-Wesley. All rights reserved. Chapter 1 Introduction.
CSE 311: Foundations of Computing Fall 2014 Lecture 12: Primes, GCD.
ICS202 Data Structures King Fahd University of Petroleum & Minerals College of Computer Science & Engineering Information & Computer Science Department.
Algorithms 1.Notion of an algorithm 2.Properties of an algorithm 3.The GCD algorithm 4.Correctness of the GCD algorithm 5.Termination of the GCD algorithm.
UNIT-I INTRODUCTION ANALYSIS AND DESIGN OF ALGORITHMS CHAPTER 1:
A. Levitin “Introduction to the Design & Analysis of Algorithms,” 3 rd ed., Ch. 1 ©2012 Pearson Education, Inc. Upper Saddle River, NJ. All Rights Reserved.
Computability Heap exercise. The class P. The class NP. Verifiers. Homework: Review RELPRIME proof. Find examples of problems in NP.
Prof. Amr Goneid, AUC1 Analysis & Design of Algorithms (CSCE 321) Prof. Amr Goneid Department of Computer Science, AUC Part 1. Complexity Bounds.
CS404 Design and Analysis of Algorithms BBy DDr. M V S Peri Sastry BB.E, PhD(BITS-Pilani)
CS 615: Design & Analysis of Algorithms Chapter 2: Efficiency of Algorithms.
CSE 311 Foundations of Computing I Lecture 14 Euclid’s Algorithm Mathematical Induction Autumn 2012 CSE
Introduction to design and analysis algorithm
Data Structures and Algorithms in Java AlaaEddin 2012.
MA/CSSE 473 Day 07 Euclid's Algorithm. MA/CSSE 473 Day 07 Student Questions Review topics not covered in class Euclid's algorithm (if there is time) extended.
1 Introduction to design and analysis algorithm. 2.
Intro to Computer Algorithms Lecture 15 Phillip G. Bradford Computer Science University of Alabama.
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett.
MA/CSSE 473 Day 05 Factors and Primes Recursive division algorithm.
TK3043 Analysis and Design of Algorithms
The Design and Analysis of Algorithms
Chapter 1 Introduction Copyright © 2007 Pearson Addison-Wesley. All rights reserved.
What is an algorithm? An algorithm is a sequence of unambiguous instructions for solving a problem, i.e., for obtaining a required output for any legitimate.
What is an algorithm? An algorithm is a sequence of unambiguous instructions for solving a problem, i.e., for obtaining a required output for any legitimate.
What is an algorithm? An algorithm is a sequence of unambiguous instructions for solving a problem, i.e., for obtaining a required output for any legitimate.
Introduction to the Design and Analysis of Algorithms
Introduction to The Design & Analysis of Algorithms
CSE 311 Foundations of Computing I
What is an algorithm? An algorithm is a sequence of unambiguous instructions for solving a problem, i.e., for obtaining a required output for any legitimate.
Introduction of ECE665 Computer Algorithms
Courtsey & Copyright: DESIGN AND ANALYSIS OF ALGORITHMS Courtsey & Copyright:
GCD and Optimization Problem
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett
What is an algorithm? An algorithm is a sequence of unambiguous instructions for solving a problem, i.e., for obtaining a required output for any legitimate.
What is an algorithm? An algorithm is a sequence of unambiguous instructions for solving a problem, i.e., for obtaining a required output for any legitimate.
Discrete Math for CS CMPSC 360 LECTURE 12 Last time: Stable matching
REU Summer Research in Computer Security
Discrete Math for CS CMPSC 360 LECTURE 43 Last time: Variance
Introduction to Algorithms
CSC 380: Design and Analysis of Algorithms
Design and Analysis of Algorithms
Chapter 1 Introduction Copyright © 2007 Pearson Addison-Wesley. All rights reserved.
What is an algorithm? An algorithm is a sequence of unambiguous instructions for solving a problem, i.e., for obtaining a required output for any legitimate.
Presentation transcript:

Intro to Computer Algorithms Lecture 1 Phillip G. Bradford Computer Science University of Alabama

Announcements ACM initial meeting of the year. Thursday, August 28th, 5:00pm in East Eng. 119 Industrial Colloquium Series Tuesday, September 2nd, 5:00pm in EE 119 Herschel Chandler presents: “Being an Independent Computer Consultant”

General Lecture Format Some power-point slides Some white-board writing Details are very important Lots of Interaction a good thing

Lecture Outline Syllabus Learning Grading Your Expectations My Expectations Material: High Level Overview Motivation Foundations, History and Perspective Applications of Algorithms & the Future

Lecture Outline The book by A. Levitin Design paradigms approach Nice way to think about design & analysis Classifications of challenges on how they are solved Commonalities are the solutions Let’s get started Chapter 1.1 to 1.3

My Expectations Exercise gives strength This is an exercise course Excellent Students give excellent results Given some work What are your expectations? Survey

Motivation How hard is it to solve Computer Challenges? Deep Question…heavy ramifications Optimization Applications Networks Financial Models, business issues, etc. Real-Time Applications Airplanes, trains, missiles Sensors, medical applications, etc.

Motivation Foundational questions Sorting & searching Exhaustive Search Apparent hardness of old and new challenges Cuts across engineering and other math & science disciplines

Algorithms What is an algorithm? Unambiguous list of instructions that solve a challenge Gives the right answer on legitimate input What about algorithms that use randomness? Designed with randomness in mind Really, pseudo-random numbers

Algorithms: what to do… Page 10, Figure 1.2 Understand the challenge! Design an algorithm Easy sub cases first, perhaps Prove correctness Analyze the algorithm Check & improve design if analysis warrants Iterate, iterate, …

Euclid’s Algorithm The challenge Greatest-common divisors GCD(12,6) = 6 GCD(17,16) = 1 GCD(20,15) = 5 Euclid’s method GCD(m,0) = m GCD(m,n) = GCD(n, m mod n)

Euclid’s Algorithm, cont. Book example: GCD(60,24) = GCD(24,12) = GCD(12,0) = 12 Euclid(m,n) While(n != 0) { r  m mod n; m  n; n  r; } Return m;

Euclid’s Algorithm Correctness? Halts? Prime-Factor approach How? Which is better?? Relative costs?

Sieve of Eratosthenes Challenge: given an integer n, find all primes <= n. Example: n = 18, then output: 2,3,5,7,11,13,17 Elimination of prime candidates by potential factors Claim: the largest potential factor: floor(sqroot(n))

Types of Problems Sorting, Searching Stable Sorts String Processing Graph problems Combinatorial problems TSP Geometric Problems Numerical Problems

Homework set Due Tuesday Page 8, #5, #6 Page 17, #1 Page 18, #3, #8