Solution
This is the cost matrix.
| 43 | 57 | 22 | 10 |
| 28 | 25 | 3 | 50 |
| 12 | 79 | 99 | 97 |
| 99 | 23 | 42 | 86 |
Subtract row minima
For each row, the minimum element is subtracted from all elements in that row.
| 33 | 47 | 12 | 0 | (-10) |
| 25 | 22 | 0 | 47 | (-3) |
| 0 | 67 | 87 | 85 | (-12) |
| 76 | 0 | 19 | 63 | (-23) |
Subtract column minima
Because each column already contains a zero, subtracting the column minima has no effect.
Cover all zeros with a minimum number of lines
A total of 4 lines are required to cover all zeros.
| 33 | 47 | 12 | 0 | x |
| 25 | 22 | 0 | 47 | x |
| 0 | 67 | 87 | 85 | x |
| 76 | 0 | 19 | 63 | x |
The optimal assignment
Because there are 4 lines required, an optimal assignment exists among the zeros.
| 33 | 47 | 12 | 0 |
| 25 | 22 | 0 | 47 |
| 0 | 67 | 87 | 85 |
| 76 | 0 | 19 | 63 |
This corresponds to the following optimal assignment in the original cost matrix.
| 43 | 57 | 22 | 10 |
| 28 | 25 | 3 | 50 |
| 12 | 79 | 99 | 97 |
| 99 | 23 | 42 | 86 |
The total minimum cost is 48.