A007881 Erroneous version of A001357 printed by mistake on back cover of Encyclopedia of Integer Sequences.
1, 2, 4, 8, 18, 71
Offset: 0
This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
a(10) = 16 because 2^16 = 65536 does not have all distinct digits in base 10, while 2^k does have all distinct digits for 1 <= k <= 15.
f:= proc(n) local k,L; for k from 2 do L:= convert(2^k,base,n); if nops(L) <> nops(convert(L,set)) then return k fi od; end proc: map(f, [$2..100]);
from itertools import count from sympy.ntheory import digits def a(n): return next(k for k in count(2) if len(set(d:=digits(1<Michael S. Branicky, Jul 05 2023
a(10) = 1357_bij9 = 9*(9*(9*1+3)+5)+7 = 1024 = 2^10. a(16) = 98797_bij9 = 9*(9*(9*(9*9+8)+7)+9)+7 = 65536 = 2^16.
b:= proc(n) local d, l, m; m:= n; l:= ""; while m>0 do d:= irem(m, 9, 'm'); if d=0 then d:=9; m:= m-1 fi; l:= d, l od; parse(cat(l)) end: a:= n-> b(2^n): seq(a(n), n=0..33);
a(10) = 29 because all decimal digits of 2^29 = 536870912 are distinct.
f:= proc(b) local M,k,L; M:= b^b - (b^b-b)/(b-1)^2; for k from ilog2(M) to 1 by -1 do L:= convert(2^k,base,b); if nops(L) = nops(convert(L,set)) then return k fi od end proc: map(f, [$2..100]);
from sympy.ntheory.factor_ import digits def A364089(n): m = 1<<(l:=((r:=n**n)-(r-n)//(n-1)**2).bit_length()-1) while len(d:=digits(m,n)[1:]) > len(set(d)): l -= 1 m >>= 1 return l # Chai Wah Wu, Jul 07 2023
Comments