login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A109863 Primes arising as the 10's complement of A109862(n). 2
7, 5, 3, 89, 809, 647, 617, 71, 89399, 88589, 87179, 86069, 85259, 84449, 83939, 83639, 83339, 82529, 69197, 67577, 66467, 63737, 27773, 25253, 24443, 23633, 23333, 6761, 5651, 5351, 5051, 2621, 8971799, 8925299, 8917199, 8699969, 8671769, 8543459, 8491949 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
COMMENTS
a(n) - 1 is a palindrome. Obviously 7, 5 and 3 are the only palindromic terms. Conjecture: Sequence is infinite.
LINKS
EXAMPLE
353 is a member of A109862 and 647 = 1000 - 353 corresponds to it.
PROG
(Python)
from sympy import isprime
from itertools import product
def tc(n): return 10**len(str(n)) - n
def cond(p): return isprime(p) and isprime(tc(p))
def palcands(digs):
if digs == 1: yield from [2, 3, 5, 7]; return
if digs%2 == 0: yield from [[], [11]][digs==2]; return
for first in "1379":
for p in product("0123456789", repeat=(digs-2)//2):
left = first + "".join(p)
for mid in "0123456789": yield int(left + mid + left[::-1])
def auptod(digs):
return [tc(p) for d in range(1, digs+1) for p in palcands(d) if cond(p)]
print(auptod(7)) # Michael S. Branicky, Jul 05 2021
CROSSREFS
Cf. A109862.
Sequence in context: A090289 A160670 A145985 * A179177 A021574 A021061
KEYWORD
base,nonn
AUTHOR
Amarnath Murthy, Jul 08 2005
EXTENSIONS
More terms from Joshua Zucker, May 08 2006
Corrected by T. D. Noe, Nov 15 2006
a(37) and beyond from Michael S. Branicky, Jul 05 2021
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 25 08:27 EDT 2024. Contains 371964 sequences. (Running on oeis4.)