login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A105173
Numbers k such that either k*(k+1)/4 + 1 or k*(k+1)/4 - 1 or both are primes.
1
3, 7, 8, 15, 16, 23, 24, 32, 39, 40, 47, 48, 55, 56, 63, 64, 71, 79, 80, 87, 95, 103, 104, 111, 112, 119, 120, 128, 135, 136, 143, 151, 152, 159, 167, 175, 176, 183, 199, 208, 216, 223, 224, 231, 232, 239, 240, 247, 248, 255, 256, 263, 264, 271, 279, 287, 288
OFFSET
1,1
COMMENTS
The primes are (sum of numbers from 1 to k)/2 + or - 1.
LINKS
EXAMPLE
3*4/4 = 3, 3-1 = 2 is prime so a(1) = 3.
7*8/4 = 14, 14-1 = 13 is prime so a(2) = 7.
8*9/4 = 18, 18-1 = 17 is prime, 18+1 = 19 is prime, so a(3) = 8.
MATHEMATICA
Select[Range[300], Or @@ PrimeQ[#*(#+1)/4 + {-1, 1}] &] (* Amiram Eldar, Jul 18 2021 *)
CROSSREFS
Subsequence of A014601.
Sequence in context: A131559 A366783 A051211 * A309197 A076683 A045542
KEYWORD
nonn
AUTHOR
Pierre CAMI, Apr 11 2005
EXTENSIONS
More terms from Amiram Eldar, Jul 18 2021
STATUS
approved