← 2020 Paper 2

UPSC 2020 Maths Optional Paper 2 Q1e — Step-by-Step Solution

10 marks · Section A

LPP: standard form; basic, basic feasible, optimal solutions · Linear Programming · asked 6× in 13 yrs · Read the full method →

Question

The UPSC maintenance section has purchased sufficient curtain cloth pieces; the length of each piece is 17 feet. The requirement by curtain length is: length 5 ft → 700 required; length 9 ft → 400 required; length 7 ft → 300 required. The width of all curtains is the same as the available pieces. Form a linear programming problem in standard form that decides the number of pieces cut in different ways so that the total trim loss is minimum. Also give a basic feasible solution to it.

Technique

Cutting-stock (Gilmore–Gomory) formulation: decision variables = pieces cut per pattern; minimize (trimj)xj\sum(\text{trim}_j)x_j subject to demand \ge constraints; standard form via surplus + artificial variables.

Solution

This is a classic cutting-stock / trim-loss problem. Each stock piece (17 ft) can be cut into curtains of length 5,7,95,7,9 ft. A cutting pattern specifies how many of each length come from one piece.

Step 1 — Enumerate the (efficient) cutting patterns

A pattern (n5,n7,n9)(n_5,n_7,n_9) must satisfy 5n5+7n7+9n9175n_5+7n_7+9n_9\le 17. We keep the maximal patterns (those in which no further curtain of any length fits — otherwise the trim could be reduced):

Pattern55 ft (n5n_5)77 ft (n7n_7)99 ft (n9n_9)Length usedTrim loss (ft)
P1P_1001111161611
P2P_2002200141433
P3P_3110011141433
P4P_4221100171700
P5P_5330000151522

Let xj0x_j\ge 0 = number of stock pieces cut according to pattern PjP_j, j=1,,5j=1,\dots,5.

Step 2 — Objective: minimize total trim loss

min  z=1x1+3x2+3x3+0x4+2x5.\min\; z = 1\,x_1 + 3\,x_2 + 3\,x_3 + 0\,x_4 + 2\,x_5.

Step 3 — Demand constraints

Number of each curtain produced must meet the requirement (5 ft: 700, 7 ft: 300, 9 ft: 400):

5-ft:0x1+0x2+1x3+2x4+3x5700,7-ft:1x1+2x2+0x3+1x4+0x5300,9-ft:1x1+0x2+1x3+0x4+0x5400,x1,,x50.\begin{aligned} 5\text{-ft}:&\quad 0x_1+0x_2+1x_3+2x_4+3x_5 \ge 700,\\ 7\text{-ft}:&\quad 1x_1+2x_2+0x_3+1x_4+0x_5 \ge 300,\\ 9\text{-ft}:&\quad 1x_1+0x_2+1x_3+0x_4+0x_5 \ge 400,\\ &\quad x_1,\dots,x_5\ge 0. \end{aligned}

Step 4 — Standard form (surplus + artificial variables)

Convert each \ge constraint to equality by subtracting a surplus variable si0s_i\ge0. For a starting basis one also adds an artificial variable Ai0A_i\ge0 (penalised by +M+M in the objective, Big-M method). The standard form is:

min  z=x1+3x2+3x3+0x4+2x5+0(s1+s2+s3)+M(A1+A2+A3)\min\; z = x_1+3x_2+3x_3+0x_4+2x_5+0(s_1+s_2+s_3)+M(A_1+A_2+A_3)

subject to

x3+2x4+3x5s1+A1=700,x1+2x2+x4s2+A2=300,x1+x3s3+A3=400,xj0,si0,Ai0.\begin{aligned} x_3+2x_4+3x_5 - s_1 + A_1 &= 700,\\ x_1+2x_2+x_4 - s_2 + A_2 &= 300,\\ x_1+x_3 - s_3 + A_3 &= 400,\\ x_j\ge0,\quad s_i\ge0,\quad A_i\ge0. \end{aligned}

Equivalently, in matrix form mincx\min\, c^\top x s.t. Ax=b, x0Ax=b,\ x\ge0 with

A=[001231201010100],b=[700300400],c=[13302]A=\begin{bmatrix}0&0&1&2&3\\1&2&0&1&0\\1&0&1&0&0\end{bmatrix},\quad b=\begin{bmatrix}700\\300\\400\end{bmatrix},\quad c=\begin{bmatrix}1\\3\\3\\0\\2\end{bmatrix}

(before adding surplus/artificial columns).

Step 5 — A basic feasible solution

The constraints are three \ge inequalities in five nonnegative variables. A BFS in standard form has at most 33 (= number of constraints) basic variables.

A convenient feasible point using only patterns that directly supply the larger curtains. Use P5P_5 (three 5-ft each) for the 5-ft demand, P2P_2 (two 7-ft each) for the 7-ft demand, P1P_1 (one 9-ft each) for the 9-ft demand:

x5=7003 ⁣LP=7003,x2=3002=150,x1=400,x3=x4=0.x_5=\left\lceil\tfrac{700}{3}\right\rceil\!\Big|_{\text{LP}}=\tfrac{700}{3},\qquad x_2=\tfrac{300}{2}=150,\qquad x_1=400,\qquad x_3=x_4=0.

Check (LP allows fractional pieces):

The three basic structural variables {x1,x2,x5}\{x_1,x_2,x_5\} together with the slack of the slack constraint give a basic feasible solution. Its trim loss is

z=1400+3150+27003=400+450+14003=850+14003=395031316.7 ft.z=1\cdot 400+3\cdot 150+2\cdot\tfrac{700}{3}=400+450+\tfrac{1400}{3}=850+\tfrac{1400}{3}=\tfrac{3950}{3}\approx 1316.7\text{ ft}.

Answer

  BFS: (x1,x2,x3,x4,x5)=(400,150,0,0,7003),  z=39503 ft of trim.  \boxed{\;\text{BFS: } (x_1,x_2,x_3,x_4,x_5)=\big(400,\,150,\,0,\,0,\,\tfrac{700}{3}\big),\ \ z=\tfrac{3950}{3}\text{ ft of trim.}\;}
We post more of this — worked solutions, CSAT trap breakdowns, guide chapters — a few times a week on Telegram. Free, no sign-in. Join

This solution is part of the Maths Coverage Map — 13 years, mapped. Get the take-away PDF free.