%I #23 Jul 25 2024 19:09:07
%S 1,2,3,5,9,15,27,51,99,195,387,771,1539,3075,6147,12291,24579,49155,
%T 98307,196611,393219,786435,1572867,3145731,6291459,12582915,25165827,
%U 50331651,100663299,201326595,402653187,805306371,1610612739,3221225475,6442450947,12884901891
%N New record highs reached in A060000.
%H Harvey P. Dale, <a href="/A060013/b060013.txt">Table of n, a(n) for n = 1..1000</a>
%H <a href="/index/Rec#order_02">Index entries for linear recurrences with constant coefficients</a>, signature (3,-2).
%F For n>4: a(n) = 2*a(n-1)-3. For n>3: a(n) = 3*2^(n-3)+3 = 3*A000051(n-3) = A007283(n-3)+3.
%F a(n+1) = A060000(a(n)+1), a(1) = 1. - _Reinhard Zumkeller_, Mar 04 2008
%F G.f.: -x*(x^2-x+1)*(2*x^3+2*x^2-1) / ((x-1)*(2*x-1)). - _Colin Barker_, Jan 12 2013
%F E.g.f.: (144*exp(x) + 9*exp(2*x) - 153 - 114*x - 42*x^2 - 12*x^3 - 2*x^4)/48. - _Stefano Spezia_, Jul 25 2024
%t h = f = {1, 2}; a = 1; b = 2; Do[ g = Sort[ h ]; If[ g[ [ -1 ] ] + 1 == n, c = a + b, k = 1; While[ g[ [ k ] ] == k, k++ ]; c = k ]; a = b; b = c; h = Append[ h, c ]; If[ c > g[ [ -1 ] ], f = Append[ f, c ] ], { n, 3, 10^4 } ]; f
%t LinearRecurrence[{3,-2},{1,2,3,5,9,15},40] (* _Harvey P. Dale_, Dec 12 2018 *)
%Y Cf. A000051, A060000.
%K nonn,easy
%O 1,2
%A _Robert G. Wilson v_, Mar 15 2001
%E Formulae and more terms from _Henry Bottomley_ and Larry Reeves (larryr(AT)acm.org), Mar 19 2001