intlinprog stuck on Optimal objective value

8 visualizaciones (últimos 30 días)
Or Hirshfeld
Or Hirshfeld el 30 de Mzo. de 2015
Respondida: Or Hirshfeld el 26 de Abr. de 2015
Hello I'm writing a code that should find optimal solution for distribution of air pollution sensors. I'm using 'intlinprog' solver that it's best suit for mixed integer linear program. All my Variable are set to be binary (integers that limited from 0 to 1) but i have a lot of them, 20100 variables, so it take my computer time to compute solution. i ran the solver and i get after few seconds and i got only the optimal objective value and Matlab seems to keep running the solver but i waited for an hour and still nothing. also i tried to use the Control+C to stop and it didn't stop, the only way was to close Matlab which made him crash.
i wish to get the value of the variables (x column vector).
the only output line i get is:
% code
LP: Optimal objective value is -5.196264e+05
I'm using Matlab R2014a
Thank you Or Hirshfeld אור הירשפלד

Respuesta aceptada

Alan Weiss
Alan Weiss el 30 de Mzo. de 2015
You have a lot of variables. This kind of problem can take a long time. Did you leave the 'Display' option set at its default 'iter'? Eventually you should see some display.
Good luck,
Alan Weiss
MATLAB mathematical toolbox documentation
  2 comentarios
Or Hirshfeld
Or Hirshfeld el 30 de Mzo. de 2015
Editada: Or Hirshfeld el 30 de Mzo. de 2015
thank you for the fast response,
does 'iter' display mode would take more time to compute?
I tried it and it didn't show anything for about an hour
Alan Weiss
Alan Weiss el 31 de Mzo. de 2015
No, "iter" shouldn't slow things down by more than a millisecond or so.
Unfortunately, iterative display is the only way you can monitor intlinprog in R2014a. As the release notes show, output functions and plot functions were added to intlinprog in R2014b.
Sorry, but MILP can be very slow and use a lot of memory. Is there any way you can try to solve a smaller problem to double-check that your formulation is correct? You might also want to check out the documentation on tuning integer programming, though I would try tuning first on a smaller version of your problem.
Alan Weiss
MATLAB mathematical toolbox documentation

Iniciar sesión para comentar.

Más respuestas (1)

Or Hirshfeld
Or Hirshfeld el 26 de Abr. de 2015
so apparently it just take long time because it's a lot of variables and constrains I made it faster by setting CutGeneration and Heuristic to None or

Categorías

Más información sobre Get Started with Optimization Toolbox 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