Changes

Jump to navigation Jump to search
end
However using Gurobi actually did not help with the code performance. This is possibly due to the cost to create models for each Gurobi object. Gurobi is indeed the best commercial solver in the market, but it should be used for solving large LPs (hundreds of thousands of constraints), where as our Lp has only a few thousands constraints. We reversed back to using Matlab's native linprog: % Parallelly solve Solve LPs in parallel with Matlab's native linprog
parfor r = 1 : R
options = optimset('Display', 'off');
[asgr(:, r), ~, eflag(r)] = linprog(f(:, r), [B;-B], [constrB; constrM], [], [], zeros(L, 1), ones(L,1),options);
end

Navigation menu