1parameter sweep 2* resistive divider, R1 swept from start_r to stop_r 3* replaces .STEP R1 1k 10k 1k 4* chapter 16.13.4.2 5 6R1 1 2 1k 7R2 2 0 1k 8 9VDD 1 0 DC 1 10.dc VDD 0 1 .1 11 12.control 13let start_r = 1k 14let stop_r = 10k 15let delta_r = 1k 16let r_act = start_r 17* loop 18while r_act le stop_r 19 alter r1 r_act 20 run 21 write dc-sweep.out v(2) 22 set appendwrite 23 let r_act = r_act + delta_r 24end 25plot dc1.v(2) dc2.v(2) dc3.v(2) dc4.v(2) dc5.v(2) 26+ dc6.v(2) dc7.v(2) dc8.v(2) dc9.v(2) dc10.v(2) 27.endc 28 29.end 30