# Limit associated with a recursion, connection to normality of quadratic irrationals

Update on 3/2/2020. All the material below and much more has been incorporated into a comprehensive article on this topic. The question below is discussed in that article, entitled "State-of-the-Art Statistical Science to Tackle Famous Number Theory Conjectures", and available here.

I posted a popular question 5 months ago about the following recursion, see here.

If $$z_n < 2y_n$$ Then

• $$y_{n+1} = 4y_n - 2z_n$$
• $$z_{n+1} = 2z_n + 3$$
• $$d_{n+1}=1$$

Else

• $$y_{n+1} = 4y_n$$
• $$z_{n+1} = 2 z_n - 1$$
• $$d_{n+1}=0$$

Back then, I wrote:

The sequence $$d_n$$ represents the binary digits of some unknown number $$x$$, a number that depends on the initial conditions. It turns out that if $$y_1=2,z_1=5$$ then that number is $$x=\sqrt{2}$$.

Here I offer a full solution and a potential path to proving the normality of quadratic numbers. My question is about proving that my main result (below) is correct. It is backed by very strong empirical results involving computations with thousands of digits. By normality, I mean that 50% of the binary digits of $$x$$ are equal to 1. This is one of the most challenging unsolved mathematical conjectures of all times.

Below is a Perl script that does all the computations. It uses the Bignum library to perform exact arithmetic (computation of millions of binary digits for each number, using the formulas described here.) The variable called number in the code corresponds to $$x$$.

use strict;
use bignum;

my $$y; my$$z;
my $$u; my$$v;
my $$k; my$$c;
my $even; my $$counter; my$$seed_y; my $$seed_z; my$$number; my $$denominator; my$$c1; my$c2;

$counter=0; open(OUT2,">collatzr.txt"); # summary stats open(OUT,">coll2.txt"); # details and digits for each number for ($$seed_y=1;$$seed_y<=5; $$seed_y++) { for (seed_z=seed_y; seed_z<=10;$$seed_z++) { $$y=$$seed_y; $$z=$$seed_z; $$u=2*$$y-$$z;$$v=2*$z+3;

$$number=0;$$denominator=1;
$$c1=0;$$c2=0;