Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

$f \circ g$ is usually interpreted as $f(g(x))$ although, as Google shows, $g(f(x))$ is used frequently too. My question: Does anybody know who was the first mathematician to use this symbol and what was his interpretation?

share|cite|improve this question
$f\circ g$ is always interpreted as $f(g(x))$; more precisely, the rule for the function $f\circ g$ is $(f\circ g)(x)=f(g(x))$. $g(f(x))$ would correspond to $g\circ f$: $(g\circ f)(x)=g(f(x))$. $f\circ g$ and $g\circ f$ are generally different functions. – David Mitra Apr 17 '12 at 15:12
$f\circ g$ is not interpreted as $f(g(x))$. Rather $(f\circ g)(x)$ is interpreted as $f(g(x))$, and $(f\circ g)(w)$ is interpreted as $f(g(w))$, and $(f\circ g)(5.2)$ is interpreted as $f(g(5.2))$, and so on. – Michael Hardy Apr 17 '12 at 15:30
it depends on whether you write $f$ as $f(x)$ or $(x)f$. although the latter notation is rare, it does occur (often in the context of permutation mappings, or other algebraic contexts in which "we do as we parse"). – David Wheeler Apr 17 '12 at 16:25
If you put the symbol for a function after arguments, then f∘g means (x)(f∘g) or equivalently ((x)f)g which means the same thing as g(f(x)) when you put the symbol for a function before arguments. – Doug Spoonwood Apr 17 '12 at 16:28
Back in graduate school, in our Galois Theory text, the author wrote $x^\sigma$ for the result of applying automorphism $\sigma$ to the element $x$. So naturally composition was $x^{\sigma\circ\tau} = (x^\sigma)^\tau$. That is: $\sigma\circ\tau$ means: first do $\sigma$, then do $\tau$. – GEdgar Apr 17 '12 at 18:17

N. Bourbaki used $f\circ g$ with the interpretation $(f\circ g)(x)=f(g(x))$ in 1949 (Fonctions d'une variable réelle).

Looking at the Bourbaki papers, I found this example from 1944 (middle of page 5), with the same interpretation. I haven't found any older examples, although I haven't tried very hard. (Van der Waerden does not use this notation in his Moderne Algebra from 1930.)

It is certainly conceivable that the notation $f\circ g$ was invented by someone from the Bourbaki group. They were certainly very occupied with good notation, and André Weil introduced the modern symbol for the empty set in 1939 to be able to distinguish between $\emptyset$ and $0$. This notation for composition could have appeared from a similar discussion about $f(g(x))$ and $f(x)g(x)$.

share|cite|improve this answer

I have never seen "$(f\circ g)(x)=g(f(x))$" in a math paper or book. Looking at a few of the results you quote from Google, the only academic papers I find there are either in computer science or engineering.

Maybe the confusion arises from the following fact: in Spanish (and maybe in French?) which is the language I took my undergrad classes in, one reads "$f\circ g$" as "$g$ composed with $f$". I remember this was a source of confusion for many students.

share|cite|improve this answer
I know of a professor in category theory/computer science who uses $(f\circ g)(x)$ to mean $g(f(x))$. He does this because when drawing a commutative diagram, the composition $f\circ g$ would be rendered $X\overset g \to Y\overset f \to Z$ and so he writes the composition as $gf$. – SL2 Apr 17 '12 at 18:03
Doesn't Herstein, in his book Topics in Algebra, use $(f\circ g)(x)=g(f(x))?$ I don't have a copy of his book with me now, but I seem to recall that in his book $fg$ means apply $f$ first, then apply $g$ to the result. (I had a 2-semester undergraduate algebra sequence from Herstein's text, but this was during the 1976-77 academic year.) Perhaps Herstein didn't use the $\circ$ notion, however ... I don't remember. – Dave L. Renfro Apr 17 '12 at 18:30
@AMPerrine: that makes sense, when one writes everything on the other side. – Martin Argerami Apr 17 '12 at 22:46
@ Martin Argerami: AMPerrine's quote can be found on p. 13 of the 2nd edition (1975) of Herstein's text. I recall that we used to say something like you have to drive on the other side of the road when reading Herstein. – Dave L. Renfro Apr 18 '12 at 19:17
FWIW, I don't think it is standard even for Spanish-speaking countries to read "$f\circ g$" as "$g$ composed with $f$"... In Uruguay, at least, we say "$f$ compuesto con $g$". Also, my secondary education was in French, and I remember reading "$f\circ g$" as "$f$ rond $g$" (which in retrospect is quite ugly!) – Bruno Stonek Jun 15 '12 at 1:30

In dealing with categories and groupoids it is natural to write the composition of

$$A \xrightarrow{f} B \xrightarrow{g} C $$ as $$ A \xrightarrow{fg} C.$$ This convention is used in the book

Higgins, P.J., Categories and Groupoids, Van Nostrand Reinhold Mathematical studies 32, Van Nostrand Reinhold, London, (1971); Reprints in Theory and Applications of Categories, No. 7 (2005) pp 1--195. (downloadable)

and might be called the "algebraist's convention". I have found it very useful in dealing with double and higher categories and groupoids. It involves writing functions on the right as $(x)f$ as mentioned in other answers. This goes against the grain of course in dealing with the functions sin and log !

These ideas and notations, for example $x \mapsto x^2 +1$, evolved through trying to clarify the notion of function, and eventually finding both the domain and codomain were important, leading to a function being $f: A \to B$, with domain $A$ and codomain $B$. This arrow notation is one of the impetuses behind the notion of category. A further complication is that ordinary real number analysis and calculus is largely about partial functions $\mathbb R \to \mathbb R$, i.e. functions whose domain of definition is a subset of $\mathbb R$.

share|cite|improve this answer
How does that relate to the question who invented the $\circ$ notation is beyond me... – Asaf Karagila Jun 14 '12 at 21:41

Typing $$\rm history\ mathematical\ notation$$ into Google turned up some sites that might be worth checking out, and it also gave Florian Cajori's book, A History of Mathematical Notations, which ought to be worth a look.

share|cite|improve this answer
Unfortunately Cajori's two volumes do not contain the solution (unless I am too blind). – user29503 Apr 24 '12 at 8:04

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.