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 A233401 #21 Nov 14 2024 10:23:38 %S A233401 1,4,8,21,37,40,56,112,113,204,280,445,481,560,688,709,1933,1945,3601, %T A233401 3805,3861,4156,4333,4365,7096,8408,8516,11064,12688,13609,13945, %U A233401 16501,17080,18901,21464,23125,27244,27364,28141,45228,45549,58321,60061,66245,70585,78688 %N A233401 Numbers k such that k^3 - b2 is a triangular number (A000217), where b2 is the largest square less than k^3. %C A233401 The cubes k^3 begin: 1, 64, 512, 9261, 50653, 64000, 175616, 1404928, ... %C A233401 The squares b2 begin: 0, 49, 484, 9216, 50625, 63504, 175561, 1404225, ... %C A233401 Their square roots are 0, 7, 22, 96, 225, 252, 419, 1185, 1201, 2913, 4685, 9387, ... %o A233401 (Python) %o A233401 from math import isqrt %o A233401 def isTriangular(a): %o A233401 a+=a %o A233401 sr = isqrt(a) %o A233401 return (a==sr*(sr+1)) %o A233401 for n in range(1,79999): %o A233401 n3 = n*n*n %o A233401 b = isqrt(n3) %o A233401 if b*b==n3: b-=1 %o A233401 if isTriangular(n3-b*b): print(n, end=', ') %o A233401 (PARI) f(k) = if (issquare(k), sqrtint(k-1)^2, sqrtint(k)^2); \\ adapted from A048760 %o A233401 isok(k) = my(b2 = sqrtint(k^3-1)^2); (k^3-b2) && ispolygonal(k^3-b2, 3); \\ _Michel Marcus_, Jan 26 2019 %Y A233401 Cf. A000217, A000290, A000578, A048760, A233400. %K A233401 nonn %O A233401 1,2 %A A233401 _Alex Ratushnyak_, Dec 09 2013