Simulating Power Supplies with
SPICE
Agenda
Why simulating power supplies?
Average modeling techniques
The PWM switch concept, CCM
The PWM switch concept, DCM
The voltage-mode model at work
Current-mode modeling
The current-mode model at work
Power factor correction
Switching models
EMI filtering
Conclusion
Agenda
Why simulating power supplies?
Average modeling techniques
The PWM switch concept, CCM
The PWM switch concept, DCM
The voltage-mode model at work
Current-mode modeling
The current-mode model at work
Power factor correction
Switching models
EMI filtering
Conclusion
Simulation helps feeling how the product behaves before breadboard
Experiment What If? at any level. Power libraries do not blow!
Easily shows impact of parameter variations: ESR, Load etc.
Draw Bode plots without using costly equipments
Avoid trials and errors: compensate the loop on the PC first!
Use SPICE to assess current amplitudes, voltage stresses etc.
Go to the lab. and check if the assumptions were valid.
Why Simulate Switch Mode Power Supplies?
SPICE does NOT NOT replace the breadboard!
SPICE
Calm down!
An average model is made of equations that are continuous in time
The switching component has disappeared, leading to:
a simpler ac analysis of the power supply
the study of the stability margins in various conditions
the assessment of the ESRs contributions in the loop stability
a flashing simulation time!
Why Average Simulations? Average
Average modeling
1
Rload 3
5
Resr 100m
Cout 220uF
2
Vg AC = 0
Vout
4
Duty
V2 AC = 1
3
Vin Vout
Gnd Ctrl AC model
D
RS = 20m FS = 50k VOUT = 5 RL = 3 VIN = 11 X1 RI = 0.33 L = 37.5u
0 0 0
0.458 0
An switching model is like breadboarding on the PC
The switching component is back in place, leading to:
the analysis of current and voltage stresses
the study of leakage and stray elements impacts
the analysis of the input current signature – EMI
a longer simulation time…
Why Switching Simulations? Switching
Switching approach
1vout2il
3.50 4.50 5.50 6.50 7.50
vout in voltsPlot1 1
1.00 1.40 1.80 2.20
il in amperesPlot2
2 7
4
10
1
6
2
14 12
3
8
19
5 15
RESR_C3 0.3702 C2
100U IC = 11.9999
C3 {220u/DIV}
IC = 230
C4 1n
R_X2_SEC 13M D5 DN4934 C5
{0.68u/DIV}
IC = 0
RLOAD 657 D6
MUR130 R4
100K
R5 22K
R8 1.0MEG L_X2_PR 320U
R9 11K R_X2_PR 0.162
R10 0.1 X3 MTP8N50
VCC Vsw VOUT
Zero_CD
CS * Pout
I_LOAD Vdrv
FB CTRL Ct CS ZCD
GND DRV Vcc X1 Config_1
VCTRL
Agenda
Why simulating power supplies?
Average modeling techniques
The PWM switch concept, CCM
The PWM switch concept, DCM
The voltage-mode model at work
Current-mode modeling
The current-mode model at work
Power factor correction
Switching models
EMI filtering
Conclusion
Average Modeling, the SSA
State-State-SpaceSpace Averaging (SSA)Averaging
Introduced by Slobodan Ćuk in the 80’
Long and painful process
Fails to predict sub-harmonic oscillations
Lu Lx dt
dx 1
1 2 1=− +
. 2 1 1
1
2 x
Cout Rload Coutx
dt
dx = −
1 2
1 x
L dt dx =−
. 2 1 1
1
2 x
Cout Rload Cout x
dt
dx = −
Vout
L
C R
x1
x2 u1
Vout
L
C R
x1
x2 on off
Apply smoothing process Linearize
Pfffff!
/
ON OFF
Average Modeling, the PWM Switch
The PWM SwitchPWM Switch
Introduced by Vatché Vorpérian in the mid-80’
Easy to derive and fully invariant
No auto-toggling mode models
Can predict sub-harmonic oscillations in CCM
DCM model in current-mode was never published!
c a
p
d d'
Ia(t) Ic(t)
Vap(t) Vcp(t)
a c
PWM switch p
d d'
Vin
L
C R Vout
The PWM Switch Concept
Vin L
C R Vout
ac PWM switchp
d d'
Linear network
Linear network
off
on
diode + transistor = guilty for non-linearity!
Identify the guilty network: the transistor and the diode
Average their voltage and current waveforms: large-signal model
Linearize the equations around a dc point: small-signal model
Agenda
Why simulating power supplies?
Average modeling techniques
The PWM switch concept, CCM
The PWM switch concept, DCM
The voltage-mode model at work
Current-mode modeling
The current-mode model at work
Power factor correction
Switching models
EMI filtering
Conclusion
The PWM Switch Concept
1
4
2
Q1
5
Rb_upper 1Meg
Rb_lower 100k Vg
Vout
8
3 7
h11 Beta.Ib
Rc 10k
Re 150
Ce 1nF Req
Rb_upper//Rb_lower
b c
e
ib ic
ie
Rc Vin 10k
Re 150
Ce 1nF Vin
Vout
Ve
Remember the bipolars Ebers-Moll model…
Replace Q1 by its small-signal model
The transistor is a highly non-linear device:
Replace the transistor with its small-signal model
Solve a system of linear equations
The PWM Switch Concept
a c
PWM switch p d
d'
Vin
L
C R
Vout Vin
L
C R Vout
ac PWM switchp
d d'
Vin
L
C R Vout
ac PWM switchp
d d'
c a
p
d d'
Ia(t) Ic(t)
Vap(t) Vcp(t)
BuckBuck Boost Boost Buck-Buck-
boost boost
The PWM switch model works in all two switch converters:
Rotate the model to match the switch and diode connections
Solve a system of linear equations
The PWM Switch Concept
a c
p
d d'
Ia(t) Ic(t)
Vap(t) Vcp(t)
Vin
L
C R
Vout
( ) 1 ( ) ( )
sw
sw sw
T
a T a a c T c
I t I I t dt d I t dI
= =T ∫ = = Vcp( )t T Vcp 1 TswVcp( )t dt d Vap( )t T dVap
= =T ∫ = =
The keyword with average modeling: waveforms averaging
The PWM Switch Concept
c a
p
Ia(t) Ic(t)
V=d.V(a,p)
p
I=d.Ic
Large-signal (non-linear) model
The obtained set of equations is that of a transformer
¾ A CCM two-switch DC-DC can be modeled like a 1:D transformer!
V1 V2
I1 I2
1:N
2 1
V = NV
1 2
I = NI
a c
p
Ia(t) Ic(t)
1 d
Vap Vcp
The PWM Switch Concept
L
d
100uH
Vbias 0.4 AC = 1
C1 100u
R1 10
Vout
Vin 10
a
c p
10.0 10.0
16.7 0.400
Always verify the dc operating point!
SPICE only deals with linear equations
It first computes a bias point then it linearizes the network
1 10 100 1k 10k 100k
-30.0 -10.0 10.0 30.0 50.0
1 2 3 4
d = 40%, Vout= 16.7 V d = 10%, Vout= 11.1 V
dB
( ) ( )
Vout s d s
No equations, result appears in a second!
Make sure the bias point is correct…
The PWM Switch Concept
We have a set of non-linear equations: can’t derive transfer functions!
We need a small-signal model: linearize the equations by hand
two options: perturbation or partial derivatives…
Pertubation Partial derivatives
0 0
0
ˆ ˆ ˆ
a c
a a a
c c c
I dI
I I i
I I i
d d d
=
= +
= +
= +
0
0
ˆ ˆ
cp ap
cp cp cp
V dV
V V v
d d d
=
= +
= +
( ) ( )
0 ˆ 0 ˆ 0 ˆ
a a c c
I + =i d + d I +i
0 0 0
0 ˆ 0
ˆ ˆ
a c
a c c
I d I i d i dI
=
= +
ac and dc equations
ˆ ˆ ˆ
a c
a a
a c
c
I dI
I I
i i d
I d
=
∂ ∂
= +
∂ ∂ ˆ ˆ ˆ
cp ap
cp cp
cp ap
ap
V dV
V V
v v d
V d
=
∂ ∂
= +
∂ ∂
0 ˆ 0
ˆ ˆ
a c c
i = d i + dI
0 0 0
0 ˆ 0
ˆ ˆ
cp ap
cp ap ap
V d V
v d v dV
=
= +
same
0 ˆ 0
ˆcp ˆap ap v = d v + dV
ac equations No dc point
The PWM Switch Concept
Put the small-signal sources in the large-signal model
You obtain the small-signal model of the CCM PWM switch
a c
p
0 0 0
0 ˆ 0
ˆ ˆ
cp ap
cp ap ap
V d V
v d v dV
=
= +
(
Vap d0)
dˆ0 ˆ
ap ap
V + v
0 ˆ
c c
I +i
V1 0 c0
d I
(
0)
ˆ ˆ
c c
d I +i
You can now analytically find the dc bias and the ac response!
Agenda
Why simulating power supplies?
Average modeling techniques
The PWM switch concept, CCM
The PWM switch concept, DCM
The voltage-mode model at work
Current-mode modeling
The current-mode model at work
Power factor correction
Switching models
EMI filtering
Conclusion
The PWM Switch in DCM
c a
p
d1 d2
Ia(t) Ic(t)
Vap(t) Vcp(t)
Vin
L
C R
Vout
d3
Ia
Ipeak
Vap
Ipeak Ic
Vcp
Vap
Vcp
d1Tsw d2Tsw d3Tsw
t t
t t Ia
Ipeak
Vap
Ipeak Ic
Vcp
Vap
Vcp
d1Tsw d2Tsw d3Tsw
t t
t t
The original model could not be auto-toggling
A new DCM-CCM model has been derived
( )
( )
1
1 2
1 2
2 2
peak a
peak c
c a
I d I
I d d
I
d d I I
d
=
= +
= +
Extract and replace
The PWM Switch in DCM
a c
p
Ia(t) Ic(t)
1 N
Vap Vcp
N=d1/(d1+d2)
1
2 1
1 1
2
c ac²
sw2
sw cac sw ac
I L V d T LF I
d d
V d T d V
= − = −
Model input Clamp d
2: d
2CCM = 1- d
1d
2DCM = 1- d
1- d
3d
2< 1 - d
1model is in DCM!
By clamping the d2 equation, the circuit toggles between the modes
Agenda
Why simulating power supplies?
Average modeling techniques
The PWM switch concept, CCM
The PWM switch concept, DCM
The voltage-mode model at work
Current-mode modeling
The current-mode model at work
Power factor correction
Switching models
EMI filtering
Conclusion
The PWM Switch in DCM
3
V4 10
4
L1 75u
17 d
a c
PWM switch VM p
X4
PWMCCMVM
GAIN
XPWM GAIN K = 0.5 10.0
5.00
0.500
In voltage-mode, the duty-cycle is built with a ramp generator
The transition occurs when the error voltage crosses the ramp
( )
on( ) ( )
err peak peak
sw
t t
V t V V d t
= T =
V
peak0
V
err0
Vramp(t)
d(t)
ton Tsw
( )
err( )
peak
V t d t = V
( ) ( )
1 PWMerr peak
d d t
d V t V K
⎛ ⎞
= =
⎜ ⎟
⎜ ⎟
⎝ ⎠
Vpeak = 2 V
The Voltage-Mode Model at Work
Let us compensate a buck converter operated in CCM and DCM 1. Run an open-loop Bode plot at full load, lowest input
2. Identify the excess/deficiency of gain at the selected cross over
3. Place a double zero at f0, a pole at the ESR zero and a pole at Fsw/2 4. Check final loop gain and run a transient load test
Vout2
16
Cout 220u
Resr 150m
2 13
L1 180u
6
Rupper 38k
Rlower 10k
9 5
X2 AMPSIMP
V2 2.5
vout
d
a c
PWM switch VM p
4
7
X3 PWMVM L = 180u Fs = 100k
GAIN
15
XPWM GAIN K = 0.4
R4 20m
LoL 1kH
10
CoL 1kF
V1 AC = 1 Vin
vout
Vout
12
R2 {R2}
C1 {C1}
C2 {C2}
8
R3 {R3}
C3 {C3}
Rload 3 Vin
20
12.0V
12.0V 12.0V
2.50V
2.50V 1.51V
20.0V
12.1V 604mV
1.51V
1.51V 12.0V
parameters Rupper=38k fc=7k Gfc=-15 G=10^(-Gfc/20) pi=3.14159 fz1=650 fz2=650 fp1=7k fp2=50k
C3=1/(2*pi*fz1*Rupper) R3 =1/(2*pi*fp2*C3) C1=1/(2*pi*fz2*R2) C2=1/(2*pi*(fp1)*R2)
a=fc^4+fc^2*fz1^2+fc^2*fz2^2+fz1^2*fz2^2 c=fp2^2*fp1^2+fc^2*fp2^2+fc^2*fp1^2+fc^4 R2=sqrt(c/a)*G*fc*R3/fp1
Automated compensation
H(s)
T(s)
The Voltage-Mode Model at Work
-24.0 -12.0 0 12.0 24.0
-180 -90.0 0 90.0
180
2
1
10 100 1k 10k 100k
-180 -90.0 0 90.0
180
-40.0 -20.0 0 20.0 40.0
3 4
Pm = 80°
fc = 7 kHz
|H(7 kHz)| =-15 dB
ArgH(7 kHz) =-121°
ArgT(s)
|H(s)|
9.91m 11.0m 12.1m 13.3m 14.4m
11.6 11.8 12.0 12.2 12.4
1 2
The Bode plot reveals a gain loss of -15 dB at 7 kHz
The compensator provides a +15 dB gain increase plus phase boost
The final loop gain shows a comfortable phase margin
The transient response at both input levels shows a stable signal
|T(s)|
arg|H(s)|
V
out(t)
Iout = 200 mA to 4 A in 10 µs
Agenda
Why simulating power supplies?
Average modeling techniques
The PWM switch concept, CCM
The PWM switch concept, DCM
The voltage-mode model at work
Current-mode modeling
The current-mode model at work
Power factor correction
Switching models
EMI filtering
Conclusion
Current-Mode Operation
In voltage-mode, the error signal directly controls the duty cycle
In current mode, the error voltage sets the inductor peak current
To derive a model, observe the current signals and average them!
( ) ( ) ( ) '( )
2
(1 )
2
f sw
c i c sw e
c sw e sw
c cp
i i
S d t T I t R V t d t T S
V T S T
I d V d
R R L
= − −
= − − −
1 2
3
c a
p
Ia(t)
Ic(t)
I=Vc/Ri
p
I=d.Ic I=Iu Cs
( ) ( ) ( ) '( )
2
(1 )
2
f sw
c i c sw e
c sw e sw
c cp
i i
S d t T I t R V t d t T S
V T S T
I d V d
R R L
= − −
= − − −
1 2
3
c a
p
Ia(t)
Ic(t)
I=Vc/Ri
p
I=d.Ic I=Iu Cs
1
2
3
CCM
Current-Mode Operation
Do the same for DCM signals
Match the previous structure to build a CCM/DCM model
c a
p
Ia(t) Ic(t)
I=Vc/Ri
p
I=(d1/(d1+d2)).Ic I=Iu
3rd event linked to DCM
1
1
2
1 1 2
2 1
2
c sw e
peak
i
c sw e
c sw f
i sw e cp
sw i
V d T S
I R
V d T S
I d T S
R
d T S V d d
I d T
R L
μ
α
= −
= − −
⎛ + ⎞
= + ⎜⎝ − ⎟⎠
α
DCM
Agenda
Why simulating power supplies?
Average modeling techniques
The PWM switch concept, CCM
The PWM switch concept, DCM
The voltage-mode model at work
Current-mode modeling
The current-mode model at work
Power factor correction
Switching models
EMI filtering
Conclusion
The Current-Mode Model at Work
To study a converter, we can write down the equations
Or use a SPICE simulation to get the Bode plot in a second
Take the example of a current-mode flyback converter
( ) 2
1
2 2
2
1 3
10 0 2 2 2 2
1 1 1
20 log 1
1 1
z z z
p n n p
f f f
f f f
H f G
f f f
f f f Q
⎡ ⎤
⎛ ⎞ ⎛ ⎞
⎛ ⎞
⎢ ⎥
+⎜ ⎟ +⎜ ⎟ +⎜ ⎟
⎢ ⎝ ⎠ ⎜⎝ ⎟⎠ ⎝ ⎠ ⎥
⎢ ⎥
= ⎢ ⎥
⎛ ⎞ ⎛ ⎞ ⎛ ⎞
⎢ + ⎜ ⎟ ⎜ −⎛⎜ ⎞⎟ ⎟ + ⎜ ⎟ ⎥
⎢ ⎜⎝ ⎟⎠ ⎜ ⎝ ⎠ ⎟ ⎜⎝ ⎟⎠ ⎥
⎢ ⎝ ⎠ ⎥
⎣ ⎦
( )
1 2 3 1
1 1 1 1 1
2
arg tan tan tan tan tan 1
z z z p n p 1
n
f f f f f
H f f f f f f Q f
f
− − − − −
⎛ ⎞
⎜ ⎟
⎛ ⎞
⎛ ⎞ ⎛ ⎞ ⎛ ⎞ ⎜ ⎟
= ⎜⎜⎝ ⎟⎟⎠− ⎜⎜⎝ ⎟⎟⎠+ ⎜⎜⎝ ⎟⎟⎠− ⎜⎜⎝ ⎟⎟⎠− ⎜⎜⎜⎝ − ⎜ ⎟⎛⎝ ⎞⎠ ⎟⎟⎟⎠
Stabilizing a CCM Flyback Converter
Capture a SPICE schematic with an averaged model
1
C5 6600u R10 14.4m
2
Vin 90 AC = 0
3 4
X2x XFMR
RATIO = -0.25 vout
vout DC 6
8 13
L1 {Lp}
D1A
mbr20200ctp
B1 Voltage V(errP)/3 > 1 ? 1 : V(errP)/3
Rload 4
vcac PWM switch CMp
duty-cycle
X9 PWMCM L = Lp Fs = 65k Ri = 0.25 Se = 0
19.0V 19.0V 90.0V
-78.8V 19.7V
467mV
0V
786mV
Look for the bias points values: V
out= 19 V, ok
V
setpoint< 1 V, enough margin on current sense
Stabilizing a CCM Flyback Converter
Capture a SPICE schematic with an averaged model
18
Verr
Cpole2 {Cpole}
10 9
11
vout
X8
Optocoupler Fp = Pole CTR = CTR
Czero1 {Czero}
Rpullup {Rpullup}
5
Rled {Rled}
Rlower2 {Rlower}
Rupper2 {Rupper}
X10 TL431_G Vdd
5 errP
X4 POLE FP = pole
K = 1 K S+A
R7 1 err
14
LoL 1kH
Vstim AC = 1
15
CoL 1kF
2.36V
0V 2.36V 2.36V
2.36V 18.7V
2.49V 17.7V
5.00V
parameters Vout=19 Ibridge=250u Rlower=2.5/Ibridge
Rupper=(Vout-2.5)/Ibridge Lp=350u
Se=20k fc=1k pm=60 Gfc=-22 pfc=-71
G=10^(-Gfc/20) boost=pm-(pfc)-90 pi=3.14159
K=tan((boost/2+45)*pi/180) Fzero=fc/k
Fpole=k*fc Rpullup=20k
RLED=CTR*Rpullup/G
Czero=1/(2*pi*Fzero*Rupper) Cpole=1/(2*pi*Fpole*Rpullup) CTR=1.5
Pole=6k
from Bode
Stabilizing a CCM Flyback Converter
Capture a SPICE schematic with an averaged model
-32.0 -16.0 0 16.0 32.0
4
-180 -90.0 0 90.0 180
6
Gain at 1 kHz -22 dB
Phase at 1 kHz -71 °
|H(s)|
argH(s)
Sub harmonic poles
Inject ramp compensation
ramp
Stabilizing a CCM Flyback Converter
The easiest way to damp the poles:
¾ Calculate the equivalent quality coefficient at F
sw/2
¾ Calculate the external ramp to make Q less than 1
( )
1 1
3.14 0.5 0.46 8 ' 1
2
e n
Q
D S D
π S
= = =
× −
⎛ ⎞
⎜ + − ⎟
⎝ ⎠
( )
1 1 90 0.25 1
0.5 0.5 0.5 0.46 36
' ' 320 1 0.46 3.14
n in i
e
p
S V R
S D D kV s
D π L D π u
⎛ ⎞ ⎛ ⎞ × ⎛ ⎞
= ⎜⎝ − + ⎟⎠ = ⎜⎝ − + ⎟⎠= × − ⎜⎝ − + ⎟⎠=
NCP1230 Rramp
Ri
2.3 Vpp
18 kΩ
CS
DRV 2.3
15 153
Sramp kV s
= u =
36 51%
70
e r
n
S k
M = S = k =
0.51 70 18 153 4.1
r n ramp current
ramp
M S R k k
R k
S k
× ×
= = = Ω
Rcurrent
On-time slope in i
p
V R L
Stabilizing a CCM Flyback Converter
Boost the gain by +22 dB, boost the phase at f
c11
-80.0 -40.0 0 40.0 80.0
10
-180 -90.0 0 90.0 180
11
|T(s)|
argT(s)
Cross over 1 kHz
Margin at 1 kHz 60 °
GM 20 dB
Stabilizing a CCM Flyback Converter
Test the response at both input levels, 90 and 265 Vrms
Sweep ESR values and check margins again
18.79 18.87 18.95 19.03 19.11
1211
V
out(t)
Low line Hi
line
112 mV
Agenda
Why simulating power supplies?
Average modeling techniques
The PWM switch concept, CCM
The PWM switch concept, DCM
The voltage-mode model at work
Current-mode modeling
The current-mode model at work
Power factor correction
Switching models
EMI filtering
Conclusion
Power Factor Correction
CBulk 100u IC = 50
6
D5 1N4007
2
D6 1N4007
D7 1N4007
D8 1N4007 Vmains
Vbulk
Vbulk
B2 Current 50/V(Vbulk)
Itotal Iout
Ibulk
Vbulk
Vmains
Iin Vbulk
Vmains
Iin
The bulk capacitor connects to a low-impedance source
At the bulk capacitor refueling, a narrow peak current flows
This peak conveys a large harmonic content
Power Factor Correction
Cbulk
D1 D2
D3 D4
Mains
PWM Vbulk
PFC
Pre-converter
store release
Cbulk
D1 D2
D3 D4
Mains
PWM Vbulk
PFC
Pre-converter
store release
A pre-converter is installed as a front-end section
The pre-converter draws a sinusoidal current
The energy is stored and released in/by the bulk capacitor
Power Factor Correction
+ -
2 1
4
+-
17 7
3
5
16 11 8
Rlimit
Ddmg
12
Dout
Cout
Vout S
R Q
Q 6
Verr Reset detector
Rsense current sense
comparator
9
10 13
G1 A
B K*A*B 14
X6
C1 Vref
Rupper
Rlower
RdivL RdivU
18
D3
15
D4
D5 D6
Cin Vin
Vdem
L
Peak current setpoint Error amplifier
One of the most popular techinique uses Borderline mode
The MC33262 operates in peak current mode control
The NCP1606 also operates in constant-on time
Power Factor Correction
the average inductor current is average half the inductor peak current value half
8.05m 8.15m 8.25m 8.35m 8.45m
time in seconds
IL(t) IL,peak
IL,avg
ton
IL = 0
( ) ( )
( )
L Tsw in
I t t =I t
8.05m 8.15m 8.25m 8.35m 8.45m
time in seconds
IL(t) IL,peak
IL,avg
ton
IL = 0
( ) ( )
( )
L Tsw in
I t t =I t
The core is always reset from cycle to the other
On time is constant
Power Factor Correction
4
9
C5 150u
IC = {Vrms*1.414}
R10 50m
16 23
L1 {L}
parameter Vrms=100 Pout=150 Vout=400 Ri=0.22 L=850u
Vton 5
Vfsw 26
22
13 17
G1 100u
V4 2.5
25
C2 0.68u R5
1G Verr
14
V5 1.7 D2 N = 0.01
15
D1 N = 0.01
V3 6.4
10
R1 1.6Meg
R2
12k C3
10n
A
B K*A*B 24
2
K = 0.6 R6 100m
B1 V11 Current
I(V11) > 10u ? 10u : I(V11)
R3 10k R4 1.6Meg
R8 23k
err B4
Voltage
V(err)-2.05 < 0 ? 0 : V(err)-2.05
B1 3 0 V = V(1) * V(2) * {K}>1.3 ? 1.3 : V(1) * V(2) * {K}
vcac PWM switch BCMp
tonFsw (kHz)
X5
PWMBCMCM2 L = L Ri = Ri
3
6
Vin {VRMS}
+
- IN
8
X1 KBU4J Iin
Δ
Vin
Vrect
Cin 1u
Vmul
Vout
Rload {Vout*Vout/Pout}
A 150 W BCM PFC average example with the MC33262
Current-mode borderline model
Power Factor Correction
-8.00 -4.00 0 4.00 8.00
vton in volts
-2.00 -1.00 0 1.00 2.00
iin in amperesPlot1
1 3
394 398 402 406 410
vout, vout#a in voltsPlot2 62
1.139 1.149 1.159 1.169 1.179
-60.0 -30.0 0 30.0 60.0
vton in volts
-4.00 -2.00 0 2.00 4.00
iin in amperesPlot3
4 5
THD = 2%
THD = 10% Iin(t)
Iin(t) Vin = 230 Vac
Vin = 100 Vac
ton(t) - µs
ton(t) - µs
Vout,peak = 406 V
Vout,valley = 398 V Vout(t)
-8.00 -4.00 0 4.00 8.00
vton in volts
-2.00 -1.00 0 1.00 2.00
iin in amperesPlot1
1 3
394 398 402 406 410
vout, vout#a in voltsPlot2 62
1.139 1.149 1.159 1.169 1.179
-60.0 -30.0 0 30.0 60.0
vton in volts
-4.00 -2.00 0 2.00 4.00
iin in amperesPlot3
4 5
THD = 2%
THD = 10% Iin(t)
Iin(t) Vin = 230 Vac
Vin = 100 Vac
ton(t) - µs
ton(t) - µs
Vout,peak = 406 V
Vout,valley = 398 V Vout(t)
High line
Low line Constant
on-time
Average models can also work in transient conditions
Power Factor Correction
-80.0 -40.0 0 40.0 80.0
gain in db(volts)
-180 -90.0 0 90.0 180
phase in degreesplot1
1
2
1m 10m 100m 1 10 100 1k 10k 100k
frequency in hertz -80.0
-40.0 0 40.0 80.0
gain in db(volts)
-180 -90.0 0 90.0 180
phase in degreesPlot2
4
5
No zero added Zero added
phase gain
phase gain
fc = 5 Hz fc = 5 Hz
Pm = 61°
-80.0 -40.0 0 40.0 80.0
gain in db(volts)
-180 -90.0 0 90.0 180
phase in degreesplot1
1
2
1m 10m 100m 1 10 100 1k 10k 100k
frequency in hertz -80.0
-40.0 0 40.0 80.0
gain in db(volts)
-180 -90.0 0 90.0 180
phase in degreesPlot2
4
5
No zero added Zero added
phase gain
phase gain
fc = 5 Hz fc = 5 Hz
Pm = 61°
Use the model to boost the phase at the cross over point
Power Factor Correction
122m 365m 608m 851m 1.09
time in seconds 320
350 380 410 440
vout#a, vout#a#1 in voltsPlot1
32
1.128 1.135 1.142 1.149 1.157
time in seconds -800m
-400m 0 400m 800m
iin, iin#1 in amperesPlot2 41
Vout(t)
Iin(t)
440 V
413 V
THD = 1.5%
THD = 10%
122m 365m 608m 851m 1.09
time in seconds 320
350 380 410 440
vout#a, vout#a#1 in voltsPlot1
32
1.128 1.135 1.142 1.149 1.157
time in seconds -800m
-400m 0 400m 800m
iin, iin#1 in amperesPlot2 41
Vout(t)
Iin(t)
440 V
413 V
THD = 1.5%
THD = 10%
Added zero No zero
Added zero
No zero