The MOSEK Python optimizer API manual Version 7.0 (Revision 141)

Optimizer API for Python - Documentation - Mosek Optimizer API for Python - Documentation - Mosek

25.11.2015 Views

242 APPENDIX A. API REFERENCE Description: Let (s x n) ∗ be the value of variable (s x n) for the specified solution. For simplicity let us assume that s x n is a member of quadratic cone, then the violation is computed as follows { max(0, ‖(s x n ) 2;n ‖ ∗ − (s x n) ∗ 1)/ √ 2, (s x n) ∗ ≥ − ‖(s x n) ∗ 2:n‖ , ‖(s x n) ∗ ‖ , otherwise. Both when the solution is a certificate of primal infeasibility or when it is a dual feasibible solution the violation should be small. A.2.70 Task.getdviolvar() Task.getdviolvar( whichsol, sub, viol) Computes the violation of a dual solution associated with a set of x variables. Arguments sub : int[] An array of indexes of x variables. viol : double[] viol[k] is the maximal violation of the solution for the constraints (s x l ) sub[k] (s x u) sub[k] ≥ 0. whichsol : soltype Selects a solution. ≥ 0 and Description: The violation fo dual solution associated with the j’th variable is computed as follows where max(ρ((s x l ) ∗ i , (b x l ) i ), ρ((s x u) ∗ i , −(b x u) i ), | ∑ j = 0 numcon−1 a ij y i + (s x l ) ∗ i − (s x u) ∗ i − τc j |) { − x, l > −∞, ρ(x, l) = |x|, otherwise τ = 0 if the the solution is certificate of dual infeasibility and τ = 1 otherwise. The formula for computing the violation is only shown for linear case but is generalized approriately for the more general problems.

A.2. CLASS TASK 243 A.2.71 Task.getinfeasiblesubproblem() inftask = Task.getinfeasiblesubproblem(whichsol) Obtains an infeasible sub problem. Arguments inftask : Task A new task containing the infeasible subproblem. whichsol : soltype Which solution to use when determining the infeasible subproblem. Description: See also Given the solution is a certificate of primal or dual infeasibility then a primal or dual infeasible subproblem is obtained respectively. The subproblem tend to be much smaller than the original problem and hence it easier to locate the infeasibility inspecting the subproblem than the original problem. For the procedure to be useful then it is important to assigning meaningful names to constraints, variables etc. in the original task because those names will be duplicated in the subproblem. The function is only applicable to linear and conic quadrtic optimization problems. For more information see Section 13.2. • iparam.infeas prefer primal Controls which certificate is used if both primal- and dualcertificate of infeasibility is available. • Task.relaxprimal Deprecated. A.2.72 Task.getinti() Task.getinti( whichsol, sub, inti) Deprecated. Arguments inti : double[] inti[i] contains integer infeasibility of variable sub[i].

A.2. CLASS TASK 243<br />

A.2.71<br />

Task.getinfeasiblesubproblem()<br />

inftask = Task.getinfeasiblesubproblem(whichsol)<br />

Obtains an infeasible sub problem.<br />

Arguments<br />

inftask : Task<br />

A new task containing the infeasible subproblem.<br />

whichsol : soltype<br />

Which solution to use when determining the infeasible subproblem.<br />

Description:<br />

See also<br />

Given the solution is a certificate of primal or dual infeasibility then a primal or dual infeasible<br />

subproblem is obtained respectively. <strong>The</strong> subproblem tend to be much smaller than the original<br />

problem and hence it easier to locate the infeasibility inspecting the subproblem than the original<br />

problem.<br />

For the procedure to be useful then it is important to assigning meaningful names to constraints,<br />

variables etc. in the original task because those names will be duplicated in the subproblem.<br />

<strong>The</strong> function is only applicable to linear and conic quadrtic optimization problems.<br />

For more information see Section 13.2.<br />

• iparam.infeas prefer primal Controls which certificate is used if both primal- and dualcertificate<br />

of infeasibility is available.<br />

• Task.relaxprimal Deprecated.<br />

A.2.72<br />

Task.getinti()<br />

Task.getinti(<br />

whichsol,<br />

sub,<br />

inti)<br />

Deprecated.<br />

Arguments<br />

inti : double[]<br />

inti[i] contains integer infeasibility of variable sub[i].

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!