login
A163292
a(n) = n-th prime minus (number of digits of n-th prime written in base 4).
1
1, 2, 3, 5, 9, 11, 14, 16, 20, 26, 28, 34, 38, 40, 44, 50, 56, 58, 63, 67, 69, 75, 79, 85, 93, 97, 99, 103, 105, 109, 123, 127, 133, 135, 145, 147, 153, 159, 163, 169, 175, 177, 187, 189, 193, 195, 207, 219, 223, 225, 229, 235, 237, 247, 252, 258, 264, 266, 272, 276
OFFSET
1,2
LINKS
FORMULA
a(n) = A000040(n) - A163291(n).
EXAMPLE
a(6) = 11 (= 13 - 2);
a(7) = 14 (= 17 - 3); ...
a(54) = 247 (= 251 - 4);
a(55) = 252 (= 257 - 5).
MAPLE
A000040 := proc(n) ithprime(n) ; end: A163291 := proc(n) max(1, ilog[4](A000040(n))+1) ; end: A163292 := proc(n) A000040(n)-A163291(n) ; end: seq(A163292(n), n=1..100) ; #R. J. Mathar, Jul 26 2009
MATHEMATICA
#-IntegerLength[#, 4]&/@Prime[Range[60]] (* Harvey P. Dale, Dec 14 2015 *)
PROG
(PARI) a(n) = my(p=prime(n)); p - #digits(p, 4); \\ Michel Marcus, Mar 03 2019
CROSSREFS
Cf. A000040, A004678, A163291, A163293 (analog in base 2).
Sequence in context: A161514 A215779 A140329 * A137518 A137509 A350916
KEYWORD
nonn,base
AUTHOR
STATUS
approved