Integer programming solver: whole-number and yes/no decisions, solved and checked
Type a model whose decisions must be whole numbers (integer: x, y) or yes/no (binary: z) and solve it here, no account needed. A branch-and-bound solver finds the best whole-number answer and proves it optimal within its gap tolerance, or says so if a time limit stops it first.
Solve it here
The example below is the Set covering problem worked example; its saved answer, checked by the solver, is 6 (optimal).
How to type it
- First line:
maximizeorminimizeand the objective, such as3*a + 2*b. - Then
subject toand one constraint per line with<=,>=or=. a, b >= 0for nonnegative variables;integer: aorbinary: zfor whole-number or yes/no ones.- Lines starting with
#are notes, such as what a variable means.
What you get here
- the best whole-number answer and the value of each variable
- a check that every constraint holds at the answer
- the proof label: optimal within the solver's gap tolerance
With a free account: the full step-by-step walkthrough, word problems, photos and voice, and your history.
Worked examples
- Set covering problem
- 0-1 knapsack problem
- Facility location problem
- LP relaxation versus integer optimum
Questions
How do I say a variable must be a whole number?
Add a line integer: x, y for whole numbers, or binary: z for yes/no (0 or 1) decisions.
Is the answer really optimal?
When the solver proves it, the answer says optimal within the gap tolerance. If a time limit stops the solver first, the answer says so.
More: all calculators · 50 solved examples · what the app solves
Try ProvenDecisions free: type, photograph or say an optimization problem; every answer is checked by a solver.