Deriving constraints in linear programming can be a consuming affair. The question must be properly read and understood. Below are examples of how to derive typical constraints.
Example: A factory produces two cars, A and B. Each A car requires 3 hours of labour and each B car requires 5 hours. There are 480 hours of labour available.
If the number of A cars produced is a, thenhours of labour are required to produce them.
If the number of B cars produced is b, thenhours of labour are required to produce them.
The total number of hours of labour required to producecars of type A andcars of type B isThe total number of hours available is 480, so we can write
Example: A ferry is to carry a school party on a trip. The ferry can accommodate 500. It is required that the number of children can be at most ten times the number of adults, and that there be at least ten children for every adult.
If the number of children isand the number of adults isthen since the ferry can accommodate 500, we must have
'The number of children can be at most ten times the number of adults' can be rewritten as the ten times the number of adults is greater than or equal to the number of children, allowing us to write
'There must be at least four children for every adult' can be rewritten as the number of children is at least four times the number of adults, allowing us to write
Example: Mean and women are to be picked as candidates for election. The number of female candidates is to be greater than one quarter of the number of candidates, but no more than three fifths.
If the number of female candidates isand the number of male candidates isthen the number of candidates is'The number is female candidates is greater than one quarter the number of candidates' becomes
and 'no more than three fifths' becomes