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.
%I A131591 #16 Jul 06 2024 05:18:41 %S A131591 4,38,1556,86606,4083404,171658094,6716224724,247782290006, %T A131591 8763080657420,299863491723614,9990667099305740,325847250824377382, %U A131591 10445562407382412028,330039152364735149222,10301457052184951857604,318211810358946705058382 %N A131591 Sum of the squares of the first 3^n primes. %H A131591 Amiram Eldar, <a href="/A131591/b131591.txt">Table of n, a(n) for n = 0..21</a> %F A131591 a(n) = A024450(3^n). - _Amiram Eldar_, Jul 06 2024 %e A131591 The sum of the squares of the first 3^1 primes is 4 + 9 + 25 = 38, the second term of this sequence. %t A131591 nn=15;With[{prsq=Prime[Range[3^nn]]^2},Table[Total[Take[prsq,3^n]],{n,0,nn}]] (* _Harvey P. Dale_, Mar 08 2014 *) %o A131591 (PARI) sumprimesq(n,b) = { local(x,y,s,a); for(y=0,n, s=0; for(x=1,b^y, s+=prime(x)^2; ); print1(s","); ) } %o A131591 (PARI) lista(pmax) = {my(sm = 0, c = 0, pow = 1); forprime(p = 1, pmax, sm += p^2; c++; if(c == pow, print1(sm, ", "); pow *= 3));} \\ _Amiram Eldar_, Jul 06 2024 %Y A131591 Cf. A001248, A024450, A131590. %K A131591 nonn %O A131591 0,1 %A A131591 _Cino Hilliard_, Aug 30 2007 %E A131591 More terms from _Harvey P. Dale_, Mar 08 2014