login
A331861
Numbers n for which R(n) + 10^floor(n/2) is prime, where R(n) = (10^n-1)/9.
4
1, 6, 10, 18, 24, 4978
OFFSET
1,2
COMMENTS
The primes corresponding to the terms of the sequence are a subset of the near-repunit primes A105992.
In base 10, R(n) + 10^floor(n/2) has ceiling(n/2)-1 digits 1, one digit 2, and again floor(n/2) digits 1. For odd n, this is a palindrome, for even n the digit 2 is just left to the middle of the number.
There cannot be an odd term > 1 since the corresponding palindrome factors as R((n+1)/2)*(10^((n-1)/2) + 1).
No term can be congruent to 2 mod 3. - Chai Wah Wu, Feb 07 2020
LINKS
Brady Haran and Simon Pampena, Glitch Primes and Cyclops Numbers, Numberphile video (2015).
EXAMPLE
For n = 1, R(n) + 10^floor(n/2) = 2 is prime.
For n = 6, R(n) + 10^floor(n/2) = 112111 is prime.
For n = 10, R(n) + 10^floor(n/2) = 1111211111 is prime.
PROG
(PARI) for(n=0, 9999, isprime(p=10^n\9+10^(n\2))&&print1(n", "))
CROSSREFS
Cf. A105992 (near-repunit primes), A002275 (repunits), A011557 (powers of 10).
Cf. A331860 (variant with floor(n/2-1) instead of floor(n/2)), A331862 (variant with - (digit 0) instead of + (digit 2)).
Sequence in context: A315365 A315366 A248056 * A032641 A293555 A077626
KEYWORD
nonn,more,hard,base
AUTHOR
M. F. Hasler, Jan 30 2020
EXTENSIONS
a(6) from Daniel Suteu, Feb 01 2020
STATUS
approved