# What is the probability that all chess pieces are correctly arranged on the standard chessboard

I trying to solve this task using two approaches: an elementary approach and one using conditional probability.

1. Approach: Let's number all pieces from 1 to 32. Then for the 1st piece there're 64 possible positions, for the 2nd piece there're 63 possible positions, ..., for the 32st piece there are 33 possible positions. Since there are 8 identical pawn twice, and 2 identical bishops twice, 2 identical knights twice and 2 identical rooks twice, then we have $$\frac{\left(64 - 0\right)\left(64 - 1\right) \dots \left(64 - 31\right)}{8!^22^22^22^2}$$.

Since there is one possibility satisfies the constraints then $$P\left(\text{All chess pieces are correctly arranged on the standard chessboard}\right) = \frac{8!^22^22^22^2}{\left(64 - 0\right)\left(64 - 1\right) \dots \left(64 - 31\right)}$$

1. Approach: Let $$A$$ be the event that the white pieces are correctly arranged on the chessboard, and $$B$$ be the event that the black pieces are correctly arranged on the chessboard. Thus $$P\left(\text{All chess pieces are correctly arranged on standard chessboard}\right) = P\left( A \cap B\right)$$. Since $$A$$ and $$B$$ are dependent then $$P\left( A \cap B\right) \neq P\left( A \right)P\left( B \right)$$.

But $$P\left( A \cap B\right) = P\left( A \right)P\left( B |A\right)$$. I got stuck here. Any clue?

• This lacks detail. How are the pieces being distributed on the board? Is the first placement uniformly random with all subsequent placements uniformly random on the available squares? If so, then just count the "good" placements, being aware of the fact that the queens must be on their own colors and that bishops, rooks, knights, pawns are indistinguishable aside from rank and color.
– lulu
Commented Jul 22 at 12:05
• All pieces are uniformly random distributed. That was indirectly given by labeling all pieces from 1 up to 32 Commented Jul 22 at 12:08
• So, add that to the post. Then, count by pretending the pieces are all distinct (number the pawns and such), and then count good arrangements.
– lulu
Commented Jul 22 at 12:10
• There's an ambiguity in your question. I initially thought that that the pieces were in any valid configuration (e.g. at move N in a chess game). Obviously there are constraints (the two kings cannot touch, for example), but they are a bit more complex. Consideration of a similar problem, (with playing cards), led Stanislaw Ulam to invent Monte Carlo methods. Commented Jul 22 at 20:51

So here you should think of there being $$(64−0)(64−1)…(64−31)$$ arrangements in total. Now there are $$8!^2\times 2^6$$ possible valid arrangements, since you can permute equivalent pieces, so you get the same answer.
• @AyoubFalah I don't know why you would want to, but you could do pieces one by one. The probability of placing the white king correctly is $1/64$. The probability of placing the white queen correctly, given that you placed the white king correctly, is $1/63$. The probability of placing the first white rook correctly, given the previous pieces are correct, is $2/62$, and so on. Then just multiply all these together. Commented Jul 22 at 12:14
The result follows directly from your formula $$P\left( A \cap B\right) = P( A)P( B\,|\,A)$$. We have $$P(A)=\frac{8!\cdot 2\cdot 2\cdot 2}{(64-0)(64-1)\ldots(64-15)}$$ and with the White pieces in place, there are only $$48$$ empty squares, so $$P(B\,|\,A)=\frac{8!\cdot 2\cdot 2\cdot 2}{(48-0)(48-1)\ldots(48-15)}$$ Multiplying these together gives your original result.