6

Prove that the function $f$ is continuous only at the irrational points.

$f(x)=\begin{cases} 0 & ;x \in \mathbb R-\mathbb Q \\ \dfrac{1}{n} & ;x=\dfrac {m}{n} :\gcd(m,n)=1;m,n \in \mathbb Z \\ 1 & ;x=0 \end{cases}$

Attempt: Let us suppose $a \in [0,1]$ such that $f$ is continuous in $[0,1]$ Then :

$\forall \epsilon >0, \exists \delta >0 $ such that $|g(x)-g(a)|< \epsilon$ whenever $|x-a|< \delta$

Case $1$ :Suppose $a$ is a rational element in the interval $[0,1]$

Then if $a=\dfrac {p}{q} \implies g(a) = \dfrac {1}{q}$. Hence :

$|g(x)-\dfrac {1}{q} |< \epsilon~~~........(1)$.

$(a)$ Now, if $x$ is a rational element, then $(1)$ reduces to $\dfrac {1}{q} < \epsilon$ which is not true always.

Hence, there is no continuity for any rational point $a$

Case $2$ :Suppose $a$ is an irrational element in the interval $[0,1]$

$\forall \epsilon >0, \exists \delta >0 $ such that $|g(x)-g(a)|< \epsilon$ whenever $|x-a|< \delta$

Hence, $|g(x)-0|< \epsilon ~~~...........(2)$

$(a)$ Now, if $x= \dfrac {r}{s}$ is a rational element: $g(x) =\dfrac {1}{s}$

There always exist an integer $s$ such that $(2)$ holds

But, how do we find the value of $\delta$?

$(b)$ If $x$ is an irrational element, then $|g(x)|=0< \epsilon$

Which is always true for any $\delta$.

Did I attempt this problem correctly?

Thank you for your help.

MathMan
  • 9,312

2 Answers2

14

Firstly, $f$ can't be continuous at any rational point. Because if $x =\frac{m}{n}$ with $(m,n) = 1$, then $f(x) = \frac{1}{n}$. But we can always find an irrational sequence $x_n \to x$ and $f(x_n) = 0$ doesn't converge to $\frac{1}{n}$.

Secondly, $f$ is continuous at irrational points.

Take any $y$ irrational so $f(y) = 0$. For any $\epsilon >0$, we know the number of intgers $n$ such that $\frac{1}{n} > \epsilon$ is finite. For each fixed such $n$, the number of $m$ such that $\frac{m}{n}$ is in the interval $[y-1, y+1]$ is finite. Thus the number of rational numbers $\frac{m}{n}$ in the interval $[y-1, y+1]$ with $\frac{1}{n} > \epsilon$ is finite. Define $d$ as the smallest distance of these $\frac{m}{n}$ with $y$. Then for any $z$ with $|y-z|<d$ we have $|f(z)-f(y)|<\epsilon$

  • Thank you for your answer. I have edited my question. I meant $f$ to be continuous at only the irrational points only – MathMan Oct 06 '14 at 15:31
  • 1
    @VHP Yeah I see your edition. In fact $f$ is continuous not only at irrational points in $[0,1]$, but at all the irrational points in $\mathbb{R}$ – Petite Etincelle Oct 06 '14 at 15:34
  • @Liy: What happens if we use a point outside $|y-z|<d$? – MathMan Oct 06 '14 at 16:17
  • @VHP It may be one of the $\frac{m}{n}$ with $\frac{1}{n}> \epsilon$ – Petite Etincelle Oct 06 '14 at 16:19
  • I have a little trouble understanding this. Could you please give me an example? – MathMan Oct 06 '14 at 16:24
  • Suppose $x_1, x_2, x_3$ are distinct. Define $d = \min{|x_n - x|, n = 1,2,3}$ for example, then if $|y-x| > d$, $y$ could be one of $x_1, x_2, x_3$. Anyway, it's enough to show good property for points inside $|y-z|<d$, why do you want to take points outside it? – Petite Etincelle Oct 06 '14 at 16:28
  • Uhmm, for any $x = \dfrac {m} {n}, f(x) = \dfrac {1} {n}$. Any rational number like $ \dfrac {1} {n}, \dfrac {4000} {n}, \dfrac {50000} {n}$ also satisfy $g(x)= \dfrac {1} {n}$. Hence, we should be able to take infinitely many of these rational numbers – MathMan Oct 06 '14 at 16:35
  • @VHP But they should lie in the interval $[y-1, y+1]$. Anyway you find the reason why I use this interval $[y-1, y+1]$ :) – Petite Etincelle Oct 06 '14 at 16:37
  • Is it because you wanted to enclose $[0,1]$? – MathMan Oct 06 '14 at 16:45
  • @VHP No, just as you have found, if I didn't take a bounded interval around $y$, then the number of $\frac{m}{n}$ satisfying the wanted condtion would be infinite – Petite Etincelle Oct 06 '14 at 16:47
  • Ooo .. I think I got it. Thank you . Silly me :-) – MathMan Oct 06 '14 at 16:49
  • @VHP Great, you are welcome – Petite Etincelle Oct 06 '14 at 16:51
1

Yes you have proceeded in a right way. Observe for any $\epsilon>0$ $\exists n\in \Bbb N$ s.t $\frac1n<\epsilon$ & for any $a\in \Bbb R\setminus \Bbb Q$ we can choose $\frac pq \in \Bbb Q$ s.t $\frac 1q<\frac1n<\epsilon$

Ri-Li
  • 9,466
  • 4
  • 56
  • 104