use of org.ojalgo.optimisation.MathProgSysModel in project ojAlgo by optimatika.
the class LpsolveSemiContCase method testSemiContOrg.
@Test
@Disabled("Underscored before JUnit 5")
public void testSemiContOrg() {
final File tmpFile = new File(PATH + "lpsolve_sc_org.mps");
final MathProgSysModel tmpMPS = MathProgSysModel.make(tmpFile);
final ExpressionsBasedModel tmpModel = tmpMPS.getExpressionsBasedModel();
tmpModel.minimise();
TestUtils.assertTrue(tmpModel.validate());
final BigDecimal tmpExpVal = new BigDecimal("6.83333");
final double tmpActVal = tmpModel.maximise().getValue();
if (!tmpModel.validate(PRECISION)) {
TestUtils.fail(SOLUTION_NOT_VALID);
}
TestUtils.assertEquals(tmpExpVal.doubleValue(), tmpActVal, PRECISION);
}
Aggregations