ch9 - QDM - Assignment Model Final
ch9 - QDM - Assignment Model Final
for i 1, 2, . . . , n and j 1, 2, . . . , n. Thus, each xij is a binary variable (it has value 0 or 1). As
discussed at length in the chapter on integer programming , binary variables are important in OR for
representing yes/no decisions. In this case, the yes/no decision is: Should assignee i perform task j?
By letting Z denote the total cost, Parameter table for the assignment problem
the assignment problem model is formulated as a transportation problem
Network representation of the assignment problem
Hungarian method for solution of assignment problem
• The Hungarian method of assignment provides us with an efficient means of finding the optimal solution. The
Hungarian method is based upon the following principles:
(i) If a constant is added to every element of a row and/or column of the cost matrix of an assignment
problem the resulting assignment problem has the same optimum solution as the original problem or vice
versa.
(ii) The solution having zero total cost is considered as optimum solution.
Hungarian method (contd)
• Hungarian method of assignment problem (minimization case) solution can be summarized in the following
steps:
Step I: Subtract the minimum cost of each row of the cost (effectiveness) matrix from all the
elements of the respective row so as to get first reduced matrix.
Step II: Similarly subtract the minimum cost of each column of the cost matrix from all the elements
of the respective column of the first reduced matrix. This is first modified matrix.
Step III: Draw minimum number of lines to cover all zeros.
Step IV: If Number of lines drawn = order of matrix, then optimally is reached, so proceed to step 6.
If optimally is not reached, then go to step 5.
Step V: Select the smallest element of the whole matrix, which is NOT COVERED by lines. Subtract
this smallest element with all other remaining elements that are NOT COVERED by lines and add the element
at the intersection of lines. Leave the elements covered by single line as it is. Now go to step 4.
Step VI: Take any row or column which has a single zero and assign by squaring it. Strike off the
remaining zeros, if any, in that row and column (X). Repeat the process until all the assignments have been
made.
Step VII : Write down the assignment results and find the minimum cost/time.
Hungarian method (contd)
• Example: Assign the four tasks to four operators. The assigning costs are given in Table.
Hungarian method (contd)
• Solution:
• Step 1: The given problem is a balanced (cost matrix is a
square matrix) and it is not necessary to add a dummy
row/column
• Step 2: Reduce the matrix by selecting the smallest value in
each row and subtracting from other values in that
corresponding row. In row A, the smallest value is 13, row B is
15, row C is 17 and row D is 12. The row wise reduced matrix is
shown in table below.
• Step 3: Reduce the new matrix given in the following table by
selecting the smallest value in each column and subtract from
other values in that corresponding column. In column 1, the
smallest value is 0, column 2 is 4, column 3 is 3 and column 4 is
0. The column-wise reduction matrix is shown in the following
table
Hungarian method (contd)
• Step 4: Draw minimum number of lines possible to cover all
the zeros in the matrix given in Table. The first line is drawn
crossing row C covering three zeros, second line is drawn
crossing column 4 covering two zeros and third line is drawn
crossing column 1 (or row B) covering a single zero.
• Step 5: Check whether number of lines drawn is equal to the
order of the matrix, i.e., 3 ≠ 4. Therefore optimally is not
reached. Go to step 6.
• Step 6: Take the smallest element of the matrix that is not
covered by single line, which is 3. Subtract 3 from all other
values that are not covered and add 3 at the intersection of
lines. Leave the values which are covered by single line. The
following table shows the details.
Hungarian method (contd)
• Step 7: Now, draw minimum number of lines to cover all the
zeros and check for optimality. Here in table minimum number
of lines drawn is 4 which are equal to the order of matrix. Hence
optimality is reached.
• Step 8: Assign the tasks to the operators. Select a row that has
a single zero and assign by squaring it. Strike off remaining
zeros if any in that row or column. Repeat the assignment for
same procedure for columns till all assignments are done. The
final assignment is shown in table below.
Hungarian method (contd)
• Therefore, optimal assignment is: