Duality
At a Glance
- Frequency: 4 sub-parts across 4 of 13 years (2019, 2021, 2024, 2025)
- Priority tier: T3
- Marks (count): 10 (1), 15 (3)
- Average solve time: ~11 min
- Difficulty mix: medium 3, easy 1
- Section: A | Dominant type: computation
Why This Chapter Matters
Every linear program has a paired “dual” problem, and UPSC has tested three distinct uses of that pairing: forming the dual from scratch (2021), solving a problem by working through the dual (2024, 2025), and using complementary slackness to certify that a given basis is not optimal (2019). The questions carry 10–15 marks and are entirely algorithmic — there is no heavy computation, only careful bookkeeping of signs and direction. Mastering the four conversion rules (constraint type → dual variable sign, variable type → dual constraint type) and the two complementary-slackness conditions is sufficient to score full marks.
Minimum Theory
Primal–Dual Correspondence. Given a primal minimisation subject to , , the dual is subject to , . The number of dual variables equals the number of primal constraints; the number of dual constraints equals the number of primal variables. The conversion rule for mixed-constraint problems: a -constraint in a Min primal gives a dual variable ; a -constraint gives ; an equality constraint gives unrestricted. Symmetrically, a non-negative primal variable gives a dual constraint, while an unrestricted gives a equality constraint.
Weak and Strong Duality. For any primal-feasible and dual-feasible , the weak duality inequality always holds. At optimality, the strong duality theorem guarantees equality: . Consequence: if the dual is infeasible while the primal is feasible, the primal objective is unbounded (no finite optimum).
Complementary Slackness. At optimality, two conditions must hold simultaneously: (i) for each primal variable , either or the -th dual constraint is binding (); (ii) for each dual variable , either or the -th primal constraint is binding (). These conditions provide an optimality test: given a candidate primal basis, read off the implied by setting binding dual constraints to equality; if any remaining dual constraint is violated, the basis is not optimal.
Question Archetypes
| Archetype | Recognition |
|---|---|
| solve-via-dual | ”solve using duality principle” — dual has two variables, solved graphically |
| duality-optimality-check | ”use the dual to verify a basic solution is not optimal” |
| form-dual | ”convert to dual” / “write the dual” of a given LPP |
solve-via-dual (2 question(s); 2024, 2025)
Recognition Cues — The question phrase is “using the duality principle, solve…” or “apply the principle of duality to solve…”. The primal usually has three or more variables (hard to solve graphically) but only two constraints, so the dual has only two variables and can be solved graphically. Be alert for the case where the dual is infeasible — that signals the primal is unbounded, which is itself the answer.
Solution Template
- Write the primal in standard form for duality. For a Min problem with constraints, keep as-is. For a Max problem with constraints, keep as-is. For mixed constraints, convert to by multiplying by .
- Pair each primal constraint with a dual variable , each primal variable with a dual constraint. Write the dual objective and constraints.
- Solve the dual (typically a 2-variable LP) graphically: find all vertices of the dual feasible region, evaluate the objective at each, identify the optimum.
- If the dual is infeasible, invoke the duality theorem: primal is unbounded. Stop.
- Otherwise, at the dual optimum , apply complementary slackness to recover the primal optimum: a slack dual constraint forces the corresponding primal variable to zero; a positive dual variable forces the corresponding primal constraint to be binding. Solve the resulting system.
- Verify: primal objective dual objective at the recovered solution.
Worked Example(s)
2024 Paper 2, 2024-P2-Q3c (15 marks)
Using the duality principle, solve: subject to , , .
Step 1 — Form the dual. Primal is Min with constraints; dual is Max with constraints. With dual variables :
subject to:
Step 2 — Solve the dual graphically. The third constraint is the most restrictive. Enumerate vertices of the feasible region:
- : .
- (intersection of with ): check ✓, ✓. So .
- (intersection of with ): check ✓, ✓. So .
- Intersections of with the other two constraints give — infeasible.
Maximum of is 8 at .
Step 3 — Recover primal via complementary slackness. By strong duality, .
At :
- Dual constraint 1: (slack) .
- Dual constraint 2: (slack) .
- : primal constraint 2 must be binding: .
- Check primal constraint 1: ✓ (slack, consistent with ).
2025 Paper 2, 2025-P2-Q3c (15 marks)
Apply the principle of duality to solve: Maximize subject to , , , .
Step 1 — Standard form. Multiply the constraint by :
Step 2 — Write the dual. Dual variables ; dual of a max- primal is min-:
subject to:
Step 3 — Dual is infeasible. The second dual constraint requires . Since , the left side is . No feasible point exists — the dual is infeasible.
Step 4 — Apply duality theorem. The primal is feasible (e.g., satisfies all constraints). A feasible primal with an infeasible dual is unbounded.
Confirmation. Take , : constraints ✓, ✓, ✓; objective .
Common Traps
- Dual direction. For a Min primal with constraints, the dual is a Max with constraints (and vice versa). Mixing these up flips the feasible region.
- Complementary slackness has two parts. Slack dual constraint forces primal variable to zero; positive dual variable forces primal constraint to bind. Both must be used to recover all primal variables.
- Dual infeasibility signals primal unboundedness — do not try to iterate the primal simplex when this happens.
- Mis-transposing the dual. Each column of becomes a row of the dual constraint matrix. Number of dual variables = number of primal constraints; number of dual constraints = number of primal variables.
duality-optimality-check (1 question(s); 2019)
Recognition Cues — The question provides a specific basic solution (naming which variables are basic) and asks you to “use the dual” or “verify using the dual” that it is or is not optimal. The primal typically has equality constraints (so dual variables are unrestricted in sign).
Solution Template
- Identify the candidate basic variables. Set nonbasic variables to zero and solve for the basic values. Confirm feasibility.
- Write the dual. Equality primal constraints → unrestricted dual variables. Inequality constraints → sign-restricted dual variables.
- Use complementary slackness: since basic variables , their corresponding dual constraints must be binding. Solve this system for the implied dual point .
- Check dual feasibility: verify all remaining dual constraints (for the nonbasic variables) are satisfied at .
- If any dual constraint is violated, the basis is not optimal. State the certificate: which constraint is violated, and what the positive reduced cost is.
Worked Example(s)
2019 Paper 2, 2019-P2-Q4d (10 marks)
Use the dual problem to verify that the basic solution is not optimal for: subject to , , .
Step 1 — The candidate basic solution. With : , . Subtract: , . Both positive, so this is a feasible basis with .
Step 2 — Form the dual. Equality constraints → dual variables are unrestricted. Dual of a max-equality primal is min- (unrestricted ):
Step 3 — Implied dual point. Basic variables and force their dual constraints to be binding:
Subtract: , .
Step 4 — Test dual feasibility. Check the nonbasic-variable constraints:
- constraint: ? We have . Violated.
- constraint: ? ✓.
Step 5 — Certificate. The dual solution induced by basis violates . Equivalently, the reduced cost of is — a positive reduced cost in maximisation means should enter the basis.
Common Traps
- Equality constraints give unrestricted dual variables. Do not impose when the primal has equality constraints. The dual constraints still apply, but itself is free.
- The certificate is dual infeasibility. Non-optimality is proved by showing the dual point implied by the basis fails at least one dual constraint — not merely by arguing the objective could be larger.
- Reduced cost interpretation. The violated dual constraint is exactly a positive reduced cost , confirming entering the basis would increase .
form-dual (1 question(s); 2021)
Recognition Cues — The question asks to “convert to dual” or “write the dual” of a given LPP. The primal has a mix of , , and/or constraints; some primal variables may be unrestricted. The core task is to apply the conversion table without error.
Solution Template
- Identify the primal direction (Min or Max) and list each constraint type (, , ) and each variable type ( or unrestricted).
- Apply the conversion table:
| Primal (Min) | Dual (Max) |
|---|---|
| constraint | |
| constraint | |
| constraint | unrestricted |
| dual constraint | |
| unrestricted | dual constraint |
- Write the dual objective: (for a Min primal).
- Write one dual constraint per primal variable using the transposed coefficient matrix .
- State the sign restrictions on each dual variable from step 2.
Worked Example(s)
2021 Paper 2, 2021-P2-Q3c (15 marks)
Convert to dual: subject to , , ; , unrestricted.
Step 1 — Constraint types. Constraint 1 is → . Constraint 2 is → . Constraint 3 is → unrestricted.
Step 2 — Variable types. → dual constraints of the form. unrestricted → dual constraint of the form.
Step 3 — Dual objective.
Step 4 — Dual constraints (transpose the coefficient columns of ):
- For (coefficients ): .
- For (coefficients ): .
- For (coefficients , unrestricted): .
Common Traps
- Sign of dual variable depends on Min vs Max direction. For a Min primal, a -constraint gives (not ). This is the most frequent error — students apply the Max-primal table to a Min problem.
- Equality constraint → unrestricted dual variable, not or .
- Unrestricted primal variable → equality dual constraint, not an inequality.
- There are dual variables (one per primal constraint) and dual constraints (one per primal variable). Check the counts before writing.
Marks-Aware Writing
10-mark answer (2019-style duality-optimality-check): (1) Find the basic solution values and state . (2) Write out the complete dual problem with all constraints and sign conditions. (3) Solve for the implied dual point from the two binding equations. (4) Test every remaining dual constraint; identify the violated one. (5) State the certificate: the dual constraint violated, or equivalently the positive reduced cost. Five clearly labelled steps; no prose needed beyond the conclusion sentence.
15-mark answer (form-dual or solve-via-dual): For form-dual: show the conversion table or state the rules applied; write the dual objective; list all dual constraints with workings for each transposed column; state all sign restrictions on dual variables. For solve-via-dual: form the dual with full justification; enumerate all vertices of the dual feasible region (show feasibility checks); identify the optimum; apply complementary slackness step-by-step to recover each primal variable; verify with the primal objective. Either type needs six to eight lines of algebra clearly laid out.
Practice Set
- 2015-P2-Q4c (20 m) — — Hint: form the dual of a mixed-constraint Min LPP; track sign restrictions carefully.
- 2022-P2-Q3c (15 m) — — Hint: solve via dual graphically; use complementary slackness to recover the primal solution.