OFFSET
1,3
LINKS
Reinhard Zumkeller, Rows n = 1..200 of triangle, flattened
EXAMPLE
1;
1;
3, 1;
4, 1;
10, 5, 1;
15, 6, 1;
35, 21, 7, 1;
56, 28, 8, 1;
126, 84, 36, 9, 1;
210, 120, 45, 10, 1;
462, 330, 165, 55, 11, 1;
792, 495, 220, 66, 12, 1.
PROG
(Haskell)
a014413 n k = a014413_tabf !! (n-1) !! (k-1)
a014413_row n = a014413_tabf !! (n-1)
a014413_tabf = [1] : f 1 [1] where
f 0 us'@(_:us) = ys : f 1 ys where
ys = zipWith (+) us' (us ++ [0])
f 1 vs@(v:_) = ys' : f 0 ys where
ys@(_:ys') = zipWith (+) (vs ++ [0]) ([v] ++ vs)
-- Reinhard Zumkeller, Dec 24 2015
CROSSREFS
KEYWORD
tabf,nonn,easy
AUTHOR
EXTENSIONS
More terms from James A. Sellers
STATUS
approved