|
|
A225842
|
|
Least k such that some digit occurs n times (or more) in the decimal representation of n^k.
|
|
2
|
|
|
0, 0, 16, 11, 23, 25, 28, 33, 31, 45, 10, 46, 61, 60, 66, 62, 66, 73, 76, 76, 20, 76, 91, 116, 109, 105, 122, 125, 105, 121, 29, 130, 115, 132, 132, 164, 153, 159, 162, 152, 39, 178, 182, 163, 181, 174, 186, 195, 180, 204, 45, 179, 221, 217, 224, 225, 245, 215, 208, 252, 55, 215
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,3
|
|
COMMENTS
|
a(10^j) = ceiling((10^j) / j) for any j > 0.
a(i*10^j) <= ceiling((i*10^j) / j) for any i > 0 and j > 0.
|
|
LINKS
|
|
|
EXAMPLE
|
3^11 = 177147 is the first power of 3 with some digit occurring 3 times in its decimal representation. Hence a(3)=11.
|
|
MATHEMATICA
|
a[n_] := If[n < 2, 0, Block[{k = 1}, While[Max[DigitCount[n^k]] < n, k++]; k]]; Array[a, 62, 0] (* Giovanni Resta, May 17 2013 *)
|
|
PROG
|
(PARI) mddo(n)=my(c=vector(10), m=0, d); while(n>0, d=n%10; n=n\10; c[d+1]=1+c[d+1]; m=max(c[d+1], m)); return(m)
a(n)=my(k=0, p=1); while(mddo(p)<n, k=k+1; p=p*n); return(k)
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,base
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|