Is there a definition for free and bound variables in logic?

That makes me crazy to think about it because my book and other pages on the web talks about free and bound variables without any definition. I think everything in mathematics has a definition so there must be a definition for it.

Also, I am taking a course called abstract mathematics talks about how to proof and logic. I am curious about if logic and these proof study have another name in mathematics.


Solution 1:

Free and bound variables are defined in the context of the syntax of first-order logic, considering terms (i.e. "names" for objects) and formuals (i.e. statements).

The formal definition of the set $\text {FV}(φ)$ of free variables of a formula $φ$ is defined by :

all the variables occurring in a term or atomic formula are free.

$\text {FV}(¬φ) = \text {FV}(φ)$;

$\text {FV}(φ ∨ ψ) = \text {FV}(φ) \cup \text {FV}(ψ)$, (and the same for the other binary connectives);

$\text {FV}(∀xφ) = \text {FV}(∃xφ) = \text {FV}(φ) \setminus \{ x \}$.

A variable that is not free is bound.

A formula $φ$ is called closed if $\text {FV}(φ)=\emptyset$.

In formula $\forall x P(x)$, the variable $x$ is bound.

In formula $\forall x R(x,y)$ the variable $x$ is bound while the variable $y$ is free.


A closed formula, when interpreted, expresses a sentence, i.e. has a definite tuth value.

$\forall n (n \ge 0)$ is true in $\mathbb N$, while $\exists n (n < 0)$ is false in it.

What is the truth value of a formula with a free variable, like e.g. $(x > 0)$ ?

It depends... It depends on the value we assign to the variable $x$.

A free variable acts as a pronoun of natural language : its reference must be identified according to the context : if I say "it is red", the truth vale of the statement depends on the object I'm pointing at with my finger : the red book or the blue pen on my table.

In the same way, there are ways (defined by the formal semantical specifications of the first-order language : see variable assignment function) to give "temporary" reference to free variables of a formula.

Consider the formula :

$x+2=5$;

if we substitute to $x$ the (name for the) number $3$, we obtain a true sentence (i.e. $3+2=5$).

If instead we substitute to $x$ the (name for the) number $4$, we obtain a false sentence (i.e. $4+2=5$).

A formula with free var is called "open" because it has no (fixed) meaning : it is "open to" different interpretations; in order to give it meaning, we have to transform it into a sentence (i.e. a closed formula).