@@ -65,17 +65,17 @@ public function traverseAdjacencyMatrix<T>
6565 output BackendDAE . AdjacencyMatrix outM;
6666 output T outTypeA;
6767 partial function FuncType
68- input BackendDAE . IncidenceMatrixElement elem;
68+ input BackendDAE . AdjacencyMatrixElement elem;
6969 input Integer pos;
7070 input T inTpl;
7171 output list< Integer > outList;
7272 output T outTpl;
7373 end FuncType ;
7474algorithm
75- (outM, outTypeA) := traverseIncidenceMatrix1 (inM, func , 1 , arrayLength(inM), inTypeA);
75+ (outM, outTypeA) := traverseAdjacencyMatrix1 (inM, func , 1 , arrayLength(inM), inTypeA);
7676end traverseAdjacencyMatrix;
7777
78- protected function traverseIncidenceMatrix1 < T >
78+ protected function traverseAdjacencyMatrix1 < T >
7979 input BackendDAE . AdjacencyMatrix inM;
8080 input FuncType func ;
8181 input Integer pos "iterated 1..len" ;
@@ -84,18 +84,18 @@ protected function traverseIncidenceMatrix1<T>
8484 output BackendDAE . AdjacencyMatrix outM;
8585 output T outTypeA;
8686 partial function FuncType
87- input BackendDAE . IncidenceMatrixElement elem;
87+ input BackendDAE . AdjacencyMatrixElement elem;
8888 input Integer pos;
8989 input T inTpl;
9090 output list< Integer > outList;
9191 output T outTpl;
9292 end FuncType ;
9393algorithm
94- (outM, outTypeA) := traverseIncidenceMatrix2 (inM, func , pos, len, intGt(pos, len), inTypeA);
94+ (outM, outTypeA) := traverseAdjacencyMatrix2 (inM, func , pos, len, intGt(pos, len), inTypeA);
9595 annotation(__OpenModelica_EarlyInline = true );
96- end traverseIncidenceMatrix1 ;
96+ end traverseAdjacencyMatrix1 ;
9797
98- protected function traverseIncidenceMatrix2 < T >
98+ protected function traverseAdjacencyMatrix2 < T >
9999 input BackendDAE . AdjacencyMatrix inM;
100100 input FuncType func ;
101101 input Integer pos "iterated 1..len" ;
@@ -105,7 +105,7 @@ protected function traverseIncidenceMatrix2<T>
105105 output BackendDAE . AdjacencyMatrix outM;
106106 output T outTypeA;
107107 partial function FuncType
108- input BackendDAE . IncidenceMatrixElement elem;
108+ input BackendDAE . AdjacencyMatrixElement elem;
109109 input Integer pos;
110110 input T inTpl;
111111 output list< Integer > outList;
@@ -124,13 +124,13 @@ algorithm
124124 case false equation
125125 (eqns, extArg) = func (inM[pos], pos, inTypeA);
126126 eqns1 = List . removeOnTrue(pos, intLt, eqns);
127- (m1, extArg1) = traverseIncidenceMatrixList (eqns1, inM, func , arrayLength(inM), pos, extArg);
128- (m2, extArg2) = traverseIncidenceMatrix2 (m1, func , pos+ 1 , len, intGt(pos+ 1 , len), extArg1);
127+ (m1, extArg1) = traverseAdjacencyMatrixList (eqns1, inM, func , arrayLength(inM), pos, extArg);
128+ (m2, extArg2) = traverseAdjacencyMatrix2 (m1, func , pos+ 1 , len, intGt(pos+ 1 , len), extArg1);
129129 then (m2, extArg2);
130130 end match;
131- end traverseIncidenceMatrix2 ;
131+ end traverseAdjacencyMatrix2 ;
132132
133- protected function traverseIncidenceMatrixList < T >
133+ protected function traverseAdjacencyMatrixList < T >
134134 input list< Integer > inLst "elements to traverse" ;
135135 input BackendDAE . AdjacencyMatrix inM;
136136 input FuncType func ;
@@ -140,7 +140,7 @@ protected function traverseIncidenceMatrixList<T>
140140 output BackendDAE . AdjacencyMatrix outM;
141141 output T outTypeA;
142142 partial function FuncType
143- input BackendDAE . IncidenceMatrixElement elem;
143+ input BackendDAE . AdjacencyMatrixElement elem;
144144 input Integer pos;
145145 input T inTpl;
146146 output list< Integer > outList;
@@ -165,24 +165,24 @@ algorithm
165165 (eqns, extArg) = func (inM[pos], pos, inTypeA);
166166 eqns1 = List . removeOnTrue(maxpos, intLt, eqns);
167167 alleqns = List . unionOnTrueList({rest, eqns1}, intEq);
168- (m, extArg1) = traverseIncidenceMatrixList (alleqns, inM, func , len, maxpos, extArg);
168+ (m, extArg1) = traverseAdjacencyMatrixList (alleqns, inM, func , len, maxpos, extArg);
169169 then (m, extArg1);
170170
171171 case (pos::rest) equation
172172 // do not leave the list
173173 true = intLt(pos, len+ 1 );
174- (m, extArg) = traverseIncidenceMatrixList (rest, inM, func , len, maxpos, inTypeA);
174+ (m, extArg) = traverseAdjacencyMatrixList (rest, inM, func , len, maxpos, inTypeA);
175175 then (m, extArg);
176176
177177 else equation
178178 true = Flags . isSet(Flags . FAILTRACE );
179- Debug . trace("- BackendDAEOptimize.traverseIncidenceMatrixList failed \n " );
179+ Debug . trace("- BackendDAEOptimize.traverseAdjacencyMatrixList failed \n " );
180180 then fail();
181181 end matchcontinue;
182- end traverseIncidenceMatrixList ;
182+ end traverseAdjacencyMatrixList ;
183183
184184public function getOtherEqSysAdjacencyMatrix
185- "This function removes tvar and res from incidence matrix."
185+ "This function removes tvar and res from adjacency matrix."
186186 input BackendDAE . AdjacencyMatrix m;
187187 input Integer size;
188188 input Integer index;
@@ -219,7 +219,7 @@ algorithm
219219end isAssigned;
220220
221221public function transposeAdjacencyMatrix
222- "Calculates the transpose of the incidence matrix,
222+ "Calculates the transpose of the adjacency matrix,
223223 i.e. which equations each variable is present in."
224224 input BackendDAE . AdjacencyMatrix m;
225225 input Integer nRowsMt;
@@ -263,7 +263,7 @@ algorithm
263263end transposeRow;
264264
265265public function absAdjacencyMatrix "author: PA
266- Applies absolute value to all entries in the incidence matrix.
266+ Applies absolute value to all entries in the adjacency matrix.
267267 This can be used when e.g. der(x) and x are considered the same variable."
268268 input BackendDAE . AdjacencyMatrix m;
269269 output BackendDAE . AdjacencyMatrix res;
0 commit comments