OFFSET
1,1
COMMENTS
The early portion of this sequence appears to be very similar to the early portions of two other sequences. Note that a(n) = A046075(n) for n = 1..81. A046075 deals with nontrivial undulants of 3 digits or more which by definition excludes RepDigits, but which includes non-palindromic terms when 4-digit numbers are reached. For example a(82) = 1001 but A046075(82) = 1010. Note also that a(n) = A050783(n+10) for n = 1..81. A050783 deals with palindromes that contain no consecutive pairs of equal digits, so although A050783 excludes RepDigits, it includes the single-digit palindromes and excludes a large number of the palindromes in this sequence (such as, for example, all the 4-digit nontrivial palindromes and larger nontrivial palindromes such as 22022 or 61116). A050783(92) = 10101. Note that in the first 65534 values of n there are 754 palindromes, 712 nontrivial palindromes and 42 RepDigits.
LINKS
Michael S. Branicky, Table of n, a(n) for n = 1..10000
EXAMPLE
PROG
(Python)
from itertools import count, islice, product
def agen(): # generator of terms
digits = "0123456789"
for d in count(3):
for p in product(digits, repeat=d//2):
if d > 1 and p[0] == "0": continue
left = "".join(p); right = left[::-1]
for mid in [[""], digits][d%2]:
t = left + mid + right
if len(set(t)) != 1: yield int(t)
print(list(islice(agen(), 52))) # Michael S. Branicky, May 17 2022
CROSSREFS
KEYWORD
base,nonn
AUTHOR
Chuck Seggelin (barkeep(AT)plastereddragon.com), Oct 21 2003
STATUS
approved