← 2022 Paper 2
UPSC 2022 Maths Optional Paper 2 Q3c — Step-by-Step Solution
15 marks · Section A
Simplex method (basic) · Linear Programming · asked 9× in 13 yrs · Read the full method →
Question
Solve maxZ=x1+x2+x3 subject to 2x1+x2+x3≤2, 4x1+2x2+x3≤2, xi≥0 by simplex. Write dual; read dual optimum from optimal table.
Technique
Standard simplex; degenerate pivot (RHS becomes 0 during pivot); continue until all z−c≥0.
Solution
2x1+x2+x3+s1=2
4x1+2x2+x3+s2=2
Step 2 — Initial simplex tableau
| Basis | x1 | x2 | x3 | s1 | s2 | RHS |
|---|
| s1 | 2 | 1 | 1 | 1 | 0 | 2 |
| s2 | 4 | 2 | 1 | 0 | 1 | 2 |
| z−c | -1 | -1 | -1 | 0 | 0 | 0 |
Most negative: any of −1. Pick x3 (ties broken by choosing smallest index, but x3‘s column gives a cleaner pivot).
Actually let me pick x1 (smallest index).
Pivot on x1: Ratio test: s1:2/2=1, s2:2/4=1/2. s2 leaves.
New x1 row: (s2/4): (1,1/2,1/4,0,1/4,1/2).
New s1 row: s1−2⋅x1: (0,0,1/2,1,−1/2,1).
New z−c: add 1⋅x1 row: (−1+1,−1+1/2,−1+1/4,0,1/4,1/2)=(0,−1/2,−3/4,0,1/4,1/2).
Tableau:
| Basis | x1 | x2 | x3 | s1 | s2 | RHS |
|---|
| s1 | 0 | 0 | 1/2 | 1 | -1/2 | 1 |
| x1 | 1 | 1/2 | 1/4 | 0 | 1/4 | 1/2 |
| z−c | 0 | -1/2 | -3/4 | 0 | 1/4 | 1/2 |
Most negative: −3/4 at x3. x3 enters.
Ratio test: s1:1/(1/2)=2, x1:(1/2)/(1/4)=2. Tie.
Pick s1 leaving (degenerate, but either works).
Pivot on x3, row s1:
New x3 row: multiply s1 by 2: (0,0,1,2,−1,2).
New x1 row: x1−(1/4)⋅x3: (1,1/2,0,−1/2,1/2,0).
New z−c: add (3/4)⋅x3 row: (0,−1/2,0,3/2,1/4−3/4,1/2+3/2)=(0,−1/2,0,3/2,−1/2,2).
Hmm — still −1/2 for x2. Continue.
Pivot on x2: Ratio test on x2 column.
x3 row x2-coeff =0: skip.
x1 row x2-coeff =1/2, ratio 0/(1/2)=0. x1 leaves.
But ratio 0 means a degenerate pivot — Bland’s rule typically prevents cycling.
Hmm actually if x1 has x2-coefficient 1/2 and RHS =0 in the x1 row (after last pivot), then ratio =0. The pivot will keep things at x1=0 but introduce x2 into the basis. The objective doesn’t increase.
Let me re-examine: after the second pivot, do I have RHS=0 for x1 row? Yes: x1 row is (1,1/2,0,−1/2,1/2,0) with RHS 0.
OK this means x1=0 now (degenerate). The current solution is x1=0,x2=0,x3=2,s1=0,s2=0, with Z=0+0+2=2.
But there’s still room to improve: −1/2 in z−c for x2. Pivot:
New x2 row: multiply x1 row by 2: (2,1,0,−1,1,0).
New x3 row: x3−0⋅x2: (0,0,1,2,−1,2) (unchanged).
New z−c: add (1/2)⋅x2 row: (0+1,−1/2+1/2,0,3/2−1/2,−1/2+1/2,2+0)=(1,0,0,1,0,2).
All z−c≥0 ⇒ optimal.
Tableau:
| Basis | x1 | x2 | x3 | s1 | s2 | RHS |
|---|
| x2 | 2 | 1 | 0 | -1 | 1 | 0 |
| x3 | 0 | 0 | 1 | 2 | -1 | 2 |
| z−c | 1 | 0 | 0 | 1 | 0 | 2 |
x2=0,x3=2,x1=0. Z=0+0+2=2.
Primal optimum: x1=0,x2=0,x3=2,Z=2.
Step 3 — Dual
Primal: max Z=x1+x2+x3, two ≤ constraints, x≥0.
Dual: min W=2y1+2y2, three ≥ constraints (one per primal variable), y≥0.
Constraints:
- 2y1+4y2≥1 (from x1).
- y1+2y2≥1 (from x2).
- y1+y2≥1 (from x3).
Step 4 — Read dual optimum from primal optimal tableau
Dual values = z−c row entries at slack-variable columns:
- y1∗=1 (at s1).
- y2∗=0 (at s2).
Dual optimum: y1=1,y2=0,W=2(1)+2(0)=2 ✓ (matches Z=2, strong duality).
Step 5 — Verify dual feasibility
- 2(1)+4(0)=2≥1 ✓.
- 1+2(0)=1≥1 ✓ (binding).
- 1+0=1≥1 ✓ (binding).
Complementary slackness: bindings 2 and 3 correspond to nonzero primal variables x2,x3? But x2=0 in optimum. Hmm, primal degenerate.
Actually the primal optimum is at vertex x1=x2=0,x3=2 where only x3 is positive — so only dual constraint 3 needs to bind. Constraint 2 binding is consistent (degenerate vertex with multiple optimal vertices possible).
Answer
Primal: x3=2,Z=2;Dual: y1=1,y2=0,W=2.