* SPICE netlist
V1 Va 0 SINE(0 324.3 50 0 0 {phi_pos})
L1 E N001 100m
V2 E 0 SINE(0 300 50 0)
R1 N001 Va 1
V3 N005 0 PULSE(-509 509 {phi_pos/(3.1415*2*50)} 1n 1n 10m 20m)
L2 N007 N006 100m
V4 N007 0 SINE(0 300 50 0)
R2 N006 N005 1
V5 Vsw 0 PULSE(-1 1 0 1m 1m 0 2m)
V6 Vcarrier 0 SINE(0 0.8 50 {phi_pos/(3.1415*2*50)})
B1 N008 0 V=if(V(Vsw) < V(Vcarrier), 509, -509)
L3 N010 N009 100m
V7 N010 0 SINE(0 300 50 0)
R3 N009 N008 1
V8 N002 0 SINE(0 324.3 50 0 0 {phi_neg})
L4 N004 N003 100m
V9 N004 0 SINE(0 300 50 0)
R4 N003 N002 1
B2 N011 0 V=if(V(Vsw) < V(Vcarrier2), 509, -509)
L5 N013 N012 100m
V10 N013 0 SINE(0 300 50 0)
R5 N012 N011 1
V11 Vcarrier2 0 SINE(0 0.8 50 {phi_neg/(3.1415*2*50)})
.tran 0 1000m 900m
.param phi_pos=30 phi_neg=-30

* LTspice schematic (.asc)
Version 4
SHEET 1 1168 1536
WIRE -136 -752 -584 -752
WIRE -8 -752 -56 -752
WIRE 184 -752 72 -752
WIRE -584 -720 -584 -752
WIRE 184 -720 184 -752
WIRE 184 -608 184 -640
WIRE -584 -592 -584 -640
WIRE -152 -496 -584 -496
WIRE -24 -496 -72 -496
WIRE 168 -496 56 -496
WIRE -584 -464 -584 -496
WIRE 168 -464 168 -496
WIRE 168 -352 168 -384
WIRE -584 -336 -584 -384
WIRE -104 -160 -584 -160
WIRE 24 -160 -24 -160
WIRE 216 -160 104 -160
WIRE 216 -128 216 -160
WIRE -584 -112 -584 -160
WIRE 216 -16 216 -48
WIRE -584 16 -584 -32
WIRE 584 64 584 32
WIRE 584 176 584 144
WIRE -104 208 -584 208
WIRE 24 208 -24 208
WIRE 216 208 104 208
WIRE 216 240 216 208
WIRE -584 256 -584 208
WIRE 216 352 216 320
WIRE 584 352 584 320
WIRE -584 368 -584 336
WIRE -104 464 -584 464
WIRE 24 464 -24 464
WIRE 216 464 104 464
WIRE 584 464 584 432
WIRE 216 496 216 464
WIRE -584 512 -584 464
WIRE 216 608 216 576
WIRE -584 624 -584 592
WIRE 584 656 584 624
WIRE 584 768 584 736
FLAG 184 -608 0
FLAG -584 -592 0
FLAG 184 -752 E
FLAG -584 -752 Va
FLAG 216 -16 0
FLAG -584 16 0
FLAG 584 176 0
FLAG 584 464 0
FLAG -584 368 0
FLAG 584 320 Vcarrier
FLAG 584 32 Vsw
FLAG 216 352 0
FLAG 168 -352 0
FLAG -584 -336 0
FLAG -584 624 0
FLAG 216 608 0
FLAG 584 768 0
FLAG 584 624 Vcarrier2
SYMBOL voltage -584 -736 R0
SYMATTR InstName V1
SYMATTR Value SINE(0 324.3 50 0 0 {phi_pos})
SYMBOL ind 88 -768 R90
SYMATTR InstName L1
SYMATTR Value 100m
SYMBOL voltage 184 -736 R0
SYMATTR InstName V2
SYMATTR Value SINE(0 300 50 0)
SYMBOL res -40 -768 R90
SYMATTR InstName R1
SYMATTR Value 1
SYMBOL voltage -584 -128 R0
SYMATTR Value PULSE(-509 509 {phi_pos/(3.1415*2*50)} 1n 1n 10m 20m)
SYMATTR InstName V3
SYMBOL ind 120 -176 R90
SYMATTR InstName L2
SYMATTR Value 100m
SYMBOL voltage 216 -144 R0
SYMATTR InstName V4
SYMATTR Value SINE(0 300 50 0)
SYMBOL res -8 -176 R90
SYMATTR InstName R2
SYMATTR Value 1
SYMBOL voltage 584 48 R0
SYMATTR InstName V5
SYMATTR Value PULSE(-1 1 0 1m 1m 0 2m)
SYMBOL voltage 584 336 R0
SYMATTR InstName V6
SYMATTR Value SINE(0 0.8 50 {phi_pos/(3.1415*2*50)})
SYMBOL bv -584 240 R0
SYMATTR InstName B1
SYMATTR Value V=if(V(Vsw) < V(Vcarrier), 509, -509)
SYMBOL ind 120 192 R90
SYMATTR InstName L3
SYMATTR Value 100m
SYMBOL voltage 216 224 R0
SYMATTR InstName V7
SYMATTR Value SINE(0 300 50 0)
SYMBOL res -8 192 R90
SYMATTR InstName R3
SYMATTR Value 1
SYMBOL voltage -584 -480 R0
SYMATTR InstName V8
SYMATTR Value SINE(0 324.3 50 0 0 {phi_neg})
SYMBOL ind 72 -512 R90
SYMATTR InstName L4
SYMATTR Value 100m
SYMBOL voltage 168 -480 R0
SYMATTR InstName V9
SYMATTR Value SINE(0 300 50 0)
SYMBOL res -56 -512 R90
SYMATTR InstName R4
SYMATTR Value 1
SYMBOL bv -584 496 R0
SYMATTR InstName B2
SYMATTR Value V=if(V(Vsw) < V(Vcarrier2), 509, -509)
SYMBOL ind 120 448 R90
SYMATTR InstName L5
SYMATTR Value 100m
SYMBOL voltage 216 480 R0
SYMATTR InstName V10
SYMATTR Value SINE(0 300 50 0)
SYMBOL res -8 448 R90
SYMATTR InstName R5
SYMATTR Value 1
SYMBOL voltage 584 640 R0
SYMATTR InstName V11
SYMATTR Value SINE(0 0.8 50 {phi_neg/(3.1415*2*50)})