How many ways can $5$ digits be written down such that no odd integer is in its natural position?

493 Views Asked by At

How many ways can $5$ digits - ${1,2,3,4,5}$ be written down such that no odd integer is in its natural position ?


I tried by Inclusion-Exclusion Principle, but I'm not sure though

$=5!-\binom{3}{1}4!+\binom{3}{2}3!-\binom{3}{3}2!$


Am I right here ?

2

There are 2 best solutions below

0
On BEST ANSWER

There are three odd integers between 1 and 5. Therefore, the number of odd integers in natural position can be between 0 and 3.

To calculate the number of A0 permutations with zero odd integers in natural positions, the inclusion-exclusion principle leads to:

$$A_0 = 5! - A_1 - A_2 - A_3$$

$A_2$ is the number of permutations with two odd integers in natural position. $\binom{3}{1}$ choices to select one of three odd integers. Two non-natural positions for this selected odd integer and two choices for the remaining two even integers.

$$A_2 = 4\binom{3}{1} $$

$A_3$ is the number of permutations with all three odd integers in natural position. There are two choices to position the remaining two even integers.

$$A_3 = 2$$

To determine $A_1$, we have to find out how many possibilities exist to arrange two even and two odd integers, such that no odd integer is in its natural position. By applying the inclusion-exclusion principle again, this number $B_0$ can be determined as:

$$B_0 = 4! - B_1 - B_2$$

$$B_1 = 2 \times 2 \times 2$$

$$B_2 = 2$$

$$A_1 = 3 B_0 = 3 \times 14 = 42$$

$$A_0 = 120 - 42 - 12 -2 = 64$$


The resulting $64$ permutations:

21453
21534
21543
23154
23451
23514
23541
24153
24513
24531
25134
25143
25413
25431
31254
31452
31524
31542
32154
32451
32514
32541
34152
34251
34512
34521
35124
35142
35214
35241
35412
35421
41253
41523
41532
42153
42513
42531
43152
43251
43512
43521
45123
45132
45213
45231
51234
51243
51423
51432
52134
52143
52413
52431
53124
53142
53214
53241
53412
53421
54123
54132
54213
54231
0
On

Your approach is fine. Problems of this kind are called derangements. The inclusion-exclusion principle is a proper way to solve them, since it is easier to count the number of possibilities having at least a certain number of fix points.

We consider

  • There are $5!$ different arrangements to place the five digits.

  • From this we subtract $\binom{3}{1}4!$ which is the number of arrangements with at least one out of three odd digits at its natural position.

  • But we have subtracted arrangements with two odd digits at their natural position more than once. We correct this by adding $\binom{3}{2}3!$.

  • Finally we have to subtract arrangements with three odd digits at their natural position.

We obtain \begin{align*} 5!-\binom{3}{1}4!+\binom{3}{2}3!-\binom{3}{3}2!=120-72+18-2=64 \end{align*}