|
|
A124651
|
|
Least n-digit number m such that m and m^10 are zeroless.
|
|
1
|
|
|
1, 12, 113, 1134, 11227, 112154, 1112236, 11111566, 111123685, 1111133874, 11111178192, 111111796422, 1111111392823, 11111112811396, 111111112641445, 1111111115954155, 11111111158315794, 111111111132821544, 1111111111273944122, 11111111111777673838, 111111111113343756694
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,2
|
|
COMMENTS
|
a(n)^10 is converging to 2867971991..1 (1 repeated 10*n-18 times at end), or 10^(10*n-10) times the smallest rational greater than (10/9)^10 that contains no 0 digit. - Michael S. Branicky, Jan 12 2021
|
|
LINKS
|
|
|
EXAMPLE
|
12^10 is 61917364224 but 10 and 11^10 = 25937424601 have zeros. - Michael S. Branicky, Jan 12 2021
|
|
PROG
|
(Python)
from sympy import integer_nthroot
def a(n):
if n == 1: return 1
m, perfect = integer_nthroot(int('286797199' + '1'*(10*n-18)), 10)
strm = str(m)
# strm = "1"*n # slower than the foregoing for larger n
while strm.count('0') > 0 or str(m**10).count('0') > 0:
if '0' in strm:
ind0 = strm.find('0')
m = int(strm[:ind0] + '1'*(len(strm)-ind0))
elif strm[-1] == '9':
m += 2
else:
m += 1
strm = str(m)
return m
for n in range(1, 15):
|
|
CROSSREFS
|
|
|
KEYWORD
|
base,nonn
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|