# Numeric Tolerances¶

PICOS allows you to fine-tune how accurate your solution needs to be. Tolerances fall in three categories:

• Feasibility tolerances, abbreviated fsb, control the magnitude of constraint violation that is tolerated. The integrality tolerance also falls into this category.

• Optimality tolerances, abbreviated opt, control the maximum allowed deviation from the mathematically exact optimum solution and serve as a termination criterion. An exception is the the Simplex algorithm that uses the dual feasibility as its stopping criterion.

• The remaining tolerances are used at intermediate steps of specific algorithms, such as the Markowitz threshold used in a pivoting strategy of the Simplex algoritm.

Solvers differ in how they measure deviations from the ideal values. Some bound absolute values while others consider the deviation in relation to the magnitude of the numbers that occur in the problem. PICOS abbreviates the former measurement with abs and the latter with rel. If both measurements are supported by a solver, then the standard approach is to allow values if they are sufficiently accurate according to either one.

If solvers use a single value for primal and dual feasibility but PICOS is configured to use differing accuracies, supplied in the options with the prim and dual abbreviations respectively, it will supply the smaller of both values to such solvers.

By default, PICOS overrides the solver’s default accuracies with common values, so that the choice of solver becomes transparent to you. Given that P is your problem instance, you can make PICOS respect the solvers’ individual choices as follows:

>>> import picos
>>> P = picos.Problem()
>>> P.options["*_tol"] = None


## Comparison Table¶

The table shows what tolerance options are supported by PICOS and each solver, and what their respective default value is.

Option

PICOS

CPLEX

CVXOPT

ECOS

GLPK

Gurobi

MOSEK

SCIP

SMCP

abs_prim_fsb_tol

unused

unused ?

unused

rel_prim_fsb_tol

unused ?

unused ?

abs_dual_fsb_tol

unused

unused ?

unused

rel_dual_fsb_tol

unused ?

unused

abs_ipm_opt_tol

unused

unused

unused

unused

rel_ipm_opt_tol

unused

abs_bnb_opt_tol

no IP

unused

no IP

rel_bnb_opt_tol

no IP

no IP

integrality_tol

no IP

unused

no IP

markowitz_tol

None

no SX

no SX

unused ?

unused

no SX

Pooled options

Legend

 ? It is unclear whether an absolute or relative measure is used, or if an option is not available. SX Linear Programs via Simplex LP Linear Programs via Interior-Point Method CP Conic Programs LQ Linear and Quadratic Programs QP Quadratic Programs QC Quadratically Constrained (Quadratic) Programs NL Nonlinear Programs IP (Mixed) Integer Programs