Purpose
Provides a simplified interface for
XPRSrepairweightedinfeas.
Synopsis
int XPRS_CC XPRSrepairinfeas (XPRSprob prob, int *p_status, char penalty, char phase2, char flags, double lepref, double gepref, double lbpref, double ubpref, double delta);
Arguments
prob
|
The current problem.
|
p_status
|
The status after the relaxation:
0
|
relaxed optimum found;
|
1
|
relaxed problem is infeasible;
|
2
|
relaxed problem is unbounded;
|
3
|
solution of the relaxed problem regarding the original objective is nonoptimal;
|
4
|
error (when return code is nonzero);
|
5
|
numerical instability;
|
6
|
analysis of an infeasible relaxation was performed, but the relaxation is feasible.
|
|
penalty
|
The type of penalties created from the preferences:
c
|
each penalty is the reciprocal of the preference (default);
|
s
|
the penalties are placed in the scaled problem.
|
|
phase2
|
Controls the second phase of optimization:
o
|
use the objective sense of the original problem (default);
|
x
|
maximize the relaxed problem using the original objective;
|
f
|
skip optimization regarding the original objective;
|
n
|
minimize the relaxed problem using the original objective;
|
i
|
if the relaxation is infeasible, generate an irreducible infeasible subset for the analys of the problem;
|
a
|
if the relaxation is infeasible, generate all irreducible infeasible subsets for the analys of the problem.
|
|
flags
|
Specifies if the tree search should be done:
g
|
do the tree search (default);
|
l
|
solve as a linear model ignoring the discreteness of variables.
|
|
lepref
|
Preference for relaxing the less or equal side of row.
|
gepref
|
Preference for relaxing the greater or equal side of a row.
|
lbpref
|
Preferences for relaxing lower bounds.
|
ubpref
|
Preferences for relaxing upper bounds.
|
delta
|
The relaxation multiplier in the second phase -1. For console use
-d value. A positive value means a relative relaxation by multiplying the first phase objective with (
delta-1), while a negative value means an absolute relaxation, by adding
abs(delta) to the first phase objective.
|
Related controls
Integer
|
Forced algorithm selection (default for repairinfeas is primal).
|
Example
READPROB MYPROB.LP
REPAIRINFEAS -a -d 0.002
This example reads in an infeasible problem and identifies a solution which violates the rows and bounds the least. It then fixes the measure of violations to this value multiplied by 1.002 to slightly increase the freedom in the problem and optimizes the relaxed problem using the original objective function.
Further information
1. This function currently does not apply to general nonlinear problems.
2. A row or bound is relaxed by introducing a new nonnegative variable that will contain the infeasibility of the row or bound. Suppose for example that row a
Tx = b is relaxed from below. Then a new variable (infeasibility breaker)
s≥0 is added to the row, which becomes a
Tx +s = b. Observe that a
Tx may now take smaller values than b. To minimize such violations, the weighted sum of these new variables is minimized.
3. A preference of 0 results in the row or bound not being relaxed.
4. A negative preference indicates that a quadratic penalty cost should be applied. This can specified on a per constraint side or bound basis.
5. Note that the set of preferences are scaling independent.
6. If a feasible solution is identified for the relaxed problem, with a sum of violations p, then the sum of violations is restricted to be no greater than (
1+delta)
p, and the problem is optimized with respect to the original objective function. A nonzero delta increases the freedom of the original problem.
7. Note that on some problems, slight modifications of delta may affect the value of the original objective drastically.
8. The default value for delta in the console is 0.001.
9. Note that because of their special associated modeling properties, binary and semi-continuous variables are not relaxed.
10. The default algorithm for the first phase is the simplex algorithm, since the primal problem can be efficiently warm started in case of the extended problem. These may be altered by setting the value of control
DEFAULTALG.
11. If
penalty is set such that each penalty is the reciprocal of the preference, the following rules are applied while introducing the auxiliary variables:
Preference |
Affects |
Relaxation |
Cost if pref.>0 |
Cost if pref.<0 |
lepref |
= rows |
aTx - aux_var = b |
1/lepref*aux_var |
1/lepref*aux_var2 |
lepref |
<= rows |
aTx - aux_var <= b |
1/lepref*aux_var |
1/lepref*aux_var2 |
gepref |
= rows |
aTx + aux_var = b |
1/gepref*aux_var |
1/gepref*aux_var2 |
gepref |
>= rows |
aTx + aux_var >= b |
1/gepref*aux_var |
1/gepref*aux_var2 |
ubpref |
upper bounds |
xi - aux_var <= u |
1/ubpref*aux_var |
1/ubpref*aux_var2 |
lbpref |
lower bounds |
xi + aux_var >= l |
1/lbpref*aux_var |
1/lbpref*aux_var2 |
12. If an irreducible infeasible set (IIS) has been identified, the generated IIS(s) are accessible through the IIS retrieval functions, see
NUMIIS and
XPRSgetiisdata.
Related topics
© 2001-2023 Fair Isaac Corporation. All rights reserved. This documentation is the
property of Fair Isaac Corporation (“FICO”). Receipt or possession of this documentation does not
convey rights to disclose, reproduce, make derivative works, use, or allow others to use it except
solely for internal evaluation purposes to determine whether to purchase a license to the software
described in this documentation, or as otherwise set forth in a written software license agreement
between you and FICO (or a FICO affiliate). Use of this documentation and the software described in
it must conform strictly to the foregoing permitted uses, and no other use is permitted.