In class, a student asked to work through a question:

Let $f(x) = \frac{5(x-1)}{(x+1)(x-4)} - \frac{3}{x-4}$.

(a) Show that $f(x)$ can be written as $\frac{2}{x+1}$.

(b)Hence find $f^{-1}(x)$, stating its domain.

The answer they gave was outrageous ((Am I doing this clickbait thing right?)).

Part (a)

Part (a) was fine: combine it all into a single fraction as $\frac{5(x-1) - 3(x+1)}{(x+1)(x-4)}$, then simplify the top to get $\frac{2(x-4)}{(x+1)(x-4)} = \frac{2}{x+1}$. Not an enormous challenge for someone with algebraic fraction skills.

First part of (b)

… and the inverse function isn’t much more difficult: starting from $x = \frac{2}{F(x) + 1}$ (where $F(x)$ is $f^{-1}(x)$, but less hassle to write), we swiftly rearrange to get $F(x) + 1 = \frac{2}{x}$ and $f^{-1}(x) = \frac{2}{x} - 1$, which can be written in several ways.

Second part of (b)

This is where the mark scheme and I disagree.

According to the mark scheme, the domain of the inverse function is $x \in \RR$, $x \ne 0$, and I have a problem with that.

And my problem goes back to part (a): the function is not properly defined: no domain is given. We can assume, reasonably, that it’s as big as the definition allows: all real numbers are allowed, except for -1 and 4.

Yes, and 4. Even though the ‘equivalent’ form, $\frac{2}{x+1}$ doesn’t have an $x-4$ on the bottom, the function as it’s given to us does. Even though the limit of the function as $x$ approaches 4 is well-defined (it gives $\frac{2}{5}$), we still have to exclude it from the domain - we cannot evaluate $\frac{5(x-1)}{(x+1)(x-4)} - \frac{3}{x-4}$ at $x=4$; neither term is defined.

And that has a knock-on effect for the inverse: because $x=4$ is excluded from the domain of $f(x)$, $f(x) = \frac{2}{5}$ has to be excluded from its range. And if $\frac{2}{5}$ is excluded from the range of $f(x)$, it must also be excluded from the domain of $f^{-1}(x)$.

So, according to me, the correct answer to the second part of (b) is $x \in \RR$, $x\ne 0$, $x \ne \frac{2}{5}$.

Any objections? No. Good.