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

212 APPENDIX A. API REFERENCE A.2.15 Task.chgbound() Task.chgbound( accmode, i, lower, finite, value) Changes the bounds for one constraint or variable. Arguments accmode : accmode Defines if operations are performed row-wise (constraint-oriented) or column-wise (variableoriented). finite : int If non-zero, then value is assumed to be finite. i : int Index of the constraint or variable for which the bounds should be changed. lower : int If non-zero, then the lower bound is changed, otherwise the upper bound is changed. value : double New value for the bound. Description: See also Changes a bound for one constraint or variable. If accmode equals accmode.con, a constraint bound is changed, otherwise a variable bound is changed. If lower is non-zero, then the lower bound is changed as follows: Otherwise if lower is zero, then { − ∞, finite = 0, new lower bound = value otherwise. { ∞, finite = 0, new upper bound = value otherwise. Please note that this function automatically updates the bound key for bound, in particular, if the lower and upper bounds are identical, the bound key is changed to fixed. • Task.putbound Changes the bound for either one constraint or one variable. • dparam.data tol bound inf Data tolerance threshold. • dparam.data tol bound wrn Data tolerance threshold.

A.2. CLASS TASK 213 A.2.16 Task.commitchanges() Task.commitchanges() Commits all cached problem changes. Description: Commits all cached problem changes to the task. It is usually not necessary explicitly to call this function since changes will be committed automatically when required. A.2.17 Task.deletesolution() Task.deletesolution(whichsol) Undefines a solution and frees the memory it uses. Arguments whichsol : soltype Selects a solution. Description: Undefines a solution and frees the memory it uses. A.2.18 Task.dualsensitivity() Task.dualsensitivity( subj, leftpricej, rightpricej, leftrangej, rightrangej) Performs sensitivity analysis on objective coefficients. Arguments leftpricej : double[] leftpricej[j] is the left shadow price for the coefficients with index subj[j]. leftrangej : double[] leftrangej[j] is the left range β 1 for the coefficient with index subj[j].

212 APPENDIX A. <strong>API</strong> REFERENCE<br />

A.2.15<br />

Task.chgbound()<br />

Task.chgbound(<br />

accmode,<br />

i,<br />

lower,<br />

finite,<br />

value)<br />

Changes the bounds for one constraint or variable.<br />

Arguments<br />

accmode : accmode<br />

Defines if operations are performed row-wise (constraint-oriented) or column-wise (variableoriented).<br />

finite : int<br />

If non-zero, then value is assumed to be finite.<br />

i : int<br />

Index of the constraint or variable for which the bounds should be changed.<br />

lower : int<br />

If non-zero, then the lower bound is changed, otherwise the upper bound is changed.<br />

value : double<br />

New value for the bound.<br />

Description:<br />

See also<br />

Changes a bound for one constraint or variable. If accmode equals accmode.con, a constraint<br />

bound is changed, otherwise a variable bound is changed.<br />

If lower is non-zero, then the lower bound is changed as follows:<br />

Otherwise if lower is zero, then<br />

{ − ∞, finite = 0,<br />

new lower bound =<br />

value otherwise.<br />

{<br />

∞, finite = 0,<br />

new upper bound =<br />

value otherwise.<br />

Please note that this function automatically updates the bound key for bound, in particular, if<br />

the lower and upper bounds are identical, the bound key is changed to fixed.<br />

• Task.putbound Changes the bound for either one constraint or one variable.<br />

• dparam.data tol bound inf Data tolerance threshold.<br />

• dparam.data tol bound wrn Data tolerance threshold.

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

Saved successfully!

Ooh no, something went wrong!