login
A163291
Number of digits of n-th prime written in base 4.
2
1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5
OFFSET
1,3
LINKS
FORMULA
a(n) = log_4 n + log_4 log n + O(1). - Charles R Greathouse IV, Mar 25 2010
EXAMPLE
6th prime = 13 = 31_4, so a(6) = 2;
7th prime = 17 = 101_4, so a(7) = 3;
54th prime = 251 = 3323_4, so a(54) = 4;
55th prime = 257 = 10001_4, so a(55) = 5.
MATHEMATICA
IntegerLength[#, 4] & /@ Prime[Range[100]] (* G. C. Greubel, Dec 17 2016 *)
PROG
(PARI) a(n) = #digits(prime(n), 4); \\ Michel Marcus, Dec 18 2016
CROSSREFS
Sequence in context: A092139 A084558 A320065 * A156875 A066339 A345379
KEYWORD
nonn,base
AUTHOR
STATUS
approved