Consider this definition of first-order (or Herbrand) logic syntax. Here is the vocabulary:
Definition (Vocabulary): A vocabulary V consists of:
- A set of relation constants {r1, ..., rn}, each with an associated arity.
- A set of function constants {f1, ..., fm}, each with an associated arity.
- A non-empty set of object constants {c1, ..., ck}.
- A set of variables {x1,x2,...}.
Here is the definition for 'term':
Definition (Term): A term in V:
- A variable.
- An object constant.
- A function constant with arity n applied to n terms.
- Only expressions produced by the above rules are terms.
Here is the definition for 'sentence':
Definition (Sentence): A sentence in V:
- A relation constant with arity n applied to n terms.
- (¬ φ) where φ is a sentence.
- (φ ∨ ψ), where φ and ψ are sentences.
- (φ ∧ ψ), where φ and ψ are sentences.
- (φ ⇐ ψ), where φ and ψ are sentences.
- (φ ⇒ ψ), where φ and ψ are sentences.
- (φ ⇔ ψ), where φ and ψ are sentences.
- (∀x.φ), where φ is a sentence.
- (∃x.φ), where φ is a sentence.
- Only expressions produced by the above rules are sentences.
I noticed that a function is a term, but a relation is a sentence. At first I thought that was because of the quantifiers associated with a relation, but sentences using quantifiers are also defined. Also the definition of relation does not involve quantifiers.
This makes me wonder what is the difference between functions and relations in first-order logic that one would be considered a term and the other a sentence.
Francois Bry, Mike Genesereth, Tim Hinrichs, Nat Love. Herbrand Logic. Retrieved on September 28, 2019 at https://www.cs.uic.edu/~hinrichs/herbrand/html/herbrandlogic.html