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 A185128 #42 Dec 29 2024 12:46:46 %S A185128 21,171,703,990,3741,4186,6786,8778,30628,38781,77028,188191,203203, %T A185128 219453,318801,359128,416328,678030,763230,928203,1023165,1342341, %U A185128 1505980,1983036,2114596,2185095,2349028,2795430,3219453,3744216,4928230,6049981,7036876,7478778 %N A185128 a(n) = larger member of n-th pair of distinct, positive, triangular numbers whose sum and difference are also triangular numbers. %C A185128 Comments from _N. J. A. Sloane_, Dec 28 2024 (Start): %C A185128 Beiler's Table 81 (see link) lists eight sequences based on finding pairs of distinct, positive, triangular numbers whose sum and difference are also triangular numbers. The sequences are A185128 (the present sequence), A185129, A185223, A185233, A185243, A185253, A185257, and A185258. %C A185128 The order of the pairs is the same in each sequence, and is determined by the terms of the present sequence. %C A185128 It would be nice to have an analytic solution to the corresponding Diophantine equations. Beiler does not discuss this, but it is probably in Volume 2 of Dickson's "History of the Theory of Numbers". %C A185128 (End) %D A185128 Albert H. Beiler, Recreations in the Theory of Numbers, New York, Dover, (2nd ed.) 1966, p. 197, no. 8. %H A185128 N. J. A. Sloane, <a href="/A185128/a185128.jpg">Annotated scan of Beiler's Table 81</a>, based on page 197 of Beiler's "Recreations in the Theory of Numbers: The Queen of Mathematics Entertains", New York, Dover, First ed., 1964. %F A185128 a(n) = A000217(A185223(n)). - _R. J. Mathar_, Feb 11 2018. (This is a restatement of the definition.) %e A185128 a(2) = 171, since the pair of triangular numbers 171 = 18*(18+1)/2 and 105 = 14*(14+1)/2 produce the sum 276 = 23*(23+1)/2 and the difference 66 = 11*(11+1)/2 which are both triangular numbers. %t A185128 Module[{trs=Accumulate[Range[3900]]},Union[Select[Sort/@Subsets[trs,{2}],AllTrue[{Sqrt[ 8Total[#]+ 1],Sqrt[8Abs[#[[1]]-#[[2]]]+1]},OddQ]&]]][[All,2]]//Sort (* The program uses the AllTrue function from Mathematica version 10 *) (* _Harvey P. Dale_, Dec 02 2018 *) %o A185128 (PARI) lista(nn) = {v = vector(nn, n, n*(n+1)/2); for (n=2, nn, for (k=1, n-1, if (ispolygonal(v[n]+v[k], 3) && ispolygonal(v[n]-v[k], 3), print1(v[n], ", "));););} \\ _Michel Marcus_, Jan 08 2015 %Y A185128 Cf. A000217, A185129, A185223, A185233, A185243, A185253, A185257, A185258. %K A185128 nonn %O A185128 1,1 %A A185128 _Martin Renner_, Jan 20 2012 %E A185128 Edited by _N. J. A. Sloane_, Dec 28 2024