A373339 Number of permutations in symmetric group S_n with an even number of cycles of length 2 or more.
1, 1, 1, 1, 4, 36, 296, 2360, 19776, 180544, 1812352, 19953792, 239490560, 3113487872, 43589096448, 653837077504, 10461394714624, 177843713556480, 3201186851815424, 60822550202187776, 1216451004083601408, 25545471085844758528, 562000363888782868480
Offset: 0
Keywords
Examples
a(1)=a(2)=a(3)=1 due to S_1,S_2,S_3 containing 1 permutation with an even number of non-fixed point cycles: the identity permutation, with 0 non-fixed point cycles. a(4)=4 due to S_4 containing 4 permutations with an even number of non-fixed point cycles: the 3 (2,2)-cycles (12)(34),(13)(24),(14)(23); and the identity permutation (1)(2)(3)(4).
Programs
-
PARI
a(n) = n!/2 - (n-2)*2^(n-2); \\ Michel Marcus, Jun 05 2024
Formula
E.g.f.: (1/(1 - x) + exp(2*x)*(1 - x))/2. - Stefano Spezia, Jun 05 2024