Skip to content

Commit

Permalink
Add more tests
Browse files Browse the repository at this point in the history
  • Loading branch information
odow committed Nov 16, 2021
1 parent 8423174 commit b8df0b5
Showing 1 changed file with 14 additions and 5 deletions.
19 changes: 14 additions & 5 deletions docs/src/background/infeasibility_certificates.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,15 +61,16 @@ and the dual is a minimization problem in standard conic form:

## Unbounded models

If a model is unbounded, then two things are true:
If a model is unbounded, two things are true:
1. there exists a feasible primal solution
2. the dual is infeasible.

A feasible primal solution---if one exists---can be obtained by setting
[`ObjectiveSense`](@ref) to `FEASIBILITY_SENSE` and then optimizing. Therefore,
most solvers terminate after they prove the dual is infeasible via a certificate
of dual infeasibility. This is also the reason that MathOptInterface defines the
`DUAL_INFEASIBLE` status instead of `UNBOUNDED`.
of dual infeasibility, but _before_ they have found a feasible primal solution.
This is also the reason that MathOptInterface defines the `DUAL_INFEASIBLE`
status instead of `UNBOUNDED`.

A certificate of dual infeasibility is an improving ray of the primal problem.
That is, there exists some vector ``d`` such that for all ``\eta > 0``:
Expand All @@ -83,14 +84,18 @@ a_0^\top (x + \eta d) + b_0 < a_0^\top x + b_0,
for any feasible point ``x``. The latter simplifies to ``a_0^\top d < 0``. For
maximization problems, the inequality is reversed, so that ``a_0^\top d > 0``.

If the solver has found a certificate of infeasibility:
If the solver has found a certificate of dual infeasibility:

* [`TerminationStatus`](@ref) must be `DUAL_INFEASIBLE`
* [`PrimalStatus`](@ref) must be `INFEASIBILITY_CERTIFICATE`
* [`VariablePrimal`](@ref) must be the corresponding value of ``d``
* [`ObjectiveValue`](@ref) must be the value ``a_0^\top d``. Note that this is
the value of the objective function at `d`, ignoring the constant `b_0`.

!!! note
The choice of whether to scale the ray ``d`` to have magnitude `1` is left
to the solver.

## Infeasible models

A certificate of primal infeasibility is an improving ray of the dual problem.
Expand Down Expand Up @@ -118,6 +123,10 @@ If the solver has found a certificate of infeasibility:

* [`TerminationStatus`](@ref) must be `INFEASIBLE`
* [`DualStatus`](@ref) must be `INFEASIBILITY_CERTIFICATE`
* [`ConstraintPrimal`](@ref) must be the corresponding value of ``d``
* [`ConstraintDual`](@ref) must be the corresponding value of ``d``
* [`DualObjectiveValue`](@ref) must be the value
``\sum_{i=1}^m b_i^\top d_i``.

!!! note
The choice of whether to scale the ray ``d`` to have magnitude `1` is left
to the solver.

0 comments on commit b8df0b5

Please sign in to comment.