%I #46 Feb 28 2024 16:23:12
%S 1,1,7,13,25,43,73,121,199,325,529,859,1393,2257,3655,5917,9577,15499,
%T 25081,40585,65671,106261,171937,278203,450145,728353,1178503,1906861,
%U 3085369,4992235,8077609,13069849,21147463,34217317,55364785,89582107
%N a(n) = a(n-1) + a(n-2) + 5 where a(0) = a(1) = 1.
%C a(n+1)/a(n) converges to the golden ratio. - _Stefan Steinerberger_, Nov 19 2005
%C This is the sequence A(1,1;1,1;5) of the family of sequences [a,b:c,d:k] considered by _Gary Detlefs_, and treated as A(a,b;c,d;k) in the W. Lang link given below. - _Wolfdieter Lang_, Oct 17 2010
%H Reinhard Zumkeller, <a href="/A111721/b111721.txt">Table of n, a(n) for n = 0..1000</a>
%H Taras Goy and Mark Shattuck, <a href="https://doi.org/10.2478/amsil-2023-0027">Determinants of Toeplitz-Hessenberg Matrices with Generalized Leonardo Number Entries</a>, Ann. Math. Silesianae (2023). See p. 13.
%H Wolfdieter Lang, <a href="/A111721/a111721.pdf">Notes on certain inhomogeneous three term recurrences</a>.
%H <a href="/index/Rec#order_03">Index entries for linear recurrences with constant coefficients</a>, signature (2,0,-1).
%F For n > 1: a(n) = a(n-1) + 6*F(n-1). (a(n)-1)/6 = A000071(n+1) = F(n+1) - 1. Hence a(n) = 6*F(n+1) - 5. - _Jonathan Vos Post_, Nov 19 2005
%F G.f.: (5*x^2-x+1)/(x^3-2*x+1). - _Stefan Steinerberger_, Nov 19 2005
%e a(2) = a(0) + a(1) + 5 = 1 + 1 + 5 = 7.
%t Join[{a=1,b=1},Table[c=a+b+5;a=b;b=c,{n,50}]] (* _Vladimir Joseph Stephan Orlovsky_, Apr 13 2011 *)
%t Nest[Append[#, #[[-1]] + #[[-2]] + 5] &, {1, 1}, 34] (* or *)
%t CoefficientList[Series[(5 x^2 - x + 1)/(x^3 - 2 x + 1), {x, 0, 35}], x] (* _Michael De Vlieger_, Dec 17 2017 *)
%o (MuPAD) a := 1; b := 1; for n from 1 to 50 do c := a+b+5; print(c); a := b; b := c; end_for; // _Stefan Steinerberger_
%o (Sage) from sage.combinat.sloane_functions import recur_gen2b
%o it =recur_gen2b(1,1,1,1, lambda n: 5)
%o [next(it) for i in range(38)] # _Zerinvary Lajos_, Jul 16 2008
%o (Haskell)
%o a111721 n = a111721_list !! n
%o a111721_list = 1 : 1 :
%o map (+ 5) (zipWith (+) a111721_list (tail a111721_list))
%o -- _Reinhard Zumkeller_, Nov 05 2011
%o (PARI) x='x+O('x^99); Vec((5*x^2-x+1)/(x^3-2*x+1)) \\ _Altug Alkan_, Dec 17 2017
%Y Cf. A000045, A000071.
%K nonn,easy
%O 0,3
%A _Parthasarathy Nambi_, Nov 17 2005
%E More terms from _Stefan Steinerberger_, Nov 19 2005