login
Binomial transform of A131666.
1

%I #18 Sep 08 2022 08:45:32

%S 0,0,1,4,12,33,90,252,729,2160,6480,19521,58806,176904,531441,1595052,

%T 4785156,14353281,43053282,129146724,387420489,1162241784,3486725352,

%U 10460235105,31380882462,94143001680,282429536481,847289140884

%N Binomial transform of A131666.

%H G. C. Greubel, <a href="/A135254/b135254.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,-12,9).

%F From _R. J. Mathar_, Apr 02 2008: (Start)

%F O.g.f.: x^2*(1-2*x)/((1 - 3*x + 3*x^2)*(1-3*x)).

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

%p seq(coeff(series(x^2*(1-2*x)/((1-3*x+3*x^2)*(1-3*x)), x, n+1), x, n), n = 0..30); # _G. C. Greubel_, Nov 21 2019

%t CoefficientList[Series[x^2(2x-1)/((3x^2-3x+1)(3x-1)),{x,0,30}],x] (* or *) LinearRecurrence[{6,-12,9},{0,0,1,4},30] (* _Harvey P. Dale_, May 26 2011 *)

%o (PARI) my(x='x+O('x^30)); concat([0,0], Vec(x^2*(1-2*x)/((1-3*x+3*x^2)*(1-3*x)))) \\ _G. C. Greubel_, Nov 21 2019

%o (Magma) R<x>:=PowerSeriesRing(Integers(), 30); [0,0] cat Coefficients(R!( x^2*(1-2*x)/((1-3*x+3*x^2)*(1-3*x)) )); // _G. C. Greubel_, Nov 21 2019

%o (Sage)

%o def A135254_list(prec):

%o P.<x> = PowerSeriesRing(ZZ, prec)

%o return P(x^2*(1-2*x)/((1-3*x+3*x^2)*(1-3*x))).list()

%o A135254_list(30) # _G. C. Greubel_, Nov 21 2019

%o (GAP) a:=[0,1,4];; for n in [4..30] do a[n]:=6*a[n-1]-12*a[n-2]+9*a[n-3]; od; Concatenation([0], a); # _G. C. Greubel_, Nov 21 2019

%Y Cf. A133474.

%K nonn

%O 0,4

%A _Paul Curtz_, Nov 30 2007

%E More terms from _R. J. Mathar_, Apr 02 2008