Enter Your Linear Program
Use non-negative decision variables. The solver supports maximization, minimization, and constraints with ≤, ≥, and = signs.
Example Data Table
This sample model maximizes profit using three resource constraints.
| Model Part | x1 | x2 | Sign | RHS |
|---|---|---|---|---|
| Objective Coefficients | 3 | 5 | Max | — |
| Constraint 1 | 2 | 1 | ≤ | 18 |
| Constraint 2 | 2 | 3 | ≤ | 42 |
| Constraint 3 | 3 | 1 | ≤ | 24 |
Formula Used
Maximize or Minimize: Z = c1x1 + c2x2 + ... + cnxn
Subject to: a11x1 + a12x2 + ... + a1nxn (≤, ≥, =) b1
And: a21x1 + a22x2 + ... + a2nxn (≤, ≥, =) b2, continuing for all constraints
With: x1, x2, ... , xn ≥ 0
The solver builds a simplex tableau, adds slack or surplus variables where needed, and uses artificial variables with a Big M penalty when a starting basis is unavailable.
The entering variable is chosen from the largest positive value in Cj - Zj. The leaving variable is chosen using the smallest non-negative ratio of RHS divided by the pivot column entry.
How to Use This Calculator
- Choose maximize or minimize, then set the number of variables and constraints.
- Enter objective coefficients for each decision variable.
- Fill every constraint row with coefficients, pick the correct sign, and enter the right-hand-side value.
- Adjust the iteration limit or decimal display if needed.
- Click Solve Problem to view the optimal result, variable values, chart, and tableau steps above the form.
- Use the export buttons to save a CSV summary or a PDF report.
FAQs
1. What kinds of models can this solver handle?
It handles linear programming models with non-negative decision variables, a linear objective, and linear constraints. You can enter maximization or minimization problems with less-than, greater-than, or equality constraints.
2. Does it support minimization problems?
Yes. The calculator converts the minimization model internally so simplex iterations can proceed, then it reports the final objective using your original minimization coefficients.
3. Can I use ≥ or = constraints?
Yes. The solver adds surplus and artificial variables when required. That makes it suitable for many practical models that do not begin with a direct slack-variable basis.
4. What does an unbounded result mean?
Unbounded means the objective can keep improving without violating the constraints. In practical terms, your model is missing a limiting condition for one or more directions.
5. What does an infeasible result mean?
Infeasible means no point satisfies all constraints at the same time. This often happens when limits conflict, such as requiring a variable to be both very small and very large.
6. Why are artificial variables used here?
Artificial variables help create a temporary starting basis when a regular slack basis does not exist. The Big M penalty then forces those artificial values out if a feasible solution exists.
7. Can I enter decimal coefficients?
Yes. All coefficient and RHS inputs accept decimals, so you can model fractional resource usage, rates, costs, and other real-valued linear relationships.
8. What does the chart represent?
The chart plots the objective value captured at each recorded iteration. It helps you see how the solution improves or changes as pivots move the basis.