Skip to content
This repository has been archived by the owner on May 18, 2019. It is now read-only.

Commit

Permalink
Use ZeroCrossingSet where necessary
Browse files Browse the repository at this point in the history
  • Loading branch information
hkiel committed Apr 11, 2019
1 parent 2e52c37 commit 28d0c1a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
8 changes: 4 additions & 4 deletions Compiler/BackEnd/FindZeroCrossings.mo
Original file line number Diff line number Diff line change
Expand Up @@ -811,7 +811,7 @@ end findZeroCrossingsIfEqns;
protected function findZeroCrossingsinJacobians
input BackendDAE.StrongComponents inStrongComponents;
input BackendDAE.ZeroCrossingSet zeroCrossingLst;
input DoubleEndedList<BackendDAE.ZeroCrossing> relationsLst;
input BackendDAE.ZeroCrossingSet relationsLst;
input BackendDAE.ZeroCrossingSet samplesLst;
input BackendDAE.Variables allVariables;
input BackendDAE.Variables globalKnownVars;
Expand Down Expand Up @@ -855,7 +855,7 @@ end findZeroCrossingsinJacobians;
protected function replaceZCExpinFullJacobian
input BackendDAE.FullJacobian fullJac;
input BackendDAE.ZeroCrossingSet zeroCrossingLst;
input DoubleEndedList<BackendDAE.ZeroCrossing> relationsLst;
input BackendDAE.ZeroCrossingSet relationsLst;
input BackendDAE.ZeroCrossingSet samplesLst;
input BackendDAE.Variables allVariables;
input BackendDAE.Variables globalKnownVars;
Expand All @@ -881,7 +881,7 @@ end replaceZCExpinFullJacobian;
protected function replaceZCExpinSymJacobian
input BackendDAE.SymbolicJacobian symJac;
input BackendDAE.ZeroCrossingSet zeroCrossingLst;
input DoubleEndedList<BackendDAE.ZeroCrossing> relationsLst;
input BackendDAE.ZeroCrossingSet relationsLst;
input BackendDAE.ZeroCrossingSet samplesLst;
input BackendDAE.Variables allVariables;
input BackendDAE.Variables globalKnownVars;
Expand All @@ -900,7 +900,7 @@ end replaceZCExpinSymJacobian;
protected function replaceZeroCrossingsJacBackend
input BackendDAE.BackendDAE inBackendDAE;
input BackendDAE.ZeroCrossingSet zeroCrossingLst;
input DoubleEndedList<BackendDAE.ZeroCrossing> relationsLst;
input BackendDAE.ZeroCrossingSet relationsLst;
input BackendDAE.ZeroCrossingSet samplesLst;
input BackendDAE.Variables allVariables;
input BackendDAE.Variables globalKnownVars;
Expand Down
4 changes: 2 additions & 2 deletions Compiler/SimCode/SimCodeMain.mo
Original file line number Diff line number Diff line change
Expand Up @@ -1131,7 +1131,7 @@ protected
list<DAE.ComponentRef> discreteModelVars;
list<BackendDAE.TimeEvent> timeEvents;
BackendDAE.ZeroCrossingSet zeroCrossingsSet, sampleZCSet;
DoubleEndedList<BackendDAE.ZeroCrossing> de_relations;
BackendDAE.ZeroCrossingSet de_relations;
list<BackendDAE.ZeroCrossing> zeroCrossings, sampleZC, relations;

BackendDAE.Variables daeVars, resVars, algStateVars, auxVars;
Expand Down Expand Up @@ -1179,7 +1179,7 @@ algorithm
timeEvents := inBackendDAE.shared.eventInfo.timeEvents;
(zeroCrossings,relations,sampleZC) := match inBackendDAE.shared.eventInfo
case BackendDAE.EVENT_INFO(zeroCrossings=zeroCrossingsSet, relations=de_relations, samples=sampleZCSet)
then (ZeroCrossings.toList(zeroCrossingsSet), DoubleEndedList.toListNoCopyNoClear(de_relations), ZeroCrossings.toList(sampleZCSet));
then (ZeroCrossings.toList(zeroCrossingsSet), ZeroCrossings.toList(de_relations), ZeroCrossings.toList(sampleZCSet));
end match;

// initialization stuff
Expand Down

0 comments on commit 28d0c1a

Please sign in to comment.