I have a question for my math study. It seems quite simple, but I just can't find a counterexample for the following:
The composition of two functions is always commutative
Could you help me with that?
$\endgroup$ 32 Answers
$\begingroup$Simple. Take $f(x) = x^3, g(x) = 2x$. Then $f(g(x)) = (2x)^3 = 8x^3$, while $g(f(x)) = 2x^3$.
No thanks
$\endgroup$ $\begingroup$just check out matrix multiplication which is almost never commutative. But of course there are examples where the matrix multiplication is commutative so this a good source for both cases.
bests
$\endgroup$