-
-
Notifications
You must be signed in to change notification settings - Fork 232
Closed
Description
function switch(;name)
@named p = Pin()
@named n = Pin()
#@parameters sig = m
sts = @variables begin
v(t)
i(t)
end
sc = [10] => [i ~ 0]
eqs = [v ~ p.v - n.v
0 ~ p.i + n.i
i ~ p.i]
injection = (t == 10) => [i ~ 0]
modelll=compose(ODESystem(eqs, t, sts, []; name=name), p, n)
@named modelf = ODESystem(modelll, t, [], []; discrete_events = injection)
return modelf
end
@named igbt1 = switch()
Metadata
Metadata
Assignees
Labels
No labels