Domain of the composition of functions

functionsradicals

If $f(x) = x^2$ and $g(x) = \sqrt{x-1}$, find $f(g(x))$ and specify the domain.

My solution

$$
f(g(x)) = \left(\sqrt{x-1}\right)^2 = x-1,
$$

Domain: $x$ such that $x$ is any real number.

Solution at the back of the book states that the domain is, $x$ such that $x \ge 1$.

Now I understand why that is the domain for $g(x)$, for any number less than 1 would make $g(x)$ negative and the square root of a negative number is an imaginary number.

But, that is not the cases with $f(g(x))$. When is $(\sqrt{x-1})^2$ not a real number? isn't any input valid?

Best Answer

I think you have to differentiate between $$ f(g(x)) = \left(\sqrt{x-1}\right)^2 $$ and $h(x) = x-1$. For $h(x)$, indeed the domain are all reals, but $f(g(x))$ is defined to only take the output of $g(x)$, so you have to go through $g(x)$ first, resulting in the domain being $x \ge 1$.

Related Question