What is a rigorous method/mechanism to find the range of a function $f(x)$? Is it acceptable to find $f^{-1}(x)$ and then its domain? I understand that $f^{-1}(x)$ does not always exist (at least not without limiting the domain of $f(x)$, as is the case of the trigonometric functions) which I imagine can potentially lead to problems when trying to find the range of $f(x)$ in this way.
The other approach I see would be checking the end behaviour of $f(x)$ and potentially considering its local minima and maxima, but I am not convinced that this will aptly handle discontinuities, etc.
Thanks in advance for your help.
$\endgroup$ 12 Answers
$\begingroup$If you are talking about the real case, then finding the domain of a function is relatively easy. Find the values of $x$ where piece-wise continuous $f(x)$ is nonexistent. Exclude these intervals from $(-\infty,\infty)$ to get the domain. If the domaine is the interval $[a,b]$, then the domain is $[\min f(a),\max f(b)]$.
As an example, consider $f(x)=\sqrt{x}$. This is nonexistent, in the real case, for $x<0$. Thus, the range is simply $[0,\infty)$. The domain, however, is $(-\infty,\infty)$
For complex functions, see this M.SE question.
$\endgroup$ 7 $\begingroup$After talking to a friend, I was able to work out an answer to my question.
In general, given a function $f$ whose domain is $D\left(f\right)$, its range is $R\left(f\right) = \left\{f\left(x\right) : x \in D\left(f\right) \right\}$.
Suppose that $f$ is a composition of some two functions $g$ and $h$, such that $f\left(x\right) = g\left(h\left(x\right)\right)$. Then we can consider the range of $f$ to be
$R\left(f\right) = \left\{g\left(y\right) : y \in R\left(h\right) \cap D\left(g\right)\right\}$.
Here, we use $g$ to map $R\left(h\right) \stackrel g\to R\left(f\right)$. Thus, so long as we know $R\left(h\right)$ (either a priori or by finding it via this method) and $D\left(g\right)$, we can find $R\left(f\right)$.
To give an example:
Suppose that $f\left(x\right) = \frac{1}{x^2 + 1} - 1$. Then
$R\left(f\right) = \left\{f\left(x\right) : x \in D\left(f\right)\right\} = \left\{y-1 : y \in R\left(\frac{1}{x^2 + 1}\right)\right\}$.
Next,
$R\left(\frac{1}{x^2 + 1}\right) = \left\{\frac{1}{y} : y \in R\left(x^2+1\right)\setminus \left\{0\right\}\right\}$
because $D\left(\frac{1}{x}\right) = \mathbb R \setminus \left\{0\right\}$. Again,
$R\left(x^2+1\right) = \left\{y + 1 : y \in R\left(x^2\right)\right\}$
and finally I assume that we trivially recognise that $R\left(x^2\right) = \left[0, \infty\right)$.
It follows that $R\left(x^2+1\right) = \left[1, \infty\right)$ by "adding" $1$ to both endpoints of the interval representing $R\left(x^2\right)$.*
Next, $R\left(\frac{1}{x^2 + 1}\right) = \left(0, 1\right]$ after "taking the reciprocal" of the endpoints. In this case, it turns out that our concern about the domain $D\left(\frac{1}{x}\right)$ was unnecessary because $0 \notin R\left(x^2+1\right)$.
Finally, our original problem $R\left(f\right) = R\left(\frac{1}{x^2 + 1} - 1\right) = \left(-1, 0\right]$ by "subtracting" $1$ from both endpoints.
Sure enough, see its graph below (also see WolframAlpha's analysis of this function).
*More formally, when you apply a function $f$ to a noninclusive interval, e.g. $\left[a,b\right)$, you are in fact taking the limit $\lim_{x\to b} f\left(x\right)$. That is, $\left\{f\left(x\right) : x \in \left[a,b\right)\right\} = \left[f\left(a\right), \lim_{x\to b^-} f\left(x\right)\right)$. In the cases above, $\lim_{x\to \infty} \left(x+1\right) = \infty$, $\lim_{x\to \infty} \frac{1}{x} = 0$, and $\lim_{x\to 0^+} \left(x-1\right) = -1$.
$\endgroup$