login
A348109
Lexicographically earliest sequence S of distinct positive terms such that the first n digits of a(n)*a(n+1) are the first n digits of S.
2
1, 10, 11, 100, 1101, 10001, 11010, 100010, 110099991, 1000100001, 1100999910, 10001000010, 110099990992, 100010000100, 11009999099191, 100010000099992, 1100999909919097, 10001000009999195, 110099990991909693, 1000100000999919493, 11009999099190969296
OFFSET
1,2
COMMENTS
A self-describing sequence.
LINKS
EXAMPLE
a(1)*a(2) = 1*10 = 10 and 1 is the 1st digit of the product and S;
a(2)*a(3) = 10*11 = 110 and 1, 1 are the first 2 digits of the product and S;
a(3)*a(4) = 11*100 = 1100 and 1, 1, 0 are the first 3 digits of the product and S;
a(4)*a(5) = 100*1101 = 110100 and 1, 1, 0, 1 are the first 4 digits of the product and S;
a(5)*a(6) = 1101*10001 = 11011101 and 1, 1, 0, 1, 1 are the first 5 digits of the product and S;
a(6)*a(7) = 10001*11010 = 110111010 and 1, 1, 0, 1, 1, 1 are the first 6 digits of the product and S; etc.
PROG
(Python)
def aupton(terms):
alst, astr, n = [1], "1", 1
while len(alst) < terms:
an, n = alst[-1], len(alst)
target, pow10 = int(astr[:n]), 1
while len(alst) == n:
i = 0
while i < pow10:
q, r = divmod(target+i, an)
if r == 0 and q not in alst:
alst.append(q)
astr += str(q)
break
i += an - r
pow10 *= 10
target *= 10
return alst
print(aupton(21)) # Michael S. Branicky, Jan 07 2022
CROSSREFS
Cf. A348108.
Sequence in context: A038313 A066330 A361336 * A125099 A055611 A077813
KEYWORD
base,nonn
AUTHOR
Eric Angelini and Carole Dubois, Sep 30 2021
EXTENSIONS
a(15) and beyond from Michael S. Branicky, Jan 07 2022
STATUS
approved