login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A119440 Triangle read by rows: T(n,k) is the number of binary sequences of length n that start with exactly k 01's (0 <= k <= floor(n/2)). 3

%I #15 Oct 11 2017 10:30:46

%S 1,2,3,1,6,2,12,3,1,24,6,2,48,12,3,1,96,24,6,2,192,48,12,3,1,384,96,

%T 24,6,2,768,192,48,12,3,1,1536,384,96,24,6,2,3072,768,192,48,12,3,1,

%U 6144,1536,384,96,24,6,2,12288,3072,768,192,48,12,3,1,24576,6144,1536,384,96

%N Triangle read by rows: T(n,k) is the number of binary sequences of length n that start with exactly k 01's (0 <= k <= floor(n/2)).

%C Row n contains 1+floor(n/2) terms.

%C Sum of entries in row n is 2^n (A000079).

%C T(n,0)=A098011(n+2). Except for a shift, all columns are identical.

%C G.f. of column k is x^(2k)*(1-x^2)/(1-2x).

%C Sum_{k=0..floor(n/2)} k*T(n,k) = A000975(n-1).

%H G. C. Greubel, <a href="/A119440/b119440.txt">Table of n, a(n) for the first 100 rows, flattened</a>

%F T(n,k) = 3*2^(n-2k-2) for n >= 2k+2; T(2k,k)=1; T(2k+1,k)=2.

%F G.f.: G(t,x) = (1-x^2)/((1-2*x)*(1-t*x^2)).

%e T(6,2)=3 because we have 010100, 010110 and 010111.

%e Triangle starts:

%e 1;

%e 2;

%e 3, 1;

%e 6, 2;

%e 12, 3, 1;

%e 24, 6, 2;

%e 48, 12, 3, 1;

%p T:=proc(n,k) if 2*k+2<=n then 3*2^(n-2*k-2) elif n=2*k then 1 elif n=2*k+1 then 2 else 0 fi end: for n from 0 to 16 do seq(T(n,k),k=0..floor(n/2)) od; # yields sequence in triangular form

%t nn=15;a=1/(1-y x^2);c=1/(1-2x);Map[Select[#,#>0&]&,CoefficientList[Series[1+x c+x^2 a c+x a +x^2y a+x^3y a c,{x,0,nn}],{x,y}]]//Grid (* _Geoffrey Critzer_, Jan 03 2014 *)

%t CoefficientList[CoefficientList[Series[(1 - x^2)/((1 - 2*x)*(1 - y*x^2)), {x, 0, 10}, {y, 0, 10}], x], y] // Flatten (* _G. C. Greubel_, Oct 10 2017 *)

%Y Cf. A000079, A000975, A098011.

%K nonn,tabf

%O 0,2

%A _Emeric Deutsch_, May 19 2006

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 20 11:10 EDT 2024. Contains 371838 sequences. (Running on oeis4.)