# Is Inverse of a function continuous too?

I read an example from "Principles of Mathematical Analysis" by Rudin under the section 'Continuity and Compactness'.

According to the example,

Let $X$ be the half-open interval $[0,2\pi)$ on the real line, and let $f$ be the mapping of $X$ onto the circle $Y$ consisting of all points whose distance from the origin is $1$, given by $f(t)=(\cos t, \sin t) \quad(0 \leq t < 2\pi)$

Now, we know that $f$ is continuous, since $f$ is one to one and onto, it has $f^{-1}$, but $f^{-1}$ is not continuous.

Argument:

since, $f$ maps the points from $[0,\pi/2]$ to quarter of the circle in the I quadrant, $[\pi/2,\pi]$ to the II quadrant, $[\pi,3\pi/2]$ to the III quadrant, $[3\pi/2,2\pi)$ to the fourth quadrant, hence $f$ is continuous, similarly $f^{-1}$ maps the points in the quarter of the circle in the first quadrant to $[0,\pi/2]$, similarly the other $3$ quadrants..

it is given that $f^{-1}$ is not continuous at $(1,0)$, how is this possible?

According to the definition of continuity at $x_0$:

For every $\epsilon$ there exits a $\delta > 0$ such that $d(x_0,x)<\delta$ implies $d(f(x_0),f(x))<\epsilon$.

but a open ball at $(1,0)$ with $\delta$ radius, we can find the $\epsilon =2 \pi$ of radius, the above definition gets satisfied...

Obviously, when we move from I quadrant to the point $(1,0) f^{-1}$ converges to $0$ and when we move from from IV quadrant to the point $(1,0) f^{-1}$ converges to $2\pi$..hence left limit not equals right limit, hence it is discontinuous, but I want to know how it violates the definition, I cant find any, if any of my argument is wrong, please correct me.

Secondly, if $X$ is $[0,2\pi]$, then is $f^{-1}$ is continuous? if it is, how is that, how is the difference affects the continuity?

First of all, if $X=[0,2\pi]$, then $f$ is not bijective and therefore does not have an inverse.

Second, let's first remember how we can prove that something is not continuous. Since $f$ is continuous at a point $x_0$ if

For every $\epsilon>0$, there exists $\delta>0$ such that for every $x$, if $|x_0-x| < \delta$, then $|f(x_0)-f(x)| < \epsilon$.

Therefore, to prove that $f$ is not continuous, we need to find one point at which it is not continuous, and we can prove that it is not continuous if we show that

There exists some $\epsilon > 0$ such that for every $\delta >0$, there exists some $x$ such that $|x_0-x|<\delta$ and $|f(x)-f(x_0)|\geq \epsilon$

In our case, the inverse, $f^{-1}$ is not continuous at $(1,0)$, because there exists some $\epsilon$ (in particular, that value of $\epsilon$ can be $1$) such that for every $\delta$, you can find some point $(x,y)$ on $Y$ such that $f^{-1}((x,y))$ is more than $\epsilon$ away from $f^{-1}((1,0))$, which is $0$.

For example, if you take $\delta=0.1$, I can always choose $(x,y) = (\cos(-0.01), \sin(-0.01)$, and you will see that $f^{-1}((x,y))$ is very close to $2\pi$, so nowhere near $0$.

One way to do this is with sequences.

Suppose $f^{-1}$ is continuous at $(1,0).\$ Then it must be the case that

$(x_n,y_n)\to (1,0)\Rightarrow f^{-1}((x_n,y_n))\to f^{-1}((1,0))=0$ for any sequence $\left \{ (x_y,y_n) \right \}_n\subset S^1$.

But if we take $(x_n,y_n)=\left ( \cos \frac{(-1)^{n}}{n},\sin \frac{(-1)^{n}}{n} \right ),\$ then $(x_n,y_n)\to (1,0)\$ but $f^{-1}(x_n,y_n)$ does not converge, since the $f^{-1}(x_k,y_k)\to 0$ if $k=2n$ and $f^{-1}(x_k,y_k)\to 2\pi$ if $k=2n+1$.

The points $p_h=(\cos h,\sin h)$ and $q_h=(\cos h,-\sin h)$ can be made as close as desired by taking $h$ sufficiently small.

But $f^{-1}(p_h)=h$ and $f^{-1}(q_h)=2\pi-h$, so $f^{-1}(p_h)$ and$f^{-1}(q_h)$ cannot be made close by taking $h$ sufficiently small.