GLPK の出力に必要なヘルプ。一部の制約は (意図的に) 満たすことができません。GLPK は「PROBLEM HAS NO INTEGER FEASIBLE SOLUTION」を出力しますが、解決策のステータスとして「最適」を返します。
すべての許容レベルを 0 に設定しました
glpk.options['feastol']=0
solvers.options['feastol']=0
glpk.options['abstol']=0
solvers.options['abstol']=0
glpk.options['reltol']=0
solvers.options['reltol']=0
これが出力です
GLPK Integer Optimizer, v4.43
10 rows, 5 columns, 19 non-zeros
5 integer variables, none of which are binary
Preprocessing...
1 hidden covering inequaliti(es) were detected
5 rows, 5 columns, 14 non-zeros
5 integer variables, all of which are binary
Scaling...
A: min|aij| = 1.000e+00 max|aij| = 1.000e+00 ratio = 1.000e+00
Problem data seem to be well scaled
Constructing initial basis...
Size of triangular part = 4
Solving LP relaxation...
GLPK Simplex Optimizer, v4.43
5 rows, 5 columns, 14 non-zeros
0: obj = 2.000000000e+00 infeas = 1.000e+00 (1)
* 2: obj = -2.500000000e+00 infeas = 0.000e+00 (0)
* 3: obj = -4.000000000e+00 infeas = 0.000e+00 (0)
OPTIMAL SOLUTION FOUND
Integer optimization begins...
+ 3: mip = not found yet >= -inf (1; 0)
+ 3: mip = not found yet >= tree is empty (0; 1)
PROBLEM HAS NO INTEGER FEASIBLE SOLUTION
必要な動作は、「問題に整数の実行可能な解決策がない」場合に失敗を示すことです。
ありがとう。