A014692 a(n) = prime(n) - (n-1).
2, 2, 3, 4, 7, 8, 11, 12, 15, 20, 21, 26, 29, 30, 33, 38, 43, 44, 49, 52, 53, 58, 61, 66, 73, 76, 77, 80, 81, 84, 97, 100, 105, 106, 115, 116, 121, 126, 129, 134, 139, 140, 149, 150, 153, 154, 165, 176, 179, 180, 183, 188, 189, 198, 203, 208, 213, 214, 219, 222, 223
Offset: 1
Links
- David A. Corneth, Table of n, a(n) for n = 1..10000
Programs
-
Maple
A014692:=n->ithprime(n)-(n-1): seq(A014692(n), n=1..100); # Wesley Ivan Hurt, Oct 15 2017
-
Mathematica
Table[Prime[n] - n + 1, {n, 61}] (* Geoffrey Critzer, May 02 2013 *)
-
PARI
first(n) = {my(t, res = vector(n)); forprime(p=2, , t++; res[t] = p - t + 1; if(t>=n, return(res)))} \\ David A. Corneth, Oct 04 2017
-
PARI
a(n) = prime(n)-n+1; \\ Altug Alkan, Oct 05 2017
-
Python
from sympy import prime def A014692(n): return prime(n)-n+1 # Chai Wah Wu, Oct 11 2024
Extensions
More terms from Andrew J. Gacek (andrew(AT)dgi.net)
Comments