# CS 441 Discrete Mathematics for CS Lecture 2. Propositional logic. CS 441 Discrete mathematics for CS. Course administration

Save this PDF as:

Size: px
Start display at page:

Download "CS 441 Discrete Mathematics for CS Lecture 2. Propositional logic. CS 441 Discrete mathematics for CS. Course administration"

## Transcription

1 CS 441 Discrete Mathematics for CS Lecture 2 Propositional logic Milos Hauskrecht 5329 Sennott Square Course administration Homework 1 First homework assignment is out today will be posted on the course web page Due next week on Thurday Recitations: today at 4:00pm SENSQ 5313 tomorrow at 11:00 SENSQ 5313 Course web page: 1

2 Propositional logic: review Propositional logic: a formal language for representing knowledge and for making logical inferences A proposition is a statement that is either true or false. A compound proposition can be created from other propositions using logical connectives The truth of a compound proposition is defined by truth values of elementary propositions and the meaning of connectives. The truth table for a compound proposition: table with entries (rows) for all possible combinations of truth values of elementary propositions. Compound propositions Let p: 2 is a prime.. T q: 6 is a prime.. F Determine the truth value of the following statements: p: F p q : F p q: T p q : T p q: T p q: F q p: T 2

3 Constructing the truth table Example: Construct the truth table for (p q) ( p q) Constructing the truth table Example: Construct the truth table for (p q) ( p q) Rows: all possible combinations of values p q p for p elementary q p q (p q) propositions: ( p q) T T 2 n values T F F T F F 3

4 Constructing the truth table Example: Construct the truth table for (p q) ( p q) Typically the target (unknown) compound proposition and its values p q p p q p q (p q) ( p q) T T T F F F T F Auxiliary compound propositions and their values Constructing the truth table Examples: Construct a truth table for (p q) ( p q) p q p p q p q (p q) ( p q) T T F T F F T F F F T F F T T T T T F F T T F F 4

5 Computer representation of True and False We need to encode two values True and False: Computers represents data and programs using 0s and 1s Logical truth values True and False A bit is sufficient to represent two possible values: 0 (False) or 1(True) A variable that takes on values 0 or 1 is called a Boolean variable. Definition: A bit string is a sequence of zero or more bits. The length of this string is the number of bits in the string. Bitwise operations T and F replaced with 1 and 0 p q p q p q p p

6 Bitwise operations Examples: Applications of propositional logic Translation of English sentences Inference and reasoning: new true propositions are inferred from existing ones Used in Artificial Intelligence: Rule based (expert) systems Automatic theorem provers Design of logic circuit 6

7 Translation Assume a sentence: If you are older than 13 or you are with your parents then you can attend a PG-13 movie. Parse: If ( you are older than 13 or you are with your parents )then ( you can attend a PG-13 movie) Atomic (elementary) propositions: A= you are older than 13 B= you are with your parents C=you can attend a PG-13 movie Translation: A B C Translation General rule for translation. Look for patterns corresponding to logical connectives in the sentence and use them to define elementary propositions. Example: You can have free coffee if you are senior citizen and it is a Tuesday Step 1 find logical connectives 7

8 Translation General rule for translation. Look for patterns corresponding to logical connectives in the sentence and use them to define elementary propositions. Example: You can have free coffee if you are senior citizen and it is a Tuesday Step 1 find logical connectives Translation General rule for translation. Look for patterns corresponding to logical connectives in the sentence and use them to define elementary propositions. Example: You can have free coffee if you are senior citizen and it is a Tuesday Step 2 break the sentence into elementary propositions 8

9 Translation General rule for translation. Look for patterns corresponding to logical connectives in the sentence and use them to define elementary propositions. Example: You can have free coffee if you are senior citizen and it is a Tuesday a b c Step 2 break the sentence into elementary propositions Translation General rule for translation. Look for patterns corresponding to logical connectives in the sentence and use them to define elementary propositions. Example: You can have free coffee if you are senior citizen and it is a Tuesday a b c Step 3 rewrite the sentence in propositional logic b c a 9

10 Translation Assume two elementary statements: p: you drive over 65 mph ; q: you get a speeding ticket Translate each of these sentences to logic you do not drive over 65 mph. ( p) you drive over 65 mph, but you don't get a speeding ticket. (p q) you will get a speeding ticket if you drive over 65 mph. (p q) if you do not drive over 65 mph then you will not get a speeding ticket.( p q) driving over 65 mph is sufficient for getting a speeding ticket. (p q) you get a speeding ticket, but you do not drive over 65 mph. (q p) Application: inference Assume we know the following sentences are true: If you are older than 13 or you are with your parents then you can attend a PG-13 movie. You are older than 13. Translation: If ( you are older than 13 or you are with your parents )then ( you can attend a PG-13 movie). (You are older than 13). A= you are older than 13 B= you are with your parents C=you can attend a PG-13 movie (A B C), A (A B C) A is true With the help of the logic we can infer the following statement (proposition): You can attend a PG-13 movie or C is True 10

11 Application: inference The field of Artificial Intelligence: Builds programs that act intelligently Programs often rely on symbolic manipulations Expert systems: Encode knowledge about the world in logic Support inferences where new facts are inferred from existing facts following the semantics of logic Theorem provers: Encode existing knowledge (e.g. about math) using logic Show that some hypothesis is true Example: MYCIN MYCIN: an expert system for diagnosis of bacterial infections It represents Facts about a specific patient case Rules describing relations between entities in the bacterial infection domain If Then 1. The stain of the organism is gram-positive, and 2. The morphology of the organism is coccus, and 3. The growth conformation of the organism is chains the identity of the organism is streptococcus Inferences: manipulates the facts and known relations to answer diagnostic queries (consistent with findings and rules) CS

12 Tautology and Contradiction Some propositions are interesting since their values in the truth table are always the same Definitions: A compound proposition that is always true for all possible truth values of the propositions is called a tautology. A compound proposition that is always false is called a contradiction. A proposition that is neither a tautology nor contradiction is called a contingency. Example: p p is a tautology. p p p p T F F T T T Tautology and Contradiction Some propositions are interesting since their values in the truth table are always the same Definitions: A compound proposition that is always true for all possible truth values of the propositions is called a tautology. A compound proposition that is always false is called a contradiction. A proposition that is neither a tautology nor contradiction is called a contingency. Example: p p is a contradiction. p p p p T F F T F F 12

13 Equivalence We have seen that some of the propositions are equivalent. Their truth values in the truth table are the same. Example: p q is equivalent to q p (contrapositive) p q p q q p T T T T T F F F F T T T F F T T Equivalent statements are important for logical reasoning since they can be substituted and can help us to: (1) make a logical argument and (2) infer new propositions Logical equivalence Definition: The propositions p and q are called logically equivalent if p q is a tautology (alternately, if they have the same truth table). The notation p <=> q denotes p and q are logically equivalent. Example of important equivalences DeMorgan's Laws: 1) ( p q ) <=> p q 2) ( p q ) <=> p q Example: Negate "The summer in Mexico is cold and sunny" with DeMorgan's Laws Solution:? 13

14 Equivalence Definition: The propositions p and q are called logically equivalent if p q is a tautology (alternately, if they have the same truth table). The notation p <=> q denotes p and q are logically equivalent. Example of important equivalences DeMorgan's Laws: 1) ( p q ) <=> p q 2) ( p q ) <=> p q Example: Negate "The summer in Mexico is cold and sunny" with DeMorgan's Laws Solution: "The summer in Mexico is not cold or not sunny." Equivalence Example of important equivalences DeMorgan's Laws: 1) ( p q ) <=> p q 2) ( p q ) <=> p q To convince us that two propositions are logically equivalent use the truth table p q p q (p q) p q T T F F T F F T F T T F F F T T 14

15 Equivalence Example of important equivalences DeMorgan's Laws: 1) ( p q ) <=> p q 2) ( p q ) <=> p q To convince us that two propositions are logically equivalent use the truth table p q p q (p q) p q T T F F F T F F T F F T T F F F F T T T Equivalence Example of important equivalences DeMorgan's Laws: 1) ( p q ) <=> p q 2) ( p q ) <=> p q To convince us that two propositions are logically equivalent use the truth table p q p q (p q) p q T T F F F F T F F T F F F T T F F F F F T T T T 15

16 Equivalence Example of important equivalences DeMorgan's Laws: 1) ( p q ) <=> p q 2) ( p q ) <=> p q To convince us that two propositions are logically equivalent use the truth table p q p q (p q) p q T T F F F F T F F T F F F T T F F F F F T T T T Identity p T <=> p p F <=> p Important logical equivalences Domination p T <=> T p F <=> F Idempotent p p <=> p p p <=> p 16

17 Important logical equivalences Double negation ( p) <=> p Commutative p q <=> q p p q <=> q p Associative (p q) r <=> p (q r) (p q) r <=> p (q r) Important logical equivalences Distributive p (q r) <=> (p q) (p r) p (q r) <=> (p q) (p r) De Morgan ( p q ) <=> p q ( p q ) <=> p q Other useful equivalences p p <=> T p p <=> F p q <=> ( p q) 17

18 Using logical equivalences Equivalences can be used in proofs. A proposition or its part can be transformed using equivalences and some conclusion can be reached. Example: Show (p q) p is a tautology. Proof: (we must show (p q) p <=> T) (p q) p <=> (p q) p Useful <=> [ p q] p DeMorgan <=> [ q p] p Commutative <=> q [ p p ] Associative <=> q [ T ] Useful <=> T Domination Using logical equivalences Equivalences can be used in proofs. A proposition or its part can be transformed using equivalences and some conclusion can be reached. Example: Show (p q) p is a tautology. Alternate proof: p q p q (p q) p T T T T T F F T F T F T F F F T 18

19 Using logical equivalences Equivalences can be used in proofs. A proposition or its part can be transformed using equivalences and some conclusion can be reached. Example 2: Show (p q) <=> ( q p) Proof: (p q) <=> ( q p) <=>? Using logical equivalences Equivalences can be used in proofs. A proposition or its part can be transformed using equivalences and some conclusion can be reached. Example 2: Show (p q) <=> ( q p) Proof: (p q) <=> ( q p) <=> ( q) ( p) Useful <=>? 19

20 Using logical equivalences Equivalences can be used in proofs. A proposition or its part can be transformed using equivalences and some conclusion can be reached. Example 2: Show (p q) <=> ( q p) Proof: (p q) <=> ( q p) <=> ( q) ( p) Useful <=> q ( p) Double negation <=>? Using logical equivalences Equivalences can be used in proofs. A proposition or its part can be transformed using equivalences and some conclusion can be reached. Example 2: Show (p q) <=> ( q p) Proof: (p q) <=> ( q p) <=> ( q) ( p) Useful <=> q ( p) Double negation <=> p q Commutative <=>? 20

21 Using logical equivalences Equivalences can be used in proofs. A proposition or its part can be transformed using equivalences and some conclusion can be reached. Example 2: Show (p q) <=> ( q p) Proof: (p q) <=> ( q p) <=> ( q) ( p) Useful <=> q ( p) Double negation <=> p q Commutative <=> p q Useful End of proof 21

### Discrete Mathematics for Computer Science

CS 441 Discrete Mathematics for CS Discrete Mathematics for Computer Science Milos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square Course administrivia Instructor: Milos Hauskrecht 5329 Sennott Square

### CS 441 Discrete Mathematics for CS Lecture 5. Predicate logic. CS 441 Discrete mathematics for CS. Negation of quantifiers

CS 441 Discrete Mathematics for CS Lecture 5 Predicate logic Milos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square Negation of quantifiers English statement: Nothing is perfect. Translation: x Perfect(x)

### Chapter I Logic and Proofs

MATH 1130 1 Discrete Structures Chapter I Logic and Proofs Propositions A proposition is a statement that is either true (T) or false (F), but or both. s Propositions: 1. I am a man.. I am taller than

### Discrete Mathematics Lecture 1 Logic of Compound Statements. Harper Langston New York University

Discrete Mathematics Lecture 1 Logic of Compound Statements Harper Langston New York University Administration Class Web Site http://cs.nyu.edu/courses/summer05/g22.2340-001/ Mailing List Subscribe at

### 2. Propositional Equivalences

2. PROPOSITIONAL EQUIVALENCES 33 2. Propositional Equivalences 2.1. Tautology/Contradiction/Contingency. Definition 2.1.1. A tautology is a proposition that is always true. Example 2.1.1. p p Definition

### Propositional Logic. Definition: A proposition or statement is a sentence which is either true or false.

Propositional Logic Definition: A proposition or statement is a sentence which is either true or false. Definition:If a proposition is true, then we say its truth value is true, and if a proposition is

### n logical not (negation) n logical or (disjunction) n logical and (conjunction) n logical exclusive or n logical implication (conditional)

Discrete Math Review Discrete Math Review (Rosen, Chapter 1.1 1.6) TOPICS Propositional Logic Logical Operators Truth Tables Implication Logical Equivalence Inference Rules What you should know about propositional

### 22C:19 Discrete Math. So. What is it? Why discrete math? Fall 2009 Hantao Zhang

22C:19 Discrete Math Fall 2009 Hantao Zhang So. What is it? Discrete mathematics is the study of mathematical structures that are fundamentally discrete, in the sense of not supporting or requiring the

### Propositional Logic. A proposition is a declarative sentence (a sentence that declares a fact) that is either true or false, but not both.

irst Order Logic Propositional Logic A proposition is a declarative sentence (a sentence that declares a fact) that is either true or false, but not both. Are the following sentences propositions? oronto

### CSE 191, Class Note 01 Propositional Logic Computer Sci & Eng Dept SUNY Buffalo

Propositional Logic CSE 191, Class Note 01 Propositional Logic Computer Sci & Eng Dept SUNY Buffalo c Xin He (University at Buffalo) CSE 191 Discrete Structures 1 / 37 Discrete Mathematics What is Discrete

### 1 Proposition, Logical connectives and compound statements

Discrete Mathematics: Lecture 4 Introduction to Logic Instructor: Arijit Bishnu Date: July 27, 2009 1 Proposition, Logical connectives and compound statements Logic is the discipline that deals with the

### Sets and set operations: cont. Functions.

CS 441 Discrete Mathematics for CS Lecture 8 Sets and set operations: cont. Functions. Milos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square Set Definition: set is a (unordered) collection of objects.

### Handout #1: Mathematical Reasoning

Math 101 Rumbos Spring 2010 1 Handout #1: Mathematical Reasoning 1 Propositional Logic A proposition is a mathematical statement that it is either true or false; that is, a statement whose certainty or

### Discrete Mathematics, Chapter : Propositional Logic

Discrete Mathematics, Chapter 1.1.-1.3: Propositional Logic Richard Mayr University of Edinburgh, UK Richard Mayr (University of Edinburgh, UK) Discrete Mathematics. Chapter 1.1-1.3 1 / 21 Outline 1 Propositions

### CHAPTER 1. Logic, Proofs Propositions

CHAPTER 1 Logic, Proofs 1.1. Propositions A proposition is a declarative sentence that is either true or false (but not both). For instance, the following are propositions: Paris is in France (true), London

### (Refer Slide Time: 05:02)

Discrete Mathematical Structures Dr. Kamala Krithivasan Department of Computer Science and Engineering Indian Institute of Technology, Madras Lecture - 1 Propositional Logic This course is about discrete

### Chapter 1, Part I: Propositional Logic. With Question/Answer Animations

Chapter 1, Part I: Propositional Logic With Question/Answer Animations Chapter Summary Propositional Logic The Language of Propositions Applications Logical Equivalences Predicate Logic The Language of

### Propositional Logic and Methods of Inference SEEM

Propositional Logic and Methods of Inference SEEM 5750 1 Logic Knowledge can also be represented by the symbols of logic, which is the study of the rules of exact reasoning. Logic is also of primary importance

### CS 441 Discrete Mathematics for CS Lecture 4. Predicate logic. CS 441 Discrete mathematics for CS. Announcements

CS 441 Discrete Mathematics for CS Lecture 4 Predicate logic Milos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square Announcements Homework assignment 1 due today Homework assignment 2: posted on the course

### CSL105: Discrete Mathematical Structures. Ragesh Jaiswal, CSE, IIT Delhi

Propositional Logic: logical operators Negation ( ) Conjunction ( ) Disjunction ( ). Exclusive or ( ) Conditional statement ( ) Bi-conditional statement ( ): Let p and q be propositions. The biconditional

### 1 Propositional Logic

1 Propositional Logic Propositions 1.1 Definition A declarative sentence is a sentence that declares a fact or facts. Example 1 The earth is spherical. 7 + 1 = 6 + 2 x 2 > 0 for all real numbers x. 1 =

### Definition 10. A proposition is a statement either true or false, but not both.

Chapter 2 Propositional Logic Contrariwise, continued Tweedledee, 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. (Lewis Carroll, Alice s Adventures

### DISCRETE MATHEMATICS W W L CHEN

DISCRETE MATHEMATICS W W L CHEN c W W L Chen, 1982, 2008. This chapter originates from material used by the author at Imperial College, University of London, between 1981 and 1990. It is available free

### DISCRETE MATH: LECTURE 4

DISCRETE MATH: LECTURE 4 DR. DANIEL FREEMAN 1. Chapter 3.1 Predicates and Quantified Statements I A predicate is a sentence that contains a finite number of variables and becomes a statement when specific

### Inference in propositional logic

C 1571 Introduction to AI Lecture 13 Inference in propositional logic Milos Hauskrecht milos@cs.pitt.edu 5329 ennott quare Logical inference problem Logical inference problem: Given: a knowledge base KB

### Chapter 1. Logic and Proof

Chapter 1. Logic and Proof 1.1 Remark: A little over 100 years ago, it was found that some mathematical proofs contained paradoxes, and these paradoxes could be used to prove statements that were known

### Chapter 1 LOGIC AND PROOF

Chapter 1 LOGIC AND PROOF To be able to understand mathematics and mathematical arguments, it is necessary to have a solid understanding of logic and the way in which known facts can be combined to prove

### Likewise, we have contradictions: formulas that can only be false, e.g. (p p).

CHAPTER 4. STATEMENT LOGIC 59 The rightmost column of this truth table contains instances of T and instances of F. Notice that there are no degrees of contingency. If both values are possible, the formula

### Propositional logic: Horn clauses

ecture 6 ropositional logic: Horn clauses ilos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square dministration Homework assignment 2 ropositional logic exercises rogramming a resolution solver ogical inference

### Boolean or Propositional Logic

Boolean or Propositional Logic SET07106 Mathematics for Software Engineering School of Computing Edinburgh Napier University Module Leader: Uta Priss 2010 Copyright Edinburgh Napier University Boolean

### 31 is a prime number is a mathematical statement (which happens to be true).

Chapter 1 Mathematical Logic In its most basic form, Mathematics is the practice of assigning truth to welldefined statements. In this course, we will develop the skills to use known true statements to

### Section 1. Statements and Truth Tables. Definition 1.1: A mathematical statement is a declarative sentence that is true or false, but not both.

M3210 Supplemental Notes: Basic Logic Concepts In this course we will examine statements about mathematical concepts and relationships between these concepts (definitions, theorems). We will also consider

### Exam 1 Answers: Logic and Proof

Q250 FALL 2012, INDIANA UNIVERSITY Exam 1 Answers: Logic and Proof September 17, 2012 Instructions: Please answer each question completely, and show all of your work. Partial credit will be awarded where

### Integers and division

CS 441 Discrete Mathematics for CS Lecture 12 Integers and division Milos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square Symmetric matrix Definition: A square matrix A is called symmetric if A = A T.

### Artificial Intelligence Automated Reasoning

Artificial Intelligence Automated Reasoning Andrea Torsello Automated Reasoning Very important area of AI research Reasoning usually means deductive reasoning New facts are deduced logically from old ones

### CS 2336 Discrete Mathematics

CS 2336 Discrete Mathematics Lecture 2 Logic: Predicate Calculus 1 Outline Predicates Quantifiers Binding Applications Logical Equivalences 2 Predicates In mathematics arguments, we will often see sentences

### Inference Rules and Proof Methods

Inference Rules and Proof Methods Winter 2010 Introduction Rules of Inference and Formal Proofs Proofs in mathematics are valid arguments that establish the truth of mathematical statements. An argument

### CSI 2101 Discrete Structures Winter 2012

CSI 2101 Discrete Structures Winter 2012 Prof. Lucia Moura University of Ottawa Homework Assignment #1 (100 points, weight 5%) Due: Thursday Feb 9, at 1:00 p.m. (in lecture); assignments with lateness

### The Foundations: Logic and Proofs. Chapter 1, Part III: Proofs

The Foundations: Logic and Proofs Chapter 1, Part III: Proofs Rules of Inference Section 1.6 Section Summary Valid Arguments Inference Rules for Propositional Logic Using Rules of Inference to Build Arguments

### Logic and Proofs. Chapter 1

Section 1.0 1.0.1 Chapter 1 Logic and Proofs 1.1 Propositional Logic 1.2 Propositional Equivalences 1.3 Predicates and Quantifiers 1.4 Nested Quantifiers 1.5 Rules of Inference 1.6 Introduction to Proofs

### Math 3000 Section 003 Intro to Abstract Math Homework 2

Math 3000 Section 003 Intro to Abstract Math Homework 2 Department of Mathematical and Statistical Sciences University of Colorado Denver, Spring 2012 Solutions (February 13, 2012) Please note that these

### 1.4/1.5 Predicates and Quantifiers

1.4/1.5 Predicates and Quantifiers Can we express the following statement in propositional logic? Every computer has a CPU No Outline: Predicates Quantifiers Domain of Predicate Translation: Natural Languauge

### Statements, negations, connectives, truth tables, equivalent statements, De Morgan s Laws, arguments, Euler diagrams

Logic Statements, negations, connectives, truth tables, equivalent statements, De Morgan s Laws, arguments, Euler diagrams Part 1: Statements, Negations, and Quantified Statements A statement is a sentence

### Undergraduate Notes in Mathematics. Arkansas Tech University Department of Mathematics. Introductory Notes in Discrete Mathematics

Undergraduate Notes in Mathematics Arkansas Tech University Department of Mathematics Introductory Notes in Discrete Mathematics Marcel B. Finan c All Rights Reserved Last Updated April 6, 2016 Preface

### Computing Science 272 Solutions to Midterm Examination I Tuesday February 8, 2005

Computing Science 272 Solutions to Midterm Examination I Tuesday February 8, 2005 Department of Computing Science University of Alberta Question 1. 8 = 2+2+2+2 pts (a) How many 16-bit strings contain exactly

### 1.5 Arguments & Rules of Inference

1.5 Arguments & Rules of Inference Tools for establishing the truth of statements Argument involving a seuence of propositions (premises followed by a conclusion) Premises 1. If you have a current password,

### CS 441 Discrete Mathematics for CS Lecture 16. Counting. CS 441 Discrete mathematics for CS. Course administration

CS 44 Discrete Mathematics for CS Lecture 6 Counting Milos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square Course administration Midterm exam: Thursday, March 6, 24 Homework assignment 8: due after Spring

### Mathematical induction & Recursion

CS 441 Discrete Mathematics for CS Lecture 15 Mathematical induction & Recursion Milos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square Proofs Basic proof methods: Direct, Indirect, Contradiction, By Cases,

### CHAPTER 2. Logic. 1. Logic Definitions. Notation: Variables are used to represent propositions. The most common variables used are p, q, and r.

CHAPTER 2 Logic 1. Logic Definitions 1.1. Propositions. Definition 1.1.1. A proposition is a declarative sentence that is either true (denoted either T or 1) or false (denoted either F or 0). Notation:

### 2. Methods of Proof Types of Proofs. Suppose we wish to prove an implication p q. Here are some strategies we have available to try.

2. METHODS OF PROOF 69 2. Methods of Proof 2.1. Types of Proofs. Suppose we wish to prove an implication p q. Here are some strategies we have available to try. Trivial Proof: If we know q is true then

### Discrete Mathematics and Probability Theory Fall 2009 Satish Rao, David Tse Note 1

CS 70 Discrete Mathematics and Probability Theory Fall 2009 Satish Rao, David Tse Note 1 Course Outline CS70 is a course on Discrete Mathematics and Probability for EECS Students. The purpose of the course

### Sets and set operations

CS 441 Discrete Mathematics for CS Lecture 7 Sets and set operations Milos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square asic discrete structures Discrete math = study of the discrete structures used

### What is logic? Propositional Logic. Negation. Propositions. This is a contentious question! We will play it safe, and stick to:

Propositional Logic This lecture marks the start of a new section of the course. In the last few lectures, we have had to reason formally about concepts. This lecture introduces the mathematical language

### Logic in Computer Science: Logic Gates

Logic in Computer Science: Logic Gates Lila Kari The University of Western Ontario Logic in Computer Science: Logic Gates CS2209, Applied Logic for Computer Science 1 / 49 Logic and bit operations Computers

### Mathematical Induction

Mathematical Induction Victor Adamchik Fall of 2005 Lecture 2 (out of three) Plan 1. Strong Induction 2. Faulty Inductions 3. Induction and the Least Element Principal Strong Induction Fibonacci Numbers

Lecture Notes in Discrete Mathematics Marcel B. Finan Arkansas Tech University c All Rights Reserved 2 Preface This book is designed for a one semester course in discrete mathematics for sophomore or junior

### WUCT121. Discrete Mathematics. Logic

WUCT121 Discrete Mathematics Logic 1. Logic 2. Predicate Logic 3. Proofs 4. Set Theory 5. Relations and Functions WUCT121 Logic 1 Section 1. Logic 1.1. Introduction. In developing a mathematical theory,

### Logic, Sets, and Proofs

Logic, Sets, and Proofs David A. Cox and Catherine C. McGeoch Amherst College 1 Logic Logical Statements. A logical statement is a mathematical statement that is either true or false. Here we denote logical

### Math 55: Discrete Mathematics

Math 55: Discrete Mathematics UC Berkeley, Fall 2011 Homework # 1, due Wedneday, January 25 1.1.10 Let p and q be the propositions The election is decided and The votes have been counted, respectively.

### Discrete Mathematics and Probability Theory Fall 2009 Satish Rao, David Tse Note 2

CS 70 Discrete Mathematics and Probability Theory Fall 2009 Satish Rao, David Tse Note 2 Proofs Intuitively, the concept of proof should already be familiar We all like to assert things, and few of us

### Chapter 2 Logic Unit Math 114

Chapter 2 Logic Unit Math 114 Section 2.1 Deductive and Induction Reasoning Statements Definition: A statement is a group of words or symbols that can be classified as true or false. Examples of statements

### Propositional Logic. 'Fun and games... detail from The Secret Player' - René Magritte

Propositional Logic 01/17/13 'Fun and games... detail from The Secret Player' - René Magritte Discrete Structures (CS 173) Derek Hoiem, University of Illinois Real-world Problem: Textual Entailment Textual

### Part A Course Outline

University of Macau Faculty of Science and Technology Department of Computer and Information Science Department of Electrical and Computer Engineering CISB111/ECEB222 Discrete Structures Syllabus 2 nd

### Foundations of Artificial Intelligence

Foundations of Artificial Intelligence 7. Propositional Logic Rational Thinking, Logic, Resolution Wolfram Burgard, Bernhard Nebel and Martin Riedmiller Albert-Ludwigs-Universität Freiburg Contents 1 Agents

### A set is a Many that allows itself to be thought of as a One. (Georg Cantor)

Chapter 4 Set Theory A set is a Many that allows itself to be thought of as a One. (Georg Cantor) In the previous chapters, we have often encountered sets, for example, prime numbers form a set, domains

### WOLLONGONG COLLEGE AUSTRALIA. Diploma in Information Technology

First Name: Family Name: Student Number: Class/Tutorial: WOLLONGONG COLLEGE AUSTRALIA A College of the University of Wollongong Diploma in Information Technology Mid-Session Test Summer Session 008-00

### 1. Use the following truth table to answer the questions.

Topic 3: Logic 3.3 Introduction to Symbolic Logic Negation and Conjunction Disjunction and Exclusive Disjunction 3.4 Implication and Equivalence Disjunction and Exclusive Disjunction Truth Tables 3.5 Inverse,

### MATH 55: HOMEWORK #2 SOLUTIONS

MATH 55: HOMEWORK # SOLUTIONS ERIC PETERSON * 1. SECTION 1.5: NESTED QUANTIFIERS 1.1. Problem 1.5.8. Determine the truth value of each of these statements if the domain of each variable consists of all

### 1.5 Rules of Inference

1.5 Rules of Inference (Inference: decision/conclusion by evidence/reasoning) Introduction Proofs are valid arguments that establish the truth of statements. An argument is a sequence of statements that

### DISCRETE MATH: LECTURE 3

DISCRETE MATH: LECTURE 3 DR. DANIEL FREEMAN 1. Chapter 2.2 Conditional Statements If p and q are statement variables, the conditional of q by p is If p then q or p implies q and is denoted p q. It is false

### Integers: applications, base conversions.

CS 441 Discrete Mathematics for CS Lecture 14 Integers: applications, base conversions. Milos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square Modular arithmetic in CS Modular arithmetic and congruencies

### 15-381: Artificial Intelligence. Probabilistic Reasoning and Inference

5-38: Artificial Intelligence robabilistic Reasoning and Inference Advantages of probabilistic reasoning Appropriate for complex, uncertain, environments - Will it rain tomorrow? Applies naturally to many

### Even Number: An integer n is said to be even if it has the form n = 2k for some integer k. That is, n is even if and only if n divisible by 2.

MATH 337 Proofs Dr. Neal, WKU This entire course requires you to write proper mathematical proofs. All proofs should be written elegantly in a formal mathematical style. Complete sentences of explanation

### Fundamentals of Mathematics Lecture 6: Propositional Logic

Fundamentals of Mathematics Lecture 6: Propositional Logic Guan-Shieng Huang National Chi Nan University, Taiwan Spring, 2008 1 / 39 Connectives Propositional Connectives I 1 Negation: (not A) A A T F

### Proof: A logical argument establishing the truth of the theorem given the truth of the axioms and any previously proven theorems.

Math 232 - Discrete Math 2.1 Direct Proofs and Counterexamples Notes Axiom: Proposition that is assumed to be true. Proof: A logical argument establishing the truth of the theorem given the truth of the

### Jeff Wickstrom Jason Slattery Discrete Mathematics - Logic. Lesson Plans. Discrete Mathematics

Jeff Wickstrom Jason Slattery Discrete Mathematics - Logic Lesson Plans Discrete Mathematics Discrete mathematics, also called finite mathematics, is the study of mathematical structures that are fundamentally

### Introduction to Proofs

Chapter 1 Introduction to Proofs 1.1 Preview of Proof This section previews many of the key ideas of proof and cites [in brackets] the sections where they are discussed thoroughly. All of these ideas are

### Direct Proofs. CS 19: Discrete Mathematics. Direct Proof: Example. Indirect Proof: Example. Proofs by Contradiction and by Mathematical Induction

Direct Proofs CS 19: Discrete Mathematics Amit Chakrabarti Proofs by Contradiction and by Mathematical Induction At this point, we have seen a few examples of mathematical proofs. These have the following

### Predicate Logic. Lucia Moura. Winter Predicates and Quantifiers Nested Quantifiers Using Predicate Calculus

Predicate Logic Winter 2010 Predicates A Predicate is a declarative sentence whose true/false value depends on one or more variables. The statement x is greater than 3 has two parts: the subject: x is

### Predicate logic Proofs Artificial intelligence. Predicate logic. SET07106 Mathematics for Software Engineering

Predicate logic SET07106 Mathematics for Software Engineering School of Computing Edinburgh Napier University Module Leader: Uta Priss 2010 Copyright Edinburgh Napier University Predicate logic Slide 1/24

### Rules of Inference Friday, January 18, 2013 Chittu Tripathy Lecture 05

Rules of Inference Today s Menu Rules of Inference Quantifiers: Universal and Existential Nesting of Quantifiers Applications Old Example Re-Revisited Our Old Example: Suppose we have: All human beings

### Deductive Systems. Marco Piastra. Artificial Intelligence. Artificial Intelligence - A.A Deductive Systems [1]

Artificial Intelligence Deductive Systems Marco Piastra Artificial Intelligence - A.A. 2012- Deductive Systems 1] Symbolic calculus? A wff is entailed by a set of wff iff every model of is also model of

### Florida State University Course Notes MAD 2104 Discrete Mathematics I

Florida State University Course Notes MAD 2104 Discrete Mathematics I Florida State University Tallahassee, Florida 32306-4510 Copyright c 2011 Florida State University Written by Dr. John Bryant and Dr.

### CS 2710 Foundations of AI. Lecture 12. Inference in FOL. CS 2710 Foundations of AI. Optimization competition winners.

Lecture 12 Inference in FOL Milos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square Optimization competition winners CS2710 Homework 3 Simulated annealing 1. Valko Michal 2. Zhang Yue 3. Villamarin Ricardo

### 1.2 Truth and Sentential Logic

Chapter 1 Mathematical Logic 13 69. Assume that B has m left parentheses and m right parentheses and that C has n left parentheses and n right parentheses. How many left parentheses appear in (B C)? How

### Resolution in Propositional and First-Order Logic

Resolution in Propositional and First-Order Logic Inference rules Logical inference creates new sentences that logically follow from a set of sentences (KB) An inference rule is sound if every sentence

### Elementary Number Theory and Methods of Proof. CSE 215, Foundations of Computer Science Stony Brook University http://www.cs.stonybrook.

Elementary Number Theory and Methods of Proof CSE 215, Foundations of Computer Science Stony Brook University http://www.cs.stonybrook.edu/~cse215 1 Number theory Properties: 2 Properties of integers (whole

### def: An axiom is a statement that is assumed to be true, or in the case of a mathematical system, is used to specify the system.

Section 1.5 Methods of Proof 1.5.1 1.5 METHODS OF PROOF Some forms of argument ( valid ) never lead from correct statements to an incorrect. Some other forms of argument ( fallacies ) can lead from true

### INTRODUCTION TO PROOFS: HOMEWORK SOLUTIONS

INTRODUCTION TO PROOFS: HOMEWORK SOLUTIONS STEVEN HEILMAN Contents 1. Homework 1 1 2. Homework 2 6 3. Homework 3 10 4. Homework 4 16 5. Homework 5 19 6. Homework 6 21 7. Homework 7 25 8. Homework 8 28

### Definition of Statement: A group words or symbols that can be classified as true or false.

Logic Math 116 Section 3.1 Logic and Statements Statements Definition of Statement: A group words or symbols that can be classified as true or false. Examples of statements Violets are blue Five is a natural

### CSE 459/598: Logic for Computer Scientists (Spring 2012)

CSE 459/598: Logic for Computer Scientists (Spring 2012) Time and Place: T Th 10:30-11:45 a.m., M1-09 Instructor: Joohyung Lee (joolee@asu.edu) Instructor s Office Hours: T Th 4:30-5:30 p.m. and by appointment

### The Importance of discrete mathematics in computer science

The Importance of discrete mathematics in computer science Exemplified by deductive logic and Boolean algebra By Mathias Schilling BSc Computing, Birkbeck, University of London Preface Discrete mathematics

### The Predicate Calculus in AI

Last time, we: The Predicate Calculus in AI Motivated the use of Logic as a representational language for AI (Can derive new facts syntactically - simply by pushing symbols around) Described propositional

### AI Principles, Semester 2, Week 2, Lecture 4 Introduction to Logic Thinking, reasoning and deductive logic Validity of arguments, Soundness of

AI Principles, Semester 2, Week 2, Lecture 4 Introduction to Logic Thinking, reasoning and deductive logic Validity of arguments, Soundness of arguments Formal systems Axioms, Inference, and Proof Propositional

### Predicates and Quantifiers. Niloufar Shafiei

Predicates and Quantifiers Niloufar Shafiei Review Proposition: 1. It is a sentence that declares a fact. 2. It is either true or false, but not both. Examples: 2 + 1 = 3. True Proposition Toronto is the

### Applications of Methods of Proof

CHAPTER 4 Applications of Methods of Proof 1. Set Operations 1.1. Set Operations. The set-theoretic operations, intersection, union, and complementation, defined in Chapter 1.1 Introduction to Sets are

### Decision making in the presence of uncertainty II

CS 274 Knowledge representation Lecture 23 Decision making in the presence of uncertainty II Milos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square Information-gathering actions Many actions and their

### CHAPTER 7 GENERAL PROOF SYSTEMS

CHAPTER 7 GENERAL PROOF SYSTEMS 1 Introduction Proof systems are built to prove statements. They can be thought as an inference machine with special statements, called provable statements, or sometimes

### CS510 Software Engineering

CS510 Software Engineering Propositional Logic Asst. Prof. Mathias Payer Department of Computer Science Purdue University TA: Scott A. Carr Slides inspired by Xiangyu Zhang http://nebelwelt.net/teaching/15-cs510-se

### MAT2400 Analysis I. A brief introduction to proofs, sets, and functions

MAT2400 Analysis I A brief introduction to proofs, sets, and functions In Analysis I there is a lot of manipulations with sets and functions. It is probably also the first course where you have to take