No history yet

Introduction to Predicate Logic

Beyond True or False

In propositional logic, we work with simple, declarative statements that are either true or false. "It is raining" is a proposition. "The sky is blue" is another. While useful, this has limits. How would we express a statement like "All dogs are mammals"? We can't assign a single true or false value to this without being able to talk about the properties of things.

This is where predicate logic comes in. It gives us a richer way to talk about the world. Instead of just dealing with whole statements, we can break them down to talk about objects and their properties or relationships. Predicate logic is the language we use to make general claims and reason about groups of things.

Predicate logic lets us move from talking about specific facts to describing general rules and properties.

Think of a predicate as a sentence with a blank in it. For example, "___ is a planet." This isn't true or false on its own. It's a property waiting for an object. If we fill the blank with "Mars," we get "Mars is a planet," which is a true proposition. If we fill it with "Pluto," the truth of the statement is a bit more complicated, but it becomes a proposition we can evaluate.

The blank-filler is called a term, which is usually a variable (like xx) or a constant (like Mars). The predicate itself is the property, which we can write in a more formal way, like P(x)P(x), where PP stands for "is a planet" and xx is our variable term.

Lesson image

Quantifiers: All and Some

The real power of predicate logic comes from two special symbols called quantifiers. They let us talk about the quantity of objects that have a certain property.

quantifier

noun

A symbol that specifies the quantity of elements in a domain that have a certain property.

The first is the universal quantifier, written as \forall. It means "for all" or "for every." If we want to say "All dogs are mammals," we could write it like this:

x(Dog(x)Mammal(x))\forall x (Dog(x) \rightarrow Mammal(x))

This reads: "For every thing xx, if xx is a dog, then xx is a mammal." This single statement covers every dog that has ever existed or will ever exist.

The second is the existential quantifier, written as \exists. It means "there exists" or "for some." It makes a claim about at least one thing. To say "Some cats have stripes," we could write:

x(Cat(x)Striped(x))\exists x (Cat(x) \land Striped(x))

This reads: "There exists some thing xx such that xx is a cat and xx is striped." It doesn't say all cats have stripes, just that we can find at least one that does.

Universal quantifier (\forall): All things have the property. Existential quantifier (\exists): At least one thing has the property.

How It Differs from Propositional Logic

The key difference is expressiveness. Propositional logic treats sentences as indivisible blocks of truth. Predicate logic looks inside those sentences to see how objects and their properties are related. It gives us the tools to handle variables and make general statements about populations of objects.

FeaturePropositional LogicPredicate Logic
Basic UnitPropositions (e.g., PP, QQ)Predicates (e.g., P(x)P(x), Q(x,y)Q(x,y))
FocusRelationships between propositionsProperties of objects & relationships
GeneralizationCannot express "all" or "some"Uses quantifiers (,\,\forall, \exists\,)
Example"If it is raining, then the ground is wet." (PQP \rightarrow Q)"All birds can fly." (x(Bird(x)CanFly(x))\forall x (Bird(x) \rightarrow CanFly(x)))

In essence, propositional logic is the logic of sentences, while predicate logic is the logic of objects, properties, and relations. This makes it a foundational tool for fields like mathematics, philosophy, and computer science, especially in artificial intelligence, where we need to represent complex knowledge about the world.

Ready to test your understanding?

Quiz Questions 1/5

What is the primary advantage of predicate logic over propositional logic?

Quiz Questions 2/5

Which of the following expressions in predicate logic best represents the statement "Some cats are black"?

By adding predicates and quantifiers, we gain a much more powerful and flexible way to represent logical statements.