login
A270026
a(n) is the smallest b for which the base-b representation of n contains at least one 0 (or 0 if no such base exists).
2
0, 2, 3, 2, 2, 2, 7, 2, 2, 2, 2, 2, 2, 2, 3, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 2, 2, 2, 2, 2, 2, 2, 2, 2
OFFSET
1,2
COMMENTS
For n > 1, a(n)=2 whenever n+1 is not a power of 2.
It is conjectured that the only terms that are neither 2 nor 3 in this sequence are a(7) and a(32767), which are 7 and 5 respectively.
a(n) > 0 for n >= 2 since the base-n representation of n is 10.
LINKS
Eric Weisstein's World of Mathematics, Ternary
MATHEMATICA
Table[SelectFirst[Range[2, 1200], DigitCount[n, #, 0] > 0 &], {n, 2, 120}] (* Michael De Vlieger, Mar 09 2016, Version 10 *)
PROG
(PARI) a(n) = if (n==1, 0, my(b=2); while(vecmin(digits(n, b)), b++); b); \\ Michel Marcus, Mar 09 2016
CROSSREFS
Sequence in context: A373249 A077199 A145390 * A340703 A128049 A104543
KEYWORD
nonn,base
AUTHOR
Nathan Fox, Mar 08 2016
STATUS
approved