login
A167807
Square pyramidal numbers which are sums of three consecutive primes.
1
1015, 25585, 1623245, 2127685, 7838831, 8865649, 19849115, 52051769, 73998155, 88409285, 91753025, 161553785, 216862421, 289872105, 347016319, 382029011, 466430159, 835713879, 1077314939, 1223359835, 1509659555, 1584781241
OFFSET
1,1
COMMENTS
Intersection of A000330 (Square pyramidal numbers) and A034961 (Sums of three consecutive primes).
EXAMPLE
1015=A034961(67)=A000330(14)
25585=A034961(1062)=A000330(42).
PROG
(Python)
from __future__ import division
from sympy import nextprime, prevprime
A167807_list = []
for i in range(3, 10**6):
n = i*(i+1)*(2*i+1)//6
p2 = prevprime(n//3)
p1, p3 = prevprime(p2), nextprime(p2)
q = p1+p2+p3
while q <= n:
if q == n:
A167807_list.append(n)
p1, p2, p3 = p2, p3, nextprime(p3)
q = p1+p2+p3 # Chai Wah Wu, Dec 31 2015
CROSSREFS
Sequence in context: A225717 A117807 A223089 * A118879 A023083 A221808
KEYWORD
nonn
AUTHOR
Zak Seidov, Nov 12 2009
EXTENSIONS
a(6)-a(22) from Donovan Johnson, Nov 15 2009
STATUS
approved