login
A360533
a(n) = index of the diagonal of the natural number array, A000027, that includes prime(n). See Comments.
0
1, -1, 0, 3, 4, 0, 3, -1, 4, 7, 3, 8, 0, -4, 7, -5, 4, 0, 11, 3, -1, 12, 4, -8, 3, -5, -9, 12, 8, 0, 3, -5, 16, 12, -8, -12, 11, -1, -9, 16, 4, 0, 19, 15, 7, 3, 20, -4, -12, -16, 19, 7, 3, -17, 16, 4, -8, -12, 23, 15, 11, -9, 12, 4, 0, -8, 15, 3, -17, -21
OFFSET
1,4
COMMENTS
The natural number array, A000027 = (w(n,k)) = (n + (n + k - 2) (n + k - 1)/2), has corner:
1 2 4 7 ...
3 5 8 12 ...
6 9 13 18 ...
10 14 19 25 ...
The indexing of diagonals is given in A191360. Conjecture: Every odd-indexed diagonal contains infinitely many primes.
EXAMPLE
Prime(1) = 2 is in the diagonal (w(n,n+1)), so a(1) = 1.
Prime(13) = 43 is in the diagonal (w(n,n-4)), so a(7) = -4.
MATHEMATICA
Map[1 + #[[1]] - 2 #[[2]] &[{#[[2]], #[[1]] - ((#[[2]] - 1) + (#[[2]] - 1)^2)/
2} &[{#, Floor[(1 + Sqrt[8 # - 7])/2]}] &[Prime[#]]] &, Range[1000]]
(* Peter J. C. Moses, Feb 07 2023 *)
CROSSREFS
KEYWORD
easy,sign
AUTHOR
Clark Kimberling, Feb 10 2023
STATUS
approved