SIMterix-Simplis~9~ parameter sweep
In LTspice, the most exciting function is .Step. In fact, this function also exists in SS, but its name is .STP. For details, see the multi step analyses section of the manual.
Figure 1: Multi-step analysis instructions
With the instruction manual, let's build a simple circuit diagram (Figure 2) to test the function. Then use F11 to call up the simulation command line. See Figure 3.
Figure 2: RC circuit used for testing
Figure 3: Simulation command line
Code 1: Simulation control code
.simulator SIMETRIX
* represents the simulation time of 1ms. Sweep represents the sweep. Device is the device, and V1 is the device being scanned.
*Device name, STP stands for scan scan type 0 stands for start 5 stands for end, 0.1 stands for step value
.tran 1m SWEEP DEVICE V1 STP 0 5 0.1
.IC V(VOUT)=0
.simulator DEFAULT
|
Code 2: Simulation netlist Note: You can see it under the simulator menu
* C:\Users\xutong\Desktop\simplis 9.sxsch
*#SIMETRIX
V1 V1_P 0 5
R1 VOUT V1_P 1K
C1 VOUT 0 1n
.GRAPH VOUT curveLabel= VOUT nowarn=true ylog=auto xlog=auto analysis=tran|ac|dc disabled=false PROBEREF=Probe1
.tran 1m SWEEP DEVICE V1 STP 0 5 0.1
.IC V(VOUT)=0
|
Figure 4: Simulation results // Attractive crow's feet
In addition to using .STP, there are many options to choose from. Let's look at them one by one, starting with LIN. See code 3
Code 3: Simulation control code
.simulator SIMETRIX
**LIN represents the number of simulation points. The first 5 represents 5 simulation points and 1 represents the starting point is 1.
** The second 5 represents the termination point is 5V
.tran 1m SWEEP DEVICE V1 LIN 5 1 5
.IC V(VOUT)=0
.simulator DEFAULT
|
Figure 5: LIN simulation results
Code 4: Simulation control code
.simulator SIMETRIX
*dec represents the number of points of 10 times the frequency. Here 5 represents 5 points. 1 is the start and 100 is the end.
.tran 1m SWEEP DEVICE V1 DEC 5 1 100
.IC V(VOUT)=0
.simulator DEFAULT
|
Figure 6: DEC simulation points
That’s all for today~ Bye~
Where are you going for the New Year? Promote your hometown and visit Cangnan