For
Screen Shot 2019-06-05 at 16.21.28.png
Runing the code:
% Linprog defined on min problem and Ax<=b for max problem take - objectiveFunction
%% The problem
objectiveFunction = -1 * [10 6 -8];
A = [5 -2 6; 10 4 -6];
b = [20 ;30];
%%Sloution
linprog (objectiveFunction, A,b)
I get that "Problem is unbounded." but the answer seems to be 170/3

댓글 수: 3

Torsten
Torsten 2019년 6월 5일
You forgot to include the condition x1,x2,x3 >= 0 in your problem formulation.
Harel Harel Shattenstein
Harel Harel Shattenstein 2019년 6월 5일
Where should I add them? in the matrix A?
Torsten
Torsten 2019년 6월 5일
lb = [0 0 0];
ub = [Inf Inf Inf];

댓글을 달려면 로그인하십시오.

답변 (0개)

카테고리

도움말 센터 및 File Exchange에서 Linear Programming and Mixed-Integer Linear Programming에 대해 자세히 알아보기

태그

질문:

2019년 6월 5일

댓글:

2019년 6월 5일

Community Treasure Hunt

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

Start Hunting!

Translated by