|
|
A008282
|
|
Triangle of Euler-Bernoulli or Entringer numbers read by rows: T(n,k) is the number of down-up permutations of n+1 starting with k+1.
|
|
22
|
|
|
1, 1, 1, 1, 2, 2, 2, 4, 5, 5, 5, 10, 14, 16, 16, 16, 32, 46, 56, 61, 61, 61, 122, 178, 224, 256, 272, 272, 272, 544, 800, 1024, 1202, 1324, 1385, 1385, 1385, 2770, 4094, 5296, 6320, 7120, 7664, 7936, 7936, 7936, 15872, 23536, 30656, 36976, 42272, 46366, 49136, 50521, 50521
(list;
table;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,5
|
|
REFERENCES
|
R. C. Entringer, A combinatorial interpretation of the Euler and Bernoulli numbers, Nieuw Archief voor Wiskunde, 14 (1966), 241-246.
|
|
LINKS
|
Carolina Benedetti, Rafael S. González D’León, Christopher R. H. Hanusa, Pamela E. Harris, Apoorva Khare, Alejandro H. Morales, and Martha Yip, The volume of the caracol polytope, Séminaire Lotharingien de Combinatoire XX (2018), Article #YY, Proceedings of the 30th Conference on Formal Power, Series and Algebraic Combinatorics (Hanover), 2018.
J. Millar, N. J. A. Sloane and N. E. Young, A new operation on sequences: the Boustrophedon transform, J. Combin. Theory, 17A (1996) 44-54 (Abstract, pdf, ps).
|
|
FORMULA
|
Let E[j] = A000111(j) = j! * [x^j](sec(x) + tan(x)) be the up/down or Euler numbers. For 1 <= k < n,
T(n, k) = Sum_{i=0..floor((k-1)/2)} (-1)^i * binomial(k, 2*i+1) * E[n-2*i-1];
T(n,k) = Sum_{i=0..floor((n-k)/2)} (-1)^i * binomial(n-k, 2*i) * E[n-2*i];
T(n, k) = Sum_{i=0..floor((n-k)/2)} (-1)^i * binomial(n-k, 2*i) * E[n-2*i]; and
T(n, n) = E[n] for n >= 1. (End)
If n is even, then T(n,k) = k!*(n-k)!*[x^(n-k),y^k] cos(x)/cos(x + y).
If n is odd, then T(n,k) = k!*(n-k)!*[x^k,y^(n-k)] sin(x)/cos(x + y).
(These were adapted and corrected from the formulas in Corollary 1.3 in Foata and Guo-Niu Han (2014).) (End)
Comment from Masanobu Kaneko: (Start)
A generating function that applies for all n, both even and odd:
Sum_{n=0..oo} Sum_{k=0..n} T(n,k) x^(n-k}/(n-k)! * y^k/k! = {cos x + sin y}/cos(x + y).
|
|
EXAMPLE
|
Triangle T(n,k) (with rows n >= 1 and columns k = 1..n) begins
1
1 1
1 2 2
2 4 5 5
5 10 14 16 16
16 32 46 56 61 61
...
Each row is constructed by forming the partial sums of the previous row, reading from the right and repeating the final term.
T(4,3) = 5 because we have 41325, 41523, 42314, 42513 and 43512. All these permutations have length n+1 = 5, start with k+1 = 4, and they are down-up permutations.
|
|
MAPLE
|
f:=series(sec(x)+tan(x), x=0, 25): E[0]:=1: for n from 1 to 20 do E[n]:=n!*coeff(f, x^n) od: T:=proc(n, k) if k<n then sum((-1)^i*binomial(k, 2*i+1)*E[n-2*i-1], i=0..floor((k-1)/2)) elif k=n then E[n] else 0 fi end: seq(seq(T(n, k), k=1..n), n=1..10);
# Alternatively:
T := proc(n, k) option remember; if k = 0 then `if`(n = 0, 1, 0) else
T(n, k - 1) + T(n - 1, n - k) fi end:
for n from 1 to 6 do seq(T(n, k), k=1..n) od; # Peter Luschny, Aug 03 2017
# Third program:
T := proc(n, k) local w: if 0 = n mod 2 then w := coeftayl(cos(x)/cos(x + y), [x, y] = [0, 0], [n - k, k]): end if: if 1 = n mod 2 then w := coeftayl(sin(x)/cos(x + y), [x, y] = [0, 0], [k, n - k]): end if: w*(n - k)!*k!: end proc:
|
|
MATHEMATICA
|
ro[1] = {1}; ro[n_] := ro[n] = (s = Accumulate[ Reverse[ ro[n-1]]]; Append[ s, Last[s]]); Flatten[ Table[ ro[n], {n, 1, 10}]] (* Jean-François Alcover, Oct 03 2011 *)
nxt[lst_]:=Module[{lst2=Accumulate[Reverse[lst]]}, Flatten[Join[ {lst2, Last[ lst2]}]]]; Flatten[NestList[nxt, {1}, 10]] (* Harvey P. Dale, Aug 17 2014 *)
|
|
PROG
|
(Haskell)
a008282 n k = a008282_tabl !! (n-1) !! (k-1)
a008282_row n = a008282_tabl !! (n-1)
a008282_tabl = iterate f [1] where
f xs = zs ++ [last zs] where zs = scanl1 (+) (reverse xs)
|
|
CROSSREFS
|
|
|
KEYWORD
|
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|