The proportion of binary digits of $\sum_{k=1}^\infty \Big\lfloor{\frac{k}{2}\sqrt{p}\Big\rfloor}\cdot2^{-k}$ equal to one, is $> 0.978$ if $p=143$.

Can you prove this? Is it true? If $p$ is an integer, is this proportion never equal to 50%? See my related question regarding this sum, here. For $p=143$, I computed the binary digits in Excel using carry-over operations implemented in Excel formulas. The first few digits equal to zero take place at the following locations:

47, 95, 143, 191, 239, 287, 335, 383, 431, 479, 527, 574, 622, 670, 718, 766, 814, 862, 910, 958, 1006, 1054, 1102, 1149, 1197, 1245, 1293, 1341, 1389, 1437, 1485, 1533, 1581, 1629, 1677, 1724, 1772, 1820, 1868, 1916, 1964, 2012, 2060, 2108, 2156, 2204, 2252, 2299, 2347, 2395

The delta between two successive locations with a zero digit, is 48 most of the time, and sometimes 47. So, less than 1 out of 47 binary digits is equal to zero, though this is not a proof, just a statement based on observations. More precisely, the location delta is 47 (rather than 48) between a zero digit and the previous one, only at the following digit positions: $574+ k \cdot 575$, for $k=0, 1, 2$ and so on.

You can thus compute the exact proportion of binary digits equal to one. Can you compute that proportion? It must be - it seems - between $1-\frac{1}{47}$ and $1-\frac{1}{48}$, and much closer to $1-\frac{1}{48}$ than to $1-\frac{1}{47}$. I assumed here that we are only interested in the fractional part, and the first digit for the fractional part of the number in question, is assigned position 1.

The exciting thing here is the discovery of a class of (presumably) irrational, non-normal numbers, that are rather natural. Usually such numbers are built artificially. Other similar numbers include the rabbit number, and numbers described here (or problem #11 in this article).

Other spectacular examples in the same family

Besides $p=143 = 11 \times 13$, with first zero digit in position 47, we have:

  • $p = 17 \times 19$: the first binary digit equal to 0 is in position 71; about 98.3% of the digits are equal to 1.
  • $p = 29 \times 31$: the first binary digit equal to 0 is in position 119; about 98.7% of the digits are equal to 1.
  • $p = 41 \times 43$: the first binary digit equal to 0 is in position 167; about 99.1% of the digits are equal to 1.
  • $p = 59 \times 61$: the first binary digit equal to 0 is in position 239; more than 99% of the digits are equal to 1.

Sounds like if $p$ is the product of twin primes, it leads to interesting results. Would be interesting to see if the sequence that includes the numbers $47, 71, 119, 167, 239, \cdots$ is well known.

A case with known exact solution

By known, I mean that the exact proportion of binary digits equal to 1 is a known, explicit algebraic number. Not a proof, but it is based on my experience dealing with this kind of stuff, and strong empirical evidence.

The case $p=2$ leads to very strong and simple patterns in the distribution of the binary digits. The proportion of digits equal to 1 is $\sqrt{2}/2$. An immediate consequence is that the number that has these digits, is irrational. Below are the first 2,000 or so digits.

11011011101101110110110111011011101101101110110111011011101101101110110111011011011101101110110111011011011101101110110110111011011101101101110110111011011101101101110110111011011011101101110110111011011011101101110110110111011011101101101110110111011011101101101110110111011011011101101110110111011011011101101110110110111011011101101110110110111011011101101101110110111011011011101101110110111011011011101101110110110111011011101101110110110111011011101101101110110111011011011101101110110111011011011101101110110110111011011101101110110110111011011101101101110110111011011101101101110110111011011011101101110110110111011011101101110110110111011011101101101110110111011011101101101110110111011011011101101110110110111011011101101110110110111011011101101101110110111011011101101101110110111011011011101101110110110111011011101101110110110111011011101101101110110111011011101101101110110111011011011101101110110111011011011101101110110110111011011101101101110110111011011101101101110110111011011011101101110110111011011011101101110110110111011011101101101110110111011011101101101110110111011011011101101110110111011011011101101110110110111011011101101110110110111011011101101101110110111011011011101101110110111011011011101101110110110111011011101101110110110111011011101101101110110111011011011101101110110111011011011101101110110110111011011101101110110110111011011101101101110110111011011011101101110110111011011011101101110110110111011011101101110110110111011011101101101110110111011011101101101110110111011011011101101110110110111011011101101110110110111011011101101101110110111011011101101101110110111011011011101101110110110111011011101101110110110111011011101101101110110111011011101101101110110111011011011101101110110111011011011101101110110110111011011101101101110110111011011101101101110110111011011011101101110110111011011011101101110110110111011011101101101110110111011011101101101110110111011011011101101110110111011011011101101110110110111011011101101110110110111011011101101101110110111011011011101101110110111011011011101101110110110111011011

The lag-1 autocorrelation in this sequence of binary digits seems to be equal to $1 - \sqrt{2} < 0$, a value that is way too small for the number in question to be normal in any base $b$ with $1< b \leq 2$. See chart in section 4.1.(b) in this article for details.

Useful reference

See second half of the following Wolfram article about the Devil's staircase.


Solution 1:

Let's look more generally at sums on the form $$ S = \sum_{k=1}^\infty \lfloor ka\rfloor\cdot 2^{-k} $$ where $a>0$. The original problem has $a=\sqrt{143}/2$.

Let's write $a=A+\alpha$ where $A=\lfloor a\rfloor$ and $0\le\alpha<1$. Since $kA$ is always an integer, this makes $$ S = \sum_{k=1}^\infty (kA+\lfloor k\alpha\rfloor)\cdot 2^{-k} = 2A + \sum_{k=1}^\infty \lfloor k\alpha\rfloor\cdot 2^{-k} $$ as $\sum_{k=1}^\infty k\cdot 2^{-k}=2$. So, the $A$ term makes no difference.

If $a$ is an integer, $S=2A=2a$ is also an integer. Otherwise, $\alpha>0$, which we will assume from now on.

Now, assuming $0<\alpha<1$, we can rewrite $$ S-2A = \sum_{k=1}^\infty \sum_{n=1}^{\lfloor k\alpha\rfloor} 2^{-k} = \sum_{\substack{n,k\ge 1 \\ n\le k\alpha}} 2^{-k} = \sum_{n=1}^\infty \sum_{k=\lceil n/\alpha\rceil}^\infty 2^{-k} = \sum_{n=1}^\infty 2^{1-\lceil n/\alpha\rceil}. $$ So, we have binary decimal $1$ at locations $\lceil n/\alpha\rceil-1$ for $n=1,2,\ldots$. The average distance between $1$s is $1/\alpha$, which makes their density $\alpha$. Correspondingly, the density of $0$s in the binary expansion is $1-\alpha$.

We could have done a similar derivation using $a=A-\alpha$ where $A=\lceil a\rceil$, in which case we would have ended up subtracting negative powers of $2$ instead of adding them. To see that this results in $0$s at in the binary expansion, think of the initial integer written out as $?.11111\ldots$ from which different negative powers of $2$ are subtracted.

The original problem had $a=\sqrt{143}/2$ which makes $\alpha=a-5=0.979130\ldots$, so the sum $S$ will have $97.9130\ldots\%$ of $1$s in the binary expansion.