Bland pivoting rule Created 2026-10-07 Updated 2026-10-14
For a maximization simplex dictionary, choose the smallest-index nonbasic variable with positive reduced cost to enter. Among basic variables attaining the minimum feasible ratio, choose the smallest-index one to leave. This fixed index rule prevents cycling, including in degenerate pivots whose step length is zero. It need not minimize the number of pivots on a particular instance.
Cutting-plane method 2026-10-06
A cutting-plane method repeatedly adds valid inequalities that exclude a current relaxed solution while preserving all feasible integer solutions. Gomory fractional cuts provide such inequalities from a fractional simplex dictionary.
Dual feasibility 2026-10-14
For minimization with constraints , , a dual-feasible vector obeys , so is a lower bound on every primal-feasible objective value. For a simplex dictionary with basis matrix , the associated vector is . Its basic reduced costs are zero and its nonbasic reduced costs are . Thus nonnegative reduced costs are exactly dual feasibility in this minimization convention; basic primal values may still be negative, as in the dual simplex algorithm.
Greatest improvement pivot rule 2026-10-14
For a feasible simplex dictionary, let be a nonbasic variable's improving reduced cost and let be its largest feasible increase from the simplex ratio test. The greatest improvement pivot rule chooses an entering variable maximizing . It measures the improvement over the entire edge, whereas the Dantzig pivot rule maximizes only .
// Target: mathematical-optimization.bigb
Past exam of the mathematics course of the University of Cambridge 2001 ib Paper 3 15D Solution Created 2026-09-24 Updated 2026-10-14
Use the original PDF constraints, whose right sides are and . Introduce nonnegative surplus variables , slack , and artificial variables :All seven variables are nonnegative. Phase I of the two-phase simplex method minimizes with initial basis . The initial simplex dictionary isEnter and leave : the ratio test gives . Substituting givesNow enter and leave . The bounds from are , so the ratio test selects . The new dictionary isThe associated basic solution has and , which is a global minimum because artificial variables are nonnegative. Delete their columns for Phase II. In the remaining basis the objective isFor , both reduced costs are nonnegative, so the simplex method has reached the optimum at :For , the coefficient of is negative. Enter ; the ratio test gives from and from , so leaves. Eliminating givesand henceThe two reduced costs are now positive, so is optimal andAt the whole feasible edge from to is optimal; both value formulas agree. These dictionaries explicitly carry out both phases rather than inferring the answer solely from a feasible-region sketch.
Past exam of the mathematics course of the University of Cambridge 2002 ib Paper 3 15H Solution Created 2026-09-24 Updated 2026-10-14
Introduce surplus variables , slack , and artificial variables , all nonnegative. The two-phase simplex standard-form equations arePhase I maximizes . An initial basic feasible solution has basic variables and all others zero. Its simplex dictionary isLet enter. The simplex ratio test gives from the row and from the row, so leaves. After this pivot,Choose to enter; the limiting ratios are and , so leaves. The resulting dictionary isThus , attained at with . Since for every feasible Phase I point, this proves feasibility and completes Phase I.
Delete the artificial variables and restore the original objective . The resulting Phase II dictionary isLet enter; only decreases, and it reaches zero at . Pivoting givesAn optimal simplex tableau, with each row recording its equality, isBoth reduced costs in the maximization dictionary are negative. Setting nonbasic therefore givesAs a direct optimality check, implies ; the displayed point attains both equalities.
Past exam of the mathematics course of the University of Cambridge 2002 iii Paper 34 1 Solution Created 2026-10-03 Updated 2026-10-14
Introduce the nonnegative integer surplus variables and . Solving these two equalities gives the optimal relaxed simplex dictionarywith objectiveThe printed tableau has a sign error in the first row: in equality-row form the coefficient of must be , rather than . The defining constraints and the printed objective row both confirm this correction. The second row, from which the required cut is obtained, is unaffected.
The cutting-plane method solves the linear programming relaxation and, if the optimum is fractional, adds an inequality valid for every feasible integer point but violated by that optimum. For an all-integer tableau rowwrite each coefficient as its integer part plus its fractional part. The quantity is an integer, while is nonnegative. Thus the integer is at most , and subtraction gives the Gomory fractional cutIt retains every feasible integer point and cuts off the fractional basic point with all nonbasic .
Apply this to the row . Since , and , the resulting valid inequality isMultiply by five and add an integer slack . Its row is . At the old relaxed optimum, is negative, while the minimization objective coefficients remain nonnegative. This is the starting configuration for the dual simplex algorithm: retain dual feasibility and pivot to repair the negative basic value.
The cut row permits either or to enter. The dual ratio test givesThus enters and leaves. Solving the cut row and substituting givesSetting the nonbasic variables gives nonnegative basic values . The new objective coefficients are nonnegative, so this is optimal for the cut relaxation. Its decision variables are already integer and satisfy the original inequalities. ThereforeIndeed the positive coefficients of both nonbasic variables make this relaxed optimizer unique. No additional cut is needed.
Past exam of the mathematics course of the University of Cambridge 2003 ib Paper 4 14H Solution Created 2026-09-24 Updated 2026-10-14
Introduce nonnegative slack variables , a nonnegative surplus variable , and an artificial variable . Phase I of the two-phase simplex method minimizes . The initial simplex dictionary isWith the nonbasic variables zero this is feasible for the artificial problem. Enter ; the minimum ratios are , so leaves. Solving its row for and substituting givesNow enter . The ratios from decreasing basic variables are and , so leaves. The resulting dictionary isSetting the nonbasic variables zero gives , so Phase I has reached its minimum and found feasibility. Remove and reinstate the true objective . Substitution of the basic variables givesEnter . The decreasing rows give ratios for and for , so leaves. Phase II then hasEvery nonbasic variable is nonnegative and every reduced cost is positive. Thus the simplex optimality criterion provesAll three original constraints are active. Positivity of all three reduced costs also proves uniqueness: equality in the objective lower bound forces , which fixes the displayed solution.
Past exam of the mathematics course of the University of Cambridge 2005 iii Paper 40 1 Solution Created 2026-10-03 Updated 2026-10-14
Introduce nonnegative slack variables and write for the objective value. The initial simplex dictionary, recovered from the original PDF rather than the corrupted converted table, isFor this minimization convention, nonnegative objective coefficients give dual feasibility. The dual simplex algorithm repairs a negative basic value while retaining those nonnegative reduced costs. If the leaving row is , , an entering variable must have ; choose the smallest ratio of its objective coefficient to .
Choose to leave. Eligible columns are , with ratios and . Thus enters. Solving its row and substituting givesNow only has a negative basic value. Its only eligible entering column is , so pivot there, with leaving. The resulting dictionary isSetting the nonbasic variables to zero gives a basic feasible solution. The final objective row also proves for every feasible point, because its nonbasic variables are nonnegative. Hence the unique relaxed optimum is
For the integer program, all four original slack variables are integers whenever the decision variables are integers. The fractional row can be writtenThe Gomory fractional cut keeps the fractional parts of these coefficients: and . It therefore gives , or . Its validity can also be seen directly: the displayed row makes an odd nonnegative integer. In original variables this cut is .
Introduce the new integer-valued slack , with initial row . It is primal infeasible but retains dual feasibility, so one more dual-simplex pivot has leave and enter. Substitute to obtainAll basic values at are nonnegative integers, including . The objective row proves a lower bound of on every point satisfying the valid cut, hence on every integer-feasible point. It is attained atThe strictly positive nonbasic objective coefficients also show uniqueness. One Gomory cut and its reoptimization are sufficient.
Past exam of the mathematics course of the University of Cambridge 2006 ib Paper 4 20C Solution Created 2026-09-24 Updated 2026-10-14
Use two-phase simplex to handle the constraint of the opposite inequality direction. Introduce nonnegative slack variables , a surplus variable , and an artificial variable . The equality constraints areFor Phase I maximize , initially with basis . Its initial simplex dictionary isChoose to enter. The simplex ratio test compares , and , so leaves. The new dictionary isSince , choose to enter. Its limiting ratios are from and from , so leaves. This givesNow , so let enter. Its limiting ratios are from and from ; the artificial variable leaves. The simplex dictionary becomesSetting all nonbasic variables to zero gives , a feasible original basis. Since , Phase I is optimal with value zero; delete .
For Phase II the original objective in this basis isAll nonbasic reduced costs are strictly negative, so no further improving simplex pivot exists. As the nonbasic variables are nonnegative, the dictionary also directly certifies , with equality only when . ThereforeThe second original constraint has slack five and the other two are tight. As an independent linear programming optimality certificate, multiply the first constraint by and the third, after reversing it, by . This gives , and subtracting proves the same upper bound for the objective.
Past exam of the mathematics course of the University of Cambridge 2006 iii Paper 38 1 Solution Created 2026-10-03 Updated 2026-10-14
Introduce slack variables . The initial simplex dictionary isAll six variables are nonnegative. The given rule is the Dantzig pivot rule: select the nonbasic variable with the largest positive reduced cost. It applies to slack variables too once they become nonbasic. At each step the simplex ratio test limits how far that entering variable can increase before a basic variable reaches zero.
The successive objective rows of the simplex dictionary, expressed in the current nonbasic variables, areThese rows identify each entering variable unambiguously. Performing the corresponding simplex ratio tests gives the complete pivot sequence:For example, after pivot two the dictionary has , and . Although increasing improves the objective at rate four, reaches zero first at , giving pivot three. After pivot four, and ; the upper bound gives pivot five.
In the final objective row every reduced cost is nonpositive. Since , it also directly certifies the upper bound , attained only when all three vanish. Thus
A greatest improvement pivot rule uses the total feasible increase in the objective, rather than its increase per unit of the entering variable. At the origin, the three candidate edge moves have improvements , and . It therefore brings into the simplex basis first, with leaving, and immediately reaches the optimum. This rule solves this instance in one pivot.
This is a three-dimensional Klee-Minty cube example: the specified Dantzig pivot rule visits every vertex before reaching the optimum. Higher-dimensional versions require pivots, so that rule has exponential worst-case running time despite its strong practical performance. Each pivot requires only polynomially many arithmetic operations. An anti-cycling rule such as the Bland pivoting rule ensures finite termination; without one, degenerate pivots can cycle. A crude terminating bound is the number of possible bases, for constraints and original variables, which can be exponential. This does not show that every conceivable pivot rule must take exponential time. Linear programming itself has polynomial-time algorithms, including the ellipsoid method and suitable interior-point methods.
Past exam of the mathematics course of the University of Cambridge 2007 ib Paper 4 20C ii Solution Created 2026-09-24 Updated 2026-10-14
The amended payoff is . Using the previous simplex dictionary,Thus enters. The positive pivot-column coefficients give ratios from and from ; the coefficient in the row gives no bound. The simplex ratio test makes leave. Dividing that row by and eliminating givesThe positive objective-row coefficients and nonnegative slack variables prove optimality at . ThereforeAll three constraints are equalities at this point. Strict positivity of the three objective-row coefficients also forces every optimal point to have all three slacks zero; the displayed dictionary then makes the optimizer unique.
Past exam of the mathematics course of the University of Cambridge 2007 ib Paper 4 20C i Solution Created 2026-09-24 Updated 2026-10-14
Use payoff , so maximization of is equivalent to the required minimization. In the given simplex tableau, can increase the payoff. The simplex ratio test has candidate ratios in the row and in the row; the negative coefficient in the row imposes no upper bound. Thus enters the simplex basis and leaves.
Divide the pivot row by , then eliminate from the other rows. The resulting simplex dictionary isAll slack variables and original variables are nonnegative. The last row therefore proves for every feasible point; setting the nonbasic variables to zero attains it and leaves all basic variables nonnegative. HenceThe slack vector is .
Past exam of the mathematics course of the University of Cambridge 2007 iii Paper 40 1 Solution Created 2026-10-03 Updated 2026-10-14
Introduce nonnegative slack variables , and , and write the objective as . With nonbasic, the initial simplex dictionary isThis is feasible at the origin. Enter . The simplex ratio test selects to leave, since its bound is , compared with from . Pivoting givesNow enter . The ratio test chooses to leave: its bound is smaller than from and from . The resulting dictionary isAll basic values are nonnegative and all nonbasic objective coefficients are nonpositive. The simplex algorithm therefore certifiesThe negative objective coefficients also make this continuous optimum unique.
For integer , all three original slacks are integers. Apply a Gomory fractional cut to the rowThe fractional part of is , so the cut is , or . To justify it directly, rewrite the row asThe parenthesized term is an integer and is at most , since the other term is nonnegative. It is therefore at most , proving the cut. This retains every feasible integer solution and excludes the current fractional optimum. Since , the cut is equivalently .
Introduce the integer-valued nonnegative slack . Its dictionary row is , so primal feasibility fails while the objective row remains dual feasible. In the dual simplex algorithm, leaves; tie in the dual ratio test, each with ratio . Choose to enter. Substituting givesThis dictionary is feasible at and certifies the cut relaxation's optimum , achieved at the integer point .
Past exam of the mathematics course of the University of Cambridge 2008 ib Paper 3 20H Solution Created 2026-09-24 Updated 2026-10-14
Set , so and . Introduce nonnegative slack and surplus variables :The objective is . A feasible simplex basis is with nonbasic variables ; its basic values are . The initial simplex dictionary isIn the simplex algorithm, choose as the entering variable since it has positive objective coefficient. With the other nonbasic variables zero, only decreases; the simplex ratio test gives . Thus leaves. Pivoting its row givesAll nonbasic variables are nonnegative, and all objective coefficients in the final dictionary are nonpositive, proving optimality. Setting them to zero gives , , , henceThe surplus value is , so the lower constraint is indeed satisfied, not mistakenly treated as equality at the optimum. The strict negative objective coefficients also show uniqueness of the optimizer.
Past exam of the mathematics course of the University of Cambridge 2009 iii Paper 35 1 Solution Created 2026-10-03 Updated 2026-10-14
Introduce nonnegative slack variables and write . A maximizing simplex dictionary is dual feasible when every nonbasic coefficient in the objective is nonpositive. After inserting a constraint, the dual simplex algorithm retains this property while repairing any negative basic value. For a leaving row with , only can enter; choose a column minimizing the ratio of its objective penalty to .
For the first linear program, has the best profit-to-resource ratio. Pivot it into the initial slack basis to obtainAll basic values are nonnegative and all reduced costs are nonpositive, so the optimal point is , with value five. Adding the second constraint givesThe same basis remains feasible and optimal: the second constraint does not change the answer.
The third constraint gives the new rowThe current dictionary is dual feasible but primal infeasible. The eligible entering variables are , with dual ratio-test values and respectively. Enter and leave ; solving that row and substituting into the old rows yieldsThis is a feasible optimal simplex dictionary. Thus the new optimal point is , with value three. As an independent linear programming optimality certificate, dual multipliers have weighted objective bound and weighted coefficient row , which dominates the profit row.
On inserting the fourth constraint the slack isIt has a negative constant and no eligible entering column. Since all its nonbasic variables are nonnegative, this row cannot be satisfied: the fourth linear program is infeasible, and adding the fifth constraint cannot restore feasibility. The requested optimal values are therefore
The arbitrary-data selection question is a maximum feasible subsystem problem. With rational input it is in NP: guess the selected row indices, and test their linear programming feasibility in polynomial time. Equivalently, a nonempty rational polyhedron has a feasible rational point of polynomially bounded encoding length, which serves as a certificate.
For an explicit NP-hardness reduction, take an independent set instance with graph having vertices and desired independent-set size . Use variables , one inequality for each vertex, and identical copies of for each edge. Ask for a feasible subsystem of size . An independent set of size gives such a subsystem: include all edge rows and those vertex rows, and use its indicator vector. Conversely, omitting every copy of even one edge row leaves at most selectable rows. Hence any qualifying subsystem retains every edge inequality and at least vertex inequalities. Their vertices must be independent, since two adjacent selected vertices would force . The construction has polynomial size; is irrelevant to feasibility. Thus the rational-input decision problem is NP-complete, not merely difficult because there are many subsets to enumerate.
Past exam of the mathematics course of the University of Cambridge 2012 iii Paper 42 2 a Solution Created 2026-10-03 Updated 2026-10-07
Use the PDF's first constraint, ; the TeX aid substitutes a different inequality. Introduce a surplus , slacks , and one artificial variable , all nonnegative. The initial simplex dictionary isThe initial basis is , with values . In two-phase simplex, Phase I maximizes . We use the Bland pivoting rule: the smallest-index nonbasic variable with positive reduced cost enters, and among minimum-ratio ties the smallest-index basic variable leaves.
First enters. The ratios for are , so leaves in a degenerate pivot. The resulting dictionary isNext enters. It reduces and with ratios and , while increases. Thus leaves. The Phase I maximum is , with a feasible original basis; remove and obtainIn Phase II the original objective is . Bland's rule makes enter, and leaves at ratio . This givesFinally enters. The decreasing basic variables have ratios and , so leaves. The final tableau, with the basic columns suppressed, isEach row means its row variable plus the displayed nonbasic terms equals the right side. Since , no nonnegative choice of nonbasic variables improves the objective. ThusThe slacks are , .
A different entering rule is faster here. Selecting the largest eligible index in the initial Phase I objective makes enter and leave. The dictionary then has and . Entering makes leave at , directly reaching the final original basis . Hence two pivots suffice instead of Bland's four, and Phase II needs no further pivot. This comparison concerns this instance, not a general superiority of that entering rule.
Past exam of the mathematics course of the University of Cambridge 2013 iii Paper 38 2 b Solution Created 2026-10-03 Updated 2026-10-07
Introduce nonnegative slack variables for the four dual inequalities. The initial simplex dictionary isAt the origin all four basic slacks are positive. Enter : the simplex ratio test compares bounds from and from , so leaves at . Entering initially would tie two limiting bounds and produce degeneracy in linear programming; the chosen pivot avoids this. The new simplex dictionary isOnly has positive objective coefficient. Enter it; the limiting bound is from , rather than from . Thus leaves, givingEvery nonbasic variable has nonpositive objective coefficient, so this feasible simplex basis is optimal. Setting the nonbasic variables to zero yieldsBoth new basic solutions have strictly positive basic coordinates; neither pivot is degenerate.
The first and fourth dual constraints have positive slacks and . Complementary slackness therefore requires . Since , the second and third primal constraints must be equalities:ConsequentlyThe first primal left side is , so the vector is feasible. Its value matches the feasible dual value, giving a linear programming optimality certificate.
Past exam of the mathematics course of the University of Cambridge 2014 iii Paper 37 4 c Solution Created 2026-10-03 Updated 2026-10-06
Introduce nonnegative surplus variablesAt the proposed starting basic feasible solution, the basic variables are and the nonbasic variables are . Its simplex dictionary, with objective , isIncrease to decrease . The simplex ratio test gives limits from , from , and from . The smallest is , so enters and leaves. After this single pivot the dictionary isAll objective coefficients of nonbasic variables are strictly positive. Thus the simplex method has reached its unique optimum:The feasible dual vector has the same objective, providing an independent weak duality certificate. Normalization givesThese are all the equilibria: the dual's strict slack in row two forces , and the primal's strict slack in column two forces . Equality of the two active row and column payoffs then fixes the displayed probabilities. The value is the first player's expected net loss; the second gains .
Past exam of the mathematics course of the University of Cambridge 2016 ib Paper 2 9H Solution Created 2026-09-24 Updated 2026-10-06
Introduce nonnegative slack variables and start the simplex algorithm at , with slacks . The objective's largest positive entering coefficient belongs to . Its ratio test is , , , so leaves and enters.
Solve that pivot row for and substitute into the other rows and the objective :This is a feasible simplex dictionary at nonbasic variables . All their objective coefficients are negative, so no feasible increase can improve the objective. ThusThe negative reduced coefficients also prove uniqueness of this optimum.
The dual linear program, with nonnegative variables , isThe feasible choice has objective . Weak duality proves that it and the primal point are optimal. Complementary slackness also forces because the first two primal slacks are positive, and then the positive forces .