Specify initial condition for linprog?

1 view (last 30 days)
Ahmad Abuaish
Ahmad Abuaish on 10 Aug 2022
Edited: Matt J on 12 Aug 2022
Hello there,
I am using `linprog` to solve a linear program. The solution to the program are mostly zeros. Also, I have a version of the problem with zero cost, i.e., constraint satisfaction problem, again, with mostly zeros solution. It takes 7 and 16 seconds, respectively, to solve those two problems. I figured I would set the initial condition for `linprog` to zeros as it may speed up convergence. However, it appears that for new versions of MATLAB, `linprog` stopped supporting the initial condition argument. When I pass an initial condition argument following this old api, I get the following warning:
The dual-simplex algorithm uses a built-in starting point; ignoring supplied X0.
Is there a way to set the initial condition for the `linprog` solver in another way?
Kind regards, and I look forward to hearing from you soon.

Answers (2)

Walter Roberson
Walter Roberson on 10 Aug 2022
Edited: Walter Roberson on 11 Aug 2022
Use the options to set the Algorithm to interior-point
  3 Comments
Ahmad Abuaish
Ahmad Abuaish on 11 Aug 2022
I see. Thanks for the prompt responses.

Sign in to comment.


Matt J
Matt J on 11 Aug 2022
Edited: Matt J on 11 Aug 2022
You can try adding the inequality constraint f.'*x<=f.'*x0.
  2 Comments
Matt J
Matt J on 12 Aug 2022
Edited: Matt J on 12 Aug 2022
I do not think is going to work becuase I want to start with x0=zeros(n,1)
The only reason it wouldn't work is if x0 is infeasible with respect to the other constraints.

Sign in to comment.

Products


Release

R2021a

Community Treasure Hunt

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

Start Hunting!