login
a(n) = 4^n + 4*n.
2

%I #26 Sep 10 2024 20:48:21

%S 1,8,24,76,272,1044,4120,16412,65568,262180,1048616,4194348,16777264,

%T 67108916,268435512,1073741884,4294967360,17179869252,68719476808,

%U 274877907020,1099511627856,4398046511188,17592186044504,70368744177756,281474976710752,1125899906842724

%N a(n) = 4^n + 4*n.

%H Vincenzo Librandi, <a href="/A221906/b221906.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 (6,-9,4).

%F G.f.: (1 + 2*x - 15*x^2)/((1-x)^2*(1-4*x)).

%F a(n) = 6*a(n-1) - 9*a(n-2) + 4*a(n-3).

%F E.g.f.: exp(x)*(exp(3*x) + 4*x). - _Elmo R. Oliveira_, Sep 10 2024

%t Table[(4^n + 4 n), {n, 0, 30}] (* or *) CoefficientList[Series[(1 + 2 x - 15 x^2)/((1 - x)^2 (1 - 4 x)), {x, 0, 30}], x]

%o (Magma) [4^n + 4*n: n in [0..30]]; /* or */ I:=[1, 8, 24]; [n le 3 select I[n] else 6*Self(n-1)-9*Self(n-2)+4*Self(n-3): n in [1..30]];

%Y Cf. A107584, A370659.

%K nonn,easy

%O 0,2

%A _Vincenzo Librandi_, Mar 02 2013