필터 지우기
필터 지우기

Does function linprog by interior point method have crossover process to obtain a basic solution?

조회 수: 2 (최근 30일)
Greetings,
Currently, I am working on a linear programming problem. I used function linprog to solve it. However, I found if I specified either using interior point method or dual simplex method, I would get totally different solutions. The reason is the existence of multiple optimal solutions.
As we know, dual simplex method gives a vertex solution. How about interior point method? If interior point method has crossover process, I should get a vertex solution (basic solution). If it has not, I will get a inner point of the hyperplane of constraints.
Does function linprog by interior point method have crossover process to obtain a basic solution?

채택된 답변

Matt J
Matt J 2019년 2월 1일
Definitely not if your Matlab version is old enough, in which case the interior-point method offered is presumably the same as what is R2018a calls interior-point-legacy. I draw this conclusion from this test,
f=-[1,1];
A=-f;
b=5;
lb=[0,0];
ub=[1,1]*b;
opts=optimoptions('linprog','Algorithm','interior-point-legacy');
x_ipl=linprog(f,A,b,[],[],lb,ub,opts)
which yields the non-basic solution,
x_ipl =
2.5000
2.5000
With the interior-point algorithm of R2018a, I always seem to get a basic solution, but don't know why.
  댓글 수: 8
Devin
Devin 2019년 2월 19일
A = [1 1; 1 2];
b = [4 5]';
z = -[2 4];
%% Matlab interior
LPoptions = optimset('Algorithm','interior-point','MaxIter',2000,'TolFun',1e-6,'display','iter');
[MBarrier,fval,exitflag,output,lambda] = linprog(z, A, b, [], [], [0 0], [], LPoptions);
%% Matlab interior legacy
LPoptions = optimset('Algorithm','interior-point-legacy','MaxIter',2000,'TolFun',1e-6,'display','iter');
[MBarrier_legacy,fval,exitflag,output,lambda] = linprog(z, A, b, [], [], [0 0], [], LPoptions);
%% Matlab dual simplex
LPoptions = optimset('Algorithm','dual-simplex','Display','final','MaxIter',2000,'TolFun',1e-6);
[MDual,fval,exitflag,output,lambda] = linprog(z, A, b, [], [], [0 0], [], LPoptions);
You are right. I did this test, it is very clear that there is no crossover process in both interior-point and interior-point-legacy. I got a non-basic solution. The basic solution should be [0; 2.5].
I have a new question. Do you know from what version of matlab, new interior-point is used to replace old interior-point (interior-point-legacy)? Because I need to repeat the results simulated by old interior-point. And these two methods give different resultes when there are multiple optimal solutions.
Thank you very much!
Matt J
Matt J 2019년 2월 19일
편집: Matt J 2019년 2월 19일
When there are multiple optimal solutions to a linear program there is no way to ensure reproducibility of one solution on a different computer or software version. Such optimization problems are numerically unstable and so there is no way, through algorithm implementation, that you can hope to guarantee a particular output.

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Get Started with Optimization Toolbox에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by