How can i minimize

1 visualización (últimos 30 días)
Jeffrey Eiyike
Jeffrey Eiyike el 23 de Jun. de 2016
Respondida: Titus Edelhofer el 24 de Jun. de 2016
min h
45<= x1 + u1 -u3 -u4 <= 45 + h100
40<= x2 + u2 -u3 +u4 <= 40 + h100
80<= x3 + u3 <= 80 + h100
u1,u2,u3,u4 >= 0
u1<= 170 ,u2<= 50 , u3<= 100, u4<= 70
  1 comentario
Torsten
Torsten el 24 de Jun. de 2016
What does h100 mean ? How is it related to h ?
Best wishes
Torsten.

Iniciar sesión para comentar.

Respuestas (4)

Titus Edelhofer
Titus Edelhofer el 23 de Jun. de 2016
Hi Jeffrey,
there is probably some missing information. I guess it's clear that h>=0. Since there are no restrictions on x1, x2, x3, you might choose
u1 = 0; u2 = 0; u3 = 0; u4 = 0;
x1 = 45; x2 = 40; x3 = 80;
=>
h = 0;
is the optimal solution... ? Or am I missing something?
Titus
  1 comentario
Jeffrey Eiyike
Jeffrey Eiyike el 23 de Jun. de 2016
I am suppose to minimise h .

Iniciar sesión para comentar.


Jeffrey Eiyike
Jeffrey Eiyike el 23 de Jun. de 2016
That's the question on the jpg

Titus Edelhofer
Titus Edelhofer el 24 de Jun. de 2016
Hi Jeffrey,
I'm not sure I fully understand. If u1, u2, u3, u4 and x (=x1,x2,x3) are given, the computing lambda is trivial. There is still some information missing.
Titus
  1 comentario
Jeffrey Eiyike
Jeffrey Eiyike el 24 de Jun. de 2016
u1<= 170 ,u2<= 50 , u3<= 100, u4<= 70 and x1= 130 x2= 120 x3= 150

Iniciar sesión para comentar.


Titus Edelhofer
Titus Edelhofer el 24 de Jun. de 2016
Hi Jeffrey,
if I'm not mistaken, this should work:
% let the vector of unknowns be [u1 u2 u3 u4 lambda], then we
% have the following inequalities:
% u1 -u3 -u4 -lambda*100 <= 45-x1
% -u1 +u3 +u4 <= -45+x1
% and likewise for the other two
% in matrix form A*x<=b we have:
A = [ ...
1 0 -1 -1 -100;
0 1 -1 1 -100;
0 0 1 0 -100;
-1 0 1 1 0;
0 -1 1 -1 0;
0 0 -1 0 0];
% where b is:
b = [45-130; 40-120; 80-150; -45+130; -40+120; -80+150];
% now solve for the unknowns: we don't care about u1, u2, u3, u4 but lambda should be small:
uLambda = linprog([0;0;0;0;1], A, b, [], [], [0;0;0;0;0], [170;50;100;70;inf])
% extract lambda
lambda = uLambda(5);
Titus

Categorías

Más información sobre Solver Outputs and Iterative Display en Help Center y File Exchange.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by