On this page
Many marks in linear programming are lost before the graph is drawn. If a constraint is missing or the units do not match, the corner point method will find the best answer to the wrong problem. Below, a factory problem and a diet problem are formulated in full.
What does it mean to formulate a linear programming problem?
Formulating means translating the story into four pieces: decision variables, an objective function, constraints and non-negativity conditions. The NCERT Class 12 Mathematics chapter on linear programming defines a linear programming problem as one concerned with finding the maximum or minimum value of a linear function of several variables, subject to the variables being non-negative and satisfying a set of linear inequalities.
NCERT calls Z = ax + by the objective function and x, y the decision variables. The feasible region is the area common to all the constraints, including x ≥ 0, y ≥ 0.
To revise how to shade a single inequality first, start with graphing linear inequalities in Class 11.
How do you choose the decision variables?
Ask what the person in the problem is actually deciding. Profit and cost are outcomes; the variables are the quantities they control.
Write each variable as a full sentence with a unit: "Let x be the number of cricket bats made per day", not "let x be bats".
If the data come per 100 g or per hour, let the variable count those same units.
How do you write the objective function and constraints?
A workshop makes cricket bats and hockey sticks. A bat needs 40 minutes on the cutting machine and 15 minutes of finishing; a hockey stick needs 20 minutes of cutting and 30 minutes of finishing. The machine runs 8 hours a day; finishing has 6 hours a day. Profit is ₹30 per bat and ₹50 per stick. How many of each should be made to maximise profit?
Variables: let x be the number of bats and y the number of hockey sticks made per day.
Objective: maximise Z = 30x + 50y, in rupees.
Cutting: 40x + 20y ≤ 480, because 8 hours is 480 minutes. Dividing by 20 gives 2x + y ≤ 24.
Finishing: 15x + 30y ≤ 360, because 6 hours is 360 minutes. Dividing by 15 gives x + 2y ≤ 24.
Non-negativity: x ≥ 0, y ≥ 0.
The corner points are (0, 0), (12, 0), (8, 8) and (0, 12), where Z is 0, 360, 640 and 600. The maximum profit is ₹640 a day from 8 bats and 8 hockey sticks. For graphing and the corner point steps in detail, see the corner point method in CBSE Class 12.
How do you formulate a diet problem in linear programming?
According to the NEOS Guide's case study of the diet problem, George Stigler's educated guess for the cost of an optimal diet was $39.93 a year at 1939 prices. When his model was solved with the simplex method in 1947, the optimum came to $39.69.
Here is a two-food version. Food P costs ₹60 per kg and Food Q costs ₹40 per kg. Each 100 g of P has 4 units of iron and 2 units of calcium; each 100 g of Q has 1 unit of iron and 3 units of calcium. A mix must give at least 8 units of iron and 9 units of calcium at the lowest cost.
Variables: let x be the number of 100 g portions of P and y the number of 100 g portions of Q.
Objective: minimise Z = 6x + 4y, because ₹60 per kg is ₹6 per 100 g.
Iron: 4x + y ≥ 8. Calcium: 2x + 3y ≥ 9. "At least" is a floor, so use ≥.
Non-negativity: x ≥ 0, y ≥ 0.
The corner points are (0, 8), (1.5, 2) and (4.5, 0), with Z equal to 32, 17 and 27. The region is unbounded, so by NCERT's corner point rule, 17 is the minimum only if the open half-plane 6x + 4y < 17 shares no point with the region. It does not, so the cheapest mix is 150 g of P and 200 g of Q for ₹17.
What are the most common formulation mistakes?
Check these before you draw anything:
Forgetting x ≥ 0, y ≥ 0, so the region spills into negative quantities.
Writing ≤ for "at least" or ≥ for "at most".
Mixing price per kg with nutrients per 100 g, or hours with minutes.
Missing a resource. Match every limit in the story to one inequality.
Putting profit per item in a constraint instead of the objective.
Stuck on a particular question? The Fermi Problem Library has worked problems with a step-by-step solver that explains the reasoning rather than printing an answer. For the ideas underneath, such as half-planes and convex regions, the Fermi Concept Library gives each concept in mathematics its own lesson.



