EM214_Logic_part 2
EM214_Logic_part 2
EM214_Logic_part 2
Class Notes
Dr. R. Palamakumbura
Propositional Logic
• In the part 1 of the lecture notes, we studied symbols, syntax
and semantic on propositional logic.
Next we will evaluate the truth values of these and see which
of them are logically equivalent to p → q .
Propositional Logic
• Examples:
1.
• Propositional satisfiability:
- A compound proposition is satisfiable if there is an assignment of
the truth values to its variables that makes it true. When no such
assignment exist then it is unsatisfiable.
• Normal Forms:
It is easier to work with the logical connectives ∨ , ∧ , ⌝
and such wffs are called Normal forms.
There are two such normal forms.
• Note:
Using the following logical equivalences it is possible to transform
any compound proposition to CNF or DNF.
1.Remove the implication:
p ↔ q ≡ (p → q) ∧ (q → p)
p → q ≡ ⌝p ∨ q
2. (q ∨ (p ∧ r)) → (q ∨ ⌝p)
≡ ⌝(q ∨ (p ∧ r)) ∨ (q ∨ ⌝p) Eliminate implication
≡ ⌝q ∧ ⌝(p ∧ r)) ∨ (q ∨ ⌝p) De Morgan′s
≡ (⌝q ∧ (⌝p ∨ ⌝r)) ∨ (q ∨ ⌝p) De Morgan′s
≡ (⌝q ∨ (q ∨ ⌝p)) ∧ ((⌝p ∨ ⌝r) ∨ (q ∨ ⌝p)) Distributive law
≡ (⌝q ∨ q ∨ ⌝p) ∧ (⌝p ∨ ⌝r ∨ q ∨ ⌝p) Flatten the disjunction
≡ T ∧ (⌝p ∨ ⌝r ∨ q)
≡ ⌝p ∨ ⌝r ∨ q
Propositional Logic
• Validity of an Argument:
Validity:
The argument is valid if the conclusion ( final statement) follows
from the truth of the preceding statements (premises). That is an
argument is valid if the premises are all true then the conclusion is
true.
Suppose p1, ⋯, pn are premises and q is the conclusion. Then the
argument is valid when p1 ∧ ⋯ ∧ pn → q is a tautology.
Propositional Logic
• Validity of an Argument:
Examples:
1.If you have a valid password then you can log onto the network.
p: You have a valid password
q: You can log onto the network
Therefore the argument is, p→q
p
q
2. It will be sunny or cloudy today. It isn’t sunny. Therefore it will be cloudy.
3.Look for all the rows where the premises are true. These are
called critical rows. If the conclusion is false in a critical row
then the argument is invalid otherwise valid.
Propositional Logic
Inference Rules:
Clausal Form:
• Note:
Example: p ∧ (q → r) ≡ p ∧ (⌝q ∨ r) .
• Propositional resolution:
• Propositional resolution:
{p, q}
The Rule: {p, q}, {⌝q, r} or {⌝q, r}
{p, r} {p, r}
Idea:
Since q must be either true or false then it must be the case that either p is true or r
is true. That is {p, r} .
Propositional Logic
• Note:
• Note:
• Resolution reasoning:
• Resolution Proof:
2. Determine validity of the argument: The meeting can take place if all members
are informed in advance and there is quorum (a minimum number of members
are present). There is a quorum if at least 15 members are present. Members
would have been informed in advance if there was no postal strike.Therefore, if
the meeting was canceled, then either there were fewer than 15 members present
or there was a postal strike.