[Math] Find the domain, co-domain and range of a function

calculusfunctions

The function is

$$g:\Bbb R\setminus\{0\}\to\Bbb R\setminus\{1\}\;,$$

where $$g(x) = x-\frac1x\;.$$

Please pardon my formatting as I am new to this. I know what a function is of course and their domain, codomain and range. What I do not understand is what the Real number part means. Does it mean all real numbers from $0$ to $1$? So it is basically already giving me the domain? Any help would be appreciated.

Best Answer

In principle the domain and codomain are given explicitly in the first displayed line: the domain ought to be $\Bbb R\setminus\{0\}$, i.e., the set of all non-zero real numbers. Similarly, the codomain is given as $\Bbb R\setminus\{1\}$, the set of all real numbers different from $1$. $\Bbb R$ is the set of all real numbers, positive, negative and $0$. The only part that ought to require any actual work on your part is finding the range: which real numbers different from $1$ are possible values of $g(x)$?

However, on further examination I see that the problem is a bit nasty: there are non-zero real numbers $x$ such that $g(x)=1$, which means that the actual domain of $g$ cannot be all of $\Bbb R\setminus\{0\}$ if $\Bbb R\setminus\{1\}$ is to be the codomain. You can find those numbers by setting $g(x)=1$ and solving for $x$.

Added: This is really a rather bad exercise: properly speaking, the lines

$$g:\Bbb R\setminus\{0\}\to\Bbb R\setminus\{1\}$$

and $$g(x)=x-\frac1x\tag{1}$$

are mutually contradictory, because $\Bbb R\setminus\{1\}$ is not a possible codomain for the function defined by $(1)$ whose domain is $\Bbb R\setminus\{0\}$.