|
|
A129817
|
|
Number of alternating fixed-point-free permutations on n letters.
|
|
4
|
|
|
1, 0, 1, 1, 2, 6, 24, 102, 528, 2952, 19008, 131112, 1009728, 8271792, 74167488, 703077552, 7194754368, 77437418112, 890643066048, 10726837356672, 136988469649728, 1825110309733632, 25625477737660608, 374159217291201792, 5728724202727533888, 90961591766739121152, 1508303564683904357568, 25874345243221479539712, 461932949559928514787648, 8513674175717969079785472, 162818666826944872460200128
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,5
|
|
COMMENTS
|
Alternating permutations are also called down-up permutations.
a(n) is also the number of alternating permutations of {1,2,...,n} having exactly 1 fixed point (see the Richard Stanley reference). Example: a(4)=2 because we have 4132 and 3241.
(End)
|
|
LINKS
|
|
|
FORMULA
|
|
|
EXAMPLE
|
|
|
MATHEMATICA
|
nmax = 30;
fo = Exp[e*(ArcTan[q*t] - ArcTan[t])]/(1 - e*t);
fe = Sqrt[(1+t^2)/(1+q^2*t^2)]*Exp[e*(ArcTan[q*t] - ArcTan[t])]/(1-e*t);
Q[n_] := If [OddQ[n] , SeriesCoefficient[fo, {t, 0, n}], SeriesCoefficient[fe, {t, 0, n}]] // Expand;
b[n_] := n!*SeriesCoefficient[Sec[x] + Tan[x], {x, 0, n}];
P[n_] := (Q[n] /. e^k_Integer :> b[k]) /. e :> b[1] // Expand;
a[n_] := Coefficient[P[n], q, 0];
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|