- Trending Categories
- Data Structure
- Networking
- RDBMS
- Operating System
- Java
- iOS
- HTML
- CSS
- Android
- Python
- C Programming
- C++
- C#
- MongoDB
- MySQL
- Javascript
- PHP

- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who

# The Predicate Calculus

Predicate Calculus deals with predicates, which are propositions containing variables.

## Predicate

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.

Consider the following statement.

Ram is a student.

Now consider the above statement in terms of Predicate calculus.

Here "is a student" is a predicate and Ram is subject.

Let's denote "Ram" as x and "is a student" as a predicate P then we can write the above statement as P(x).

Generally a statement expressed by Predicate must have at least one object associated with Predicate. In our case, Ram is the required object with associated with predicate P.

## Statement Function

Earlier we denoted "Ram" as x and "is a student" as predicate P then we have statement as P(x). Here P(x) is a statement function where if we replace x with a Subject say Sunil then we'll be having a statement "Sunil is a student."

Thus a statement function is an expression having Predicate Symbol and one or multiple variables. This statement function gives a statement when we replaced the variables with objects. This replacement is called substitution instance of statement function.

## Quantifiers

The variable of predicates is quantified by quantifiers. There are two types of quantifier in predicate logic − Universal Quantifier and Existential Quantifier.

## Universal Quantifier

Universal quantifier states that the statements within its scope are true for every value of the specific variable. It is denoted by the symbol ∀.

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

**Example** − "Man is mortal" can be transformed into the propositional form ∀ x P(x) where P(x) is the predicate which denotes x is mortal and ∀ x represents all men.

## Existential Quantifier

Existential quantifier states that the statements within its scope are true for some values of the specific variable. It is denoted by the symbol ∃.

∃ x P(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 ∃ x P(x) where P(x) is the predicate which denotes x is dishonest and ∃ x represents some dishonest men.

## Predicate Formulas

Consider a Predicate P with n variables as P(x_{1}, x_{2}, x_{3}, ..., x_{n}). Here P is n-place predicate and x_{1}, x_{2}, x_{3}, ..., x_{n} are n individuals variables. This n-place predicate is known as atomic formula of predicate calculus. For Example: P(), Q(x, y), R(x,y,z)

## Well Formed Formula

Well Formed Formula (wff) is a predicate holding any of the following −

All propositional constants and propositional variables are wffs

If x is a variable and Y is a wff, ∀ x Y and ∀ x Y are also wff

Truth value and false values are wffs

Each atomic formula is a wff

All connectives connecting wffs are wffs

## Free and Bound variables

Consider a Predicate formula having a part in form of (∃ x) P(x) of (x)P(x), then such part is called x-bound part of the formula. Any occurrence of x in x-bound part is termed as bound occurrence and any occurrence of x which is not x-bound is termed as free occurrence. See the examples below -

(∃ x) (P(x) ∧ Q(x))

(∃ x) P(x) ∧ Q(x)

In first example, scope of (∃ x) is (P(x) ∧ Q(x)) and all occurrences of x are bound occurrences. Whereas in second example, scope of (∃ x) is P(x) and last occurrence of x in Q(x) is a free occurrence.

## Universe of Discourse

We can limit the class of individuals/objects used in a statment. Here limiting means confining the input variable to a set of particular individuals/objects. Such a restricted class is termed as Universe of Discourse/domain of individual or universe. See the example below:

Some cats are black.

C(x) : x is a cat.

B(x) : x is black.

(∃ x)(C(x) ∧ B(x))

If Universe of discourse is E = { Katy, Mille } where katy and Mille are white cats then our third statement is false when we replace x with either Katy or Mille where as if Universe of discourse is E = { Jene, Jackie } where Jene and Jackie black cats then our third statement stands true for Universe of Discourse F.

- Related Questions & Answers
- Inference Theory of the Predicate Calculus
- Rules Of Inference for Predicate Calculus
- Theory of Inference for the Statement Calculus
- Inference Theory of the Predicate Logic
- Difference between Relational Algebra and Relational Calculus
- Remove elements from a SortedSet that match the predicate in C#
- Check if every List element matches the predicate conditions in C#
- Difference between Function and Predicate in Java 8
- Importance of Predicate interface in lambda expression in Java?
- Remove elements from a HashSet with conditions defined by the predicate in C#
- C# Program to filter array elements based on a predicate
- Remove all elements of a List that match the conditions defined by the predicate in C#
- How to get all elements of a List that match the conditions specified by the predicate in C#?
- How to use Predicate<T> and BiPredicate<T, U> in lambda expression in Java?
- At the union level the prime minister heads the government; at the state level, the chief ministers head the government; who heads the government at the district level?