Skip to content

Commit

Permalink
- BackendDump.printEquation use equationStr
Browse files Browse the repository at this point in the history
- SimCode: handle also Record(..) = f(..) for nonliniear systems

git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@12454 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
Jens Frenkel committed Aug 8, 2012
1 parent a760503 commit cb45e0f
Show file tree
Hide file tree
Showing 2 changed files with 517 additions and 255 deletions.
33 changes: 1 addition & 32 deletions Compiler/BackEnd/BackendDump.mo
Expand Up @@ -221,38 +221,7 @@ public function printEquation "function: printEquation
"
input BackendDAE.Equation inEquation;
algorithm
_:=
match (inEquation)
local
String s1,s2,res;
DAE.Exp e1,e2;
DAE.ComponentRef cr;
BackendDAE.WhenEquation w;
case (BackendDAE.EQUATION(exp = e1,scalar = e2))
equation
s1 = ExpressionDump.printExpStr(e1);
s2 = ExpressionDump.printExpStr(e2);
res = stringAppendList({s1," = ",s2,"\n"});
print(res);
then
();
case (BackendDAE.RESIDUAL_EQUATION(exp = e1))
equation
s1 = ExpressionDump.printExpStr(e1);
res = stringAppendList({s1,"\n"});
print(res);
then
();
case (BackendDAE.WHEN_EQUATION(whenEquation = w))
equation
(cr,e2) = BackendEquation.getWhenEquationExpr(w);
s1 = ComponentReference.printComponentRefStr(cr);
s2 = ExpressionDump.printExpStr(e2);
res = stringAppendList({s1," = ",s2,"\n"});
print(res);
then
();
end match;
print(equationStr(inEquation) +& "\n");
end printEquation;

public function dumpEquation "function: dumpEquation
Expand Down

0 comments on commit cb45e0f

Please sign in to comment.