How do I show a function on 2-adic units is continuous (using the 2-adic metric)?

I'd be happy to learn the general rule or definition. But in particular I need to show that $f(x)=\dfrac{3x+1}{2^{v_2(3x+1)}}$ is continuous at all odd numbers.

Since the function is isometric in $\lvert\cdot\rvert_2$, i.e. since $\lvert f(x)\rvert_2=\lvert x\rvert_2$ every orbit of the function is duplicated, multiplied by any power of $2$. This can therefore be formulated in various ways; as a function though the odd numbers, through the dyadic rationals, but the following seems good to work with. If we let $n$ be a positive integer and $k$ be the power of $2$ we can define:


So $f(2^k(2n+1)=(3n+2)\times2^k\times\lvert3n+2\rvert_2$

Here is what I have so far:

I think to prove continuity in the 2-adic metric I need $\lvert x_n-x\rvert_2=0\implies\lvert f(x_n)-f(x)\rvert_2=0$

I think $k$ and $n$ are independent so I think I can examine them independently. Taking $k$ to infinity brings both $x$ and $f(x)$ to zero so that seems to satisfies the continuity requirement.

Moving on to $n$; this seems to be an exercise in proving convergence within odd integers which are in a sense a subset of the 2-adic units. I know all Cauchy sequences in these converge to 2-adic units but not much more than that.

However I do have a little insight into this particular function. For example if we examine the inputs $x$ which map to any given output of $f(x)$, it can fairly easily be shown that these $x$'s take the form of a set $\left\{4^mp+\dfrac{4^m-1}{3}:m,n\in\mathbb{N}\right\}$ so, at least for any given output $f(x)$ the inputs always converge to $x=\frac{-1}{3}$ as the intervals between them become large powers of $2$.

In fact the orbit of the function $a(2^kx)=2^k(4x+1)$ on variation of $x$ and holding $k$ fixed is in a sense orthogonal to $f(x)$; which is a restatement of the above except not in closed form.

  • $\begingroup$ Do you understand how $\mathbb{R}$ is $\mathbb{Q}$ plus the limits of every Cauchy sequences for $|.|$ ? Then $\mathbb{Z}_2$ is $\mathbb{Z}$ plus the limits of every Cauchy sequences for $|.|_2$. A function $g : (\mathbb{Z}_2,|.|_2) \to (X,|.|_X)$ is continuous iff $\lim_{n \to \infty} |a_n - a| = 0 \implies \lim_{n \to \infty} |g(a_n) - g(a)| = 0$. Thus your function $f : (\mathbb{Q},|.|_2) \to (\mathbb{Q},|.|_2)$ is continuous iff for every Cauchy sequence $a_n \in (\mathbb{Q},|.|_2)$ then $f(a_n)$ is Cauchy $\in (\mathbb{Q},|.|_2)$. $\endgroup$
    – reuns
    Commented Dec 19, 2017 at 20:26
  • $\begingroup$ @reuns thanks for the hint. Yes I understand completion/Cauchy. Apologies for being daft; is this a) something I should be able to answer from here given your hint, b) too hard, c) obviously false from what you write, or d) provable only if I prove the Collatz Conjecture first!? $\endgroup$ Commented Dec 19, 2017 at 20:51
  • $\begingroup$ If you can define $|.|_2$ and prove the addition and multiplication are continuous $(\mathbb{Z},|.|_2)\times (\mathbb{Z},|.|_2) \to (\mathbb{Z},|.|_2) $, then you shouldn't have any problem to answer. Of course replacing $2^{-v_2(x)}$ by $|x|_2$ may help. Do you think $x \mapsto |x|_2$ is continuous $(\mathbb{Z},|.|_2) \to \mathbb{R},|.|)$ ? Is it continuous $(\mathbb{Z},|.|_2) \to (\mathbb{Q},|.|_2)$ ? Maybe more important : do you understand why if $f$ is continuous on $(\mathbb{Z},|.|_2) $ then it is also naturally defined and continuous on $(\mathbb{Z}_2,|.|_2) $ ? $\endgroup$
    – reuns
    Commented Dec 19, 2017 at 21:05
  • 1
    $\begingroup$ ??? Nonsense again. The Collatz function is continuous for $|.|_2$ and has a canonical continuous extension to $\mathbb{Z}_2$. But its condensed version $\tilde{f}(2n+1)= 3(2n+1)+1, \tilde{f}(2^k (2n+1)) = 2n+1$ is not continuous. $\endgroup$
    – reuns
    Commented Dec 20, 2017 at 5:47
  • 2
    $\begingroup$ $\tilde{f}(2^k (2n+1)) = 2n+1$ is not continuous because $\lim_{k \to \infty} 2^k (2k+1) = 0$ and $\lim_{k \to \infty} \tilde{f}(2^k (2k+1))$ diverges. The non-condensed Collatz function can be extended to a continuous function on $\mathbb{Z}_2$ and $\mathbb{Q}_2$. $\endgroup$
    – reuns
    Commented Dec 27, 2017 at 23:09

1 Answer 1


As for the map

$$f: x \mapsto \frac{3x+1}{2^{v_2(3x+1)}} = (3x+1)\cdot |3x+1|_2,$$

it is the composition of $x\mapsto 3x+1$ and $y\mapsto y |y|_2$, so we want to enquire where these are continuous, the only interesting part being actually the absolute value map $| \cdot|_2$ itself. Viewed as map $(\Bbb{Q}_2, |\cdot|_2)\rightarrow (\Bbb{Q}_2, |\cdot|_2)$, the absolute value is not continuous at $0$ (because $|2^n|_2 =2^{-n}$ does not converge $2$-adically for $n\to \infty$), but outside of $0$, it is actually locally constant and hence continuous. So the composite map $g: (\Bbb{Q}_2, |\cdot|_2)\rightarrow (\Bbb{Q}_2, |\cdot|_2)$ is continuous everywhere except at $x=-\frac{1}{3}$. (Note, however, that this point $-1/3$ w.r.t. the $2$-adic metric does lie in every neighbourhood of $\mathbb{N}$, even in every neighbourhood of the odd natural numbers, as mentioned here recently.)

With a similar argument, the function $\tilde f$ in your answer -- which, if I understand it correctly, is nothing else than $x\mapsto |x|_2^{-1}\cdot f(x\cdot |x|_2)$ -- is continuous as function $(\Bbb{Q}_2, |\cdot|_2)\rightarrow (\Bbb{Q}_2, |\cdot|_2)$, except at the points $-\frac{2^k}{3}, k \in \mathbb{Z}$.

As for the function $g$, which I would rewrite as $x\mapsto (3x+|x|_2^{-1})\cdot |3x+|x|_2^{-1}|_2$, it looks as if it is continuous except at $0$ and all $-\frac{2^k}{3}, k \in \mathbb{Z}$.

  • $\begingroup$ Thanks, this is fabulous, I am much clearer now. I edited and simplified the question and deleted my attempted answer so I may adjust those amends in the morning to ensure your answer makes sense. The first thing I am unsure of here, is the fact that to treat the function as a composition of two functions you had to use a function which leaves the odd numbers, and whether this may affect the validity of the composition as a means of deciding the function is continuous in the odd numbers. Is there any doubt over this? $\endgroup$ Commented Dec 31, 2017 at 2:01
  • $\begingroup$ P.s. you may be able to show much faster than me that this implies the orbit of $\tilde{f}$ can not be periodic in the integers other than period $1$, which I hope now follows fairly quickly. $\endgroup$ Commented Dec 31, 2017 at 2:40
  • 1
    $\begingroup$ I took your function(s) as defined on all of $\mathbb{Q}_2$. The continuity results stay the same when you restrict it to any subspace. By the way, one has $|f(x)|_2 = 1$ for all $x \in \mathbb{Q}_2$ except $x=-1/3$; in particular, $f$ is only isometric if you restrict it to a subset consisting of elements of absolute value $1$ (like the odd integers). -- I do not know what it means for a function to have "a periodic orbit", and for my guesses of what that might mean, I do not see how it would follow from those continuity results. $\endgroup$ Commented Dec 31, 2017 at 3:35
  • $\begingroup$ Ok I will think more but I think this could be an important result. Orbit is just repeated composition. Period $n$ just means the orbit gets back where it started in $n$ compositions so $\exists x|\tilde{f}^n(x)=x$. My thinking is... the orbit of the Collatz function is closed to the odd integers on composition. I have an argument there are no continuous periodic functions in the 2-adic space not of period 1. It may translate to the odd numbers proving no nontrivial loops in the Collatz function. $\endgroup$ Commented Dec 31, 2017 at 7:52
  • 2
    $\begingroup$ Then that argument you have is wrong. Replace $3x+1$ by $5x+1$ in the formula; this also gives a function that is continuous $2$-adically on the odd integers, but $f(13) = 33, f^2(13) = 83, f^3(13)=13$. (Off-topic advice: It is you who should immediately think of such easy counterexamples, not me. You should develop the habit of checking "wait, if I think this proves Collatz, why does it not work in the variations where there are counterexamples?" This would save you and others frustration and embarrassment.) $\endgroup$ Commented Dec 31, 2017 at 19:45

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .