Presentation is loading. Please wait.

Presentation is loading. Please wait.

Lecture for Week 6 2012 Spring.   Introduction to Propositional Logic  Types of Proposition  Operator and Truth table Agenda.

Similar presentations


Presentation on theme: "Lecture for Week 6 2012 Spring.   Introduction to Propositional Logic  Types of Proposition  Operator and Truth table Agenda."— Presentation transcript:

1 Lecture for Week 6 2012 Spring

2   Introduction to Propositional Logic  Types of Proposition  Operator and Truth table Agenda

3  Logic is the discipline which is concerned with reasoning. It provides rules and methods for determining the validity of a given argument. The argument itself is a sequence of statements, or propositions, one of which is the conclusion and the others, called premises, are intended to justify the conclusion.  All English people are Europeans.  George Boole was English.  Therefore George Boole was a European. This is an argument in which the two premises “all English people are European” and “George Boole was English” are intended to support the conclusion “George Boole was a European”. Hence, logical reasoning concludes based on certain statements. The fundamental objects in logic are propositions. Logic

4  A proposition is a sentence which is either true or false but not both. True (T) or false (F) is called the truth value of the proposition. For example: 1. Kathmandu is a city. 2. Java is a programming language. 3. Paper is made of glass. Proposition

5  Consider the following sentences: i)Everest is the highest mountain in the world. ii)The Thames is the longest river in the world. iii)A  B = B  A. iv)2 + 3 = 4. v)It will rain on the first day of the new millennium. vi)He is thirty years old. vii)1 + x = 7. viii)Newton contributed more to our understanding of science than Einstein did. ix)How old are you? x)Take the key with you. Proposition

6  The first four are clearly propositions. They evaluate without ambiguity to T, F, T, F respectively. We can accept v) as a proposition since eventually we will be able to assign a unique truth value to it. As it stands vi) is not a proposition since its truth value depends on who ‘he’ is. Taken in the context of a conversation amongst people who clearly understood the identity of ‘he’ it would be acceptable. The truth value of vii) depends on the value of x. It would be true if x = 6 but false it x = 2. Consequently, vii) is not proposition. Proposition

7  Sentences for which the truth value is a matter of opinion (as in viii) are not acceptable as propositions. Questions and commands cannot be given a truth value and so ix) and x) are not propositions. Sentences that are “Questions”, “Commands” and “Opinions” are not valid propositions because they will/may not have a true or false value. Proposition

8  Examples: 1. How old are you? 2. Go to School. 3. He is tall. Some examples of valid propositions 1. Kathmandu is the capital of Nepal. 2. There are 8 days in a week. 3. Isaac Newton was born in 1642. 4. 5 is greater than 7. Proposition

9  In mathematics x, y, z, … denote numerical variables. They represent numbers (let x=3) and can be combined using addition, multiplication and division to form expressions and equations. In logic we use lower case letters p, q, r, … to denote propositional variables, which represent propositions. For example: p: C++ is a high-level language means let p represent the proposition “C++ is a high-level language”. Notation

10  p: Kathmandu is in either Nepal or UK. This proposition is made up of two simpler propositions. This evaluates unambiguously to true and so is a proposition. However it is made up of two ‘simpler’ propositions q: Kathmandu is in Nepal. r: Kathmandu is in UK. Joined together by the word “or” Primitive and compound propositions

11  The propositions q and r cannot themselves be broken down into simpler ones. Such propositions are called primitive. Propositions like p which are combinations of two or more simpler ones are called compound, while the linking word ‘or’ is an example of what we will call a connective. Primitive and compound propositions

12  Three operations on prepositions are: 1.Conjunction/ AND 2.Disjunction/OR and 3.Negation/NOT/Complement Operations on propositions

13  When two simple statement are combined by the word “and” the compound statement so formed is called the conjunction of the original statement. Let p and q be given propositions. The proposition ‘p and q’ is called the conjunction of the given propositions. It is written p  q and read “p and q”. p  q is true if both proposition p is true and proposition q is true. Otherwise p  q is false. Conjunction/AND

14  Example. p: Kathmandu is the capital of Nepal. q: Delhi is the capital of India. p and q: Kathmandu is the capital of Nepal and Delhi is the capital of India. p ∧ q is called the conjunction of two propositions. Conjunction/AND

15  This is called the conjunction of the two propositions p, q. It is written p  q and read as “p and q”. “and” is called a logical connective. The word “and” which links the two propositions is called a logical connective. Conjunction/AND

16  The truth table for conjunction is pq pqpq TTT TFF FTF FFF

17  Let p and q be given propositions. The proposition ‘p or q’ is called the disjunction of the given propositions. It is written p  q and read “p or q”. If p  q is true if either p is true or q is true or both p and q are true. Otherwise p  q is false. Disjunction/OR

18  Example p: Kathmandu is the capital of Nepal. q: Delhi is the capital of China. p or q: Kathmandu is the capital of Nepal or Delhi is the capital of China. p ∨ q is called the disjunction of the two propositions p and q. It is written p  q and read “p or q”. In this case the connective linking the two propositions is “or”. Disjunction/OR

19  There is no difficulty with the truth value of p  q. This evaluates to true since one of the propositions, p, is true. Similarly, for p  r, q  s and r  s are all true as in each case, one and only one, of the individual propositions is true. Equally, since both q and r are false, so too is q  r. Disjunction/OR

20  The truth table for disjunction is Disjunction/OR pq pqpq TTT TFT FTT FFF

21  Notes: i)The definition of p  q uses the connective ‘or’ in the inclusive sense. That is, p  q is true if either of the propositions p, q are true or both are. ii) An alternative equivalent definition of the disjunctive p  q is : p  q is false if both p is false and q is false. Otherwise p  q is true. Disjunction/OR

22  Let p be any proposition. The proposition ‘not p’ or ‘it is not true that p’ is called the negation of p. It is written ¬ p and read “not p”. ¬ p is true if p is false ¬ p is false if p is true. The Negation of a Proposition

23  If p is any proposition we can form a new proposition called the negation of p, or not p, by writing “it is not true that” or “it is not the case that” (or something similar) in front of p. This new proposition is written ¬ p and read “not p”. Example: p : Stockholm is the capital of Sweden. The negation of the given statement is ¬ p : Stockholm is not the capital of Sweden. The Negation of a Proposition

24  The truth table for Negation is The Negation of a Proposition p pp TF FT

25  1.The propositions p, q, r and s have truth values T, F, F and T respectively. Find the truth value for the following 1. p  ¬ q 2. q  ¬ r 3. ¬ s  q 4. ¬ p  r 5. ¬ q  ¬ r Practice problem

26  1. “and”, “or” and “¬” are referred to as connectives. 2. In formal logic, even if there is no relationship between the primitive propositions, it will make up a compound proposition. Example: if p : 3 + 6 = 5 and q : Delhi is the capital of Nepal then p ∧ q : 3 + 6 = 5 and Delhi is the capital of Nepal p V ¬ q : 3 + 6 = 5 or Delhi is not the capital of Nepal are both valid propositions. They evaluate to “F” and “T” respectively. Notes…

27  What is the truth value of each of the following propositions? a)2 is even and 3 is even. b)2 is even or 3 is even. c)2 is even or 3 is odd. d)2 is not even or 3 is even. e)(1<0) ∨ (2<1) f)(0<1) ∨ (2<1) g)p ∧ (false ∧ q) Practice problem..

28  A compound proposition is an expression P(p, q, r,...), which consists of propositional variables p, q, r,... joined together by the logical connectives ∧, V and ¬. The propositional variables p, q,... are sometimes called the arguments of P. Compound Propositions

29  When there are more than one logical connectives, their operation can be determined by using braces. For example: (p ∨ q) ∧ r means first evaluate w = (p ∨ q) and then evaluate w ∧ r. Compound Propositions

30  Example: p: Kathmandu is the capital of Nepal. T q: Delhi is the capital of China. F r: Tokyo is the capital of Pakistan. F Then (p ∨ q) ∧ r is false but p ∨ (q ∧ r) is true. Compound Propositions

31  To minimize the number of brackets in expressions we will adopt the following order of precedence in which connectives are applied. 1. Apply connectives within brackets first. 2. The ¬ connective next. 3. “and” and “or”. Using this convention ¬ p ∧ q will mean (¬ p) ∧ q rather than ¬ (p ∧ q) Rules..

32  Example 3 Suppose p : Stockholm is the capital of Sweden.T q : London is the capital of France.F r : Paris is the capital of England.F Then find the truth value of 1. w = p  q and w  r. 2. z = q  r and p  z. Thus find the truth value of (p  q)  r and p  (q  r). Practice problem..

33  ? Happy Sunday Any Questions…


Download ppt "Lecture for Week 6 2012 Spring.   Introduction to Propositional Logic  Types of Proposition  Operator and Truth table Agenda."

Similar presentations


Ads by Google