%I #13 Jun 13 2015 00:51:52
%S 0,1,3,1,2,12,2,9,45,9,34,174,34,131,669,131,504,2574,504,1939,9903,
%T 1939,7460,38100,7460,28701,146583,28701,110422,563952,110422,424829,
%U 2169705,424829,1634454,8347554,1634454,6288271,32115729,6288271
%N a(n)= 3*a(n-3) +3*a(n-6) +a(n-9).
%C The recurrence shows that this consists of three interleaved sequences (actually two, one doubled) with the same recurrence (and the same characteristic polynomial).
%H <a href="/index/Rec#order_09">Index entries for linear recurrences with constant coefficients</a>, signature (0, 0, 3, 0, 0, 3, 0, 0, 1).
%F G.f.: x*(-1-3*x-x^2+x^3-3*x^4+x^5)/(-1+3*x^3+3*x^6+x^9). [From _R. J. Mathar_, Sep 27 2009]
%t M1 = {{0, 1, 0}, {0, 0, 1}, {1, 1, 1}}; M2 = {{1, 1, 1}, {1, 0, 0}, {0, 1, 0}}; M3 = {{0, 1, 0}, {1, 1, 1}, {1, 0, 0}}; M[n_] = If[Mod[n, 3] == 1, M3, If[Mod[n, 3] == 2, M2, M1]]; v[0] = {0, 1, 1}; v[n_] := v[n] = M[n].v[n - 1] a = Table[v[n][[1]], {n, 0, 100}]
%t LinearRecurrence[{0,0,3,0,0,3,0,0,1},{0,1,3,1,2,12,2,9,45},40] (* _Harvey P. Dale_, Mar 19 2013 *)
%Y Cf. A000931.
%K nonn,easy
%O 0,3
%A _Roger L. Bagula_, Jun 18 2005
%E Definition replaced by recurrence. - The Assoc. Editors of the OEIS, Oct 22 2009
|