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.

A214513 Least number having n orderless representations as p^2 + q^2 + r^2 + s^2, where p, q, r, and s are primes.

This page as a plain text file.
%I A214513 #6 Jul 30 2012 06:48:39
%S A214513 16,148,196,436,388,628,868,988,1228,1468,1708,2212,2068,2860,2620,
%T A214513 2380,3220,3388,3700,4108,3940,4180,5260,4228,5068,4900,5500,6220,
%U A214513 6340,7780,5908,5740,6580,7540,8260,7420,8860,9340,11260,10708,9940,9100,10180,12820
%N A214513 Least number having n orderless representations as p^2 + q^2 + r^2 + s^2, where p, q, r, and s are primes.
%H A214513 Donovan Johnson, <a href="/A214513/b214513.txt">Table of n, a(n) for n = 1..1000</a>
%t A214513 nn = 10^5; ps = Prime[Range[PrimePi[Sqrt[nn]]]]; t = Flatten[Table[ps[[i]]^2 + ps[[j]]^2 + ps[[k]]^2 + ps[[l]]^2, {i, Length[ps]}, {j, i, Length[ps]}, {k, j, Length[ps]}, {l, k, Length[ps]}]]; t = Select[t, # <= nn &]; t2 = Sort[Tally[t]]; u = Union[Transpose[t2][[2]]]; d = Complement[Range[u[[-1]]], u]; If[d == {}, nLim = u[[-1]], nLim = d[[1]]-1]; t3 = Table[Select[t2, #[[2]] == n &, 1][[1]], {n, nLim}]; Transpose[t3][[1]]
%Y A214513 Cf. A025416, A025417, A214511, A214512.
%K A214513 nonn
%O A214513 1,1
%A A214513 _T. D. Noe_, Jul 29 2012