%I #36 Apr 19 2018 09:35:18
%S 1,55,1891,64261,2183005,74157931,2519186671,85578188905,
%T 2907139236121,98757155839231,3354836159297755,113965672260284461,
%U 3871478020690373941,131516287031212429555,4467682281040532230951,151769681268346883422801
%N Triangular numbers of the form k^2 + k - 1.
%C Triangular numbers belonging to A028387. - _Bruno Berselli_, Apr 18 2018
%C Since this sequence lists triangular numbers t such that 4*t + 5 = u^2 and 8*t + 1 = v^2 by definition of triangular numbers, 2*u^2 - 9 = 2*(4*t + 5) - 9 = 8*t + 1 = v^2, that is, sqrt(4*a(n) + 5) is in A075841. - _Altug Alkan_, Apr 18 2018
%H <a href="/index/Rec#order_03">Index entries for linear recurrences with constant coefficients</a>, signature (35,-35,1).
%F From _Giovanni Resta_, Mar 24 2013: (Start)
%F G.f.: -x*(1 + 20*x + x^2) / ( (x - 1)*(x^2 - 34*x + 1) ).
%F a(n) = floor(9 * (17 + sqrt(288))^n * (3 - sqrt(8))/32). (End)
%F a(n) = (A075841(n)^2 - 5)/4. - _Altug Alkan_, Apr 18 2018
%e Triangular(10) = 55 = 7^2 + 7 - 1, so 55 is in the sequence.
%t a[1]=1; a[2]=55; a[3]=1891; a[n_] := a[n] = 35*a[n-1] - 35*a[n-2] + a[n-3]; Array[a,20] (* _Giovanni Resta_, Mar 24 2013 *)
%t Table[Floor@(9 (17 + Sqrt@ 288)^n*(3 - Sqrt@ 8)/32), {n, 0, 16}] (* or *)
%t CoefficientList[Series[-x (1 + 20 x + x^2)/((x - 1) (x^2 - 34 x + 1)), {x, 0, 16}], x] (* _Michael De Vlieger_, Oct 08 2016 *)
%o (C)
%o #include <stdio.h>
%o typedef unsigned long long U64;
%o U64 rootPronic(U64 a) {
%o U64 sr = 1L<<32, s, b;
%o while (a < sr*(sr-1)) sr>>=1;
%o for (b = sr>>1; b; b>>=1) {
%o s = sr+b;
%o if (a >= s*(s-1)) sr = s;
%o }
%o return sr;
%o }
%o int main() {
%o U64 a, i, t;
%o for (i=0; i < 1L<<32; ++i) {
%o a = i*(i+1)/2 + 1;
%o t = rootPronic(a);
%o if (a == t*(t-1)) printf("%llu %llu %llu\n", i, t, a-1);
%o }
%o return 0;
%o }
%o (PARI) Vec(x*(1+20*x+x^2)/(1-35*x+35*x^2-x^3)+O(x^66)) \\ _Joerg Arndt_, Mar 25 2013
%Y Cf. A000217, A028387, A069017, A075841.
%K nonn,easy
%O 1,2
%A _Alex Ratushnyak_, Mar 23 2013