Duality Examples
Duality Examples
Decision variables must be non-negative. In some formulations it makes sense to have negative
values allowed for some decision variables or unrestricted in sign. (e.g., trade balance, distance
relative to an origin, etc.)
Now these variables must be replaced with positive variables.
Negative Variables:
Replace xj with x/j where x/j = (-1) xj and so x/j >=0
Unrestricted in sign
Replace xj with xj+- xj- where xj+ and xj- >=0
Duality:
Subject to:
xi is primal variable and Z is primal Objective function. vi is dual variable and W is dual Objective
function.
Max Z = c1x1+c2x2+ ... +cnxn Min W = b1v1 + b2v2 + ... +bmvm
Subject to: Subject to:
a11x1+a12x2+ ... + a1nxn ≤ b1 a11v1 + a21v2 + ... + am1vm ≥ c1
a21x1+a12x2+ ... + a1nxn ≤ b1 a12v1 + a22v2 + ... + am2vm ≥ c2
... …
... …
a11x1+a12x2+ ... + a1nxn ≤ b1 a1nv1 + a2nv2 + ... = amnvm ≥ cn
x1, x2, ... , xn ≥ 0 v1, v2, ... . vm ≥ 0
Procedure
• Problem must be of canonical form. If not, convert it, that is, If Objective function is of
Maximization type then constraints must be of less than equal to types and if Objective
function is of Minimization type then constraints must be of greater than equal to types.
• If any constraint is of equal to type then convert it to two less than equal to or greater than
equal to according to objective function.
• All variables must be of non-negative. If not, convert as per rule.
• If the primal is maximization type then the dual is of minimization type & vice-versa
• Number of variables in the dual problem is equal to the number of constraints in the primal
& vice-versa
• The elements of the requirement vector (Constraint levels) in one problem are the
respective coefficient in the objective function of the other problem and vice-versa.
• The “less than equal” sign in primal constraints become “greater than equal” in the dual &
vice-versa
• The coefficients matrix of constraints of primal problem will be converted to its transpose
matrix and this transpose matrix will be used as coefficients of dual problem
Examples:
2. The vitamins V and W are found in two different foods, F1 and F2. The amount of vitamin in
each of the two foods, respective prices per unit of each food and the daily vitamin
requirements are given in the following table.
Vitamin Foods Daily Requirement
F1 F2
V 2 4 40
W 3 2 50
Cost per unit of Food (in Rs) 3 2.5
The primal problem is to determine optimal of Food f1 and f2 to be purchased so that the
daily requirements are met and simultaneously the cost of purchasing the foods is
minimized. Formulate the dual problem for the primal problem and interpret.
3. A firm makes three products A, B and C. Each product requires production time in each of
three departments as shown below:
Product Time taken in hours per unit
Deptt I Deptt II Deptt III
A 3 2 1
B 4 1 3
C 2 2 3
Total time available is 60 hours, 40 hours and 30 hours in department I, II and III
respectively. If product A contributes Rs 2 per unit and products B and C Rs 4 and Rs 2.5
respectively, determine the optimum product mix. Write the dual of this problem and give
its economic interpretation.
4. Obtain the dual problem of the following LPP and verify that the dual of dual problem is the
primal problem.
Maximize Z = 2x1 + 5x2 +6x3
Subject to:
5x1 + 6 x2 - x3 ≤ 3
-2x1 + x2 +4 x3 ≤ 4
x1 - 5 x2 + 3 x3 ≤ 1
-3x1 -3 x2 + 7x3 ≤ 6
x1, x2, x3 ≥ 0
9. Solve both the primal and dual problem of the following LPP
Maximize Z = 3 x1 + 2 x2
Subject to: 2x1 + x2 ≤ 5
x1 + x2 ≤ 3
x1, x2 ≥ 0
10. Solve both the primal and dual problem of the following LPP
Maximize Z = x1 + 6 x2
Subject to: x1 + x2 ≥ 2
x1 + 3 x2 ≤ 3
x1, x2 ≥ 0