%I #18 Jul 21 2021 08:45:04
%S 2,11,57,286,1432,7161,35807,179036,895182,4475911,22379557,111897786,
%T 559488932,2797444661,13987223307,69936116536,349680582682,
%U 1748402913411,8742014567057,43710072835286,218550364176432,1092751820882161
%N Base 5 digits are, in order, the first n terms of the periodic sequence with initial period 2,1.
%H <a href="/index/Rec#order_03">Index entries for linear recurrences with constant coefficients</a>, signature (5,1,-5).
%F a(n) = 5a(n-1) + a(n-2) - 5a(n-3).
%F G.f.: x*(2+x) / ( (x-1)*(5*x-1)*(1+x) ). - _R. J. Mathar_, Nov 21 2011
%F a(n) = (11*5^n - 2*(-1)^n - 9)/24. - _Stefano Spezia_, Jul 21 2021
%t With[{nn=30},Table[FromDigits[PadRight[{},n,{2,1}],5],{n,nn}]] (* or *) LinearRecurrence[{5,1,-5},{2,11,57},30] (* _Harvey P. Dale_, Jun 13 2016 *)
%K nonn,base,easy
%O 1,1
%A _Clark Kimberling_
|