Issue 124115 - Solver does not identify a linear model as infeasible
Summary: Solver does not identify a linear model as infeasible
Status: CONFIRMED
Alias: None
Product: Calc
Classification: Application
Component: programming (show other issues)
Version: 4.0.1
Hardware: PC All
: P3 Normal (vote)
Target Milestone: ---
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-01-26 14:04 UTC by tavert
Modified: 2014-01-31 17:33 UTC (History)
4 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: 4.1.0-dev
Developer Difficulty: ---


Attachments
spreadsheet that replicates the problem (10.44 KB, application/vnd.oasis.opendocument.spreadsheet)
2014-01-26 14:04 UTC, tavert
no flags Details
screenshot of spreadsheet (90.77 KB, image/png)
2014-01-26 14:57 UTC, Edwin Sharp
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description tavert 2014-01-26 14:04:17 UTC
Created attachment 82400 [details]
spreadsheet that replicates the problem

The linear programming Solver is giving nonsense results for some infeasible problems. An attached example is:

Min A2 = 10 + 0.03 * B2 + 0.5625 * C2
s.t. B2 >= 0
     C2 >= 0
     D2 = 1.5 * B2 - 9.81 * A2 >= 0
     E2 = A2 - 4 * (A2 - 0.5 * C2) >= 0

In OpenOffice 3.3.0 or 3.2.1, the Solver recognizes this problem as infeasible. However in 4.0.1, it is reporting success with B2 = 0, C2 = 96, D2 = -627.84, E2 = 0. This violates the D2 constraint, so should not have been reported as a successful solution.

I don't know when https://issues.apache.org/ooo/show_bug.cgi?id=118160 went into a release, but my guess is this problem is related to having changed the linear solver. As it happens I am a contributor to several COIN-OR projects, I'm quite familiar with those solvers so if the LP as sent from Calc to CoinMP looks correct I can help look into what's happening on the solver side.
Comment 1 Edwin Sharp 2014-01-26 14:52:06 UTC
A2=3908 with
AOO410m1(Build:9750)  -  Rev. 1557669
2014-01-14_04:11:13 - Rev. 1557927
Debian
Gnumeric 1.12.9 gives error.
Comment 2 Edwin Sharp 2014-01-26 14:57:45 UTC
Created attachment 82401 [details]
screenshot of spreadsheet
Comment 3 tavert 2014-01-26 15:15:21 UTC
I also get the same A2 = 3908.69 "solution" when I enter B2 >= 0 and C2 >= 0 as separate constraints. The A2 = 64, B2 = 0, C2 = 96 result was from selecting the "Assume variables as non-negative" option, with the only explicit constraints on D2 >= 0 and E2 >= 0.