Skip to main content
1+1
EN
All calculators

Categories

Simplex method solver

Result

Fill in the fields to see your result.

How it works

Each constraint here is a "less than or equal to" limit on a linear combination of the variables, with every variable required to stay non-negative — the standard form the simplex method was originally built around. A slack variable is added to each constraint to convert the inequality into an equation, and the algorithm then pivots between corner points of the feasible region, always moving toward a better objective value, until no further improvement is possible.

The result is guaranteed optimal when one exists: the simplex method never settles for a local improvement that isn't also the global best, unlike many general-purpose optimization techniques.

Formulas used

Standard form

Maximize c₁x₁ + c₂x₂ + …, subject to each aᵢ₁x₁ + aᵢ₂x₂ + … ≤ bᵢ, and every xⱼ ≥ 0

Worked examples

A classic production problem

Maximizing 3x₁ + 5x₂ subject to x₁ ≤ 4, 2x₂ ≤ 12, and 3x₁ + 2x₂ ≤ 18 gives an optimal value of 36, at x₁ = 2, x₂ = 6.

Minimizing instead

To minimize the same objective under the same constraints, the best value is 0, achieved at x₁ = 0, x₂ = 0 — minimizing a positive-coefficient objective under these limits is trivially solved at the origin.

Assumptions and limits

  • The objective and every constraint are linear (no squared terms or products of variables).
  • All variables are constrained to be non-negative.
  • All constraints are "less than or equal to," with a non-negative limit.

Frequently asked questions

How do I enter a constraint?

One line per constraint, with the coefficient of each variable in order followed by the limit — for x₁ + 2x₂ ≤ 10, enter "1, 2, 10". A variable absent from a constraint gets a coefficient of 0.

Can I use "greater than or equal to" or "equal to" constraints?

Not directly in this version — it solves standard-form problems with "≤" constraints and non-negative variables only. A "≥" constraint can sometimes be rewritten as a "≤" by multiplying both sides by −1.

What does "unbounded" mean?

It means the objective can be improved forever within the given constraints — there is no ceiling, so no single optimal answer exists. This usually signals a missing constraint in the problem setup.

Why must the variables be non-negative?

This is the standard assumption in most real linear programming problems (you cannot produce a negative quantity of something), and it is what the classic simplex method is built to exploit.

Updated