login
a(n) = 3*a(n-1) - a(n-2) - 3*a(n-3) + 2*a(n-4), where a(0) = 2, a(1) = 4, a(2) = 8, a(3) = 18.
2

%I #17 Apr 07 2020 21:46:11

%S 2,4,8,18,38,80,164,334,674,1356,2720,5450,10910,21832,43676,87366,

%T 174746,349508,699032,1398082,2796182,5592384,11184788,22369598,

%U 44739218,89478460,178956944,357913914,715827854,1431655736,2863311500,5726623030,11453246090

%N a(n) = 3*a(n-1) - a(n-2) - 3*a(n-3) + 2*a(n-4), where a(0) = 2, a(1) = 4, a(2) = 8, a(3) = 18.

%C Conjecture: a(n) is the number of letters (0's and 1's) in the n-th iteration of the mapping 00->0010, 1->010, starting with 00; see A288203.

%C See the Comments of A288203 for a proof of this conjecture. - _Michel Dekking_, Oct 12 2018

%H Clark Kimberling, <a href="/A288206/b288206.txt">Table of n, a(n) for n = 0..2000</a>

%H <a href="/index/Rec#order_04">Index entries for linear recurrences with constant coefficients</a>, signature (3, -1, -3, 2).

%F a(n) = 3*a(n-1) - a(n-2) - 3*a(n-3) + 2*a(n-4), where a(0) = 2, a(1) = 4, a(2) = 8, a(3) = 18.

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

%F a(n) = (-3 + (-1)^(1+n) + 2^(4+n) - 6*n) / 6. - _Colin Barker_, Sep 29 2017

%t LinearRecurrence[{3, -1, -3, 2}, {2, 4, 8, 18}, 40]

%o (PARI) Vec(2*(1 - x - x^2 + 2*x^3) / ((1 - x)^2*(1 + x)*(1 - 2*x)) + O(x^40)) \\ _Colin Barker_, Sep 29 2017

%Y Cf. A288203.

%K nonn,easy

%O 0,1

%A _Clark Kimberling_, Jun 07 2017