login
Number of binary strings of length n avoiding "squares" (that is, repeated blocks of the form xx) with |x| = 3.
4

%I #12 Aug 09 2019 12:13:09

%S 1,2,4,8,16,32,56,104,192,352,648,1192,2192,4032,7416,13640,25088,

%T 46144,84872,156104,287120,528096,971320,1786536,3285952,6043808,

%U 11116296,20446056,37606160,69168512,127220728,233995400,430384640,791600768,1455980808

%N Number of binary strings of length n avoiding "squares" (that is, repeated blocks of the form xx) with |x| = 3.

%H Colin Barker, <a href="/A230216/b230216.txt">Table of n, a(n) for n = 0..1000</a>

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

%F a(n) = 8*A000073(n) for n >= 3.

%F From _Colin Barker_, Aug 09 2019: (Start)

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

%F a(n) = a(n-1) + a(n-2) + a(n-3) for n>5.

%F (End)

%e For n = 6 there are 8 strings omitted, namely 000000, 001001, ..., 111111, so a(6) = 64-8 = 56.

%o (PARI) Vec((1 + x + x^2 + x^3 + 2*x^4 + 4*x^5) / (1 - x - x^2 - x^3) + O(x^40)) \\ _Colin Barker_, Aug 09 2019

%Y Cf. A000073, A022087, A229614, A230127, A230177.

%K nonn,easy

%O 0,2

%A _Nathaniel Johnston_, Oct 11 2013