1
$\begingroup$

The number $C(n)$ , where $n$ is a positive integer is defined as follows : Write the numbers $j$ from $1$ to $n$ $j$ times. The resulting number is $C(n)$. The letter $C$ comes from the name I invented for these numbers : "Crazy Numbers"

Two examples ($C(8)$ and $C(10)$) including the PARI-routine calculating $C(n)$ :

? s=0;n=8;for(j=1,n,for(k=1,j,s=s*10^length(digits(j))+j));print(s)
122333444455555666666777777788888888
? s=0;n=10;for(j=1,n,for(k=1,j,s=s*10^length(digits(j))+j));print(s)
12233344445555566666677777778888888899999999910101010101010101010
?

To get $RC(n)$ (the "reversed crazy numbers"), the procedure is reversed, so we write the numbers from $n$ to $1$.

So, $RC(8)$ and $RC(10)$ are the following numbers :

? s=0;n=8;forstep(j=n,1,-1,for(k=1,j,s=s*10^length(digits(j))+j));print(s)
888888887777777666666555554444333221
? s=0;n=10;forstep(j=n,1,-1,for(k=1,j,s=s*10^length(digits(j))+j));print(s)
10101010101010101010999999999888888887777777666666555554444333221
?

I searched for prime numbers $C(n)$ or $RC(n)$ and did not find an example yet. The sequences $C(n)$ and $RC(n)$ are growing rapidly, so there might be no prime number of either form. For $n\le 154$, no primes of the desired form exist. Since $C(154)$ and $RC(154)$ have $30\ 810$ digits, a prime of the desired form must be very large, having more than $30\ 000$ digits

  • Are there primes of the form $C(n)$ or $RC(n)$ ?
  • Is there a formula to calculate $C(n)$ or $RC(n)$ more quickly ?
$\endgroup$
  • 1
    $\begingroup$ It is easy to check that the reminder of $C(n)$ & $RC(n)$; module $3$, is equal to $n-[\dfrac{n}{3}]$.So $C(n)$ & $RC(n)$ are divisible by $3$ if and only if $n \overset{9}{\equiv} 4$ or $8$ or $0$. So you can improve the speede of your search by eliminating these numbers. For example $n=116,117$ satisfies this condition. $\endgroup$ – Davood Khajehpour Jul 28 '17 at 10:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.