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 A214514 #10 Dec 17 2021 11:07:14 %S A214514 12,17,22,27,33,38,43,54,57,59,62,67,75,78,83,99,102,107,123,129,134, %T A214514 139,147,150,155,171,174,177,179,182,187,195,198,203,219,222,227,243, %U A214514 246,251,267,291,294,297,299,302,307,315,318,323,339,342,347,363,369 %N A214514 Numbers of the form p^2 + q^2 + r^2, where p, q, and r are primes. %H A214514 T. D. Noe, <a href="/A214514/b214514.txt">Table of n, a(n) for n = 1..10000</a> %t A214514 nn = 10^3; ps = Prime[Range[PrimePi[Sqrt[nn]]]]; t = Flatten[Table[ps[[i]]^2 + ps[[j]]^2 + ps[[k]]^2, {i, Length[ps]}, {j, i, Length[ps]}, {k, j, Length[ps]}]]; t = Select[t, # <= nn &]; Union[t] %o A214514 (Python) %o A214514 from sympy import primerange as primes %o A214514 from itertools import takewhile, combinations_with_replacement as mc %o A214514 def aupto(N): %o A214514 psqs = list(takewhile(lambda x: x<=N, (p**2 for p in primes(1, N+1)))) %o A214514 sum3 = set(sum(c) for c in mc(psqs, 3) if sum(c) <= N) %o A214514 return sorted(sum3) %o A214514 print(aupto(369)) # _Michael S. Branicky_, Dec 17 2021 %Y A214514 Cf. A045636 (two primes), A214515 (four primes). %K A214514 nonn %O A214514 1,1 %A A214514 _T. D. Noe_, Jul 29 2012