0

How many permutations of $[n]$ are there satisfying $j=f(i)\iff i=f(j)$ for all $i,j\in [n]$?

I thought to count the number of permutations for which there's some $i,j\in [n]$ not satisfying the equivalence. So it's enough to count the permutations for which there are $i\neq j$ satisfying $f(i)=j,f(j)\neq i$.

So we start with $i$ and its image is determined for us. Then we go to $j$ and see it only has $n-2$ available places since it can't go to $j$ and it can't stay in place because $j$ will replace it. Then we're left with $n-2$ items and $n-2$ slots (every save the image of $i,j$) so I think the overall answer is $n! - (n-2)\cdot (n-2)!$

However I'm bad at combinatorics and am worried I have a mistake. The phrasing of the problem suggests inclusion-exclusion may be the correct approach but after trying it I didn't really get anywhere. I also thought the equivalence is saying $ \left\{ i,j \right\} $ is a "fixed block" so maybe something with fixed points and derangements...

  • 2
    http://math.stackexchange.com/questions/590402/number-of-involution-in-symmetric-group – Jack D'Aurizio Sep 23 '16 at 12:56
  • @JackD'Aurizio thanks. Could you explain what's wrong in my reasoning? – combinarcotics Sep 23 '16 at 13:12
  • Actually I don't quite follow your algorithm for performing replacements. It is easier to me to consider the cycle decomposition of $f$ and notice the cycle length is always $1$ or $2$. – Jack D'Aurizio Sep 23 '16 at 13:30
  • @JackD'Aurizio I don't know what cycle decompositions are. I'm trying to count to number of permutations for which there are $i\neq j$ satisfying $f(i)=j,f(j)\neq i$. The image of $i$ is determined so we move on to the image of $j$. This image has $n-2$ possible values because it can be anything except $i,j$. Then we're left with $n-2$ images to determine, each of which has $n-2$ possible values, so a permutation of $[n-2]$. – combinarcotics Sep 23 '16 at 13:36
  • But you consider a single $(i,j)$ couple, and nothing about the behaviour of $f$ on the ${h,k}$ couple, for instance. The cycle decomposition is a very important notion in dealing with permutations: http://groupprops.subwiki.org/wiki/Cycle_decomposition_theorem_for_permutations – Jack D'Aurizio Sep 23 '16 at 13:58
  • @JackD'Aurizio but why does the behavior of $f$ on any other couple matter? We just want a single couple for which the equivalence doesn't hold, count how many such permutations there are, and subtract them from the total. What am I missing? – combinarcotics Sep 23 '16 at 14:37
  • What if we have the wrong behaviour over two distinct couples? How many times do you count such occurrency? – Jack D'Aurizio Sep 23 '16 at 14:38
  • 1
    @JackD'Aurizio ahh.. so simple.. Thanks! – combinarcotics Sep 23 '16 at 14:54

0 Answers0