Safekipedia

Quantifier (logic)

Adventurer · ages 7–10Adapted from Wikipedia
Portrait of Augustus De Morgan, a famous mathematician from the 19th century.

A quantifier in logic is a symbol that shows how many things in a group meet a certain condition. There are two main types of quantifiers.

The universal quantifier, written as ∀, means "for all" or "everything." For example, if we say ∀ x P(x), it means that every single thing in our group has the property P.

The other main type is the existential quantifier, written as ∃, which means "there exists" or "at least one." If we write ∃ x P(x), it means that there is at least one thing in our group that has the property P.

Quantifiers help us make clear and exact statements in logic. They are used in mathematics, computer science, and many other fields to build careful and accurate arguments.

Relations to logical conjunction and disjunction

When we have a small group of things, saying "everything has a property" is the same as joining many "and" statements together. For example, if we have the numbers 0 and 1, saying "every number equals its square" means "0 equals 0 squared, and 1 equals 1 squared." This is true because both parts are true.

Sometimes we want to say "at least one thing has a property," which is like joining many "or" statements together. For example, saying "some number equals 5 plus 5" means "either 1 equals 5 plus 5, or 2 equals 5 plus 5, or 3 equals 5 plus 5," and so on.

Main article: logical conjunction
Main article: logical disjunction

Algebraic approaches to quantification

Some mathematicians have made special ways to study logic using algebra. These include relation algebra, which was invented by Augustus De Morgan and worked on by many others. Relation algebra can help us understand some logic rules but has limits.

Other algebra methods include cylindric algebra and polyadic algebra. These were made by different mathematicians to explore logic in new ways. These tools help us understand how logic works in a different style.

Notation

The two most common ways to show quantities in logic are the universal quantifier and the existential quantifier. The symbol "∀", a rotated letter "A", means "for all" or "all". The symbol "∃", a rotated letter "E", means "there exists" or "exists".

For example, if we have a statement like "Each of Peter's friends either likes to dance or likes to go to the beach (or both)", we can rewrite it using these symbols. Let X be all of Peter's friends, P(x) mean "x likes to dance", and Q(x) mean "x likes to go to the beach". The statement can then be written as ∀ x ∈ X, (P(x) ∨ Q(x)). This reads, "for every x that is a member of X, P applies to x or Q applies to x".

Other ways to write these ideas include:

  • ∃ x P
  • ∀ x P

These can be read as "there exists a friend of Peter who likes to dance" and "all friends of Peter like to dance", respectively. There are many different symbols and ways to write these ideas, and they all work in similar ways.

Order of quantifiers (nesting)

See also: Quantifier shift

The order of words like "every" and "some" can change the meaning of a sentence. For example:

  • For every whole number n, there is a whole number s such that s equals n squared. This is true because every number has a square.
  • There is a whole number s such that for every whole number n, s equals n squared. This is false because one number cannot be the square of all whole numbers.

In math, the order of these words is important. For example, when we study how lines or curves change, the order of "for every" and "there exists" can change the meaning.

Swapping two "for every" words or two "there exists" words usually doesn’t change the meaning. But swapping a "there exists" with a nearby "for every" can change the meaning.

The deepest the words like "for every" and "there exists" are nested inside each other is called the "quantifier rank".

Equivalent expressions

In logic, we use special symbols to talk about groups of things. The symbol ∀ means "for all." For example, ∀ x P(x) tells us that everything in a certain group has a certain property.

Another symbol, ∃, means "there exists." For example, ∃ x P(x) means that at least one thing in the group has that property.

These symbols help us make clear and exact statements about groups and what is true for the things in them.

Range of quantification

Every quantification uses a variable and a domain of discourse or range of quantification. This range tells us the values the variable can have. For example, it shows the difference between natural numbers and real numbers.

Sometimes, we use something called guarded quantification to limit what we discuss. For example, saying "For some natural number n, n is even and n is prime" means the same as "For some even number n, n is prime." In some mathematical theories, we start with one big domain of discourse. For example, in Zermelo–Fraenkel set theory, variables can refer to any set. Guarded quantifiers help us look at smaller groups within this big domain.

Formal semantics

Mathematical semantics uses math to study the meaning of expressions in a formal language. It looks at how we build expressions, where meanings can exist, and how these connect.

This article talks about how we understand quantities in logic. We can think of expressions as having a structure, like a tree. A quantifier has a "scope," and a variable like x is "free" if it isn’t inside a part of the expression that locks it down with a quantifier. For example, in the expression

∀ x (∃ y B(x, y)) ∨ C(y, x)

both x and y in C(y, x) are free, while x and y in B(x, y) are bound, meaning they are not free.

When we use formulas in logic, we start with a group of individuals, called a domain. A formula with free variables becomes a special kind of function that tells us if something is true or false, depending on the values we choose for those variables.

The universal quantifier, written as ∀, means “for all.” For example, ∀ x P(x) says that the property P is true for every single thing in our domain. The existential quantifier, written as ∃, means “there exists.” So ∃ x P(x) says that there is at least one thing in our domain where the property P is true.

Paucal, multal and other degree quantifiers

Some quantifiers describe special groups of numbers or items. For example, we might want to say "there are many numbers..." or "there are only a few numbers..." These ideas help us talk about groups in a more detailed way.

Mathematicians also use other ways to describe groups, like:

  • There are infinitely many elements such that...
  • For all but finitely many elements... (sometimes called "for almost all elements...").
  • There are uncountably many elements such that...
  • For all but countably many elements...
  • For all elements in a set of positive size...
  • For all elements except those in a very small set...

History

Term logic, also called Aristotelian logic, talked about "All," "Some," and "None" a long time ago in the 4th century BC. It was closer to everyday speech but hard to study.

Later, in 1827, George Bentham wrote about the idea of quantifiers, but his book didn’t get much attention. William Hamilton is said to have created the words "quantify" and "quantification" around 1840. Augustus De Morgan helped make these ideas more popular in the mid-1800s.

Augustus De Morgan (1806–1871) was the first to use "quantifier" in the modern sense.

Gottlob Frege was the first to use quantifiers in a formal way in 1879. He showed how to say that everything or something in a group has a certain property. His work wasn’t well known until later.

Charles Sanders Peirce and his student Oscar Howard Mitchell also created symbols for these ideas in the late 1800s. Their symbols were used by many famous mathematicians and logicians. Over time, new symbols like ∀ were introduced and became common in the 1900s.

Pictures

A classical bust of the ancient Greek philosopher Socrates.

Keep exploring

This article is a child-friendly adaptation of the Wikipedia article on Quantifier (logic), available under CC BY-SA 4.0.

Images from Wikimedia Commons. Tap any image to view credits and license.