%I #23 Jan 02 2024 08:59:37
%S 0,1,1,1,3,9,15,25,55,121,231,441,903,1849,3655,7225,14535,29241,
%T 58311,116281,232903,466489,932295,1863225,3727815,7458361,14913991,
%U 29822521,59650503,119311929,238612935,477204025,954429895,1908903481,3817763271,7635439161,15270965703
%N First differences of A138477.
%H G. C. Greubel, <a href="/A138495/b138495.txt">Table of n, a(n) for n = 0..1000</a>
%H <a href="/index/Rec#order_04">Index entries for linear recurrences with constant coefficients</a>, signature (1, 0, 2, 4).
%F From _R. J. Mathar_, May 19 2008: (Start)
%F O.g.f.: x/((1-2*x)*(1+x)*(1+2*x^2)).
%F a(n) = a(n-1) + 2*a(n-3) + 4*a(n-4). (End)
%F E.g.f.: (2*exp(2*x) - exp(-x) - cos(sqrt(2)*x) + 2*sqrt(2)*sin(sqrt(2)*x) )/9. - _G. C. Greubel_, May 24 2019
%t LinearRecurrence[{1,0,2,4}, {0,1,1,1}, 40] (* _G. C. Greubel_, May 24 2019 *)
%o (PARI) concat(0, Vec(x/((1-2*x)*(1+x)*(1+2*x^2)) + O(x^40))) \\ _Michel Marcus_, May 24 2019
%o (Magma) R<x>:=PowerSeriesRing(Integers(), 40); [0] cat Coefficients(R!( x/((1-2*x)*(1+x)*(1+2*x^2)) )); // _G. C. Greubel_, May 24 2019
%o (Sage) (x/((1-2*x)*(1+x)*(1+2*x^2))).series(x, 40).coefficients(x, sparse=False) # _G. C. Greubel_, May 24 2019
%o (GAP) a:=[0,1,1,1];; for n in [5..40] do a[n]:=a[n-1]+2*a[n-3]+4*a[n-4]; od; a; # _G. C. Greubel_, May 24 2019
%Y Cf. A138477.
%K nonn
%O 0,5
%A _Paul Curtz_, May 18 2008
%E a(13) corrected by _Georg Fischer_, May 24 2019
%E More terms from _Michel Marcus_, May 24 2019