%I #18 Jan 02 2024 08:58:22
%S 0,0,1,-1,8,-12,65,-125,544,-1224,4657,-11593,40520,-107700,356561,
%T -988901,3161728,-9014352,28179745,-81795025,252010184,-740036124,
%U 2258722337,-6682944653,20273892640,-60278338200,182146752721,-543273442201,1637465696648,-4893939533892,14726379083825
%N a(n) = -a(n-1) + 7*a(n-2) + 3*a(n-3) with a(0) = a(1) = 0, a(2) = 1.
%H G. C. Greubel, <a href="/A137232/b137232.txt">Table of n, a(n) for n = 0..1000</a>
%H <a href="/index/Rec#order_03">Index entries for linear recurrences with constant coefficients</a>, signature (-1,7,3).
%F From _R. J. Mathar_, Mar 17 2008: (Start)
%F O.g.f.: x^2/((1+3*x)*(1-2*x-x^2)).
%F a(n) = ( (-3)^n + A135532(n) )/14. (End)
%F a(n) = (1/14)*( (-3)^n + 5*Pell(n) - Pell(n+1) ), where Pell(n) = A000129(n). - _G. C. Greubel_, Apr 19 2021
%t Table[((-3)^n + 5*Fibonacci[n,2] -Fibonacci[n+1,2])/14, {n,0,40}] (* _G. C. Greubel_, Apr 19 2021 *)
%t LinearRecurrence[{-1,7,3},{0,0,1},40] (* _Harvey P. Dale_, Apr 26 2022 *)
%o (Magma) I:=[0,0,1]; [n le 3 select I[n] else -Self(n-1) +7*Self(n-2) +3*Self(n-3): n in [1..36]]; // _G. C. Greubel_, Apr 19 2021
%o (Sage) [((-3)^n +5*lucas_number1(n,2,-1) -lucas_number1(n+1,2,-1))/14 for n in (0..40)] # _G. C. Greubel_, Apr 19 2021
%Y Cf. A000129, A135532.
%K sign,easy
%O 0,5
%A _Paul Curtz_, Mar 08 2008