# If $f(x)g(x) = 1$, then prove that $g(g(f(f(g(f(x))))) = f(f(g(g(f(g(x)))))$

I have looked at the solution and it simply says that if the number of 'g's and 'f's on both sides of the equation are equal, then the two expressions will be the same given the condition f(x).g(x) = 1.

However I am unable to see how that happens and have been trying to prove this. This is as far as I have come.

My attempt:

Let $f(x) = x$, then $g(x) = 1/x$

$f(f(x)) = x$

$g(g(x)) = x$

$f(g(x)) = \dfrac 1x$

$g(f(x)) = \dfrac 1x$

Then the given expressions become

$g(g(f(f(g(f(x))))) = \dfrac 1x$

$f(f(g(g(f(g(x))))) = \dfrac 1x$

This shows the expressions are equal. But I am stuck now and do not understand how to proceed from here. Trying quadratic expressions do not seem like an option as the expressions get very complex.

Any help regarding how to proceed from here would be greatly appreciated.

• Does the problem statement mean f(g(x))=1 when it says f.g(x)=1? Aug 2 '16 at 3:09
• most likely, unless they mean it to be false. Aug 2 '16 at 3:10
• Is there any further restrictions? Because all that $f(x)g(x) = 1$ tells you is that $g(x) = 1/f(x)$ f can send 'x' to any value. Aug 2 '16 at 3:18
• @Brian No it only says f(x)*g(x) = 1, not f(g(x)) = 1 Aug 2 '16 at 3:19
• @QthePlatypus No further restrictions are mentioned Aug 2 '16 at 3:20

This is false if you consider the dot to be a product. You can take $f(x)=x+1$, and $g(x)=\frac{1}{x+1}$. Then, $g(f(x))=g(x+1) = \frac{1}{f(x+1)} = \frac{1}{x+2}$ and $f(g(x))=f(\frac{1}{x+1}) = \frac{1}{x+1} + 1$, which are not the same, so $f(g(x)) \neq g(f(x))$, and similarly you will get far more unequal expressions for $g(g(f(f(g(f(x))))))$ and the other one (I don't want to expand, I hope you understand).
This is false even if the dot is a composition. For example, consider $f(x)=x-1$ and $g(x) \equiv 2$, then $f(g(x)) \equiv 1$, but $g(g(f(f(g(f(x)))))) = 2$, while $f(f(g(g(f(g(x)))))) = 0$, so again they are not equal.
So I do not know the criteria behind establishing this, but my feeling is there have to be restrictions on the way $f$ and $g$ are operating, or maybe the condition that $g(f(x)) \equiv 1$ should also be applied (then the answer is obvious).
(As a note, $\equiv$ means equivalence of functions)