Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

So if we have


$y=x$ when $x \ne 1$ and

$y = 0$ when $x = 1$.

The inverse would be:

$y=x$ when $x \ne 0$ and

$y=1$ when $x = 0$


share|improve this question
The easiest way to check is to see if $f^{-1}(f(x)) = x$. Does it? –  Arkamis Oct 25 '12 at 21:19
it gives me 1 when y = 0 –  Gladstone Asder Oct 25 '12 at 21:32
Answer to the question in the title is yes. –  wnvl Oct 25 '12 at 21:35
The answer to the question in the title is that the question reflects a great confusion about functions and graphs. You can't reflect a function. What you mean to ask is, "Is the graph of the inverse of a function the reflection of the graph of the function about the line $y=x$?" And please do something about that zero percent accept rate! –  Gerry Myerson Oct 25 '12 at 22:14

3 Answers 3

up vote 0 down vote accepted

Yep. You correctly switched $x$ and $y$ and solved for $y$, and then switched the domain and range.

share|improve this answer

It’s just a bit more complicated than reflecting the graph about the line $y=x$, because the result may not be the graph of a function any more. Note that if you take your original picture and perform the reflection, there are two points in the new picture with $x$-coordinate $0$, and none with $x$-coordinate $1$.

The elaborate way of describing the situation is: consider a function $f\colon X\to Y$, $X$ being the domain of the function, and $Y$ being the target space. There is a left inverse $g\colon Y\to X$ satisfying $g(f(x))=x$ for all $x\in X$, if and only if the original $f$ was one-to-one. And there is a right inverse $h\colon Y\to X$ satisfying $f(h(y))=y$ for all $y\in Y$ if and only if $f$ was onto $Y$.

Examples with $X=Y=\mathbb R$: the exponential function $\exp(x)=e^x$ is one-to-one but not onto, and has this left inverse $g$: if $t>0$, $g(t)=\ln(t)$, while if $t\le0$, $g(t)=17$. The function $\tan^*$ cooked up from the tangent by setting $\tan^*(x)=\tan(x)$ if $x$ is not an odd multiple of $\pi/2$, and $\tan^*((k+1/2)\pi)=0$ is onto, and has the right inverse $h=\arctan$, the usual inverse tangent function. Notice that $g$ is not a right inverse of the exponential function any more than $h$ is a left inverse of the hoked-up tangent function.

share|improve this answer

The reflection of a line along the $x$-axis is the inverse IF the inverse of the original function is defined. A function is invertible if it passes the horizontal line test (so that its inverse will pass the vertical line test).

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.