login
A375222
a(n) is the number of permutations of the multiset 1,1, 2,2, ..., n,n such that exactly one pair k,k stays at its initial locations 2k-1, 2k.
4
1, 0, 15, 296, 10965, 609864, 47880595, 5047886640, 688359502089, 117929734950320, 24798753695076471, 6280419381186155160, 1885582606127524251805, 662239984799385248609976, 268999138538324585872798395, 125133475474486312764311243744, 66091677106419135401506827779985
OFFSET
1,3
COMMENTS
1
LINKS
FORMULA
a(n) = n * A374980(n-1). - Alois P. Heinz, Aug 05 2024
EXAMPLE
a(3) = 15: The permutations with one stable pair are
[1, 1, 2, 3, 2, 3], [1, 1, 2, 3, 3, 2], [1, 1, 3, 2, 2, 3], [1, 1, 3, 2, 3, 2],
[1, 1, 3, 3, 2, 2], [1, 2, 1, 2, 3, 3], [1, 2, 2, 1, 3, 3], [1, 3, 2, 2, 1, 3],
[1, 3, 2, 2, 3, 1], [2, 1, 1, 2, 3, 3], [2, 1, 2, 1, 3, 3], [2, 2, 1, 1, 3, 3],
[3, 1, 2, 2, 1, 3], [3, 1, 2, 2, 3, 1], [3, 3, 2, 2, 1, 1].
PROG
(PARI) a375222(n) = {my(p=vector(2*n, i, 1+(i-1)\2), m1=0); forperm (p, q, my(m=0); for (k=1, n, if (q[2*k-1]==k && q[2*k]==k, m++)); m1+=(m==1)); m1}
CROSSREFS
Cf. A000680 (all permutations of this multiset), A375223 (at least one stable pair), A374980.
Sequence in context: A201029 A201341 A144349 * A009064 A049381 A051691
KEYWORD
nonn
AUTHOR
Hugo Pfoertner, Aug 05 2024
EXTENSIONS
a(8) onwards from Alois P. Heinz, Aug 05 2024
STATUS
approved