LTSpice ideal models
A list of LTSpice ideal models I find very useful during hardware development and simulation. Sometimes, moving to ideal models is a helpful approach to focus on circuit functionality. This allows for a better understanding of the most relevant properties of the component, supporting then the selection process.
Diode
The simplest ideal diode can be modeled in the following way
0
.model MyDiode1 D(Ron=1m Roff=1Meg Vfwd=1m Vrev=1Meg)
This is very ideal! LTSpice will work on a three region model whose transitions are not smooth. You could encounter integration or convergence issues during simulation, especially if your circuit is complex. To avoid this, let's write a slightly more ideal model.
0
.model MyDiode2 D(Ron=1m Roff=1Meg Vfwd=1m Vrev=1Meg Ilimit=10 Revilimit=10 Epsilon=0.5 Revepsilon=0.5)
With this model, you can see how LTSpice applies smooth transition between diode operating regions.
nMOSFET
Well, MOSFETs are very intricated as there are several parameters and many of them are related to physical properties of the device. However, I often found useful the following description
0
.model MyMOS VDMOS(Vto=1.0 Kp=100 Rd=1m Rs=1m Rg=1m Cgdmax=1n Cgdmin=300p Cgs=1n Cjo=1n Rb=10m)
Here I specify the threshold voltage, the transconductance value, drain, source and gate resistance, minimum and maximum Miller capacitance values, gate-source and zero-bias body diode capacitances, diode resistance. This should be enough to run a simulation avoiding all those parameters that increase complexity and distract you from the circuit functionality.
When you are sure your circuit behaves as expected, then you can substitute the ideal model with the one of the chosen component.
Voltage controlled switch
Sometimes, ideal switches are better than transistor: they remove any non-ideality. However they generate abrupt state changes that, in some cases, should be made smoother to improve simulation and ensure convergence.
0
.model MySw1 SW(Vt=2.5 Vh=0.5 Ron=1u Roff=100Meg)
Ron and Roff are pure resistive elements, placed dynamically in the circuit according to the switch state. Vt is the center threshold level, making the switch changing its state; Vh is the input hysteresis: switch turns on at Vt+Vh and turns off at Vt-Vh.
Again, since switches turn on and off very quickly, high current spikes could appear in your circuit, partially invalidating it. To make this components more similar to a silicon-based device, you can add some extra parameters, as shown below:
0
.model MySw2 SW(Vt=2.5 Vh=0.5 Ron=1u Roff=100Meg Lser=10n Vser=0 Ilimit=10)
Lser is a series inductance, useful to limit the current peaks during state transitions. Vser is a series voltage added by the switch. Ilimit is the maximum current allowed in the component; if this limit is reached, current is clamped.
Comments
Be polite and respectful in the comments section. In case of doubts, read this before posting.
Posted comments ⮧
Comment section still empty.
INDEX
INFO


STATISTICS

CONTACTS
SHARE