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

204 APPENDIX A. API REFERENCE A.2 Class Task A.2.1 Task.analyzenames() Task.analyzenames( whichstream, nametype) Analyze the names and issue an error for the first invalid name. Arguments nametype : nametype The type of names e.g. valid in MPS or LP files. whichstream : streamtype Index of the stream. Description: The function analyzes the names and issue an error if a name is invalid. A.2.2 Task.analyzeproblem() Task.analyzeproblem(whichstream) Analyze the data of a task. Arguments whichstream : streamtype Index of the stream. Description: The function analyzes the data of task and writes out a report. A.2.3 Task.analyzesolution() Task.analyzesolution( whichstream, whichsol) Print information related to the quality of the solution.

A.2. CLASS TASK 205 Arguments whichsol : soltype Selects a solution. whichstream : streamtype Index of the stream. Description: See also Print information related to the quality of the solution and other solution statistics. By default this function prints information about the largest infeasibilites in the solution, the primal (and possibly dual) objective value and the solution status. Following parameters can be used to configure the printed statistics: • iparam.ana sol basis. Enables or disables printing of statistics specific to the basis solution (condition number, number of basic variables etc.). Default is on. • iparam.ana sol print violated. Enables or disables listing names of all constraints (both primal and dual) which are violated by the solution. Default is off. • dparam.ana sol infeas tol. The tolerance defining when a constraint is considered violated. If a constraint is violated more than this, it will be listed in the summary. • Task.getpviolcon Computes the violation of a primal solution for a list of xc variables. • Task.getpviolvar Computes the violation of a primal solution for a list of x variables. • Task.getpviolbarvar Computes the violation of a primal solution for a list of barx variables. • Task.getpviolcones Computes the violation of a solution for set of conic constraints. • Task.getdviolcon Computes the violation of a dual solution associated with a set of constraints. • Task.getdviolvar Computes the violation of a dual solution associated with a set of x variables. • Task.getdviolbarvar Computes the violation of dual solution for a set of barx variables. • Task.getdviolcones Computes the violation of a solution for set of dual conic constraints. • iparam.ana sol basis Controls whether the basis matrix is analyzed in solaution analyzer. A.2.4 Task.appendbarvars() Task.appendbarvars(dim) Appends a semidefinite variable of dimension dim to the problem.

A.2. CLASS TASK 205<br />

Arguments<br />

whichsol : soltype<br />

Selects a solution.<br />

whichstream : streamtype<br />

Index of the stream.<br />

Description:<br />

See also<br />

Print information related to the quality of the solution and other solution statistics.<br />

By default this function prints information about the largest infeasibilites in the solution, the<br />

primal (and possibly dual) objective value and the solution status.<br />

Following parameters can be used to configure the printed statistics:<br />

• iparam.ana sol basis. Enables or disables printing of statistics specific to the basis solution<br />

(condition number, number of basic variables etc.). Default is on.<br />

• iparam.ana sol print violated. Enables or disables listing names of all constraints (both<br />

primal and dual) which are violated by the solution. Default is off.<br />

• dparam.ana sol infeas tol. <strong>The</strong> tolerance defining when a constraint is considered violated.<br />

If a constraint is violated more than this, it will be listed in the summary.<br />

• Task.getpviolcon Computes the violation of a primal solution for a list of xc variables.<br />

• Task.getpviolvar Computes the violation of a primal solution for a list of x variables.<br />

• Task.getpviolbarvar Computes the violation of a primal solution for a list of barx variables.<br />

• Task.getpviolcones Computes the violation of a solution for set of conic constraints.<br />

• Task.getdviolcon Computes the violation of a dual solution associated with a set of constraints.<br />

• Task.getdviolvar Computes the violation of a dual solution associated with a set of x<br />

variables.<br />

• Task.getdviolbarvar Computes the violation of dual solution for a set of barx variables.<br />

• Task.getdviolcones Computes the violation of a solution for set of dual conic constraints.<br />

• iparam.ana sol basis Controls whether the basis matrix is analyzed in solaution analyzer.<br />

A.2.4<br />

Task.appendbarvars()<br />

Task.appendbarvars(dim)<br />

Appends a semidefinite variable of dimension dim to the problem.

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

Saved successfully!

Ooh no, something went wrong!