Optimization Solver

Find best values: linear programming with a feasible-region graph (maximize / minimize subject to constraints), the simplex method for many variables, and gradient-descent nonlinear optimization with a contour visualizer. Built for cost/profit and engineering design problems.

Calculator Numbers & Math Updated Jun 21, 2026
How to Use
  1. For <strong>linear programming</strong>, write the objective on the first line — <code>maximize 40x + 30y</code> (or <code>minimize …</code>) — then one constraint per line: <code>2x + y &lt;= 100</code>, <code>x + y &lt;= 80</code>, <code>x &gt;= 0</code>, <code>y &gt;= 0</code>.
  2. With two variables you get the full <strong>feasible-region graph</strong> — the shaded polygon, every constraint line, the corner points and the optimal vertex marked. The example above solves to <strong>x = 20, y = 60, profit = 2600</strong>.
  3. With three or more variables it switches to the <strong>simplex method</strong> and reports the optimal values and objective (no 2-D graph).
  4. For <strong>nonlinear</strong> problems use the Gradient Descent tab: type <code>f(x, y)</code>, choose minimize or maximize, set a start point and learning rate, and watch the descent path trace across a contour heat-map to the optimum.
  5. It detects <strong>unbounded</strong> objectives (can grow forever) and <strong>infeasible</strong> systems (contradictory constraints), and warns when gradient descent diverges so you can lower the learning rate.

Feasible region / descent path

How it solves each kind

Linear program
optimum is at a corner of the feasible region
2-var graphical
intersect constraints → feasible vertices → best objective
n-var simplex
Big-M method, ≤ / ≥ / = constraints, x ≥ 0
Gradient descent
xₖ₊₁ = xₖ − η∇f(xₖ) (ascent for maximize)
Feasible region
intersection of all constraint half-planes
Unbounded
objective improves along an infinite direction
Infeasible
no point satisfies all constraints
Learning rate
too large → overshoot & diverge; too small → slow

About the Optimization Solver

The Optimization Solver is a simple, free helper for everyday maths and number work that runs entirely on your own device. Find best values: linear programming with a feasible-region graph (maximize / minimize subject to constraints), the simplex method for many variables, and gradient-descent nonlinear optimization with a contour visualizer. Built for cost/profit and engineering design problems.

How it works

Enter your figures and the result appears instantly, updating the moment you change anything. There is no submit button and nothing to wait for, so it is easy to try a few what-if numbers and compare the results. Just check each box holds the kind of value it expects.

Want the deeper story? The Knowledge Base explains the ideas behind the tools in more detail.

Frequently Asked Questions

What is linear programming?

Optimising a linear objective (like profit = 40x + 30y) subject to linear inequality constraints, with the variables usually ≥ 0. The set of points satisfying every constraint is the <strong>feasible region</strong> — a polygon for two variables — and the optimum always sits at one of its <strong>corner points (vertices)</strong>. This tool finds every vertex, evaluates the objective at each, and reports the best.

How does the 2-variable graph work?

Each constraint is a line that splits the plane into an allowed and a forbidden half. Their overlap is the shaded feasible region. Because a linear objective is optimised at a corner, the tool intersects the constraint lines, keeps the feasible intersections, and picks the vertex with the best objective value — which it highlights on the graph along with its coordinates.

What about more than two variables?

It uses the <strong>simplex method</strong> (a Big-M implementation), the standard algorithm for linear programs. It handles ≤, ≥ and = constraints and reports the optimal value of every variable. There's no 2-D picture beyond two variables, but the answer is exact for the model you enter.

How does gradient descent find a minimum?

It starts at your point and repeatedly steps <em>downhill</em> — in the direction opposite the gradient ∇f — by an amount set by the learning rate, until the gradient is essentially zero. For maximisation it steps uphill instead. The path is drawn over a heat-map of f so you can see it roll into the valley. If the learning rate is too big the steps overshoot and the tool reports divergence.

Why does it say “unbounded” or “infeasible”?

<strong>Unbounded</strong> means the feasible region stretches to infinity in a direction that keeps improving the objective, so there's no finite best value — usually a missing constraint. <strong>Infeasible</strong> means no point satisfies all the constraints at once (e.g. x ≤ 1 and x ≥ 5), so there's nothing to optimise.

Does any of this run on a server?

No — the parser, the vertex/simplex solvers, gradient descent and the graphics all run locally in your browser. Nothing is uploaded and it works offline.

How do I use the Optimization Solver?

Just type your numbers. The answer shows up right away — there is no button to press. Change anything and it updates by itself.

Does it cost anything or need an account?

No. The tool is completely free, there is no account to create, and it keeps working offline after the page first loads.

Is anything I type uploaded?

No. The tool works entirely on your device, so the values you enter never leave your browser.

Common Use Cases

Cost / profit optimization

Maximise profit or minimise cost under resource and capacity limits — the classic LP.

Production & blending

Operations-research problems: product mix, scheduling, diet/blend models.

Engineering design

Minimise weight, energy or error over design variables with gradient descent.

Machine-learning intuition

Visualise how gradient descent rolls a loss surface down to its minimum.

Coursework

Check LP corner-point solutions and see the feasible region drawn for you.

Resource allocation

Split limited budget, time or materials for the best outcome.

Last updated: