javascript-lp-solver
Version:
Easy to use, JSON oriented Linear Programming and Mixed Int. Programming Solver
32 lines (31 loc) • 587 B
JSON
{
"name": "Wood Shop Problem",
"optimize": "profit",
"opType": "max",
"constraints": {
"wood": {
"max": 300
},
"labor": {
"max": 110
}
},
"variables": {
"table": {
"wood": 30,
"labor": 5,
"profit": 6
},
"chair": {
"wood": 20,
"labor": 10,
"profit": 8
}
},
"expects": {
"feasible": true,
"table": 4,
"chair": 9,
"result": 96
}
}