John lives in a warm country. He has just 30 square meters of land. He can plant cocoa and pineapples. How much of pineapple and cocoa he has to plant in his plot to get maximum profit? This is a classical problem. It can be solved with graphs.
Let x stand for the amount of cocoa and y for the amount of pineapple. When john harvests the crops, he will get a unit return of 3 dollars on the cocoa and of 2 dollars on the pineapples. His total return p will be p = 3x+2y ----(1)
The profit p, we want to maximize. Planting comes with a cost. The unit cost of cocoa seed is 2 dollars and of pineapple, the seed is 1 dollar. Also, 4 dollars is required to cultivate both the crops in his land.
Hence, the total cost c of growing the two crops is c = 2x+y+4 -----(2)
John has only 50 dollars in the bank. That is the first constraint. We write it mathematically as
c= 2x+y+4 < 50 ---(3) constraint I
The size of the field also provides the second constraint. The amount of space taken up by unit cocoa is one square meter and unit pineapple also takes one square meter land. The total amount of space s taken up by the two crops is s=x+y -----(4)
The size of the plot is 30 square meters. So s cannot exceed this value. s=x+y < 50 ----(5) constraint -----II
It is clear that x and y both need to be greater than zero. They cannot be negative.
Solution:
Take quantities of cocoa on the x-axis and that of pineapple on the y-axis. Convert the inequality (3) into an equation such as y = -2x+46 and plot the straight line for the equation in the graph. The points (x,y) that satisfy the inequality 3 are underneath that line (shaded area).
Next, we will convert inequality (5) into an equation y = -x+30 and also plot the straight line for it.
"P is always maximized at one of the corner points of the shaded region". Here p is maximized at the corner point M.
At M; x = 16, y = 14
hence p=3x+2y =3*16+2*14 =76
76 dollars, maximum profit for 16 units of cocoa, and 14 units of pineapple. At other corner points, the p is smaller. You can verify yourself. The problem is solved.
This method will work out when the equations are linear. That is, the x and y should not have powers. Hence this process is called "linear programming".
This method can be extended to work with more constraints (shaded region bounded by more lines) and also to work when more than two variables (crops) are involved. The extended method is called the "simplex algorithm" invented by George Dantzig. It has a wide variety of applications.
A company makes many models of smartphones. How much quantity, the company has to manufacture in each model to maximize the profit? How to minimize the raw materials required? The simplex algorithm will answer this kind of question.
Comments
Post a Comment