Variables as place-holders and the set builder notation

590 Views Asked by At

In logic, variables don't have a meaning by themselves. They simply hold the place in an expression where the names of objects could be present. Adopting this placeholder viewpoint, I'm having trouble interpreting the set builder notation.

Consider, for instance, the set of all natural numbers less than 10, denoted in the set builder notation as

$$\{x:x<10\}$$

A common interpretation of this notation is

The set of all x such that x is less than 10

This interpretation IMO doesn't go well with the placeholder viewpoint of variables, as when we replace 'x' by say '2', we get the expression

The set of all 2 such that 2 is less than 10

which doesn't make sense.

So my question is how should I interpret $\{x:x<10\}$ from a placeholder viewpoint of variables? I can understand only the $x<10$ part from the placeholder viewpoint of variables as it is clearly an open sentence that gives a statement upon replacement of 'x' by appropriate constants.


As an extension of this question, a similar issue arises when the domain of 'x' is specified in the set builder notation as:

$$\{x \in N :x<10\}$$

This is often interpreted as

The set of all x in N such that x is less than 10

Adopting the placeholder viewpoint, replacing 'x' by say '3' yields,

The set of all 3 in N such that 3 is less than 10

Again only the '3 is less than 10' part of the expression makes sense.

4

There are 4 best solutions below

0
On BEST ANSWER

$\{x \mid \phi(x)\}$ is usually introduced as an abbreviation for something like "the set of all objects $x$ such that the condition $\phi(x)$ holds" (Enderton) or unpacked further ”the unique $y$ such that $\forall x (x \in y \leftrightarrow \phi(x))$" (Potter)

So, once fully unpacked, the only variables we have are bound variables, the $y$ bound by the description operator, the $x$ bound by the universal quantifier. No place-holder in sight. (Bound variables are not mere place-holders.)

0
On

The set builder notation is a bit different from the "placeholder" usage you describe in that it gives a meaning to one variable, and that variable's meaning is used in a formula it quantifies. There are other mathematical notations which use variables this way, such as

  • $\forall x \in \mathbb{R}: x^2 \geq 0$: "If $x$ is any real number, then $x^2$ is greater than or equal to zero."
  • $\exists x \in \mathbb{R}: x^3 = 2$: "There exists a real number $x$ such that $x^3$ is $2$."
  • $\lim_{x \to 0} \frac{\sin x}{x} = 1$: "As $x$ approaches $0$, $\frac{\sin x}{x}$ approaches $1$."
  • $\sum_{k=0}^n x^k = \frac{x^{k+1}-1}{x-1}$: "The sum of the terms $x^k$ over the integers $k$ with $0 \leq k \leq n$ equals $\frac{x^{k+1}-1}{x-1}$."

For none of these would it make sense to substitute a value for the quantifier variable ($x$ in the first three, $k$ in the last). The syntax is "in charge" of its "bound variable", and we don't get to substitute any number we want, like is often valid for a "free variable". The quantifier part says how we choose the values to substitute in the formula, and what we do with the results of those substitutions.

Although there actually is an interpretation of set-builder notation which is closer to the simple substitution idea: Read $\{x: x<10\}$ as "$x$ is in this set if and only if $x<10$". Now it does make more sense to say "$2$ is in the set if and only if $2<10$, so $2$ is in the set." Even using that as a handy mnemonic, I'd still recommend you be aware that the variable the notation is using special to that notation.

Note we also sometimes say things like $\{x^2 : 0 \leq x \leq 5\}$. If it's not just a variable left of the colon, that part gives another formula describing the set's members in terms of the variable values. So we can read it as "$x^2$ is in this set if and only if $0 \leq x \leq 5$". If the implicit domain is the integers, then the notation means

$$ \{x^2 : 0 \leq x \leq 5\} = \{0,1,4,9,16,25\} $$

When there's an explicit domain such as $\{x \in \mathbb{N}: x < 10\}$, this is mostly the same as $\{x : x \in\mathbb{N} \mathrm{\ and\ } x<10 \}$. One reason we often see the domain out front is that in formal set theory, we're only allowed to define sets out of elements from some other set we know exists, not from any imaginable values at all. Even when we're not that worried about that technical rigor, it's often helpful to see right away what the general context of the set is.

5
On

$$A=\{x:x<10\}$$

This is just the set of elements (of the universe of discourse) that are smaller than $\boldsymbol{10}.$

Observe that $$A=\{t:t<10\}=\{y:y<10\}.$$

A common interpretation of this notation is

“The set of all $x$ such that $x$ is less than $10$

No: your description suggests that the dummy variable $x$ (which, as I pointed out, could well have been $t$ or $y$) is a free variable. Don't feature $x$ in your verbal description of the set: instead of saying “all $x$”, say “all rational numbers” or “all values” or “all objects” or “all elements of the universe”, or whichever apt.

$x$ should be a placeholder for the name of elements of the set from which we are picking elements to be checked.

Not at all: $x$ is a placeholder not for the members of the universal set—just for the members of the set of interest $A.$ We are not taking a collection whose members are called $x$ then stipulating a subset of it.

$$\{x \in \mathbb N :x<10\}$$

This is often interpreted as

“The set of all $x$ in $\mathbb N$ such that $x$ is less than $10$

Again, no. Here, we are picking, from the discourse universe, elements that are natural numbers and smaller than $10$ (you can think of this as taking a specific subset of $\mathbb N$), then within the scope of this process again labelling a representative such element $\text‘x\text’.$ So, the correct reading of the given specification is simply “the set of natural numbers that are smaller than $\boldsymbol{10}$” (no mention of $x$).

0
On

I suspect there is some confusion here between free variables and bound variables:

  1. In the expression x < 10, x is a free variable. Free variables reference something in the surrounding context. You can substitute x with potential values and evaluate the result: 2 < 10 is true, whereas 20 < 10 is false.

    In English, this would be like "John is less than 10 feet tall." This sentence might refer to John Smith from high school, or John Stewart from the comics.

  2. In the expression {x : x < 10}, x is a bound variable. It is bound to the scope of the {x : …} notation. You are not permitted to plug in concrete values, but you can swap the variable to a different letter: {y : y < 10} means the same thing as {x : x < 10}.

    Some people call them dummy variables because what letter you use doesn't actually matter. The bound variables exist solely to establish a connection between different parts of the expression.

    In English, this is more like "Tell me every person who is less than 10 feet tall." Here, the relative pronoun who takes on a role similar to x. You can't really replace who with a specific name like "John Smith".

    (A longer English translation that uses a temporary bound name would be: "For every person, call them X (for now); if X is less than 10 feet tall, tell me who they are." People don't usually speak like this, but it might appear in technical descriptions of algorithms.)

Bound variables show up a lot in mathematical notation but they are not often explained explicitly. The prototypical example is in the definition of a function:

f(x) = x + 1
  ^    ^-- here x is bound to the current scope
  |
  +--- introduces a variable x and along with it a new scope

It shows up in other places too, like:

$$\sum_{n = 1}^\infty x^n$$

Here n is bound to the scope of the summation, whereas x remains free.

If you really want to train yourself on these concepts, consider learning lambda calculus.