Outline
First Order Logic - Syntax and Semantics
K. Subramani1
1Lane Department of Computer Science and Electrical Engineering West Virginia University
30 January, 4 February, 6 February 2013
Subramani First Order Logic Outline Outline
1 Motivation
Subramani First Order Logic Outline Outline
1 Motivation
2 Syntax Translation
Subramani First Order Logic Outline Outline
1 Motivation
2 Syntax Translation
3 Semantics
Subramani First Order Logic Motivation Syntax Semantics First Order Logic
Subramani First Order Logic Motivation Syntax Semantics First Order Logic
Limitations of Propositional Logic
Subramani First Order Logic Motivation Syntax Semantics First Order Logic
Limitations of Propositional Logic Propositional Logic has limited expressiveness.
Subramani First Order Logic Motivation Syntax Semantics First Order Logic
Limitations of Propositional Logic Propositional Logic has limited expressiveness. For instance, how would you capture the assertion, “Property P is true of every positive number”?
Subramani First Order Logic Motivation Syntax Semantics First Order Logic
Limitations of Propositional Logic Propositional Logic has limited expressiveness. For instance, how would you capture the assertion, “Property P is true of every positive number”? P1 ∧ P2 ... P∞ is neither compact nor useful.
Subramani First Order Logic Motivation Syntax Semantics First Order Logic
Limitations of Propositional Logic Propositional Logic has limited expressiveness. For instance, how would you capture the assertion, “Property P is true of every positive number”? P1 ∧ P2 ... P∞ is neither compact nor useful. First-order Logic (FOL) extends Propositional Logic (PL) with predicates, functions and quantifiers.
Subramani First Order Logic Motivation Syntax Translation Semantics Syntax of FOL
Subramani First Order Logic Motivation Syntax Translation Semantics Syntax of FOL
Basics
Subramani First Order Logic Motivation Syntax Translation Semantics Syntax of FOL
Basics (i) Predicates are used to describe properties of objects. e.g., P(x) could stand for the property that x is divisible by 3.
Subramani First Order Logic Motivation Syntax Translation Semantics Syntax of FOL
Basics (i) Predicates are used to describe properties of objects. e.g., P(x) could stand for the property that x is divisible by 3. (ii) The universal quantifier (∀x)P(x) indicates that property P holds for all x in some domain.
Subramani First Order Logic Motivation Syntax Translation Semantics Syntax of FOL
Basics (i) Predicates are used to describe properties of objects. e.g., P(x) could stand for the property that x is divisible by 3. (ii) The universal quantifier (∀x)P(x) indicates that property P holds for all x in some domain. (iii) The existential quantifier (∃x)P(x) indicates that property P holds for some x in some domain.
Subramani First Order Logic Motivation Syntax Translation Semantics Syntax of FOL
Basics (i) Predicates are used to describe properties of objects. e.g., P(x) could stand for the property that x is divisible by 3. (ii) The universal quantifier (∀x)P(x) indicates that property P holds for all x in some domain. (iii) The existential quantifier (∃x)P(x) indicates that property P holds for some x in some domain. (iv) A function is a mapping from the domain of interest to a range.
Subramani First Order Logic Motivation Syntax Translation Semantics Syntax of FOL
Basics (i) Predicates are used to describe properties of objects. e.g., P(x) could stand for the property that x is divisible by 3. (ii) The universal quantifier (∀x)P(x) indicates that property P holds for all x in some domain. (iii) The existential quantifier (∃x)P(x) indicates that property P holds for some x in some domain. (iv) A function is a mapping from the domain of interest to a range. (v) Variables are used as placeholders (0-ary predicates).
Subramani First Order Logic Motivation Syntax Translation Semantics Syntax of FOL
Basics (i) Predicates are used to describe properties of objects. e.g., P(x) could stand for the property that x is divisible by 3. (ii) The universal quantifier (∀x)P(x) indicates that property P holds for all x in some domain. (iii) The existential quantifier (∃x)P(x) indicates that property P holds for some x in some domain. (iv) A function is a mapping from the domain of interest to a range. (v) Variables are used as placeholders (0-ary predicates). (vi) Constants are used to represent values that do not change.
Subramani First Order Logic Motivation Syntax Translation Semantics Syntax of FOL
Basics (i) Predicates are used to describe properties of objects. e.g., P(x) could stand for the property that x is divisible by 3. (ii) The universal quantifier (∀x)P(x) indicates that property P holds for all x in some domain. (iii) The existential quantifier (∃x)P(x) indicates that property P holds for some x in some domain. (iv) A function is a mapping from the domain of interest to a range. (v) Variables are used as placeholders (0-ary predicates). (vi) Constants are used to represent values that do not change. (vii) Terms, atom, literal, formula.
Subramani First Order Logic Motivation Syntax Translation Semantics Scope
Subramani First Order Logic Motivation Syntax Translation Semantics Scope
Bound and Free variables
Subramani First Order Logic Motivation Syntax Translation Semantics Scope
Bound and Free variables Consider the expression:
(∀x)[Q(x, y) → (∃y)R(x, y)]
Subramani First Order Logic Motivation Syntax Translation Semantics Scope
Bound and Free variables Consider the expression:
(∀x)[Q(x, y) → (∃y)R(x, y)]
The x occurrences are bound to the (∀x) quantifier.
Subramani First Order Logic Motivation Syntax Translation Semantics Scope
Bound and Free variables Consider the expression:
(∀x)[Q(x, y) → (∃y)R(x, y)]
The x occurrences are bound to the (∀x) quantifier. The first y is said to be a free variable, since it is not bound to any quantifier.
Subramani First Order Logic Motivation Syntax Translation Semantics Scope
Bound and Free variables Consider the expression:
(∀x)[Q(x, y) → (∃y)R(x, y)]
The x occurrences are bound to the (∀x) quantifier. The first y is said to be a free variable, since it is not bound to any quantifier. The scope of a quantifier is the portion of the predicate formula to which it applies.
Subramani First Order Logic Motivation Syntax Translation Semantics Scope
Bound and Free variables Consider the expression:
(∀x)[Q(x, y) → (∃y)R(x, y)]
The x occurrences are bound to the (∀x) quantifier. The first y is said to be a free variable, since it is not bound to any quantifier. The scope of a quantifier is the portion of the predicate formula to which it applies. A formula F is closed if it has no free variables.
Subramani First Order Logic Motivation Syntax Translation Semantics Scope
Bound and Free variables Consider the expression:
(∀x)[Q(x, y) → (∃y)R(x, y)]
The x occurrences are bound to the (∀x) quantifier. The first y is said to be a free variable, since it is not bound to any quantifier. The scope of a quantifier is the portion of the predicate formula to which it applies. A formula F is closed if it has no free variables.
Closures
Subramani First Order Logic Motivation Syntax Translation Semantics Scope
Bound and Free variables Consider the expression:
(∀x)[Q(x, y) → (∃y)R(x, y)]
The x occurrences are bound to the (∀x) quantifier. The first y is said to be a free variable, since it is not bound to any quantifier. The scope of a quantifier is the portion of the predicate formula to which it applies. A formula F is closed if it has no free variables.
Closures (i) Existential closure.
Subramani First Order Logic Motivation Syntax Translation Semantics Scope
Bound and Free variables Consider the expression:
(∀x)[Q(x, y) → (∃y)R(x, y)]
The x occurrences are bound to the (∀x) quantifier. The first y is said to be a free variable, since it is not bound to any quantifier. The scope of a quantifier is the portion of the predicate formula to which it applies. A formula F is closed if it has no free variables.
Closures (i) Existential closure. (ii) Universal closure.
Subramani First Order Logic Motivation Syntax Translation Semantics Scope
Bound and Free variables Consider the expression:
(∀x)[Q(x, y) → (∃y)R(x, y)]
The x occurrences are bound to the (∀x) quantifier. The first y is said to be a free variable, since it is not bound to any quantifier. The scope of a quantifier is the portion of the predicate formula to which it applies. A formula F is closed if it has no free variables.
Closures (i) Existential closure. (ii) Universal closure.
Subformulas and Subterms
Subramani First Order Logic Motivation Syntax Translation Semantics Scope
Bound and Free variables Consider the expression:
(∀x)[Q(x, y) → (∃y)R(x, y)]
The x occurrences are bound to the (∀x) quantifier. The first y is said to be a free variable, since it is not bound to any quantifier. The scope of a quantifier is the portion of the predicate formula to which it applies. A formula F is closed if it has no free variables.
Closures (i) Existential closure. (ii) Universal closure.
Subformulas and Subterms
1 Subformulas and strict subformulas.
Subramani First Order Logic Motivation Syntax Translation Semantics Scope
Bound and Free variables Consider the expression:
(∀x)[Q(x, y) → (∃y)R(x, y)]
The x occurrences are bound to the (∀x) quantifier. The first y is said to be a free variable, since it is not bound to any quantifier. The scope of a quantifier is the portion of the predicate formula to which it applies. A formula F is closed if it has no free variables.
Closures (i) Existential closure. (ii) Universal closure.
Subformulas and Subterms
1 Subformulas and strict subformulas. 2 Subterms and strict subterms.
Subramani First Order Logic Motivation Syntax Translation Semantics Outline
1 Motivation
2 Syntax Translation
3 Semantics
Subramani First Order Logic Motivation Syntax Translation Semantics Converting English to Predicate Logic
Subramani First Order Logic Motivation Syntax Translation Semantics Converting English to Predicate Logic
Note Not an easy task!
Subramani First Order Logic Motivation Syntax Translation Semantics Converting English to Predicate Logic
Note Not an easy task! More than one result possible, depending on semantics of English language (which is not unambiguous).
Subramani First Order Logic Motivation Syntax Translation Semantics Converting English to Predicate Logic
Note Not an easy task! More than one result possible, depending on semantics of English language (which is not unambiguous). “Hang him not, let him free” and “Hang him, not let him free”!
Subramani First Order Logic Motivation Syntax Translation Semantics Converting English to Predicate Logic
Note Not an easy task! More than one result possible, depending on semantics of English language (which is not unambiguous). “Hang him not, let him free” and “Hang him, not let him free”!
Example
Subramani First Order Logic Motivation Syntax Translation Semantics Converting English to Predicate Logic
Note Not an easy task! More than one result possible, depending on semantics of English language (which is not unambiguous). “Hang him not, let him free” and “Hang him, not let him free”!
Example (i) All parrots are ugly.
Subramani First Order Logic Motivation Syntax Translation Semantics Converting English to Predicate Logic
Note Not an easy task! More than one result possible, depending on semantics of English language (which is not unambiguous). “Hang him not, let him free” and “Hang him, not let him free”!
Example (i) All parrots are ugly. (∀x)[P(x) → U(x)].
Subramani First Order Logic Motivation Syntax Translation Semantics Converting English to Predicate Logic
Note Not an easy task! More than one result possible, depending on semantics of English language (which is not unambiguous). “Hang him not, let him free” and “Hang him, not let him free”!
Example (i) All parrots are ugly. (∀x)[P(x) → U(x)]. (ii) Some parrots are ugly.
Subramani First Order Logic Motivation Syntax Translation Semantics Converting English to Predicate Logic
Note Not an easy task! More than one result possible, depending on semantics of English language (which is not unambiguous). “Hang him not, let him free” and “Hang him, not let him free”!
Example (i) All parrots are ugly. (∀x)[P(x) → U(x)]. (ii) Some parrots are ugly. (∃x)[P(x) ∧ U(x)].
Subramani First Order Logic Motivation Syntax Translation Semantics Converting English to Predicate Logic
Note Not an easy task! More than one result possible, depending on semantics of English language (which is not unambiguous). “Hang him not, let him free” and “Hang him, not let him free”!
Example (i) All parrots are ugly. (∀x)[P(x) → U(x)]. (ii) Some parrots are ugly. (∃x)[P(x) ∧ U(x)]. (iii) All dogs chase all rabbits.
Subramani First Order Logic Motivation Syntax Translation Semantics Converting English to Predicate Logic
Note Not an easy task! More than one result possible, depending on semantics of English language (which is not unambiguous). “Hang him not, let him free” and “Hang him, not let him free”!
Example (i) All parrots are ugly. (∀x)[P(x) → U(x)]. (ii) Some parrots are ugly. (∃x)[P(x) ∧ U(x)]. (iii) All dogs chase all rabbits. (∀x)[D(x) → (∀y)[R(y) → C(x, y)]].
Subramani First Order Logic Motivation Syntax Translation Semantics Converting English to Predicate Logic
Note Not an easy task! More than one result possible, depending on semantics of English language (which is not unambiguous). “Hang him not, let him free” and “Hang him, not let him free”!
Example (i) All parrots are ugly. (∀x)[P(x) → U(x)]. (ii) Some parrots are ugly. (∃x)[P(x) ∧ U(x)]. (iii) All dogs chase all rabbits. (∀x)[D(x) → (∀y)[R(y) → C(x, y)]]. (iv) Some dogs chase all rabbits.
Subramani First Order Logic Motivation Syntax Translation Semantics Converting English to Predicate Logic
Note Not an easy task! More than one result possible, depending on semantics of English language (which is not unambiguous). “Hang him not, let him free” and “Hang him, not let him free”!
Example (i) All parrots are ugly. (∀x)[P(x) → U(x)]. (ii) Some parrots are ugly. (∃x)[P(x) ∧ U(x)]. (iii) All dogs chase all rabbits. (∀x)[D(x) → (∀y)[R(y) → C(x, y)]]. (iv) Some dogs chase all rabbits. (∃x)[D(x) ∧ (∀y)[R(y) → C(x, y)]].
Subramani First Order Logic Motivation Syntax Translation Semantics Exercise
Exercise Let S(x) denote “x is a student”, I(x) denote “x is intelligent” and M(x) denote “x likes music”.
Subramani First Order Logic Motivation Syntax Translation Semantics Exercise
Exercise Let S(x) denote “x is a student”, I(x) denote “x is intelligent” and M(x) denote “x likes music”. Give predicate wffs for: (i) All students are intelligent. (ii) Some intelligent students like music. (iii) Only intelligent students like music.
Subramani First Order Logic Motivation Syntax Translation Semantics Exercise
Exercise Let S(x) denote “x is a student”, I(x) denote “x is intelligent” and M(x) denote “x likes music”. Give predicate wffs for: (i) All students are intelligent. (ii) Some intelligent students like music. (iii) Only intelligent students like music.
Solution (i) (∀x)[S(x) → I(x)].
Subramani First Order Logic Motivation Syntax Translation Semantics Exercise
Exercise Let S(x) denote “x is a student”, I(x) denote “x is intelligent” and M(x) denote “x likes music”. Give predicate wffs for: (i) All students are intelligent. (ii) Some intelligent students like music. (iii) Only intelligent students like music.
Solution (i) (∀x)[S(x) → I(x)]. (ii) (∃x)[S(x) ∧ I(x) ∧ M(x)].
Subramani First Order Logic Motivation Syntax Translation Semantics Exercise
Exercise Let S(x) denote “x is a student”, I(x) denote “x is intelligent” and M(x) denote “x likes music”. Give predicate wffs for: (i) All students are intelligent. (ii) Some intelligent students like music. (iii) Only intelligent students like music.
Solution (i) (∀x)[S(x) → I(x)]. (ii) (∃x)[S(x) ∧ I(x) ∧ M(x)]. (iii) (∀x)[M(x) → [S(x) ∧ I(x)]].
Subramani First Order Logic Motivation Syntax Translation Semantics FOL in mathematics
Subramani First Order Logic Motivation Syntax Translation Semantics FOL in mathematics
Example
Subramani First Order Logic Motivation Syntax Translation Semantics FOL in mathematics
Example (i) The length of one side of a triangle is less than the sum of the lengths of the other two sides.
Subramani First Order Logic Motivation Syntax Translation Semantics FOL in mathematics
Example (i) The length of one side of a triangle is less than the sum of the lengths of the other two sides. (ii) Fermat’s last theorem.
Subramani First Order Logic Motivation Syntax Semantics Semantics
Subramani First Order Logic Motivation Syntax Semantics Semantics
Main Points
Subramani First Order Logic Motivation Syntax Semantics Semantics
Main Points (i) As with propositional logic, a FOL formula evaluates to true or false.
Subramani First Order Logic Motivation Syntax Semantics Semantics
Main Points (i) As with propositional logic, a FOL formula evaluates to true or false. (ii) Terms of a FOL formula evaluate to values from a specified domain.
Subramani First Order Logic Motivation Syntax Semantics Semantics
Main Points (i) As with propositional logic, a FOL formula evaluates to true or false. (ii) Terms of a FOL formula evaluate to values from a specified domain. (iii) A first order interpretation I,
Subramani First Order Logic Motivation Syntax Semantics Semantics
Main Points (i) As with propositional logic, a FOL formula evaluates to true or false. (ii) Terms of a FOL formula evaluate to values from a specified domain.
(iii) A first order interpretation I, is a 2-tuple (DI , αI ), where DI is a non-empty set called the domain of interpretation and αI is an assignment function.
Subramani First Order Logic Motivation Syntax Semantics Semantics
Main Points (i) As with propositional logic, a FOL formula evaluates to true or false. (ii) Terms of a FOL formula evaluate to values from a specified domain.
(iii) A first order interpretation I, is a 2-tuple (DI , αI ), where DI is a non-empty set called the domain of interpretation and αI is an assignment function. The assignment function maps constants and variables in the expression to objects in the domain,
Subramani First Order Logic Motivation Syntax Semantics Semantics
Main Points (i) As with propositional logic, a FOL formula evaluates to true or false. (ii) Terms of a FOL formula evaluate to values from a specified domain.
(iii) A first order interpretation I, is a 2-tuple (DI , αI ), where DI is a non-empty set called the domain of interpretation and αI is an assignment function. The assignment function maps constants and variables in the expression to objects in the domain, predicates in the domain to properties of objects in the domain,
Subramani First Order Logic Motivation Syntax Semantics Semantics
Main Points (i) As with propositional logic, a FOL formula evaluates to true or false. (ii) Terms of a FOL formula evaluate to values from a specified domain.
(iii) A first order interpretation I, is a 2-tuple (DI , αI ), where DI is a non-empty set called the domain of interpretation and αI is an assignment function. The assignment function maps constants and variables in the expression to objects in the domain, predicates in the domain to properties of objects in the domain, and functions in the expression to functions over the domain,
Subramani First Order Logic Motivation Syntax Semantics Semantics
Main Points (i) As with propositional logic, a FOL formula evaluates to true or false. (ii) Terms of a FOL formula evaluate to values from a specified domain.
(iii) A first order interpretation I, is a 2-tuple (DI , αI ), where DI is a non-empty set called the domain of interpretation and αI is an assignment function. The assignment function maps constants and variables in the expression to objects in the domain, predicates in the domain to properties of objects in the domain, and functions in the expression to functions over the domain, respecting arity.
Subramani First Order Logic Motivation Syntax Semantics Semantics
Main Points (i) As with propositional logic, a FOL formula evaluates to true or false. (ii) Terms of a FOL formula evaluate to values from a specified domain.
(iii) A first order interpretation I, is a 2-tuple (DI , αI ), where DI is a non-empty set called the domain of interpretation and αI is an assignment function. The assignment function maps constants and variables in the expression to objects in the domain, predicates in the domain to properties of objects in the domain, and functions in the expression to functions over the domain, respecting arity.
Example What is the truth-value of
Subramani First Order Logic Motivation Syntax Semantics Semantics
Main Points (i) As with propositional logic, a FOL formula evaluates to true or false. (ii) Terms of a FOL formula evaluate to values from a specified domain.
(iii) A first order interpretation I, is a 2-tuple (DI , αI ), where DI is a non-empty set called the domain of interpretation and αI is an assignment function. The assignment function maps constants and variables in the expression to objects in the domain, predicates in the domain to properties of objects in the domain, and functions in the expression to functions over the domain, respecting arity.
Example What is the truth-value of (i) F : x + y ≥ z → y ≥ z − x?
Subramani First Order Logic Motivation Syntax Semantics Semantics
Main Points (i) As with propositional logic, a FOL formula evaluates to true or false. (ii) Terms of a FOL formula evaluate to values from a specified domain.
(iii) A first order interpretation I, is a 2-tuple (DI , αI ), where DI is a non-empty set called the domain of interpretation and αI is an assignment function. The assignment function maps constants and variables in the expression to objects in the domain, predicates in the domain to properties of objects in the domain, and functions in the expression to functions over the domain, respecting arity.
Example What is the truth-value of (i) F : x + y ≥ z → y ≥ z − x? (ii) G : (∀x) P(x, a)?
Subramani First Order Logic Motivation Syntax Semantics Semantics
Main Points (i) As with propositional logic, a FOL formula evaluates to true or false. (ii) Terms of a FOL formula evaluate to values from a specified domain.
(iii) A first order interpretation I, is a 2-tuple (DI , αI ), where DI is a non-empty set called the domain of interpretation and αI is an assignment function. The assignment function maps constants and variables in the expression to objects in the domain, predicates in the domain to properties of objects in the domain, and functions in the expression to functions over the domain, respecting arity.
Example What is the truth-value of (i) F : x + y ≥ z → y ≥ z − x? (ii) G : (∀x) P(x, a)? These questions are meaningless without the interpretation! Consider the following interpretation for G:
Subramani First Order Logic Motivation Syntax Semantics Semantics
Main Points (i) As with propositional logic, a FOL formula evaluates to true or false. (ii) Terms of a FOL formula evaluate to values from a specified domain.
(iii) A first order interpretation I, is a 2-tuple (DI , αI ), where DI is a non-empty set called the domain of interpretation and αI is an assignment function. The assignment function maps constants and variables in the expression to objects in the domain, predicates in the domain to properties of objects in the domain, and functions in the expression to functions over the domain, respecting arity.
Example What is the truth-value of (i) F : x + y ≥ z → y ≥ z − x? (ii) G : (∀x) P(x, a)? These questions are meaningless without the interpretation! Consider the following interpretation for G: The domain is the set of natural numbers N = {0, 1,..., }, P(x, y) stands for x ≥ y and a is 0.
Subramani First Order Logic Motivation Syntax Semantics Semantics
Main Points (i) As with propositional logic, a FOL formula evaluates to true or false. (ii) Terms of a FOL formula evaluate to values from a specified domain.
(iii) A first order interpretation I, is a 2-tuple (DI , αI ), where DI is a non-empty set called the domain of interpretation and αI is an assignment function. The assignment function maps constants and variables in the expression to objects in the domain, predicates in the domain to properties of objects in the domain, and functions in the expression to functions over the domain, respecting arity.
Example What is the truth-value of (i) F : x + y ≥ z → y ≥ z − x? (ii) G : (∀x) P(x, a)? These questions are meaningless without the interpretation! Consider the following interpretation for G: The domain is the set of natural numbers N = {0, 1,..., }, P(x, y) stands for x ≥ y and a is 0. Clearly, in this interpretation, the expression is true.
Subramani First Order Logic Motivation Syntax Semantics Semantics
Main Points (i) As with propositional logic, a FOL formula evaluates to true or false. (ii) Terms of a FOL formula evaluate to values from a specified domain.
(iii) A first order interpretation I, is a 2-tuple (DI , αI ), where DI is a non-empty set called the domain of interpretation and αI is an assignment function. The assignment function maps constants and variables in the expression to objects in the domain, predicates in the domain to properties of objects in the domain, and functions in the expression to functions over the domain, respecting arity.
Example What is the truth-value of (i) F : x + y ≥ z → y ≥ z − x? (ii) G : (∀x) P(x, a)? These questions are meaningless without the interpretation! Consider the following interpretation for G: The domain is the set of natural numbers N = {0, 1,..., }, P(x, y) stands for x ≥ y and a is 0. Clearly, in this interpretation, the expression is true. Can you think of an interpretation in which G is false?
Subramani First Order Logic Motivation Syntax Semantics Inductive definition of semantics
Subramani First Order Logic Motivation Syntax Semantics Inductive definition of semantics
Goal
Given a FOL formula F and an interpretation I : (DI , αI ), we want to compute if F evaluates to true, under that interpretation.
Subramani First Order Logic Motivation Syntax Semantics Inductive definition of semantics
Goal
Given a FOL formula F and an interpretation I : (DI , αI ), we want to compute if F evaluates to true, under that interpretation.
Truth Symbols
Subramani First Order Logic Motivation Syntax Semantics Inductive definition of semantics
Goal
Given a FOL formula F and an interpretation I : (DI , αI ), we want to compute if F evaluates to true, under that interpretation.
Truth Symbols (i) I |= ⊤.
Subramani First Order Logic Motivation Syntax Semantics Inductive definition of semantics
Goal
Given a FOL formula F and an interpretation I : (DI , αI ), we want to compute if F evaluates to true, under that interpretation.
Truth Symbols (i) I |= ⊤. (ii) I 6|=⊥.
Subramani First Order Logic Motivation Syntax Semantics Inductive definition of semantics
Goal
Given a FOL formula F and an interpretation I : (DI , αI ), we want to compute if F evaluates to true, under that interpretation.
Truth Symbols (i) I |= ⊤. (ii) I 6|=⊥.
Atoms
Subramani First Order Logic Motivation Syntax Semantics Inductive definition of semantics
Goal
Given a FOL formula F and an interpretation I : (DI , αI ), we want to compute if F evaluates to true, under that interpretation.
Truth Symbols (i) I |= ⊤. (ii) I 6|=⊥.
Atoms
Use the assignment function αI to recursively evaluate arbitrary terms and arbitrary atoms.
Subramani First Order Logic Motivation Syntax Semantics Inductive definition of semantics
Goal
Given a FOL formula F and an interpretation I : (DI , αI ), we want to compute if F evaluates to true, under that interpretation.
Truth Symbols (i) I |= ⊤. (ii) I 6|=⊥.
Atoms
Use the assignment function αI to recursively evaluate arbitrary terms and arbitrary atoms. For instance,
Subramani First Order Logic Motivation Syntax Semantics Inductive definition of semantics
Goal
Given a FOL formula F and an interpretation I : (DI , αI ), we want to compute if F evaluates to true, under that interpretation.
Truth Symbols (i) I |= ⊤. (ii) I 6|=⊥.
Atoms
Use the assignment function αI to recursively evaluate arbitrary terms and arbitrary atoms. For instance,
(i) αI [f (t1, t2,... tn)] =
Subramani First Order Logic Motivation Syntax Semantics Inductive definition of semantics
Goal
Given a FOL formula F and an interpretation I : (DI , αI ), we want to compute if F evaluates to true, under that interpretation.
Truth Symbols (i) I |= ⊤. (ii) I 6|=⊥.
Atoms
Use the assignment function αI to recursively evaluate arbitrary terms and arbitrary atoms. For instance,
(i) αI [f (t1, t2,... tn)] = αI [f (αI [t1], αI [t2],...αI [tn]].
Subramani First Order Logic Motivation Syntax Semantics Inductive definition of semantics
Goal
Given a FOL formula F and an interpretation I : (DI , αI ), we want to compute if F evaluates to true, under that interpretation.
Truth Symbols (i) I |= ⊤. (ii) I 6|=⊥.
Atoms
Use the assignment function αI to recursively evaluate arbitrary terms and arbitrary atoms. For instance,
(i) αI [f (t1, t2,... tn)] = αI [f (αI [t1], αI [t2],...αI [tn]].
(ii) αI [p(t1, t2,... tn)] =
Subramani First Order Logic Motivation Syntax Semantics Inductive definition of semantics
Goal
Given a FOL formula F and an interpretation I : (DI , αI ), we want to compute if F evaluates to true, under that interpretation.
Truth Symbols (i) I |= ⊤. (ii) I 6|=⊥.
Atoms
Use the assignment function αI to recursively evaluate arbitrary terms and arbitrary atoms. For instance,
(i) αI [f (t1, t2,... tn)] = αI [f (αI [t1], αI [t2],...αI [tn]].
(ii) αI [p(t1, t2,... tn)] = αI [p(αI [t1], αI [t2],...αI [tn]].
Subramani First Order Logic Motivation Syntax Semantics Inductive definition of semantics
Goal
Given a FOL formula F and an interpretation I : (DI , αI ), we want to compute if F evaluates to true, under that interpretation.
Truth Symbols (i) I |= ⊤. (ii) I 6|=⊥.
Atoms
Use the assignment function αI to recursively evaluate arbitrary terms and arbitrary atoms. For instance,
(i) αI [f (t1, t2,... tn)] = αI [f (αI [t1], αI [t2],...αI [tn]].
(ii) αI [p(t1, t2,... tn)] = αI [p(αI [t1], αI [t2],...αI [tn]]. Then I |= p(t1, t2,... tn) iff
Subramani First Order Logic Motivation Syntax Semantics Inductive definition of semantics
Goal
Given a FOL formula F and an interpretation I : (DI , αI ), we want to compute if F evaluates to true, under that interpretation.
Truth Symbols (i) I |= ⊤. (ii) I 6|=⊥.
Atoms
Use the assignment function αI to recursively evaluate arbitrary terms and arbitrary atoms. For instance,
(i) αI [f (t1, t2,... tn)] = αI [f (αI [t1], αI [t2],...αI [tn]].
(ii) αI [p(t1, t2,... tn)] = αI [p(αI [t1], αI [t2],...αI [tn]]. Then I |= p(t1, t2,... tn) iff αI [p(αI [t1], αI [t2],...αI [tn]] = true.
Subramani First Order Logic Motivation Syntax Semantics Completing the induction
Subramani First Order Logic Motivation Syntax Semantics Completing the induction
General unquantified FOL formulas
Subramani First Order Logic Motivation Syntax Semantics Completing the induction
General unquantified FOL formulas (i) I |= ¬F iff I 6|= F.
Subramani First Order Logic Motivation Syntax Semantics Completing the induction
General unquantified FOL formulas (i) I |= ¬F iff I 6|= F.
(ii) I |= F1 ∧ F2 iff I |= F1 and I |= F2.
Subramani First Order Logic Motivation Syntax Semantics Completing the induction
General unquantified FOL formulas (i) I |= ¬F iff I 6|= F.
(ii) I |= F1 ∧ F2 iff I |= F1 and I |= F2.
(iii) I |= F1 ∨ F2 iff I |= F1 or I |= F2.
Subramani First Order Logic Motivation Syntax Semantics Completing the induction
General unquantified FOL formulas (i) I |= ¬F iff I 6|= F.
(ii) I |= F1 ∧ F2 iff I |= F1 and I |= F2.
(iii) I |= F1 ∨ F2 iff I |= F1 or I |= F2.
(iv) I |= F1 → F2 iff if I |= F1, then I |= F2.
Subramani First Order Logic Motivation Syntax Semantics Completing the induction
General unquantified FOL formulas (i) I |= ¬F iff I 6|= F.
(ii) I |= F1 ∧ F2 iff I |= F1 and I |= F2.
(iii) I |= F1 ∨ F2 iff I |= F1 or I |= F2.
(iv) I |= F1 → F2 iff if I |= F1, then I |= F2.
Quantified Formulas
Subramani First Order Logic Motivation Syntax Semantics Completing the induction
General unquantified FOL formulas (i) I |= ¬F iff I 6|= F.
(ii) I |= F1 ∧ F2 iff I |= F1 and I |= F2.
(iii) I |= F1 ∨ F2 iff I |= F1 or I |= F2.
(iv) I |= F1 → F2 iff if I |= F1, then I |= F2.
Quantified Formulas (i) I |= (∀x) F if and only if for every v ∈ D, I ⊳ {x 7→ v}|= F.
Subramani First Order Logic Motivation Syntax Semantics Completing the induction
General unquantified FOL formulas (i) I |= ¬F iff I 6|= F.
(ii) I |= F1 ∧ F2 iff I |= F1 and I |= F2.
(iii) I |= F1 ∨ F2 iff I |= F1 or I |= F2.
(iv) I |= F1 → F2 iff if I |= F1, then I |= F2.
Quantified Formulas (i) I |= (∀x) F if and only if for every v ∈ D, I ⊳ {x 7→ v}|= F. (ii) I |= (∃x) F if and only if there exists some v ∈ D, I ⊳ {x 7→ v}|= F.
Subramani First Order Logic Motivation Syntax Semantics Completing the induction
General unquantified FOL formulas (i) I |= ¬F iff I 6|= F.
(ii) I |= F1 ∧ F2 iff I |= F1 and I |= F2.
(iii) I |= F1 ∨ F2 iff I |= F1 or I |= F2.
(iv) I |= F1 → F2 iff if I |= F1, then I |= F2.
Quantified Formulas (i) I |= (∀x) F if and only if for every v ∈ D, I ⊳ {x 7→ v}|= F. (ii) I |= (∃x) F if and only if there exists some v ∈ D, I ⊳ {x 7→ v}|= F.
Example Consider the formula F : x + y > z → y > z − x.
Subramani First Order Logic Motivation Syntax Semantics Completing the induction
General unquantified FOL formulas (i) I |= ¬F iff I 6|= F.
(ii) I |= F1 ∧ F2 iff I |= F1 and I |= F2.
(iii) I |= F1 ∨ F2 iff I |= F1 or I |= F2.
(iv) I |= F1 → F2 iff if I |= F1, then I |= F2.
Quantified Formulas (i) I |= (∀x) F if and only if for every v ∈ D, I ⊳ {x 7→ v}|= F. (ii) I |= (∃x) F if and only if there exists some v ∈ D, I ⊳ {x 7→ v}|= F.
Example Consider the formula F : x + y > z → y > z − x. Is F true
Subramani First Order Logic Motivation Syntax Semantics Completing the induction
General unquantified FOL formulas (i) I |= ¬F iff I 6|= F.
(ii) I |= F1 ∧ F2 iff I |= F1 and I |= F2.
(iii) I |= F1 ∨ F2 iff I |= F1 or I |= F2.
(iv) I |= F1 → F2 iff if I |= F1, then I |= F2.
Quantified Formulas (i) I |= (∀x) F if and only if for every v ∈ D, I ⊳ {x 7→ v}|= F. (ii) I |= (∃x) F if and only if there exists some v ∈ D, I ⊳ {x 7→ v}|= F.
Example Consider the formula F : x + y > z → y > z − x. Is F true under the interpretation I : (Z, αI ), where αI : {+ 7→ +Z, − 7→ −Z,> 7→ >Z, x 7→ 13Z, y 7→ 42Z, z 7→ 1Z}?
Subramani First Order Logic