Expert Answer
Based on the details of the city & date to define row & column; B3 means leaving Boston & A7 means returning from Atlanta.
A7 | A12 | A21 | A28 | |
D3 | 400 | 300 | 300 | 280 |
D10 | 300 | 400 | 300 | 300 |
D17 | 300 | 300 | 400 | 300 |
D25 | 300 | 300 | 300 | 400 |
Step 1: The first requirement is that matrix should be balanced i.e. the number of rows should be equal to the number of columns. The second Requirement is that each row and each column must have least one zero. So Select, least number from the first row i.e. 1 and subtract that number from remaining numbers of that row. Follow the similar procedure for rest of the rows. Then follow the similar procedure for the column as we, select the least number from that column and subtract it from remaining numbers of that column, if zero is already present in that column, no need to perform the operation.
A7 | A12 | A21 | A28 | |
D3 | 120 | 20 | 20 | 0 |
D10 | 0 | 100 | 0 | 0 |
D17 | 0 | 0 | 100 | 0 |
D25 | 0 | 0 | 0 | 100 |
Step 2: Perform Row & column operation.
To perform row operation, the particular row should have only one zero, then only you can perform row operation, otherwise, proceed to next row.
In the first row, there is only one zero, so row operation can be performed. Row operation is performed by assigning the zero, by making the square on it and canceling the column.
A7 | A12 | A21 | A28 | |
D3 | 120 | 20 | 20 | 0 |
D10 | 0 | 100 | 0 | 0 |
D17 | 0 | 0 | 100 | 0 |
D25 | 0 | 0 | 0 | 100 |
Step 3 : For optimal solution, Number of squared zero= number of row/column.
Here, Number of squared zero=4 & number of row=4, so optimal solution.
D3-A28=280, D10-A21=300, D17-A12=300, D25-A21=300
Solving this, we get answer zmin is 1180$
With regards to the one-way ticket for $ 250, as there is no one way journey considering all these possibilities, the one-way journey cannot be considered for this solution. While Solving this problem we can get an alternate solution as while making the optimal solution there were more than 1 zero in row and column.