Predicate Calculus Presentation and Predicate Calculus presentation

DrVenkateshRamanna 0 views 33 slides Oct 29, 2025
Slide 1
Slide 1 of 33
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10
Slide 11
11
Slide 12
12
Slide 13
13
Slide 14
14
Slide 15
15
Slide 16
16
Slide 17
17
Slide 18
18
Slide 19
19
Slide 20
20
Slide 21
21
Slide 22
22
Slide 23
23
Slide 24
24
Slide 25
25
Slide 26
26
Slide 27
27
Slide 28
28
Slide 29
29
Slide 30
30
Slide 31
31
Slide 32
32
Slide 33
33

About This Presentation

Predicate Calculus


Slide Content

1
The Predicate Calculus
2.0Introduction
2.1 The Propositional Calculus
2.2The Predicate Calculus
2.3Using Inference Rules to Produce Predicate Calculus
Expressions
2.4 Logic Based Financial Advisor
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

2
knowledge representation scheme is
a)to capture the essential features of
problem domain, and
b)make that information accessible to a
problem-solving procedure.
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

3
A representation scheme should:
a)Be adequate to express all of the
necessary information.
b)Support efficient execution of the
resulting code.
c)Provide a natural scheme for expressing
the required knowledge.
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

4
The Propositional Calculus
•Propositional symbols denote propositions,
i.e., statements about the world that may be
either true or false.
•Legal sentences are called well-formed
formulas or WFFs.
•Only expressions that are formed of legal
symbols through some sequence of the
above rules are well-formed formulas.
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

5
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

6
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

7
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

8
For propositional expressions P, Q and R:
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

9
Figure 2.1: Truth table for the operator .
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

10
Figure 2.2: Truth table demonstrating the equivalence of P, Q and related.
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

11
The Predicate Calculus
•It is a basic representation language.
•Its advantages include a well-defined
formal semantics and sound and complete
inference rules.
•It provides the way to access the
components of an individual proposition.
•It allows expressions to contain variables
which may refer to classes of entities.
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

12
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

13
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

14
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

15
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

16
verify_sentence algorithm
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

17
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

18
•Predicate calculus semantics provide a formal
basis for determining the truth value of well-
formed expressions.
•Quantifications introduce problems in
computation:
a) Exhaustive testing of all substitutions to a universally
quantified variable is computationally impossible,
therefore the predicate calculus is said to be undecidable.
b) Evaluating the truth of an expression containing an
existentially quantified variable may be no easier than
evaluating the truth of expressions containing universally
quantified variables.
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

19
•First-order predicate calculus allows
quantified variables to refer to objects in the
domain of discourse, and not to predicate or
functions.
•Almost any grammatically correct English
sentence may be represented in first-order
predicate calculus.
•The limitation of the predicate calculus is
that it is difficult to represent possibility,
time, and belief.
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

CS3754 Class Notes AI#2, By John
Shieh
20
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

14/02/12 CS3754 Class Notes AI#2, By John
Shieh
21
Figure 2.3: A blocks world with its predicate calculate description.
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

14/02/12 CS3754 Class Notes AI#2, By John
Shieh
22
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

23
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

24
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

25
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

26
Unification
•It is an algorithm for determining the
substitutions needed to make two predicate
calculus expressions match.
•A variable cannot be unified with a term
containing that variable. The test for it is
called the occurs check.
e.g., X cannot unify with F(X, b)
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

27
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

28
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

EXAMPLE: FIND MGU FOR THE FOLLOWING PAIRS OF TERMS:
1.f(g(X), W) and f(Y, V)
The mgu is {Y=g(X), V=W}
2. f(g(X), W) and f(X, W)
No mgu.
3. f(a, Y, g(X, Y, Z), t(Y, Z)) and f(a, W, g(b, V, a),
t(c, a))
The mgu is {V=c, W=c, X=b, Y=c, Z=a}
4. p(X, Y, t(a, b, c)) and p(g(a, Y), f(b), t(Z, b, c))
The mgu is {X=g(a, f(b)), Y=f(b), Z=a}
29
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

30
Figure 2.5: Further steps in the unification of (parents X (father X) (mother
bill)) and (parents bill (father bill) Y).
11
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

CS3754 Class Notes AI#2, By John
Shieh
31
Figure 2.6: Final trace of the unification of (parents X (father X)
(mother bill)) and (parents bill (father bill) Y).
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

32
A Logic-Based Financial Advisor
•Adequacy:
–At least $5000 in the bank for each dependent
–A steady income: at least $15,000/year +
$4,000/dependent
•Investment:
–Saving account
–Stocks
–blend
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru

33
10/29/25 Prof. Venkatesh, CSE Dept., UVCE , Bengaluru