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.

A026495 a(n) = least positive integer > a(n-1) and not a(i)^2 + a(j)^2 + a(k)^2 for 1<=i

This page as a plain text file.
%I A026495 #20 Jul 23 2025 09:12:27
%S A026495 1,2,3,4,5,6,7,8,9,10,11,12,13,15,16,17,18,19,20,22,23,24,25,27,28,31,
%T A026495 32,33,34,36,37,39,40,43,44,47,48,51,52,55,57,58,60,63,64,67,68,71,72,
%U A026495 73,76,79,80,82,85,87,88,92,95,96,97,99,100,102,103,108,111,112,119,123
%N A026495 a(n) = least positive integer > a(n-1) and not a(i)^2 + a(j)^2 + a(k)^2 for 1<=i<j<k<=n.
%C A026495 Starts to differ from A004440 at a(102). - _Robert Israel_, Jul 22 2025
%H A026495 Klaus Brockhaus, <a href="/A026495/b026495.txt">Table of n, a(n) for n=1..10000</a>
%o A026495 (PARI) {m=70; z=300; a=[]; a2=Set([]); a3=Set([]); s=1; for(n=1, m, p=s; while(setsearch(a3, p, 0), p++); if(p>z, break); new=vector(#a2); for(k=1, #a2, q=eval(a2[k])+p^2; if(q<=z, new[k]=q)); a3=setunion(a3, Set(new)); new=vector(#a); for(k=1, #a, q=a[k]^2+p^2; if(q<=z, new[k]=q)); a2=setunion(a2, setminus(Set(new), Set(0))); a=concat(a, p); s=p+1; print1(p, ","))} /* _Klaus Brockhaus_, Jul 03 2008 */
%Y A026495 Cf. A004440. [From _R. J. Mathar_, Oct 23 2008]
%K A026495 nonn
%O A026495 1,2
%A A026495 _Clark Kimberling_
%E A026495 Extended by _Klaus Brockhaus_, Jul 03 2008