Let j be the smallest integer for which 1+(1+1*n)+(1+2*n)+...+(1+j*n)=k^2=s. Then a(n)=1+j*n; if no such j exists, then a(n)=0.

A100253

Let j be the smallest integer for which 1+(1+1*n)+(1+2*n)+...+(1+j*n)=k^2=s. Then a(n)=1+j*n; if no such j exists, then a(n)=0.

Terms

    a(0) =8a(1) =3a(2) =241a(3) =97a(4) =26a(5) =49a(6) =8a(7) =0a(8) =55a(9) =31a(10) =23a(11) =97a(12) =274a(13) =15a(14) =721a(15) =49a(16) =120a(17) =0a(18) =305a(19) =161a(20) =1681a(21) =89a(22) =24a(23) =577a(24) =1126a(25) =53a(26) =244a(27) =3361a(28) =146a(29) =241

External references