• Practice
  • About 16 min
  • 5 practice questions

Formulating harder word problems: units, percentages and ratios

Turn exam-style word problems into LPPs without the usual slips: mixed units, percentages of a total, ratios, "differ by at most" conditions and profit worked out from price and cost.

If something looks wrong, please tell us.

In competitive exams the formulation is where most marks in linear programming are won or lost. The foundation course built simple constraints such as 3x + y ≤ 30 straight from a table. Exam problems hide the same structure behind minutes and hours, percentages of a mixture, ratios and phrases such as "differ by at most". This lesson collects these traps and shows a safe way through each.

Trap 1: mixed units

If one process is timed in minutes and the time available is given in hours, convert everything to the same unit before writing the inequality. Then divide the whole inequality by any common factor to keep the numbers small; dividing by a positive number does not change the sign.

Worked example 1: lamps on three machines

A workshop makes Standard lamps (x) and Deluxe lamps (y). Cutting takes 5 minutes for a Standard and 15 minutes for a Deluxe, and the cutter runs 2 hours a day. Assembly takes 30 minutes for a Standard and 20 minutes for a Deluxe, with 4 hours available. Packing takes 6 minutes for any lamp, with 1 hour available. Profit is ₹50 on a Standard and ₹60 on a Deluxe.

ProcessStandard (x)Deluxe (y)AvailableConstraint
Cutting5 min15 min2 h = 120 min5x + 15y ≤ 120, so x + 3y ≤ 24
Assembly30 min20 min4 h = 240 min30x + 20y ≤ 240, so 3x + 2y ≤ 24
Packing6 min6 min1 h = 60 min6x + 6y ≤ 60, so x + y ≤ 10

The LPP is: maximise Z = 50x + 60y subject to x + 3y ≤ 24, 3x + 2y ≤ 24, x + y ≤ 10, x ≥ 0, y ≥ 0. We solve it in lesson 3.

Trap 2: percentages of a total

"A is at least 40% of the mixture" means x ≥ 0.4(x + y), not x ≥ 0.4y. Expand and collect terms to get a linear inequality with zero on the right.

Worked example 2: a juice blend

A juice blend uses x litres of mango pulp at ₹60 a litre and y litres of orange pulp at ₹40 a litre. At least 50 litres are needed, mango must be at least 40% of the blend, and only 30 litres of mango pulp are in stock. Mango share: x ≥ 0.4(x + y), so 0.6x ≥ 0.4y, that is 3x − 2y ≥ 0. The LPP: minimise Z = 60x + 40y subject to x + y ≥ 50, 3x − 2y ≥ 0, x ≤ 30, x, y ≥ 0. The corners are (20, 30) where x + y = 50 meets 3x = 2y, (30, 20) and (30, 45), with costs ₹2400, ₹2600 and ₹3600. The cheapest blend is 20 litres of mango and 30 of orange for ₹2400, using exactly the minimum share of the dearer pulp.

Trap 3: ratios, "differ by" and "more than"

  • "x : y must not exceed 2 : 3" means x/y ≤ 2/3; multiply by 3y (positive) to get 3x ≤ 2y.
  • "x and y differ by at most 5" means |x − y| ≤ 5, which is two linear constraints: x − y ≤ 5 and y − x ≤ 5.
  • "x is more than 10" is x > 10. When x counts whole items, this is the same as x ≥ 11, which keeps the boundary in the region.
  • "Profit" means selling price minus cost per item, not the selling price.

Worked example 3: two shifts

A factory runs two shifts with x and y workers. Each shift needs more than 10 workers, the two shifts may differ by at most 5 workers, and at most 40 workers are available in all. Wages are ₹900 a shift on shift 1 and ₹1100 on shift 2 (night allowance). Constraints: x ≥ 11, y ≥ 11 (whole numbers), x − y ≤ 5, y − x ≤ 5, x + y ≤ 40. Objective: minimise Z = 900x + 1100y. If the problem also says total output needs at least 30 workers, add x + y ≥ 30.

Convert to one unit, take percentages of the whole (x + y), turn |x − y| ≤ k into two inequalities, and test every translated constraint with a pair of numbers that should pass and one that should fail.

Key takeaways: most formulation errors come from units, from taking a percentage of the wrong quantity, and from reversing a ratio. Simplify each constraint by a common factor, and check it with numbers before moving on.

Check your understanding

  1. 1. Item A takes 20 minutes and item B takes 45 minutes on a machine that is available for 6 hours. Using x of A and y of B, which constraint is correct?

    1. 20x + 45y ≤ 6
    2. 9x + 4y ≤ 72
    3. 4x + 9y ≤ 72
    4. 4x + 9y ≥ 72
    Show answer

    Answer: C. Work in one unit: 6 hours = 360 minutes, so 20x + 45y ≤ 360. Dividing by 5 gives 4x + 9y ≤ 72. Writing 6 on the right mixes minutes with hours, the commonest unit trap.

  2. 2. A mix contains x kg of wheat and y kg of barley, and wheat must be at least 30% of the mix. Which constraint is correct?

    1. 7x − 3y ≥ 0
    2. 3x − 7y ≥ 0
    3. 10x − 3y ≥ 0
    4. 7x − 3y ≤ 0
    Show answer

    Answer: A. 30% of the MIX means 30% of (x + y): x ≥ 0.3(x + y). Multiply by 10: 10x ≥ 3x + 3y, so 7x − 3y ≥ 0. 10x − 3y ≥ 0 comes from the trap x ≥ 0.3y, which takes 30% of barley instead of the whole mix.

  3. 3. The numbers x and y of workers on two shifts may differ by at most 4. How is this written as linear constraints?

    1. x − y ≤ 4 only
    2. x + y ≤ 4
    3. x − y ≥ 4 and y − x ≥ 4
    4. x − y ≤ 4 and y − x ≤ 4
    Show answer

    Answer: D. "Differ by at most 4" means |x − y| ≤ 4, which is not linear as it stands, but it is the same as −4 ≤ x − y ≤ 4, that is, x − y ≤ 4 and y − x ≤ 4. Writing only x − y ≤ 4 allows y to be much larger than x.

  4. 4. Item A sells for ₹250 and costs ₹180 to make; item B sells for ₹400 and costs ₹310. If x of A and y of B are made and sold, what is the profit to maximise?

    1. Z = 250x + 400y
    2. Z = 70x + 90y
    3. Z = 180x + 310y
    4. Z = 430x + 710y
    Show answer

    Answer: B. Profit per item = selling price − cost: 250 − 180 = ₹70 for A and 400 − 310 = ₹90 for B. So Z = 70x + 90y. Maximising revenue 250x + 400y is a different problem.

  5. 5. The ratio x : y must not be more than 2 : 3 (with y > 0). Which constraint is correct?

    1. 3x ≤ 2y
    2. 2x ≤ 3y
    3. 3x ≥ 2y
    4. 3y ≤ 2x
    Show answer

    Answer: A. x/y ≤ 2/3. Since y > 0, multiply both sides by 3y: 3x ≤ 2y. Check: x = 2, y = 3 is allowed (6 ≤ 6) and x = 3, y = 4 is not (9 ≤ 8 is false). 2x ≤ 3y would mean x/y ≤ 3/2.

Sign in to keep track of the lessons you finish.

Next lesson → Transportation and allocation problems

Privacy · Terms · Refunds · Delivery