First-Order Logic (FOL)

Teqnht  NohmosÔnh M. Koumparˆkhc ' $ First-Order Logic (FOL) Ontological commitments of FOL: • The world consists of objects i.e., things with ind...
Author: Lenard Hunt
2 downloads 2 Views 155KB Size
Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

First-Order Logic (FOL) Ontological commitments of FOL: • The world consists of objects i.e., things with individual identities. Objects have properties that distinguish them from other objects. • Objects participate in relations with other objects. Some of these relations are functions. Relations hold or do not hold. These ontological commitments make FOL more powerful than PL. FOL is here to stay!

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

FOL: Syntax The symbols of FOL (with equality) are the following: • Parentheses: (, ). • The logical connectives ¬, ∧, ∨, ⇒ and ⇔. • A countably infinite set of variables. This set will be denoted by V ars. Examples: x, y, v, . . .

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

FOL: Syntax (cont’d) • The quantifier symbols: ∀, ∃ • A countably infinite set of constant symbols. Examples: John, M ary, 5, 6, Ball, . . . • The equality symbol: = • Predicate symbols: For each positive integer n, some set (possibly empty) of symbols, called n-place predicate symbols. Examples: Happy(.), Brother(., .), Arrives(., ., .), . . . • Function symbols: For each positive integer n, some set (possibly empty) of symbols, called n-place function symbols. Examples: F atherOf (.), Cosine(.), . . . Logicians usually introduce only the connectives ¬ and ∨ and one of the quantifiers. &

Teqnht  NohmosÔnh

%

M. Koumparˆkhc

$

'

FOL: Syntax (cont’d) Terms are expressions of FOL that refer to objects. The set of all terms will be denoted by T erms. The following BNF grammar gives the syntax of terms: T erm → ConstantSymbol | V ariable | F unctionSymbol(T erm, . . . , T erm) Examples: John, x, F atherOf (John), W if eOf (F atherOf (x)), . . .

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

FOL: Syntax (cont’d) Atomic formulas are expressions of FOL that refer to simple facts. The following BNF grammar gives the syntax of atomic formulas: AtomicF ormula → T erm = T erm | P redicateSymbol(T erm, . . . , T erm) Examples: John = ElderSonOf (F atherOf (John)), Happy(John), Lives(John, London), Arrives(John, Athens, M onday)

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

FOL: Syntax (cont’d) Well-formed formulas (wffs) are the most complex kind of expressions in FOL. They can be used to refer to any complicated state of affairs. The following BNF grammar gives the syntax of wffs: W f f → AtomicF ormula | ( W f f ) | ¬ W f f | W f f BinaryConnective W f f | ( Quantif ier V ariable ) W f f

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

FOL: Syntax (cont’d) Examples of wffs: • ¬Loves(T ony, M ary) • Loves(T ony, P aula) ∨ Loves(T ony, F iona) • Loves(John, P aula) ∧ Loves(John, F iona) • (∀x)(SportsCar(x) ∧ HasDriven(M ike, x) ⇒ Likes(M ike, x)) • (∃x)(SportsCar(x) ∧ Owns(John, x))

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Free Variables The following recursive definition defines the notion of free variables of a wff. • If φ is an atomic formula, x occurs free in φ iff x is a symbol of φ. • x occurs free in ¬φ iff x is a symbol of φ. • x occurs free in φ ∧ ψ iff x is a symbol of φ or ψ. Similarly for the remaining binary connectives. • x occurs free in (∀v)φ iff x is a symbol of φ and x is different than v. Similarly for ∃. The opposite of free is bound. Definition. sentence. &

If no variable occurs free in the wff φ, then φ is a %

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Free Variables (cont’d) Examples: • x is free in Brother(x, John) but not in (∀x)(Cat(x) ⇒ M ammal(x)). • y is free in (∀x)(F riend(x, y) ⇒ Loves(x, y)) but not in (∀x)(∀y)(F riend(x, y) ⇒ Loves(x, y)).

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

FOL: Semantics The meaning of FOL formulas is provided by interpretations. An interpretation is a mapping between symbols of FOL and objects, functions or relations in the world. More precisely: • An interpretation maps each constant symbol to an object in the world. Example: In one particular interpretation the symbol John might refer to John Major, the British PM. In another interpretation it might refer to the evil King John, king of England from 1199 to 1216.

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

FOL: Semantics (cont’d) • An interpretation maps each predicate symbol to a relation in the world. Example: In one particular interpretation the symbol Brother(., .) might refer to the relation of brotherhood. In a world with three objects, King John, John Major, and Richard the Lionheart, the relation of brotherhood is defined by the following set of tuples: { hKing John, Richard the Lionhearti, hRichard the Lionheart, King Johni }

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

FOL: Semantics (cont’d) • An interpretation always maps the equality symbol to the identity relation in the world. The identity relation is: id = {ho, oi : o is an object in the world} • An interpretation maps each function symbol to a functional relation (or function) in the world. Example: In one particular interpretation the symbol F atherOf (.) might refer to the relation of fatherhood.

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

FOL: Formal Semantics An interpretation I is a function which makes the following assignments to the symbols of FOL: 1. I assigns to the quantifier symbol ∀ a non-empty set |I| called the universe or domain of I. 2. I assigns to each constant symbol c a member cI of the universe |I|. 3. I assigns to each n-place predicate symbol P an n-ary relation n P I ⊆ |I| ; i.e., P I is a set of n-tuples of members of the universe. 4. I assigns to each n-place function symbol F an n-ary function n F I on |I|; i.e., F I : |I| → |I|. &

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Satisfaction

Definition. A variable assignment is a function s : V ars → |I| for some set of variables V ars and interpretation I. Let φ be a wff of FOL, I an interpretation and s : V ars → |I| a variable assignment. We will define what it means for I to satisfy φ with variable assignment s. This will be denoted by |=I φ[s] or I |= φ[s]. Intuitively |=I φ[s] if and only if the state of affairs denoted by φ is true according to I (where any variable x which occurs in φ, stands for s(x) wherever it occurs free). &

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Satisfaction (cont’d) The formal definition of satisfaction proceeds as follows: Terms. We define the function s : T erms → |I| from the set of all terms T erms into the universe |I|. This function is an extension of s, and maps each FOL term to the object in the universe denoted by this term: • For each variable x, s(x) = s(x). • For each constant symbol c, s(c) = cI . • If t1 , . . . , tn are terms and F is an n-place function symbol, then s(F (t1 , . . . , tn )) = F I (s(t1 ), . . . , s(tn )). &

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Satisfaction (cont’d) Atomic formulas. The definition of satisfaction for atomic formulas is as follows: • For atomic formulas involving the equality symbol, |=I t1 = t2 [s] iff s(t1 ) is identical to s(t2 ). • For an n-place predicate symbol P , |=I P (t1 , . . . , tn )[s] iff hs(t1 ), . . . , s(tn )i ∈ P I .

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Satisfaction (cont’d) Other wffs. • |=I ¬φ[s] iff 6|=I φ[s] (i.e., iff |=I φ[s] is not the case). • |=I (φ ∧ ψ)[s] iff |=I φ[s] and |=I ψ[s]. • |=I (φ ∨ ψ)[s] iff |=I φ[s] or |=I ψ[s]. • |=I (φ ⇒ ψ)[s] iff 6|=I φ[s] or |=I ψ[s]. • |=I (φ ⇔ ψ)[s] iff |=I φ[s] and |=I ψ[s], or 6|=I φ[s] and 6|=I ψ[s].

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Satisfaction (cont’d) • |=I (∀x)φ [s] iff for all d ∈ |I|, we have |=I φ[s(x|d)]. The function s(x|d) is defined as follows:   s(y) if y = 6 x s(x|d)(y) =  d if y = x • |=I (∃x)φ [s] iff there exists d ∈ |I| such that |=I φ[s(x|d)].

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Example: the WW in FOL

4

Breeze

Stench

Breeze

3

Stench

PIT

Breeze

PIT

Gold

2

Breeze

Stench

Breeze

1

Breeze

PIT START

1

2

3

4

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Example (cont’d) If we want to formalize the WW in FOL, we can use the following symbols: • Constant symbols: Agent, W umpus, Gold, Breeze, Stench, Rm11, Rm12, . . . , Rm44 • Function symbols: – The unary function symbol N orthOf to denote the unique room which is north of the room denoted by the argument of the function. For example, the room north of room 11 is room 21. – The unary function symbols SouthOf, W estOf, EastOf with similar meanings. &

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Example (cont’d) • Predicate symbols: – The binary predicate Location will be used to denote the location (i.e. room) of each object (agent, wumpus and gold). – The binary predicate P ercept will be used to denote the percept (i.e., breeze or stench) in each room. – The unary predicate Bottomless will be used to denote that a room contains a pit.

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Example (cont’d) One could rightly object to having constant symbols R11 , R12 to model the grid of rooms etc. A better way to model the grid of rooms is to have a binary function symbol Room(x, y) where x and y are the coordinates of the room. Try this as an exercise!

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Example (cont’d) Let us now provide an interpretation I of the above symbols which corresponds to the previous picture: • The universe of I is the objects we see in the picture: |I| = {agent, wumpus, gold, breeze, stench, rm11, . . . , rm44}. • I makes the following assignments to constant symbols: AgentI = agent, W umpusI = wumpus, GoldI = gold, BreezeI = breeze, StenchI = stench, Rm11I = rm11, . . . , Rm44I = rm44 &

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

$

'

Example (cont’d) • I assigns to the unary function symbol N orthOf the function N orthOf I : |I| → |I| which is defined as follows: N orthOf I (rm11) = rm21, N orthOf I (rm21) = rm22, . . . , N orthOf I (rm34) = rm44 • I assigns to the unary function symbols SouthOf, W estOf, EastOf the function symbols SouthOf I , W estOf I , EastOf I that are defined similarly with N orthOf I .

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Example (cont’d) • I assigns to the unary predicate symbol Bottomless the following relation: {hrm13i, hrm33i, hrm44i} • I assigns to the binary predicate symbol Location the following relation: {hagent, rm11i, hwumpus, rm31i, hgold, rm32i}

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Example (cont’d) • I assigns to the binary predicate symbol P ercept the following relation: {hrm12, breezei, hrm14, breezei, hrm21, stenchi, hrm23, breezei, hrm32, breezei, hrm32, stenchi, hrm34, breezei, hrm41, stenchi, hrm43, breezei}

Note: To describe interpretation I we used words like agent, breeze, etc. which start with a lowercase letter. These are not symbols of our FOL language; they are just English words referring to what is in the picture. Instead, we could have drawn little pictures to describe the elements of the universe of the interpretation. &

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Example (cont’d) We now give examples of satisfaction: • |=I x = y[s] for any variable assignment s which maps x and y to identical objects of the universe (e.g., s(x) = s(y) = wumpus). Why? Because if s(x) = s(y) = wumpus then s(x) = s(x) = wumpus is identical to s(y) = s(y) = wumpus. • |=I Agent = Agent[s] for any variable assignments s. This is trivial.

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Example (cont’d) • |=I Rm21 = N orthOf (Rm11)[s] for any variable assignment s. Why? Because s(Rm21) = Rm21I = rm21 and s(N orthOf (Rm11)) = N orthOf I (s(Rm11)) = = N orthOf I (Rm11I ) = N orthOf I (rm11) = rm21. • |=I Rm21 = N orthOf (x)[s] for any variable assignment s such that s(x) = rm11. Why? Because s(Rm21) = Rm21I = rm21 and s(N orthOf (x)) = N orthOf I (s(x)) = N orthOf I (s(x)) = N orthOf I (rm11) = rm21. &

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Example (cont’d) • |=I Bottomless(x)[s] for any variable assignment s such that s(x) = rm13 or s(x) = rm33 or s(x) = rm44. Why? Because if s(x) = rm13 then hs(x)i = hs(x)i = hrm13i ∈ BottomlessI . Similarly, for the other cases. • |=I Location(Agent, Rm11)[s] for any variable assignments s. Why? Because hs(Agent), s(Rm11)i = hAgentI , Rm11I i = hagent, rm11i ∈ LocationI . &

%

Teqnht  NohmosÔnh '

M. Koumparˆkhc$

Example (cont’d) • |=I ¬Location(Gold, Rm44)[s] for any variable assignment s. Why? Because hs(Gold), s(Rm44)i = hGoldI , Rm44I i = hgold, rm44i 6∈ LocationI therefore 6|=I Location(Gold, Rm44)[s] for any variable assignment s. • |=I Location(Gold, Rm32) ∨ Location(Gold, Rm44)[s] for any variable assignment s. Why? Because hs(Gold), s(Rm32)i = hGoldI , Rm32I i = hgold, rm32i ∈ LocationI therefore |=I Location(Gold, Rm32)[s] for any variable assignment s. &

%

Teqnht  NohmosÔnh '

M. Koumparˆkhc$

Example (cont’d) • |=I (∃x)Location(x, Rm11)[s] for any variable assignment s. Why? Because hs(Agent), s(Rm11)i = hAgentI , Rm11I i = hagent, rm11i ∈ LocationI thus |=I Location(x, Rm11)[s(x|agent)]. • 6|=I (∀x)Location(W umpus, x)[s] for any variable assignment s. Why? Because hs(W umpus), s(Rm11)i = hW umpusI , Rm11I i = hwumpus, rm11i 6∈ LocationI thus 6|=I Location(W umpus, x)[s(x|rm11)]. &

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Satisfaction (cont’d) When we want to verify whether or not an interpretation satisfies a wff φ with s, we do not really need all of the (infinite amount of) information that s gives us. All that matters are the values of the function s at the (finitely many) variables which occur free in s. In particular, if φ is a sentence, then s does not matter at all. This is made formal by the following theorem. Theorem. Let s1 and s2 be variable assignments from V ars into |I| which agree at all variables (if any) which occur free in the wff φ. Then |=I φ[s1 ] iff |=I φ[s2 ]. &

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Satisfaction (cont’d) The previous theorem has the following corollary. Corollary. Let φ be a sentence and I an interpretation. Then, either (a) I satisfies φ with every variable assignment s : V ars → |I|, or (b) I does not satisfy φ with any variable assignment. The above corollary allows us to ignore variable assignments whenever we talk about satisfaction of sentences. Thus if φ is a sentence and I an interpretation, we can just say that I satisfies (or does not satisfy) φ. &

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Satisfiability

Definition. A formula φ is called satisfiable iff there exists an interpretation I and variable assignment s such that |=I φ[s]. Otherwise, the formula is called unsatisfiable. Examples:

The formulas

Location(W umpus, Rm31), Location(Agent, Rm11), (∃x)R(y, x) are satisfiable. The following formulas are unsatisfiable: P (x) ∧ ¬P (x), (∀x)P (x) ∧ ¬P (A) Can you write an algorithm which discovers whether a given wff is satisfiable? &

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Truth and Models

Definition. Let φ be a sentence and I an interpretation. If I satisfies φ then we will say that φ is true in I or I is a model of φ. Example: The interpretation I defined in the WW example is a model of the following sentences: Location(W umpus, Rm31), Location(Agent, Rm11), (∃x)P ercept(Breeze, x) Definition. An interpretation I is a model of a set of sentences KB iff it is a model of every member of KB. &

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Entailment

Definition. Let KB be a set of wffs, and φ a wff. Then KB entails or logically implies φ, denoted by KB |= φ, iff for every interpretation I and every variable assignment s : V ars → |I| such that I satisfies every member of KB with s, I also satisfies φ with s. Examples: { Happy(John), (∀x)(Happy(x) ⇒ Laughs(x)) } |= Laughs(John) { W ellP aid(John), ¬W ellP aid(John)∨Happy(John) } |= Happy(John) Can you give an algorithm that discovers whether a set of wffs entail a wff? &

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Validity and Equivalence

Definition. A wff φ is valid iff for every interpretation I and every variable assignment s : V ars → |I|, I satisfies φ with s. Examples:

The formulas

P (A) ∨ ¬P (A), P (A) ⇒ P (A), (∀x)P (x) ⇒ (∃x)P (x) are valid. Can you write an algorithm which discovers whether a given wff is valid? Definition. Two formulas φ and ψ will be called logically equivalent, denoted by φ ≡ ψ, iff φ |= ψ and ψ |= φ. &

Teqnht  NohmosÔnh '

%

M. Koumparˆkhc $

Satisfiability, Equivalence and Validity In the following theorems, φ and ψ are arbitrary wffs. Theorem. φ |= ψ iff φ ⇒ ψ is valid. Proof. “Only if” Let I be an arbitrary interpretation and s an arbitrary variable assignment s : V ars → |I|. We will prove that |=I (φ ⇒ ψ)[s]. We consider two cases depending on whether |=I φ[s] or not. Let us first assume that |=I φ[s]. Since φ |= ψ, we have |=I ψ[s]. Thus, from the definition of satisfaction for implication, we have |=I (φ ⇒ ψ)[s]. Let us now assume that 6|=I φ[s]. From the definition of satisfaction for implication, we can immediately conclude |=I (φ ⇒ ψ)[s]. &

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Proof (cont’d) “If” Let I be an arbitrary interpretation and s an arbitrary variable assignment s : V ars → |I|. Let us also assume that |=I φ[s]. We will prove that |=I ψ[s]. Since φ ⇒ ψ is valid, we have |=I (φ ⇒ ψ)[s]. Since we also know that |=I φ[s], we must have |=I ψ[s]. Thus, from the definition of entailment, we have φ |= ψ.

&

Teqnht  NohmosÔnh

'

%

M. Koumparˆkhc

$

Satisfiability, Equivalence and Validity (cont’d)

Theorem. φ is unsatisfiable iff ¬φ is valid. Proof? Theorem. φ ≡ ψ iff φ ⇔ ψ is valid. Proof?

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Some Important Logical Equivalences Let φ and ψ be wffs. Then: 1. ¬(φ ∧ ψ) ≡ ¬φ ∨ ¬ψ 2. ¬(φ ∨ ψ) ≡ ¬φ ∧ ¬ψ 3. φ ∧ ψ ≡ ¬(¬φ ∨ ¬ψ) 4. φ ∨ ψ ≡ ¬(¬φ ∧ ¬ψ) 5. φ ⇒ ψ ≡ ¬φ ∨ ψ 6. φ ⇔ ψ ≡ (φ ⇒ ψ) ∧ (ψ ⇒ φ) Proofs? &

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Proof of φ ⇒ ψ ≡ ¬φ ∨ ψ Let us first prove that φ ⇒ ψ |= ¬φ ∨ ψ. Let I be an arbitrary interpretation and s an arbitrary variable assignment s : V ars → |I|. Let us assume that |=I (φ ⇒ ψ)[s]. We will prove that |=I (¬φ ∨ ψ)[s]. From the definition of satisfaction for implication, we have 6|=I φ[s] or |=I ψ[s]. If 6|=I φ[s] then, from the definition of satisfaction for negation, we have |=I ¬φ[s]. Thus, from the definition of satisfaction for disjunction, we have |=I (¬φ ∨ ψ)[s]. If |=I ψ[s] then, from the definition of satisfaction for disjunction, we also have |=I (¬φ ∨ ψ)[s]. &

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Proof (cont’d) Let us now prove that ¬φ ∨ ψ |= φ ⇒ ψ. Let I be an arbitrary interpretation and s an arbitrary variable assignment s : V ars → |I|. Let us assume that |=I (¬φ ∨ ψ)[s]. We will prove that |=I (φ ⇒ ψ)[s]. From the definition of satisfaction for disjunction, we have |=I ¬φ[s] or |=I ψ[s]. We consider these two cases below. If |=I ¬φ[s] then, from the definition of satisfaction for negation, we have 6|=I φ[s]. Thus, from the definition of satisfaction for implication, we have |=I (φ ⇒ ψ)[s]. If |=I ψ[s] then we can immediately conclude |=I (φ ⇒ ψ)[s] from the definition of satisfaction for implication. &

Teqnht  NohmosÔnh

'

%

M. Koumparˆkhc

$

Some Important Logical Equivalences (cont’d) 1. (∀x)φ ≡ ¬(∃x)¬φ 2. (∃x)φ ≡ ¬(∀x)¬φ 3. (∀x)¬φ ≡ ¬(∃x)φ 4. (∃x)¬φ ≡ ¬(∀x)φ Proofs?

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Some Important Logical Equivalences (cont’d) 1. (∃x)(φ ∨ ψ) ≡ (∃x)φ ∨ (∃x)ψ 2. (∃x)(φ ∧ ψ) |= (∃x)φ ∧ (∃x)ψ 3. (∀x)φ ∨ (∀x)ψ |= (∀x)(φ ∨ ψ) 4. (∀x)(φ ∧ ψ) ≡ (∀x)φ ∧ (∀x)ψ Proofs?

&

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

One of the Proofs Prove that (∃x)(φ(x) ∧ ψ(x)) |= (∃x)φ(x) ∧ (∃x)ψ(x). Proof: Let I be an interpretation and s a variable assignment such that |=I (∃x)(φ(x) ∧ ψ(x))[s]. Then according to the definition of satisfaction for existential statements, there exists a d ∈ |I| such that |=I (φ(x) ∧ ψ(x))[s(x|d)]. Then according to the definition of satisfaction for conjunctive statements, we have |=I φ(x)[s(x|d)] &

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

and |=I ψ(x)[s(x|d)]. Now from the definition of satisfaction for existential statements again, we have |=I (∃x)φ(x)[s] and |=I (∃x)ψ(x)[s]. Now from the definition of satisfaction for conjunctive statements we have: |=I (∃x)φ(x) ∧ (∃x)ψ(x)[s]. The proof is now finished.

&

%

Teqnht  NohmosÔnh

'

M. Koumparˆkhc

$

Representing Knowledge Using FOL

Definition. In knowledge representation, a domain is a section of the world about which we wish to express some knowledge. • The domain of family relationships. • The domain of sets. • The wumpus domain. • The domain of web resources (HTML pages, images, programs etc. on the WWW) • ... &

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Knowledge Engineering The process of knowledge-base construction is called knowledge engineering. A knowledge engineer is someone who investigates a particular domain, determines what concepts are important in that domain, and creates a formal representation of the objects and relations in that domain. If you want to see how FOL can be applied to represent knowledge in various sophisticated application domains, see Chapter 10 of the AIMA book (we will not cover it in the course). &

%

Teqnht  NohmosÔnh

'

M. Koumparˆkhc

$

Other Logics in Computer Science FOL is certainly the most important logic in use today by computer scientists. But there are others too: • Second-order logic • Modal logic (with operators such as “possible” and “certain”) • Temporal logic (with operators such as “in the past”, etc.) • Logics of knowledge and belief • Logics for databases • .... &

%

Teqnht  NohmosÔnh

M. Koumparˆkhc

'

$

Readings Chapter 8 of AIMA: First-Order Logic Other formal presentations of FOL can be found in: 1. Any mathematical logic textbook. Most of the formal material in these notes is from: H.B. Enderton, “A Mathematical Introduction to Logic”, Academic Press, 1972. See the Web page of the course for more details. 2. M.R. Genesereth and N.J. Nilsson, “Logical Foundations of Artificial Intelligence”, Morgan Kaufmann, 1987. &

%