Fractional feed blend
Input
{
"constraints": [
{
"op": ">=",
"rhs": 800,
"terms": [
{
"coeff": 1,
"var": "corn_kg"
},
{
"coeff": 1,
"var": "soy_kg"
}
]
},
{
"op": "<=",
"rhs": 0,
"terms": [
{
"coeff": 0.21,
"var": "corn_kg"
},
{
"coeff": -0.3,
"var": "soy_kg"
}
]
},
{
"op": ">=",
"rhs": 0,
"terms": [
{
"coeff": 0.03,
"var": "corn_kg"
},
{
"coeff": -0.01,
"var": "soy_kg"
}
]
}
],
"objective": {
"sense": "minimize",
"terms": [
{
"coeff": 0.3,
"var": "corn_kg"
},
{
"coeff": 0.9,
"var": "soy_kg"
}
]
},
"variables": [
{
"max": 1000,
"min": 0,
"name": "corn_kg",
"type": "continuous"
},
{
"max": 1000,
"min": 0,
"name": "soy_kg",
"type": "continuous"
}
]
}Output
Build-time verified. stats.elapsed_ms normalized to 0.
{
"best_bound": 437.64705882352933,
"bound_verified": true,
"max_violation": 1.1368683772161603e-13,
"objective_value": 437.64705882352933,
"solution": {
"corn_kg": 470.58823529411757,
"soy_kg": 329.4117647058823
},
"stats": {
"elapsed_ms": 0,
"timed_out": false
},
"verdict": "optimal",
"verified": true
}Request
curl --fail-with-body --silent --show-error https://oracles.burgeonads.com/v1/solve/lp-mip -H 'Content-Type: application/json' --data-raw '{"variables":[{"name":"corn_kg","type":"continuous","min":0,"max":1000},{"name":"soy_kg","type":"continuous","min":0,"max":1000}],"constraints":[{"terms":[{"var":"corn_kg","coeff":1},{"var":"soy_kg","coeff":1}],"op":">=","rhs":800},{"terms":[{"var":"corn_kg","coeff":0.21},{"var":"soy_kg","coeff":-0.3}],"op":"<=","rhs":0},{"terms":[{"var":"corn_kg","coeff":0.03},{"var":"soy_kg","coeff":-0.01}],"op":">=","rhs":0}],"objective":{"sense":"minimize","terms":[{"var":"corn_kg","coeff":0.3},{"var":"soy_kg","coeff":0.9}]}}'