A163389 The position of first occurrence of n-th prime in A014085.
1, 4, 10, 16, 39, 45, 57, 82, 79, 117, 134, 192, 193, 218, 240, 256, 284, 343, 359, 415, 386, 467, 484, 501, 550, 627, 595, 739, 612, 724, 815, 785, 872, 868, 1007, 998, 1064, 1154, 1086, 1134, 1173, 1181, 1260, 1304, 1357, 1291, 1515, 1502, 1545, 1638, 1590
Offset: 1
Keywords
Examples
The first ten terms of A014085 are 2,2,2,3,2,4,3,4,3,5. prime(1) = 2 is the first element, prime(2) = 3 is the 4th element, prime(3)= 5 is the 10th element; so 1,4,10 are the first three elements of this sequence.
Crossrefs
Cf. A014085.
Programs
-
PARI
f(n) = primepi((n+1)^2)-primepi(n^2); \\ A014085 a(n) = my(k=1, p=prime(n)); while(f(k) != p, k++); k; \\ Michel Marcus, Aug 16 2022
Extensions
Extended by Ray Chandler, May 10 2010