Introduce a slack variable in each constraint
3x+2y+s1=10,2x+s2=25,3x+3y+s3=40,s1, s2, s3≥0 Each ≤ constraint becomes an equation by adding a non-negative slack variable.
Write the objective function as the objective row
P−7x−5y=0 Moving every variable to the left makes the objective-row entries the negatives of the coefficients.
Write down the initial simplex tableau
b.v.s1s2s3Px323−7y203−5s11000s20100s30010P0001Value1025400 The slack variables are the initial basic variables and the origin is the initial basic feasible solution.
Iteration 1: choose the pivot column
most negative objective-row entry=−7⇒pivot column=x The rule is to pivot on the column with the most negative entry in the objective row.
Iteration 1: apply the ratio test
310=310,225=225,340=340⇒pivot row=s1 The smallest non-negative ratio picks the pivot row.
Iteration 1: state the pivot element
pivot element=3 The pivot element sits where the pivot column meets the pivot row.
Iteration 1: divide the pivot row by the pivot element
Rs1→31Rs1=(1, 32, 31, 0, 0, 0, 310) This makes the pivot element equal to 1.
Iteration 1: clear the rest of the pivot column
Rs2→Rs2−2×Rpivot,Rs3→Rs3−3×Rpivot,RP→RP+7×Rpivot Row operations reduce every other entry of the pivot column to zero.
Iteration 1: write down the new tableau
b.v.xs2s3Px1000y32−341−31s131−32−137s20100s30010P0001Value31035530370 The variable x has entered the basis and s1 has left it.
Iteration 2: choose the pivot column
most negative objective-row entry=−31⇒pivot column=y The rule is to pivot on the column with the most negative entry in the objective row.
Iteration 2: apply the ratio test
32310=5,130=30⇒pivot row=x The smallest non-negative ratio picks the pivot row. The s2 row is excluded because its entry in the pivot column is not positive.
Iteration 2: state the pivot element
pivot element=32 The pivot element sits where the pivot column meets the pivot row.
Iteration 2: clear the rest of the pivot column
Rs2→Rs2+34×Rpivot,Rs3→Rs3−1×Rpivot,RP→RP+31×Rpivot Row operations reduce every other entry of the pivot column to zero.
Iteration 2: write down the new tableau
b.v.ys2s3Px232−2321y1000s1210−2325s20100s30010P0001Value5252525 The variable y has entered the basis and x has left it.
Check the stopping condition
objective row=(21, 0, 25, 0, 0, 1)≥0 in every variable column There are no negative entries left in the objective row, so the tableau is optimal.
Read the solution from the final tableau
y=5,s2=25,s3=25,x=0,s1=0 Basic variables take the value in their row of the value column; non-basic variables are zero.
State the value of y at the optimum
The optimal value of y is read from the final tableau.