(0) Obligation:

Q restricted rewrite system:
The TRS R consists of the following rules:

f(g(x), x, y) → f(y, y, g(y))
g(g(x)) → g(x)

Q is empty.