Skip to the content

Topics Covered

Concept of Duality Primal & Dual Conversion Rules Primal-Dual Relations Economic Interpretation Dual Simplex Method
On this page
  1. 1. Concept of Duality
  2. 2. Standard Primal–Dual Pair
  3. 3. General Rules for Converting Primal to Dual
  4. 4. Worked Examples — Constructing the Dual
  5. 5. Relation Between Primal and Dual Solutions
  6. 6. Economic Interpretation of Dual Variables
  7. 7. Using Duality to Solve a Primal
  8. 8. The Dual Simplex Method
  9. 9. Summary Table — Primal vs Dual Simplex
  10. Key Take-aways

1. Concept of Duality

IDEA

Every Linear Programming Problem (called the Primal) has an associated companion problem called the Dual. The dual is also an LPP, derived from the same data but with the roles of constraints and variables interchanged. Solving either problem automatically yields information about the solution of the other.

Why Study Duality?

  1. It often provides a more efficient computational approach (especially when the dual has fewer constraints).
  2. The dual variables carry valuable economic interpretation as shadow prices / marginal values of resources.
  3. Sensitivity analysis becomes intuitive in dual form.
  4. It underpins many advanced algorithms (interior-point methods, decomposition).

2. Standard Primal–Dual Pair

Symmetric (Canonical) Form

Primal:

\[ \begin{aligned} \text{Max}\;Z &= \mathbf{c}^{T}\mathbf{x}, \\ A\mathbf{x} &\le \mathbf{b}, \quad \mathbf{x} \ge \mathbf{0}. \end{aligned} \]

Dual:

\[ \begin{aligned} \text{Min}\;W &= \mathbf{b}^{T}\mathbf{y}, \\ A^{T}\mathbf{y} &\ge \mathbf{c}, \quad \mathbf{y} \ge \mathbf{0}. \end{aligned} \]

Each constraint of the primal corresponds to a variable of the dual, and vice-versa. The RHS vector \(\mathbf{b}\) of the primal becomes the objective coefficient of the dual; the objective coefficients \(\mathbf{c}\) of the primal become the dual's RHS.

3. General Rules for Converting Primal to Dual

For an LPP that is not in pure canonical form, apply the following correspondences:

Primal (Max Z)Dual (Min W)
Number of variables (\(n\))Number of constraints (\(n\))
Number of constraints (\(m\))Number of variables (\(m\))
Objective coefficients \(c_j\)RHS of dual constraints
RHS \(b_i\)Objective coefficients of dual
Coefficient matrix \(A\)\(A^{T}\) (transpose)
MaximisationMinimisation
\(i\)-th constraint: \(\le\)\(i\)-th dual variable \(y_i \ge 0\)
\(i\)-th constraint: \(\ge\)\(y_i \le 0\)
\(i\)-th constraint: =\(y_i\) unrestricted in sign
Variable \(x_j \ge 0\)\(j\)-th dual constraint: \(\ge\)
Variable \(x_j \le 0\)\(j\)-th dual constraint: \(\le\)
Variable \(x_j\) unrestricted\(j\)-th dual constraint: =

Mnemonic: "Max ↔ Min, ≤ ↔ ≥, ≥ ↔ ≤, = ↔ unrestricted, ≥ 0 ↔ ≥, unrestricted ↔ =". Always assume the primal is in maximisation canonical form with \(\le\) constraints when applying the table directly; convert any deviation before reading the rules.

4. Worked Examples — Constructing the Dual

EXAMPLE 1 — Symmetric primal

Primal: Max \(Z = 3 x_1 + 5 x_2 + 4 x_3\) subject to

Dual (3 constraints in primal ⇒ 3 dual variables \(y_1, y_2, y_3\); 3 primal variables ⇒ 3 dual constraints):

EXAMPLE 2 — Mixed signs and unrestricted variable

Primal: Max \(Z = 5 x_1 + 6 x_2\) subject to

Dual:

5. Relation Between Primal and Dual Solutions

Key Theorems (statements only)

1. Weak Duality Theorem

For any feasible primal solution \(\mathbf{x}\) and any feasible dual solution \(\mathbf{y}\):

\[ \mathbf{c}^{T}\mathbf{x} \;\le\; \mathbf{b}^{T}\mathbf{y} \]

i.e., a feasible primal objective never exceeds a feasible dual objective.

2. Strong Duality (Fundamental) Theorem

If either the primal or the dual has an optimal solution, then both have optimal solutions and

\[ Z^{*} \;=\; W^{*}. \]

i.e., the optimal objective values are equal.

3. Complementary Slackness Theorem

At optimality:

Formally:

\[ (b_i - \mathbf{a}_i^{T}\mathbf{x})\,y_i = 0,\qquad (A^{T}\mathbf{y} - \mathbf{c})_j \, x_j = 0. \]
4. Duality of Duality

The dual of the dual is the primal.

Possible Outcomes

PrimalDual
Optimal solutionOptimal solution (same Z*)
UnboundedInfeasible
InfeasibleUnbounded OR Infeasible

6. Economic Interpretation of Dual Variables

If the primal models a profit-maximisation problem (with resources \(b_i\) and per-unit profit \(c_j\)), then the optimal dual variable \(y_i^{*}\) is the shadow price of resource \(i\) — the rate at which the optimal profit would increase per additional unit of that resource, holding everything else fixed.

In the diet problem, dual variables represent marginal cost of meeting one more unit of each nutrient requirement.

7. Using Duality to Solve a Primal

If the primal has many constraints but few variables, the dual will have many variables but few constraints — which can be easier to solve by hand. Solve the dual; recover the primal solution from the optimal dual's tableau (or by complementary slackness).

Steps

  1. Convert primal to canonical form (Max with ≤).
  2. Write the dual.
  3. Solve the dual by ordinary simplex.
  4. From the final simplex tableau of the dual, read off the primal's optimal solution from the \(c_j - z_j\) row entries under the slack columns (slack columns of the dual correspond to primal variables).
EXAMPLE — Solve primal via dual

Primal: Max \(Z = 4 x_1 + 5 x_2\) s.t. \(2 x_1 + x_2 \le 8,\; x_1 + 2 x_2 \le 10,\; x_1, x_2 \ge 0\).

Dual: Min \(W = 8 y_1 + 10 y_2\) s.t. \(2 y_1 + y_2 \ge 4,\; y_1 + 2 y_2 \ge 5,\; y_1, y_2 \ge 0\).

Solve the dual via Big-M (Unit 4): optimal \(y_1^{*} = 1, y_2^{*} = 2, W^{*} = 28\).

By strong duality, \(Z^{*} = 28\). Use complementary slackness to recover \(x^{*}\):

8. The Dual Simplex Method

PURPOSE

The dual simplex method is used when the starting tableau is:

The algorithm iteratively restores primal feasibility while maintaining dual optimality — the exact opposite of the regular simplex.

When to use Dual Simplex?

  1. After adding new constraints to an already-solved LPP (sensitivity analysis).
  2. When some constraints are of the ≥ form and the converted ≤ form has negative b's (so adding slacks alone doesn't give a feasible start).
  3. In branch-and-bound for integer programming.

Algorithm (Maximisation)

  1. Test for primal feasibility: are all \(b_i \ge 0\)?
    • Yes → already optimal (and feasible). Stop.
    • No → continue.
  2. Choose leaving variable: pick the row with the most negative \(b_i\) — that basic variable leaves.
  3. Choose entering variable: among non-basic variables with negative coefficients in the leaving row, compute \(\rho_j = (c_j - z_j) / a_{rj}\). Pick the one with the smallest absolute value of \(\rho_j\) (i.e., the least negative ratio). This is the entering variable.
  4. Pivot: perform row operations to make pivot element 1 and others in the column 0.
  5. Go back to step 1.

If at some iteration no negative coefficient appears in the leaving row, the LPP is infeasible.

Worked Example — Dual Simplex

PROBLEM

Min \(Z = 3 x_1 + 2 x_2 + x_3\) subject to

Convert to canonical form for the dual simplex. Multiply each ≥ by −1 to get ≤ with negative RHS:

\[ \begin{aligned} -3 x_1 - x_2 - x_3 + s_1 &= -3 \\ 3 x_1 - 3 x_2 - x_3 + s_2 &= -6 \end{aligned} \]

Convert Min to Max: \(Z' = -3 x_1 - 2 x_2 - x_3\) (so \(c_j - z_j\) is dual-feasible since all are ≤ 0 in initial tableau).

Initial Tableau

cBBasisxBx₁ (−3)x₂ (−2)x₃ (−1)s₁ (0)s₂ (0)
0s₁−3−3−1−110
0s₂−63−3−101
cj−Zj−3−2−100

All \(c_j - z_j \le 0\) ⇒ dual feasible. But b's are negative ⇒ primal infeasible. Use dual simplex.

After pivoting and another iteration, the optimal solution is \(x_1 = 0,\; x_2 = 1.5,\; x_3 = 1.5,\; Z = 4.5\) (both constraints binding: \(x_2 + x_3 = 3\) and \(3x_2 + x_3 = 6\)).

9. Summary Table — Primal vs Dual Simplex

AspectPrimal SimplexDual Simplex
Starting conditionPrimal feasible (b ≥ 0), dual may be infeasibleDual feasible (cⱼ − zⱼ ≤ 0 for Max), primal may be infeasible
Direction of movesImproves objective each iteration; feasibility preservedRestores feasibility; optimality preserved
Termination — optimalAll cⱼ − zⱼ ≤ 0All bᵢ ≥ 0
Termination — infeasibleArtificial positive at endNo negative entry in pivot row
Termination — unboundedAll non-positive entries in entering columnn/a

Key Take-aways