Library/Algebra/Mathematics in Chess/Exact Opponent Attacks

Exact Opponent Attacks

Practice
Overview

[!IMPORTANT] Colour the pieces black and white, and draw an edge whenever opposite-colour pieces attack each other. Then the puzzle becomes a bipartite graph problem with an exact degree condition.

Important properties

  • If every piece attacks exactly kk opponent pieces, then every vertex has degree kk.
  • Because each edge joins one white piece to one black piece, the total edge count is both kWkW and kBkB, where WW and BB are the numbers of white and black pieces. So W=BW=B whenever k>0k>0.
  • Knights give local sparse patterns, while queens create long line-of-sight interactions that can be controlled by blockers.
  • The same graph idea explains the old degree-2 knight problems and the new knight-and-queen problems.

The challenge is not just counting. It is realizing the required regular bipartite graph inside the actual geometry of the chessboard.