0

… in general, but also related to a calculus problem I have before me which is about continuity.

The question regards continuity wrt the function

$$ f(x) = \begin{cases} x, x \in \mathbb{Q} \\ 0, x \in \mathbb{R} /\ \mathbb{Q} \end{cases} $$

You can probably see where I’m going with the question/title of the post… Are there $\ge2$ irrationals between any 2 rationals? Is $f(x)$ continuous on the second interval/condition?

I know the irrationals are denser but does that shake out in concrete ways like establishing continuity in the above function?

Thanks,

El Jfe
  • 41
  • 3
    Between any two rationals there is an infinite family of irrationals. – MJD May 19 '24 at 03:03
  • 1
    We already know there is an irrational number between any two real numbers. So if $x_1,x_2 \in\Bbb R$ with $x_1<x_2$ then there is an irrational number in the interval $(x_1,x_2)$. However, we also know then that there must be an irrational number in the interval $(x_1,\frac{x_1}{2}+\frac{x_2}{2})$ and likewise for $(\frac{x_1+x_2}{2},x_2)$. – K.defaoite May 19 '24 at 03:06
  • Yes, there are also at least two irrationals between any two rationals. But this says nothing about the question you actually need to answer. You need to review and apply the definition of continuity. – David K May 19 '24 at 03:08
  • @David K if the interval is sufficiently small, like small enough to be between two rationals, could you not possibly think about $\lim_{x \to \text{irrational } c} f(x) = f(c)$ ? – El Jfe May 19 '24 at 03:21
  • 1
    In fact, there are actually uncountably many irrational numbers between any two rational numbers. Namely, by translating and scaling, it suffices to show that $[0,1] \cap (\mathbb{R} \setminus \mathbb{Q})$ is uncountably infinite, which is true by Cantor's diagonal argument. For arbitrary intervals $[x,y]$, just map $z$ to $(z-x)/(y-x)$ to establish a bijection between $[x,y]$ and $[0,1]$. – Geoffrey Trang May 19 '24 at 03:36
  • Every interval is between two rationals. For example, the interval $[\pi-1,\pi+1]$ is between $2$ and $4.$ But perhaps you are thinking that a much smaller interval might be between two consecutive rationals. You should know that there’s no such thing. – David K May 19 '24 at 03:49
  • 2
    There is also an infinite number of rationals between any two irrationals. Only a countable infinite number, but certainly more than two. More importantly to your problem, between any two real numbers (rational or irrational or one of each) there is at least one rational number and at least one irrational number. – David K May 19 '24 at 03:52
  • Addressing your question in the title: for two rational numbers $a<b$ all the numbers $a+(b-a)n^{-1}\sqrt{2}$ for $n\ge 2$ are irrational and are located between $a$ and $b.$ – Ryszard Szwarc May 19 '24 at 06:10
  • 1
    @David K, I originally had the word consecutive in the post title and it somehow got edited out. For me that’s at the heart of my problem. I appreciate your responses. – El Jfe May 19 '24 at 11:31

1 Answers1

1

See the answers to What does it mean for rational numbers to be "dense in the reals?" for two interpretations of what we mean when we say the rational numbers are dense on the real number line.

The two interpretations are mathematically equivalent, so let's use the one that says there is a rational number between any two real numbers. The irrational numbers are also dense in this sense: there is an irrational number between any two real numbers.

That's all dense means in this context. It's the answer to a true-false question. There's no answer to this question that's "truer" than "true".

If anyone says the irrationals are denser than the rationals, they're talking about a completely different property: how many numbers of this kind can you find between two real numbers? It turns out that there are more irrational numbers than rational numbers.

But when you are looking into the continuity of a function, it doesn't matter whether you can find uncountably many numbers of a certain type within an interval or only countably many such numbers. What matters is whether you can find even one number $x$ where the value of $f(x)$ prevents you from saying your function is continuous. So all we really need to consider is the original meaning of numbers being "dense", namely, the answer to that true-false question. Both the rationals and irrationals are dense on the real number line. That's all you need to know about how "dense" they are.

Finally, there is no such thing as two consecutive rational numbers. If you have any two rational numbers $p$ and $q$, then $\frac{p+q}2$ is also a rational number and it is between $p$ and $q.$ The idea of two consecutive numbers refers to a set of numbers that is not dense. For example, you can say that there are infinitely many rational and irrational numbers between two consecutive integers, because the integers are not dense. But once you find out that a set of numbers is dense, you can forget about "consecutive" numbers in that set.

Infinity is weird. Don't use finite thinking to reason about infinite sets.


A hint on how to continue from here (actually, how to start over, but correctly): the problem you're looking into (at what points is $f$ continuous?) will most likely require you to go all the way back to the definition of continuity. (I doubt that you've proved any subsequent theorems about continuity that would help.) So the first step in solving it is to write down the complete definition of continuity, including the statement that must be true for a particular number $c$ in order for $f$ to be continuous at $c.$ Then write the statement that negates this statement. At each real number $c,$ just one of these statements will be true.

But in order to really answer the question, you will probably also need to rewrite the part about a "limit" in both of your statements, using the definition of a limit. It is relatively straightforward to apply the limit definition directly to this function, but without it you're likely to give informal and inadequate reasoning for your conclusions.

David K
  • 108,155
  • That’s a nice post. Thx again. I have made this with infinity mistake before, and might still again. So where I would land is $\lim_{h \to 0} f(c+h) \ne f(c)$ – El Jfe May 20 '24 at 15:24