util_linear_program
Linear / integer program solver — Solve a linear program offline (two-phase simplex): objective= linear expression like 3x+5y, constraints= separated by ; using <=, >= or = (variables allowed on both sides), sense=max|min (default max). Variables are >= 0 unless listed in free=. integer=true (or integer=x,y) runs branch-and-bound for integer/binary (add x<=1) problems. Returns OPTIMAL/INFEASIBLE/UNBOUNDED, objective value, variable values, per-constraint slack, binding constraints and shadow prices. Up to 60 variables and 150 constraints. Use for production mix, diet/blending, budget allocation, knapsack, staffing. Price: $0.003 USDC (Base, via x402).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"objective": "<objective>",
"constraints": "<constraints>"
},
"name": "util_linear_program"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| objective | Yes | 3x+5y | |
| constraints | Yes | x<=4;2y<=12;3x+2y<=18 |