# Find the range of function $f(x) = \frac{4-x}{x-4}$

We have to find the range of the function,

$$y = \dfrac{4-x}{x-4}$$

My approach:-

I know the first method to find the range of a function by finding the domain of inverse function.

$$y = \dfrac{4-x}{x-4}$$

$$\implies y(x-4) = 4-x$$

$$\implies xy - 4y = 4-x$$

$$\implies xy +x = 4+4y$$

$$\implies x(y+1) = 4(y+1)$$

$$\implies x = \dfrac{4(y+1)}{(y+1)}$$

Now, here $$y$$ cannot be equal to $$-1$$.

Therefore the range of the function is $$\mathbb{R} - \{-1\}$$

The second method is :-

$$y= \dfrac{4-x}{x-4}$$

$$y = \dfrac{-(x-4)}{(x-4)}$$

$$y = -1$$

Therefore the range of the function is $$\{-1\}$$

I checked my answer on wolfram alpha, $$\{-1\}$$ is the correct answer. But what's the mistake in the first method? Which step is incorrect?

Further more, I tried to check my solution step by step on desmos by plotting the graph. What I found is that the graphs from 1st to 6th step are same but the graph changed at the step when I got $$x = \dfrac{4(1+y)}{(1+y)}$$.

I need help here. Thanks in advance!

• $y\neq -1?$ what is $y$ when $x=0?$ Hint: you can’t divide by $y+1$ if $y=-1,$ but that doesn’t mean that $y\neq -1.$ Sep 30, 2021 at 12:34
• You can multiply by $(x - 4)$ exactly when $x \neq 4$. Otherwise, the function is not defined. So, you can simply cancel off the terms as in method 2 to always get $-1$. As for the first method, if you insist on multiplying $(x - 4)$, then you can divide by $(y + 1)$ exactly when $y \neq -1$. But in that case $x$ has to be $4$, which is a contradiction. Hence, $y$ must always be $-1$. Sep 30, 2021 at 12:34

The method of finding the domain of the inverse cannot work when the function has no inverse, which is the case here. Actually, your function is constant (and, in particular, not injective) and only takes the value $$-1$$. Therefore, the range is $$\{-1\}$$.