A138798 Values of j corresponding to least possible k>0 with T(k)-T(j)=n, where T(i)>0 are the triangular numbers A000217.
1, 2, 3, 1, 5, 2, 7, 1, 9, 4, 2, 5, 1, 3, 15, 7, 2, 8, 1, 5, 3, 10, 6, 2, 4, 1, 27, 13, 3, 14, 31, 2, 6, 1, 10, 17, 7, 3, 5, 19, 2, 20, 1, 4, 9, 22, 14, 3, 7, 5, 2, 25, 1, 8, 4, 6, 12, 28, 3, 29, 13, 2, 63, 1, 14, 32, 4, 8, 6, 34, 3, 35, 16, 2, 5, 1, 17, 38, 13, 4, 18, 40, 6, 3, 19, 11, 2, 43, 1
Offset: 2
Keywords
Examples
a(30)=3 because 30 = T(30)-T(29)=T(11)-T(8)=T(9)-T(5)=T(8)-T(3) and 3 is the least index of the subtrahends.
Programs
-
Mathematica
T=#(#+1)/2&;Sort[{k,j}/.{ToRules[Reduce[{T[k]-T[j]\[Equal]#,0
Comments