Discr
e
te
Structur
es
Pr
edic
a
te Lo
gic
2
Dr
.
Muh
ammad
Hu
ma
y
oun
Assis
tan
t
Pr
of
es
so
r
C
OM
S
A
T
S
Ins
ti
tut
e
of
Comput
er
Sci
e
nce,
Lahor
e.
mhuma
youn@ci
itl
ahor
e.edu.pk
h
ttp
s://
si
tes.
g
oo
gl
e.c
om/
a/
ci
itl
a
hor
e.edu.pk/ds
truc
t/
1
Neg
a
tio
n
of
Quan
tifi
er
s
•
ݔ
ܲ
ݔ
ؠ
ܲ
ݔ
•
ݔ
ܲ
ݔ
ؠ
ܲ
ݔ
•
ݔ
ሺܲ
ݔ
ר
ܳ
ݔ
ሻ
ؠ
?
?
?
2
Neg
a
tio
n
of
Quan
tifi
er
s
•
ݔ
ܲ
ݔ
ؠ
ܲ
ݔ
•
ݔ
ܲ
ݔ
ؠ
ܲ
ݔ
•
ݔ
ሺܲ
ݔ
ר
ܳ
ݔ
ሻ
ؠ
?
?
?
3
Neg
a
tio
n
of
Quan
tifi
er
s
•
ݔ
ܲ
ݔ
ؠ
ܲ
ݔ
•
ݔ
ܲ
ݔ
ؠ
ܲ
ݔ
•
ݔ
ሺܲ
ݔ
ר
ܳ
ݔ
ሻ
ؠ
?
?
?
4
Ex
er
cise
B(x)
:
“x i
s a
bab
y
”
ignor
an
t(
x)
:
“x i
s i
gnor
an
t”
v
ain(x)
: “x i
s v
ai
n”
Uni
ver
se:
The
se
t of
al
l
peopl
e.
•
Babies
ar
e
ignor
an
t.
5
Ex
er
cise
B(x)
:
“x i
s a
bab
y
”
ignor
an
t(
x)
:
“x i
s i
gnor
an
t”
v
ain(x)
: “x i
s v
ai
n”
Uni
ver
se:
The
se
t of
al
l
peopl
e.
•
Babies
ar
e
ignor
an
t.
(Amb
iguous)
•
All
/Some
babies
ar
e ignor
an
t
6
Ex
er
cise
B(x)
:
“x i
s a
bab
y
”
ignor
an
t(
x)
:
“x i
s i
gnor
an
t”
v
ain(x)
: “x i
s v
ai
n”
Uni
ver
se:
The
se
t of
al
l
peopl
e.
•
Babies
ar
e
ignor
an
t.
(Amb
iguous)
•
All
babies
ar
e ignor
an
t
•
࢞
ሺ
࢞
՜
ࢍ࢘ࢇ
࢚
࢞
ሻ
7
Ex
er
cise
pr
of
esso
r(x)
:
“x i
s
a pr
of
essor
”
ignor
an
t(
x)
:
“x i
s i
gnor
an
t”
v
ain(x)
: “x i
s v
ai
n”
Uni
ver
se:
The
se
t of
al
l
peopl
e.
•
No pr
of
essor
s
ar
e ignor
an
t.
•
It
is
not
the c
ase
tha
t
ther
e e
xi
sts
an x such
tha
t
x
is
a
pr
of
ess
or
and
x i
s i
gnor
an
t.
•
ݔ
ሺݎ݂݁ݏ
ݏݎ
ݔ
ר
݅݃݊ݎܽ݊ݐ
ݔ
ሻ
•
It
is
not
the c
ase
tha
t
al
l
pr
of
essor
s ar
e
ignor
an
t. 8
Ex
er
cise
pr
of
esso
r(x)
:
“x i
s
a pr
of
essor
”
ignor
an
t(
x)
:
“x i
s i
gnor
an
t”
v
ain(x)
: “x i
s v
ai
n”
Uni
ver
se:
The
se
t of
al
l
peopl
e.
•
No pr
of
essor
s
ar
e ignor
an
t.
•
[Ther
e
is no such pr
of
essor
who is igno
ran
t]
•
[It
is
not
the c
ase t
ha
t ther
e i
s an
x such tha
t
x i
s a
pr
of
ess
or and
x
i
s i
gnor
an
t.
]
•
ݔ
ሺݎ݂݁ݏ
ݏݎ
ݔ
ר
݅݃݊ݎܽ݊ݐ
ݔ
ሻ
•
It
is
not
the c
ase
tha
t
al
l
pr
of
essor
s ar
e
ignor
an
Ex
er
cise
pr of esso r(x) : “x i s a pr of essor ” ignor an t( x) : “x i s i gnor an t” v ain(x): “x i
s v ai n” Uni ver se: The se t of al l peopl e. • No pr of essor s ar e ignor an t. • [Ther e
is no such pr
of
essor
who is igno
ran t] • [It is not the c ase t ha t ther e i s an
x such tha
t x i s a pr of ess or and x i s i gnor an t. ] • ݔ ሺݎ݂݁ݏ ݏݎ ݔ ר ݅݃݊ݎܽ݊ݐ ݔ ሻ pr of essor s ar e ignor an t. 1 0
Ex
er
cise
pr of esso r(x) : “x i s a pr of essor ” ignor an t( x) : “x i s i gnor an t” v ain(x): “x i
s v ai n” Uni ver se: The se t of al l peopl e. • No pr of essor s ar e ignor an t. • [Ther e
is no such pr
of
essor
who is igno
ran t] • [It is not the c ase t ha t ther e i s an
x such tha
t x i s a pr of ess or and x i s i gnor an t. ] • ݔ ሺݎ݂݁ݏ ݏݎ ݔ ר ݅݃݊ݎܽ݊ݐ ݔ ሻ • Al l pr of essor s ar e not i gnor an t 1 1
Ex
er
cise
pr of esso r(x) : “x i s a pr of essor ” ignor an t( x) : “x i s i gnor an t” v ain(x): “x i
s v ai n” Uni ver se: The se t of al l peopl e. • No pr of essor s ar e ignor an t. • ݔ ሺݎ݂݁ݏ ݏݎ ݔ ר ݅݃݊ݎܽ݊ݐ ݔ ሻ • All ( and all of them) pr of essor s ar e n ot ignor an t. • ݔ ݎ݂݁ݏ ݏݎ ݔ ՜ ݅݃݊ݎܽ݊ݐ ݔ 1 2
Ex
er
cise
pr of es so r(x) : “x i s a pr of essor ” ignor an t( x ): “x i s i gno ran t” v ain( x ): “x i s v ai n” Uni ver se: The se t of al l peopl e. • All ig nor an t peop le ar e v ain. • For al l peopl e x, if x i s ign or an t then x i s vai n . • ݔ ሺ݅݃ݎܽ݊ ݐ ݔ ՜ ݒܽ݅݊ ݔ ሻ • It is l o gi cal ly equi val e n t to ሾ ሺ ݔ ݅݃ ݎܽ݊ݐ ݔ ՜ ݒܽ݅ ݊ ݔ ሻ ሿ • ؠ ሾ ሺ ݔ ݅݃ ݎܽ݊ݐ ݔ ש ݒܽ݅ ݊ ݔ ሿ • ؠ ݔ ݅݃ ݎܽ݊ݐ ݔ ר ݒܽ݅ ݊ ݔ • ؠ ݔ ݅݃ ݎܽ݊ݐ ݔ ר ݒܽ݅ ݊ ݔ • Th ere is n
o such per son x such t ha t he is ign or an t and not v ain . 1 3
Ex
er
cise
pr of es so r(x) : “x i s a pr of essor ” ignor an t( x ): “x i s i gno ran t” v ain( x ): “x i s v ai n” Uni ver se: The se t of al l peopl e. • All ig nor an t peop le ar e v ain. • For al l peopl e x, if x i s ign or an t then x i s vai n . • ݔ ሺ݅݃ݎܽ݊ ݐ ݔ ՜ ݒܽ݅݊ ݔ ሻ • It is l o gi cal ly equi val e n t to ሾ ሺ ݔ ݅݃ ݎܽ݊ݐ ݔ ՜ ݒܽ݅ ݊ ݔ ሻ ሿ • ؠ ሾ ሺ ݔ ݅݃ ݎܽ݊ݐ ݔ ש ݒܽ݅ ݊ ݔ ሿ • ؠ ݔ ݅݃ ݎܽ݊ݐ ݔ ר ݒܽ݅ ݊ ݔ • ؠ ݔ ݅݃ ݎܽ݊ݐ ݔ ר ݒܽ݅ ݊ ݔ • Th ere is n
o such per son x such t ha t he is ign or an t and not v ain . 1 4
Ex
er
cise
pr of es so r(x) : “x i s a pr of essor ” ignor an t( x ): “x i s i gno ran t” v ain( x ): “x i s v ai n” Uni ver se: The se t of al l peopl e. • All ig nor an t peop le ar e v ain. • For al l peopl e x, if x i s ign or an t then x i s vai n . • ݔ ሺ݅݃ݎܽ݊ ݐ ݔ ՜ ݒܽ݅݊ ݔ ሻ • It is l o gi cal ly equi val e n t to ሾ ሺ ݔ ݅݃ ݎܽ݊ݐ ݔ ՜ ݒܽ݅ ݊ ݔ ሻ ሿ • ؠ ሾ ሺ ݔ ݅݃ ݎܽ݊ݐ ݔ ש ݒܽ݅ ݊ ݔ ሿ • ؠ ݔ ݅݃ ݎܽ݊ݐ ݔ ר ݒܽ݅ ݊ ݔ • ؠ ݔ ݅݃ ݎܽ݊ݐ ݔ ר ݒܽ݅ ݊ ݔ • Th ere is n
o such per son x such t ha t he is ign or an t and not v ain . 1 5
Ex
er
cise
pr of es so r(x) : “x i s a pr of essor ” ignor an t( x ): “x i s i gno ran t” v ain( x ): “x i s v ai n” Uni ver se: The se t of al l peopl e. • All ig nor an t peop le ar e v ain. • For al l peopl e x, if x i s ign or an t then x i s vai n . • ݔ ሺ݅݃ݎܽ݊ ݐ ݔ ՜ ݒܽ݅݊ ݔ ሻ • It is l o gi cal ly equi val e n t to ሾ ሺ ݔ ݅݃ ݎܽ݊ݐ ݔ ՜ ݒܽ݅ ݊ ݔ ሻ ሿ • ؠ ሾ ሺ ݔ ݅݃ ݎܽ݊ݐ ݔ ש ݒܽ݅ ݊ ݔ ሿ • ؠ ݔ ݅݃ ݎܽ݊ݐ ݔ ר ݒܽ݅ ݊ ݔ • ؠ ݔ ݅݃ ݎܽ݊ݐ ݔ ר ݒܽ݅ ݊ ݔ • Th ere is n
o such per son x such t ha t he is ign or an t and not v ain . 1 6
Ex
er
cise
pr of es so r(x) : “x i s a pr of essor ” ignor an t( x ): “x i s i gno ran t” v ain( x ): “x i s v ai n” Uni ver se: The se t of al l peopl e. • All ig nor an t peop le ar e v ain. • For al l peopl e x, if x i s ign or an t then x i s vai n . • ݔ ሺ݅݃ݎܽ݊ ݐ ݔ ՜ ݒܽ݅݊ ݔ ሻ • It is l o gi cal ly equi val e n t to ሾ ሺ ݔ ݅݃ ݎܽ݊ݐ ݔ ՜ ݒܽ݅ ݊ ݔ ሻ ሿ • ؠ ሾ ሺ ݔ ݅݃ ݎܽ݊ݐ ݔ ש ݒܽ݅ ݊ ݔ ሿ • ؠ ݔ ݅݃ ݎܽ݊ݐ ݔ ר ݒܽ݅ ݊ ݔ • ؠ ݔ ݅݃ ݎܽ݊ݐ ݔ ר ݒܽ݅ ݊ ݔ • Th ere is n
o such per son x such t ha t he is ign or an t and not v ain . 1 7 U seful
Ex
er
cise
pr of essor(x): “x i
s a pr of essor ” ignor an t(x )
: “x i
s ignor an t” v ain(x ): “x i s v ai n” Uni ver se: The se t of al l peopl e. • No pr of essor s a re v ain • It is no t the c ase tha t ther e is an x such tha t x is pr of essor and x is v ai n. • ሾ ݔሺ ݎ݂݁ݏݏݎ ݔ ר ݒܽ ݅݊ ሺݔ ሻሻ ሿ • ሾ ݔሺ ݎ ݂݁ݏݏݎ ݔ ש ݒܽ ݅݊ ሺݔ ሻሻ ሿ • ݔ ݎ݂݁ݏݏݎ ݔ ՜ ݒܽ ݅݊ ݔ •
For all p
eople x,
if x i
s a pr
Ex
er
cise
pr
of
essor(x)
: “x i
s
a pr
of
essor
”
ignor
an
t(x
)
: “x i
s
ignor
an
t”
v
ain(x
):
“x i
s v
ai
n”
Uni
ver
se: The
se
t
of
al
l
peopl
e.
•
No pr
of
essor
s a
re
v
ain
•
It
is no
t
the c
ase
tha
t
ther
e
is an
x
such
tha
t
x
is pr
of
essor
and
x
is v
ai
n.
•
ሾ
ݔሺ
ݎ݂݁ݏݏݎ
ݔ
ר
ݒܽ
݅݊
ሺݔ
ሻሻ
ሿ
•
ሾ
ݔሺ
ݎ
݂݁ݏݏݎ
ݔ
ש
ݒܽ
݅݊
ሺݔ
ሻሻ
ሿ
•
ݔ
ݎ݂݁ݏݏݎ
ݔ
՜
ݒܽ
݅݊
ݔ
•
For all p
eople x,
if x i
s a pr
of
essor then
x
not
v
ain.
1
9
Ex
er
cise
pr
of
essor(x)
: “x i
s
a pr
of
essor
”
ignor
an
t(x
)
: “x i
s
ignor
an
t”
v
ain(x
):
“x i
s v
ai
n”
Uni
ver
se: The
se
t
of
al
l
peopl
e.
•
No pr
of
essor
s a
re
v
ain
•
It
is no
t
the c
ase
tha
t
ther
e
is an
x
such
tha
t
x
is pr
of
essor
and
x
is v
ai
n.
•
ሾ
ݔሺ
ݎ݂݁ݏݏݎ
ݔ
ר
ݒܽ
݅݊
ሺݔ
ሻሻ
ሿ
•
ሾ
ݔሺ
ݎ
݂݁ݏݏݎ
ݔ
ש
ݒܽ
݅݊
ሺݔ
ሻሻ
ሿ
•
ݔ
ݎ݂݁ݏݏݎ
ݔ
՜
ݒܽ
݅݊
ݔ
•
For all p
eople x,
if x i
s a pr
of
essor then
x
not
v
ain.
2
0
Pr
ec
edence of
Quan
tifi
er
s
•
The quan
ti
fi
er
s
and
ha
ve
hi
gher
pr
ecedence
then
al
l l
ogi
cal
oper
a
tor
s
fr
om
pr
oposi
ti
onal
c
al
cu
lus.
•
e.
g.
࢞
ሺࡼ
࢞
ש
ࡽ
࢞
ሻ
i
s the
di
sjuncti
on
of
࢞
ࡼ
࢞
࢞
ࡽ
ሺ࢞
ሻ
.
2
1
Quan
tifier
s
with R
es
trict
ed
Domain
•
ݔ
ݔ
ଶ
Ͳ
–
ݔ
൏
Ͳ
ݔ
ଶ
Ͳ
–
ؠ
ݔ
ሺݔ
൏
Ͳሻ
՜
ሺݔ
ଶ
Ͳሻ
•
ݕ
ݕ
ଷ ്
Ͳ
–
ݕ
്
Ͳ
ݕ
ଷ്
Ͳ
–
ؠ
ݕ
്
Ͳ
՜
ݕ
ଷ ്
Ͳ
•
ݖ
ሺݖ
ଶ ൌ
ʹሻ
–
ݖ
Ͳ
ሺݖ
ଶൌ
ʹሻ
–
ؠ
ݖ
ሺݖ
Ͳ
՜
ݖ
ଶൌ
ʹሻ
2
2
Quan
tifier
s
with R
es
trict
ed
Domain
•
ݔ
ݔ
ଶ
Ͳ
–
ݔ
൏
Ͳ
ݔ
ଶ
Ͳ
–
ؠ
ݔ
ሺݔ
൏
Ͳሻ
՜
ሺݔ
ଶ
Ͳሻ
•
ݕ
ݕ
ଷ ്
Ͳ
–
ݕ
്
Ͳ
ݕ
ଷ്
Ͳ
–
ؠ
ݕ
്
Ͳ
՜
ݕ
ଷ ്
Ͳ
•
ݖ
ሺݖ
ଶ ൌ
ʹሻ
–
ݖ
Ͳ
ሺݖ
ଶൌ
ʹሻ
–
ؠ
ݖ
ሺݖ
Ͳ
՜
ݖ
ଶൌ
ʹሻ
2
3
Quan
tifier
s
with R
es
trict
ed
Domain
•
ݔ
ݔ
ଶ
Ͳ
–
ݔ
൏
Ͳ
ݔ
ଶ
Ͳ
–
ؠ
ݔ
ሺݔ
൏
Ͳሻ
՜
ሺݔ
ଶ
Ͳሻ
•
ݕ
ݕ
ଷ ്
Ͳ
–
ݕ
്
Ͳ
ݕ
ଷ്
Ͳ
–
ؠ
ݕ
്
Ͳ
՜
ݕ
ଷ ്
Ͳ
•
ݖ
ሺݖ
ଶ ൌ
ʹሻ
–
ݖ
Ͳ
ሺݖ
ଶൌ
ʹሻ
–
ؠ
ݖ
ሺݖ
Ͳ
՜
ݖ
ଶൌ
ʹሻ
2
4
Quan
tifier
s
with R
es
trict
ed
Domain
•
ݔ
ݔ
ଶ
Ͳ
–
ݔ
൏
Ͳ
ݔ
ଶ
Ͳ
–
ؠ
ݔ
ሺݔ
൏
Ͳሻ
՜
ሺݔ
ଶ
Ͳሻ
•
ݕ
ݕ
ଷ ്
Ͳ
–
ݕ
്
Ͳ
ݕ
ଷ്
Ͳ
–
ؠ
ݕ
്
Ͳ
՜
ݕ
ଷ്
Ͳ
•
ݖ
ሺݖ
ଶ ൌ
ʹሻ
–
ݖ
Ͳ
ሺݖ
ଶ ൌ
ʹሻ
–
ؠ
ݖ
ሺ
ݖ
Ͳ
՜
ݖ
ଶൌ
ʹ
ሻ
2
5
Nes
ted
Quan
tifi
er
s
l
ݔ
ݕ
ܲ
ሺݔ
ǡݕ
ሻ
§
“
Fo
r
all
ݔ
,
th
ere
exist
s
a
ݕ
su
ch
th
at
ܲ
ሺݔ
ǡݕ
ሻ
”
.
§
Exam
ple:
§
ݔ
ݕ
ሺݔ
ݕ
ൌ
Ͳ
ሻ
where
ݔ
and
ݕ
are in
tegers
2
6
Nes
ted
Quan
tifi
er
s
l
ݔ
ݕ
ܲ
ሺݔ
ǡݕ
ሻ
§
“
Fo
r
al
l
ݔ
,
there
exis
ts
a
ݕ
such
that
ܲ
ሺݔ
ǡݕ
ሻ
”
.
§
Ex
am
ple:
§
ݔ
ݕ
ሺݔ
ݕ
ൌ
Ͳ
ሻ
wh
ere
ݔ
and
ݕ
are
inte
gers
l
$
ݔ
"
ݕܲ
ሺݔ
ǡݕ
ሻ
§
Th
er
e
exis
ts
an x
such
that
for a
ll
ݕ
,
ܲሺ
ݔǡ
ݕሻ
is
tr
ue”
§
Ex
am
ple:
$
ݔ
"
ݕ
ሺݔ
ൈ
ݕ
ൌ
Ͳሻ
•
ݔ
ݕ
ݖ
ݔ
ݕ
ݖ
ൌ
ݔ
ݕ
ݖ
•
THI
NK QU
ANTIFICA
TION
AS L
OO
PS
2
Meaning
s
of multiple
quan
tifier
s
Sup
pose
ࡼ
ሺ࢞
ǡ࢟
ሻ
=
“
x lik
es y
.”
Domai
n
of
x: {St1,
St2
};
Domai
n
of
y:
{DS,
Cal
cul
us}
•
"
࢞
"
࢟
ࡼ
ሺ࢞
ǡ࢟
ሻ
–
ܲሺ
ݔǡ
ݕሻ
true for
al
l x,
y pa
irs
.
•
$
࢞
$
࢟ࡼ
ሺ࢞
ǡ࢟
ሻ
–
ܲሺ
ݔǡ
ݕሻ
true for
a
t leas
t
on
e x, y pa
ir
.
•
"
࢞
$
࢟
ࡼ
ሺ࢞
ǡ࢟
ሻ
–
Fo
r ev
ery
va
lue of x we
can f
ind a (po
ss
ibly
dif
ferent) y
so
t
ha
t
P(
x,y
) i
s true
.
•
$
࢞
"
࢟
ࡼ
ሺ࢞
ǡ࢟
ሻ
–
Th
ere i
s at leas
t
on
e x for which P(
x,y
) i
s
alwa
ys t
rue
.
2
8
Meaning
s
of multiple
quan
tifier
s
Sup
pose
ࡼ
ሺ࢞
ǡ࢟
ሻ
=
“
x lik
es y
.”
Domai
n
of
x:
{St1,
St2
};
Domai
n
of
y:
{DS,
Cal
cul
us}
•
"
࢞
"
࢟
ࡼ
ሺ࢞
ǡ࢟
ሻ
–
ܲሺ
ݔǡ
ݕሻ
true for
al
l x,
y pa
irs
.
•
$
࢞
$
࢟ࡼ
ሺ࢞
ǡ࢟
ሻ
–
ܲሺ
ݔǡ
ݕሻ
true for
a
t leas
t
on
e x, y pa
ir
.
•
"
࢞
$
࢟
ࡼ
ሺ࢞
ǡ࢟
ሻ
–
Fo
r ev
ery
va
lue of x we
can f
ind a (po
ss
ibly
dif
ferent) y
so
t
ha
t
P(
x,y
) i
s true
.
•
$
࢞
"
࢟
ࡼ
ሺ࢞
ǡ࢟
ሻ
–
Th
ere i
s at leas
t
on
e x for which P(
x,y
) i
s
alwa
ys t
rue
.
2
9
Meaning
s
of multiple
quan
tifier
s
Sup
pose
ࡼ
ሺ࢞
ǡ࢟
ሻ
=
“
x lik
es y
.”
Domai
n
of
x:
{St1,
St2
};
Domai
n
of
y:
{DS,
Cal
cul
us}
•
"
࢞
"
࢟
ࡼ
ሺ࢞
ǡ࢟
ሻ
–
ܲሺ
ݔǡ
ݕሻ
true for
al
l x,
y pa
irs
.
•
$
࢞
$
࢟
ࡼ
ሺ࢞
ǡ࢟
ሻ
–
ܲሺ
ݔǡ
ݕሻ
true for
a
t leas
t
on
e x, y pa
ir
.
•
"
࢞
$
࢟
ࡼ
ሺ࢞
ǡ࢟
ሻ
–
Fo
r ev
ery
va
lue of x we
can f
ind a (po
ss
ibly
dif
ferent) y
so
t
ha
t
P(
x,y
) i
s true
.
•
$
࢞
"
࢟
ࡼ
ሺ࢞
ǡ࢟
ሻ
–
Th
ere i
s at leas
t
on
e x for which P(
x,y
) i
s
alwa
ys t
rue
.
3
0
Meaning
s
of multiple
quan
tifier
s
Sup
pose
ࡼ
ሺ࢞
ǡ࢟
ሻ
=
“
x lik
es y
.”
Domai
n
of
x: {St1,
St2
};
Domai
n
of
y:
{DS,
Cal
cul
us}
•
"
࢞
"
࢟
ࡼ
ሺ࢞
ǡ࢟
ሻ
–
ܲሺ
ݔǡ
ݕሻ
true for
al
l x,
y pa
irs
.
•
$
࢞
$
࢟ࡼ
ሺ࢞
ǡ࢟
ሻ
–
ܲሺ
ݔǡ
ݕሻ
true for
a
t leas
t
on
e x, y pa
ir
.
•
"
࢞
$
࢟
ࡼ
ሺ࢞
ǡ࢟
ሻ
–
Fo
r ev
ery
va
lue of x we
can f
ind a (po
ss
ibly
dif
ferent) y
so
t
ha
t
P(
x,y
) i
s true
.
•
$
࢞
"
࢟
ࡼ
ሺ࢞
ǡ࢟
ሻ
–
Th
ere i
s at leas
t
on
e x for which P(
x,y
) i
s
alwa
ys t
rue
.
3
1
•
Quan
ti
fi
ca
ti
on
or
der
is
not
commut
a
ti
ve
"
࢞
$
࢟
ࡼ
࢞ǡ
࢟
്
$
࢞
"
࢟
ࡼ
ሺ࢞
ǡ࢟
ሻ
3
2
Ex
ampl
e
ܳ
ሺݔ
ǡݕ
ǡݖ
ሻǣ
ൌ
Dom
ai
n: R
eal
numbe
rs
•
ݔ
ݕ
ݖ
ܳ
ሺݔ
ǡݕ
ǡݖ
ሻ
True
/F
al
se
???
•
F
or
al
l r
eal
nu
mber
s
x and f
or al
l r
eal
number
s
y
ther
e
is
a r
eal
number z
such tha
t
ݔ
ݕ
ൌ
ݖ
.
•
True
•
ݖ
ݔ
ݕ
ܳ
ሺݔ
ǡݕ
ǡݖ
ሻ
True
/F
al
se
?
?
?
•
Ther
e
is a r
eal
number z such
tha
t
for a
ll
r
eal
numb
er
s x a
nd
for al
l r
eal
n
umbe
rs y i
t
is
true
tha
t
ݔ
ݕ
ൌ
ݖ
.
•
Fal
se
3
3
Ex
ampl
e
ܳ
ሺݔ
ǡݕ
ǡݖ
ሻǣ
ൌ
Dom
ai
n: R
eal
numbe
rs
•
ݔ
ݕ
ݖ
ܳ
ሺݔ
ǡݕ
ǡݖ
ሻ
True
/F
al
se
???
•
For
al
l r
eal
nu
mber
s
x and f
or al
l r
eal
number
s
y
ther
e
is
a r
eal
number z
such tha
t
ݔ
ݕ
ൌ
ݖ
.
•
True
•
ݖ
ݔ
ݕ
ܳ
ሺݔ
ǡݕ
ǡݖ
ሻ
True
/F
al
se
?
?
?
•
Ther
e
is a r
eal
number z such
tha
t
for a
ll
r
eal
numb
er
s x a
nd
for al
l r
eal
n
umbe
rs y i
t
is
true
tha
t
ݔ
ݕ
ൌ
ݖ
.
•
Fal
se
3
4
Ex
ampl
e
ܳ
ሺݔ
ǡݕ
ǡݖ
ሻǣ
ൌ
Dom
ai
n: R
eal
numbe
rs
•
ݔ
ݕ
ݖ
ܳ
ሺݔ
ǡݕ
ǡݖ
ሻ
True
/F
al
se
???
•
F
or
al
l r
eal
nu
mber
s
x and f
or al
l r
eal
number
s
y
ther
e
is
a r
eal
number z
such tha
t
ݔ
ݕ
ൌ
ݖ
.
•
True
•
ݖ
ݔ
ݕ
ܳ
ሺݔ
ǡݕ
ǡݖ
ሻ
True
/F
al
se
?
?
?
•
Ther
e
is a r
eal
number z such
tha
t
for a
ll
r
eal
numb
er
s x a
nd
for al
l r
eal
n
umbe
rs y i
t
is
true
tha
t
ݔ
ݕ
ൌ
ݖ
.
•
Fal
se
3
5
Ex
ampl
e
ܳ
ሺݔ
ǡݕ
ǡݖ
ሻǣ
ൌ
Dom
ai
n: R
eal
numbe
rs
•
ݔ
ݕ
ݖ
ܳ
ሺݔ
ǡݕ
ǡݖ
ሻ
True
/F
al
se
???
•
F
or
al
l r
eal
nu
mber
s
x and f
or al
l r
eal
number
s
y
ther
e
is
a r
eal
number z
such tha
t
ݔ
ݕ
ൌ
ݖ
.
•
True
•
ݖ
ݔ
ݕ
ܳ
ሺݔ
ǡݕ
ǡݖ
ሻ
True
/F
al
se
?
?
?
•
Ther
e
is a r
eal
number z such
tha
t
for a
ll
r
eal
numb
er
s x a
nd
for al
l r
eal
n
umbe
rs y i
t
is
true
tha
t
ݔ
ݕ
ൌ
ݖ
.
•
Fal
se
3
Fr
om
Nes
ted
Qua
n
tifier
s
to
English
•
F (a, b
): “
a
and b
a
re
fri
en
ds”
•
Domai
n: Al
l s
tude
n
ts i
n
C
OMS
A
T
S.
ݔ
ݕ
ݖ
ܨ
ݔǡ
ݕ
ר
ܨ
ݔǡ
ݖ
ר
ݕ
്
ݖ
՜
ܨ
ݕǡ
ݖ
•
Ther
e
is a s
tuden
t
x such tha
t
for al
l s
tuden
ts
y and
al
l
studen
ts
z
other
than y
, i
f x
and y
a
re
fri
en
ds
and x
a
nd
z ar
e
fri
en
ds, t
he
n
y and z
ar
e
not
fri
en
ds.
•
Ther
e
is a s
tuden
t
none
of
whose fri
e
nds ar
e al
so
fri
en
ds w
ith
each
other
.
3
7
Fr
om
Nes
ted
Qua
n
tifier
s
to
English
•
F (a, b
): “
a
and b
a
re
fri
en
ds”
•
Domai
n: Al
l s
tude
n
ts i
n
C
OMS
A
T
S.
ݔ
ݕ
ݖ
ܨ
ݔǡ
ݕ
ר
ܨ
ݔǡ
ݖ
ר
ݕ
്
ݖ
՜
ܨ
ݕǡ
ݖ
•
Ther
e
is a s
tuden
t
x such tha
t
for al
l s
tuden
ts
y and
al
l
studen
ts
z
other
than y
, i
f x
and y
a
re
fri
en
ds
and x
a
nd
z ar
e
fri
en
ds, t
he
n
y and z
ar
e
not
fri
en
ds.
•
Ther
e
is a s
tuden
t
none
of
whose fri
e
nds ar
e al
so
fri
en
ds w
ith
each
other
.
3
8
Fr
om English
to
Nes
ted
Qua
n
tifier
s
•
"If
a pe
rso
n
is f
emale an
d
is a p
ar
en
t,
then
this
per
so
n
is someone's
mother
“
•
For e
very per
son
x , i
f per
son
x i
s
femal
e
and
per
son
x i
s
a
par
en
t,
then
ther
e
e
xi
sts
a
per
son
y such
tha
t
per
son
x i
s
the
mother o
f per
son
y.
“
–
F(x):
“x
is
f
emal
e”
–
P(x):
“x
i
s
a
par
en
t“
–
M(x,
y) :
“x
i
s
the
mother o
f y
”
•
ݔ
ሾሺ
ܲ
ݔ
ר
ܨሺ
ݔሻ
ሻ
՜
ݕ
ܯ
ݔǡ
ݕ
ሿ
•
ݔ
ݕ
ሾሺ
ܲ
ݔ
ר
ܨሺ
ݔሻ
ሻ
՜
ܯ
ݔǡ
ݕ
ሿ
3
9
Fr
om English
to
Nes
ted
Qua
n
tifier
s
•
"If
a pe
rso
n
is f
emale an
d
is a p
ar
en
t,
then
this
per
so
n
is someone's
mother
“
•
For e
very per
son
x , i
f per
son
x i
s
femal
e
and
per
son
x i
s
a
par
en
t,
then
ther
e
e
xi
sts
a
per
son
y such
tha
t
per
son
x i
s
the
mother o
f per
son
y.
“
–
F(x):
“x
is
f
emal
e”
–
P(x):
“x
i
s
a
par
en
t“
–
M(x,
y) :
“x
i
s
the
mother o
f y
”
•
ݔ
ሾሺ
ܲ
ݔ
ר
ܨሺ
ݔሻ
ሻ
՜
ݕ
ܯ
ݔǡ
ݕ
ሿ
•
ݔ
ݕ
ሾሺ
ܲ
ݔ
ר
ܨሺ
ݔሻ
ሻ
՜
ܯ
ݔǡ
ݕ
ሿ
4
0
•
The
s
um
of tw
o positi
v
e
in
teg
er
s
is alw
a
y
s
posit
iv
e.
•
ݔ
ݕ
ሾ
ݔ
Ͳ
ר
ݕ
Ͳ
՜
ݔ
ݕ
Ͳ
ሿ
•
ݔ
ݕ
ሾݏ
ݔ
ר
ݏ
ݕ
՜
ݏ
ݔ
ݕ
ሿ
•
Wha
t i
s domai
n
abov
e?
•
In
teg
er
s
•
If domain
is “+
v
e
in
teg
er
s”
•
ݔ
ݕ
ݔ
ݕ
Ͳ
4
1
•
The
s
um
of tw
o positi
v
e
in
teg
er
s
is alw
a
y
s
posit
iv
e.
•
ݔ
ݕ
ሾ
ݔ
Ͳ
ר
ݕ
Ͳ
՜
ݔ
ݕ
Ͳ
ሿ
•
ݔ
ݕ
ሾݏ
ݔ
ר
ݏ
ݕ
՜
ݏ
ݔ
ݕ
ሿ
•
Wha
t i
s domai
n
abov
e?
•
In
teg
er
s
•
If domain
is “+
v
e
in
teg
er
s”
•
ݔ
ݕ
ݔ
ݕ
Ͳ
4
2
•
The
s
um
of tw
o positi
v
e
in
teg
er
s
is alw
a
y
s
posit
iv
e.
•
ݔ
ݕ
ሾ
ݔ
Ͳ
ר
ݕ
Ͳ
՜
ݔ
ݕ
Ͳ
ሿ
•
ݔ
ݕ
ሾݏ
ݔ
ר
ݏ
ݕ
՜
ݏ
ݔ
ݕ
ሿ
•
Wha
t i
s domai
n
abov
e?
•
In
teg
er
s
•
If domain
is “+
v
e
in
teg
er
s”
•
ݔ
ݕ
ݔ
ݕ
Ͳ
4
3
•
E
v
ery
one has
e
xactl
y
one
be
st
frien
d
•
For e
ver
y
per
son x , per
son x has e
xactl
y
one bes
t
fri
end.
•
ݔ
ሾ
pers
on
x
has
exactl
y
one
bes
t
fri
end
ሿ
•
B
(x,y
): “x
has
bes
t friend
y
”
•
ݔ
ݕ
ሾܤ
ݔǡ
ݕ
ሿ
•
Ex
actl
y one bes
t fri
end ??
??
•
࢞
࢟
ሾ
࢞ǡ
࢟
ר
ࢠ
࢟
്
ࢠ
՜
ሺ࢞
ǡࢠ
ሿ
•
ݔ
ݕ
ݖ
ሾܤ
ݔǡ
ݕ
ר
ݕ
്
ݖ
՜
ܤ
ሺݔ
ǡݖ
ሿ
4
4
•
E
v
ery
one has
e
xactl
y
one
be
st
frien
d
•
For e
ver
y
per
son x , per
son x has e
xactl
y
one bes
t
fri
end.
•
ݔ
ሾ
pers
on
x
has
exactl
y
one
bes
t
fri
end
ሿ
•
B
(x,y
): “x
has
bes
t friend
y
”
•
ݔ
ݕ
ሾܤ
ݔǡ
ݕ
ሿ
•
Ex
actl
y one bes
t fri
end ??
??
•
࢞
࢟
ሾ
࢞ǡ
࢟
ר
ࢠ
࢟
്
ࢠ
՜
ሺ࢞
ǡࢠ
ሿ
•
ݔ
ݕ
ݖ
ሾܤ
ݔǡ
ݕ
ר
ݕ
്
ݖ
՜
ܤ
ሺݔ
ǡݖ
ሿ
4
•
E
v
ery
one has
e
xactl
y
one
be
st
frien
d
•
For e
ver
y
per
son x , per
son x has e
xactl
y
one bes
t
fri
end.
•
ݔ
ሾ
pers
on
x
has
exactl
y
one
bes
t
fri
end
ሿ
•
B
(x,y
): “x
has
bes
t friend
y
”
•
ݔ
ݕ
ሾܤ
ݔǡ
ݕ
ሿ
•
Ex
actl
y one bes
t fri
end ??
??
•
࢞
࢟
ሾ
࢞ǡ
࢟
ר
ࢠ
࢟
്
ࢠ
՜
ሺ࢞
ǡࢠ
ሿ
•
ݔ
ݕ
ݖ
ሾܤ
ݔǡ
ݕ
ר
ݕ
്
ݖ
՜
ܤ
ሺݔ
ǡݖ
ሿ
4
6
•
E
v
ery
one has
e
xactl
y
one
be
st
frien
d
•
For e
ver
y
per
son x , per
son x has e
xactl
y
one bes
t
fri
end.
•
ݔ
ሾ
pers
on
x
has
exactl
y
one
bes
t
fri
end
ሿ
•
B
(x,y
): “x
has
bes
t friend
y
”
•
ݔ
ݕ
ሾܤ
ݔǡ
ݕ
ሿ
•
Ex
actl
y one bes
t fri
end ??
??
•
࢞
࢟
ሾ
࢞ǡ
࢟
ר
ࢠ
࢟
്
ࢠ
՜
ሺ࢞
ǡࢠ
ሿ
•
ݔ
ݕ
ݖ
ሾܤ
ݔǡ
ݕ
ר
ݕ
്
ݖ
՜
ܤ
ሺݔ
ǡݖ
ሿ
4
7
•
E
v
ery
one has
e
xactl
y
one
be
st
frien
d
•
For e
ver
y
per
son x , per
son x has e
xactl
y
one bes
t
fri
end.
•
ݔ
ሾ
pers
on
x
has
exactl
y
one
bes
t
fri
end
ሿ
•
B
(x,y
): “x
has
bes
t friend
y
”
•
ݔ
ݕ
ሾܤ
ݔǡ
ݕ
ሿ
•
Ex
actl
y one bes
t fri
end ??
??
•
࢞
࢟
ሾ
࢞ǡ
࢟
ר
ࢠ
࢟
്
ࢠ
՜
ሺ࢞
ǡࢠ
ሿ
•
ݔ
ݕ
ݖ
ሾܤ
ݔǡ
ݕ
ר
ݕ
്
ݖ
՜
ܤ
ሺݔ
ǡݖ
ሿ
4
8
•
E
v
ery
one has
e
xactl
y
one
be
st
frien
d
•
For e
ver
y
per
son x , per
son x has e
xactl
y
one bes
t
fri
end.
•
ݔ
ሾ
pers
on
x
has
exactl
y
one
bes
t
fri
end
ሿ
•
B
(x,y
): “x
has
bes
t friend
y
”
•
ݔ
ݕ
ሾܤ
ݔǡ
ݕ
ሿ
•
Ex
actl
y one bes
t fri
end ??
??
•
࢞
࢟
ሾ
࢞ǡ
࢟
ר
ࢠ
࢟
്
ࢠ
՜
ሺ࢞
ǡࢠ
ሿ
•
ݔ
ݕ
ݖ
ሾܤ
ݔǡ
ݕ
ר
ݕ
്
ݖ
՜
ܤ
ሺݔ
ǡݖ
ሿ
4
9
•
The
re is
a w
oman
who has
tak
en
a
fligh
t
on
e
v
er
y
airl
ine
in the
w
orl
d.
•
Domai
ns
:
peopl
e
ai
rl
ines
fl
igh
ts
•
W(x): x
i
s a w
oman
•
F(x
, f
):
x has t
ak
en fl
igh
t
f
•
A(f
, a):
fl
igh
t
f bel
ongs t
o
ai
rl
ine
a
•
࢞
ሾࢃ
࢞
՜
ࢇ
ࢌ
ࢌǡ
ࢇ
ר
ࡲ
࢞ǡ
ࢌ
ሿ
•
ݔ
ܽ
݂
ሾܹ
ݔ
՜
ܣ
݂ǡ
ܽ
ר
ܨ
ݔǡ
݂
ሿ
5
0
•
The
re is
a w
oman
who has
tak
en
a
fligh
t
on
e
v
er
y
airl
ine
in the
w
orl
d.
•
Domai
ns
:
w
oman
ai
rl
ines
fl
igh
ts
•
P(w
, f
): W
oman w has
t
ak
en fl
igh
t
f
•
Q(f
,
a):
fl
igh
t
f bel
ongs t
o
ai
rl
ine
a
•
࢞
ሾࢃ
࢞
՜
ࢇ
ࢌ
ࢌǡ
ࢇ
ר
ࡲ
࢞ǡ
ࢌ
ሿ
•
ݔ
ܽ
݂
ሾܹ
ݔ
՜
ܣ
݂ǡ
ܽ
ר
ܨ
ݔǡ
݂
ሿ
5
1
•
The
re is
a w
oman
who has
tak
en
a
fligh
t
on
e
v
er
y
airl
ine
in the
w
orl
d.
•
Domai
ns
:
w
oman
ai
rl
ines
fl
igh
ts
•
P(w
, f
): W
oman w has
t
ak
en fl
igh
t
f
•
Q(f
,
a):
fl
igh
t
f bel
ongs t
o
ai
rl
ine
a
•
࢝
ࢇ
ࢌ
ሾ
ࡼ
࢝
ǡࢌ
ר
ࡽ
ࢌǡ
ࢇ
ሿ
5
2
•
The
re is
a w
oman
who has
tak
en
a
fligh
t
on
e
v
er
y
airl
ine
in the
w
orl
d.
•
Domai
ns
:
w
oman
ai
rl
ines
fl
igh
ts
•
R(w
, f
, a): W
oman w
has t
ak
en
fl
igh
t
f
on
ai
rl
ine
a
•
࢝
ࢇ
ࢌ
ሾࡽ
ሺ࢝
ǡࢌ
ǡࢇ
ሿ
5
3
Bound
a
nd fr
ee v
aria
bles
l
A
va
riab
le
is bo
un
d
if
it is
kn
own
or qu
an
tified.
Otherwise
,
it is free.
l
Exa
mple
s:
l
P
(
x
)
x
is free
l
P(5)
x
is bo
un
d
to 5
l
"
x
P
(
x
)
x
is bo
un
d
by
qu
an
tifier
Reminder:
in
a pro
po
si
tion,
all
varia
bles
must
be bo
und.
5
Neg
a
ting
Nes
ted
Quan
tifi
er
s
•
ሾ
࢝
ࢇ
ࢌ
ࡼ
࢝
ǡࢌ
ר
ࡽ
ࢌǡ
ࢇ
ሿ
•
࢝
ࢇ
ࢌ
ࡼ
࢝
ǡࢌ
ש
ࡽ
ࢌǡ
ࢇ
5
5
Do Ex
er
cises
5