The origin of the function $f(x)$ notation

What are the historical origins of the $f(x)$ notation used for functions? That is when did people start to use this notation instead of just thinking in terms of two different variables one being dependent on the other?

Any references would be appreciated.


Solution 1:

The authoritative reference for these matters is the book

Florian Cajori, A History of Mathematical Notations (1929), reprinted by Dover.

On page 268 of volume II, Cajori says that the notation $f(x)$ was first used by Euler in 1734:

enter image description here

Solution 2:

Some remarks:

  1. Euler did not write $f(x)$ in most of his works. Instead he just wrote $f\, x$ or later in his life $f:x$. Of course, when he considered a function of a composite qunatity like $\frac{x}{a}+c$ he had to use parenthesis and write $f(\frac{x}{a}+c)$, since $f\, \frac{x}{a}+c$ could have been misunderstood for $(f \frac{x}{a})+c$. But by Euler's own account, the original notation was intended to be used as $f\, x$ and not as $f(x)$. This was also true in the writings of Lagrange. (So functional programming languages that omit parenthesis are on the right side of history.)

  2. Euler did not invent the notation $f\, x$ for an arbitrary function of $x$, it was his teacher Johann Bernoulli! See the quoted passage of Cajori in the answer of lhf. Bernoulli used the greek $\phi$ instead of the latin $f$, but changing $\phi$ to $f$ can hardly be considered a significant step by Euler.

  3. During Bernoulli's time it was already common practice to write things like $$ l\,x,\quad r\,x \quad \text{and}\quad s\, x \; \text{ (or} \sin x) $$ for the logarithm the root and the sine of $x$ respectively. From this perspective writing $\phi\, x$ for an arbitrary function of $x$ seems quite natural.

  4. Euler and Bernoulli rarely used the $f x$ notation to denote an arbitrary function of $x$, instead they mainly used single letters like $y,u$ etc. (What you call "thinking in terms of two variables depending on each other"). The systematic use of $f(x)$ notation was probably popularized by Lagrange. But, he did not treat $f$ as a mathematical object by itself. That came only with Dedekind, Peano, Cantor and Frege and started to be popular after ~1930. So Lagrange was still thinking in terms of one variable depending on another, just that he would mainly write $f(x)$ for one of these variables.

  5. Finally, and this might be the hardest part to understand for a modern mathematician: according to Bernoulli, Euler and Lagrange (and many others), the $f$ in $f\, x$ was not what was called the function, instead $f$ was called the character of the function $f\,x$, while $f\,x$ was called the function of $x$. But it was common to omit the "of $x$" and simply call $f\,x$ a function.