Sei sulla pagina 1di 17

Lecture No.

3
Equality and Definite Description

Dr. Nazir A. Zafar

Formal Methods

Introduction
Now we extend our language by adding a theory
of equality between expressions.
Predicate calculus with equality is more
expressive, because of asserting identity of two
objects, or distinguishing between them.
The expressions which are equal may be
substituted one for the other, without affecting the
truth of a statement.
This forms basis of our theory of equality.
Properties such as symmetry and transitivity can
be derived from them.

Dr. Nazir A. Zafar

Formal Methods

Introduction
Addition of equality allows us to formulate a
simple rule for reasoning with quantifications:
the one-point rule.
We show how this rule may be used to
introduce existential quantifier and
eliminate the existential quantifier.

We also show how equality may be used in


statements expressing
uniqueness and
numerical quantity.

We will conclude lecture by introducing notations


for identifying objects by using a description of
their properties, rather than referring by name.
Dr. Nazir A. Zafar

Formal Methods

Equality
The notion of equality is a familiar one:
We learn that 1+1 equals 2
In the Christian religion,
25th Dec. equals Christmas Day.
It shows that the two expressions concerned have
same value, or denote the same object.
In a formal description, we identify expressions
using the equality symbol: e.g.
1+1 = 2 and 25th Dec. = Christmas Day.
Consequently, e = f, means e is identical to f and
we cannot distinguish between them

Dr. Nazir A. Zafar

Formal Methods

Equality
Example 4.1:
In an identity parade, a witness may state that the
man on the right is the man who stole my idea, is
equivalent to:
man on the right = man who stole my idea
Reflection:
Everything is identical to itself: thus, if t is any
expression, then t is equal to t .
This principle is known as the law of reflection:
Note: This principle is an axiom of standard Z
Dr. Nazir A. Zafar

Formal Methods

Equality
Leibnizs law:
Another axiom involving equality is Leibnizs law, or
the substitution of equals i.e.
if s = t , then whatever is true of s is true of t .
Example 4.3:
If s = t then
p [t / x] = p [s / x]

Dr. Nazir A. Zafar

(by substitution)

Formal Methods

Equality
Example 4.3
If we know that
1. Christmas Day = 25th December, and
2. 25th December falls on a Sunday this year
Then we may apply the Leibniz's law rule and
conclude that
Christmas Day falls on a Sunday this year
Note:
If two expressions e and f are not identical, then
we write e f .
This is simply an abbreviation for : (e = f)
Dr. Nazir A. Zafar

Formal Methods

The One Point Rule

If the identity of bound variable is revealed within


the quantified expression, then we may replace
all instances of that variable, and remove the
existential quantifier.
x:apx=t
If t is in a, and p holds with t substituted for x, then
t is a good candidate for this value.
This is the basis of the one-point rule
( x : a p x = t) t a p [t / x]

Dr. Nazir A. Zafar

Formal Methods

Example: One Point Rule


The predicate , n : N 4 + n = 6 n = 2
is equivalent to 2 N 4 + 2 = 6 and
n does not appear free in expression 2,
Hence the proposition 2 N 4 + 2 = 6 is true
The predicate , n : N 6 + n = 4 n = -2
is equivalent -2 N 6 + (-2) = 4
and n does not appear free in expression -2,
Hence proposition -2 N 6 - 2 = 4 is false.

Dr. Nazir A. Zafar

Formal Methods

The One Point Rule


Example:
The predicate
n : N ( m : N n m ) n = n +1
can not be simplified using one point rule.
This is because n is free in the expression n + 1

Dr. Nazir A. Zafar

Formal Methods

Uniqueness and Equality (use of Only)


Example 4.8
Symbolize only Romeo likes Juliet using a
conjunction
Symbolization:
1. Let L(x, y) means x likes y, and
2. let Person be the set of all people then
L(Romeo, Juliet)
p : Person L(p, Juliet) p = Romeo
That is, any person likes Juliet must be Romeo
Dr. Nazir A. Zafar

Formal Methods

Uniqueness and Equality (use of At most)


Example 4.9:
Formalize he statement:
there is at most one person to whom Romeo likes
Formalization:
1. Let L(x, y) mean that x likes y, and
2. let Person be the set of all people then
p, q : Person
L(Romeo, p) L(Romeo, q) p = q

Dr. Nazir A. Zafar

Formal Methods

Use of at most and at least


Example 4.10:
Formalize the statement:
no more than two visitors are permitted
Formalization:
let Visitors be the set of all visitors then
p, q, r : Visitors p = q q = r r = p
Example 4.11:
The statement at least two person has applied
could be formalized as
p, q : Applicants p q
Dr. Nazir A. Zafar

Formal Methods

Uniqueness and Equality (use of Exactness)


Example 4.12:
Formalize the statement:
there is exactly one book on my desk.
Formalization:
1. let Book be the set of all books
2. Desk(x) means that x is on my desk, then
b : Book Desk(b)
( c : Book | Desk(c) c = b) OR
1 b : Book Desk(c)
Dr. Nazir A. Zafar

Formal Methods

Definite Description

We often use a descriptive phrase to denote an


object, rather than a name.
For example, when a crime is committed, and the
police have not yet learned who committed, the
question is referred to as
the driver of the white car or
the cat in the hat etc.
Here, the word the is important which indicates
existence and uniqueness.

Dr. Nazir A. Zafar

Formal Methods

Definite Description
Example 4.14 :
Following phrases indicate that there is a unique
object with a certain property

The man who shot John Lennon

The woman who discovered radium

The oldest college in Oxford


Notation in Z: ( x : a | p)
denotes unique object x from a such that p.

Dr. Nazir A. Zafar

Formal Methods

Definite Description
Example 4.15 :
The phrases in Example 4.14 can be formalized
as above:
1.
2.
3.

( x : Person | Shot(x, John Lennon))


( y : Person | Discovered(x, radium))
( z : Colleges | Oldest-College(x , Oxford))

Dr. Nazir A. Zafar

Formal Methods

Potrebbero piacerti anche