%I #28 Sep 08 2022 08:45:15
%S 1,4,20,95,456,2184,10465,50140,240236,1151039,5514960,26423760,
%T 126603841,606595444,2906373380,13925271455,66719983896,319674648024,
%U 1531653256225,7338591633100,35161304909276,168467932913279,807178359657120,3867423865372320
%N Expansion of 1 / ((1+x) * (1-5*x+x^2)).
%D R. C. Alperin, A nonlinear recurrence and its relations to Chebyshev polynomials, Fib. Q., 58:2 (2020), 140-142.
%H Colin Barker, <a href="/A099025/b099025.txt">Table of n, a(n) for n = 0..1000</a>
%H P. Barry, <a href="https://cs.uwaterloo.ca/journals/JIS/VOL12/Barry4/barry64.html">Symmetric Third-Order Recurring Sequences, Chebyshev Polynomials, and Riordan Arrays</a>, JIS 12 (2009) 09.8.6
%H <a href="/index/Rec#order_03">Index entries for linear recurrences with constant coefficients</a>, signature (4,4,-1).
%F a(n) = (1/7)*[A030221(n+2) - A003501(n+2) + (-1)^n].
%F a(n) = 5*a(n-1) -a(n-2) +(-1)^n, a(0)=1, a(1)=4. - _Vincenzo Librandi_, Mar 22 2011
%F G.f.: 1 / ((1 + x) * (1 - 5*x + x^2)).
%F a(-3-n) = -a(n). - _Michael Somos_, Jan 25 2013
%F a(n) = (2^(-n)*(3*(-2)^n+(9-2*sqrt(21))*(5-sqrt(21))^n+(5+sqrt(21))^n*(9+2*sqrt(21))))/21. - _Colin Barker_, Nov 02 2016
%e 1 + 4*x + 20*x^2 + 95*x^3 + 456*x^4 + 2184*x^5 + 10465*x^6 + ...
%t CoefficientList[Series[1/((1+x)*(1-5*x+x^2)), {x,0,50}], x] (* or *) LinearRecurrence[{4,4,-1}, {1,4,20}, 30] (* _G. C. Greubel_, Dec 31 2017 *)
%o (PARI) Vec(1/(1+x)/(1-5*x+x^2)+O(x^99)) \\ _Charles R Greathouse IV_, Sep 26 2012
%o (PARI) {a(n) = (3 * (-1)^n + 38 * subst( poltchebi(n), x, 5/2) - 8 * subst( poltchebi(n-1), x, 5/2)) / 21} /* _Michael Somos_, Jan 25 2013 */
%o (Magma) I:=[1, 4, 20]; [n le 3 select I[n] else 4*Self(n-1) + 4*Self(n-2) - Self(n-3): n in [1..30]]; // _G. C. Greubel_, Dec 31 2017
%Y First differences of A089927. First differences are in A003769 and A005386. Pairwise sums are in A004254.
%K nonn,easy
%O 0,2
%A _Ralf Stephan_, Sep 26 2004