4.
Propositions are elementary atomic sentences. Propositions may be either true or false but may take no other value. P|R|Q…..(Propositional Symbols) True | False (Logical Constants) Sentence Connective Sentence Connective : &|V | |
5.
A Logic is a formal language, in which knowledge can be expressed , with precisely defined syntax and semantics, which supports sound inference. Logic is independent of domain of application.
6.
Need of Propositional Logic :
Logic offers the only formal approach to reasoning.
It’s structure is flexible enough to permit the accurate representation of natural language.
It is widely accepted by workers in AI as one of the most powerful representation method.
7.
Propositional logic :
In general a propositional logic is defined by :
Syntax: what expressions are allowed in the language.
Semantics: what they mean, in terms of a mapping to real world
Inference rules: how we can draw new conclusions from existing statements in the logic.
8.
Syntax
9.
Syntax of Propositional logic :
A set of propositional symbols used to represent facts about the world, e.g., P, Q, R, …(atomic propositions)
“ P” represents the fact “Ram likes chocolate”
“ Q” represents the fact “Ram has chocolate”
Parenthesis (for grouping): ( )
Logical constants: True, False
10.
A set of logical connectives
AND / CONJUNCTION OR / DISJUNCTION NOT / NEGATION IF…..THEN / IMPLICATION IF AND ONLY IF / DOUBLE IMPLICATION
11.
Semantics
12.
Semantics of Propositional Logic :
What does it all mean?
Sentences in propositional logic tell us about what is true or false.
P ∧ Q means that both P and Q are true.
P ∨ Q means that either P or Q is true (or both)
P ⇒Q means that if P is true, so is Q.
13.
This is all formally defined using truth tables. P Q ~P Negation P & Q Conjunction P V Q Disjunction P -> Q Implication P<->Q Double Implication True True False True True True True True False False False True False False False True True False True True False False False True False False True True
14.
An interpretation for a sentence or group of sentences is an assignment of a truth value to each propositional symbol.
For instance consider the statement :
((P & ~ Q) R) V Q
Interpretation (I 1 ):
P = True
Q = False (implies that ~ Q = True)
R = False
15.
((P & ~ Q) R) V Q
16.
17.
Modes ponens
This rule states that :
from P
,and P Q
infer Q
For instance :
given : (Joe is a father)
and : (Joe is a father) (Joe has a child)
infer : (Joe has a child)
18.
Chain Rule
This rule states that :
from P Q
and, Q R
infer P R
For instance
given :( If it’s sunny) (the ground is dry)
and : (If the ground is dry) (we can party)
infer : (If it’s sunny ) (we can party)
19.
Substitution :
This rule states that :
If s is a valid sentence , s’ derived from s by consistent substitution of propositions in s , then s’ is also a valid sentence.
For instance :
s : I live in Nangal.
s’: Tamanna lives in Nangal.
Consistent Substitution
20.
Simplification :
It states that : From P & Q infer P
For instance:
(P & Q) : Today is Monday and day after tomorrow will be Wednesday.
infer : Today is Monday.
21.
Conjunction : It states that :
From P
and , From Q
infer P & Q
For instance
P : I tried to speak Spanish
Q : My friend tried to speak English.
infer : I tried to speak Spanish, and my friend tried to speak English.
22.
Transposition : It states that :
From P Q
infer ~ P ~ Q
For instance :
(P Q) : If you have good marks, then you are eligible for scholarship.
( ~ P ~ Q) : If you don’t have good marks , then you are not eligible for scholarship.
23.
Summary
PROPOSITIONAL LOGIC Represents facts as being either true or false.
Syntax : what expressions are allowed in the language.
Semantics : what they mean, in terms of a mapping to real world
Inference rules : how we can draw new conclusions from existing statements in the logic.