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

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A057606 Triangle read by rows: T(n,k) = number of binary n-tuples u having exactly k grandchildren, where a grandchild is a vector obtained by deleting any two coordinates of u (n >= 3, 1<=k<=2^(n-2)). 2

%I #13 Jul 13 2013 12:02:34

%S 2,6,2,4,6,4,2,4,8,4,8,4,2,0,2,4,10,6,12,8,8,6,6,0,2,0,0,0,0,0,2,4,12,

%T 8,16,14,16,12,12,12,6,4,8,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,4,

%U 14,10,20,22,24,22,22,26,18,16,12,16,12,0,4,10,0,0,0,2,0,0,0,0

%N Triangle read by rows: T(n,k) = number of binary n-tuples u having exactly k grandchildren, where a grandchild is a vector obtained by deleting any two coordinates of u (n >= 3, 1<=k<=2^(n-2)).

%C Row lengths = 2^(n-2), row sums = 2^n.

%D N. J. A. Sloane, On single-deletion-correcting codes, in Codes and Designs (Columbus, OH, 2000), 273-291, Ohio State Univ. Math. Res. Inst. Publ., 10, de Gruyter, Berlin, 2002.

%H Reinhard Zumkeller, <a href="/A057606/b057606.txt">Rows n = 3..15 of triangle, flattened</a>

%H N. J. A. Sloane, <a href="http://neilsloane.com/doc/dijen.txt">On single-deletion-correcting codes</a>

%e 2,6; 2,4,6,4; 2,4,8,4,8,4,2,0; ...

%o import Data.List (group, sort, nub, inits, tails)

%o a057606 n k = a057606_tabf !! (n-3) !! (k-1)

%o a057606_row n = a057606_tabf !! (n-3)

%o a057606_tabf = map g \$ drop 3 \$

%o iterate (\xs -> (map (0 :) xs) ++ (map (1 :) xs)) [[]] where

%o g xss = map length \$ fill0 \$ group \$ sort \$ map (length . del2) xss

%o where fill0 uss = f0 uss [1 .. length xss `div` 4] where

%o f0 _ [] = []

%o f0 [] (j:js) = [] : f0 [] js

%o f0 vss'@(vs:vss) (j:js)

%o | j == head vs = vs : f0 vss js

%o | otherwise = [] : f0 vss' js

%o del2 = nub . (concatMap del1) . del1

%o del1 xs = nub \$

%o zipWith (++) (init \$ inits xs) (map tail \$ init \$ tails xs)

%o -- _Reinhard Zumkeller_, Apr 30 2012

%Y Cf. A057607.

%K nonn,tabf,nice

%O 3,1

%A _N. J. A. Sloane_, Oct 08 2000

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.

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