You are viewing a free preview of this lesson.
Subscribe to unlock all 10 lessons in this course and every other course on LearningBro.
The Simplex algorithm extends linear programming beyond two variables, where the graphical method cannot be used. It is an algebraic method that systematically moves from one vertex of the feasible region to an adjacent vertex with a better (or equal) objective value, until the optimum is found.
To apply the Simplex algorithm, the LP must be in standard form:
Convert each "≤" inequality to an equality by adding a slack variable si≥0:
ai1x1+ai2x2+⋯+ainxn+si=bi
The slack variable represents unused capacity.
Write the system as a table (the Simplex tableau):
| x1 | x2 | s1 | s2 | RHS | |
|---|---|---|---|---|---|
| s1 | a11 | a12 | 1 | 0 | b1 |
| s2 | a21 | a22 | 0 | 1 | b2 |
| P | −c1 | −c2 | 0 | 0 | 0 |
The initial basic feasible solution is: x1=0,x2=0,s1=b1,s2=b2,P=0.
Select the column with the most negative entry in the objective row (bottom row). This is the variable that will enter the basis.
If no entry in the objective row is negative, the current solution is optimal — stop.
For each row (excluding the objective row), compute the ratio RHS/pivot column entry (only for positive entries).
The row with the smallest positive ratio is the pivot row. The variable in this row leaves the basis.
Divide the pivot row by the pivot element (to make it 1). Then use row operations to make all other entries in the pivot column equal to 0.
Maximise P=5x+4y subject to:
Subscribe to continue reading
Get full access to this lesson and all 10 lessons in this course.