Reword error messages that are displayed when a group fails to solve.

The current messages accurately reflect what happens to the system
of equations that represents the sketch, but can be quite confusing
to users that only think in terms of the constraints.

We use "unsolvable" and not "impossible" because while most of
the cases that result in this error message will indeed stem from
mutually exclusive sets of constraints, it is still possible that
there is some solution that our solver is unable to find using
numeric methods.
This commit is contained in:
whitequark 2016-01-21 08:05:21 +00:00
parent 30d9bb0479
commit 55cde18c5a
4 changed files with 9 additions and 9 deletions

View File

@ -220,7 +220,7 @@ default: dbp("bad constraint type %d", sc->type); return;
ssys->result = SLVS_RESULT_DIDNT_CONVERGE;
break;
case System::SINGULAR_JACOBIAN:
case System::REDUNDANT:
ssys->result = SLVS_RESULT_INCONSISTENT;
break;

View File

@ -435,7 +435,7 @@ public:
enum {
SOLVED_OKAY = 0,
DIDNT_CONVERGE = 10,
SINGULAR_JACOBIAN = 11,
REDUNDANT = 11,
TOO_MANY_UNKNOWNS = 20
};
int Solve(Group *g, int *dof, List<hConstraint> *bad,

View File

@ -453,7 +453,7 @@ int System::Solve(Group *g, int *dof, List<hConstraint> *bad,
if(andFindBad) {
FindWhichToRemoveToFixJacobian(g, bad);
}
return System::SINGULAR_JACOBIAN;
return System::REDUNDANT;
}
// This is not the full Jacobian, but any substitutions or single-eq
// solves removed one equation and one unknown, therefore no effect

View File

@ -471,12 +471,12 @@ void TextWindow::ShowGroupSolveInfo(void) {
Printf(true, "%FtGROUP %E%s", g->DescriptionString().c_str());
switch(g->solved.how) {
case System::DIDNT_CONVERGE:
Printf(true, "%FxSOLVE FAILED!%Fd no convergence");
Printf(true, "%FxSOLVE FAILED!%Fd unsolvable constraints");
Printf(true, "the following constraints are unsatisfied");
break;
case System::SINGULAR_JACOBIAN:
Printf(true, "%FxSOLVE FAILED!%Fd inconsistent system");
case System::REDUNDANT:
Printf(true, "%FxSOLVE FAILED!%Fd redundant constraints");
Printf(true, "remove any one of these to fix it");
break;