Can the idea of a ‘function of a variable’ be made rigorous

functionsnotationreal-analysis

Suppose that $y=x^2$. Very often people describe this relationship by saying that '$y$ is a function of $x$'. It seems that there are several logical problems with this statement:

  • A function is simply a set of ordered pairs of numbers. It does not matter how you denote the input of a function, and there is no doubt that $x \mapsto x^2$ and $y \mapsto y^2$ are the same function. Indeed, in both cases $y$ and $x$ are simply dummy variables used to illustrate what happens when you plug in an arbitrary number into the function.
  • $x$ and $y$ are often described as variables that are related in some way; in this case, with $y$ being the square of $x$. However, in this Math Overflow post Mike Shulman states that the idea of a variable is 'not a standard part of modern formalizations of mathematics'. Strangely, the idea of a dummy variable makes much more sense to me. For instance, when we say 'consider the function $f$ defined by $f(x)=x^2$ for all $x$', it is clear that the only purpose of the letter $x$ is to declare that the second entry of the ordered pair is the square of the first.
  • If $y=x^2$ and $x \geq 0$, then we just as well might write $x=\sqrt{y}$. This flexibility is not really allowed when speaking of functions: $x \mapsto x^2$ and $x \mapsto \sqrt{x}$ are certainly not the same function. Perhaps it is possible evade this by treating $x$ as the independent variable and $y$ as the dependent variable.

Some authors get around this ambiguity by saying that 'the function $y=x^2$' is just a shorthand for 'the function $y(x)=x^2$', which in turn is just a shorthand for 'the function $y$ defined by $y(x)=x^2$ for all x'. However, this doesn't seem to align with how people treat the relationship between $y$ and $x$ in practice. Even if we accept that $y=x^2$ is simply a shorthand for $y(x)=x^2$, it still seems that there is a tendency towards treating $x$ as an independent variable representing the input of $y$, as opposed to simply a dummy variable that can be replaced by any other letter.

So I ask, in formal mathematics, is it possible to interpret $y=f(x)$ in such a way that $x$ and $y$ are variables representing the inputs and outputs of a function? And if so, how should the statement '$y$ is a function of $x$' be understood?

Best Answer

When we say “$y=f(x)$”, we are stating a typographical convention that we are going to adopt in the present context: Namely, whenever the letters $x$ and $y$ appear, the values to which they refer are connected by the functional relationship $f$. The terminology “$y$ is a function of $x$” is confusing. While it is still employed by many people who use mathematics, it is often avoided by present-day mathematicians, who are aware that $y$ and $f$ refer to quite different types of mathematical object.

For example, consider the function $$f:\Bbb R\to\Bbb R_{\geqslant0}:x\mapsto f(x):= x^2.$$ In this case, $f$ may be identified with a certain subset of $\Bbb R\times\Bbb R_{\geqslant0}$. Quite separately, and in addition, we may adopt the naming convention of using $y$ instead of $f(x)$. But $y$ is just some element of $\Bbb R_{\geqslant0}$, albeit dependent on $x$, while $f$ is a quite particular subset of $\Bbb R\times\Bbb R_{\geqslant0}$ (which determines the relationship between $x$ and $y$).

In this context, the notation “$y=y(x)$” is often used, which further reinforces the confusion between $y$ and $f$. This sort of notation may be convenient for (say) practical engineering calculations, but it's not a good place to start when you want to maintain a clear mathematical concept of function.

In the above, for simplicity, I have adopted the convention of identifying a function with its graph. In some branches of mathematics this is inconvenient, and to specify a function it is necessary to specify a codomain for it (of which the range of the function is a subset).

Related Question