0
$\begingroup$

Define $f:\mathbb{R}\rightarrow\mathbb{R}$ by
$\ f(x) = \begin{cases} 1/q & \text{if } x =p/q \space(\mathrm{lowest}\space \mathrm{terms},\space\mathrm{nonzero})\\ 0 & \text{if } x = 0\space\mathrm{or}\space x\not\in\mathbb{Q} \end{cases} $
Show that f is continuous at 0 and every $x\in\mathbb{R}\setminus\mathbb{Q}$. Show that $f$ is not continuous at any nonzero rational pt.

Attempt: (1) First I need to show that $f$ is continuous at zero. Then I need to show that $\forall\epsilon>0,\exists\delta>0$ s.t. $y\in B_{\delta}(0)$ implies $f(y)\in B_{\epsilon}(f(0))$. So I need to show $y\in B_{\delta}(0)$ implies $f(y)\in B_{\epsilon}(0)$ for $y\in\mathbb{R}$. Note $f(0)=0$. Pick $\delta =...$

(2) Then, I need to show that $f$ is continuous at every irrational number. Here I need to show that $\forall\epsilon>0,\exists\delta>0$ s.t. $y\in B_{\delta}(0)$ implies $f(y)\in B_{\epsilon}(f(0))$. Note that once again $f(0)=0$. Pick $\delta = ...$

(3) Then, I need to show that $f$ is not continuous at every nonzero rational number. Let $q\in\mathbb{Q}$. Intuitively, because $\mathbb{I}$ is dense in $\mathbb{R}$, we can construct a sequence $x_n\in\mathbb{I}$ such that $x_n\rightarrow q$. Since $x_n\in\mathbb{I}$, $\lim{x_n}=0\neq f(x)$ so clearly $f(x_n)\not\rightarrow f(x)$.

  • 0
    According to [Wikipedia](http://en.wikipedia.org/wiki/Thomae%27s_function) various names are used for this function: Thomae's function, the popcorn function, the raindrop function, the countable cloud function, the modified Dirichlet function, the ruler function, the Riemann function, or the Stars over Babylon.2012-06-30

2 Answers 2

1

Hints:

Keep in mind that to show $f$ is continuous at $p=0$ or at $p$ irrational, that $f(p)=0$. So to show continuity at $p$, you need to show that $|f(z)|$ can be made as small as desired by taking $z$ sufficiently close to $p$.

Towards this end, use (and prove) the fact that one can select an open ball centered at $p$ whose radius is so small that the ball excludes all rationals in lowest terms with denominator less than a given integer. So, for example, at the irrational $p$, there is an open ball $U$ centered at $p$ that contains no rational in lowest terms of the form $M/N$ with $N\le 1000$ (or, equivalently, if $q$ is rational, in $U$, and in lowest terms, then its denominator is greater than 1000).


A sequential argument, as you have in (3) (but your argument seems off...), is suitable to show that $f$ is not continuous at a rational $q\ne0$. Here, note that $f(q)>0$ and that every nhood of $q$ contains irrational numbers. (So, your argument in (3) should start with irrationals converging to $x$.)

  • 0
    thanks! The intuition here certainly helped, hopefully my edits are an improvement.2012-02-06
0

I think the following can help you a lot:

Proposition: Let $\,\displaystyle{\left\{\frac{p_n}{q_n}\right\}}\subset\mathbb Q\,$ be a rational sequence, with $\,(p_n,q_n)=1\,\,\text{and}\,\,q_n>0\,\,,\,\forall n\,$ , and s.t. $\frac{p_n}{q_n}\xrightarrow [n\to\infty]{}x\in\mathbb R-\mathbb Q$ Then $\,q_n\xrightarrow [n\to\infty]{} \infty\,$

Proof (sketch): Suppose not. Then $\,\,\exists\,R\in\mathbb N\,\,s.t.\,\,\forall\,M\in\mathbb N\,\,\exists\,n_M\in\mathbb N\,\,s.t.\,\,n_m>M\,\,and\,\,q_{n_M}\leq R\,\,$

We now take a closer look at the subsequence $\left\{\frac{p_{n_M}}{q_{n_M}}\right\}_{M=1}^\infty$ where we choose the subindexes in such a way that $\,n_1 (otherwise we have no subsequence at all. Fill in details here).

But $\,\displaystyle{\frac{p_{n_m}}{q_{n_m}}\xrightarrow [M\to\infty]{} x}\,$ (why?) , so for any $\epsilon>0\,\,\,\exists K_\epsilon\in\mathbb N\,\,s.t.\,\,n_M>K_\epsilon\Longrightarrow \left|\frac{p_{n_M}}{q_{n_M}}-x\right|<\epsilon\Longrightarrow $ $\Longrightarrow R\geq q_{n_M}>\left|\frac{p_{n_M}-q_{n_M}x}{\epsilon}\right|\geq\frac{|p_{n_M}|-R|x|}{\epsilon}\Longrightarrow $ $\Longrightarrow R(\epsilon+|x|)\geq |p_{n_M}|$ which means also $\,\{p_{n_M}\}\,$ is bounded (take, for example, $\,\epsilon=1\,$ ), which is absurd.