OFFSET
0,2
EXAMPLE
Least k such that there are 2 triangular numbers between triangular(k) and k^2 is k=7: triangular(8)=36 and triangular(9)=45 are between triangular(7)=28 and 7^2=49. Thus a(2)=7.
Least k such that there are 3 triangular numbers between triangular(k) and k^2 is k=9: 55, 66, 78 are the triangular numbers between triangular(9)=45 and 9^2=81. Thus a(3)=9.
MATHEMATICA
nn = 1000; tri = Table[n*(n+1)/2, {n, 0, Sqrt[2]*nn}]; sq = Range[nn]^2; t = Table[Length[Select[tri, tri[[n]] < # < sq[[n]] &]], {n, nn}]; Join[{0}, Table[Position[t, n, 1, 1][[1, 1]], {n, Max[t]}]] (* T. D. Noe, Dec 13 2013 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Alex Ratushnyak, Dec 11 2013
STATUS
approved