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.

A265134 Numbers that are the sum of two distinct nonzero triangular numbers in exactly two ways.

Original entry on oeis.org

16, 31, 46, 51, 76, 94, 111, 121, 123, 126, 133, 141, 146, 156, 157, 172, 174, 186, 191, 196, 198, 216, 225, 226, 231, 237, 241, 246, 259, 268, 281, 286, 289, 291, 297, 301, 310, 315, 321, 326, 328, 336, 346, 354, 366, 367, 379, 384, 391, 396, 412, 416
Offset: 1

Views

Author

Arkadiusz Wesolowski, Dec 02 2015

Keywords

Crossrefs

Cf. A000217, A051533, A260647, A265140 (exactly one way), A262749 (more than one way), A265135 (more than two ways), A265136 (exactly three ways), A265137 (more than three ways), A265138 (exactly four ways).

Programs

  • Mathematica
    r = 416; lst = Table[0, {r}]; lim = Floor[Sqrt[8*r - 7]]; Do[num = (i^2 + i)/2 + (j^2 + j)/2; If[num <= r, lst[[num]]++], {i, lim}, {j, i - 1}]; Flatten@Position[lst, 2]
    Module[{nn=40,trnos},trnos=Accumulate[Range[nn]];Select[PositionIndex[ Sort[ Counts[Total/@Subsets[trnos,{2}]]]][2],#<=Last[trnos]&]] (* The program uses the PositionIndex and Counts functions from Mathematica version 10 *) (* Harvey P. Dale, Dec 25 2015 *)