Lecture 1 CS 1813 – Discrete Mathematics

Slides:



Advertisements
Similar presentations
22C:19 Discrete Structures Induction and Recursion Fall 2014 Sukumar Ghosh.
Advertisements

What’s wrong with this proof? If you figure it out, don’t call it out loud – let others ponder it as well. 1. Let a and b be non-zero such thata = b 2.
Welcome to 8 th Grade Math at Lanier Middle School! My name is Ms Cooper.
Software Reliability CIS 640 Adapted from the lecture notes by Doron Pelel (
CS 1813 Discrete Mathematics, Univ Oklahoma Copyright © 2000 by Rex Page 1 Lecture 3 CS 1813 – Discrete Mathematics Truth Inference and the Logical Way.
About the Course Lecture 0: Sep 2 AB C. Plan  Course Information and Arrangement  Course Requirement  Topics and objectives of this course.
CSE115/ENGR160 Discrete Mathematics 01/17/12 Ming-Hsuan Yang UC Merced 1.
CS 2210 (22C:019) Discrete Structures Logic and Proof Spring 2015 Sukumar Ghosh.
Algorithm Design and Analysis (ADA)
C OURSE : D ISCRETE STRUCTURE CODE : ICS 252 Lecturer: Shamiel Hashim 1 lecturer:Shamiel Hashim second semester Prepared by: amani Omer.
7-Sep-15 Physics 1 (Garcia) SJSU Conceptual Physics (Physics 1) Prof. Alejandro Garcia Spring 2007.
CS 103 Discrete Structures Lecture 01 Introduction to the Course
CS 1813 Discrete Mathematics, Univ Oklahoma Copyright © 2000 by Rex Page 1 Lecture 18 CS 1813 – Discrete Mathematics Loops Without Invariants Are Like.
MATH 224 – Discrete Mathematics
Welcome to 8 th Grade Math at Lanier Middle School! My name is Ms Cooper.
Class 1: What this course is about. Assignment Read: Chapter 1 Read: Chapter 1 Do: Chapter 1 ‘workbook’ pages not finished in class Do: Chapter 1 ‘workbook’
Discrete Maths: Induction/1 1 Discrete Maths Objective – –to introduce mathematical induction through examples , Semester
CS 1813 Discrete Mathematics, Univ Oklahoma Copyright © 2000 by Rex Page 1 Lecture 7 CS 1813 – Discrete Mathematics Equational Reasoning Back to the Future:
Introduction COMP283 – Discrete Structures. JOOHWI LEE Dr. Lee or Mr. Lee ABD Student working with Dr. Styner
Expectations in a College Math Class How does taking math in college differ from taking math in high school? What is your instructor thinking?
CompSci 102 Discrete Math for Computer Science March 1, 2012 Prof. Rodger Slides modified from Rosen.
CS 1813 Discrete Mathematics, Univ Oklahoma Copyright © 2000 by Rex Page 1 Lecture 2 CS 1813 – Discrete Mathematics Proofs Propositions and Calculuses.
 22M:150 Introduction to Discrete Mathematics  Fall :30A - 11:20A MWF 218 MLH  Instructor: Dr. Isabel Darcy Office:B1H MLH Phone:
22C:19 Discrete Structures Logic and Proof Fall 2014 Sukumar Ghosh.
CSE 311 Foundations of Computing I Lecture 28 Computability: Other Undecidable Problems Autumn 2011 CSE 3111.
1 CS 381 Introduction to Discrete Structures Lecture #1 Syllabus Week 1.
CS 225 Discrete Structures in Computer Science Winter, 2014: 157 Spring, 2014: 151 Summer, 2014: Two sections 97 and 53.
CS/APMA 202 Spring 2005 Aaron Bloomfield. Sequences in Nature
CS 1813 Discrete Mathematics, Univ Oklahoma Copyright © 2000 by Rex Page 1 Lecture 17 CS 1813 – Discrete Mathematics How Does It Work in the Real World?
Notions & Notations - 1ICOM 4075 (Fall 2010) UPRM Department of Electrical and Computer Engineering University of Puerto Rico at Mayagüez Fall 2010 ICOM.
KU 122: Introduction to Math Skills and Strategies Prof. Scott Brown Unit 1 Seminar.
Proof And Strategies Chapter 2. Lecturer: Amani Mahajoub Omer Department of Computer Science and Software Engineering Discrete Structures Definition Discrete.
Harper Langston New York University Summer 2017
CS 2210:0001 Discrete Structures Logic and Proof
P & NP.
MATH 224 – Discrete Mathematics
MATHEMATICS EDUCATION DEPARTMENT
COMP 283 Discrete Structures
WELCOME (Back) …TO THE CAMPUS OF TOMORROW.
MyStatLab Student help/instructions MTH/233
Welcome to CMSC 203 – Discrete Structures Spring 2003
CS2210:0001Discrete Structures Induction and Recursion
Database Design and Implementation
Principles of Computing – UFCFA Lecture-1
Psychological Science I: Statistics
CS 583 Fall 2006 Analysis of Algorithms
Lecture 4 CS 1813 – Discrete Mathematics
CS 1813 – Discrete Mathematics
Lecture 12 CS 1813 – Discrete Mathematics
Welcome to CS 1340! Computing for scientists.
Mathematical Structures for Computer Science Chapter 1
CS 1813 – Discrete Mathematics
CS 220: Discrete Structures and their Applications
Jeremy Bolton, PhD Assistant Teaching Professor
CSE 311 Foundations of Computing I
Induction and recursion
This Lecture Substitution model
Programming in JavaScript
Lecture 9 CS 1813 – Discrete Mathematics
Lecture 11 CS 1813 – Discrete Mathematics
Lecture 5 CS 1813 – Discrete Mathematics
Programming in JavaScript
CMSC201 Computer Science I for Majors Final Exam Information
BIT 115: Introduction To Programming
This Lecture Substitution model
Principles of Computing – UFCFA Week 1
Welcome to CS 620 – Theory of Computation Spring 2019
This Lecture Substitution model
Honors Analysis COURSE DESCRIPTION
IE 360: Design and Control of Industrial Systems I
Presentation transcript:

Lecture 1 CS 1813 – Discrete Mathematics Learning Goals Lesson Plans and Logic Rex Page Professor of Computer Science University of Oklahoma EL 119 – Page@OU.edu CS 1813 Discrete Mathematics, Univ Oklahoma Copyright © 2000 by Rex Page

CS 1813 Discrete Mathematics Learning Goals Lecture 1 - CS1813 Discrete Math, University of Oklahoma 12/10/2018 CS 1813 Discrete Mathematics Learning Goals Apply mathematical logic to prove properties of software Predicate calculus and natural deduction Boolean algebra and equational reasoning Mathematical induction Understand fundamental data structures Sets Trees Functions and relations Additional topics Graphs Counting Algorithm Complexity proofs galore! CS 1813 Discrete Mathematics, Univ Oklahoma Copyright © 2000 by Rex Page

Lecture 1 - CS1813 Discrete Math, University of Oklahoma 12/10/2018 Why Proofs? 100s of inputs > 2100s of possibilities input signals software output signals Key presses Mouse gestures Files Databases … computation Images Sounds Software translates input signals to output signals A program is a constructive proof of a translation Responsible software developers are obligated specify what properties their software is guaranteed to have. Proofs play a big role in this. Other methods of confirming software properties, especially testing, leave software riddled with errors. Most systems have hundreds of input signals. Since each input signal must have at least two possible values, the number of different input states that must be checked to verify the operation of the software through testing is at least 2 to the power 100. If you can generate, run, and examine one test case every minute, round the clock, you will not finish testing before you die. Not even before the sun runs out of fuel. Not even if you do one test case every nanosecond. Forget it. Testing can work only on very small pieces of software. But what translation? Proofs can confirm that software works correctly Testing cannot confirm software correctness Practice with proofs improves software thinking CS 1813 Discrete Mathematics, Univ Oklahoma Copyright © 2000 by Rex Page

CS 1813 Discrete Mathematics Textbook and Tools Discrete Mathematics Using a Computer Cordelia Hall and John O’Donnell Springer-Verlag, January 2000 Tools provided with textbook Download from course website for CS 1813 Hugs interpreter for Haskell Download from course website Haskell is a math notation (and a programming lang) Reading assignments begin with Chapter 2 Read Chapter 1 (Haskell) as needed, for reference Haskell coverage JIT, like other math notations CS 1813 Discrete Mathematics, Univ Oklahoma Copyright © 2000 by Rex Page

Formal Mathematical Notations Lecture 1 - CS1813 Discrete Math, University of Oklahoma 12/10/2018 Formal Mathematical Notations Notations introduced as needed (JIT) Logic ab, ab, ab, x.P(x), x.Q(x),  Sets A  B, A  B, {x | xS, P(x)},  Sequences [x | x <- s, P(x)] [4, 7, 2] ++ [3, 7] == [4,7,2,3,7] Haskell s(a: xs) = s[x | x <- xs, x < a] ++ [a] ++ s[x | x <- xs, x >= a] The last one contains a sequence, but is not itself a sequence. It is an algebraic datatype using several constructors (Theorem, Imp, Not, etc.). Structures Theorem [P, Q] (And P Q) CS 1813 Discrete Mathematics, Univ Oklahoma Copyright © 2000 by Rex Page

Lecture 1 - CS1813 Discrete Math, University of Oklahoma 12/10/2018 Coursework Class Attendance REQUIRED Reading assignments See syllabus on course website Study prior to class Class Participation Homework problem sets Approximately weekly Midterm Exam 1 Midterm Exam 2 Final Exam 10% 20% Contribution to grade 40% The Q/A Lab will be a lecture/workshop format. The instructor will not come with a prepared agenda. Students ask questions, and the instructor attempts to answer them. The instructor will bring a laptop computer for addressing problems with software. Students may also bring laptops. The Q/A session will go on as long as necessary, or until 10pm, whichever comes first. Q/A Lab Attendance NOT REQUIRED Q/A Lab – Thursdays 8:00pm, CEC 439 CS 1813 Discrete Mathematics, Univ Oklahoma Copyright © 2000 by Rex Page

Tiling with Dominos a mathematical proof – just for practice Lecture 1 - CS1813 Discrete Math, University of Oklahoma 12/10/2018 Tiling with Dominos a mathematical proof – just for practice Dominos – size matches board checkerboard with two missing corners Problem cover board with dominos no overlapping dominos no dominos outside board How many squares on board? Adapted from Singh, Fermat’s Enigma, Walker & Co, 1997 So, how many dominos will it take? One domino covers how many red squares? Let’s do a little planning before we start laying dominos on the checkerboard. How many dominos is it going to take to do the job? When a domino is place on the board, how many red squares and how many black squares does it cover? How many red squares are covered when 30 dominos have been placed? How many black squares? How many red squares are left to be covered? There are only 30 red squares, so they’re all covered when 30 dominos have been placed. That leaves no red square for the last domino to cover. The last two squares are black. The last domino cannot cover them because no two black square are next to each other. 31 dominos cover how many red squares? How many red squares are there? Yikes! What’s wrong here? TILT CS 1813 Discrete Mathematics, Univ Oklahoma Copyright © 2000 by Rex Page

How To Find a Million Dollars using logic Lecture 1 - CS1813 Discrete Math, University of Oklahoma 12/10/2018 How To Find a Million Dollars using logic Three Doors Behind one is a million dollars Behind another is a Palm Pilot Behind the other is a melting Popsicle Where’s the jackpot? Why not A? Why not B? Must be C, eh? Bonus question: Where’s the Palm Pilot? Door C speaks the truth – the Palm Pilot is behind A Door B lies – it has a Popsicle, afterall A Palm Here B Popsicle Behind C C Palm Behind A Adapted from Smullyan, The Lady or the Tiger, Times Books, 1982 so palm here if $$$ here … popsicle here so C sign correct It can’t be door A because the statement on the jackpot door is true, and door A says the Palm Pilot is behind it. So, the jackpot can’t be behind door A. It can’t be door B because if door B had the jackpot, it’s sign would be true, and the Popsicle would be behind C. But if the Popsicle were behind C, the statement on C would be false, but it can’t be because there’s nowhere else but door A for the Palm Pilot. So the jackpot can’t be behind door B. TILT Signs on Doors $$$ door: true statement Popsicle door: false statement If it was so, it might be; and if it were so, it would be: but as it isn’t, it ain’t. That’s logic. - Tweedledee in Through the Looking Glass CS 1813 Discrete Mathematics, Univ Oklahoma Copyright © 2000 by Rex Page

Tracing a Square and Its Diagonals Square + Diagonals Problem Start at any corner Trace some line to another corner Then trace from that corner to another Keep going until all six lines are traced Don’t trace any line more than once (crossing OK, but not retracing) Solution revealed in the next lecture CS 1813 Discrete Mathematics, Univ Oklahoma Copyright © 2000 by Rex Page

CS 1813 Discrete Mathematics, Univ Oklahoma Homework #1 Problem under “Assignments” tab in course website It’s a hard problem You don’t have much mathematical apparatus, yet, to attack it Grade based more on thoughtfulness and well-expressed ideas than on solutions CS 1813 Discrete Mathematics, Univ Oklahoma Copyright © 2000 by Rex Page

CS 1813 Discrete Mathematics, Univ Oklahoma End of Lecture CS 1813 Discrete Mathematics, Univ Oklahoma Copyright © 2000 by Rex Page