Unstoppable mosek

(O No1 Kraxtis) #1

I am using mosek under cvx in matlab. My program has integer variables and sometimes is expensive timewise ( I do not know if this is relevant). I renewed my academic license today and I noticed that although when I used to press control C the execution would stop and return a suboptimal solution, the behavior now is different(?!) and cvx ignores me and continues running, even when I spam it to stop. How can this be happening?

Is this problem solvable in cvx?
(Erling D.Andersen) #2

In general MATLAB makes it very hard for us like MOSEK to stop a program based on control c. It is an undocumented feature how to do it. See for instance


Ctrlk-c and logging in recent MATLABs is pain. Sorry to say so.

But I do not see why it should just stop working unless you upgraded MATLAB.

(O No1 Kraxtis) #3

This undocumented feature is very tough for me to understand. Could it be better to do it using cvx_slvitr ? Even when I try to set this number to something like (cvx_slvitr= 15), the solver seems to ignore it and continue without stopping. Actually is there any possible way to set some type of time-out dependent of some variable? (iterations,real time, or anything else?)

(Erling D.Andersen) #4

You migh be able to set a maximum time MOSEK will run. How you do it from CVX I do not know.

(Mark L. Stone) #5

You can use cvx_solver_settings to set MOSEK parameters to (non-default) values http://cvxr.com/cvx/doc/solver.html#advanced-solver-settings