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.

A084370 Convolution of odd primes with themselves.

This page as a plain text file.
%I A084370 #15 Sep 30 2021 20:03:13
%S A084370 9,30,67,136,237,386,587,852,1213,1658,2227,2932,3765,4766,5939,7324,
%T A084370 8917,10746,12851,15200,17845,20794,24083,27748,31785,36250,41107,
%U A084370 46376,52113,58350,65111,72444,80353,88858,98003,107744,118201,129410,141355,154080
%N A084370 Convolution of odd primes with themselves.
%H A084370 Harvey P. Dale, <a href="/A084370/b084370.txt">Table of n, a(n) for n = 1..1000</a>
%F A084370 a(n) = Sum_{k=1..n} A065091(k) * A065091(n-k+1).
%e A084370 a(4) = 11*3 + 7*5 + 5*7 + 3*11 = 136.
%t A084370 Table[With[{c=Prime[Range[2,n]]},ListConvolve[c,c]],{n,2,40}]//Flatten (* _Harvey P. Dale_, Apr 25 2016 *)
%o A084370 (PARI) conv(n)=local(v,s); v=primes(n+1); s=0; for(i=2, length(v), s+=v[i]*v[length(v)-i+2]); s
%o A084370 for(n=1,40,print1(conv(n)","))
%o A084370 (Python)
%o A084370 from numpy import convolve
%o A084370 from sympy import prime, primerange
%o A084370 def aupton(terms):
%o A084370     p = list(primerange(3, prime(terms+1)+1))
%o A084370     return list(convolve(p, p))[:terms]
%o A084370 print(aupton(40)) # _Michael S. Branicky_, Sep 30 2021
%Y A084370 Cf. A065091, A014342, A209403.
%K A084370 nonn
%O A084370 1,1
%A A084370 _Jon Perry_, Jun 23 2003