Zorro
|
hello everybody,
I am writing a model that contains an internal diode. this diode is only used when a certain condition arises, and is therefore embedded within an if statement. The equation I am using is: I(Diode) <+ is*(exp(V(Diode)/$vt)-1)
However I tend to get convergence problems, and when I try to use the limexp function, it compiles ok but the elaborator does not like it. It says that is only possible to use it outside of the if statement.
I do not want to perform the limexp function outside of the if statement and return the result inside the "if" when called, because then the simulator is having to make an unwanted calculation constantly, and hence slowing the process down and using more memory space.
So my question is, is there a way of using the limexp function only when called (i.e. the if statement becomes true)?
Regards, Douglas Paniagua :P
|