We are looking for maximum of the function
Q(x, y) = x y − x − y + 1
subject to the constraint
px + qy = B ,
as well as the additional constraints x ≥1 and y ≥1. We use the method of Lagrange multipliers, which results in the set of equations
y − 1 = pλ
x − 1 = qλ
px + q y = B .
Substituting the first two equations into the third one yields
We also have to check that this solution satisfies the additional constraints x≥ 1 and y≥ 1 and that there are no extrema on the edge, that is with x = 1 or y = 1. First we note that
Q(1, y) = y − 1 − y + 1 = 0 and
Q(x, 1) = x − x − 1 + 1 = 0 ,
while Q(x0 , y0 ) ≥ 0, provided p > 0 and q > 0. We see that we need some additional assumptions on p, q and B. Since p and q are prices of cotton and wool respectively, it makes sense to assume that p > 0 and q > 0. The conditions x ≥ 1 and y ≥ 1 express that we want to buy at least one pound each of cotton and wool; in order to be able to afford this, we need B ≥ p + q. So we make the following assumptions
p > 0 , q > 0 and B ≥ p + q .
With these assumptions it is easy to check that x0 ≥1 and y0 ≥ 1 as well as Q(x0 , y0 )≥ 0. This means that we have indeed found a maximum satisfying the required constraints
Therefore most cloth can be produced by buying
pounds of wool and
of cotton yielding
pounds of cloth