Skip to content

Commit 92f6f6f

Browse files
getEventCouters introduced
1 parent ae18706 commit 92f6f6f

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

src/Symbolic.jl

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ Examples of use can be found in TestSymbolic.jl
1111
module Symbolic
1212

1313
export removeBlock, makeDerVar, append, prepend, Incidence, findIncidence!, linearFactor, solveEquation,
14-
isLinear, getCoefficients, substitute, removeUnits, resetCounters, substituteForEvents
14+
isLinear, getCoefficients, substitute, removeUnits, resetEventCounters, getEventCounters, substituteForEvents
1515

1616
using Base.Meta: isexpr
1717
#using OrderedCollections
@@ -101,7 +101,7 @@ nCrossingFunctions = 0
101101
nClocks = 0
102102
nSamples = 0
103103

104-
function resetCounters()
104+
function resetEventCounters()
105105
global nCrossingFunctions
106106
global nClocks
107107
global nSamples
@@ -110,6 +110,13 @@ function resetCounters()
110110
nSamples = 0
111111
end
112112

113+
function getEventCounters()
114+
global nCrossingFunctions
115+
global nClocks
116+
global nSamples
117+
return (nCrossingFunctions, nClocks, nSamples)
118+
end
119+
113120
substituteForEvents(ex) = ex
114121

115122
function substituteForEvents(ex::Expr)

0 commit comments

Comments
 (0)