login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A353136 Primes whose gaps to both neighbor primes are triangular numbers. 5
53, 157, 173, 251, 257, 263, 337, 373, 547, 557, 563, 577, 587, 593, 607, 653, 733, 947, 977, 1039, 1103, 1123, 1181, 1187, 1223, 1367, 1627, 1747, 1753, 1907, 2017, 2063, 2287, 2417, 2677, 2719, 2897, 2903, 2963, 3307, 3313, 3517, 3547, 3637, 3733, 4013, 4211 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
LINKS
EXAMPLE
Prime 251 is a term, the gap to the previous prime 241 is 10 and the gap to the next prime 257 is 6 and both gaps are triangular numbers.
MAPLE
t:= proc(n) option remember; issqr(8*n+1) end:
q:= n-> isprime(n) and andmap(t, [n-prevprime(n), nextprime(n)-n]):
select(q, [$3..5000])[];
MATHEMATICA
t[n_] := IntegerQ@Sqrt[8n+1];
q[n_] := PrimeQ[n] && t[n-NextPrime[n, -1]] && t[NextPrime[n]-n];
Select[Range[3, 5000], q] (* Jean-François Alcover, May 14 2022, after Alois P. Heinz *)
CROSSREFS
Sequence in context: A044766 A342450 A160058 * A053070 A140655 A142508
KEYWORD
nonn
AUTHOR
Alois P. Heinz, Apr 25 2022
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 16 14:17 EDT 2024. Contains 371740 sequences. (Running on oeis4.)