Solves a pure IPP by adding constraints (cuts) to the LP relaxation’s optimal tableau that exclude the fractional solution without excluding any feasible integer solution.
Fractional Cut
For a basic variable xi with a fractional value in the optimal tableau’s row:
xi+j∑aijxj=bi
Split each coefficient into integer and fractional parts, aij=⌊aij⌋+fij and bi=⌊bi⌋+fi (with 0≤fij,fi<1). The Gomory constraint is:
j∑fijxj≥fi
Steps
Solve the LP relaxation with simplex.
If every basic variable is integral, stop. The solution is optimal for the IPP.
Otherwise, pick a row with a fractional basic variable and derive its Gomory constraint.
Add the constraint (as a new row with a surplus variable) to the tableau and resolve with the dual simplex method, since the new RHS is negative.
Repeat until every basic variable is integral.
Worked Example
Same LP as the branch and bound worked example: maximize Z=2x1+3x2 subject to x1+x2≤5, 2x2≤7, x1,x2≥0 and integer, with LP relaxation optimum x1=1.5, x2=3.5, Z=13.5.
Standard form: x1+x2+s1=5, x2+0.5s2=3.5.
Optimal tableau rows, basis x1,x2:
x1+s1−0.5s2=1.5x2+0.5s2=3.5
The x1 row has b1=1.5, so f1=0.5. Its coefficients split as f1,s1=0 (since 1 is already an integer) and f1,s2=0.5 (since −0.5=⌊−0.5⌋+0.5).
Gomory constraint: 0.5s2≥0.5, i.e. s2≥1.
1 /
entering column leaving row pivot element updated this step
Basic
x1
x2
s1
s2
G
RHS
Ratio
z
0
0
2
0.5
0
13.5
x1
1
0
1
−0.5
0
1.5
x2
0
1
0
0.5
0
3.5
G
0
0
0
−0.5
1
−0.5
−0.5s2+G=−0.5 added as a new row. The tableau is still optimal
(z row non-negative) but infeasible (b=−0.5), so G leaves. Its
only negative entry is under s2, so s2 enters. Pivot on −0.5.
Basic
x1
x2
s1
s2
G
RHS
Ratio
z
0
0
2
0
1
13
x1
1
0
1
0
−1
2
x2
0
1
0
0
1
3
s2
0
0
0
1
−2
1
Every RHS is ≥0 and x1, x2, s2 are all integral. Optimal at
x1=2, x2=3, Z=13.
Step-by-step walkthrough of the simplex method on a tableau
Optimal solution: x1=2, x2=3, Z=13. Matches branch and bound.