%I #25 Sep 08 2022 08:44:52
%S 2,8,33,134,536,2145,8582,34328,137313,549254,2197016,8788065,
%T 35152262,140609048,562436193,2249744774,8998979096,35995916385,
%U 143983665542,575934662168,2303738648673,9214954594694,36859818378776
%N Base-4 digits are, in order, the first n terms of the periodic sequence with initial period 2,0,1.
%H Vincenzo Librandi, <a href="/A037513/b037513.txt">Table of n, a(n) for n = 1..1000</a>
%H <a href="/index/Rec#order_04">Index entries for linear recurrences with constant coefficients</a>, signature (4,0,1,-4).
%F G.f.: x*(2+x^2) / ( (x-1)*(4*x-1)*(1 + x + x^2) ). - _R. J. Mathar_, Nov 21 2011
%F a(n) = 4*a(n-1) + a(n-3) - 4*a(n-4). - _Vincenzo Librandi_, Jun 22 2012
%t LinearRecurrence[{4,0,1,-4},{2,8,33,134},40] (* _Vincenzo Librandi_, Jun 22 2012 *)
%t Module[{nn=30,c},c=PadRight[{},nn,{2,0,1}];Table[FromDigits[Take[c,n],4],{n,nn}]] (* _Harvey P. Dale_, May 28 2014 *)
%o (Magma) I:=[2, 8, 33, 134]; [n le 4 select I[n] else 4*Self(n-1)+Self(n-3)-4*Self(n-4): n in [1..30]]; // _Vincenzo Librandi_, Jun 22 2012
%o (PARI) x='x+O('x^99); Vec(x*(2+x^2)/((x-1)*(4*x-1)*(1+x+x^2))) \\ _Altug Alkan_, Sep 21 2018
%K nonn,base,easy
%O 1,1
%A _Clark Kimberling_