0% found this document useful (0 votes)
90 views87 pages

Module 1 DSGT

Propositional logic is the simplest form of logic that represents statements as propositions that can be either true or false. It uses logical connectives like negation, conjunction, disjunction, implication, and bi-conditional to combine propositions into compound statements. Propositional logic represents knowledge in a symbolic, logical form. Truth tables are used to determine the truth values of compound propositions under all possible combinations of the component propositions being true or false.

Uploaded by

thakur.sami2804
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
90 views87 pages

Module 1 DSGT

Propositional logic is the simplest form of logic that represents statements as propositions that can be either true or false. It uses logical connectives like negation, conjunction, disjunction, implication, and bi-conditional to combine propositions into compound statements. Propositional logic represents knowledge in a symbolic, logical form. Truth tables are used to determine the truth values of compound propositions under all possible combinations of the component propositions being true or false.

Uploaded by

thakur.sami2804
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 87

MODULE 1

LOGIC
Propositional logic in Artificial intelligence

• Propositional logic (PL) is the simplest form of logic where all the statements
are made by propositions. A proposition is a declarative statement which is
either true or false. It is a technique of knowledge representation in logical
and mathematical form.
• Example:
• a) It is Sunday.
• b) The Sun rises from West (False proposition)
• c) 3+3= 7(False proposition)
• d) 5 is a prime number.
Following are some basic facts about propositional logic
• Propositional logic is also called Boolean logic as it works on 0 and 1.
• In propositional logic, we use symbolic variables to represent the logic, and we can
use any symbol for a representing a proposition, such A, B, C, P, Q, R, etc.
• Propositions can be either true or false, but it cannot be both.
• Propositional logic consists of an object, relations or function, and logical
connectives.
• These connectives are also called logical operators.
• The propositions and connectives are the basic elements of the propositional logic.
• Connectives can be said as a logical operator which connects two sentences.
• A proposition formula which is always true is called tautology, and it is also called a
valid sentence.
• A proposition formula which is always false is called Contradiction.
• A proposition formula which has both true and false values is called contingency
• Statements which are questions, commands, or opinions are not propositions such
as "Where is Rohini", "How are you", "What is your name", are not propositions.
Syntax of propositional logic:
• The syntax of propositional logic defines the allowable sentences for the
knowledge representation. There are two types of Propositions:
• Atomic Propositions
• Compound propositions

• Atomic Proposition: Atomic propositions are the simple propositions. It


consists of a single proposition symbol. These are the sentences which must
be either true or false.
• Example:
• a) 2+2 is 4, it is an atomic proposition as it is a true fact.
• b) "The Sun is cold" is also a proposition as it is a false fact.
• 2: Compound proposition: Compound propositions are constructed
by combining simpler or atomic propositions, using parenthesis and
logical connectives.

• Example:
1.a) "It is raining today, and street is wet."
2.b) "Ankit is a doctor, and his clinic is in Mumbai
Logical Connectives:

• Logical connectives are used to connect two simpler propositions or


representing a sentence logically. We can create compound propositions with
the help of logical connectives. There are mainly five connectives, which are
given as follows:

• 1: Negation: A sentence such as ¬ P is called negation of P. A literal can be


either Positive literal or negative literal.

• 2: Conjunction: A sentence which has ∧ connective such as, P ∧ Q is called a


conjunction.
Example: Rohan is intelligent and hardworking. It can be written as,
P= Rohan is intelligent,
Q= Rohan is hardworking. → P∧ Q.
• Disjunction: A sentence which has ∨ connective, such as P ∨ Q. is called
disjunction, where P and Q are the propositions.
E.G: "Ritika is a doctor or Engineer",
Here P= Ritika is Doctor. Q= Ritika is Engineer, so we can write it as P ∨ Q.

• Implication: A sentence such as P → Q, is called an implication. Implications are


also known as if-then rules. It can be represented as
E.G If it is raining, then the street is wet.
Let P= It is raining, and Q= Street is wet, so it is represented as P → Q

• Bi-conditional: A sentence such as P⇔ Q is a Biconditional sentence,


• E.G If I am breathing, then I am alive.
P= I am breathing, Q= I am alive, it can be represented as P ⇔ Q.
1: Negation: A sentence such as ¬ P is called negation of P. A
literal can be either Positive literal or negative literal.

• It means the opposite of the original statement. If p is a statement, then the


negation of p is denoted by ~p and read as 'it is not the case that p.' So, if p is
true then ~ p is false and vice versa.

• Example: If statement p is Paris is in France, then ~ p is 'Paris is not in France'.


p ~p

T F

F T
2: Conjunction: A sentence which has ∧ connective such as, P ∧ Q is called a conjunction.
Example: Rohan is intelligent and hardworking. It can be written as,
P= Rohan is intelligent,
Q= Rohan is hardworking. → P∧ Q .
• It means Anding of two statements. If p, q are two statements, then "p and q"
is a compound statement, denoted by p ∧ q and referred as the conjunction of
p and q. The conjunction of p and q is true only when both p and q are true.
Otherwise, it is false.
p q p∧q

T T T

T F F

F T F

F F F
Disjunction:
A sentence which has ∨ connective, such as P ∨ Q. is called disjunction, where P and Q are
the propositions.
E.G: "Ritika is a doctor or Engineer",
Here P= Ritika is Doctor. Q= Ritika is Doctor, so we can write it as P ∨ Q.

• It means Oring of two statements. If p, q are two statements, then "p or q" is a
compound statement, denoted by p ∨ q and referred to as the disjunction of p
and q. The disjunction of p and q is true whenever at least one of the two
statements is true, and it is false only when both p and q are false.
p q p∨q

T T T

T F T

F T T

F F F
Implication: A sentence such as P → Q, is called an implication. Implications are also known as if-then
rules. It can be represented as
E.G If it is raining, then the street is wet.
Let P= It is raining, and Q= Street is wet, so it is represented as P → Q

• An implication p⟶q is the proposition "if p, then q." It is false if p is true and q
is false. The rest cases are true.
p q p⟶q

T T T

T F F

F T T

F F T
Bi-conditional: A sentence such as P⇔ Q is a Biconditional sentence,
E.G If I am breathing, then I am alive.
P= I am breathing, Q= I am alive, it can be represented as P ⇔ Q.

• p ↔ q is bi-conditional logical connective which is true when p and q are same,


i.e., both are false or both are true.
p q p↔q

T T T

T F F

F T F

F F T
Tautologies , Contradiction and Contingency:
• 1:Tautologies
• A proposition P is a tautology if it is true under all circumstances. It means it
contains the only T in the final column of its truth table.
• Example: Prove that the statement (p⟶q) ↔(∼q⟶∼p) is a tautology
• Solution: Make the truth table of the above statement:
p q p→q ~q ~p ~q⟶∼p (p→q)⟷(
~q⟶~p)

T T T F F T T

T F F T F F T

F T T F T T T

F F T T T T T
• 2: Contradiction:
• A statement that is always false is known as a contradiction.
• Example: Show that the statement p ∧∼p is a contradiction.
• Solution:
p ∼p p ∧∼p

T F F

F T F
• 3: Contingency:
• A statement that can be either true or false depending on the truth values of its
variables is called a contingency.

p q p →q p∧q (p →q)⟶ (p∧q )

T T T T T

T F F F T

F T T F F

F F T F F
Inverse, Converse, and Contra-positive
• If there is a conditional statement x → y, then
• The converse statement will be y → x
• The inverse statement will be ∼x → ∼y
• The contrapositive statement will be ∼y → ∼x
• Consider p: You stay in Mumbai
• q= You visit Hotel Taj Land.
• Determine converse, inverse and contrapositive of p →q. i.e If you stay in
Mumbai, you visit Hotel Taj Land.
• 1: converse ( q → p): “ If you visit Hotel Taj Land you stay in Mumbai”.

• 2: contrapositive( ∼q → ∼p): “If you do not visit Hotel Taj Land, then you do
not stay in Mumbai”.

• 3:inverse (∼p → ∼q): “If you do not visit stay in Mumbai, then you will not
visit Hotel Taj Land ”.
Following is the summarized table for Propositional Logic
Connectives:
Truth Table

• In propositional logic, we need to know the truth values of propositions in all


possible scenarios. We can combine all the possible combination with logical
connectives, and the representation of these combinations in a tabular format is
called Truth table. Following are the truth table for all logical connectives:
Truth table with three propositions:
We can build a proposition composing three propositions P, Q, and R. This truth table is made-up of 8n Tuples as we have taken

three proposition symbols .


Precedence of connectives
• Just like arithmetic operators, there is a precedence order for propositional
connectors or logical operators. This order should be followed while evaluating a
propositional problem. Following is the list of the precedence order for
operators:
Precedence Operators

First Precedence Parenthesis

Second Precedence Negation

Third Precedence Conjunction(AND)

Fourth Precedence Disjunction(OR)

Fifth Precedence Implication

Six Precedence Bi-conditional


Logical equivalence:
• Logical equivalence is one of the features of propositional logic. Two
propositions are said to be logically equivalent if and only if the columns in the
truth table are identical to each other.
• Let's take two propositions A and B, so for logical equivalence, we can write it as
A⇔B. In below truth table we can see that column for ¬A∨ B and A→B, are
identical hence A is Equivalent to B.
Properties of Operators/Laws Of Logic
1: Commutativity: 7: Absorption Law
• P∧ Q= Q ∧ P, or • P ∨ (P ∧ Q ) =P or
• P ∨ Q = Q ∨ P. • P∧ (P ∨ Q)= P,
2: Associativity: 8: Complement Law
• (P ∧ Q) ∧ R= P ∧ (Q ∧ R), • P ∨ ¬ P =T or
• (P ∨ Q) ∨ R= P ∨ (Q ∨ R) • P∧ ¬ P = F,
3: Identity Law: 9: Involution Law
• P ∧ True = P, OR P ∧ F=F • ¬ ¬ P =P
• P ∨ True= True. P ∨ F=P 10: Idempotence Law
4: Distributive: • P ∨ P =P or
• P∧ (Q ∨ R) = (P ∧ Q) ∨ (P ∧ R). • P∧ P = P,
• P ∨ (Q ∧ R) = (P ∨ Q) ∧ (P ∨ R). 11: Properties of 0
5: DE Morgan's Law: • 0 ∨ P =P or
• ¬ (P ∧ Q) = (¬P) ∨ (¬Q) • 0∧ P = 0,
• ¬ (P ∨ Q) = (¬ P) ∧ (¬Q). 12: Properties of 1
6: Double-negation elimination: • 1 ∨ P =1 or
• ¬ (¬P) = P. • 1∧ P = P,
Laws of Logical Equivalence:
In this law, we will use the 'AND' and 'OR' symbols to explain the
law of logical equivalence. Here, AND is indicated with the help of ∧ symbol and OR is indicated with the
help of ∨ symbol. There are various laws of logical equivalence, which are described as follows:

• Idempotent Law: In the idempotent law, we only use a single statement. According to this law, if
we combine two same statements with the symbol ∧(and) and ∨(or), then the resultant statement will be the
statement itself. Suppose there is a compound statement P. The following notation is used to indicate the
idempotent law:
1. P ∨ P = P
2. P ∧ P = P
3. The truth table for this law is described as follows:
P P P∨P P∧P

T T T T

F F F F
Commutative Laws:
The two statements are used to show the commutative law. According to this law, if we combine two
statements with the symbol ∧(and) or ∨(or), then the resultant statement will be the same even if we
change the position of the statements. Suppose there are two statements, P and Q. The proposition of
these statements will be false when both statements P and Q are false. In all the other cases, it will be true.
The following notation is used to indicate the commutative law:
P∨Q=Q∨P
P∧Q=Q∧P
• The truth table for these notations is described as follows:
P Q P∨Q Q∨P

T T T T

T F T T

F T T T

F F F F
Associative Law:
The three statements are used to show the associative law. According to this law, if we combine three
statements with the help of brackets by the symbol ∧(and) or ∨(or), then the resultant statement will be the same even if we
change the order of brackets. That means this law is independent of grouping or association. Suppose there are three
statements P, Q and R. The proposition of these statements will be false when P, Q and R are false. In all the other cases, it
will be true. The following notation is used to indicate the associative law:
P ∨ (Q ∨ R) = (P ∨ Q) ∨ R
P ∧ (Q ∧ R) = (P ∧ Q) ∧ R

• The truth table for these notations is described as follows:


P Q R P∨Q Q∨R (P ∨ Q) ∨ R P ∨ (Q ∨ R)

T T T T T T T
T T F T T T T
T F T T T T T
T F F T F T T
F T T T T T T
F T F T T T T
F F T F T T T
Distributive Law:
The three statements are used to show the distributive law. According to this
law, if we combine a statement by the ∨(OR) symbol with the two other statements which are
joined with the symbol ∧(AND), then the resultant statement will be the same even if we are
separately combining the statements with the symbol ∨(OR) and combining the joined
statements with ∧(AND). Suppose there are three statements P, Q and R. The following notation
is used to indicate the distributive law:
P ∨ (Q ∧ R) = (P ∨ Q) ∧ (P ∨ R)
P ∧ (Q ∨ R) = (P ∧ Q) ∨ (P ∧ R)
P Q R Q∧R P∨(Q ∧R) P∨Q P∨R (P ∨ Q) ∧ (P ∨ R)

T T T T T T T T
T T F F T T T T
T F T F T T T T
T F F F T T T T
F T T T T T T T
F T F F F T F F
F F T F F F T F
F F F F F F F F
Identity Law:
A single statement is used to show the identity law. According to this law, if we combine a statement and a True
value with the symbol ∨(or), then it will generate the True value. If we combine a statement and a False value with the symbol
∧(and), then it will generate the statement itself. Similarly, we will do this with the opposite symbols. That means if we
combine a statement and a True value with the symbol ∧(and), then it will generate the statement itself, and if we combine a
statement and a False value with the symbol ∨(or), then it will generate the False value. Suppose there is a compound
statement P, a true value T and a false value F. The following notation is used to indicate the identity law:

P ∨ T = T and P ∨ F = P
P ∧ T = P and P ∧ F = F

• The truth table for these notations is described as follows:


P T F P∨T P∨F

T T F T T

F T F T F
Complement Law:

A Single statement is used in the complement law. According to this law, if we combine a statement with its complement
statement with the symbol ∨(or), then it will generate the True value, and if we combine these statements with the symbol
∧(and), then it will generate the False value. If we negate a true value, then it will generate a false value, and if we negate a
false value, then it will generate the true value.

The following notation is used to indicate the complement law:

P ∨ ¬P = T and P ∧ ¬P = F
¬T = F and ¬F = T

• The truth table for these notations is described as follows:


P ¬P T ¬T F ¬F P ∨ ¬P P ∧ ¬P

T F T F F T T F

F T T F F T T F
Double Negation Law or Involution Law
A single statement is used to show the double negation law. According to this law, if we do the
negation of a negated statement, then the resultant statement will be the statement itself.
Suppose there is a statement P and a negate statement ¬P. The following notation is used to
indicate the Double negation law:
¬(¬P) ?=P
• The truth table for these notations is described as follows:

P ¬P ¬(¬P)

T F T

F T F
De Morgan's Law:
The two statements are used to show De Morgan's law. According to this law, if we combine two
statements with the symbol ∧(AND) and then do the negation of these combined statements,
then the resultant statement will be the same even if we combine the negation of both
statements separately with the symbol ∨(OR). Suppose there are two compound statements, P
and Q. The following notation is used to indicate De Morgan's Law:
¬(P ∧ Q) = ¬P ∨ ¬Q
¬(P ∨ Q) = ¬P ∧ ¬Q
• The truth table for these notations is described as follows:
P Q ¬P ¬Q P∧Q ¬(P ∧ Q) ¬ P ∨ ¬Q

T T F F T F F

T F F T F T T

F T T F F T T

F F T T F T T
Absorption Law:
The two statements are used to show the absorption law. According to this law, if we combine a statement P by
∨(OR) symbol with the same statement P and one other statement Q, which are joined with the symbol ∧(AND),
then the resultant statement will be the first statement P. The same result will be generated if we interchange the
symbols. Suppose there are two compound statements, P and Q. The following notation is used to indicate the
Absorption Law:
P ∨ (P ∧ Q) = P
P ∧ (P ∨ Q) = P

• The truth table for these notations is described as follows:


P Q P∧Q P∨Q P ∨ (P ∧ Q) P ∧ (P ∨ Q)

T T T T T T

T F F T T T

F T F T F F

F F F F F F
Predicate Logic
• A predicate is an expression of one or more variables defined on some specific
domain. A predicate with variables can be made a proposition by either
assigning a value to the variable or by quantifying the variable.
• E.g 1: The Ball’s color is Red
• a= The Ball’s color is Red ( Proposition Logic)
• Color ( Ball’s , Red) (Predicate logic)

• Where, Color is Predicate or Relation


• and Ball’s , Red is Argument or Objects
• E.g 2: Rohan likes Bananas
• likes( Rohan , Bananas).
• E.g 3
• All Students are intelligent
• Rohan is a students
• Rohan is Intelligent = Inference
Quantifiers
• A Quantifiers are words that refer to quantities such as “some” or “all”. It tells
for how many elements a given predicate is True.
• Quantifiers are used to express the quantities without giving an exact number.
• Ex: all, some, many, none, few etc
• Sentence like :- “ Can I have some water?”
• “ Jack has many friends here”.

• These are two types of quantifier:


• 1: Universal Quantifiers(for all, everyone , everything)
• 2: Existential Quantifiers(for some, atleast one)
Quantifiers
• Consider the following statements or propositions
• All Birds have wings.
• Some men are tall.
• No air balloon is perfectly round
• For every Integer x, x^2 is non-negative integer.
• There exists a real number whose sequence is equal to itself.
• The above statements involve certain words : “All”,
• “Some”, “ No one”, “ There exists”, “ every” , that are associated with the idea of
a “Quantity”. Such words are called “ QUANTIFIERS”.
There are two types of Quantifiers:

1: Universal Quantifiers
2: Existential Quantifiers

• 1: Universal Quantifiers: The quantifier “All” is called Universal Quantifier and it is denoted by ‘∀’.
Or
Universal quantifier states that the statements within its scope are true for every value of the specific
variable.

• The symbol ∀ represents the following phrases have same meaning.


• If x is a variable , then ∀x is read as
• For all x, For every x, For each x, Every thing x and Each thing x.

∀xP(x) is read as for every value of x, P(x) is true.

• Example − "Man is mortal" can be transformed into the propositional form ∀xP(x)
• where P(x) is the predicate which denotes x is mortal
• 2: Existential Quantifiers: The quantifier “Some ” is called Existential
Quantifier and it is denoted by ‘∃’.
or
Existential quantifier states that the statements within its scope are true for
some values of the specific variable.
• The symbol ∃ represents the following phrases have same meaning.
• There exists, There is at least and There is an.
• ∃xP(x) is read as for some values of x, P(x) is true.

• Example − "Some people are dishonest" can be transformed into the


propositional form ∃xP(x) where P(x) is the predicate which denotes x is
dishonest and the universe of discourse is some people.
3: Nested Quantifiers
• If we use a quantifier that appears within the scope of another quantifier, it is
called nested quantifier.
Normal forms
• The problem of finding whether a given statement is tautology or contradiction
or satisfiable in a finite number of steps is called the Decision Problem.
• For Decision Problem, construction of truth table may not be practical always.
We consider an alternate procedure known as the reduction to normal forms
• The standard forms are called normal form or canonical forms. There are two
types of normal form.
• 1: Disjunctive Normal form(DNF)
• 2: Conjunctive normal form(CNF)

• Elementary Product:- A product of the variables and their negations in a


formula is called an elementary product.
• Ex: Let p and q be any two atomic variables, then ~ p∧ q, ~ q ∧p ∧ ~p, p ∧ ~ p
and q ∧ ~ p are some examples of elementary products.
• Elementary Sum:- A sum of the variables and their negations in a formula is
called an elementary sum.
• Ex: Let p and q be any two atomic variables, then ~ p∨q , ~ q ∨p ∨ ~p ,
p ∨ ~ p and q ∨ ~ p are some examples of elementary sum.
• Normal Forms: We can convert any proposition in two normal forms −
• 1. Disjunctive Normal Form (DNF)
• 2. Conjunctive Normal Form (CNF)
• Disjunctive Normal Form (DNF)-: A formula which is equivalent to a given
formula and consists of a sum of elementary products is called Disjunctive
Normal form of the given formula.
Conjunctive Normal Form (DNF)-: A formula which is equivalent to a given
formula and consists of a product of elementary sums is called
Conjunctive Normal form of the given formula.
Inference theory in Predicate Calculus
• The inference theory can be described as the analysis of validity of the formula
from the given set of premises.
Structure of an argument
• An argument can be defined as a sequence of statements. The argument is a
collection of premises and a conclusion. The conclusion is used to indicate the
last statement, and premises are used to indicate all the remaining statements.
Before the conclusion, the symbol ‘ ∴’ will be placed. The following syntax is used
to show the premises and conclusion:
Premises: p1, p2, p3, p4, ….., pn
Conclusion: q
• If (p1∧ p2 ∧ p3 ∧ p4 ∧ …… ∧ pn) → q indicates a tautalogy, in this case, the
argument will be termed as valid otherwise, it will be termed invalid/fallacy.
The following expression is used to show the argument:
1.First premises
2.Second premises
3.Third premises
4.Fourth premises
5..
6..
7.Nth premises
8.______________
9.∴ Conclusion
Valid Argument:
• A valid argument can be described as an argument where if all their premises are
true, then their conclusions will also be true.
• For example:
1."If tomorrow is holiday, I will go to mall."
2."If tomorrow is holiday".
3. ∴ "I will go to mall."
This argument belongs to a form that is described as follows:
P→Q
P
____________
∴Q

The above form is valid. It does not matter what propositions are substituted for the
variables. This type of form is known as the valid argument form. From the above
definition, if a valid argument form consists
Rules of Inference
• We can construct a more complicated valid argument with the help of using
simple arguments, which work as the building blocks. If we are talking about the
usage of arguments, then there are some simple arguments that have been
established as valid and very important. These types of arguments are known as
the Rules of inference. There are various types of Rules of inference, which are
described as follows:
1. Modus Ponens
• Suppose there are two premises, P and P → Q. Now, we will derive Q with the
help of Modules Ponens like this :
P→Q
P
____________
∴Q
• Example:
• Suppose P → Q = "If we have a bank account, then we can take advantage of this
new policy."
• P = "We have a bank account.“
• Therefore, Q = "We can take advantage of this new policy."
2. Modus Tollens
• Suppose there are two premises, P → Q and ¬Q. Now, we will derive ¬P with
the help of Modules Tollens like this:

P→Q
¬Q
____________
∴ ¬P
• Example:
• Suppose P → Q = "If we have a bank account, then we can take advantage of
this new policy."
• ¬Q = "We cannot take advantage of this new policy."
• Therefore, ¬P = "We don't have a bank account."
3. Hypothetical Syllogism
• Suppose there are two premises, P → Q and Q → R. Now, we will derive P → R
with the help of Hypothetical Syllogism like this:
P→Q
Q→R
____________
∴P→R
• Example:
• Suppose P → Q = "If my friends comes to meet me, I will not go to office."
• Q → R = "If I will not go to office, I won't require to do office work."
Therefore, P → R = "If my friends come to meet me, I won't require to do office
work."
4. Disjunction Syllogism

• Suppose there are two premises ¬P and P ∨ Q. Now, we will derive Q with the
help of Disjunction Syllogism like this:
¬P
P∨Q
____________
∴Q
Suppose ¬P = "Harry birthday cake is not strawberry flavored.“
• P ∨ Q = "The birthday cake is either red velvet flavored or mixed fruit flavored."
• Therefore, Q = "The birthday cake is mixed fruit flavored."
5. Addition

• Suppose there is a premise P. Now, we will derive P ∨ Q with the help of Addition
like this:
P
____________
∴P∨Q
• Example:
• Suppose P be the proposition, "Harry is a hard working employee" is true
• Here Q has the proposition, "Harry is a bad employee".
• Therefore, "Either Harry is a hard working employee Or Harry is a bad
employee".
6. Simplification:
• Suppose there is a premise P ∧ Q. Now, we will derive P with the help of
Simplification like this:
P∧Q
____________
∴P
• Example:
• Suppose P ∧ Q = "Harry is a hard working employee, and he is the best
employee in the office".
• Therefore, "Harry is a hard working employee".
7. Conjunction
• Suppose there are two premises P and Q. Now, we will derive P ∧ Q with the help of
conjunction like this:
P
Q
____________
∴P∧Q
• Example:
• Suppose P = "Harry is a hard working employee".
• Suppose Q = "Harry is the best employee in the office".
• Therefore, "Harry is a hard working employee and Harry is the best employee in the
office".

8. Resolution
• Suppose there are two premises P ∨ Q and ¬P ∨ R. Now, we will derive Q ∨ R
with the help of a resolution like this:
1.P ∨ Q
2.¬ P ∨ R
3.____________
4.∴ Q ∨ R
• Example:
• Suppose PV Q = "If my friends comes to meet me, I will not go to office".
• ¬ P ∨ R = "If my friends did not come to met me, I won't require to do office
work".
• Therefore, Q ∨ R = "Either I will not go to office or I won't require to do office
work".
9. Constructive Dilemma
• Suppose there are two premises (P → Q) ∧ (R → S) and P ∨ R. Now, we will
derive Q ∨ S with the help of a constructive dilemma like this:
1.(P → Q) ∧ (R → S)
2.P ∨ R
3.____________
4.∴ Q ∨ S
• Example:
• Suppose P → Q = "If my friend will come to meet me, I will not go to office".
• R → S = "If my relatives will come, I will tell my employees that I will come".
• P ∨ R = "Either my friends will comes to meet me or my relatives will come".
• Therefore, Q ∨ S = "Either I will not go to office or I will tell my employees that I
will come".
10. Destructive Dilemma
• Suppose there are two premises (P → Q) ∧ (R → S) and ¬Q ∨ ¬S. Now, we will derive
¬P ∨ ¬R with the help of a Destructive dilemma like this:
1.(P → Q) ∧ (R → S)
2.¬Q ∨ ¬S
3.____________
4.∴ ¬P ∨ ¬R
• Example:
• Suppose P → Q = "If my fiancé comes to meet me, I will not go to office".
• R → S = "If my relatives come, I will tell my employees that I will come".
• ¬Q ∨ ¬S = "Either I will go to office or I will tell my employees that I will not come".
• Therefore, ¬P ∨ ¬R = "Either my fiancé will not come to meet me or my relatives will
not come".
Rules of Inference with Quantifiers
• There are some other rules of inference with quantifier statements, which are
described as follows:
• 1. Universal Instantiation
• Suppose there is a premise ∀x P(x). Now, we will derive P(c) with the help of Universal
Instantiation like this:
1.∀x P(x)
2.____________
3.∴ P(c), for any c
• 2. Universal Generalization
• Suppose there is a premise P(c) for any arbitrary c. Now, we will derive ∀x P(x) with
the help of a Universal generalization like this:
1.P(c) for any arbitrary c
2.____________
3.∴ ∀x P(x)
• 3. Existential Instantiation
• Suppose there is a premise ∃x P(x). Now, we will derive P(c) for some element c
with the help of Existential Instantiation like this:
1.∃x P(x)
2.____________
3.∴ P(c), for some element c
• 4. Existential Generalization
• Suppose there is a premise P(c) for some element c. Now, we will derive ∃x P(x)
with the help of Existential generalization like this:
1.P(c) for some element c
2.____________
3.∴ ∃x P(x)
Mathematical Induction
• Mathematical induction is a concept in mathematics that is used to prove
various mathematical statements and theorems. The principle of
mathematical induction is sometimes referred to as PMI. It is a technique that
is used to prove the basic theorems in mathematics which involve the solution
up to n finite natural terms.
• OR
• Mathematical Induction is one of the fundamental methods of writing proofs
and it is used to prove a given statement about any well-organized set.
Generally, it is used for proving results or establishing statements that are
formulated in terms of n, where n is a natural number. Suppose P(n) is a
statement for n natural number then it can be proved using the Principle of
Mathematical Induction, Firstly we will prove for P(1) then let P(k) is true then
prove for P(k+1). If P(k+1) holds true then we say that P(n) is true by the
principle of mathematical induction.
Principle of Mathematical Induction Statement
Any statement P(n) which is for “n” natural number can be proved using the Principle of
Mathematical Induction by following the below steps,

• Step 1: Verify if the statement is true for trivial cases (n = 1) i.e. check if P(1) is
true.

• Step 2: Assume that the statement is true for n = k for some k ≥ 1 i.e. P(k) is
true.

• Step 3: If the truth of P(k) implies the truth of P(k + 1), then the statement P(n)
is true for all n ≥ 1.
• The image added below contains all the steps of Mathematical Induction
• The first statement is the fact and if it is not possible for all P(n) to
hold true at n = 1 then these statements are true for some other
values of n say n = 2, n = 3, and others.

• If the statement is true for P(k) then if P(k+1) is proven to be true


then we say that P(n) is true for all n belonging to Natural Numbers
(N)
Mathematical Induction Steps

• Various steps used in Mathematical Induction are named accordingly. The


names of the various steps used in the principle of mathematical induction
are,
• Base Step: Prove P(k) is true for k =1
• Assumption Step: Let P(k) is true for all k in N and k > 1
• Induction Step: Prove P(k+1) is true using basic mathematical properties.
• If the above three steps are proved then we can say that “By the principle of
mathematical induction, P(n) is true for all n belonging to N”.
EX: Show that 1+2+3+…….+n={n(n+1)}/2, by PMI, where n>=1

1. Basis: n=1
• 1={(1)(1+1)}/2
• 1={(1)(2)}/2
• 1=2/2
• 1=1
• Therefore, L.H.S=R.H.S
2. Induction Put n=k & Assume its true
1+2+3+….+k={k(k+1)}/2 say equation 1
3. Put n=k+1, show its true
1+2+3+….+(k+1)={(k+1)(k+1+1)}/2
1+2+3+….+k+(k+1)={(k+1)(k+1+1)}/2
Put equation 1
k(k+1)/2+(k+1)= )={(k+1)(k+1+1)}/2
• 2(k(k+1)/2)+(k+1)2 ={(k+1)(k+1+1)2}/2
• K(k+1)+2(k+1)=(k+1)(k+2)
• Take (k+1) common
• (k+1)(k+2)=(k+1)(k+2)
• Hence Proved
EX :1+2+2^2+….+2^n = 2^n+1-1 , where n>=0

• 1. Basis : Let n=0


• 1=2^0+1 -1
• 1= 2-1
• 1=1
• Therefore, L.H.S =R.H.S
• 2. Induction Let n=k, Assume its true
• 1+2+2^2+….+2^k = 2^k+1 -1 say equation 2
• Put n= k+1 & show its true
• 1+2+2^2+….+2^k+1 = 2^k+1+1 -1
• 1+2+2^2+….+2^k+ 2^k+1 = 2^k+2 -1
• Put equation 2
• (2^k+1)+( 2^k+1) = 2^k+2 -1
2^k+1 + 2^k+1 -1 = 2^k+2 -1
• 2^k+1 + 2^k+1 -1 = 2^k+2 -1
• Take common 2^k+1
• 2^k+1(1+1) -1 = 2^k+2 -1
• 2^k+1(2) -1 = 2^k+2 -1 base same and power multiply
• 2^k+1+1 -1 = 2^k+2 -1
• 2^k+2 -1 = 2^k+2 -1
• Hence Proved
Prove that n3 + 2n is always divisible by 3

Solution:
Let P(n): n3 + 2n is divisible by 3 be the given statement.

Step 1: Basic Step


Firstly we prove that P(1) is true. Let n = 1 in n3 + 2n
= 13 + 2(1)
=3
As 3 is divisible by 3. Hence, P(1) is true.

Step 2: Assumption Step


Let us assume that P(k) is true
Then, k3 + 2k is divisible by 3
Thus, we can write it as k3 + 2k = 3n, (where n is any positive integer)….(i)

Step 3: Induction Steps


Now we have to prove that algebraic expression (k + 1)3 + 2(k + 1) is divisible by 3
= (k + 1)3 + 2(k + 1)
= k3 + 3k2 + 5k + 3
= (k3 + 2 k) + (3k2 + 3k + 3)
from eq(i)
= 3n + 3(k2 + k + 1)
= 3(n + k2 + k + 1)
As it is a multiple of 3 we can say that it is divisible by 3.
Thus, P(k+1) is true i.e. (k + 1)3 + 2(k + 1) is be divisible by 3.
Now by the Principle of Mathematical Induction, we can say that, P(n): n 3 + 2n is divisible by 3 is true.
Limitations of Propositional logic

• We cannot represent relations like ALL, some, or none with propositional logic.
Example:
• All the girls are intelligent.
• Some apples are sweet.
• Propositional logic has limited expressive power.
• In propositional logic, we cannot describe statements in terms of their
properties or logical relationships.

You might also like