Solution
This is the cost matrix.
| 72 | 20 | 22 | 4 |
| 89 | 18 | 4 | 11 |
| 16 | 14 | 10 | 32 |
| 10 | 71 | 18 | 30 |
Subtract row minima
For each row, the minimum element is subtracted from all elements in that row.
| 68 | 16 | 18 | 0 | (-4) |
| 85 | 14 | 0 | 7 | (-4) |
| 6 | 4 | 0 | 22 | (-10) |
| 0 | 61 | 8 | 20 | (-10) |
Subtract column minima
For each column, the minimum element is subtracted from all elements in that column.
| 68 | 12 | 18 | 0 |
| 85 | 10 | 0 | 7 |
| 6 | 0 | 0 | 22 |
| 0 | 57 | 8 | 20 |
| (-4) | | |
Cover all zeros with a minimum number of lines
A total of 4 lines are required to cover all zeros.
| 68 | 12 | 18 | 0 | x |
| 85 | 10 | 0 | 7 | x |
| 6 | 0 | 0 | 22 | x |
| 0 | 57 | 8 | 20 | x |
The optimal assignment
Because there are 4 lines required, an optimal assignment exists among the zeros.
This corresponds to the following optimal assignment in the original cost matrix.
| 72 | 20 | 22 | 4 |
| 89 | 18 | 4 | 11 |
| 16 | 14 | 10 | 32 |
| 10 | 71 | 18 | 30 |
The total minimum cost is 32.