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 A045980 #36 Aug 04 2025 10:01:45 %S A045980 0,1,2,7,8,9,16,19,26,27,28,35,37,54,56,61,63,64,65,72,91,98,117,124, %T A045980 125,126,127,128,133,152,169,189,208,215,216,217,218,224,243,250,271, %U A045980 279,280,296,316,331,335,341,342,343,344,351,370,386,387,397,407,432 %N A045980 Numbers of the form x^3 + y^3 or x^3 - y^3. %C A045980 Sums of two integer cubes. - _Charles R Greathouse IV_, Mar 30 2022 %D A045980 B. C. Berndt, Ramanujan's Notebooks Part IV, Springer-Verlag, see p. 86. %H A045980 T. D. Noe, <a href="/A045980/b045980.txt">Table of n, a(n) for n = 1..1000</a> %H A045980 Chris Bispels, Matthew Cohen, Joshua Harrington, Joshua Lowrance, Kaelyn Pontes, Leif Schaumann, and Tony W. H. Wong, <a href="https://arxiv.org/abs/2507.16135">A further investigation on covering systems with odd moduli</a>, arXiv:2507.16135 [math.NT], 2025. See p. 3. %H A045980 Kevin A. Broughan, <a href="http://www.cs.uwaterloo.ca/journals/JIS/VOL6/Broughan/broughan25.html">Characterizing the sum of two cubes</a>, J. Integer Seqs., Vol. 6, 2003. %H A045980 M. Kim, <a href="https://arxiv.org/abs/math/0210329">Diophantine equations in two variables</a>, arXiv:math/0210329 [math.NT], 2002. %H A045980 <a href="/index/Su#ssq">Index entries for sequences related to sums of cubes</a> %e A045980 7 = (2)^3 + (-1)^3. %t A045980 Union[Select[Sort[Flatten[Table[{j^3-i^3, j^3+i^3}, {i, 0, 20}, {j, i, 20}]]], #<20^3-19^3&]] %t A045980 With[{nn=20},Take[Union[Select[Flatten[{Total[#],#[[1]]-#[[2]]}&/@(Tuples[ Range[0,nn],2]^3)],#>-1&]],3*nn]] (* _Harvey P. Dale_, Jun 22 2014 *) %o A045980 (PARI) is(n)=fordiv(n,d, my(L=(d^2-n/d)/3); if(denominator(L)==1 && issquare(d^2-4*L), return(1))); 0 \\ _Charles R Greathouse IV_, Jun 12 2012 %o A045980 (PARI) list(lim)={ %o A045980 my(v=List(),x3,t); %o A045980 for(x=0,sqrtnint(lim\=1,3), %o A045980 x3=x^3; %o A045980 for(y=0,min(sqrtnint(lim-x3,3),x), %o A045980 listput(v,x3+y^3) %o A045980 ) %o A045980 ); %o A045980 for(x=2,t=sqrtint(lim\3), %o A045980 x3=x^3; %o A045980 for(y=sqrtnint(max(0,x3-lim-1),3)+1,x-1, %o A045980 listput(v,x3-y^3) %o A045980 ) %o A045980 ); %o A045980 t=(t+1)^3-t^3; %o A045980 if(t<=lim,listput(v,t)); %o A045980 Set(v); %o A045980 } \\ _Charles R Greathouse IV_, Jun 12 2012, updated Jan 13 2022 %o A045980 (PARI) is(n)=#thue(thueinit(z^3+1),n) \\ _Ralf Stephan_, Oct 18 2013 %o A045980 (Haskell) %o A045980 a045980 n = a045980_list !! (n-1) %o A045980 a045980_list = 0 : filter f [1..] where %o A045980 f x = g $ takeWhile ((<= 4 * x) . (^ 3)) $ a027750_row x where %o A045980 g [] = False %o A045980 g (d:ds) = r == 0 && a010052 (d ^ 2 - 4 * y) == 1 || g ds %o A045980 where (y, r) = divMod (d ^ 2 - div x d) 3 %o A045980 -- _Reinhard Zumkeller_, Dec 20 2013 %Y A045980 A004999 and A003325 are subsequences. %Y A045980 Cf. A222304, A222305, A222306, A027750, A010052. %K A045980 nonn,easy,nice %O A045980 1,3 %A A045980 _N. J. A. Sloane_