cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A127334 Numbers that are the sum of 7 consecutive primes.

This page as a plain text file.
%I A127334 #46 May 14 2023 13:13:02
%S A127334 58,75,95,119,143,169,197,223,251,281,311,341,371,401,431,463,493,523,
%T A127334 559,593,625,659,689,719,757,791,827,863,905,947,991,1027,1063,1099,
%U A127334 1139,1171,1211,1247,1281,1313,1351,1395,1441,1479,1519,1561,1603,1643
%N A127334 Numbers that are the sum of 7 consecutive primes.
%C A127334 a(n) = absolute value of coefficient of x^6 of the polynomial Product_{j=0..6} (x - prime(n+j)) of degree 7; the roots of this polynomial are prime(n), ..., prime(n+6).
%H A127334 Muniru A Asiru, <a href="/A127334/b127334.txt">Table of n, a(n) for n = 1..1000</a>
%p A127334 seq(add(ithprime(i),i=n..6+n),n=1..50); # _Muniru A Asiru_, Apr 16 2018
%t A127334 a = {}; Do[AppendTo[a, Sum[Prime[x + n], {n, 0, 6}]], {x, 1, 50}]; a
%t A127334 Total/@Partition[Prime[Range[60]],7,1] (* _Harvey P. Dale_, May 14 2023 *)
%o A127334 (PARI) {m=48;k=7;for(n=0,m-1,print1(a=sum(j=1,k,prime(n+j)),","))} \\ _Klaus Brockhaus_, Jan 13 2007
%o A127334 (PARI) {m=48;k=7;for(n=1,m,print1(abs(polcoeff(prod(j=0,k-1,(x-prime(n+j))),k-1)),","))} \\ _Klaus Brockhaus_, Jan 13 2007
%o A127334 (Sage)
%o A127334 BB = primes_first_n(62)
%o A127334 L = []
%o A127334 for i in range(55):
%o A127334     L.append(sum(BB[i+j] for j in range(7)))
%o A127334 L
%o A127334 # _Zerinvary Lajos_, May 14 2007
%o A127334 (Magma) [&+[ NthPrime(n+k): k in [0..6] ]: n in [1..70] ]; // _Vincenzo Librandi_, Apr 03 2011
%o A127334 (Python)
%o A127334 from sympy import prime
%o A127334 def a(x): return sum(prime(x + n) for n in range(7))
%o A127334 print([a(i) for i in range(1, 50)]) # _Indranil Ghosh_, Mar 18 2017
%o A127334 (GAP) P:=Filtered([1..1000],IsPrime);; List([0..50],n->Sum([1+n..7+n],i->P[i])); # _Muniru A Asiru_, Apr 16 2018
%Y A127334 Cf. A001043, A011974, A034961, A034963, A034964, A082246, A127333, A127335, A127336, A127337, A127338, A127339.
%K A127334 nonn
%O A127334 1,1
%A A127334 _Artur Jasinski_, Jan 11 2007
%E A127334 Edited by _Klaus Brockhaus_, Jan 13 2007