0% found this document useful (0 votes)
52 views6 pages

Preparing An LP For Solution by The Simplex

The document discusses how to prepare a linear programming problem for solution using the simplex method. It involves placing the LP in standard form by converting inequalities to equalities using slack and excess variables. The simplex method then proceeds by choosing a variable to enter the basis based on its coefficient in the objective function. It tests ratios to determine which constraint's variable will leave the basis. The two-phase method is used if a basic feasible solution is not readily apparent, by first solving an auxiliary problem to determine feasibility before solving the original LP.

Uploaded by

Elzbethy
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
52 views6 pages

Preparing An LP For Solution by The Simplex

The document discusses how to prepare a linear programming problem for solution using the simplex method. It involves placing the LP in standard form by converting inequalities to equalities using slack and excess variables. The simplex method then proceeds by choosing a variable to enter the basis based on its coefficient in the objective function. It tests ratios to determine which constraint's variable will leave the basis. The two-phase method is used if a basic feasible solution is not readily apparent, by first solving an auxiliary problem to determine feasibility before solving the original LP.

Uploaded by

Elzbethy
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 6

Preparing an LP for Solution by the Simplex

An LP is in standard form if all constraints are equality constraints and all variables are
nonnegative. To place an LP in standard form, we do the following:
Step 1 If the ith constraint is a _ constraint, then we convert it to an equality constraint
by adding a slack variable si and the sign restriction si _ 0.
Step 2 If the ith constraint is a _ constraint, then we convert it to an equality constraint
by subtracting an excess variable ei and adding the sign restriction ei _ 0.
Step 3 If the variable xi is unrestricted in sign (urs), replace xi in both the objective function
and constraints by xi_ _ xi_, where xi_ _ 0 and xi_ _ 0.
Suppose that once an LP is placed in standard form, it has m constraints and n variables.
A basic solution to Ax _ b is obtained by setting n _ m variables equal to 0 and solving
for the values of the remaining m variables. Any basic solution in which all variables
are nonnegative is a basic feasible solution (bfs) to the LP.
For any LP, there is a unique extreme point of the LP’s feasible region corresponding to
each bfs. Also, at least one bfs corresponds to each extreme point of the feasible region.
If an LP has an optimal solution, then there is an extreme point that is optimal. Thus,
in searching for an optimal solution to an LP, we may restrict our search to the LP’s basic
feasible solutions.

The Simplex Algorithm

If the LP is in standard form and a bfs is readily apparent, then the simplex algorithm (for
a max problem) proceeds as follows:
Step 1 If all nonbasic variables have nonnegative coefficients in row 0, then the current
bfs is optimal. If any variables in row 0 have negative coefficients, then choose the variable
with the most negative coefficient in row 0 to enter the basis.
Step 2 For each constraint in which the entering variable has a positive coefficient, compute
the following ratio:
Any constraint attaining the smallest value of this ratio is the winner of the ratio test. Use
EROs to make the entering variable a basic variable in any constraint that wins the ratio
test. Return to step 1.
If the LP (a max problem) is unbounded, then we eventually reach a tableau in which
a nonbasic variable has a negative coefficient in row 0 and a nonpositive coefficient in
each constraint. Otherwise (barring the extremely rare occurrence of cycling), the simplex
algorithm will find an optimal solution to an LP.
If a bfs is not readily apparent, then the Big M method or the two-phase simplex
method must be used to obtain a bfs.
The Two-Phase Method

Step 1 Modify the constraints so that the right-hand side of each constraint is nonnegative.
Step 1_1 Identify each constraint that is now (after step 1) an _ or _ constraint. In step
3, we will add an artificial variable to each of these constraints.
Step 2 Convert each inequality constraint to the standard form.
Step 3 If (after step 1_) constraint i is a _ or _ constraint, then add an artificial variable
ai and the sign restriction ai _ 0.
Right-hand side of constraint

Step 4 For now, ignore the original LP’s objective function. Instead, solve an LP whose
objective function is min w_ _ (sum of all the artificial variables). This is called the Phase
I LP.
Because each ai _ 0, solving the Phase I LP will result in one of the following three
cases:
Case 1 The optimal value of w_ is greater than zero. In this case, the original LP has no
feasible solution.
Case 2 The optimal value of w_ is equal to zero, and no artificial variables are in the optimal
Phase I basis. In this case, drop all columns in the optimal Phase I tableau that correspond
to the artificial variables and combine the original objective function with the
constraints from the optimal Phase I tableau. This yields the Phase II LP. The optimal
solution to the Phase II LP and the original LP are the same.
Case 3 The optimal value of w_ is equal to zero, and at least one artificial variable is in
the optimal Phase I basis. In this case, we can find the optimal solution to the original LP
if, at the end of Phase I, we drop from the optimal Phase I tableau all nonbasic artificial
variables and any variable from the original problem that has a negative coefficient in row
0 of the optimal Phase I tableau.

Solving Minimization Problems


To solve a minimization problem by the simplex, choose as the entering variable the nonbasic
variable in row 0 with the most positive coefficient. A tableau or canonical form is
optimal if each variable in row 0 has a nonpositive coefficient.

Unrestricted-in-Sign Variables
If we replace a urs variable xi with xi_ _ xi_, the LP’s optimal solution will have xi_, xi_ or
both xi_ and xi_ equal to zero

You might also like