OFFSET
1,1
COMMENTS
No more terms < 10^8. - Bert Dobbelaere, Mar 20 2019
FORMULA
a(1) = A063566(7). - Michel Marcus, Aug 05 2014
EXAMPLE
a(2) = 11 because 3^11 = 177147 is the smallest power of 3 to contain a run of two consecutive 7's in its decimal form.
MATHEMATICA
a = ""; Do[ a = StringJoin[a, "7"]; b = StringJoin[a, "7"]; k = 1; While[ StringPosition[ ToString[3^k], a] == {} || StringPosition[ ToString[3^k], b] != {}, k++ ]; Print[k], {n, 10} ]
PROG
(Python)
def A131546(n):
....str7 = '7'*n
....x, exponent = 3, 1
....while not str7 in str(x):
........exponent += 1
........x *= 3
....return exponent # Chai Wah Wu, Aug 05 2014
CROSSREFS
KEYWORD
more,nonn,base
AUTHOR
Shyam Sunder Gupta, Aug 26 2007
EXTENSIONS
a(11)-a(13) from Lars Blomberg, Feb 02 2013
a(14)-a(15) from Bert Dobbelaere, Mar 20 2019
STATUS
approved