If $f(x) = x-5$ and $g(x) = x^2 -5$, what is $u(x)$ if $(u \circ f)(x) = g(x)$? 
Let $f(x) = x-5$, $g(x) = x^2 -5$. Find $u(x)$ if $(u \circ f)(x) = g(x)$.

I know how to do it we have $(f \circ u) (x)$, but only because $f(x)$ was defined.  But here $u(x)$ is not defined.  Is there any way I can reverse it to get $u(x)$ alone?

I think I figured out what my professor did now . . .

$(u \circ f)(x) = g(x)$
$(u \circ f)(f^{-1} (x)) = g( f^{-1}(x)) $
$\big((u \circ f) \circ f^{-1}\big)(x) = (g \circ f^{-1})(x) $
$\big(u \circ (f \circ f^{-1})\big)(x) = (g \circ f^{-1})(x) $
$u(x) = g(f^{-1}(x))$
$u(x) = g(x+5)$

I think this is right.  Please correct me if I'm wrong.
