Lecture Notes on Predicate Logic: An Overview and Introduction, Study notes of Logic

These lecture notes provide an overview of Predicate Logic, covering the basics of predicate symbols, variables, constants, functional symbols, propositional connectives, quantifiers, and formulas. They are intended for students to review and use to solve Take-home Practice Final problems.

Typology: Study notes

2021/2022

Uploaded on 09/27/2022

bradpitt
bradpitt 🇬🇧

4.3

(10)

224 documents

1 / 17

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
Introduction to
Predicate Logic
Part 1
Professor Anita Wasilewska
Lecture Notes (1)
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff

Partial preview of the text

Download Lecture Notes on Predicate Logic: An Overview and Introduction and more Study notes Logic in PDF only on Docsity!

Introduction to

Predicate Logic

Part 1

Professor Anita Wasilewska

Lecture Notes (1)

Introduction

• Lecture Notes (1) and (2) provide an OVERVIEW of a

standard intuitive formalization and introduction to

Predicate Logic.

• I wrote them for you to review it and use it to solve

some of the Take – home Practice Final problems.

• It covers material that I assume is KNOWN to all

students;

• The formal definitions are in Chapter 13, 14 and we

will cover it later.

Formulas of Predicate Logic

We use symbols 1 - 6 to build formulas of predicate logic as

follows

1. P(x), Q(x,y), R(x)… R(c1), Q(x, c3), P(c), …

are called atomic formulas for any variables x, y,… and

constants c, c1, c2, …

2. All atomic formulas are formulas ;

3. If A,B are formulas then (like in propositional logic):

(A ∨ B) , (A ∧ B), (A ⇒ B), (A ⇔ B), ¬A

are formulas

4. ∀x A, ∃ y A are formulas, for any variables x, y

5. The set F of all formulas is the smallest set that fulfills the

conditions 1 -4.

Examples

For example: let

P(y), Q(x,c), R(z), P 1 (x, y, z) be atomic formulas, i.e.

P(x), Q(x,c), R(z), P 1 (x, y, z) ∈ F

Then we form some other formulas out of them as

follows:

(P(y) ∨ ¬Q( x, c) )∈ F

It is a formula with two free variables x, y.

∃x (P(y) ∨ ¬Q( x, c) ) ∈ F

∀y (P(y) ∨ ¬Q( x, c) ) ∈ F

∀y ∃x(P(y) ∨ ¬Q( x, c) ) ∈ F

etc

Logic and Mathematical Formulas

We often use logic symbols while writing mathematical

statements in a more symbolic way

Example of a Mathematical Statement:

∀x ∈ N (x > 0 ∧ ∃y ∈ N (y = 1))

1. Quantifier ∀x ∈ N is a quantifier with restricted domain

2. Logic uses only ∀x , ∃y

3. x > 0 and y =1 are mathematical statement about a real

relation ” >”

4. Logic uses symbols P, Q, R… for example

R(y, c 1 ) for y =1 and P(x, c 2 ) for x > 0 where c 1 and c 2 are constants representing numbers 1 and 0, respectively.

Translation of Mathematical

Statements to Logic

Consider a Mathematical Statement:

∀x ∈ N (x > 0 ∧ ∃y ∈ N (y = 1))

x ∈ N – we translate it as one argument predicate Q(x)

x > 0 – as two argument predicate P(x, c 1 ) , y = 1 – as another two argument predicate R(y, c 2 ) and get

∀Q(x) (P(x, c 1 ) ∧ ∃Q(y) R(y, c 2 ) )

↑ Logic formula with restricted domain quantifiers

But this is not yet a proper logic formula since we cannot have quantifiers ∀Q(x) , ∃Q(y) but only ∀x, ∃x.

∀Q(x), ∃Q(y) are called quantifiers with restricted domain

Restricted Domain Existential Quantifier

∃P(x) Q(x) ≡ ∃x(P(x) ∧ Q(x)) ↑ restricted ↑logic, not restricted

Example (mathematical formulas):

∃ x≠1 (x>0 ⇒ x + y > 5) - restricted

∃x ((x≠1 ) ∧ (x > 0 ⇒ x + y > 5)) - not restricted

↑ P(x, y, c)

English statement: Some students are good. Logic Translation (restricted domain): ∃S(x) G(x)

Predicates are : S(x) x is a student G(x) x is good TRANSLATION: ∃x(S(X) ∧ G(x))

Restricted Quantifiers and Quantifiers

Translation for universal quantifier

Restricted Logic (Non-restricted)

∀P(x) Q(x) Ξ ∀x (P(x) ⇒ Q(x))

Example (mathematical)

∀x ∈ N (x= 1 ∨ x< 0) restricted domain

Ξ ∀x (x ∈ N ⇒ ( x= 1 ∨ x< 0) ) – non-restricted

Remark

Mathematical statement: x + y = 5

To follow LOGIC formalization we re-write it as = ( + (x, y), 5)

and “translate it” to Predicate Language as P(f(x,y), c)

Given x = 2, x = 1, we get +(2,1) = 3 and the statement:

= (3,5) is FALSE (F)

Predicates always returns logical value F or T

We really need also function symbols (like +, etc..) to translate mathematical statements to logic, even if we could use only relations as functions are special relations

This is why in formal definition of the predicate language we often we have 2 sets of symbols

  1. Predicate symbols which can be true or false in proper domains
  2. Functions symbols ( formally called terms)

Translations to Logic

Rules:

1. Identify the domain: always as et X ≠ φ

2. Identify predicates (simple: atomic)

3. Identify functions (if needed)

4. Identify the connectives ∨, ∧ , ⇒, ¬, ⇔

5. Identify the quantifiers ∀x, ∃ x

Write a formula using only symbols for 2 ,3, 4

6. Use restricted domain quantifier translation

rules, where needed

Example

For every student there is a student that is an

elephant

B(x)- x is a student

W(x) – x is an elephant

∀B(x) ∃B(x) W(x)

∀B(x) ∃x(B(x) ∧ W(x))

∀x(B(x) ⇒ ∃x(B(x) ∧ W(x))) (logic formula)

Translations Example

Translate: Some patients like all doctors

Predicates:

P(x) – x is a patient

D(x) – x is a doctor

L( x,y) – x likes y

∃P(x) ∀D(y) L( x,y)

There is a patient(x), such that for all doctors(y), x likes y

∃x(P(x) ∧ ∀y(D(y) ⇒ L( x,y)))

(by law of quantifiers to be studied later we can “pull out ∀y”)

∃x∀y(P(x) ∧(D(y) ⇒L( x,y)))