0% found this document useful (0 votes)
5 views57 pages

Slide PE Control

The document discusses the modeling and controller design for a flyback converter used in power electronic systems. It includes sections on the mathematical modeling, controller design techniques such as LQR and Kalman observers, and numerical simulations to compare model performance. The document aims to provide a comprehensive understanding of the flyback converter's operation and control strategies.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views57 pages

Slide PE Control

The document discusses the modeling and controller design for a flyback converter used in power electronic systems. It includes sections on the mathematical modeling, controller design techniques such as LQR and Kalman observers, and numerical simulations to compare model performance. The document aims to provide a comprehensive understanding of the flyback converter's operation and control strategies.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 57

Modeling and Controller Design for the Flyback Converter

Control for power electronic systems

Vu Duc Cuong - [email protected],


Tran Son - [email protected],
Nguyen Quang Truong - [email protected]
Supervisor: Assoc. Prof. PhD. Tran Trong Minh

March 12, 2024

ONE LOVE. ONE FUTURE.


Table of Contents

1 Introduction of the flyback converter

2 Mathematical model of the flyback converter


1. Analysis and assumptions
2. Exact model
3. Big signal parts model
4. Small signal parts model
5. Model Parameters
6. Simulation for models comparison

1/48
Table of Contents

3 Controller Design for the flyback converter


1. Control Structures
2. Pole Assignment
3. Luenberger Observer
4. LQR controller
5. Kalman Observer (Kalman Filter)
6. Pre-process

4 Numerical Simulations

2/48
Table of Contents

5 LQR Weight Matrices Analysis


1. Q matrix
2. R matrix

6 Model Predictive Control for the Flyback Converter


1. Model Predictive Control: Theory
2. MPC and LQR: A comparison

3/48
Section 1
Introduction of the flyback converter
Introduction of the flyback converter

(a) MCP1661 Flyback Converter Reference (b) Mobile charger circuit diagram

Figure: Flyback converter PCB.

4/48
Section 2
Mathematical model of the flyback converter
Analysis and assumptions

Figure: Analysis Flyback Converter

Assumptions
RL = 0 and VD = 0, because RL and VD affect only static error in both transient state
and steady state. This error is small enough to be ignored.
RC
RC = 0. If, RC ̸= 0, subsystem RC C becomes a virtual capacitor C ′ = C +
R

5/48
Exact Model

Sub-interval 1: (switch enable, diode disable)

d

 L. iL = E
 (1a)
dt
 C . d u = −uC

(1b)
C
dt R

 
  0 0   "1#
d iL  iL Figure: Flyback converter state
=  u + L E (2)

dt uC 1 C 0
0 −
RC

6/48
Exact Model

Sub-interval 2: (switch disable, diode enable)

d

 L. iL .n = −uC
 (3a)
dt
 C . d u = iL − uC

(3b)
C
dt n R

 1 
0 −
Ln  iL
   
d iL 
=  (4) Figure: Flyback converter state
dt uC 
1 1
 uC

Cn RC

7/48
Exact Model

 T
State vector q = iL uC . Exact model of the flyback converter with k states

k
d X d
q= qi hi (5)
dt dt
i=0
 
" #
1
" # ! 1 !
d 0 0 0 −
q= 1 q+ L E u+  1
 Ln  q (1 − u)

(6)
dt 0 − 1
RC 0 −
Cn RC
   
1 1 1
" # !
d  0 −  0
q= 1 Ln  q +  Ln 
q + L E u (7)
dt 1  1 
− − 0 0
Cn RC Cn

8/48
Big signal parts model

From equation 7, DC average model can be found by replacing u by d follow as:


 
1 d
" #
d 0 (d − 1) 
q=
 Ln  q + L E (8)
dt 1 −1
(1 − d) 0
Cn RC
d  T
When established, q= 0 0
dt
 
1 d
" #
0 (d − 1) 
 Ln  q + L E = 0 (9)
 1 −1
(1 − d) 0
Cn RC

9/48
Big signal parts model
Therefore,

1 −1 " d #
 
0 (d − 1) 
qest = − 
 Ln  L E (10)
1 −1
(1 − d) 0
Cn RC

Edn2
 
 
iLest 2
qest = =  R(1 − d)  (11)

dCest Edn
1−d
The relationship between input voltage and output voltage
do d
=n (12)
E 1−d

10/48
Small signal parts model

From average model with

x̃i = ⟨xi ⟩0 − ⟨xie ⟩0 , i = 1, ..., n



(13a)
ũk = ⟨dk ⟩0 − ⟨dke ⟩0 , k = 1, ..., n (13b)

Substitute the fluctuations into the equation of state

x2e de + x2e d˜ + x̃2 de + x̃2 d˜



d −x̃2 − x2e
 L x̃1 = + + Ede + E d˜ (14a)


dt n n
˜ ˜
 C d x̃2 = x1e + x̃1 − x1e de − x1e d − x̃1 d − x2e − x̃2

(14b)

dt n R R

11/48
Small signal parts model
Reject the products of two small signals
d 1 1

 L x̃1 = x2e d˜ − (1 − de )x̃2 + E d˜
 (15a)
dt n n
 C d x̃ = − 1 x d˜ + 1 (1 − d )x̃ − 1 x˜

(15b)
2 1e e 1 2
dt n n R
It can be written in matrix form follow as:
de − 1  
   
1 E
 0  x2e + L  ˜
 
d x̃1 Ln  x̃1

=  1 − de 1  x̃ +  Ln−1 d (16)
dt 2 − 2
x1e
| Cn {z RC } | Cn{z }
A B
    
1 0 x̃1 0 ˜
y= + d (17)
0 1 x̃2 0
| {z } |{z}
C D

12/48
Small signal parts model
And transfers function can be found by the state-space matrices

G = C (sI − A)−1 B + D (18)

de − 1 !−1 1
   
E
 0 x +
     
1 0 1 0 Ln   Ln 2e L 0
G= s − 1 − d + (19)

1   −1
0 1 0 1 e 0
− x1e
Cn RC Cn

(RCnx2e + ERCn2 )s + Rx1e + nx2e + En2 − Rde x1e


 
  CLRn2 s 2 + Ln2 s + Rde 2 − 2Rde + R
 
GiL  
G= =  (20)
GuC  
 RLnx1e s + Rde x2e − ERn − Rx2e + ERde n 
− 2
2 2 2
CLRn s + Ln s + Rde − 2Rde + R

13/48
Model Parameters

Parameters Symbols Values


Input source E 310 V
Output voltage do 9 V
Output current Io 3 A
Transformer Ratio n 1/30
Switch frequency fsw 500 kHz
Inductance L 15e-3 H
Capacitance C 31e-6 F
Resistance R 3 Ω
Established inductor current iLest 0.1817 A
Established capacitor voltage dCest 9 V
Established duty circle de 0.4655
Table: Parameters of the flyback converter used in this project.

14/48
Simulation for models comparison

0.75
0.2
Current [A]
Inductor current of exact model
0.5 0.15 Inductor current of average model
0.1
0.25 2.5 2.6 2.7 2.8 2.9 3
10 -4
0
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 1.1 1.2 1.3 1.4
-3
10
20 7.2
Voltage [V]

16 Capacitor voltage of exact model


7
12 Capacitor voltage of average model
2.5 2.6 2.7 2.8 2.9 3
8 10 -4
4
0
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 1.1 1.2 1.3 1.4
Time [s] -3
10

Figure: Simulation results of the exact model and the average model.

15/48
Simulation for models comparison

0.75
0.2
Current [A]
Inductor current of exact model
0.5 Inductor current of average model 0.15
0.1
0.25 1.2 1.4 1.6 1.8
10 -3
0
0 0.5 1 1.5 2 2.5
-3
9 10
20
Voltage [V]

16 Capacitor voltage of exact model 8


12 Capacitor voltage of average model 7
1.2 1.4 1.6 1.8
8 10 -3
4
0
0 0.5 1 1.5 2 2.5
Time [s] -3
10

Figure: Simulation results of the exact model and the average model when E decrease 15%.

16/48
Simulation for models comparison

Current [A] 0.75


Inductor current of exact model
0.5 Inductor current of average model

0.25

0
0 0.5 1 1.5 2 2.5
-3
10
20
Voltage [V]

16 Capacitor voltage of exact model


12 Capacitor voltage of average model
8
4
0
0 0.5 1 1.5 2 2.5
Time [s] -3
10

Figure: Simulation results of the exact model and the average model with high frequency disturbance.

17/48
Section 3
Controller Design for the flyback converter
Control Structures

_ Inductor Current
ref Pre-
Flyback model
processing _

Capacitor Voltage
Pole
Assignment
Luenberger
Observer

Figure: Pole Assignment for Flyback converter.

18/48
Control Structures

_ Inductor Current
ref Pre-
Flyback model
processing _

Capacitor Voltage
LQR controller

Kalman Observer

Figure: LQR controller for Flyback converter.

19/48
State-Space matrix and Transfer function

From equations (16) và (17), state-space model of flyback converter at equilibrium can be find
     
d iL i i
= A L + Bu; y =C L (21)
dt uC uC uC

where
     T
0 −0.01069 0.386667 0
A= .105 ; B= .105 ; C= (22)
5.17258 −0.10752 −1.81065 1

and, from equation (20), transfer function from duty circle to output voltage is

6680101579724626105204736s − 737893565198799761236340780043
GuC = − (23)
4294967296(8589934592s 2 + 554189328516129s + 4749794634333150416)

→ easy to see that, this system is controllable and observable

20/48
Pole Assignment

Figure: Pole assignment control structure. Source: Prof. Nguyen Doan Phuoc

21/48
Pole Assignment

sT
   
−1 0
sT = B

S= ; AB .
sT A 1
(24)

then, we have new system


Figure: Pole Assignment control structure.
d
x = SAS −1 z + SBu (25)
dt
With 2 selected poles
and the controller of new system found by Ack-
ermann method is Rz . Then finally, the control s1 = s2 = −3.105 (27)
matrix can be calculated
then, the controller is
K = Kz S (26)  
K = 31.66 3.5075 (28)

22/48
Luenberger Observer

Figure: Combine Luenberger observer and pole assignment controller.

The observation matrix can be found similar to the pole assignment controller, by performing
pole assignment on the dual system
 T
CT
  
A B A
G= → G′ = (29)
C D BT DT

Similar to the design of the pole assignment controller, the observation matrix is
 T
L = 76261 389247 (30)
23/48
Luenberger Observer
Current [A]
Without Luenberger Observer
0.5 Luenberger Observer
0.25
0
0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2
-3
10
Voltage [V]

Without Luenberger Observer


10
Luenberger Observer
9
5 8.95
8.9
8 8.01 8.02 8.03 8.04 8.05
0 -4
0 0.2 0.4 0.6 0.8 1 1.2 10 1.4 1.6 1.8 2
Time [s] 10-3

Figure: Simulation results of Luenberger observer.

24/48
Luenberger Observers
Current [A]
Without Luenberger Observer
0.5 Luenberger Observer
0.25
0
0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2
-3
10
Voltage [V]

Without Luenberger Observer


10
Luenberger Observer
5 9
8.8
8 8.01 8.02 8.03 8.04 8.05
0 -4
0 0.2 0.4 0.6 0.8 1 1.2 10 1.4 1.6 1.8 2
Time [s] 10-3

Figure: Simulation results of Luenberger observer under the influence of white noise.

25/48
LQR controller

LQR = Linear Quadratic Regulator


Consider linear time-invariant system
d
x = Ax + Bu (31)
dt
and control signal for this system

u = ω − Klqr x (32)

The LQR controller is a state feedback controller, with the control signal u found to be satisfied
Z∞ 
1 
J= x T Qx + u T Ru dt → min (33)
2
0

J is the cost function, Q = Q T > 0 and R = R T > 0 are weight matrices.

26/48
LQR controller
The first step to find the LQR controller is to find the solution P = P T > 0 of the Algebraic
Riccati Equation (ARE)

PA + AT P − PBR −1 B T P + Q = 0 (34)

then, the controller matrix Klqr can be found

Klqr = R −1 B T P (35)

Select Q and R as follows


   
Q = diag ( 1 3 ); R = 0.5 (36)

Then, P and Klqr are found to be, respectively


 
0.001377 0.000233  
P= → Klqr = 22.0123 1.7518 (37)
0.000233 0.000045

27/48
Kalman Filter (Kalman Observer)

The Kalman observer is an optimal observer, designed similarly to the design of the LQR
controller for the dual system.
Cost function of the Kalman Filter
Z∞ 
1 
JKalman = x T Nx x + u T Ny u dt → min (38)
2
0

where, x and u are the state and control variables of the dual system, respectively.
d
x = AT x + C T u (39)
dt

28/48
Kalman Filter (Kalman Observer)

Chose Nx and Ny follow as

Ny = 10−10
   
Nx = diag ( 1 30 ); (40)

the solution of the ARE PAT + AP − PCNy−1 C T P + Nx = 0 is


 
−4 0.1226 0.0989
P = 10 (41)
0.0989 0.6236

So, the Kalman observer matrix LKalman is determined


 T
LKalman = 98936 623650 (42)

29/48
Kalman Filter (Kalman Observer)
Current [A]
Without Kalman Observer
0.5 Kalman Observer
0.25
0
0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2
-3
10
Voltage [V]

Without Kalman Observer


10
Kalman Observer
9
5 8.95
8.9
8 8.01 8.02 8.03 8.04 8.05
0 -4
0 0.2 0.4 0.6 0.8 1 1.2 10 1.4 1.6 1.8 2
Time [s] 10-3

Figure: Simulation results of Kalman observer.

30/48
Kalman Filter (Kalman Observer)
Current [A]
Without Kalman Observer
0.5 Kalman Observer
0.25
0
0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2
-3
10
Voltage [V]

Without Kalman Observer


10
Kalman Observer
5 9
8.8
8 8.01 8.02 8.03 8.04 8.05
0 -4
0 0.2 0.4 0.6 0.8 1 1.2 10 1.4 1.6 1.8 2
Time [s] 10-3

Figure: Simulation results of Kalman observer under the influence of white noise.

31/48
Pre-process

Consider a stable, noise-free closed-loop system with a negative feedback. The system has a
static error of 0, i.e. e∞ = 0 if with w (t) = 1(t), and the open-system transfer function Gh (s)
has at least one pole at the origin.

Integrate the error between the reference and the output, then the transfer function of the
pre-process is
Kpre
Gpre (s) = ; Kpre = 50000 (43)
s

32/48
Section 4
Numerical Simulations
Numerical Simulation

0.5
Current [A]
0.25
0.2 PA
0.25 0.15 LQR
1 1.05 1.1
PID
10-3
0
0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2
-3
10 10
Voltage [V]

PA
9.2
5 9
LQR
8.8 PID
1 1.05 1.1 Ref
0 10
-3

0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2


Time [s] 10-3

Figure: Simulation of Controller without Observer

33/48
Numerical Simulation

Current [A] 0.6


0.25 PA
0.4
0.2 LQR
0.2 0.15
1 1.02 1.04 1.06
Observer of PA
10-3
Observer of LQR
0
0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2
-3
10 10
Voltage [V]

PA
9.5
5 9
LQR
8.5 Observer of PA
1 1.02 1.04 1.06 Observer of LQR
0 10
-3

0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2


Time [s] 10-3

Figure: Simulation of Controller with Observer

34/48
Numerical Simulation

Gauss Distribution (Normal Distribution)

n ∼ N (µ, σ 2 ) (44)

Model: µ1 = 0; σ12 = 0.01


Measurement iL : µ2 = 0; σ22 = 0.001
Measurement uC : µ3 = 0; σ32 = 0.01

35/48
Numerical Simulation

Current [A] 0.6


PA
0.3 LQR

0
0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2
-3
10 10
Voltage [V]

PA
9.5
5 9
LQR
8.5 Ref
1 1.005 1.01
0 10
-3

0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2


Time [s] 10-3

Figure: Simulation of Controller without Observer under the influence of white noise

36/48
Numerical Simulation

Current [A] 0.6


PA
0.4
LQR
0.2 Observer of PA
Observer of LQR
0
0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2
-3
10 10
Voltage [V]

PA
9.5
5 9
LQR
8.5 Observer of PA
1 1.005 1.01 1.015 1.02 Observer of LQR
0 10
-3

0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2


Time [s] 10-3

Figure: Simulation of Controller with Observer under the influence of white noise

37/48
Section 5
LQR Weight Matrices Analysis
LQR controller

Consider the linear time-invariant system


d
x = Ax + Bu (45)
dt
and control signal for this system

u = ω − Klqr x (46)

The LQR controller is a state feedback controller, with the control signal u found to be satisfied
Z∞ 
1 
J= x T Qx + u T Ru dt → min (47)
2
0

J is the cost function, Q = Q T > 0 and R = R T > 0 are weight matrices.

38/48
Q matrix

Figure: Simulation results between 3 different Q matrices

39/48
R matrix

Figure: Simulation results between 3 different R matrices

40/48
Section 6
Model Predictive Control for the Flyback
Converter
Model Predictive Control: Theory

Figure: Predicted state and control signal in prediction horizon at time k.

41/48
Model Predictive Control: Theory

d ∗ = arg min J(q, qr , u) (48)


d
s.t. q[k + i + 1] = f (q[k + i], u[k + i]), ∀i = 0, . . . , Ns (49)
dmin ≤ d[k + i] ≤ dmax , ∀i = 0, . . . , Nc (50)

where,
N
Xs +1 Nc
X
J(q, qr , d ) = Qe[k + i]2 + Rd[k + i]2 (cost function)
i=0 i=0

42/48
Model Predictive Control: Theory

Algorithm 1:
1. At step k, measurement state variables
2. Predict the next states based on the equation (8), with the input as the solution of the
previous step.
T
3. Solve equation (48) with constraint to find solution u ∗ = dk∗ dk+1∗
. . . dN∗c .


4. The control signal at step dk is d1k , the next to step k + 1 and repeat from 1.

43/48
Model Predictive Control: Theory

Figure: Model Predictive Control for the Flyback converter structure.

44/48
Model Predictive Control: Simulation

Figure: Simulation results of MPC and LQR.

45/48
Model Predictive Control: Simulation

Figure: Simulation results of MPC and LQR.

46/48
Model Predictive Control: Simulation

Figure: Simulation results of MPC and LQR.

47/48
Acknowledgment

Model was verified in Raj, Akshatha S., et al. ”Modelling of flyback converter using state
space averaging technique.” 2015 IEEE International Conference on Electronics,
Computing and Communication Technologies (CONECCT). IEEE, 2015.
All script and simulation files (MATLAB R2021a) in:
Click here
Request for the older version: mailto: [email protected]
This slide was created by LATEX.
Open source: https://www.overleaf.com/read/tnqqrzpwnrsj

48/48
THANK YOU !

You might also like