Skip to content

Commit

Permalink
- minor changes to some comments
Browse files Browse the repository at this point in the history
git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@25491 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
lochel committed Apr 10, 2015
1 parent 08bd5e0 commit d9e3df5
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
8 changes: 4 additions & 4 deletions Compiler/BackEnd/Initialization.mo
Expand Up @@ -1358,10 +1358,10 @@ algorithm
if not perfectMatching then
Error.addCompilerNotification("The given system is mixed-determined. [index > " + intString(inIndex) + "]");
//BackendDump.dumpEqSystem(syst, "The given system is mixed-determined. [index > " + intString(inIndex) + "]");
fail();
end if;
true := perfectMatching; // if this fails, the system is singular (mixed-determined)

// map to equations
// map artificial variables to redundant equations
range := if nAddVars > 0 then List.intRange2(nVars+1, nVars+nAddVars) else {};
redundantEqns := mapIndices(range, vec1);
//print("{" + stringDelimitList(List.map(redundantEqns, intString),",") + "}\n");
Expand All @@ -1370,13 +1370,13 @@ algorithm
(me, _, _, _) := BackendDAEUtil.getAdjacencyMatrixEnhancedScalar(syst, inShared);
(_, _, _) := consistencyCheck(redundantEqns, inEqns, inVars, inShared, nAddVars, m_, me, vec1, vec2, mapIncRowEqn);

// remove all unassigned equations
// remove redundant equations
outRemovedEqns := BackendEquation.getEqns(redundantEqns, inEqns);
//BackendDump.dumpEquationList(outRemovedEqns, "removed equations");
outEqns := BackendEquation.equationDelete(inEqns, redundantEqns);
//BackendDump.dumpEquationArray(outEqns, "remaining equations");

// map to variables
// map artificial equations to unfixed states
range := if nAddEqs > 0 then List.intRange2(nEqns+1, nEqns+nAddEqs) else {};
range := mapIndices(range, vec2);
//print("{" + stringDelimitList(List.map(range, intString),",") + "}\n");
Expand Down
3 changes: 2 additions & 1 deletion Compiler/BackEnd/Matching.mo
Expand Up @@ -89,7 +89,8 @@ algorithm
end PerfectMatching;

public function RegularMatching "
This function returns at least a partial matching for singular systems."
This function returns at least a partial matching for singular systems.
Unmatched nodes are represented by -1."
input BackendDAE.IncidenceMatrix m;
input Integer nVars;
input Integer nEqns;
Expand Down

0 comments on commit d9e3df5

Please sign in to comment.