Conditional Statements CS 2312, Discrete Structures II Poorvi L. Vora, GW.

Slides:



Advertisements
Similar presentations
With examples from Number Theory
Advertisements

Discrete Math Methods of proof 1.
Introduction to Proofs
PROOF BY CONTRADICTION
Chapter 3 Elementary Number Theory and Methods of Proof.
(CSC 102) Lecture 12 Discrete Structures. Previous Lecture Summary Floor and Ceiling Functions Definition of Proof Methods of Proof Direct Proof Disproving.
CSE115/ENGR160 Discrete Mathematics 01/31/12 Ming-Hsuan Yang UC Merced 1.
CSE115/ENGR160 Discrete Mathematics 02/01/11
Logic: Connectives AND OR NOT P Q (P ^ Q) T F P Q (P v Q) T F P ~P T F
CMSC 250 Discrete Structures Number Theory. 20 June 2007Number Theory2 Exactly one car in the plant has color H( a ) := “ a has color”  x  Cars –H(
So far we have learned about:
EE1J2 - Slide 1 EE1J2 – Discrete Maths Lecture 12 Number theory Mathematical induction Proof by induction Examples.
Proof by Deduction. Deductions and Formal Proofs A deduction is a sequence of logic statements, each of which is known or assumed to be true A formal.
Introduction to Proofs ch. 1.6, pg. 87,93 Muhammad Arief download dari
Introduction to Proofs Goals 1.Introduce notion of proof & basic proof methods. 2.Distinguish between correct & incorrect arguments 3.Understand & construct.
EE1J2 – Discrete Maths Lecture 5 Analysis of arguments (continued) More example proofs Formalisation of arguments in natural language Proof by contradiction.
Mathematical Induction Assume that we are given an infinite supply of stamps of two different denominations, 3 cents and and 5 cents. Prove using mathematical.
Adapted from Discrete Math
Propositional Logic.
Methods of Proof & Proof Strategies
MATERI II PROPOSISI. 2 Tautology and Contradiction Definition A tautology is a statement form that is always true. A statement whose form is a tautology.
Discrete Mathematics and Its Applications
Introduction to Proofs
1 Methods of Proof CS/APMA 202 Epp, chapter 3 Aaron Bloomfield.
Proofs 1/25/12.
Copyright © Cengage Learning. All rights reserved. CHAPTER 4 ELEMENTARY NUMBER THEORY AND METHODS OF PROOF ELEMENTARY NUMBER THEORY AND METHODS OF PROOF.
Review I Rosen , 3.1 Know your definitions!
Proofs1 Elementary Discrete Mathematics Jim Skon.
Standard Is the equation 3(2 x – 4) = −18 equivalent to 6 x − 12 = −18? a)Yes, the equations are equivalent by the Associative Property of Multiplication.
Methods of Proofs PREDICATE LOGIC The “Quantifiers” and are known as predicate quantifiers. " means for all and means there exists. Example 1: If we.
1 Section 1.1 A Proof Primer A proof is a demonstration that some statement is true. We normally demonstrate proofs by writing English sentences mixed.
10/17/2015 Prepared by Dr.Saad Alabbad1 CS100 : Discrete Structures Proof Techniques(1) Dr.Saad Alabbad Department of Computer Science
1 Sections 1.5 & 3.1 Methods of Proof / Proof Strategy.
Methods of Proof Lecture 3: Sep 9. This Lecture Now we have learnt the basics in logic. We are going to apply the logical rules in proving mathematical.
Slides for CISC 2315: Discrete Structures Chapters CISC 2315 Discrete Structures Professor William G. Tanner, Jr. SPRING 2010 Slides created by James.
Conditional Statements Lesson 2-1. Conditional Statements have two parts: Hypothesis ( denoted by p) and Conclusion ( denoted by q)
1 CMSC 250 Discrete Structures CMSC 250 Lecture 1.
P. 270 #47-49.
1 Discrete Structures – CNS2300 Text Discrete Mathematics and Its Applications Kenneth H. Rosen (5 th Edition) Chapter 3 The Foundations: Logic and Proof,
Chapter 2 Logic 2.1 Statements 2.2 The Negation of a Statement 2.3 The Disjunction and Conjunction of Statements 2.4 The Implication 2.5 More on Implications.
Methods of Proof for Boolean Logic Chapter 5 Language, Proof and Logic.
CS104:Discrete Structures Chapter 2: Proof Techniques.
Week 4 - Friday.  What did we talk about last time?  Floor and ceiling  Proof by contradiction.
Section 1.7. Definitions A theorem is a statement that can be shown to be true using: definitions other theorems axioms (statements which are given as.
EXAMPLE 3 Write an indirect proof Write an indirect proof that an odd number is not divisible by 4. GIVEN : x is an odd number. PROVE : x is not divisible.
Notions & Notations - 1ICOM 4075 (Fall 2010) UPRM Department of Electrical and Computer Engineering University of Puerto Rico at Mayagüez Fall 2010 ICOM.
Section 1.7. Section Summary Mathematical Proofs Forms of Theorems Direct Proofs Indirect Proofs Proof of the Contrapositive Proof by Contradiction.
Chapter 1 Logic and proofs
Proof Techniques CS160/CS122 Rosen: 1.5, 1.6, 1.7.
Introduction to Proofs Goals 1.Introduce notion of proof & basic proof methods. 2.Distinguish between correct & incorrect arguments 3.Understand & construct.
Chapter 1 Logic and Proof.
Indirect Argument: Contradiction and Contraposition
2. The Logic of Compound Statements Summary
3. The Logic of Quantified Statements Summary
CSE15 Discrete Mathematics 02/01/17
CISC 2315 Discrete Structures
Direct Proof by Contraposition Direct Proof by Contradiction
COMP 1380 Discrete Structures I Thompson Rivers University
Methods of Proof CS 202 Epp, chapter 3.
Conditional Statements
Indirect Proof by Contradiction Direct Proof by Cases
CS 220: Discrete Structures and their Applications
Propositional Logic.
Elementary Number Theory & Proofs
The most important idea in logic: Validity of an argument.
COMP 1380 Discrete Structures I Thompson Rivers University
Copyright © Cengage Learning. All rights reserved.
Foundations of Discrete Mathematics
More Conditional Statements
Conditional Statements Section 2.3 GEOMETRY
Presentation transcript:

Conditional Statements CS 2312, Discrete Structures II Poorvi L. Vora, GW

Conditional Statement A implies B A => B If A then B A is the hypothesis; B the conclusion Example: If x is a prime larger than 2 then x is odd A: “x is a prime number larger than 2” B: “x is odd” Generally, the truth of the conditional statement is a function of one or more variables; in this case, x. This example statement is true for all values of x.

Truth value a function of variables Generally speaking, the truth value of a statement depends on variables. For example, consider the inequality: 0 ≤ n 3 ≤ Bn 2 – Whether it is true or not depends on the values of the variables: n and B – There are quite likely value of n and B for which it is true, as well as values for which it is false

 : for every Consider a modification of the previous example: 0 ≤ n 3 ≤ Bn 2  n ≥ b The truth value of this inequality is now a function of B and b On fixing b and B, If it is untrue for a single value of n ≥ b then the statement is false If it is true  n ≥ b then it is true Thus the truth is not dependent on n

Counterexample Sometimes you may have statement that is false: x is divisible by 4  even integers x The way to show it is false is to show that the statement is not true “  even integers x” one even integer for which it is false is enough. However, this does not mean that x is not divisible by 4  even integers x

Counterexample, contd The statement “x is divisible by 4” is sometimes true and sometimes false Thus neither of the statements below is true, because there are counterexamples for both: x is divisible by 4  even integers x x is not divisible by 4  even integers x

 : There exists Sometimes you may be asked to show that there exist values of variables such that a statement is true. Continuing the previous example:  B, b > 0 such that 0 ≤ n 3 ≤ Bn 2  n ≥ b One way of proving above is to find one value of b, B and show that the inequality is true for these values.

How  and  and change a statement Consider the statement: “x is divisible by 6” Its truth depends on the value of x Adding  or  can eliminate the dependence on x to allow you to say definitively whether the statement is true or false:  x such that x divisible by 6: True  odd x such that x is divisible by 6: False x is divisible by 6  integers x that are multiples of 12: True x is divisible by 6  integers x: False

The truth table of A=>B We want to know the truth value of A => B Note: statement makes no claims when A is false. – when A is false, the statement is true independent of the value of B

Negation or Counterexample Examining the statement A(x) => B(x)  x (where both A and B are functions of x) – If you think it is true, you need to provide a proof. Begin with the assumption A(x) is true and show B(x) is true. – If you think it is false, you could provide a counterexample. Exactly one example of the variable which makes A true but B false. Notice that providing an example where B is true but A false gives you nothing at all – because the statement is making no claims when A is false. don’t care

A Counterexample Suppose you are presented with the conditional statement:  integers x, if 2 divides x then 4 divides x What is a valid counterexample? Are there values of x for which the statement is true?

Converse Given: A => B The converse is B => A Does it follow? Example: If x is a prime larger than 2 then x is odd What is the converse? Does it follow?

Proving the converse does not prove the main statement Suppose you have to show A => B And you begin with B to show A You have not shown A => B You have shown B => A

Examples of incorrect proofs To show that If 2 divides x, then 4 divides x (this is not true, but examples of incorrect proofs will conclude it is) Example 1: Suppose 4 divides x. Then x = 4q (for q the quotient when 4 divides x). Hence x is even and 2 divides x. Incorrect! Why?

Examples of incorrect proofs, contd. To show that If 2 divides x, then 4 divides x (this is not true, but examples of incorrect proofs will conclude it is) Example 2: Suppose 2 divides x. Then x = 2q 1 Suppose 4 divides x. Then x = 4q 2 x = x => 2q 1 = 4q 2 => q 1 = 2q 2 LHS = RHS Incorrect! Why?

Contrapositive One can show A=> B by assuming A is true and showing that then B is true OR by assuming that B is not true and showing that then A is not true. That is, by showing: not B => not A Which is the contrapositive Which is logically equivalent to A => B

Why is the contrapositive equivalent to the original statement? ABA => Bnot B => not A TTTT TFFF FTTT FFTT Consider the truth table

Inverse not A => not B Is this related to the original statement? The converse? The contrapositive? It is the contrapositive of the converse

Summary Conditional Statement: A => B – Converse: B => A – Contrapositive: not B => not A – Inverse: not A => not B – Counterexample: an example of A and not B

Necessary and Sufficient A => B A sufficient for B B => A A necessary for B A B A is necessary and sufficient for B B is necessary and sufficient for A

Bidirectional If and only if (iff) If A then B AND If B then A A B A iff B A and B are equivalent statements

False Premise, Valid Argument, False Conclusion Claim: If = 0 then 2=0 Proof: Begin with correct statement: 2 = => 2 = (0+1)+1 = 0+1=0

Valid Premise, Invalid Argument, Valid Conclusion gives zero credit Assume: If 4 divides x then 2 divides x Show that 4 divides 16 Invalid proof: 2 divides 16. Hence, applying assumption, 4 divides 16.

Proof by Contradiction To show A=> B Recall, if A is not true, you cannot determine anything. Assume A is true. Suppose B is not. Then show there is a contradiction. That is, B has to be true.