Opened 12 years ago
Last modified 7 years ago
#2014 closed task
Modelica.Electrical.Spice3.Examples.CascodeCircuit — at Initial Version
Reported by: | Jens Frenkel | Owned by: | Jens Frenkel |
---|---|---|---|
Priority: | normal | Milestone: | 1.9.1 |
Component: | Backend | Version: | trunk |
Keywords: | index reduction, remove simple equations | Cc: | christian.schubert@… |
Description
The model Modelica.Electrical.Spice3.Examples.CascodeCircuit fails in simulation because the equations
4/8 (1): J1.icGD = J1.cc.cGD * der(J1.vGD) 5/9 (1): J1.icGS = J1.cc.cGS * der(J1.vGS) 13/21 (1): J2.icGD = J2.cc.cGD * der(J2.vGD) 14/22 (1): J2.icGS = J2.cc.cGS * der(J2.vGS)
are not solvable for the der(...) variables because J*.cc.cGD is zero.
If you take a look at the equation
22/30 (1): J2.vGS = v_sin.VO + (if time < v_sin.TD then 0.0 else v_sin.VA * exp((v_sin.TD - time) * v_sin.THETA) * sin(6.283185307179586 * v_sin.FREQ * (time - v_sin.TD)))
you see that the state candidate J2.vGS is the only unkown variable in the equation. Hence the variable J2.vGS is purely algebraic and the variable der(J2.vGS) is known as
der(J2.vGS) = if time < v_sin.TD then 0.0 else v_sin.VA * (exp((v_sin.TD - time) * v_sin.THETA) * 6.283185307179586 * v_sin.FREQ * cos(6.283185307179586 * v_sin.FREQ * (time - v_sin.TD)) + (-v_sin.THETA) * exp((v_sin.TD - time) * v_sin.THETA) * sin(6.283185307179586 * v_sin.FREQ * (time - v_sin.TD)))
Subsequently the variable J2.igsgmin is known from equation
15/23 (1): J2.igsgmin = 0.000000000001 * J2.vGS
and should be used to calculate the state candidates J1.vGS, J1.vGD and J2.vGD with the equations
6/10 (1): J1.igsgmin = 0.000000000001 * J1.vGS 7/11 (1): J1.igdgmin = 0.000000000001 * J1.vGD 16/24 (1): J2.igdgmin = 0.000000000001 * J2.vGD
Finally all state candidates are algebraic variables and the model is solvable.