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 A004831 #35 Jul 12 2024 17:06:55 %S A004831 0,1,2,16,17,32,81,82,97,162,256,257,272,337,512,625,626,641,706,881, %T A004831 1250,1296,1297,1312,1377,1552,1921,2401,2402,2417,2482,2592,2657, %U A004831 3026,3697,4096,4097,4112,4177,4352,4721,4802,5392,6497,6561,6562,6577,6642 %N A004831 Numbers that are the sum of at most 2 nonzero 4th powers. %C A004831 Apart from 0, 1, 2, there are no three consecutive terms up to 10^16. The first two consecutive terms not of the form n^4, n^4+1 are 3502321 = 25^4 + 42^4, 3502322 = 17^4 + 43^4. - _Charles R Greathouse IV_, Oct 17 2017 %H A004831 T. D. Noe, <a href="/A004831/b004831.txt">Table of n, a(n) for n = 1..1000</a> %F A004831 Call f(x) the number of terms if this sequence up to x. Then x^(7/16) << f(x) << x^(1/2); in other words, n^2 << a(n) << n^(16/7). The upper bound becomes O(n^2) if A230562 is finite. - _Charles R Greathouse IV_, Jul 12 2024 %t A004831 Reap[For[n = 0, n < 10000, n++, If[MatchQ[ PowersRepresentations[n, 2, 4], {{_, _},___}], Print[n]; Sow[n]]]][[2, 1]] (* _Jean-François Alcover_, Oct 30 2017 *) %o A004831 (Haskell) %o A004831 a004831 n = a004831_list !! (n-1) %o A004831 a004831_list = [x ^ 4 + y ^ 4 | x <- [0..], y <- [0..x]] %o A004831 -- _Reinhard Zumkeller_, Jul 15 2013 %o A004831 (PARI) is(n)=#thue(thueinit(z^4+1),n) \\ _Ralf Stephan_, Oct 18 2013 %o A004831 (PARI) list(lim)=my(v=List(),t); for(m=0,sqrtnint(lim\=1,4), for(n=0, min(sqrtnint(lim-m^4,4),m), listput(v,n^4+m^4))); Set(v) \\ _Charles R Greathouse IV_, Sep 28 2015 %Y A004831 Subsequences include A003336, A000583 and A002645. %K A004831 nonn %O A004831 1,3 %A A004831 _N. J. A. Sloane_