Analysis and hypothesis of the problem: Analysis: The key of the problem lies in the rational distribution of the two drinks under the condition of limiting the output of the two drinks, so as to achieve the most profitable effect. Basic assumption: the distribution of raw materials for producing 1 beverage is mutually restricted. The distribution of the number of workers producing these two drinks is mutually restrictive. The output of a beverage shall not exceed 800 cases. Symbol: x 1-100 box is used to produce beverage A x2-100 box is used to produce beverage B shape: 1. The total amount of raw materials used in drinks A and B should not exceed 60kg. 2. The total number of workers producing two kinds of drinks A and B cannot exceed 150. 3. The production quantity of beverage A shall not exceed 800 cases. 4. Profit maximization, which is an objective programming model. The objective function MAX Z0= 10x 1+9x2 constraint function S. T6x1+5x2 ≤ 6010x/+20x2 ≤/kloc-. 0≤x 1≤8, x2≥0( 1) If the raw material increases 1 kg, the linear objective programming function is established as follows: objective function max z1=10x1+9x2-0.8 constraint. 38+0+20x2 ≤ 1 500 ≤ x1≤ 8, X2 ≥ 0 Compare the size of z0 and Z 1 (2) If the profit per 100 box of A beverage can be increased by110,000 yuan, Then the linear objective programming function is established as follows: the objective function maxz2 =11+9x2 constraint function s.t6x65438x1+20x2 ≤1500 ≤ x1≤ 8. a =[6 5; 10 20; 1 0]; b =[60; 150; 8]; aeq =[]; beq =[]; vlb =[0; 0]; vub =[]; [x, fval] = linprog (c, a, b, aeq, beq, vlb, vub) problem1:c = [-10-9]; a =[6 5; 10 20; 1 0]; b =[6 1; 150; 800]; aeq =[]; beq =[]; vlb =[0; 0]; vub =[]; [x, fval] = linprog (c, a, b, aeq, beq, vlb, vub) Question 2: c = [-11-9]; a =[6 5; 10 20; 1 0]; b =[60; 150; 8]; aeq =[]; beq =[]; vlb =[0; 0]; vub =[]; [x, fval] = linprog (c, a, b, aeq, beq, vlb, vub) solution: c = [-10-9];
a =[6 5; 10 20; 1 0];
b =[60; 150; 8];
aeq =[]; beq =[];
vlb =[0; 0]; vub =[];
[x,fval]=linprog(c,A,b,Aeq,beq,vlb,vub)
Operation result: > > xxghzy 1 Optimization terminated successfully.
x =6.4286 4.2857
fval =- 102.857 1
( 1):
(2): Solution: c = [-11-9];
a =[6 5; 10 20; 1 0];
b =[60; 150; 8];
aeq =[]; beq =[];
vlb =[0; 0]; vub =[];
[x, fval] = linprog (c, a, b, aeq, beq, vlb, vub) running results:
Optimization terminated successfully. x = 8.0000 2.4000
Fval =-109.6000 It can be seen that the production plan should be changed.