Contributions To Grid Synchronization Te PDF
Contributions To Grid Synchronization Te PDF
Contributions to Grid-Synchronization
Techniques for Power Electronic Converters
9 June 2009
University of Vigo
Vigo, Spain
Vita
Since 2003 to 2005 he worked as software developer. From February 2005 he is part
time assistant lecturer of the University of Vigo. From June 2008 to October 2008 he
had a research stay at the Power Engineering Group of the University of Glasgow. He
had a research stay at the University of Alcalá in February 2009. His research interests
include digital control of Power Electronics Converters, specially for Power Quality and
renewable energy applications.
He has authored or coauthored about 20 technical papers in the field of power elec-
tronics, 8 of which are IEEE Transactions grade. He is member of the IEEE since 2007
and also of the IEEE Industrial Electronics and IEEE Power Electronics Societies.
Contributions to Grid-Synchronization Techniques for
Power Electronic Converters
Francisco Daniel Freijedo Fernández
(Abstract)
Real time grid-synchronization techniques are studied in this dissertation. The syn-
chronization block is a crucial part of the controller in grid-connected power converters.
The phase-angle of the voltage/current vector fundamental component at the point of
common coupling (PCC) should be tracked online in order to control the energy transfer
between the power converter and the ac mains. Synchronization algorithms have been
evolving since the first analog zero-cross detectors to current high performance digital
implementations.
Digital PLLs are the most employed synchronization algorithm, mainly due to their
simple implementation, good frequency adaptation and acceptable filtering versus tran-
sient response trade-off. Chapter 3 is devoted to digital PLLs design. In a general way,
PLLs with a low bandwidth (low-gain PLLs) are required when handling with distorted
voltages. It is analytically demonstrated that low-gain PLLs have more trade-offs than
high-gain PLLs (e.g. PLLs for communications): it is not possible to optimize the settling
time for a phase-jump without getting slower the PLL response to frequency variations.
Existing tuning methods do not take into account low-gain features, which may result in
non-optimum designs. An intuitive tuning methodology based on inspection of frequency-
domain diagrams is contributed in this chapter. Contrary to the other existing tuning
methods, it takes into account low-gain dynamics. It is assured an optimized performance
in the presence of any kind of disturbances in the grid. In the second part of the chapter,
the DCO based on a RC oscillator is presented: the digital model of a sinusoidal oscil-
lator is implemented, instead of explicit trigonometric functions. This solution reduces
the needed digital resources without reducing the performance, which could be specially
useful for DSP-based control of power converters.
Chapter 6 is devoted to review all the contributions of this PhD thesis. A brief outline
of the future work is also provided.
Acknowledgments
First of all, I would like to thank my director, Dr. Jesús Doval, for his patience,
guidance and support. He introduced me to the interesting field of power electronics, and
more specifically in the issue of grid-synchronization.
I would like to thank Professor Enrique Acha for giving me the opportunity to be
at the University of Glasgow, and for his invaluable help during the development of this
dissertation.
I would also like to thank University of Vigo for the grant I was given to stay in
Glasgow.
I wish to thank Dr Emilio Bueno for the good moments at IECON 2008, and for
having invited me to the University of Alcala.
I would like to thank the PhD Committee Members for their comments which help to
improve the overall quality of this dissertation.
I wish to thank all the colleagues and students for the good moments we shared.
Especially, I would like to mention Enrique Ortega, Pablo, Jano, Jacobo, Renato and
Alejandro.
I would like to thank Carmenza by her English classes and for the good moments we
shared with Miguel.
Contents i
List of Figures ix
Nomenclature xxiii
1 Introduction 1
i
ii
1.4.1 Transients . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
1.4.2.1 Interruptions . . . . . . . . . . . . . . . . . . . . . . . . . 18
1.4.2.3 Swells . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
1.4.3.1 Over-Voltage . . . . . . . . . . . . . . . . . . . . . . . . . 18
1.4.3.2 Under-Voltage . . . . . . . . . . . . . . . . . . . . . . . . 19
1.4.5.1 Dc Offset . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
1.4.5.2 Harmonics . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
1.4.5.3 Inter-Harmonics . . . . . . . . . . . . . . . . . . . . . . . 20
1.4.5.4 Notching . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
1.4.5.5 Noise . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
References 183
List of Figures
ix
x
2.7 Scheme of the PLO controller for the HVDC rectifier proposed in [1]. . . . 53
2.9 Equivalent block diagram of PLO circuit and controller for firing maximum
delay. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56
2.11 Start-up simulation of PLO for different i∗dc (dotted), idc is the blue line. . . 58
2.14 PLO tested in the presence of an unbalanced and polluted with harmonics
system of voltages. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60
2.21 Time domain simulation results from the CP-PLL model at f = 49 Hz. . . 67
2.27 Comparative of the dynamics of A(z) and D(z) (fs = 10 kHz, so n = 50 in D(z)). 74
2.34 Significant simulation results for LP-TAD: fault and unbalance conditions. 84
2.38 Simulation results for SRF-MAF1 working open loop (ωsrf = ω1 = ω1n ). . . 91
xii
+
2.40 Three-phase SRF synchronization algorithm; ωsrf = ω1 to decouple vabc 1
. . 93
2.41 Simulation results for SRF-MAF3 working in open loop (ωsrf = ω1 = ω1n ). 95
2.47 Adaptive SRF-MAF1 Vs open loop SRF-MAF1 during the start-up and
steady-state. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 112
3.4 Frequency response of H(z) for the HB-PLL (L(s)HB−P LL was discretized
using the ’zoh’ method). . . . . . . . . . . . . . . . . . . . . . . . . . . . . 125
3.5 Frequency response of H(z) for the UN-PLL (L(s)U N −P LL was discretized
using the ’zoh’ method). . . . . . . . . . . . . . . . . . . . . . . . . . . . . 126
3.6 Frequency response of H(z) for the MA-PLL (PI filter was discretized using
the ’zoh’ method). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 127
3.7 Experimental results for different SRF-PLLs: Ch1 (black) is the Va input in
p.u./V, Ch4 is the instantaneous phase-angle measurement (100 mV/rad),
Ch2 is the error signal vq in p.u./V (1 p.u. = π/2 deg of phase error), Ch3
is ∆ωo (10 mV/(rad/s)). . . . . . . . . . . . . . . . . . . . . . . . . . . . . 128
3.10 Simulation results for single-phase PLL (ω1 = 2π50.3 rad/s). . . . . . . . . 132
4.2 Design example 1: time and frequency responses of H1 (z) · H2 (z). . . . . . 140
′
4.3 Design example 2: Frequency and Step responses of H1 (z) · H1 (z) · H2 (z). . 142
−
4.5 S1 response to a big frequency step at 0.2 s. Unbalanced (va1 max
= 0.1 ·
+
va1max ) input wave. Frequency step (up), phase error (center) and fre-
quency error (down). Zero steady state error and transient duration of
0.01 s are achieved. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 144
4.6 S1 tested under a distorted set of input waves rotating at 49.5 Hz. At 1 s,
a 1 p.u. to 0.2 p.u. sag with +45 deg phase jump has been programmed. . . 145
4.7 S1: steady state error for a balanced set of inputs oscillating at 48 Hz. . . . 146
− +
4.8 S1: Steady state error for an unbalanced (va1 max
= 0.1 · va1 max
) set of inputs
oscillating at 51 Hz. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 147
4.9 S1: Transient response for a sag with −45 deg phase jump. . . . . . . . . . 148
+
4.11 Comparative between S1 and S2 in terms of noise rejection. Ch1 is va1 max
,
Ch2 is va , Ch3 is vb , Ch4 is vc (voltages in p.u., ω1 = 2π · 49.75 rad/s). . . 150
+
4.12 S1 Vs S2 in terms of transient response. Ch1 is va1 max
, Ch2 is va , Ch3 is
vb , Ch4 is vc (voltages in p.u., ω1 = 2π · 49 rad/s). . . . . . . . . . . . . . . 150
5.9 Frequency response of C(z) · P (z) around 150 Hz. When ∆ω̂1 > 0 the peak
”moves” to higher frequencies and vice versa. . . . . . . . . . . . . . . . . . 164
5.14 Transient response when there is a load change. Ch1 is iL , Ch2 is iF , Ch3
is iS and Ch4 is vP CC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 169
5.18 Steady state figures when error in estimation of ∆ω̂1 is considered. ∆ω̂1 =
0 rad/s and ∆ω1 = −4π rad/s (f1 = 48 Hz). Ch1 is iL , Ch2 is ∆ωˆ1 (scale
at 2π∆3 rad/div), Ch3 is iS and Ch4 is vP CC . . . . . . . . . . . . . . . . . 171
5.19 Transient response when there is a voltage sag (1 p.u. → 0.8 p.u.) with
phase-angle jump of +45 deg in vP CC (vS ). Ch1 is iL , Ch2 is ∆ωˆ1 (scale at
2π∆3 rad/div), Ch3 is iS and Ch4 is vP CC . . . . . . . . . . . . . . . . . . . 171
A.2 PLO system Matlab script. Function file (page 1 of 2). . . . . . . . . . . . 177
xv
A.3 PLO system Matlab script. Function file (page 2 of 2). . . . . . . . . . . . 178
A.5 Matlab script of the Kalman Filter Single-phase synchronization example. . 180
A.7 Matlab script of the single-phase PLL with RC-Oscillator based DCO. . . . 182
xvi
List of Tables
4.3 Brief comparative among significant systems with good unbalance rejection 148
xvii
xviii
ac Alternate current.
CP Charge-Pump (PLL).
dc Direct current.
GI Generalized integrator.
xix
xx
IC Integrated Circuit.
OA Operational Amplifier.
PM Phase margin.
PQ Power Quality.
∆α Small perturbation in α.
f Frequency in Hz..
ϕ Offset phase-angle.
i Single-phase current.
j Imaginary Unit.
xxiii
xxiv
P Active Power.
Q Reactive Power.
R Resistance.
S Apparent Power.
S Fortescue matrix.
t Time, in seconds.
v Single-phase voltage.
z Impedance.
Subscript
1 Fundamental component.
dc Voltages/currents in a DC bus.
i Input value.
min Minimum.
o Output value.
Superscript
+ Positive sequence.
− Negative sequence.
0 Zero sequence.
T Transpose of a matrix.
∗ Reference value.
Accents
x̄ Average value of x.
x̂ Estimated value of x.
Introduction
Due to the high amount of recent proposals and applications, an in-depth review of the
state-of-art in grid synchronization seems to be necessary. Active fields of research such
as Flexible ac Transmission Systems (FACTs), Distributed Power Generation Systems
(DPGS), Power Conditioning and Traction Systems claim for an ever-increasing perfor-
mance of synchronization algorithms. This works provides a study of existing schemes and
implementation techniques and also provides novel high performance algorithms. Special
emphasis is devoted to take advantage of digital implementation.
It is also a goal of this work to show how a good knowledge in the synchronization field
permits to improve other blocks employed in the controllers of power electronic converters.
A novel discrete-time implementation of the Proportional+Resonant (PR) controllers is
contributed in chapter 5. The added value of this implementation is the manner how each
resonant controller is made frequency adaptive using a phase locked loop (PLL). This
provides robustness in the presence of grid frequency deviations.
Some concepts should be defined before the analysis of power systems. These concepts
and definitions of electric power for sinusoidal ac systems are well stated and accepted
nowadays when considering ideal conditions. However, under distorted conditions, several
1
2 Chapter 1 Introduction
Ideal AC
Source Linear Load
v i
ω = 2 ⋅π ⋅ f
and different power definitions and theories are still in use [3].
The simple single-phase electrical systems depicted in Fig. 1.1 is considered. The ideal
ac source generates a sinusoidal voltage rotating at the the angular frequency, also named
frequency pulsation ω. The frequency of oscillation in [ Hz] is obtained as f = ω/(2π).
The ac source is connected to a linear load. The instantaneous voltage and current can
be analytically represented by
√
v(t) = 2 · vrms · sin (ωt + ϕv ), (1.1)
√
i(t) = 2 · vrms · sin (ωt + ϕi ), (1.2)
where ϕi is also a constant offset phase-angle. The relative angle between v(t) and i(t)
(φ) is given by
φ = ϕv − ϕi . (1.3)
φ is set by the load reactance: φ > 0 (the current lags the voltage) for inductive loads,
and φ < 0 (the current leads the voltage) for capacitive loads. The value of φ in Fig. 1.1
is limited in the range [−90 deg ≤ φ ≤ 90 deg]. The instantaneous active power p(t) is
1.2 Background on Electric Power Definitions 3
p(t) = v(t) · i(t) = P [1 − cos (2ω1 t)] − Q sin (2ω1 t), (1.4)
where
From (1.4) to (1.6), p(t) is not constant, since it has an oscillating component rotating
at 2ω. P represents an unidirectional power flow from the ac source to the load. Therefore,
it could be said that P gives a measurement of the averaged energy supplied in any time
interval from the ac source to the load.
The power factor (PF) is defined as cos (φ), which is obtained as:
P
cos (φ) = . (1.8)
S
The physical meaning of S is clear from (1.7) and (1.8). S represents the maximum
reachable active power P at unity power factor.
A PF of one, or “unity power factor”, is the goal of any electric utility company, since,
if the power factor is less than one, they have to supply more current to the user for a
given amount of power consumption. In so doing, they incur more line losses. They also
must have larger capacity equipment in place than would be otherwise necessary. As a
result, an industrial facility will be charged a penalty if its PF is much different from 1.
4 Chapter 1 Introduction
The scheme of Fig. 1.1 has been simulated in the time domain through PSPICE in
order to supply the waveforms shown in Fig. 1.2. The linear load is form of a resistor in
series with an inductance with a XL /R = 0.6/0.8 ratio, which results in φ ≈ 36 deg (XL
is the inductance impedance at ω). The values of the components have been arranged so
rms values of v(t) and i(t) are 1 p.u..
The above figures show both v(t) and i(t) and the time delay ≈ 2 ms associated to φ.
The figure below shows p(t) and its average value P . As expected, P = V I cos(φ) = 0.8 p.u..
In some points of time, p(t) is negative, which corresponds with an instantaneous power
flow from the load to the source. However, the area highlighted with ’A’, corresponding
with a positive power flow from the source to the load, is higher than the area highlighted
with ’B’, corresponding with the flow from the load to the source. By inspection of (1.4)
it is clear that a higher weight of the inductance (XL ) in the load results in a higher ’B’
area, which means a higher Q. If there was no resistive component φ would be equal to
90 deg, and hence, area ’B’ and area ’A’ would be the same; Q would be maximum and
P = 0. The sign of Q depends on the kind of load: inductive load (φ > 0) results in a
positive Q and a capacitive load (φ < 0) results in a negative Q.
A powerful tool in the analysis of power systems is the use of the so-called phasor nota-
tion instead of analytical expressions in the time domain. The phasor notation approach
is detailed as follows.
Any sinusoidal time function (f (t)) rotating at an angular frequency ω can be repre-
sented as the real part of a complex number:
Assuming steady-state and known frequency, f (t) can be represented by the complex
number Ḟ :
1.41
0.5
-0.5
-1
-1.5
0.04 0.045 0.05 0.055 0.06 0.062 0.065 0.07 0.075
0.08
1.5
0.8
0.5
ℑ ωt ℑ
ℜ
S ω
V& jQ
φ = 36º
φ = 36º
I&
P ℜ
(a) Voltage and current phasor representation for (b) Graphical representation of the
Fig. 1.2. complex power for Fig. 1.2.
Figure 1.3: Voltage/current and Power phasors for Fig. 1.2 example.
Fig. 1.3a shows the phasor notation for the example depicted in Fig. 1.2. As in the
time domain representation, the current lags the voltage, since there is an inductive load.
The phasor notation can be extended to the power definitions. The complex apparent
power S is defined as the product of the voltage and current phasors:
S = V̇ · I˙∗ = vmax · imax cos (φ) + jvmax · imax sin (φ) = P + jQ. (1.12)
S can be depicted in the complex plane as function of P , Q and PF. Fig. 1.3b shows
this complex power representation for the Fig. 1.2 example. The sign of the reactive
power is positive because of the inductive behavior of the load. A negative Q would refer
to a capacitive reactive part of the load.
When the system voltages and currents contain components of non fundamental fre-
quency, it is said that there is distortion. The origin of this distortion can be in the origin
or in the consumer (non-linear loads).
The assessment of power definitions under distorted conditions is not a trivial task
at all. Two different theories have been provided: the power definitions based on the
frequency domain, proposed by Budeanu [4], and the power definitions in the time domain
by Fryze [5].
1.2 Background on Electric Power Definitions 7
There is so much discussion concerning which one of that strategies is more suitable
for the control of power converters. For example, Czarnecki proved that some of the
Budeanu definitions do not have physical meaning [6]. Moreover, there are quite a lot
difficulties with frequency domain power definitions applied to three-phase and four-wire
systems [3].
A set of power definitions set by Budeanu [4] is still very useful for the analysis of
power systems in the frequency domain. These definitions are valid for generic currents
and voltages in steady-state. However, they are not suitable to analyze transients.
where vrms and irms are voltage and current rms values These rms values can be calculated
as function of each hth (h = 1, 2, ...) order harmonic component:
s v
u ∞
1ZT 2 u1 X
vrms = v (t)dt = t v2
T 0 T h=1 rmsh
s u
v (1.14)
∞
1ZT 2 u1 X
irms = i (t)dt = t i2
T 0 T h=1 rmsh
where vrmsh and irmsh are the rms values of each harmonic component, and T the funda-
mental component period.
where the displacement angle of each pair of hth order harmonic voltage and current
components is represented as φh .
8 Chapter 1 Introduction
This Q definition tried to quantify the amount of power that does not realize work
in steady-state. However, this per-component approach does not take into account other
interactions such as cross products between voltages and currents at different frequencies.
For this reason, Budeanu also defined the distortion power D to quantify the loss of power
quality due to harmonic distortion:
The physical meaning of P is clear, since it represents the average value of the instan-
taneous power p(t), that is, the average ratio of energy transfered between two systems.
However, both Q and D are just mathematical expressions without a clear physical mean-
ing. Another drawback of Budeanu’s approach is its poor applicability in practical cases
of power quality assessment [3]. Other definitions by Budeanu are:
P
cos (φ) = √ . (1.19)
P2 + Q2
P
λ= = cos (φ) · cos (γ). (1.21)
S
1.2 Background on Electric Power Definitions 9
The main definition for power components in the time domain have been presented
by Fryze:
1ZT 1ZT
Pw = p(t) = v(t) · i(t) = vrms · iw = vw · irms . (1.22)
T 0 T 0
where vrms and irms are voltage and current rms values, and vw and iw are the active
voltage and active current defined below.
where vq and iq are the reactive voltage and current defined below.
vw = λ · vrms
(1.27)
iw = λ · irms .
10 Chapter 1 Introduction
vq = λq · vrms
(1.28)
iq = λq · irms .
• The presence of a fourth wire: if a three-phase system is grounded in more than one
point there is an additional path for current circulation. In other systems, a fourth
wire connected to the neutral is presented.
√
va 2 · vrms · sin(ωt + ϕv )
√ 2π
2 · vrms · sin(ωt + ϕv −
=
vb 3
) , (1.29)
√ 2π
vc 2 · vrms · sin(ωt + ϕv + 3
)
and
√
ia 2 · irms · sin (ωt + ϕi )
√ i 2π
ib =
2 · irms · sin (ωt + ϕ − 3
)
. (1.30)
√ 2π
ic 2 · irms · sin (ωt + ϕi + 3
)
For a three-phase system the instantaneous active power p3φ (t) describing the energy
flow per time unit transfered between two systems is given by:
p3φ (t) = va (t)ia (t) + vb (t)ib (t) + vc (t)ic (t) = pa (t) + pb (t) + pc (t). (1.31)
1.2 Background on Electric Power Definitions 11
Equation (1.32) shows the different behavior with respect to single-phase systems:
p3φ (t) is constant and does not have a second harmonic oscillating term. This constant
component defines the active power (P3φ ), which is three times the single-phase active
power.
However, Q3φ does not have the same physical meaning that the reactive power has
in single-phase systems. In fact, a balanced three-phase system feeding a three-phase
balanced load does not cause power oscillations [3].
The traditional concepts of apparent power and reactive power are not suitable for
unbalanced three-phase systems. As example, in an unbalanced system the fact that
the line currents are proportional to system voltages does not assure maximum average
(active) power transfer between systems [3].
Based on rms values of voltages and currents, two different definitions of apparent
power have been proposed:
It has been proved that under unbalanced and distorted conditions SP ≤ S3φ . SP
have been used by some authors as ”the maximum reachable active power at unity power
factor” [7].
However, the physical meaning of these definitions is not universally accepted, and
some authors state that they are only mathematical expressions. For example, Akagi
et al only consider the instantaneous active power as universal concept in three-phase
systems [3].
Power definitions are employed in the control of power converters, specially in power
line conditioners [3, 8–10], since Akagi et al presented their ”instantaneous active power
theory” [11]. However, dealing with power magnitudes in real-time has some drawbacks,
specially in three-phase and four-wires systems [3, 12].
ω ω ω ω
vbmax vb + vb -
φab vabc 0
120º va + 120º va -
φbc = 120º + 120º +
vamax
φca 120º 120º
vc + vc -
vcmax
va max ≠vb max≠ vcmax Positive Sequence Negative Sequence Zero Sequence
Amplitude (p.u.)
Amplitude (p.u.)
0.06
Amplitude (p.u.)
0.1
Amplitude (p.u.)
0.5 0.5 0.04
0.05
0.02
0
= 0
+ -0.05
0
+ 0
-0.02
zero-sequence phasor V̇0 [21]. The Fortescue transformation by means of the S matrix is:
V̇ 0 1 1 1 V̇a
1
V̇ + a2
= · 1 a · V̇ , (1.37)
b
3
V̇ − 1 a2 a V̇c
| {z }
S
√
j(2π/3) −1 3
a = 1∠120 deg = e = +j . (1.38)
2 2
The real time implementation of S is approached in some works; the imaginary unit
j is implemented by means of digital filters with a 90 deg delay at ω1 [22]. However, this
approach have some limitations, as shown in chapter 2.
Clarke and Park transformations [23, 24], also based on the symmetrical components
theory, offer a much higher versatility, specially for real-time implementations such as
power converter controllers, monitoring systems, etc.
va
vα 2 1 −0.5 −0.5
= √ √ · vb , (1.39)
vβ 3 0 3
−2 3
2
| {z } | {z } vc
vαβ C | {z }
vabc
where vα and vβ are two orthogonal waves rotating at the same frequency that vabc , which
have information of both positive and negative sequences; zero-sequences do not appear
in vαβ [21]. The Clarke transformation is employed in several controllers such as the ones
implementing the Space Vector Modulation (SVM) technique [16, 25]. It is also widely
employed in grid synchronization.
va+
vd+ 2 sin(θ) sin(θ − 2π
3
) sin(θ + 2π
3
)
vb+
·
= , (1.40)
vq+ 3 cos(θ) cos(θ − 2π ) cos(θ + 2π )
3 3
| {z } | {z } vc+
v+
dq
P+ | {z }
vabc
R π
where θ = −π ωt+ϕ, ϕ being an offset constant. When referring to (1.40) implementation,
it is usually said that vabc is transformed to the synchronous reference frame (SRF) stated
by θ. Fig. 1.5 shows the graphical representation of vabc in the SRF established by θ.
q ω
vq+
v dq
vd+ d
2π 2π
2 sin (θ) sin (θ + 3
) sin (θ − 3
)
P− = , (1.41)
3 cos (θ) cos (θ + 2π
) cos (θ − 2π
)
3 3
π R
where θ = −π ωt + ϕ. Through P− the negative-sequence rotating at ω are trans-
formed to dc components and other sequences are “moved” to different frequencies. When
representing sequences in the SRF of P− , the sense of rotation is clock-wise.
0
Regarding to zero-sequences of any frequency, it should be noticed that P− · vabc =0
0
and P · vabc = 0. Therefore, zero-sequences are neglected when working with SRF based
−
approaches.
In this section, P+ and P− have been defined for a generic frequency (ω). However,
it should be noticed that electric power applications usually deal with signals containing
sequences (positive and/or negative) of more than one frequency: a fundamental com-
ponent rotating at fundamental frequency and its harmonics components. Starting from
this point, the subscript “1” is also added both to P+ and P− to refer to the fundamental
component and subscripts ”h”, where h = 2, 3, 4, 5, ... to harmonic components. E.g. P+ 1
refers to the Park transformation for the fundamental positive-frequency.
1
Negative frequencies implies a change in the kind of sequence (e.g. from negative to positive).
16 Chapter 1 Introduction
On the other hand, the Park transformation can be considered as the combination of
the Clarke transformation and the so-called angle transformations B+ and B− [21]:
cos (θ) sin (θ)
B+ = , (1.42)
− sin (θ) cos (θ)
cos(θ) − sin(θ)
B− = . (1.43)
sin(θ) cos(θ)
So
2π 2π
2 cos(θ) cos(θ − ) cos(θ + )
P+ = B+ · C = 3 3 (1.44)
3 − sin(θ) − sin(θ − 2π ) − sin(θ + 2π )
3 3
and
2 cos(θ) cos(θ + 2π
3
) cos(θ − 2π
3
)
P− = B− · C = . (1.45)
3 − sin(θ) − sin(θ + 2π ) − sin(θ − 2π )
3 3
Apparently, Park transformations (1.40) and (1.41) could seem different from (1.44)
and (1.45). However, they are totally equivalent, the difference is in how to express the
vabc vector, either as cosine waves [24, 28] or as sine waves [29, 30]. Anyway, both
approaches lead to the same final results and equivalent intermediate analysis.
As stated in [31], the term “power quality” refers to a wide variety of electromagnetic
phenomena that characterize the voltage and current at a given time and location on
1.4 Background on Power Quality 17
the power system. This section summarizes the terminology to describe the most com-
mon events. location on the power system. This section summarizes the terminology to
describe the most common events.
1.4.1 Transients
It refers to very short duration undesirable events in the voltages, currents or power in
an electric circuit. Depending on the wave-shape of the transient, there are two categories
of transients:
Back to back capacitor energization gives rise to current oscillatory transients in the
tens of kHz.
Low frequency oscillatory transients (< 5 kHz) are present both in sub-transmission
and distribution systems mainly due to capacitor bank and transformers energization.
They last more than transients: between 0.5 cycles of the fundamental frequency
(50 or 60 Hz) and 1 minute. They are mainly caused by fault conditions, energization
of large loads and intermittent loose connections in power wiring. These faults could
18 Chapter 1 Introduction
result in voltage rises (swells), voltage drops (sags) and even a complete loss of voltage
(interruptions).
1.4.2.1 Interruptions
It occurs when the supply voltage/current decreases to below 0.1 p.u.. The causes of
interruptions are power system faults, equipment failures and control malfunctions.
As said, the term sag refers to a voltage drop. They are characterized by their mag-
nitude and duration. The terminology recommended by [31] to refer to voltage sags is ”a
sag to 20 %”, which means that the line voltage is reduced to a 20%.
The main causes of sags are power system faults, switching of heavy loads or starting
of large motors. A very detailed work about kind of sags and causes is shown in [32].
1.4.2.3 Swells
It is an increase on the rms voltage or current at the nominal frequency. They are
also associated with system fault conditions but they are much less common than sags.
They are characterized by their magnitude and duration. Typical magnitudes are in the
range 1.1 p.u. and 1.8 p.u..
Long duration variations are rms deviations lasting for more than 1 minute. They
can be either over-voltages and under-voltages, depending on the cause of the variations.
They are caused by load variations on the system and switching operations. They are
characterized by plots voltage versus time.
1.4.3.1 Over-Voltage
Over-voltages may be result of load switching (e.g. switching off a large load) or
variations in the reactive compensations of a power system (e.g. switching on a capacitor
bank). Poor system voltage regulation capabilities or controls result in over-voltages.
1.4 Background on Power Quality 19
1.4.3.2 Under-Voltage
Their causes are the opposite to over-voltage ones: e.g. a big load switching on or a
capacitor bank switching off. Overloaded circuits may lead to under-voltage, too.
A decrease to zero of the supply voltage for a period of time longer than 1 minute
is a sustained interruptions. They are often permanent in nature and require manual
intervention to restoration.
Voltage imbalance or unbalance is defined as the ratio of the negative or zero sequence
component to the positive-sequence component. They main causes of these zero and neg-
ative sequences are unbalanced loads causing which results in a flow of zero and negative
sequence currents.
The main source of smooth voltage imbalance (less than 2%) is the single-phase loads
(unbalanced by definition) in three-phase circuits. Severe voltage imbalances (greater
than 5%) can result from single-phasing conditions.
Waveform distortion is steady-state deviation from the ideal sinusoidal wave of funda-
mental frequency. It is well characterized by the spectral content. They are five primary
types of waveform distortion:
1.4.5.1 Dc Offset
ac systems has some damaging effects such as an increase in the transformer saturation,
additional stressing of insulation and others.
1.4.5.2 Harmonics
Harmonics are sinusoidal voltages or currents having frequencies that are integer mul-
tiples of the fundamental (50 or 60 Hz). Harmonics combine with the fundamental voltage
or current, and produce distortion.
The cause of harmonics is the non-linearity of devices and loads which produce current
harmonics. These current harmonic also produces voltage harmonics because of the volt-
age drops in the power system impedances. Harmonic distortion is a growing concern for
many customers and for the overall power system due to increasing application of power
electronics equipment.
s
sum of all squares of amplitude of all wave harmonics
T HD = · 100% =
square of the amplitude of the f undamental component
qP
∞
(1.47)
h=2 Vh
· 100%.
V1
1.4.5.3 Inter-Harmonics
1.4.5.4 Notching
are high and therefore difficult to measure accurately with normal equipment. As shown
in the next chapter, notching can cause severe faults in power electronics converters for
which the control algorithm uses zero-cross detection circuits.
1.4.5.5 Noise
Noise is unwanted electrical signals with broadband spectral content lower than 200 kHz
superimposed over the power system voltages or currents. It is caused by power electronics
devices, control circuits, arcing equipment, non-linear loads and switching power supplies.
Noise phenomena is also very related with grounding. Basically, noise is any unwanted
distortion that cannot be classified as harmonics or transient.
Voltage fluctuations are systematic variations of the voltage envelope for which the
voltage range does not exceed the range 0.95 − 1.05 p.u..
Any load with continuous and significant current variations, specially in the reactive
components, may cause voltage fluctuations. Arc furnaces are the most common cause of
voltage variations on the transmission and distribution systems. Voltage fluctuations are
defined by their rms magnitude expressed as a percent of the fundamental.
The power system frequency is directly related to the rotational speed of the generators
on the power system. At any instant, the frequency depends on the balance between
the load and the generation. When this dynamic balance changes, small changes in
frequency occur. The size of the frequency variations 2 and its duration depends on the
load characteristics and the response of the generation system to load changes.
Frequency deviations outside accepted limits for normal steady-state operation can
be caused by faults on the bulk power transmission system, a disconnection of a large
load or a disconnection of a large source of generation. Frequency variation affecting to
equipment also appear in systems powered by isolated generators.
2
The term power frequency deviations is also employed.
22 Chapter 1 Introduction
This section dealts with power electronic converters connected to an ac mains 3 . The
main devices, architectures, and applications are summarized in this section. A special
emphasis is put in the importance of synchronization and extraction algorithms in their
controllers.
The thyristor is one of the most important types of power semiconductor devices. It
is suitable for circuits where high currents and voltages are involved. It is a four-layer
semiconductor device with three pn-juntions and three terminals: anode, cathode and
gate.
When the anode voltage is positive with respect to the cathode voltage the thyristor is
said to be in off-state condition. It can be turned on by applying a positive voltage between
gate and cathode. When the thyristor is turned on, it goes on conducting while the anode
to cathode current is above the so-called holding current; there is no influence of the gate
signal during the on-state. When the anode to cathode voltage is negative, the thyristor
behaves like a reverse biased diode: there is not current through them (independently of
the gate signal).
Fig. 1.6 shows a 6-pulse thyristor full rectifier with linear load (zL ). The average
current through the transmission cable (īdc ) directly depends on the average voltage across
the dc side terminals (v̄dc ). The active power in the dc bus is Pdc = v̄dc · īdc .
A balanced set of input voltages can be expressed as function of the line-to-line voltage
3
Even though dc-dc conversion is a very important branch of power electronics, it is approached neither
in this section nor in this Ph.D. dissertation.
1.5 Power Electronic Converters and Applications 23
idc
S1 S3 S5
va Ls
vb Ls
vdc
zL
vc Ls
S2 S4 S6
vllmax as:
vll vll
va = √max sin(ω1 t) = √max sin(θ1 )
3 3
vllmax 2π
vb = √ sin(θ1 − ) (1.48)
3 3
vll 2π
vc = √max sin(θ1 + ),
3 3
R
where θ1 = ω1 dt is the phase-angle oscillating at ω1 (ϕ1 = 0).
In normal operation, one upper and one lower thyristor of different branches are con-
ducing. Hence, The total number of combinations, or states, is 6. The notation used to
show in which state is the rectifier is Sij , where i refers to the upper branch and j the
lower branch. For example, the state Sab refers to thyristor T 1 and T 4 conducing.
The switch between states is set by the firing of the thyristor. The normal operation
sequence is Scb → Sab → Sac → Sbc → Sba → Sca → Scb → Sab → ... and so on.
From (1.48), va is the highest of the three in the range [30, 150] deg, vb in the range
[150, 270] deg and vc in the range [270, 390 (30)] deg. Moreover, va is the lowest of the
three in the range [210, 330] deg, vb in the range [330, 450 (90)] deg and vc in the range
[90, 210] deg.
If diodes are used instead of thyristor, the switching time are not controlled: each
diode starts conducting when its anode to cathode voltage is positive. Table 1.1 shows
the state dependence with respect to the line phase-angle.
However, if thyristors are used, their conduction could be delayed by choosing the
desired firing angle, named α; the α angle can be set in the range 0 deg < α < 180 deg,
24 Chapter 1 Introduction
Table 1.1
States of diode full rectifier depending of θ1 .
Range of θ1 State
[0, 30] deg Scb
[30, 90] deg Sab
[90, 150] deg Sac
[150, 210] deg Sbc
[210, 270] deg Sba
[270, 330] deg Sca
[330, 360] deg Scb
Table 1.2
State of controlled rectifier depending of θ1 and α.
Range of θ1 State
[0 + α, 30 + α] deg Scb
[30 + α, 90 + α] deg Sab
[90 + α, 150 + α] deg Sac
[150 + α, 210 + α] deg Sbc
[210 + α, 270 + α] deg Sba
[270 + α, 330 + α] deg Sca
[330 + α, 360 + α] deg Scb
that is when the thyristors anode to cathode voltage is positive. The switching times as
function of α are the shown in table 1.2.
1 Zα Z α+pi/6
3
v̄dc = [ vc − vb + va − vb + ....] = · vllmax · cos (α). (1.49)
T 0 α π
As expected, the maximum value of v̄dc corresponds with diode operation, that is
α = 0 deg. The average current īdc depends on v̄dc and the resistive component of zf
(zf (ω = 0)):
v̄dc
īdc = . (1.50)
zf (ω = 0)
The operation of the rectifier is not linear: vdc has ripple components over v̄dc . This
1.5 Power Electronic Converters and Applications 25
α=0 deg.
vdc
α=90 deg.
idc
α=180 deg.
ripple is composed of even harmonic components and also affects to īdc . Therefore, this
rectifier is producing reactive power for any α.
Fig. 1.8 shows the rectifier working in different points. The firing instant are the
points where the switching state changes are highlighted as discontinuous lines. It is clear
the non-linear behavior of this converter and its inherent reactive power consumption for
any zf . The ripple is higher as lower is the module of v̄dc .
Nowadays, with the suitability of better controllable switching devices, the use of
thyristors is in three-phase and high-power applications.
Fig. 1.9 shows a simple scheme of a HVDC. In order to minimize the losses in the
transmission line due to parasitic reactances the origin ac voltages are transformed into
high dc voltages. A power converter working as rectifier to convert the origin ac signal
to dc is employed. Another power converter is placed in the destination point to convert
the dc voltage to ac (inverter).
26 Chapter 1 Introduction
0.8
0.6
0.4
0.2
-0.2
-0.4
-0.6
0.4
0.2
-0.2
-0.4
-0.6
Sca
Sbc Sba Scb Sab Sac Sbc Sba
-1
1.95 1.955 1.965 1.97 1.975
idc
Origin ac System Destination ac System
Rectifier Inverter
Ldc
ac dc
ac
Motor
Rectifier Inverter
There are also series devices such as Thyristor Controlled Series Capacitors (TCSC),
Thyristor Controlled Series Reactances (TCSR), etc citeHingorani2000.
1.5.1.2.3 Ac Motor Drives Induction motors with squirrel cage rotors are very suit-
able for industry because of their low cost and robustness. When operated from the line
voltage as input, they work at constant speed and torque. However, by means of power
electronics converters, it is possible to control speed, torque and even position.
Fig. 1.10 shows a scheme used for the speed control of an ac induction motor using two
thyristor converter, one as rectifier and another one as inverter. This scheme is employed
in very large power rating applications, where a very fast dynamic response is not needed.
28 Chapter 1 Introduction
The rectifier converter controls the dc voltage, and the inverter controls the ac voltage
in the input of the ac motor. Varying this ac input voltage, the point of operation of the
motor (speed and torque) is controlled.
Pulse Width Modulation (PWM) is the more widespread technique to set both the on
and off firing signals of power converter switches.
The use of thyristors in PWM converters requires a forced commutation scheme. How-
ever, there are some other devices, which allow a better on-off switching control and are
suitable from lower to medium-high power rated applications: Insulated Gate Bipolar
Transistors (IGBTs), Metal Oxide Semiconductor Field Effect Transistors (MOSFETs),
Bipolar Junction Transistors (BJTs), etc. The main advantage of these devices with re-
spect to Thyristor is the fact that they are bidirectional in current. However, they only
block voltage in one way (unidirectional in voltage).
In general, PWM converters are suitable to work in four quadrant operation under the
power flow point of view. Owing to this flexibility, PWM power converters are employed
in vast range of applications.
A brief explanation of PWM operation is shown in this section. Lets suppose the
one-leg switch inverter of Fig 1.11. Ideal switches are considered instead of real power
electronic devices (S+ and S− ). Each switch has a control signal, which set if the switch
is in conducting (on state, boolean 1) or not (off state, boolean 0). Only one switch per
phase can be in on state, else the dc link would be short-circuited. The instantaneous
value of the voltage in the point “a” (va ) depends on which switch is on: vdc /2 or −vdc /2.
The rate of commutation for the switches sets the switching frequency (fs ). The maximum
value of fs is limited by the real devices (e.g. around 20 kHz for IGBTs). The average
value of va , averaged each commutation cycle, defined as v̄a will depend on the time each
switch in on. The duty cycle (d) is defined as the ration of time per commutation cycle
the switch is on per total commutation cycle. So:
vdc −vdc
v̄a = d + (1 − d) . (1.51)
2 2
Therefore setting d for each commutation cycle accordingly, the output voltage in “a”
can be controlled in real time. Equation 1.51 can also be expressed by the PWM control
1.5 Power Electronic Converters and Applications 29
+ vdc + S+
2
vdc -
a
vdc +
S- +
2 - van
- -
n
Figure 1.11: One leg of a switch mode inverter.
vdc
v̄a = m . (1.52)
2
1.5.2.1.1 Sinusoidal PWM Sinusoidal PWM is one of the most employed technique
to generate the control signals of the power switches. An example applied to the branch
of Fig. 1.11 is provided as follows.
The firing signals of the switches are obtained by comparing a triangular wave (vtri )
of amplitude 1 and switching frequency (fs ) with a control signal m. The switching rules
are:
vdc
m > vtri S+ ON, S− OF F ⇒ va =
2 (1.53)
−vdc
m < vtri S+ OF F, S− ON ⇒ va = .
2
Fig. 1.12 shows the firing signal of S+ obtained with these switching rules (S− is
the opposite to S+ ). m rotates at 50 Hz, a frequency much lower than vtri frequency,
fs = 10 kHz.
Using these switching rules, the v̄a , averaged each switching cycle, is:
vdc
v̄a = m . (1.54)
2
30 Chapter 1 Introduction
0.8
0.6 vtri m
0.4
0.2
-0.2
-0.4
-0.6
-0.8
Fig. 1.14 shows Fourier coefficients of va . It is shown how, even though the control
signal has only a 50 Hz component, va has much more spectrum components. There are
relative high components around the switching frequency (and its harmonics), and, in
general, a continuous non-zero spectrum.
There are several modulation techniques for power electronic converters. E.g. SVM
algorithms, which result in different switching sequences and spectrum contents.
Voltage-source converters (VSC) with PWM modulation are, by far, the most popular
converters for ac power supplies up to a few megawatts [36]. Fig. 1.15 shows the topology
of a three-phase VSC; ei (i = a, b, c) is the per-phase output voltage of the VSC. The
average value of ei (ēi ), averaged each commutation cycle (fs ), can be set through the
PWM or SVM techniques [16, 25].
Considering only the fundamental component of each ei , the power flow between the
ac mains and the dc side of the VSC, both active and reactive, can be controlled. This is
called four quadrant operation.
1.5 Power Electronic Converters and Applications 31
0.8
0.6
0.4
m
0.2
-0.2
-0.4
vtri
-0.6
-0.8
0.08 0.082 0.084 0.086 0.088 0.09 0.092 0.094 0.096 0.098 0.1
vdc/2
a
-vdc/2
0.082 0.084 0.086 0.088 0.09 0.092 0.094 0.096 0.098
id
S1 S3 S5
va La ea
vb Lb eb vd Cd
vc Lc ec
S2 S4 S6
vi ii Li ei
Fig. 1.16 is the per-phase representation of the VSC, where i means a, b or c phase, and
vi refers only to the supply fundamental component. The system is considered rotating
at ω1 .
From Fig. 1.16 results clear that the current through Li (ii ) depends on vi and ei . In
phasor notation this can be expressed as:
V̇i − Ėi
I˙i = = imax ∠φ1 , (1.55)
jω1 Li
where V̇i = vmax ∠0 and Ėi = emax ∠β1 ; β1 being the phase-angle offset between vi and ei
4
.
S = 3 · vrms · irms
P = 3 · vrms · irms · cos(φ1 ) (1.56)
Q = 3 · vrms · irms · sin(φ1 )
4
It should be noticed that the angle references can be set with respect to V̇i .
1.5 Power Electronic Converters and Applications 33
ℑ=Q
Quadrant II Quadrant I
VSC supplies active power to the grid. VSC absorbs active power from the grid.
VSC absorbs reactive power from the grid. VSC absorbs reactive power from the grid.
ℜ=P
Region III Region III
VSC supplies active power to the grid. VSC absorbs active power from the grid.
VSC supplies reactive power to the grid. VSC supplies reactive power from the grid.
where rms values are easily obtained from the peak values as:
vmax
vrms = √
2
imax (1.57)
irms = √ .
2
Therefore, by assessing emax and β1 accordingly, the energy transfer between the ac
side and dc side of the VSC can be controlled. Fig. 1.17 shows the complex plane to
represent the four quadrant operation of the VSC connected to the ac grid.
These complex power can also be represented using P and Q as axis (P − Q diagram).
Fig. 1.18 shows the different operation points of the VSC connected to the ac mains. It
is clear that the VSC is a very flexible device when connected to the grid: from the point
of view of the fundamental components, it is possible to absorb and supply active power,
but also positive and negative reactive power. It is typical to refer to the VSC as Voltage
Source Inverter (VSI) when it is working suppling active power to the ac grid, that is
dc-ac conversion.
VSCs can handle components rotating at higher frequencies than ω1 , e.g. harmonics.
The maximum frequency that a VSC is able to control in steady-state is related to the
controller bandwidth. Generally, it is assumed that the VSC bandwidth is the tenth (or
eleventh) part of the PWM frequency. For example, an IGBT based VSC commutating
at 10 kHz can handle with harmonics around the 20 one (1 kHz) [37, 38]. VSCs can be
connected in series, between the ac mains and another electrical system.
34 Chapter 1 Introduction
V&i Q
E& i
Q
β1
I&Lsi
β1 V&Lsi
P P
I&Lsi φ1 V&Lsi
φ1 V&i
E& i
ac dc
ac
Motor
Rectifier Inverter
1.5.2.3.1 Ac Motor Drives As said, VSC and other PWM converter topologies used
as inverter can control both frequency and magnitude of their outputs. On the other hand,
the speed of rotation of ac motors depends on the frequency of the stator voltage and the
torque on the magnitude. Therefore, it is possible to control both torque and speed of
an induction motor by means of, for example, a PWM converter as depicted in Fig. 1.19.
The ac line voltage is rectified by means of an uncontrolled diode rectifier and the inverter
feeds the stator with a voltage which controls its torque and rotation speed.
equipment by supplying power from a separate source when utility power is not available.
A UPS can be used to provide uninterrupted power to equipment for 1–20 minutes until
a generator can be turned on or utility power is restored.
• Power Factor Correction: a PWM converter can be placed in parallel with the rest
of loads supplying a fundamental current so the power factor from the ac source
remains around 1 [39, 40].
• Active Power Filters (APF) for harmonic compensation: the PWM converter can
be placed in series or in parallel with the protected loads, to compensate for voltage
or current harmonics [8, 41–45].
• Dynamic Voltage Restorer (DVR): the PWM converter is placed in series with a
sensible loads so it is prevented from voltage sags [46–50].
• UPSs can be considered power line conditioners since they provide protection against
all common power problems [51–53].
Even though analog control circuits are still being proposed and used, the clear trend
is the implementation of the control algorithms in digital devices. Current devices such as
Digital Signal Processors (DSP), Field Programmable Gate Arrays (FPGA) and Micro-
controllers allow the digital implementation of controllers for power electronics converters
[54–56]. Digital implementation offers quite a lot of advantages with respect to analog
circuits, above all its flexibility in the design, implementation and maintenance.
Fig. 1.20 shows a simplified scheme of dc-link voltage (vdc ) feedback controller using a
PI filter and SRFs obtained through the Park transformation (P1+ ). The phase-angle for
P1+ generation is obtained from a synchronization block (θ̂1v ). Assuming perfect tracking
(θ̂1v = θ1v ) the grid current (iabc ) is in-phase with the grid voltage (vabc ), so there is only
active power flow from the PCC to the dc-link.
Using the values of table 1.3, the dc controller has been simulated in order to show
the role of the synchronization algorithm.
1.6 Control of Power Electronic Converters and Synchronization 37
PCC iabc Lr
Current ac dc
vabc Sensors Side Side
Cdc vdc ZL
VSC
Firing
iabc Signals Voltage
Sensor
ac Voltage iq1+ iq1+*=0
Sensors
SRF
P1+ + Current
id1 Regulator id1+*
- vdc
θ1
PI
)v +
vabc
Synch. vdc*
Digital Controller
Table 1.3
VSC based Rectifier Values.
vmax 1 p.u.
vdc
∗
1.5 p.u.
Cdc 3 p.u. at 50 Hz
ZL (resistive) 1 p.u.
Voltage Regulator ≈ 50 Hz
Bandwidth
Current Regulator ∞
Bandwidth
38 Chapter 1 Introduction
0.5
-0.5
-1
5.01 5.02 5.03 5.04 5.06 5.07 5.08 5.09 5.1
0.5
-0.5
-1
-1.5
5.01 5.02 5.03 5.04 5.06 5.07 5.08 5.09 5.1
Fig. 1.21 shows steady-state voltages/currents of the power system for perfect tracking
(dotted) and when there is a constant steady-state phase error (θ1e = θ1v − θ̂1v ) of ≈
14 deg (solid). The effect of non-zero phase-error is a displacement power factor cos(φ1 )
reduction, both for single-phase and three-phase systems. A cos(φ1 ) 6= 1 results in Q 6= 0,
so higher rated currents are needed to maintain the bus voltage at the reference value
(vdc
∗
). Therefore, average steady state phase error (θ̄1e ) 5 should be canceled to get an
optimized real-time controller.
Fig. 1.22 shows steady-state voltages/currents when there is ripple of 2th harmonic
over the phase estimation. As shown, ripple in the measurement infers also ripple in iabc
and vdc 6 . Therefore, noise in phase estimation reduces the whole performance of the
5
Even though in PWM/SVM the average values are averaged each cycle of fs , in synchronization the
averaging is related to f1 .
6
The frequency of vdc ripple is 4ω1 , not 2ω1 .
1.6 Control of Power Electronic Converters and Synchronization 39
1.501
1.5008
1.5006
1.5004
1.5002
1.5
1.4998
1.4996
1.4994
1
1.4992
1 1
1.499
5.01 5.02 5.03 5.04 5.06 5.07 5.08 5.09 5.1
dc-link controller.
From this significant examples, it results clear the important role of synchronization
in the control of grid-connected power electronic converters. The performance of the
synchronization block is critical in very fast responding applications as well as for high
power rated systems.
40 Chapter 1 Introduction
0.8
a
b
0.6
0.4
0.2
-0.2
-0.4
-0.6
c
-0.8
-1
13.98 13.985 13.99 13.995 14.005 14.01 14.015 14.025 14.03
50
1
1
30
20
10
-10
-20
13.9 14.1 14.2 14.3 14.4 14.6 14.7 14.8
1.6
1.55
1.45
1.4
1.35
dc
1.3
dc
Figure 1.23: VSC operation during a transient. Effect of the re-tracking speed.
1.7 Structure of the Document 41
Chapter 3 is devoted to digital PLLs design. In a general way, PLLs with a low
bandwidth (low-gain PLLs) are required when handling with distorted voltages. It is
analytically demonstrated that low-gain PLLs have more trade-offs than high-gain PLLs
(e.g. PLLs for communications): it is not possible to optimize the settling time for a
phase-jump without getting slower the PLL response to frequency variations. Existing
tuning methods do not take into account low-gain features, which may result in non-
optimum designs. An intuitive tuning methodology based on inspection of frequency-
domain diagrams is contributed in this chapter. Contrary to the other existing tuning
methods, it takes into account low-gain dynamics. It is assured an optimized performance
in the presence of any kind of disturbances in the grid. In the second part of the chapter,
the DCO based on a RC oscillator is presented: the digital model of a sinusoidal oscillator
is implemented, instead of explicit trigonometric functions. This solution reduces the
needed digital resources without reducing the performance, which could be specially useful
for DSP-based control of power converters.
42 Chapter 1 Introduction
In summary, the main attributes of the new system are its good frequency adaptation,
good filtering/transient response trade-off and the fact that its dynamics is independent of
the input vector amplitude. Comprehensive experimental results validate the theoretical
approach and the high performance of the proposed synchronization algorithm.
The main contributions of this work are reviewed in the last chapter. An outline of
programmed future works is also provided.
44 Chapter 1 Introduction
Chapter 2
State-of-the-Art in Grid
Synchronization
Abstract —
The control of the power flow between a grid-connected power converter and the ac-mains
requires an online tracking of the fundamental component voltage (or current) phase-angle.
The very first synchronization schemes were based on an open loop estimation of the phase-
angle from the observation of zero-crosses. However, the presence of power quality phenomena,
specially in weak-grids, led to malfunctions in zero-cross based controllers. The introduction
of voltage controlled oscillators (VCOs) resulted in more robust controllers such as the Phase
Locked Oscillator (PLO) system and the Charge-Pump Phase Locked Loops (CP-PLL).
With the suitability of discrete devices such as micro-controllers the number of synchroniza-
tion algorithms and filtering techniques has grown drastically, in parallel with the appearance of
high performance applications (high bandwidth) and new technical requirements in fields such as
renewable energy applications, traction systems and power line conditioners. Digital Phase locked
Loops (PLL) and algorithms implementing stochastic and/or FIR filters are clear examples of
the high performance offered by digital implementation.
However, the research in the synchronization field cannot be considered complete at all. The
appearance of new applications and/or technical requirements of existing ones would need the
development of specific solutions. A review in synchronization strategies for power converters is
contributed in this chapter.
Even though the main part of this chapter is devoted to synchronization with fundamen-
tal component vectors, the issues of harmonics and negative-sequences extraction are also ap-
proached, since to synchronize with those components is required in several applications.
It should be noticed that, even though this chapter may seem to be presented in a temporal-line
manner, many of the approaches have coexisted since their proposal to nowadays.
45
46 Chapter 2 State-of-the-Art in Grid Synchronization
Input D1 D3 R3 Output
Dgen Dgen 1k
VAC1 V C1 V
1000u
0 Q1
R2
VAC2 0
1k
D2 QgenN
R1
Dgen
VAMPL = 21.2V 100k
FREQ = 50Hz
0
(a) Simple analog zero-cross detector circuit.
25
V(output)
20
15
10
Voltage (V)
-5
-10
V(input)
-15
-20
-25
0 0.01 0.02 0.03 0.04 0.05 0.06
Time (s)
When using with ac networks, zero-cross detectors obtain the information of the phase-
angle: 0 deg and 180 deg coincide with the pulses at the outputs.
In Fig. 2.1 an example of analog zero-cross detector connected to the utility grid is
shown. The input wave is supposed to be obtained from the secondary of a 220/15 V and
50 Hz transformer. The transistor Q1 is polarized in the active zone except during the
zero crosses. Under such a situation Q1 is in cut-off. As there is no current through Q1,
the voltage in the output is a bit lower than the peak value of the input voltage.
Fig. 2.1b shows the result of a time domain simulation, obtained with PSPICE, when
the input wave is ideal. As expected, the output has pulses during the zeros crosses.
2.1 Methods based on Zero-Cross Detection 47
Input U1
+ Output
VAC1 V R1
OUT
1k
V R2
- OPAMP 1k
0
VAMPL = 21.2V 0
FREQ = 50Hz
0
(a) Simple analog zero-cross detector circuit.
25
20
15
10
Voltage (V)
5
V(output)
0
-5
-10
-15
-20
V(input)
-25
0 0.01 0.02 0.03 0.04 0.05 0.06
Time (s)
Moreover, as the input wave frequency is just 50 Hz, the phase between zero crosses can
be extrapolated by means a multi-vibrator delay circuit or a digital counter [61].
The operational amplifier (OA) has been widely used for zero-cross detection. Fig. 2.2a
shows a simple circuit of zero-cross detection using an OA. Fig. 2.2b shows the result of
the time domain PSPICE simulation. When the input signal is sinusoidal, a square wave
in-phase with the input signal is obtained.
48 Chapter 2 State-of-the-Art in Grid Synchronization
idc
Origin ac System Destination ac System
Rectifier Inverter
The first implementation of power converters handling high power flows can be placed
in time with the high-voltage direct current systems (HVDC). HVDCs were initially used
to transmit large amounts of power between two ac systems over long distances. The
first commercial HVDC was developed between 1950 and 1954 in Sweden connecting the
Swedish island of Gotland with mainland. At that time, silicon devices were not suitable
for such a high power, so power converters were based on mercury-arc valves [62]. The
firing of these mercury-arc valves were equivalent to thyristor firing.
Fig. 2.3 shows a simple scheme of a HVDC. In order to minimize the losses in the
transmission line due to parasitic reactances, the origin ac voltages are transformed into
high dc voltages. A power converter is used working as rectifier to convert the origin ac
signal to dc. Another power converter is placed in the destination point to convert the dc
voltage to ac (inverter).
The control of a HVDC system is quite complex and requires many controllers includ-
ing steady-state operation and protection against transients; this subsection is focused in
the steady-state operation.
The most widely method employed to control the average 1 power flow from the origin
ac side to the dc bus is the so-called constant current (CC). The average value of the
rectifier current (īdc ) is controlled through the firing angle α.
These first rectifier controllers were based on the so-called constant-α and inverse-
cosine methods. Fig. 2.4a shows a simplified scheme of the constant-α method.
The control scheme is a circuit which implements a zero-cross detector and a variable
1
averaged each cycle of the fundamental f1 .
2.1 Methods based on Zero-Cross Detection 49
idc idc
AC DC v AC DC v
dc dc
Side Side Side Side
Per-phase Per-phase
AC Voltage AC Voltage
Sensors Sensors
Per-valve Per-valve
Zero-cross Controlled phase-lag Per-valve Firing
variable Firing Zero-cross
detection network circuits
circuits delay circuits detection
and
idc* circuits idc* comparator circuits
(external ref) (external ref) Controller circuit
Controller circuit
(a) Constant-α rectifier control scheme. (b) Inverse-cosine rectifier control scheme.
delay circuit per valve. The zero-cross detection circuits should detect separately 0 deg
and 180 deg zero crosses: 0 deg cross for upper valves and 180 deg for the lower ones. The
α angle is controlled externally (angle reference) which controls the delay of the variable
delay circuits.
The basic principle is that the delay angle can be obtained from the crossing point of
an associated “cosine-wave” with a control reference voltage at a comparator. The cosine-
wave is obtained from a phase-lag network so the output of that network has a peak at
the delay angle (α) equal to zero [63]. The firing pulse is generated at the point at which
the cosine-wave is equal to the control voltage (vr ), which is directly proportional to ī∗dc .
emax being the peak of the cosine-wave, the firing condition is set by the equation:
Fig. 2.4b shows a simplified scheme of the constant-α method. The main advantage
of this method is the fact that v̄dc varies linearly with vr .
Even though this circuit obtains good results for a lot of applications, the growing up
concern about power quality problems have led to consider other high performance solu-
tions. The main problems of zero-cross detectors are well summarized in [64]: harmonics
and noise.
50 Chapter 2 State-of-the-Art in Grid Synchronization
Fig. 2.5a shows the results of the time domain SPICE simulation when the input
wave has a 20% of 5th harmonic over the fundamental. As said, this harmonic changes
the zero-cross detection points, so there is non zero average phase error in steady-state.
With regard to the control of power converters, this error could easily lead to instability
and malfunction [65].
Fig. 2.5b shows the results of the time domain SPICE simulation when the input wave
contains notches. There are misleading zero-cross detections due to the notching, which
result in very high phase error.
Another drawback appears when considering input wave transients. Zero-cross de-
tectors only estimate the phase-angle one or two times per cycle, so when a phase-angle
jump occurs is not detected until the next zero-cross. Moreover, zero-cross detectors do
not provide frequency estimation or adaptation, which could lead to malfunctions in the
presence of frequency deviations.
In order to improve the performance in the zero-cross detection, some simple but
practical actions have been proposed, e.g.:
• In three-phase circuits a common practice has been to filter the b − phase and
extrapolate the a − phase from the filtered signal [66].
• With the suitability of digital devices implementing discrete operation, the possi-
bility of digital filtering resulted in a vast range of filtering alternatives. e.g. in [69]
the fundamental component is reconstructed from a notching wave, assuming that
the short-circuit parameters are known; in [70] an 11th order FIR filter is proposed
to cancel out harmonics.
30
Detected
20
Zero cross
Real
10 Zero cross
Voltage (V)
-10
Fundamental
-20 of V(input)
V(input)
-30
0 0.01 0.02 0.03 0.04 0.05 0.06
Time (s)
(a) Key figures under harmonic contaminated input.
25
Good
20 zero-cross
detection
15
10
Misleading
Voltage (V)
5 zero-cross
detection
0
-5
-10
-15
-20 V(input)
-25
0 0.01 0.02 0.03 0.04 0.05 0.06
Time (s)
(b) Key waves for a input wave with notches.
Xs Xr
AC DC
Side Side
AC
Source
Thyristor or Mercury-arc valves
Controlled Power Electronics Converter
Ainsworth in 1967 [65], when a problem called “harmonic instability” was reported 2 .
Harmonic instability occurs when the rectifier was connected to a weak system, a
system for which the short-circuit ratio (Xr /Xs ) is low: e.g. in the range 3 to 6 [71].
In order to overcome the problem of harmonic instability, passive filters were proposed,
but it was an insufficient alternative [34]. The real milestone in the control of the HVDC,
and indeed in the control of power electronic converters was the Ainsworth proposal of [1]:
the firing instants are independent from voltage zero-crosses through a voltage controlled
oscillator (VCO) inside the control loop. This proposal is deeply analyzed in section 2.2.
A surprising novel scheme for the control of power converters was contributed by J.
D. Ainsworth in [1]: the phase-locked oscillator (PLO) control system. The work of
Ainsworth is related with the need of a robust controller for HVDC systems connected to
weak ac grids, a problem he had posed in his previous paper [65].
The first PLO was a control system for the HVDC rectifier. Under ideal operation
conditions and during steady-state, this converter produces 5th , 7th , 11th , 13th , etc har-
monics in the ac side and 6th , 12th , etc in the dc side. Moreover, other harmonics may
2
’Harmonic instability’ does not mean instability in a feedback control system.
2.2 Phase-Locked Oscillator Control Systems 53
Xs Xr Ld idc
AC DC
vdc zL
Side Side
Current
Sensor
Firing C1
Signals
C2 R1
a
- idc*
-
ω̂1
VCO +
vco +
Figure 2.7: Scheme of the PLO controller for the HVDC rectifier proposed in [1].
also appear if unbalance and timing errors in the control systems are considered. The
presence of voltage harmonics in the ac side is higher as higher is the impedance between
the power converter and the generation (weak system) [65, 71]. The problem of those
converters working in a weak grid is the dependence of the control from the measure-
ment of the ac voltages, which could result in harmonic instability. Ainsworth proposed
a closed-loop controller containing a voltage controlled oscillator (VCO) in order to reject
the harmonics effect.
Fig. 2.7 depicts a PLO simplified scheme. The inductance current (idc ) is controlled in
a closed loop; i∗dc being its reference value. An analog filter is placed after the comparator;
the output of this filter is the input voltage of the VCO (vco ). The VCO generates
output pulses at a repetition frequency six times the system voltages/currents fundamental
frequency; the frequency of the VCO output signal implicitly represents the estimated
fundamental frequency (ω̂1 ). The output pulses, generated through a ring counter, are
employed to fire the thyristors/valves. When there is a positive difference in the output of
the comparator, the vco voltage tends to rise and, therefore, ω̂1 increases, so α is reduced.
For negative difference, the behavior is the opposite one.
Even though Fig. 2.7 represents a quite simplified model of the PLO system, it has
a very non-linear behavior. This subsection describes a linearization of the PLO system.
The linearization of the PLO was made by Ekstrom and Liss in [72], and, even though
Ainsworth was skeptical with this procedure (see discussion of [72]), nowadays it is clear
that linearization is a powerful tool to describe non-linear systems.
The average value of the voltage in the dc link (v̄dc ) is function of the line to line peak
54 Chapter 2 State-of-the-Art in Grid Synchronization
3
v̄dc = · vllmax · cos(α) = vdcmax · cos(α), (2.2)
π
3
where vdcmax = π
· vllmax .
Lets suppose a perturbation in the firing angle ∆α << 1, a small change in vdc (∆vdc )
is supposed. By introducing ∆α and ∆vdc in (2.2)
∆ω1
∆α = − . (2.6)
s
Therefore,
∆ω1
∆v̄dc = vdcmax · sin(α) · , (2.7)
s
which goes on being a non linear equivalence.
The relation between vdc and idc depends on the inductance Ld and the load impedance
(zL ):
vdc
idc = . (2.8)
Ld s + zL
∆ω1
vdcmax · sin(α) · s
idc = . (2.9)
Ld s + zL
2.2 Phase-Locked Oscillator Control Systems 55
Ainsworth designed a controller for the plant set by (2.11). This equation is non linear;
the plant depends on the firing angle through sin(α). Another source of non linearity is
due to the fact that the controller only acts at 60 deg intervals, that is, there is a time
dependent delay function, which should be considered in the design of a controller.
C2 · R1 · s + 1 Kc
C(s) = · (2.12)
C2 · C1 · R1 · s + (C2 + C1 ) s
Kc being a constant. Fig. 2.8 shows the control block diagram of the PLO.
In order to study the dynamics of the system, this model should be evaluated in all
the range of possible values of α. In [1] the minimum α was 5 deg. It is clear that, the
lower α, the lower the gain of the loop.
As pointed by Ainsworth the circuit in steady state is always in the range [0, 180] deg.
This implies in practice that ω̂1 ≈ ω1 so
1
g(t) ≤ . (2.13)
6 · f1n
Therefore, the firing delay can be modeled taken into account the worst case: the
delay is maximum ( 6·f11n ) (Fig. 2.9).
56 Chapter 2 State-of-the-Art in Grid Synchronization
s
idc
Analog filter VCO and Firing Circuit Rectifier circuit
Figure 2.9: Equivalent block diagram of PLO circuit and controller for firing maximum
delay.
Table 2.1
HVDC values.
vdcmax 1 p.u.
zL (Resistive) 1 p.u.
Ld 1/(10 · π) p.u.
• It has two poles at the origin. The phase versus frequency response is −180 deg at
dc.
• The introduced delay tends to lag the phase, reducing the phase margin (PM).
• There are another two poles: one at −(C1 + C2 )/C1 · C2 · R1 rad/s due to the con-
troller and another at −zL /Ld rad/s due to the plant.
In order to avoid a negative phase margin for very low frequencies and, therefore, to
have an unstable system, the controller should have its zero very near to the origin. The
bandwidth of the system is limited by the second pole of the controller.
A more in-depth study of a model would require the knowledge of the practical sys-
tem values employed by Ainsworth. In this section, an example of the PLO system is
contributed in order to show its performance 3 .
The most important data of this table is the relation between zL and the equivalent
inductance Ld , because this relation sets a pole in the plant. The controller parameters
of the example are shown in table 2.2.
2.2 Phase-Locked Oscillator Control Systems 57
Table 2.2
Controller Values.
R1 100 kΩ
C1 100 pF
C2 100 µF
α range [5, 90] deg
Kc 10−5
Kvco 100 rad/V
300 300
Total
Total
200 200
Controller
Magnitude (dB)
Amplitude (dB)
100 100
Controller
Plant
0 0
Delay Delay
-100 -100
Plant
-200 -3 -2 -1 0 1 2 -200 -3 -2 -1 0 1 2
10 10 10 10 10 10 10 10 10 10 10 10
0 0
Delay Delay Controller
-50 Controller -50
Plant
-100 -100
Phase (deg)
Phase (deg)
Total Plant
-150 -150 Total
-180 -180
-200 -200
-250
-250
-300 -3
10 10
-2 -1
10 10
0
10
1 2
10 -300 -3 -2 -1 0 1 2
10 10 10 10 10 10
Frequency (Hz)
Frequency (Hz)
(a) Equivalent linearized model for α = 5 deg. (b) Equivalent linearized model for α = 90 deg.
P M = 66.5 deg, at 1.35 Hz. P M = 19.92 deg, at 8.25 Hz.
0.75
0.65
0.94
0.93 0.6
0.55
0.92
0.91
0.45
(a) PLO Start-up. Step in i∗dc from 0.9 p.u. to (b) PLO Start-up. Step in i∗dc from 0.55 p.u. to
0.95 p.u.. 0.5 p.u..
Figure 2.11: Start-up simulation of PLO for different i∗dc (dotted), idc is the blue line.
As shown in Figs. 2.10 it is possible to tune a controller stable for all the α range. As
pointed by Ekstrom in [72], for higher α values the system is difficult to stabilize. In fact,
the PM for α = 90 deg is very small. But, on the other hand, as pointed by Ainsworth
in the discussion of [72], it is also true that for lower α values the tuning becomes more
concerning since the bandwidth becomes very small and the system could easily go out
from normal operation.
From Figs. 2.10 an important feature of the PLO is observed. The magnitude gain
decreases very fast with the frequency, so it is expected a good current harmonic cancel-
lation.
The simplified scheme of Fig. 2.7 with the parameters and component values of
table 2.2 has been simulated through the PLO Matlab scripts of appendix (from A.1
to A.3).
Fig. 2.11 shows the start-up for a the PLO working in different points (α). After the
initial transient the current reference is perfectly tracked. Fig. 2.11a shows the start-
up when α is 18.2 deg. In such a situation, the output current in steady-state should
be 0.95 p.u.. Fig. 2.11b shows the start-up when α is 60 deg, so the output current in
steady-state should be 0.5 p.u.. A comparative between both figures shows how for lower
α the overshoot is lower, since the PM is higher. Higher α results in a shorter rise time
but with a higher overshoot, since the PM is shorter. These results are expected from
Figs. 2.10.
Figs. 2.12 show the system voltages when steady-state is reached for both cases shown
in Fig. 2.11. As zL has been chosen to be 1 p.u. pure resistive, v̄dc should be equal to īdc .
Figs. 2.13 show the results of a simulation when the voltages system is unbalanced
both in amplitudes and angles. Specifically the phase to neutral voltages of the test have
3
Component values and tests made in this section may differ from first PLO tests.
2.2 Phase-Locked Oscillator Control Systems 59
1 1
0.95
Vdc Vdc
0.8 0.8
Vdc Vdc
0.6 0.6
0.5
0.4 0.4
0.2 0.2
0 0
Vb Vc
-0.2 -0.2 Va Vb
Va Vc
-0.4 -0.4
-0.6 -0.6
5.95 5.955 5.96 5.965 5.97 5.975 5.98 5.985 5.99 5.995 6 5.95 5.955 5.96 5.965 5.97 5.975 5.98 5.985 5.99 5.995 6
(a) Steady state voltages for Fig. 2.11a. (b) Steady state voltages for Fig. 2.11b.
1
Vdc Vdc
0.8
0.78
0.7
0.6
0.76
0.4
0.74
0.2
0.72
0
Vb Vc
-0.2
Va
0.68 -0.4
0.66 -0.6
1 1.5 2 2.5 3 3.5 4 4.5 5.95 5.955 5.96 5.965 5.97 5.975 5.98 5.985 5.99 5.995 6
(a) PLO Start-up for an unbalanced set of voltages. (b) Steady state voltages for Fig. 2.12b.
Step in i∗dc (dotted) from 0.8 p.u. to 0.7 p.u., idc is
the blue line.
the expression
va = 1 · sin(ω1n t)
vb = 0.8 · sin(ω1n t − (2 ∗ pi/3 + 0.1)) (2.14)
vc = 0.9 · sin(ω1n t + (2 ∗ pi/3 + 0.1)).
Perfect tracking under unbalanced conditions is observed; the PLO rejects voltage
unbalance effects.
Figs. 2.14 show the results of a simulation when the voltages system is unbalanced
both in amplitudes and angles and also very distorted by harmonics. Specifically, the
phase to neutral voltages of the test have been:
60 Chapter 2 State-of-the-Art in Grid Synchronization
1.2
0.84
Vdc
0.82
Vdc
0.8
0.6
0.78
0.4
0.76
0.2
0.74
0.72
Vb
-0.2 Va
Vc
-0.4
0.68 -0.6
-0.8
1 1.5 2 2.5 3 3.5 4 4.5 5.955 5.96 5.965 5.97 5.975 5.98 5.985 5.99 5.995
(a) PLO Start-up for an unbalanced set of voltages. (b) Steady state voltages for Fig. 2.14a.
Step in i∗dc (dotted) from 0.8 p.u. to 0.7 p.u., idc is
the blue line.
Figure 2.14: PLO tested in the presence of an unbalanced and polluted with harmonics
system of voltages.
Perfect tracking under unbalance and harmonics is observed. In this way, the problem
of harmonic instability in weak grids was overcome with the PLO.
Figs. 2.15 show the results of a simulation when the voltages system is very distorted
and there is a load transient: at 2.5 s a change from 1 p.u. to 1.1 p.u. has been programmed.
The PLO system retracks perfectly after the transient, so it could be said that the PLO
is robust in the presence of load transients.
Figs. 2.16 show the results of a simulation when the input frequency has a step change
and how the VCO frequency estimation (fˆ1 ) follows its reference f1 . Therefore, another
important feature of the PLO is its good frequency adaptation.
In sum, the PLO does not only fix the harmonic adaptation problem. The proposal
of using a VCO circuit inside the controller of a power converter also resulted in a very
effective tool to overcome other problems such as unbalance, frequency adaptation and
noise cancellation.
2.2 Phase-Locked Oscillator Control Systems 61
0.84
1.2
Vdc
0.82
1
Vdc
0.78
0.6
0.76
0.4
0.74
0.2
0.72
0
Vb
-0.2
Va
Vc
0.68
-0.4
0.66
-0.6
0.64
1 1.5 2 3.5 4 4.5 -0.8
5.955 5.96 5.965 5.97 5.975 5.98 5.985 5.99 5.995
(a) Ainsworth model Start-up and transient at (b) Steady state voltages for Fig. 2.15a.
2.5 s for a distorted set of voltages. The reference
current is 0.7 p.u., idc is the blue line.
0.85
50.7
50.6
50.4
0.75
50.3
50.2
50.1
2 4 6 8 12 14 16 18 2 4 6 8 12 14 16 18
(a) PLO current response. i∗dc (dotted) is 0.7 p.u., (b) Grid (f1 ) VS VCO (fˆ1 ) Frequencies for Fig.
idc is the blue line. 2.16a.
Figure 2.16: PLO tested under a sudden change in the input frequency at 10 s.
62 Chapter 2 State-of-the-Art in Grid Synchronization
The PLO system was also proposed with other schemes. Some of the most significant
ones are detailed below.
An alternative to the Ainsworth controller has been posed in [73]. In this scheme a
thyristor based controller is controlled in a closed loop with a VCO inside. The difference
of this scheme with respect to the Ainsworth one is the fact that the controlled variable
was the dc link voltage, so in practice, the second pole of the plant disappeared. This
allowed to Skjellnes et al to develop a closed loop with a bandwidth of ≈ 100 Hz, so
the transient response is highly enhanced with respect to the Ainsworth PLO. The main
limitation of this scheme is due to the fact that most of the practical applications require
a current control loop.
The PLO scheme has been adapted to the speed control of dc motors [63, 74, 75]. A
speed encoder and a phase comparator circuit are implemented in order to obtain the error
signal which controls the VCO frequency and, hence, the firing of the thyristor converter.
Based on this scheme, a frequency adaptive system with an acceptable transient re-
sponse (around one cycle of ω1n ) is achieved in [74].
As shown in the previous section, the Ainsworth proposal of using a VCO inside the
contro loop of a power converter provides harmonics/unbalance rejection and frequency
adaptation. However, the PLO system is very difficult to tune, and extra controllers
monitoring correct operation are needed [1].
An alternative use of the VCO is in phase locked loops (PLLs) tracking the funda-
mental phase-angle, as proposed in [76, 77]. PLLs had been used in other fields, specially
communications, since the 40’s [78, 79]. The works of [76, 77] extended the applicability
of PLLs to the control of power electronic converters.
The main novelty of the PLL proposal is the fact that the VCO is not a part of the
main control algorithm; the VCO is employed inside a measurement circuit (estimation).
2.3 Phase Locked Loops 63
vd
ac
dc Motor
ac Voltage Sensor
θˆ1
ω̂1
va PLL Comparator PWM
α ref
Circuit
Main
vd* Control
Controller Circuit
Fig. 2.17 shows the scheme proposed in [76] for the control of a thyristor controlled
rectifier in a single-phase motor drive application.
Even though the application is simpler than the HVDC rectifier of [1], it is clear that
the use of the PLL as a measurement circuit “liberates” the main controller of two poles
at the origin, which tend to make the system unstable.
The schemes of [76, 77] are very simple because the main control reference (vdc
∗
) is set
open loop (Fig. 2.17). However, as shown below, the kind of PLLs employed in [76, 77]
has more limitations considering power quality phenomena than PLO systems. Even so,
it is clear that the proposal of using PLLs inside the controllers is, without any doubt, a
milestone in the field of synchronization and power electronics control in general.
Fig. 2.18a shows a simplified PLL scheme. A PLL is a non-linear circuit which
synchronizes its output signal (vo ) with a reference or input signal (vi ) in frequency as
well as in phase.
The
Rπ
fundamental frequency and phase-angle of vi are ω1 and θ1 ; they are related by
θ1 = −π ω1 t + ϕ1 where ϕ1 is an offset dc constant. In the same way, the output signal
vo parameters are the estimated values of vi : ω̂1 , θ̂1 and ϕ̂1 . In steady-state it is expected
that estimated and real values are the same.
The PLL scheme is composed by the three basic functional blocks: the phase detector
(PD), the loop filter (LF) and the voltage controlled oscillator (VCO). The role of each
block could be summarized as follows:
• The PD is a circuit for which the average value of its output, averaged each cycle
64 Chapter 2 State-of-the-Art in Grid Synchronization
ω +θ
of the fundamental component of the input, is zero only when the input signals are
in-phase, that is, they are synchronized in phase and frequency.
• The VCO generates a signal of frequency ω̂1 from its central frequency, which, in
grid applications, should be adapted to ω1n and v̄c . The estimated frequency is
ω̂1 = ω1n + Kvco · v̄c , where Kvco is the VCO constant. Later, in digital PLLs, the
term Digitally Controlled Oscillator (DCO) is employed instead of VCO (integrated
circuit).
PLLs should be linearized in order to study its dynamics and tuning the LF. This
process is done assuming that the PLL is near locked state, that is, ω1 = ω̂1 and θi ≈ θ̂1
[78, 79]. Under such a situation, the equivalent system is the linear PLL (LPLL) of Fig.
2.18b.
The LPLL is a typical closed loop servo system. The instantaneous phase-angle error
at the fundamental component is θ1e = θ1 − θ̂1 . The LF path provides a frequency
correction around the nominal (central) frequency (∆ω̂1 ). When designing a PLL, its
most important features are:
1. Stability: the LPLL model should have high enough stability margins in order to
assure the stability of the PLL.
2. The “type” of the PLL: it is set by the number of origin poles of the equivalent
LPLL. A type 2 PLL (two origin poles) is necessary to assure θ̄1e = 0 when frequency
deviations are considered [78, 79].
• the transients response. The higher the bandwidth, the faster the PLL retracks
the phase-angle after a transient.
2.3 Phase Locked Loops 65
• the harmonic/noise filtering. The presence of noise and harmonics in the inputs
affects the PLL measurements. The term “phase jittering” is employed by
Best and Gardner to refer to the effect of noise in the phase estimation: phase
jittering (θ1ej ) is the error in the value of θ1e during zero crosses due to noise 4 .
2 2
In a general way, the average value of θ1ej (θ̄1ej ) is inversely proportional to
the PLL bandwidth [78, 79].
As said, the schemes implemented in [76, 77] are pioneer in power electronics, and
gave rise to much more development in the PLL technique during the end of 70’s and
early 80’s [80, 81].
PLLs proposed in [76, 77, 81] are Charge-Pump PLLs (CP-PLLs) [79, 82]. CP-PLLs
have a sequential-logic PD working together with a charge pump. The purpose of the
charge pump is to convert the logic states of the PD into analog signals suitable for
controlling the VCO. The main advantage of the charge pump is the chance of using
analog filters.
Fig. 2.19 shows the PSPICE model of a simple CP-PLL using an EXOR gate as PD.
The main characteristic of the CP-PLL using an EXOR gate is that, in tracking state,
the output leads the input signal 90 deg (cosine-wave).
• A comparator with zero is placed in order to generate a digital signal for which the
logic value changes occur synchronized with the ac grid zero crosses.
• The input and feedback signals from the VCO are the inputs of an EXOR gate.
The output of the EXOR gate controls a Charge Pump. The output of the EXOR-
Charge Pump system is an analog wave (vcp ) for which the average value, averaged
each cycle of the fundamental, depends on the relative phase between the two digital
66 Chapter 2 State-of-the-Art in Grid Synchronization
Input 2
1 (Feedback)
(AC Comp.)
Input 1
Input 1
AC Comp
AC Comp
Input 2 Input 2
Feedback Feedback
EXOR inputs
EXOR inputs
0.01 0.015 0.02 0.025 0.03 0.035 0.04 0.045 0.05 0.01 0.015 0.02 0.025 0.03 0.035 0.04 0.045 0.05
Time (s) Time (s)
Averaged
Averaged
Instantaneous
Instantaneous
0.01 0.015 0.02 0.025 0.03 0.035 0.04 0.045 0.05 0.01 0.015 0.02 0.025 0.03 0.035 0.04 0.045 0.05
Time (s) Time (s)
′
(a) Key diagrams for θ1e = π/2 rad (θ1e = 0 rad). (b) Key diagrams for θ1e = π/4 rad
′
(θ1e = −pi/4 rad).
Figure 2.20: Key diagrams for the EXOR-Charge Pump Phase Detector
2vcpmax ′ ′
v̄cp = · θ1e = Kd · θ1e . (2.16)
π
Fig. 2.20 shows the outputs of the EXOR-Charge-Pump PD.
• Considering v̄cp ≈ vco , from eq. (2.16) a negative θ1e
′
results in a negative vco , so the
ˆ
VCO frequency (f1 ) decreases. As the feedback signal has a lower frequency than
the input one, θ1e
′
tends to decrease, and therefore, the system tends to retrack the
phase. For positive θ1e′
the behavior is opposite.
• The role of the LF is to cancel the ripple in the output signal of the PD. As shown
in Fig. 2.20, the output of the PD has a fundamental component (v̄cp ) but also
harmonics, which affect to the VCO dynamics. For this reason, the LF should be a
low pass filter (LPF). In the model a first order LPF with cut-off frequency equal
to 100 rad/s has been implemented.
Fig. 2.21 shows time domain simulation results for the CP-PLL of Fig. 2.19. The
values of table 2.3 were employed. The system tracks the input phase and frequency in
around 3 cycles of the fundamental (f1n = 50 Hz).
The PD detector of this simulation is of EXOR type. However, the so called phase-
frequency detectors (PFDs) providing a feedback signal in-phase with the input (no 90 deg
2.3 Phase Locked Loops 67
25
20
15
10
AC input (V)
5
0
-5
-10
-15
-20
-25
0 0.05 0.1 0.15
Time (s)
Input 2 (VCO)
Input 2 (VCO)
1
0.8
EXOR inputs
0.6
0.4
0.2
0
0 Input 1 (AC) 0.05 0.1 Input 1 (AC) 0.15
Time (s)
VCO input, averaged value (Averaged each 20.4 ms)
5
VCO input
Voltage (V)
0 -0.1V
-5
0 0.05 0.1 0.15
VCO input Time (s)
Charge-Pump output
Figure 2.21: Time domain simulation results from the CP-PLL model at f = 49 Hz.
68 Chapter 2 State-of-the-Art in Grid Synchronization
Table 2.3
Controller Values.
Kd 3.18 rad/V
R 100 Ω
C 10 µF
Kvco 10 V/Hz
shift) have been the most widely employed in power converters [75].
On the other hand, even though some current works implement CP-PLL [83], the use
of these kind of solutions are being abandoned by digital implementations. The limitations
of CP-PLL are:
• Most of the classical VCOs such as the ICs 8038, 4044, 4046, and Siemens TCA
780-785, etc are becoming “obsolete components” [84]. Digital implementation is
definitively a current trend.
• The PD is based on zero-cross detection and therefore, could introduce phase error.
• In three-phase systems, as they work per phase, they cannot detect the fundamental
positive-sequence.
Fig. 2.22 shows the Synchronous Reference Frame PLL (SRF-PLL or dq-PLL). The
main feature of the SRF-PLL is that it estimates the phase-angle of the fundamental
+ +
positive-sequence (vabc 1
): therefore, the estimated phase-angle (θ̂1 ) corresponds with va1
+ +
phase-angle. If vabc waves are considered sine-waves, P1 of (1.40) is implemented, but
most of the authors usually present the SRF-PLL with the Park transformation obtained
+
as in (1.44), which implies that vabc components are considered cosine-waves. Anyway,
both approaches are totally equivalent.
SRF-PLLs are very suitable to work together with other SRF controllers: the phase-
+
angle of va1 sets the origin of the positive-sequence SRF, so that a SRF-PLL assures an
accurate power flow control. This fact was crucial in the success of the SRF-PLL, since
SRF-based current controllers have been employed in all kind of high performance power
converters applications, such as:
2.3 Phase Locked Loops 69
vd+1 + f (hω1 )
PD
va
vq+1 + f (hω1 )
P1+ ∆ω̂1
vb
vc LOOP
FILTER
+ + ω1n
−
DCO
The field of application of the SRF-PLL is very wide and, hence, its optimization has
been approached in several works [22, 28, 46, 94, 98–114]. The feasibility of powerful
digital devices and novel implementation techniques have led to more and more enhanced
implementations.
+
Considering vabc a set of phase to neutral “sine-waves”, the Park transformation (2.17)
+
acts as phase detector and the quadrature component (vq1 ) as phase error signal (θ1e ), so
+
that vq1 ≈ θ1e .
va
vd1+
= P+
1 ·
v , (2.17)
vq1+ b
| {z } vc
v+
dq
| {z }
vabc
where
2 sin(θ̂1 ) sin(θ̂1 − 2π ) sin(θ̂1 + 2π )
P+
1 = 3 3 . (2.18)
3 cos(θ̂1 ) cos(θ̂1 − 2π ) cos(θ̂1 + 2π )
3 3
70 Chapter 2 State-of-the-Art in Grid Synchronization
For the SRF-PLL linearization, the system is considered around the tracking point,
that is, ω1 = ω̂1 and θ1 ≈ θ̂1 , and also balanced inputs [28]. Under such a situation
+
vd1+ va1max cos(θ1 − θ̂1 ) ≈ va1 max
= +
(2.19)
vq1+ va1max sin(θi − θ̂1 ) ≈ va1 max
· (θi − θ̂1 ) = va1max · θ1e
| {z }
v+
dq1
+ + + +
where va1 max
(= vb1 max
= vc1 max
) should be rearranged so that va1 max
= 1 p.u.. It is
+
expected that v̄q1+ , which represents θ̄1e , to be zero in steady-state and, therefore, v̄d1 =
+
va1max . If amplitude measurement is not employed, only the q component of the P+ 1 is
generated (less needed resources).
+
It should be noticed that, the zero-sequence of vabc is eliminated in the PD. In fact,
several three-phase and three-wire systems could not have a physical neutral connection.
This is not a problem, but an advantage: phase to phase voltages can be employed in
order to reduce the number of voltage sensors (from 3 to 2) and components of P+1 matrix.
Eq. (2.17) can be rewritten as
va − vc
vd1+
= P+
1 · vb − vc
, (2.20)
vq1+
| {z } vc − vc = 0
v+
dq
| {z }
Line to line voltages
being the discrete implementation optimized accordingly.
From PLL theory, the level of distortion in the input signal should be taken into
account to tune PLLs, which is approached in detail for the SRF-PLL in the next chapter.
However, it should be highlighted here that a significant bandwidth reduction may lead
to a very slow transient response.
In order to improve the whole dynamics of the SRF-PLL some authors have proposed
the use of “pre-filters”, which act in a rotating reference frame (vabc or vαβ ). In this
manner, the input of the SRF-PLL is cleaner and therefore it can be tuned with a higher
bandwidth. Some interesting proposals are summarized below:
2.3 Phase Locked Loops 71
vd+1 + f (hω1 )
PD
va va+1 + f (hω1 )
S+ vb+1 + f (hω1 )
P1+ vq+1 + f (hω1 )
∆ω̂1
vb
vc v + f (hω1 )
+
c1
LOOP + + ω1n
FILTER
DCO −π
+
va1 1 a a2 va1
+
1
2
vb1 = a 1 a · v , (2.21)
b1
3
+
vc1 a a2 1 vc1
| {z }
S+
√ 2π
3
where a = −1
2
+j 2
or a = ej 3 .
The imaginary term j corresponds with a delay of 90 deg in a real signal, so digital
implementation of (2.21) is possible by means of all-pass filters delaying 90 deg the com-
ponents rotating at ω1 (phase at f1 ). Another important feature of all-pass filters is the
unitary gain for all frequencies.
Fig. 2.24 shows the Matlab/Simulink model of a sequence detector using an all-pass
filter (A(z)) of the form 5 :
−0.967z + 1
A(z) = , (2.22)
z − 0.967
in the Z-domain, implemented at fs = 10 kHz. The frequency and transient response of
A(z) are also shown. A phase of exactly 90 deg at ω1n is achieved.
Fig. 2.25 shows simulation results obtained from the model of Fig. 2.24: the input
signal is unbalanced but the output has only the (estimated) positive-sequence.
This technique is also suitable when there are harmonics in the inputs. As shown
below, some harmonic sequences are canceled with this implementation. However, the
5
It seems that there is not any specific detail of the original A(z) employed in [22].
72 Chapter 2 State-of-the-Art in Grid Synchronization
1/3*(-0.5*u(1)-0.5*sqrt(3)*u(2)-0.5*u(3)+0.5*sqrt(3)*u(4)+u(5))
-0.967 z+1
Vcp
z-0.967
Vc All pass
1
0
Amplitude (p.u.) 0.5
-5
0
-75
Phase (deg)
-80
-0.5
-85
-90
-95 -1
-100
-105 -1.5
40 42 44 46 48
50 52 54 56 58 60 0.018
0.02
0.022 0.024 0.026 0.028
0.03
0.032 0.034
0.8
0.6
0.4
0.2
-0.2
-0.4
-0.6
-0.8
-1
0.8
0.6
0.4
0.2
-0.2
-0.4
-0.6
-0.8
-1
Q+ B+ vq+1 + f (hω1 )
∆ω̂1
vb
ω1n
vβ+
C vβ
vc LOOP
+ +
FILTER
DCO −
The input signal vabc is expressed in the αβ frame by means of the Clarke Transform:
va
vα 2 1 −0.5 −0.5
= √ √ · vb . (2.23)
vβ 3 0 3
−2 3
2
| {z } | {z } vc
vαβ C | {z }
vabc
vα+ 1 1 −q vα
= · , (2.24)
vβ+ 2 q 1 vβ
| {z }
Q+
−π
where q = ej 2 .
+
Finally the angle transformation (B+ ) 6
is employed to get vdq
+
vd1 cos(θ̂1 ) sin(θ̂1 ) vα+
+
= · . (2.25)
vq1 − sin(θ̂1 ) cos(θ̂1 ) vβ+
| {z }
B+
6
B+ · C = P + .
74 Chapter 2 State-of-the-Art in Grid Synchronization
D(z)
Amplitude (p.u.)
D(z) A(z) 1
0
0.5
A(z)
-5 0
-84
-86
D(z) -0.5
-88
-90 A(z)
-92 -1
-94
-96 47 48 52 53
-1.5
0.018 0.022 0.026 0.028 0.032 0.034
49 50 51 0.02 0.024 0.03
Frequency (Hz) Time (s)
As shown in Fig. 2.26, the pre-filtering is at the real time generation of Q+ . A 90 deg
delay at f1n is applied to get the implementation of (2.24). This delay is obtained as a
FIR filter of the form
1
D(z) = (2.26)
zn
n being the order of the filter, which is so that D(z) has 90 deg of delay at f1n . D(z)
has unitary gain for all the frequencies and linear phase, so it can also be considered an
all-pass filter.
Fig. 2.27 shows a comparison between D(z) and A(z). It is expected a faster transient
response of DSC method, but a worse frequency adaptation.
N um(s)
G(s) = . (2.27)
s2 + kω ′ s + ω ′ 2
′ ′
From (2.27), G(s) has a maximum at ω (s2 + ω = 0). When k 6= 0 the GI is said
to be damped. The numerator of G(s) (N um(s)) is set so that the frequency response,
′
specially at ω , is the expected. Two GI filters were proposed in [123]: a direct GI (Hd (s))
2.3 Phase Locked Loops 75
kω1n s
Hd (s) = 2
, (2.28)
s2 + kω1n s + ω1n
with a 0 deg phase at f1n = 50 Hz, and
2
kω1n
Hq (s) = 2
, (2.29)
s2 + kω1n s + ω1n
with a 90 deg phase at f 1n = 50 Hz.
Hd (s) −Hq (s)
Q+ = . (2.30)
Hq (s) Hd (s)
Fig. 2.28a shows the frequency response of both filters. At f1 = 50 Hz both filters
have unitary gain; in terms of phase, Hd (s) = 0 deg and Hq (s) = 90 deg at 50 Hz; Hq (s)
has a better harmonic filtering response since it decays 40 dB/dec. The settling times (ts )
of both filters last around one fundamental cycle, what lags the transient considerably.
However, when digital delays of the form (2.26) are implemented, the equivalent phase
at harmonic frequencies is different. Indeed, these are “linear-phase” filters. Therefore, at
some harmonic frequencies and sequences the implementation of S+ results in harmonic
cancellation [124].
On the other hand, the real time generation of S+ with delayed signals is not unique.
Taking advantage of this feature, different combinations of the fundamental component
positive-sequence reconstruction can be linked in order to cancel some harmonic sequences
in the αβ frame [124].
10
Magnitude (dB)
0
-10
-20
-30
-40
-50
90
Phase (deg)
-90
-180
0 1 2 3
10 10 50 10 10
Frequency (Hz)
√
(a) Hd (s) and Hq (s) frequency response (k = 2).
500
300
200
100
-100
0 0.005 0.01 0.015 0.025 0.03
√
(b) Hd (s) and Hq (s) impulse (transient) response (k = 2).
The suitability of digital implementation allows to implement PDs with a higher per-
formance than the CP-PLLs ones, which are based on zero-cross detection. From PLL
theory [78, 79], the “linear multiplier” PD seems to be the most intuitive option [112, 125–
128]. Fig. 2.29 shows a simple single-phase PLL scheme based on linear multiplier as PD.
θ1e ω1n
PD
va ( p.u.)
X LOOP FILTER + +
cos(θˆ1 ) θˆ1
DCO
∫π ω̂1
π
cos(u)
−
v1max
v× cos(θ̂1 ) = · (sin(θ1 − θ̂1 ) + sin(θ1 + θ̂1 )) + f (2ωi , 4ωi , 6ωi , ...). (2.32)
| {z } 2
F eedback wave
Again, assuming that the PLL is locked in steady-state ω1 = ω̂1 and ϕ1 ≈ ϕ̂1 [78, 79],
v1max
v × cos(θ̂1 ) ≈ sin(ϕ1 − ϕ̂1 ) +
| 2 {z }
≈ϕ1 −ϕ̂1 =θ1e
v1 (2.33)
+ max sin(2ω1 t + 2ϕ1 ) + f (2ω1 , 4ω1 , 6ω1 , ...) .
| 2
| {z }
{z } Other harmonics
Generated second harmonic
Equation (2.33) shows that in steady-state the wave has a small dc signal with the
phase error information (θ1e ), a high second harmonic and other even harmonic compo-
nents. Assuming that all the harmonic components are canceled in the LF, the linearized
model is also valid for single-phase PLLs.
Other alternatives for single-phase PLL implementation have been proposed, such as:
• The implementation of a more complex PD such as the one of the “Enhanced PLL”
(EPLL) of [134], or the one based on the Coullon Oscillator [135]7 .
However, all single-phase PLLs for grid applications need of a drastic bandwidth reduc-
tion due to the PD non-linearities, more specifically the internal generation of harmonics
7
Even though the title could be misleading, [135] proposes a single-phase PLL
78 Chapter 2 State-of-the-Art in Grid Synchronization
+
As said, in a three-phase system the SRF-PLL estimates the phase-angle of va1 . On
the other hand, a single-phase PLL connected in the a-phase tracks the phase-angle of va1 .
Therefore, it seems that SRF-PLLs are more reliable when SRF controllers are employed.
That is, the use of single-phase PLLs in the presence of negative/zero sequences may
result in θ̄1e 6= 0 when tracking the positive-sequence, which may lead to a non efficient
energy transfer control. Some works have proposed the use of single-phase PLLs instead
of SRF-PLLs, since a SRF-PLL cannot detect individual phases [126, 135]. Even though
this assessment could be right, SRF controllers do not seem the most suitable to work
together with single-phase PLLs. This point should have been clarified by those authors.
It could be said that single-phase PLLs are more suitable for single-phase circuits and
three-phase circuits with per-phase controllers.
Other authors suggest a per-phase estimation of va1 , vb1 and vc1 phase-angles and
+
amplitudes in order to calculate the phase-angle of va1 [134]. Even though this is feasible,
there is no apparent reason to use individual single-phase PLLs, since the phase-detector
of the SRF-PLL (P+ +
1 ) totally decouples the positive-sequence: the dc value of vdq1 only
+
depends on vabc1 .
When considering amplitude variations such as voltage sags and swells, the drawback
of amplitude dependence in PLLs appears: from (2.19) and (2.33), it is clear that the
dynamics of digital PLLs depends on the amplitude of the tracked signal. In fact, the
amplitude is considered a proportional gain, which is normalized to 1 p.u. in order to
make easier the tuning process.
The amplitude dependence may lead to instability when the PLL phase margin is too
low. However, in practice, the most reported problem is due to the slow dynamics in the
presence of voltage sags [126, 127, 137].
This amplitude dependence can be avoided in part by compensating the PLL input
with an amplitude estimation. In single-phase PLLs, some works propose an extra loop
tracking the amplitude, which could be named amplitude locked loop (ALL) [126, 127,
136]. Similar approaches have been proposed for the SRF-PLL [111, 137].
Fig. 2.30 shows the combined ALL-PLL structure proposed in [127]. As a general
2.3 Phase Locked Loops 79
v v vˆ 1 max θˆ1
sin(ωˆ1t + ϕˆ1 )
Amplitude Phase
Locked v / vˆ 1 max Locked
loop. Loop.
sin(ωˆ1t + ϕˆ1 )
u2 +- PI
v 1
X
+
+
vˆ 1 max
1/u
v / vˆ 1 max
X
(b) ALL block.
rule, the ALL closed loop bandwidth should be lower than the PLL one, because of the
fact that the amplitude measurement also depends on the phase-angle.
Fig. 2.31 shows experimental results from the ALL-PLL structure. When there is a
voltage sag, the dynamics is faster and the amplitude can be estimated in real-time.
However, the range of improvement achieved with this technique could be considered
quite limited. In sum:
• In the single-phase case, the dependence between loops limits the response. The
study of the combined dynamics is very difficult [127].
• Also in the single-phase case, the bandwidth of the PLL should still consider the
PLL second harmonic [126, 127].
Digital PLLs are non-linear systems. Their trajectories can be depicted in the so-called
phase plane portraits [138, 139]. The frequency error ω1 − ω̂1 is represented in the Y axis
and the phase error θ1 − θ̂1 in the X axis. During normal operation, it is expected from a
80 Chapter 2 State-of-the-Art in Grid Synchronization
1.1
0.9
Amplitude (p.u.)
0.8
0.7
0.6
0.5
0.4
0.1 0.15 0.2 0.25 0.3 0.35
Time (s)
(a) ALL-PLL response to a 0.5 sag with (b) v̂1max obtained with the ALL (v gray
phase-angle jump of +45 deg. (v gray dashed, v̂1 dashed, v̂1 black solid).
black solid).
PLL to converge to the limit cycle (0, 0). Other solutions of the difference equation defined
by the PLL are expected to be unstable limit cycles. If not, a misleading estimation could
lead to malfunctions of the power electronic converter.
Different parameters of the PLL set its phase-plane portrait: the loop filter, the feed-
forward constant, the word length and other non-linear operations. It should be noticed
that the effect of these parameters cannot be assessed through the PLL linearized model.
Some digital implementations could lead to non desired stable limit cycles (misleading
steady-state estimations). In order to avoid this, the PLL region of operation can be
delimited explicitly.
1. A stable limit cycle appears at (2ω1 , −π) when the sign of ω̂1 is obviated. The
outcome of such a wrong estimation in a real time controller could be unpredictable.
2.3 Phase Locked Loops 81
1000 1000
π-0.1 π-0.1
π/2 π/2
π/4 π/4
0 0
π/2 π/2
-π+0.6 -π+0.6
-π+0.1 -π+0.1
-500 -500
-4 -3 -2 -1 1 2 3 4 -4 -3 -2 -1 1 2 3 4
(a) Phase-plane portrait of a SRF-PLL obviating (b) Phase-plane portrait of a SRF-PLL obviating
ω̂1 sign. Feedforward constant implemented (ω1n = ω̂1 sign. No feedforward constant (ω1n = 0).
2π · 50 rad/s).
1000 1000
π-0.1 π-0.1
π/2 π/2
π/4 π/4
0 0
π/2 π/2
-π+0.6 -π+0.6
-π+0.1 -π+0.1
-500 -500
-4 -3 -2 -1 1 2 3 4 -4 -3 -2 -1 1 2 3 4
(c) Phase-plane portrait of a SRF-PLL with ω̂1 sign (d) Phase-plane portrait of a SRF-PLL with ω̂1 sign
information (ω1n = 2π · 50 rad/s). information. The LF path is limited by the word
length (ω1n = 2π · 50 rad/s).
Figure 2.32: Phase-plane portraits of a SRF-PLL implementation. The curves are ob-
tained through different initial conditions (color legends indicate the initial θ̂1 ).
2. Thanks to the feedforward constant there are more trajectories converging to the
good limit cycle (0, 0), but the malfunction remains to be quite likely.
Fig. 2.32c shows the phase-plane portrait considering ω̂1 sign. In such a case, (2ω1 , −π)
is an unstable limit cycle and the SRF-PLL converges to the good estimation. Fig. 2.32d
shows the effect of the word length consideration. The trajectories in the phase-plane
portrait are limited in a smaller region.
It could be said that, in general, the region of operation of the PLL should be limited
in order to avoid non desired stable limit cycles and diverging trajectories. In practice,
the best manner to limit the region of operation is by placing the feedforward constant
and limiting the word length [112].
82 Chapter 2 State-of-the-Art in Grid Synchronization
The main drawback of PLLs is their transient response speed, specially in the presence
of distorted conditions [91, 134, 140]. On the other hand, digital implementation allows
to implement very high performance synchronization algorithms without a DCO inside a
closed-loop (a digital PLL).
Several algorithms have been proposed as an alternative to PLLs. The most significant
approaches are analyzed in this section. It should be highlighted that some of these
proposals are novel contributions of this thesis.
An open loop system, named low-pass transformation angle detector (LP-TAD), able
to synchronize with the positive-sequence of the fundamental vector of a three-phase
voltages/currents system was presented in [141]. This system was proposed as a digital
alternative to CP-PLLs for VSIs based on vector control, where the performance of zero-
cross detectors was very poor in the presence of input harmonics.
Fig. 2.33 shows the scheme of LP-TAD. A three-phase system of voltages system
(va , vb , vc ) is transformed to its equivalent Clarke variables vα and vβ :
va
vα 2 1 −0.5 −0.5
= √ √ · vb . (2.34)
vβ 3 0 3
−2 3
2
| {z } | {z } vc
vαβ C | {z }
~vabc
vα vˆα 1
x vˆα 1
norm
÷ θˆ1
va LPF
vˆα 1 + vˆβ 1
÷ vˆ
vb
C 2 2
β1
norm
(atan2)
vc vβ
LPF x
vˆβ 1
As said, LPFs are placed in order to filter higher harmonics; they should be tuned
taking into account the trade-off between filtering and transient response. Filters delay
ω
should be compensated at the outputs, which is not a trivial issue considering frequency
ω
∫
variations [105]. π
−π
Fig. 2.34 shows some significant simulation results of the LP-TAD. For these simula-
tions an order 1 Butterworth filter with cut-off frequency 15 Hz has been employed.
As shown, the LP-TAD has a good behavior under balanced conditions. However, it
has a very poor performance in the presence of negative-sequence in the inputs. This lack
of sequence decoupling ability is due to fact that the Clarke variables include information
of both positive and negative sequences [21]. The transient response depends only on the
employed LPFs.
The LP-TAD proves that open loop schemes and inverse trigonometric functions
(atan2) could be an alternative to PLLs if a good decoupling and filtering strategy is
carried out.
Also in [141], the dynamic response of the LP-TAD is enhanced by using recur-
sive/stochastic filters, giving rise to the Space Vector Filter-TAD (SVF-TAD) and En-
hanced Kalman Filter-TAD (EKF-TAD). Stochastic filtering for synchronization is ana-
lyzed below.
In [143, 144] a scheme to decouple the positive-sequence and then synchronize in the
αβ frame is shown. S+ is implemented using GIs to get 90 deg delay at nominal frequency.
Once decoupled the positive-sequence, open loop estimation is accurate. However, like in
the GI based PLLs, the transient response is not its strongest point.
84 Chapter 2 State-of-the-Art in Grid Synchronization
0.8
0.6
0.4
0.2
-0.2
-0.4
-0.6
-0.8
-1
0.47 0.48 0.49 0.51 0.52 0.53 0.54
0.8
norm
0.6
0.4
0.2
norm
-0.2
-0.4 norm
-0.6
-0.8
-1
0.47 0.48 0.49 0.51 0.52 0.53 0.54
-1
-2
-3
0.47 0.48 0.49 0.51 0.52 0.53 0.54
Figure 2.34: Significant simulation results for LP-TAD: fault and unbalance conditions.
2.4 Digital Alternatives to PLLs 85
Digital devices allow to handle electrical variables in SRFs. The main advantage of
the SRF approach is the suitability of controlling oscillating waves as dc signals. This is a
big advantage under the designer point of view, since low order infinite impulse response
(IIR) filters (Chebishew, Butterworth), moving average FIR filters (MAF), Proportional
Integrator (PI) controllers, lag/lead controllers, etc, perform much better with dc signals
[12, 44, 58, 145].
It is shown in this section how to implement SRF schemes in order to obtain high per-
formance synchronization algorithms. Firstly, algorithms to synchronize with the funda-
mental components are analyzed, both for single-phase and three-phase systems. Special
emphasis is put on the proposal of using MAFs together with SRF schemes, which is a
major contribution of this thesis [146–148]. Later, the issues of harmonics and negative-
sequences extraction based on SRFs are approached [13, 19, 148–151].
It is considered that the input wave (v) is a single-phase wave with multiple harmonics
It is important to note that (2.37) is valid for any ϕsrf ; Fig. 2.35 depicts v1 in the
SRF.
Fig. 2.36 shows a generic SRF scheme suitable for reconstruction of v1 . The goal of
the SRF algorithm is to measure v1d and v1q , which are dc values, in order to reconstruct
v1 and estimate its phase-angle (θ1 ). The frequency of the implemented SRF (ωsrf ) sets
86 Chapter 2 State-of-the-Art in Grid Synchronization
ω1
q
v q1
v1
vd1 d
ω1
∫
)
π
ω srf
vd 1
sin(u) X 2·H(z)LPF X
−π
the component to reconstruct; as said ωsrf = ω1 is set in order to track v1 . The input
wave (v) is multiplied by the d and q, yielding the following results:
1
v × sin(θsrf ) = [v1 cos(ϕ1 − ϕsrf ) + v1 cos(θsrf + θ1 ) + v3 cos(θ3 − θsrf ) +
2| {z } | {z }
vd1 rotating at 2ω1
(2.38)
v3 cos(θ3 − θsrf ) + v5 cos(θ5 − θsrf ) +...],
| {z }
rotating at 4ω1
1
v × cos(θsrf ) = [v1 sin(ϕ1 − ϕsrf ) + v1 sin(θsrf + θ1 ) + v3 sin(θ3 − θsrf ) +
2| {z } | {z }
vq1 rotating at 2ω1
(2.39)
v3 sin(θ3 − θsrf ) + v5 sin(θ5 − θsrf ) +...].
| {z }
rotating at 4ω1
From (2.38) and (2.39), it is expected that vd1 and vq1 , which are dc coefficients, can
2.4 Digital Alternatives to PLLs 87
be obtained with no ripple by means of LPFs. After the filtering stage, v1 is reconstructed
using (2.37). The estimated phase-angle of v1 (θ̂1 ) is:
where β is a relative phase-angle in the SRF, which is function of ϕsrf . v1max is estimated
by
q
2 2
v̂1max = v̂d1 + v̂q1 . (2.41)
From Fig. 2.36, it is clear that the dynamics of this system depends only on the LPFs.
The most important feature of a LPF is its amplitude versus frequency response. In
this particular case, unitary gain for low frequency values and high attenuation at higher
frequencies, specially for harmonics, are wanted. A filter with this frequency response
is relatively easy to design and implement in current digital devices. However, another
important feature of the LPF is its step response. The step response sets the system
response to a transient. In filtering there is a trade-off between the cancellation pattern
and the step-response [152].
MAFs have been implemented in electric power applications because of their excellent
behavior canceling harmonics [153–157]. In this work, it is shown how MAFs also offer a
very optimized performance for grid synchronization [146–148].
The difference equation which defines how the input signal (x) is related with the
output signal (y) of a FIR filter is:
n−1
X
y(k) = b0 · xk + b1 · xk−1 + .... + bn−1 · xk−n−1 = bi · xk−i , (2.42)
i=0
where k represents the current number of sample, bi are the filter coefficients and n − 1
is the filter order, so n must be an integer number. The window length, or time length,
(tw ) of a FIR filter is set by the number of samples, and the sampling time (1/fs ):
1
tw = n · . (2.43)
fs
An important feature of some FIR filters is the linear-phase [158]. A FIR filter is
88 Chapter 2 State-of-the-Art in Grid Synchronization
linear-phase if and only if its coefficients are symmetrical around the center coefficient; in
such a condition the delay through the filter (td ) is function of n:
n 1
td = · . (2.44)
2 fs
A particular case of linear-phase FIR filters are MAFs, which implement the average
function over the last n samples. The filter coefficients of the MAFs are found via the
following equation:
1
b(i)i=0,..,n−1 = . (2.45)
n
1
Y (z) = H1 (z) · X(z) = · X(z) + X(z)z −1 + .... + X(z)z −(n−1) =
n
1 n−1
X
! (2.46)
· z −i · X(z),
n i=0
H1 (z) being the Z domain transfer function relating the input and output of the filter.
From (2.46) and through the basic properties of the Z transform, a more suitable for
implementation form of H1 (z) is obtained:
1 1 − z −n
H1 (z) = . (2.47)
n 1 − z −1
sin( πffsn )
M ag [H1 (f )] = M ag , (2.48)
n · sin( πf
fs
)
where f is defined in the range [0, fs /2] [159].
derived:
fs
n= , (2.49)
2 · f1n
n being an integer number, since it sets the order of a digital filter; hence, fs should be
an integer multiple of 2 · f1n .
Fig. 2.37 shows the features of a MAF with fs = 10 kHz and n = 100 [146].Fig 2.37a
shows that the even harmonics of f1n are canceled and the gain is also very low around
these frequencies. The linear-phase feature can also be noticed. Figs. 2.37c and 2.37d
show the impulse and step responses set by (2.43), in this case 0.01 s.
Figs. 2.37e and 2.37f show a comparative among different kinds of discrete filters ex-
tracted from [148] 8 . As shown, the MAF has a very good cancellation pattern considering
grid applications (odd harmonics) and very good transient response.
Fig. 2.38 shows the very good performance of the SRF and MAF based algorithm,
which is named SRF-MAF1.
These simulations have been carried out considering ωsrf = ω1 = ω1n . In a practical
environment frequency deviations should be taken into account, as shown in section 2.5.
8
Butt(2,10 Hz) means: second order filter of type Butterworth, with cut-off frequency equal to 10 Hz.
90 Chapter 2 State-of-the-Art in Grid Synchronization
1.0002
1
Magnitude (abs)
Magnitude (abs)
0.8
1
0.9998
0.6
0.4 0.9996
0.2 0.9994
0 0.9992
0 0
Phase (deg)
Phase (deg)
-45 -1
-90 -2
-135 -3
-180 -4
0 50 100 150 200 250 300 350 400 450 500 550 0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2
Frequency (Hz) Frequency (Hz)
(a) Frequency response (in Hz). (b) Fig. 2.37a zoomed around dc (in Hz).
0.01
0.009
1
0.008
Amplitude
Amplitude
0.007 0.8
0.006
0.6
0.005
0.004
0.4
0.003
0.002
0.2
0.001
0 00
0 0.002 0.004 0.006 0.008
0.01 0.012
0.014 0.002 0.004 0.006 0.008 0.01 0.012 0.014
Time (sec) Time (sec)
(c) Impulse response (tw = 0.01 s). (d) Step response (tw = 0.01 s).
1 Butt(2,30Hz)
0.9
Amplitude (p.u.)
1 STEP
0.8
0.7
Butt(2,30Hz) 0.8
Butt(2,10Hz)
0.6
Gain
MAF
0.5 Butt(1,10Hz) 0.6
Butt(1,30Hz)
0.4
MAF 0.4
0.3
0.2
0.2
0.1
Butt(2,10Hz)
0 0
0 50 100 150 200 250 300 350 400 0.15 0.2 0.25 0.3 0.35 0.4
Frequency (Hz) Time (s)
(e) Comparative with other filters (Frequency Re- (f) Comparative with other filters (Step/transient
sponse.) response.)
Figure 2.37: Time and frequency responses of H(z)1 implemented at fs = 10 kHz and
n = 100.
2.4 Digital Alternatives to PLLs 91
1
0.8
0.6
0.4
1
0.2
0
-0.2
-0.4
-0.6
-0.8
-1
0 0.01
0.02 0.03 0.04 0.05
0.06
1 1max
0.8 d1
0.6
0.4
0.2
0
-0.2 q1
-0.4
-0.6
-0.8
-1
0 0.01
0.02 0.03 0.04 0.05 0.06
1 1
1
-1
-2
-3
0 0.01
0.02 0.03 0.04 0.05 0.06
Figure 2.38: Simulation results for SRF-MAF1 working open loop (ωsrf = ω1 = ω1n ).
92 Chapter 2 State-of-the-Art in Grid Synchronization
FIR generation 10
Taps 0
Magnitude (dB)
(off-line) X n=100
a N −1
-10
z −1
n=200
-20
Impulse
. -30
.
. . -40
v1
Σ
.
SRF-MAF1 . -50
X
180
a2 z −1
90
a1
Phase (deg)
X
a0 z −1 0
X
-90
v -180
0 100 150 200 250 300 350 400 450 500
HDCT(z) (on-line) 50
Frequency (Hz)
(a) Technique to obtain FIR taps from the impulse (b) SRF-MAF1 with n = 100 and n = 200 (=RDFT
response. of [158]); ωsrf = ω1n .
It should be commented that, even though the theoretical approach proposed by Mc-
Grath et al in [158], based on a Recursive Discrete Transfer Function (RDFT) and SRF-
MAF1 are different, their implemented schemes could be considered equivalent (Fig. 2.36
vs Fig. 2 of [158]). It can be checked analytically that, even though both schemes seem
to be non-linear, they could be also implemented as linear filters based on the Discrete
Cosine Transform (DCT). In this manner:
2 n−1
X
HDCT (z) = cos(ω1 · k · Ts )z −k . (2.50)
n k=0
HDCT (z) taps can be also obtained through the impulse response of SRF-MAF1 (or
RDFT-based) as depicted in Fig. 2.39a. Fig. 2.39b shows the frequency response of the
DCT filters obtained from SRF-MAF1 with n = 100 and n = 200, which is equivalent
to the RDFT based scheme of [158]. As expected, the double window length provides a
better filtering at the cost of doubling the transient time.
f (dc, ω2 , ω4 ,...)
va vˆd+1 vˆa+1
vˆq+1 P + (-1) vˆb+1
H(z)LPF
vb
vc P1+ H(z)LPF 1 vˆc+1
θ srf = ωsrf t + ϕ srf
∫
π
ω srf
−π
ω1
Open Loop Synchronous
Reference Frame Generation
+
Figure 2.40: Three-phase SRF synchronization algorithm; ωsrf = ω1 to decouple vabc 1
.
On the other hand, several works in other signal processing fields (image, speech,
communications,...) proved that the IIR equivalent implementation to a DCT are GIs,
as the ones of section 2.3.2.2 [167–170]. The main advantage of such IIR over FIR filters
appears mainly when considering very large scale integration (VLSI) implementations;
the transient response does not seem an important issue in those works. However, for
electric power applications, the performance of FIR based implementations results in a
much better filtering versus transient response trade-off, as shown in this dissertation.
2 sin(ω1 t + ϕsrf ) sin(ω1 t + ϕsrf − 2π ) sin(ω1 t + ϕsrf + 2π )
P+
1 = 3 3 (2.51)
3 cos(ω1 t + ϕsrf ) cos(ω1 t + ϕsrf − ) cos(ω1 t + ϕsrf + )
2π 2π
3 3
is implemented.
Fig. 2.40 shows a suitable scheme for three-phase systems. LPFs are employed to
+ +
cancel ripple from the dc coefficients vd1 and vq1 . The inverse of P+ is used to estimate
+
vabc . When using MAFs, the name SRF-MAF3 refers to the algorithm depicted in Fig.
2.40.
94 Chapter 2 State-of-the-Art in Grid Synchronization
+
The phase-angle and amplitude of vabc are estimated by
+ +
θ̂1 = (ω1n t + ϕsrf ) + atan2(v̂q1 , v̂d1 ), (2.52)
| {z } | {z }
θsrf β (relative angle)
and
q
+ +2 + 2
v̂a1 max
= v̂d1 + v̂q1 . (2.53)
The phase-angle estimation can also me made by using the angle transform B+(−1) to
+
get vα1 and vβ+ so the offset angle β is not needed for θ1 assessment [147].
+ +
θ̂1 = atan2(v̂α1 , v̂β1 ) ∈ [−π, π]. (2.54)
Fig. 2.41 shows simulation results of SRF-MAF3 and n = 100. The good performance,
both in steady and transient states is proved when ideal conditions are considered.
These approaches are specially suitable for power line conditioners. SRF-MAFs have
been successfully implemented as extraction algorithms in [148–151].
SRF-MAFs for selective harmonic extraction have been implemented in the APF con-
troller analyzed in chapter 5. Even though the main part of this chapter is devoted to the
PR current controller block, experimental results prove the excellent performance offered
by the SRF-MAF based extraction, both in steady-state and in the presence of input
transients.
2.4 Digital Alternatives to PLLs 95
1.5
Vc
Va Vb
1
Amplitude (p.u.)
0.5
-0.5
-1
-1.5
0 0.01 0.02 0.03
0.04 0.05 0.06 0.07 0.08
Time (s)
1 ^ +
Va1
0.8
^
V +
b1
0.6 ^ +
Vc1
Amplitude (p.u.)
0.4
0.2
0
-0.2
-0.4
-0.6
-0.8
-1
Time (s)
3
^
θ1
Phase-angle (rad)
-1
-2
-3
Time (s)
Figure 2.41: Simulation results for SRF-MAF3 working in open loop (ωsrf = ω1 = ω1n ).
96 Chapter 2 State-of-the-Art in Grid Synchronization
Digital devices allow to implement online recursive filters such as Kalman and adaptive
filters [171, 172]. The problem of synchronization with a polluted wave can be posed as
the linear-quadratic-Gaussian control problem [171] or as the Wiener problem of state
estimation [172]. Quite significant proposals in synchronization and harmonic extraction
based on stochastic filtering are present in technical literature [48, 140, 141, 173–181].
The most interesting feature of stochastic filtering based algorithms is their potential
fast transient response, even in the presence of some distorted conditions. For this reason,
they were mainly proposed to work in applications where the transient response is crucial
such as Uninterruptible Power Suppliers (UPSs), Dynamic Voltage Restorers (DVR),
traction systems, relaying protecting and harmonic identification [48, 140, 173–178, 182].
The Kalman filter is an efficient recursive filter that estimates the state of a dynamic
system from a series of noisy measurements. Kalman filters in grid applications have
been employed as extraction algorithm in [183] (off-line) and [145, 173, 181, 182, 184]
(real time). Relating to the scheme of Fig. 2.33, the EKF-TAD of [141] obtains v̂α and
v̂β in a recursive manner, rejecting noise and harmonics in vα and vβ .
It should be highlighted here that the EKF-TAD does not decouple negative-sequences,
while the Kalman based SRF schemes of [145] do it. In general, it cannot be asserted
that stochastic filtering schemes proposed novel architectures. It seems more suitable
to say that they provided a novel approach to digital filtering. In fact, MAFs 9 and
IIRs are also recursive filters. Therefore, it could be said that the manner in which
the synchronization or extraction problem is posed is much more important than the
stochastic filter coefficients.
M being
cos( ω̂fs1 ) sin( ω̂fs1 )
M= , (2.56)
− sin( ω̂fs1 ) cos( ω̂fs1 )
and
H = [0 1]. (2.58)
W (k) and V (k) are the stochastic processes of the system noise and measurement
noise, respectively. System covariance matrices for W (k) and V (k) are assumed as
E[W (k) W (k)T ] = q and E[W (k) W (k)T ] = r. The error covariance matrix (p) is
ˆ T ]. The second coefficient of
updated in each step; its initial value is p(0) = E[X̂(k) X(k)
x̂(k) is v1 estimation.
s = H · p(k) · HT + r. (2.60)
4. State estimation:
x̂(k + 1) = M · x̂(k) + K · I. (2.62)
0.8
0.8
1
0.6
0.6
0.4 0.4
0.2 0.2
-0.2
-0.2
-0.4
-0.4
-0.6
-0.6
-0.8
-0.8
-1
-1
0.01 0.02 0.03 0.04 0.06 0.07 0.08 0.09 0.01 0.02 0.03 0.04 0.06 0.07 0.08 0.09
2 2
1
1 1
-1 -1
-2 -2
-3 -3
0.01 0.02 0.03 0.04 0.06 0.07 0.08 0.09 0.01 0.02 0.03 0.04 0.06 0.07 0.08 0.09
(a) Test for an input with noise and 0.5 p.u. sag (b) Test for an input with harmonics.
with −45 deg phase jump.
The filtering pattern and dynamic response of the Kalman process mainly depend on
the initial values of the covariances. Of course, there is a trade-off between filtering and
transient response. The phase-angle of v1 for each k instant is obtained by
Figs. 2.42a and 2.42b show some significant results for the Kalman filtering synchro-
nization method obtained through the Matlab Script detailed in appendix A.5. These
simulations have been carried out considering ω̂1 = ω1 = ω1n , which is revised in section
2.5.
These results show that the Kalman filter approach is suitable for grid synchroniza-
tion, since it can offer an acceptable filtering versus transient response, specially when
comparing with single-phase PLLs.
The dynamics this Kalman based synchronization algorithm can be set in a different
manner by means of the intial parameters which set the system gain K (see appendix
A.5). Furthermore, by introducing higher harmonic components in the M matrix, the
filtering response can be enhanced at the cost of increasing computational burdens [183].
2.4 Digital Alternatives to PLLs 99
Firstly, the problem was posed for three-phase systems with negative-sequence [140,
176]: usually, after a voltage sag, there is a phase-jump and unbalance (negative-sequence)
in the grid voltage [32]; therefore, the energy transfer between the ac mains and a grid-
connected power converter would not be well controlled while phase-angle error is big, so
the retracking should be as fast as possible. On the other hand, unbalance generates a
second harmonic ripple in the positive SRF [26]. Song et al discarded the use of notch
filters because of their “sluggish” transient response; they proposed the WLSE algorithm
instead, which indeed offers a surprising almost instantaneous retracking even under un-
balanced conditions. Song et al proved the WLSE performance in a DVR. Of course, this
approach is suitable for any other approach where SRF controllers are employed.
It is also remarkable the single-phase version of the WLSE algorithm, which also
achieves almost instantaneous retracking [177, 178]. The single-phase WLSE algorithm
was proposed for a traction system in [178]: when a locomotive changes its voltage source,
the new phase-angle should be retracked as soon as possible in order to avoid malfunctions.
T
vαβ = C · vabc , (2.65)
where
2 1 − 12 − 21
C= √ √ . (2.66)
3 0 3
− 3
2 2
vαβ = [vα vβ ] has information of positive and negative sequences: when there is
unbalance (negative-sequence) vαmax 6= vβmax . In order to decouple negative from positive-
sequence of the fundamental component the angle transformations are employed: the
100 Chapter 2 State-of-the-Art in Grid Synchronization
+(−1) +(−1)
matrix H is composed of the link of B1 and B1 , which rotate at ω̂1 and have a
random offset phase. That is:
cos(ω̂1 · t(k)) sin(ω̂1 · t(k))
cos(ω̂1 · t(k)) − sin(ω̂1 · t(k))
H= − sin(ω̂1 · t(k)) cos(ω̂1 · t(k)) sin(ω̂1 · t(k)) cos(ω̂1 · t(k))
, (2.67)
| {z } | {z }
+(−1) −(−1)
B1 B1
so
+−T
vαβ = H · vdq1 , (2.68)
where
h i
+− + +
vdq1 = vd1 vq1 −
vd1 −
vq1 , (2.69)
+ + − −
vd1 , vq1 , vd1 and vq1 being the components of vabc1 in the positive and negative SRFs.
+−
The sequential recursive computation steps for the WLSE estimation of vdq1 , and
hence the phase-angle from vabc1 are detailed below. The dynamic response depends on
the forgetting factor λ and initial error covariance (p0 ):
3. Compute of r Matrix:
r = I + H · p · HT . (2.70)
4. Compute of K gain:
K = p(k) · H · r(−1) . (2.71)
+−
6. Update the estimation of vdq1 :
+− +− +−
v̂dq1 (k) = v̂dq1 (k − 1) + K · (vαβ − H · v̂dq1 (k − 1)). (2.73)
The phase-angle of the positive-sequence is obtained using vd+ , vq+ . Owing to the good
decoupling between positive and negative sequences there is not an undesired second
harmonic in estimated values.
2.4 Digital Alternatives to PLLs 101
Fig. 2.43 shows experimental results of the WLSE algorithm. The Matlab script of
appendix A.6 has been employed. It can be noticed that the transient response is very
good and it does not have ripple under unbalanced conditions. The transient response
could be even improved by the covariance reseting technique proposed in [140, 176].
Fig. 2.44 shows experimental results of adding extra sequences to H when dealing
with harmonics in the input: the simple implementation identifies the 5th harmonic as
noise and the λ should be reduced in order to filter it. The second option is to add positive
and negative sequences of the 5th harmonic to H: positive and negative sequences of 5th
harmonics are decoupled and the λ is kept. This second option could be more resource-
consuming, but in terms of performance seems to be an interesting one. Of course, in
very polluted practical systems more harmonic sequences in H could be implemented.
Until now, the effect of frequency deviations in stochastic filters has not been con-
sidered. However, stochastic filters are very sensitive to them [140, 181]. The frequency
adaptation of stochastic filters, specially the WLSE ones, is revised in the next section.
102 Chapter 2 State-of-the-Art in Grid Synchronization
1 1
Vb Va Vα
Vβ
Amplitude (p.u.)
Amplitude (p.u.)
0 0
Vc
-1 -1
0 0.01 0.02 0.03 0.04
0.05 0.06 0.07 0.08 0.09
0.1 0 0.01 0.02 0.03 0.04
0.05
0.06 0.07 0.08 0.09
0.1
Time (s) Time (s)
1 1.5
^
Vd1+
^
1 Vd1+
^
Amplitude (p.u.)
^ Vq1+
Vq1+
Amplitude (p.u.)
0
^ ^
Vq1-
Vd1-
0 ^
^ Vq1-
Vd1-
-0.2 0.01 0.02 0.03 0.04 0.06 0.07 0.08 0.09
-1 0.01 0.02 0.03 0.04 0.06 0.07 0.08 0.09
0 0.05 0.1 0 0.05 0.1
Time (s) Time (s)
3 3
Phase-angle (rad)
2
Phase-angle (rad)
1
^
θ1 ^
θ1
0 0
-1
-2
-3 -3
0 0.01 0.02 0.03 0.04
0.05 0.06 0.07 0.08 0.09
0.1 0 0.01 0.02 0.03 0.04
0.05 0.06 0.07 0.08 0.09
0.1
Time (s) Time (s)
1 1
Va Vα
Vb
Amplitude (p.u.)
Amplitude (p.u.)
Vβ
0 0
Vc
-1 -1
0 0.01 0.02 0.03 0.05
0.04 0.06 0.07 0.08 0.1
0.09
0 0.01 0.02 0.03 0.04
0.05 0.06 0.07 0.08 0.09
0.1
Time (s) Time (s)
1.5 2
1.5
^
Vd1+ ^
1 Vd1+
1
Amplitude (p.u.)
Amplitude (p.u.)
^
Vq1+ 0.5
0.5 ^
Vq1+
0
0 -0.5
-1
^ ^
Vq1-
-0.5
+(-1) -(-1) Vd1- +(-1) -(-1) +(-1) -(-1)
-1.5
1 1 1 1 5 5
-1 -2 0.01 0.02 0.03 0.04
0 0.01 0.02 0.03 0.04
0.05 0.06 0.07 0.08 0.09
0.1 0 0.05 0.06 0.07 0.08 0.09
0.1
Time (s) Time (s)
3 3
+(-1) -(-1) +(-1) -(-1) +(-1) -(-1)
2
1 1 1 1 5 5
2
Phase-angle (rad)
Phase-angle (rad)
1 1
^
θ1 ^
θ1
0 0
-1 -1
-2 -2
-3 -3
0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09
0.1 0 0.01 0.02 0.03 0.04
0.05 0.06 0.07 0.08 0.09
0.1
Time (s) Time (s)
The study of the linearized model of PLLs provides an accurate assessment of dynam-
ics. However, studies of the dynamics provided for other schemes are not as deep and
accurate as the provided by PLL theory.
Section 2.3 revised the criteria followed to assess the performance of PLLs. Following
the same criteria, any synchronization algorithm should have:
• The European Standard UNE-EN 50160, which sets f1n = 50 Hz, establishes limits
in maximum allowable frequency deviations. For interconnected systems the mean
value of f1 , estimated each 10s should not exceed ±1% ([49.5, 50.5] Hz) during the
99.5% of a week, but exceptional deviations between +4% and −6% are permited.
For isolated systems, normal operation of ±2% and exceptional deviations of ±15%
are specified [185].
• The IEC-61000 Standard sets the normal limit operation in ±2% for interconnected
system and extends these limits for isolated systems [144].
2.5 Frequency Adaptation of Synchronization Algorithms 105
• Regarding to distribution generation, and more specifically to the new grid codes
for wind turbines, normal operation of wind turbines allows frequency deviations of
around ±3 Hz [94].
• Digital PLLs using a lag/lead filter, as proposed in [46, 100, 105], would not have
θ̄1e = 0 (type I PLLs) [78, 79].
• SRF based schemes, including the stochastic filtering ones, do not have θ̄1e = 0
when ωsrf 6= ω1 because of the filtering delay. This phase error is:
• FIR filters such as numeric delays (e.g. D(z)) and MAFs do not achieve complete
harmonic cancellation, which causes phase jittering. This assertion could be ex-
tended to stochastic filters.
Of course, the issue of frequency adaptation has been posed by most of the authors
proposing novel synchronization algorithms. In sum:
• The use of PLLs to get frequency adaptation has been proposed to work with TAD
schemes [141] and SRF schemes [148, 186]. These hybrid schemes enhance their
whole performance using the frequency estimation from PLLs to adapt internal
signal and/or filter coefficients.
E.g. in [148] ωsrf is estimated by a single-phase PLL. Then, Fig. 2.36 is implemented
with ωsrf = h·ω̂1 for selective harmonic extraction of different harmonic components.
The implementation of an extra frequency loop, instead of a PLL, to estimate ω1
and update ωsrf has also been proposed [140, 143, 144, 151, 176, 177].
• The update of the sampling rate of the digital device was proposed in the RDFT
algorithm of [158] and also in the single-phase PLL of [128]. Zero steady-state phase
error and low jittering is achieved. However, technical problems could appear, since
the frequency response of discrete filters is changing continuously [158].
106 Chapter 2 State-of-the-Art in Grid Synchronization
• Svensson and Bongiorno have studied the frequency adaptation of DSC filters. The
choice of the device sampling rate is very dependant on the grid frequency [187]. In
[188] a very similar technique to the phase-offset correction of [158] is provided for
DSC implementation.
• Similarly to the case of DSC filters implementation, the choice of the sampling
frequency when implementing the pre-filters of [111] is not a trivial task. In a general
way, it could be concluded that the most difficult issue in the implementation of
pre-filters is to assure that the input wave is delayed an integer number of samples
[188].
The main reason of this slow response is the very big forgetting factor (λ = 0.9999)
employed in the implementation. From Figs. 2.43, a large λ provides very good filtering
but slow dynamics. Song et al ”fixed” this problem proposing the so-called “covariance
resetting technique”, which resets the covariances to initial values when a grid fault is
detected. In this manner, it is achieved an excellent transient and steady-state (filtering)
responses. However, this approach has a drawback considering frequency deviations:
even though the WLSE in the form proposed by Song et al has a fast transient response
(when fault condition is correctly detected), in steady-state the WLSE is tuned with slow
dynamics. Frequency deviations do not reset the covariances so the system dynamics
remains very slow.
Therefore, it could be said that the “covariance resetting” technique does not seem a
good choice when considering considerable frequency deviations.
2.5 Frequency Adaptation of Synchronization Algorithms 107
Table 2.4
Look-up table: control of n depending on ω̂1
This technique has been proposed in [148]. The frequency estimation from a PLL (ω̂1 )
is employed to adjust online the order of the MAFs. Fig. 2.45 shows how the frequency
response for different n. Table 2.4 show the rule of change of the n value: upper and
lower thresholds are different from the center value in order to provide some “hysteresis”
behavior, avoiding continuous changes due to ripple in ω̂1 .
108 Chapter 2 State-of-the-Art in Grid Synchronization
Constant2
1 K Ts
In z-1
50.8-50.7 Product Discrete-Time
Integrator
1
50.2-50.3 Out
2 4 -98
w Z
2*2
frequency Integer Delay
estimation 49.8-49.7 Add
Multiport
Switch -1
Z
49
49.3-49.2 Integer Delay1
Constant1
49.5 -1
Constant3 Z
Integer Delay2
50
Constant4
-1 Multiport
Z Switch1
50.5
Integer Delay3
Constant5
51 -1
Constant6 Z
Integer Delay4
1
n=98
0.9 n=99
0.05 n=100
0.8 n=101
0.04 (zoom) n=102
0.7
0.03
Gain
0.6
0.02
Gain
0.5
0.01
0.4 0
97 98 99 100 101 102 103
Frequency (Hz)
0.3
0.2
0.1
0
0 50 100 150 200 250 300
Frequency (Hz)
(b) Frequency response of MAFs as function of n (fs = 10 kHz).
Adaptive and stochastic filters have been also proposed for frequency estimation, e.g.
[189, 190]. This section analyzes the frequency adaptation technique proposed in [151] to
enhance the performance of SRF-MAFs.
Fig. 2.46 shows the frequency update algorithm proposed for SRF-MAF1. Fig. 2.46a
shows SRF-MAF1 with frequency adaptation. Frequency adaptive MAFs are employed.
The frequency of the SRF is updated online, so ωsrf = ω̂1 . This assures that vq1 and vd1
are dc components in steady-state, and therefore, there is not filtering delay, so θ̄1e = 0
is achieved. Fig. 2.46b represents the adatptive SRF-MAF1 (Fig. 2.46) depicted as an
adaptive filter.
Fig. 2.46c shows the flowchart for frequency estimation. This adaptive filter has been
designed taking into account the singular features of grid-applications. The main parts
of the proposed frequency estimation are detailed below:
• The error signal (e), or cost function, is e = atan2(vd1 , vq1 ) variation with respect
to the previous sample (numerical derivative), as in [140, 177].
• The abs(e) < ǫ condition is placed in order not to estimate the frequency during
transients. Hence, it is assured that the transient response is the same as in open
loop operation.
• The update of ω̂1 is proportional to a gain factor (λ) and e2 ; the e2 factor causes the
system to adapt rapidly when there is a high frequency shift and smoothly when
the shift is small.
• The value of e is saturated in a range [emin , emax ] avoiding very big changes between
consecutive ω̂1 .
• The value of ω̂1 is saturated in the range [ω̂1min , ω̂1max ], since practical frequency
deviations are within a reduced range.
• The optimum λ mainly depends on the input signal features, specially uncorrelated
white noise. The optimum λ depends on the main algorithm, i.e. SRF-MAF1
optimum λ is not optimum for SRF-MAF3.
The approach made for single-phase systems is suitable for the three-phase approach
+ +
using the fundamental positive-sequence set of values (v̂d1 ,v̂q1 ) to calculate e.
Table 2.5 shows the algorithm values used in the implementation. Different gains (λ)
have been used in order to show the noise dependence of this parameter.
Fig. 2.47 shows simulation results for the frequency adaptive SRF-MAF1 implementa-
tion using λ = 5 ∗ 104 s/rad. The test shows the response of the system during the initial
110 Chapter 2 State-of-the-Art in Grid Synchronization
∫
π vd 1
sin(u) X 2H(z)MAF
−π
f (dc, ω2 , ω4 ,...)
Frequency
d v
ω̂1
) Estimation
vq1 Algorithm
z-1 X
ωsrf (k ) = ω1 (k − 1)
cos(u) 2H(z)MAF
)
q
abs(e)<ε no
yes
ω̂1
Saturate ω1 estimation
Table 2.5
Adaptive algorithm values.
ǫ 10−3 rad/s
emin −0.7 ∗ 10−3 rad/s
emax 0.7 ∗ 10−3 rad/s
ω̂1max 2π51.5 rad/s
ω̂1min 2π48.5 rad/s
λ 1 ∗ 105 s/rad
λ′ 1 ∗ 104 s/rad
λ′′ 5 ∗ 104 s/rad
transient (start-up) of an input signal with ω1 = 49 Hz. Fig. 2.47a shows the fundamental
component reconstruction. As expected, the transient response lasts half a cycle of f1 .
Fig. 2.47b shows the phase error during and after the transient. The same result is shown
for the scheme without frequency adaptation in Fig. 2.47c. These results prove the im-
provement in steady-state, keeping the transient response features. Fig. 2.47d shows the
frequency adaptation; as said, during the initial transient ω̂1 is not updated (abs(e) > ǫ
condition); the update is made only in steady-state.
Regarding to SRF-MAFs, due to selectivity of MAFs, they cancel well harmonics but
not specially well other components. The effect of uncorrelated white noise is studied
below.
The optimum value of λ, under different noisy conditions, is studied for the SRF-
MAF3. This tests show the speed of the algorithm to adapting itself to the input frequency
during the start-up transient. Fig. 2.48a shows a set distorted (unbalance and harmonics)
input waves. The input frequency is 50.8 Hz. Fig. 2.48b shows how the system with higher
λ (λ = 1 ∗ 105 s/rad) is adapted faster and with good accuracy. Fig. 2.48c shows the same
results when white noise of BW 10 kHz and PSD of 4 × 10−8 p.u. is added to Fig. 2.48a
waves. In this case ten times lower λ (λ = 1 ∗ 104 s/rad) is more suitable, since it has a
much lower level of frequency jittering. It is clear the influence of noise in the election of
the λ value, so the variables acquisition is key.
112 Chapter 2 State-of-the-Art in Grid Synchronization
1 0
0.8 -10
0.6 ZOOM
-20
0.4
(a) Input wave and reconstructed (f1 = 51 Hz). (b) Phase-error with frequency adaptation.
51.2
0
-10 51
-20 ZOOM
System Frequency (Hz) 50.8
-30
Phase error (deg)
-40 50.6
-50
50.4
-60
NON ZERO AVERAGE STEADY-
-70 STATE PHASE ERROR 50.2
-80
50
-90
-100 49.8
0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8
Time (s) Time (s)
Figure 2.47: Adaptive SRF-MAF1 Vs open loop SRF-MAF1 during the start-up and
steady-state.
2.6 Conclusion
This chapter provides an in-depth review of the state-of-the art in grid synchronization.
It is clear that the simplest open loop systems based on zero-cross detection are not
suitable for distorted environments. The first milestone in grid synchronization was the
PLO proposed by Ainsworth. The PLO system is almost immune to harmonics and
frequency deviations in weak grids. The drawback of the PLO is its complex dynamics (α
dependence). Later, the use of CP-PLLs as measurement blocks was proposed in motor
drives applications, mainly to handle with big frequency deviations. The use of CP-PLLs
resulted in simpler controllers. However, this first CP-PLLs have important limitations
due to their PD are based on zero-cross detection. With the suitability of discrete devices,
digital PLLs were proposed. They perform much better than analog CP-PLLs. It should
be specially highlighted the SRF-PLL proposal. In fact, SRF-PLL implementation is being
investigated nowadays; several optimization techniques have been proposed since its first
appearances. Digital single-phase PLLs are also an interesting alternative to CP-PLL in
single-phase systems. On the other hand, by taking advantage of digital implementation
some interesting schemes have been proposed as alternative to PLLs, e.g. SRF-MAFs
and WLSE. However, PLLs provide a big advantage with respect to other systems: its
2.6 Conclusion 113
1.5 51.5
51
0.5
Amplitude (p.u.)
Frequency (Hz)
0 50.5
-0.5
50
-1
-1.5 49.5
0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2
Time (s) Time (s)
(a) Unbalanced and harmonic contaminated set of (b) Frequency estimation (green
input waves (blue is va , green is vb and red is vc ). with λ = 1 ∗ 104 s/rad, red with λ = 1 ∗ 105 s/rad).
51.5
51
Frequency (Hz)
50.5
50 Input Frequency
Freq. Meas with K2
Freq. Meas with K1
49.5
0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2
Time (s)
(c) Frequency estimation for a noisy input (green (d) dSpace implementation of Adaptive SRF-
with λ = 1 ∗ 104 s/rad, red with λ = 1 ∗ 105 s/rad) MAF3. Frequency estimation using λ = 1 ∗
104 s/rad.
very good frequency adaptation. Some frequency adaptation techniques for alternative
algorithms are reviewed.
114 Chapter 2 State-of-the-Art in Grid Synchronization
Chapter 3
Abstract —
This chapter presents a novel approach in the tuning of phase locked loops (PLLs) for power
electronic converters. PLLs are implemented inside a higher level controller to estimate the grid
voltage phase-angle and then control the energy transfer between the power converter and the ac
mains. The tuning of the PLL is not a trivial task, specially when considering power quality
phenomena.
In a general way, PLLs with a low bandwidth (low-gain PLLs) are required when handling
with distorted voltages. It is analytically demonstrated that low-gain PLLs have more trade-offs
than high-gain PLLs (e.g. PLLs for communications): it is not possible to optimize the settling
time for a phase-jump without getting slower the PLL response to frequency variations. Existing
tuning methods do not take into account low-gain features, which may result in non-optimum
designs.
From practical point of view, the proposed tuning procedure is very intuitive for controller
designers. Some significant design examples and experimental results, obtained from a discrete
implementation (dSpace platform), are provided in order to validate the theoretical approaches.
In the second part of the chapter, the DCO based on a RC oscillator is presented: the digi-
tal model of a sinusoidal oscillator is implemented, instead of explicit trigonometric functions.
This solution reduces the needed digital resources without reducing the performance, which could
be specially useful for DSP-based control of power converters. Experimental results are shown
proving the good performance of the proposal.
115
116 Chapter 3 Dynamics Study of Low-Gain PLLs
3.1 Introduction
As said in chapter 2, distortion in the ac mains should be taken into account when
tuning a PLL: there is a trade-off between filtering and transient response. With the
suitability of an ever increasing potential of discrete devices, several techniques to improve
this trade-off have been proposed, such as the placement of extra filter inside the loop
[106, 109, 112, 126] or before the phase detector (pre-filters) [111, 117, 123], and the
implementation of complex feedback structures [108, 126, 127]. However, it can be checked
that the implementation of filtering techniques always leads to a drastic reduction in the
whole bandwidth and therefore in the transient response speed. More specifically, when
optimization techniques affect to the closed-loop dynamics (filters inside and/or feedback),
the PLL should be tuned with a low bandwidth accordingly, giving rise to a low-gain PLL.
This chapter analyzes in depth the dynamics of low-gain PLLs through the frequency
response of their equivalent linearized model. It is analytically proved that low-gain PLLs
do not respond equally to phase or frequency changes. More specifically, it is not possible
to control the overshoot in the step response (phase-jump) without affecting very much
the dynamics when a frequency variation occurs. This fact is not taken into account in
previous works, which could easily result in a non-optimal tuning.
Taking into account ’low-gain’ features, a tuning method for grid-connected PLLs is
provided. This method is based on inspection of Bode and pole/zero diagrams, so it could
be said that it is very intuitive and useful for the controller designer. Some significant
design examples of SRF-PLL tuning are provided and tested in real time. These tests
contemplate both steady-state distortion and grid transients (faults). The dSpace DS1103
platform, using the discrete solver, and a programmable ac source have been employed
for the tests. Experimental results prove all the theoretical approaches.
In the second part of the chapter, the DCO based on a RC oscillator is presented. The
digital model of a sinusoidal oscillator is implemented, instead of explicit trigonometric
functions. This reduces the needed digital resources without reducing the performance,
which could be specially useful for DSP-based control of power converters.
Fig. 3.1 shows the PLL linear model, which is suitable for studying the dynamics of
PLL for which the linearization approach is accurate, such as SRF-PLLs and multiplied
based single-phase PLLs. The linear model open loop transfer function in the Laplace
3.2 Frequency Domain Based Tuning 117
PD
θ1e ω̂1
ω1t + θ1
+- L(s )
ωˆ1t + θˆ1
DCO
1
H (s ) s
1
H(s) = L(s) · . (3.1)
| {z } s
|{z}
Loop F ilter
DCO
The stability condition of the linear model through the open loop frequency response
is: |H(s)| < 1 when ∠H(s) ≥ −180 deg. Two quantities are directly related with this
stability criterion: the phase margin (PM) and the gain margin (GM). The crossover
frequency (ωc ) is referred to the frequency at which |H(s)| is 1 (0 dB). In this point the
PM is measured. PM is very useful to specify control system performance because it is
related with the damping ratio of the system (ζ) [191]:
PM
ζ∼
= f or P M < 70 deg . (3.2)
100
The information of PLL settling time (ts ) can be obtained from the H(s) frequency
response, since ωc is approximately equal to the closed loop bandwidth (ω3dB ) and natural
(ωn ) frequencies: ts to within 2% of the final value of a second order closed loop system
can be estimated with
4 4
ts = ≈ (3.3)
ζωn ζωc
[192]. Therefore, by inspection of the Bode diagram of H(s) the PLL transient response
can be estimated accurately. From (3.3) a high ωc results in a fast system. However, a
high ωc leads to a bad steady-state filtering: the choice of ωc is the main trade-off in the
tuning [28, 99]. ts can also be optimized increasing ζ [117].
118 Chapter 3 Dynamics Study of Low-Gain PLLs
The needed information for phase-angle tracking is the dc component after the phase
detector. Any other harmonic content in the error signal causes jittering in the estimation
and should be canceled [78]. For the single-phase PLL it is clear that the second harmonic
is an annoying problem even though the input signal is totally clean. The problem of the
second harmonic appears in the SRF-PLL when there is fundamental negative-sequence
in the set of input voltages [99]. The presence of higher harmonics in the inputs could
also result in a loss of performance [28, 99].
The very first action to cancel the presence of non dc components in the error signal was
the reduction of the PLL bandwidth (ωc ), so the closed loop has low gain at non desired
frequencies [28, 99]. The suitability of ever-increasing performance digital devices allows
the implementation of more complex discrete filters and techniques. Some significant
proposals are
• the implementation of different kind of filters inside the loop filter to cancel for
specific harmonics and unbalance effect [106, 109, 112, 126].
• the use of filters before the phase detector (pre-filters) to cancel for specific har-
monics and unbalance effect [111, 117, 123]. It should be noticed that the use of
pre-filters does not affect to PLL tuning, but reduces the whole bandwidth, since
they cause a lag when there is an input transient.
Fig. 3.2 explains by itself the pros and cons of introducing extra filters inside the
loop (L(s)). Indeed, the magnitude versus frequency response allows to cancel for specific
components. However, each filter introduces phase inside the loop, which results in a
reduction of stability margins. Therefore, in order to have an acceptable PM, when extra
filters are placed inside the loop, the bandwidth (ωc ) should be reduced. It could be said
that, in general, the better the filter cancellation pattern of a specific filter, the worse
its phase response. Moreover, it should be also noticed that the effect of adding extra
feedback signals results in a drastic bandwidth reduction [108].
3.2 Frequency Domain Based Tuning 119
Magnitude (abs)
0.8
0
90
Phase (deg)
-90
Typical power system electromagnetic phenomena related with transients in the input
of the PLL are voltage variation (sag and swells), phase-angle shifts or phase jumps and
frequency deviations [31].
The bandwidth is set by the gain of the loop filter, but also, by the amplitude of the
input signal. This is indeed a limitation of PLLs: the dynamics depends on the input
amplitude. A practical problem appears when a voltage sag is in the inputs. Usually,
voltage sags have a phase-jump associated [32]. Under such a situation, a low-gain PLL
is even slower than usual, and therefore the re-tracking time could be unacceptable. To
overcome this situation the PD input can be normalized using an amplitude estimation,
but it adds complexity to the PLL as well as to the dynamics assessment [111, 117, 126,
127].
Another limitation of low-gain PLLs, which is analytically proved below, is the fact
that the settling times in the presence of phase-jumps or frequency deviations could be
very different. More specifically, the step response of Fig. 3.1 model is not accurate for
frequency steps when H(s) overdamped. This introduces a new trade-off in the design of
the PLL, since, it is not possible to optimize ts for phase jumps without getting worse the
response to frequency deviations.
The error transfer function relating the phase error θe to the input phase θ1 is:
1
He (s) = . (3.4)
H(s) + 1
120 Chapter 3 Dynamics Study of Low-Gain PLLs
The Laplace transform of the phase error when a phase step or phase jump (∆θ) is
applied at time t = 0 is [78]:
∆θ
Θ∆θ
e (s) = He (s) · . (3.5)
s
Through the final value theorem, a PLL has zero average steady state phase error
after a phase jump if:
In the same way, the Laplace transform of the phase error when a frequency step (∆ω)
is applied at time t = 0 is:
∆ω
Θ∆ω
e (s) = He (s) · . (3.7)
s2
and
lim s · Θ∆ω
θe∆ω (∞) = s→∞ e (s) = 0 (3.8)
assures zero steady-state phase error after a frequency step.
The condition imposed by (3.8) requires of two origin poles in H(s) giving rise to a
type 2 PLL [79]. Applied to the PLLs of Fig. 2.18 if there is no origin poles in L(s)
this PLL does not have zero average steady-state phase error when the input signal is
not rotating at the frequency set by the feedforward constant of the VCO (ωvco ). Typical
digital PLLs implements PIs as loop filter resulting in type 2 PLL [99]. The use of a
lag-lead filter (lag compensator) instead of a PI filter, as proposed e.g. in [46], results in
type 1 PLL which does not assure tracking under frequency deviations.
Eqs. (3.6) and (3.8) do not provide information about how long the transients last.
In order to study the transient responses of the PLL, the inverse Laplace transform is
applied to eqs. (3.6) and (3.8). This analysis is performed assuming that L(s) is a PI
filter (type 2 PLL):
Ki
L(s) = Kp + , (3.9)
s
where Kp and Ki are the proportional and integral constants, respectively. This approach
is valid even though extra discrete filters are present inside the loop, since, from stability
conditions, their implementation require a ’low gain’ and therefore, the dominant roots
are the PI filter ones.
3.2 Frequency Domain Based Tuning 121
∆θs ∆θs
Θ∆θ
e (s) = = 2 , (3.10)
s2 + Kp s + Ki s + 2ζωn s + ωn2
and
∆ω ∆ω
Θ∆ω
e (s) = = 2 . (3.11)
s2 + K p s + Ki s + 2ζωn s + ωn2
The expression of θe∆θ (t) and θe∆ω (t) in the time domain (being t = 0 the moment of
the transient) depends on the roots of the denominator (p1 and p2 ):
q
p1,2 = −ωn (ζ ± ζ 2 − 1). (3.12)
∆θ q
θe∆θ (t) = √ · e−ζωn t
· sin(ω 2
n 1 − ζ t + φ) (3.13)
1 − ζ2
√
where φ = tan−1 ( 1 − ζ/ − ζ), and
∆ω q
θe∆ω (t) = √ · e−ζωn t
· sin(ωn 1 − ζ 2 t). (3.14)
ωn 1 − ζ 2
∆θ q √
−ζωn (1− ζ 2 −1)t
θe∆θ (t) = √ 2
[(1 − ζ − 1) · e −
2 ζ2 − 1 | {z }
slow pole
q √
ζ 2 −1)t
− (1 + ζ 2 − 1) · e−ζωn (1+ ]=
| {z } (3.15)
f ast pole
∆θ q q
√ 2 [(1 − ζ 2 − 1) · ep2 t − (1 + ζ 2 − 1) · ep1 t ]
2 ζ −1 | {z } | {z }
slow pole f ast pole
122 Chapter 3 Dynamics Study of Low-Gain PLLs
and
∆ω √
ζ 2 −1)t
θe∆ω (t) = √ 2 [e| −ζωn (1− }−
2ωn ζ − 1 {z
slow pole
√ (3.16)
−ζωn (1+ ζ 2 −1)t ∆ω
− e| {z }] = 2ω √ζ 2 − 1 [ |{z} ep1 t ]
ep2 t − |{z}
n
f ast pole slow pole f ast pole
From eqs. (3.13) and (3.14), it is clear that for the underdamped case the transient
response can be improved both increasing Ki (ωn ) or Kp (ζ). However, for overdamped
situation the situation is not clear at all. Eqs. (3.15) and (3.16) have two terms, one
decaying with ep1 t (fast pole) and another with ep2 t (slow pole).
In the case of θe∆θ (t) (phase-jump) the term associated with the slow pole has associated
a smaller coefficient. If the system is tuned so |p1| >> |p2| the transient response only
depends on the fast pole, so this transient response can be improved increasing ζ. A step
response with almost no overshoot can be achieved. It should be noticed that an increase
in ζ is also equivalent to an increasing in the PM. The problem of this approach arises
when θe∆ω (t) (frequency deviation) is considered (eq. (3.16)). The terms associated to the
slow pole has the same magnitude than the other one. If p2 is very close to the origin,
the transient defined by θe∆ω (t) lasts very much.
Fig. 3.3a shows a diagram of poles/zeros for underdamped and overdamped situations.
As larger is the distance of the dominant poles to the imaginary axis, the faster is the
transient response. Moreover, the higher the imaginary part of a pole, the higher the
overshoot. Therefore, for the case of Θ∆ e (s), it is clear that the transient response to a
θ
phase-jump is better for the overdamped case because the dominant pole is p1 , since p2
is almost canceled by the origin pole (Fig. 3.3b). However, in the case of Θ∆ e (s) the
ω
absence of zero in the overdamped tuning leads to a situation where p2 is the dominant
root, and therefore, the underdamped case has a better frequency step transient (Fig.
3.3c). Therefore, it seems that a tuning around critical damping (Kp2 ≈ 4Ki , so that
ζ ≈ 1) results in the better trade-off for transient responses, even though the overshoot
in θe∆θ (t) is not canceled.
Finally, it should be noticed that a similar approach can be made in the Z-domain
obtaining the equivalent results. A very overdamped system in the Z-domain has its
dominant poles very close to the unity circle [117]. As PLLs are implemented in a discrete
device, an analysis/tuning in the Z-domain seems to be more suitable. However, the
analysis/tuning could be made in the Laplace domain if the sampling frequency (fs ) is
high enough when compared with the dominant poles frequency; the poles/zeros place in
the Laplace domain is much more intuitive to predict the time constants of the system.
3.2 Frequency Domain Based Tuning 123
(a) Poles-zeros diagram for Θe (s)∆θ and Θe (s)∆ω . Blue poles refer to ζ < 1
and green poles to ζ > 1. The origin zero (red) is only present in Θe (s)∆θ .
First of all, it should be noticed that the Evans root-locus diagram does not provide an
accurate tuning of ’low-gain’ PLLs: a type II PLL has a zero close to the origin (dominant
root). Its effect is negligible when the dominant poles are high, but not when they are
also close to the origin. In practice, Evans root locus does not provide a reliable overshoot
information from its ζ for low-gain type II PLLs. It should be noticed that, in control
theory, the Evan root-locus is provided to analyze second order systems without zeros
[191].
In [28, 99, 117] analytical methods to predict the bandwidth and overshoot of PI
based type II PLLs are provided. It can be easily checked that low overshoot tuning
results in very overdamped systems which lead to big transient response in the presence of
frequency steps. Moreover, if extra filters (notch, MAF, DSC) are placed, those methods,
by themselves, are not accurate (P M and ωc change).
124 Chapter 3 Dynamics Study of Low-Gain PLLs
When comparing with previous tuning methods, two important new outcomes can be
extracted from this chapter:
• PM and ωc information from the Bode diagram provides a very reliable information
to tune a PLL when extra harmonics/noise filters are placed inside the loop (low-
gain PLLs).
• The PI filter coefficients tuning should not give rise to very overdamped system,
which damages the transient response in the presence of frequency deviations, which
had been previously reported as an optimum tuning [117].
Some significant examples are shown in order to provide a comparison among tuning
strategies. The sampling frequency (fs ) is 10 kHz and the nominal frequency 50 Hz.
Ki
L(s)HB−P LL = (Kp + ) (3.17)
| {z s }
P I f ilter
Table 3.1
Significant parameters of HB-PLL
From Fig. 3.4 and table 3.1, it is expected a PLL with a very fast transient response
both for phase jumps and frequency deviations. Some overshoot is expected. There is
not harmonic/unbalance cancellation.
3.2 Frequency Domain Based Tuning 125
80
60
40
20
-20
-120
-150
-210
2 3 4 5
10 10 10 10
Figure 3.4: Frequency response of H(z) for the HB-PLL (L(s)HB−P LL was discretized
using the ’zoh’ method).
A SRF-PLL for canceling the second harmonic generated by the negative sequence
using a notch filter is designed:
Ki
L(s)U N −P LL = (Kp + ) ·N (s) (3.18)
| {z s }
P I f ilter
Table 3.2
Significant parameters of UN-PLL
From Fig. 3.5 and table 3.2 it is expected a PLL with an acceptable transient response
both for phase and frequency jumps with some overshoot, since the system is near critical
damping (p1 ≈ p2 ). It has very good unbalance cancellation and an acceptable harmonic
filtering.
126 Chapter 3 Dynamics Study of Low-Gain PLLs
100
50
-50
-100
-150
0
-45
-90
-135
-180
-225
-1 0 1 2 3 4
10 10 10 10 10 10
Figure 3.5: Frequency response of H(z) for the UN-PLL (L(s)U N −P LL was discretized
using the ’zoh’ method).
Ki
L(s)M A−P LL = (Kp + ) ·M A(s) (3.19)
| {z s }
P I f ilter
where M A(s) is the transfer function of a moving average filter tuned to cancel even
harmonics; it is better expressed in the Z-domain (fs = 10 kHz):
1 1 − z −100
M A(z) = (3.20)
100 1 − z −1
Table 3.3
Significant parameters of MA-PLL
From Fig. 3.6 and table 3.3 it is expected a SRF-PLL with an excellent harmonic/unbalance
cancellation, an acceptable phase-jump transient response (decaying with ep1 t ) with no
overshoot (high PM), but with a bad frequency variation transient (decaying with ep2 t ).
3.2 Frequency Domain Based Tuning 127
-100
-200
-300
-90
-135
-225
-270
-315
0 1 2 3 4
10 10 10 10 10
Figure 3.6: Frequency response of H(z) for the MA-PLL (PI filter was discretized using
the ’zoh’ method).
The SRF-PLLs of section 3.2.5 have been implemented in a digital device (dSpace
DS1103) using the discrete solver at fs = 10 kHz. The execution times of all SRF-PLLs
were lower than 10 µs. The three-phase input voltages have been generated with a three-
phase programmable ac source (three Chroma 61501 modules). In order to obtain the test
signals the three-phase ac source has been used as an arbitrary power amplifier connected
to a three-phase arbitrary waveform generator based on a DSP card. The input signals
have been acquired through the dSpace I/O interface by means of LEM LV25-P voltage
transducers and adapted to p.u. units. Fig. 3.7 shows the key oscillograms, obtained by
three different tests.
Figs. 3.7a, 3.7b and 3.7c show experimental results when the SRF-PLLs were tested
using a clean signal (no harmonics/noise) having a phase-jump of +45 deg; the input
frequency was 49.5 Hz. Steady state and phase-jump transient responses are shown. From
these results it is clear that the HB-PLL is the best option when there is not distortion,
since it has a very fast re-tracking (see Ch2: vq ≈ phase-error) and good steady-state
phase-angle estimation (see Ch4). As expected from their bandwidth, the other two
systems are slower.
In the frequency step tests (Figs. 3.7d, 3.7e and 3.7f) sudden frequency changes in
the input waves (alternating between 49 Hz and 51 Hz) were programmed in order to
show the response of each system in the presence of frequency deviations. As expected,
the frequency step and phase jump transient times are almost equivalent for not very
overdamped systems (HB-PLL and UN-PLL). For MA-PLL (very overdamped PLL) the
optimization in the phase transient settling time (low overshoot) resulted in a very slow
response in the presence of frequency deviations (see Ch2: vq ≈ phase-error).
In the distorted signal test (Figs. 3.7g, 3.7h and 3.7i), the pre-programed input waves
128 Chapter 3 Dynamics Study of Low-Gain PLLs
(a) Clean signal Test (b) Clean signal Test (c) Clean signal Test
(HB-PLL). (UN-PLL). (MA-PLL).
(d) Frequency Step Test (e) Frequency Step Test (f) Frequency Step Test
(HB-PLL). (UN-PLL). (MA-PLL).
(g) Distorted signal Test (h) Distorted signal Test (i) Distorted signal Test
(HB-PLL). (UN-PLL). (MA-PLL).
Figure 3.7: Experimental results for different SRF-PLLs: Ch1 (black) is the Va input
in p.u./V, Ch4 is the instantaneous phase-angle measurement (100 mV/rad), Ch2 is the
error signal vq in p.u./V (1 p.u. = π/2 deg of phase error), Ch3 is ∆ωo (10 mV/(rad/s)).
3.3 RC Model of Digitally Controlled Oscillator 129
have unbalance (≈ 10% of negative sequence ) and high ammount of harmonics (10%
of 5th , 5% of 5th and 5% of 11th ); the input frequency was 50.5 Hz and a phase-jump
of +45 deg was pre-programmed. The HB-PLL responds very fast to the phase-jump
transient. However, it does not filter either harmonics or unbalance effect because its
high bandwidth, so that the quality of its phase-angle estimation is very poor due to the
jittering (see Ch4 of Fig. 3.7g). Excellent steady-state results are obtained with MA-PLL
thanks to the moving average filter, which cancels all the even harmonics caused by the
presence of odd harmonics and unbalance in the inputs (see Ch3 of Fig. 3.7i: ∆ωo ).
However, its phase-jump transient response is slow, since it has a low bandwidth. UN-
PLL has a very good unbalance cancelation and acceptable harmonic filtering (see Ch3
of Fig. 3.7h: ∆ωo ), and an average phase-jump transient response.
From these results, it could be stated that a previous knowledge of the grid level
distortion is very recommended when tuning a PLL. It should be noticed that, very
overdamped (e.g. MA-PLL) and very high bandwidth (e.g. HB-PLL) PLLs present some
important drawbacks when dealing with power quality phenomena, which may lead to
a poor energy exchange control (between the grid and the power electronic converter).
Therefore, an ‘average’ system (no overdamped with a medium bandwidth), such as UN-
PLL, could be a good choice for most of the applications.
This section provides a novel technique of trigonometric functions and SRF matrices
implementation, which has been presented in [112]. With regard to the PLL structure,
these blocks are part of a DCO.
This work proposes an efficient IIR based algorithm based on the model of a RC
electronic oscillator; its block diagram is depicted in Fig. 3.8a. Two unitary orthogonal
waves are obtained. This implementation reminds to GI based on two integrators [119],
but without input.
Fig.3.8b shows the closed loop poles of the digital oscillator for ω̂1 = ω1n ; of course, in
real time operation, the oscillation frequency ω̂1 is updated online. Following Barkhausen
criteria, this system oscillates at ω̂1 : from control theory, this system tends to instability
since its poles are on the imaginary axis; however, as the integrators are saturated, the
signal amplitude can be controlled [196]. Also from oscillators theory, the output of one
of the integrators must be non-zero in order to start the oscillation. e.g. sin(θ̂1 ) = 0,
cos(θ̂1 ) = 1 can be chosen to quickly achieve the oscillation steady-state.
130 Chapter 3 Dynamics Study of Low-Gain PLLs
cos(ωot + θ o )
ωo ∫
Pole-Zero Map
0.99 400
sin(ωot + θ o )
Pole : 0 + 314i
300
− 0.99
200
Imaginary Axis
∫
100
ωo
0.99
0
-
− 0.99
-100
ωo t + θ o
Reset
∫
-200
π
ωo
-300 Pole : 0 - 314i
−π
-400
-1 -0.5 0 0.5 1
Real Axis
(a) Block diagram of the digital oscillator. (b) Poles/Zeros map of the oscillator (in
rad/s, continuous model).
The estimated phase (θ̂1 ) is calculated through the numeric integration of ω̂1 between
[−π, π]. When sin(θ̂1 ) crosses zero in the falling edge θ̂1 is reset to −π. Another option is
to use the range [0, 2π] and reset on the rising edge.
As seen, this diagram is very low resource-consuming. A small drawback of the oscil-
lator is that the generated waves sin(θ̂n ) and cos(θ̂1 ) are not pure sinusoidal waveforms,
due to the non-linear behavior of the saturation in the integrators. However, the total
harmonic distortion (THD) of these waves is negligible (0.70% when implemented at a
sampling frequency (fs ) of 10 kHz).The limits of the integrator should be chosen accord-
ingly in order to assure that the amplitude of the fundamental component is 1. E.g. the
integrators are saturated at ±0.99, not at ±1.
As said, two orthogonal waves are the outputs of the oscillator. With regard to single-
phase the in-phase and feedback signals are directly obtained. With regard to SRF-PLLs,
the assessment of Park transformations is immediate by:
√
2π 3
sin (θ̂1 ± ) = −0.5 · sin (θ̂1 ) ∓ · cos(θ̂1 ). (3.21)
3 2
Fig. 3.9 shows the P1+ matrix calculation from the oscillator signals (Fig. 3.8a) and
(3.21) identities.
3.3 RC Model of Digitally Controlled Oscillator 131
2/3 sin(2π/3)
cos(θ^1)
-2/3
2/3 cos(2π/3)
2/3 sin(2π/3)
sin(θ^1)
-2/3
2/3 cos(2π/3)
Fig. A.7 of the Appendix shows a Matlab script which simulates the single-phase PLL
start-up tracking. A notch filter is placed to cancel the second harmonic. This script
also proves the simplicity and significance of the oscillator implementation: trigonometric
functions are not explicitly present. It is important to mention that the output of the
LF should be saturated (∆ωmax/min = ±128 rad/s). This is implicit in a DSP fixed point
implementation.
The single-phase PLL has been implemented in the Technosoft MSK2407 board con-
taining a TMS320LF2407 fixed point DSP of Texas Instruments; the word length of this
DSP is 16 bits. In the script of Fig. A.7 of appendix it is shown the representation for
each variable in Q format. It is important to comment that there is a trade-off in the
choice of the ’ylf’ pipeline format. A smaller pipeline (e.g. Q9) gives rise to a system
slower since it saturates easily. However, a bigger pipeline (e.g. Q7) would give rise to a
noticeable lose of performance due to the truncation after the LF multipliers. Q8 resulted
to be the optimum choice.
Fig. 3.11a shows the steady state phase measurement of the single-phase PLL when
a clean sinusoidal of 51 Hz is at the input. Fig. 3.11b shows the phase tracking when
the real grid signal is at the input. Fig. 3.11c shows the excellent transient response of
the PLL: after a strong fault such as a voltage sag from 1 p.u. to 0.5 p.u. and +45 deg
phase-jump the PLL re-tracks in less than a cycle. These results confirm the expected
132 Chapter 3 Dynamics Study of Low-Gain PLLs
-1
-2
Input signal
Mysin
-3 Phase-angle
0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1
Time (s)
3
Amplitude (p.u.), Phase-angle (rad/s)
-1
-2 Input signal
Mysin
-3 Phase-angle
0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1
Time (s)
Figure 3.10: Simulation results for single-phase PLL (ω1 = 2π50.3 rad/s).
3.3.1.3 SRF-PLL
The SRF-PLL have been implemented in the floating point PowerPC inside the dSpace
DS1103 prototyping platform. This platform contains a floating point micro PowerPC
and an I/O interface.
Fig. 3.11d shows the steady-state phase measurement for a highly unbalanced (both in
amplitude and phase) voltage system at the inputs of SRF-PLL. As expected, the second
harmonic is canceled. Fig. 3.11e shows the good tracking of the SRF-PLL when there is
superimposed white noise of 10 kHz BW and a power spectral density (PSD) of 10−6 p.u.
to the previous test wave. Fig. 3.11f shows the excellent performance of the SRF-PLL
tracking an unbalanced voltage system with notches.
3.3 RC Model of Digitally Controlled Oscillator 133
Zoom
(a) Phase measurement for sinusoidal input with (b) Phase measurement for real grid voltage.
input frequency of 51 Hz.
Trigger
(c) PLL response under a strong fault. (d) SRF-PLL steady state phase measurement
for a set of unbalanced voltages as input.
(fin = 50.5 Hz)
(e) SRF-PLL steady state phase measurement (f) SRF-PLL steady state phase measurement
of a highly noisy signal (fIN = 49.5 Hz). of a signal with deep notches (fIN = 50.8 Hz).
3.4 Conclusions
This chapter presents an in-depth study of the dynamics of digital PLLs for grid-
connected power electronic converters.
Section 3.2 reviews some PLL theory important concepts and proposes a tuning ap-
proach based on inspection of Bode and pole/zero diagrams. From a practical point of
view it could be said that the proposed tuning method is very intuitive. Moreover, two
new significant outcomes are contributed in this chapter:
1. PM and ωc information from the Bode diagram provides a very reliable information
to tune a PLL when extra harmonics/noise filters are placed inside the loop (low-gain
PLLs). This information is much more reliable that the obtained from analytical
methods having into account only the PI filter roots.
2. It is analytically proved that low-gain PLLs have a trade-off between the responses
to phase-jumps and frequency deviations. A very overdamped PLL has an opti-
mized phase-jump response since the overshoot is minimized, but it has a very slow
response in the presence of frequency deviations. Therefore, the PI filter coeffi-
cients should not give rise to a very overdamped system, which had been previously
reported as an optimum tuning.
Some significant design examples of SRF-PLL tuning are provided in order to check in
real time the theoretical approaches. Experimental results prove the accuracy and validity
of the analysis.
The second part of the chapter shows the good performance of the RC-oscillator based
DCO. The low ratio grid over sampling frequency allows to implement an RC-oscillator
algorithm to work as DCO. In this way, a simple and accurate method of trigonometric
functions implementation is achieved. This method is specially suitable for low-cost fixed
point DSPs. Experimental results prove that, in practice, the proposed DCO performs as
an ideal oscillator, both for single-phase and three-phase PLLs.
Chapter 4
Abstract —
Previous works establish that the fundamental positive-sequence vector of a set of utility volt-
age/current vectors can be decoupled using Park’s transformation and low pass filters. However,
the filtering process introduces delays that impair the system performance. More specifically,
when the input signal frequency is shifted above the nominal, a non zero average steady-state
phase error appears in the measurements (estimations).
To overcome such limitations, a suitable combination of predictive and moving average FIR
filters is proposed to achieve a robust synchronization system for all input frequencies inside
typical normal operation ranges. MAFs are linear phase FIR filters which have a constant time
delay at low frequencies. A characteristic which is exploited to good effect to design a predictive
FIR filter which compensates such time delays, enabling zero steady-state phase errors for shifted
input frequencies.
In summary, the main attributes of the new system are its good frequency adaptation, good
filtering/transient response trade-off, the fact that its dynamics is independent of the input vector
amplitude and no trade-off between frequency deviation and phase-jump transient responses.
Comprehensive experimental results validate the theoretical approach and the high perfor-
mance of the proposed synchronization algorithm.
135
136 Chapter 4 Predictive based SRF-MAF Synchronization Algorithms
Arguably, phase locked loops (PLLs) are the most widespread synchronization algo-
rithms employed in grid-connected converters, as shown in previous chapters.
PLLs have been employed successfully in systems where an accurate phase measure-
ment is required in high and medium voltage grid connected converters [64, 83, 197, 198],
and in systems with self adapting frequency variations characteristics [92, 145, 199–201].
However, the dynamics of PLLs presents some drawbacks, as analyzed in chapter 3: low-
gain features and input amplitude dependent dynamics.
In order to achieve frequency adaptation, predictive filters for compensating the delay
through the MAFs are proposed in this chapter: MAFs have linear-phase which implies
that the time of delay is constant and known for low frequencies [152]. The oscillation
frequency of Park variables is set by the input frequency deviation from the nominal. The
time of delay through the MAFs is always much smaller than the oscillation period of the
Park variables. Therefore, the trajectory in the time domain of the Park variables can be
approximated to a straight line, where only the time interval between the measured value
and the actual value are considered [202–208]. Using this approach, the transfer function
of a predictive filter which predicts the current value of Park variables is obtained.
In summary, the use of moving average and predictive filters enables a purely open loop
system with frequency adaptation, amplitude independent dynamics and good filtering
versus transient-response trade-off. The dynamics of this open loop system is mainly
stated by the frequency and transient responses at the filtering stage. Moreover, more
than one moving average filter can be used in order to improve the cancellation pattern,
4.1 Calculation of Predictive Filters 137
Two design examples are presented. Their high performance is shown in the experi-
mental results section. Simulation and real time implementation results are provided and
amply discussed.
As shown in section 2.5, the most problematic drawback of SRF-MAF3 and SRF-
MAF1 (Fig. 2.40 and 2.36) is that ω1 is unknown. Focusing in the design of SRF-MAF3,
+ +
when ω1 6= ω1n , vd1 and vq1 are low frequency components rotating at ωd = ω1 − ω̂1n . In
+ +
such a situation vd1 and vq1 are obtained with a time delay (td ) set by the phase versus
frequency response of the low pass filter employed. If it is not compensated, this time
delay would cause a constant average steady-state phase error (θ1e ) proportional to td and
ωd :
1 1 − z −N1
H1 (z) = . (4.2)
N1 1 − z −1
A predictive filter compensating for MAF lag can be calculated as follows. From (2.44)
td is calculated off-line. While td << ω2πd , it is correct to say that in any td interval both
+ +
vd1 and vq1 trajectories in the time domain fit very well to a straight line. Therefore, it is
possible to predict future samples from current samples into this trajectory [202–208].
y2 (k + 1) being the current sample of a straight line trajectory, it can be expressed as:
1
y2 (k + 1) = y2 (k) + m · (4.4)
fs
1
In this chapter, it is used N1 instead of n.
138 Chapter 4 Predictive based SRF-MAF Synchronization Algorithms
1
y2 (k + 2) = y2 (k + 1) + m · . (4.5)
fs
y2 (k + 2) = 2 · y2 (k + 1) − y2 (k). (4.6)
N2 being the number of samples of delay through a moving average FIR filter, it is set by
td (eq. 4.3) and fs :
N1
N2 = td · fs = . (4.7)
2
Knowing N2 from the moving average FIR filter parameters, through eq. (4.6) the
future N2 sample can be predicted from the current and past samples as follows:
y2 (k + N2 ) = 2 · y2 (k + N2 − 1) − y2 (k + N2 − 2) =
= 3 · y2 (k + N2 − 2) − 2 · y2 (k + N2 − 3) = (4.8)
= (N2 + 1) · y2 (k) − N2 · y2 (k − 1).
The predictive filter defined by eq. (4.9) compensates the delay through the moving
average FIR filter: for low frequencies, the phase versus frequency response of H2 (z) has
a linear positive phase which cancels the negative linear phase of H1 (z).
By inspecting the phase versus frequency response of the whole filtering stage (H1 (z) ·
H2 (z)) , H2 (z) can be optimized accordingly in order not to have almost any phase delay
without introducing amplitude error. H2 (z) is redefined as:
vˆd+1
vˆd+1
Vabc H1(z) H1(z)’ H2(z)
H1(z) H2(z)
vˆq+1
Vabc
vˆq+1
[P1+ ]
[P1+ ]
H1(z) H1(z)’ H2(z)
H1(z) H2(z)
Following the theoretical approach of the previous section, two design examples are
contributed.
Fig. 4.1a shows the filtering block which employs two pairs of linked moving average
and predictive filters. The values of the parameters are summarized in table 4.1.
Table 4.1
Design Example 1 Values.
fs N1 N2 ǫ
10 kHz 100 50 0.0095
The whole system implementing this filtering block is named S1. Fig. (4.2a) shows
H1 (z)·H2 (z) frequency response. The cancellation pattern is optimized for even harmonics
after P+1 caused by odd harmonics in the input signal vabc [146]. Fig. (4.2b) proves
the feasibility of the predictive filter approach: the phase delay is almost zero for low
frequencies. This error is even minimized by the optimization of the ǫ value (Fig. (4.2c)).
Figs. 4.2d and 4.2e show that the transient response is kept in half a fundamental cycle.
As said, in this approach only odd harmonics in vabc are considered since non-linear
electrical loads causing high even harmonic disturbances (in vabc ) are not usual and their
use must be precluded in ac networks [163–165]. To deal with the presence of even
harmonics in vabc , N1 = 200 and N2 = 100 could be considered.
140 Chapter 4 Predictive based SRF-MAF Synchronization Algorithms
1.5 1.002
Magnitude (abs)
Magnitude (abs)
1.0015
1
1.001
1.0005
0.5
0 0.9995
90 0.04
Phase (deg)
Phase (deg)
45 0.03
0 0.02
-45 0.01
-90
0
-135 -0.01
0 50
100 150 200 250 300 350 400 450 500
550 0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2
Frequency (Hz) Frequency (Hz)
(a) Frequency response (in Hz). (b) Fig. 4.2a zoomed around low frequency with
ǫ = 0.
1.0115
0.5 1 sample
Magnitude (abs)
1.011 0.4
0.3
1.0105
0.2
Amplitude
1.01 0.1
100 samples of 0.01
1.0095 0
0.001 -0.1
Phase (deg)
0 -0.2
-0.001
-0.3
-0.002
-0.4
-0.003
-0.5 1 sample
-0.004
0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2 0 0.002 0.004 0.006 0.008 0.01 0.012 0.014
Frequency (Hz) Time (sec)
(c) Fig. 4.2a zoomed around low frequency with (d) Impulse response (tw = 0.01 s). .
ǫ = 0.0095.
1.8
1.6
1.4
Amplitude
1.2
0.8
0.6
Figure 4.2: Design example 1: time and frequency responses of H1 (z) · H2 (z).
4.3 Simulation Results 141
Even though S1 is a very good practical solution dealing with unbalance and harmon-
ics, the presence of other factors such as interharmonics, noise, notching (also noise), dc
offset ([132]) could degrade the performance of the measurements. In fact, the limitations
of the proposed system are mainly set by its cancellation pattern. In order to improve the
′
cancellation pattern two moving average filters H1 (z) and H1 (z) can be linked, as pro-
posed in this section (Fig. 4.1b). The predictive filter should be recalculated according
to eq. (4.7), since the time of delay through the two filters is doubled. The whole system
implementing this filtering block is named S2, and its values are summarized in table 4.2:
Table 4.2
Design Example 2 Values.
′ ′
fs N1 N1 (Eq. (4.2) for H1 ) N2 ǫ
10 kHz 100 100 100 0.009
Fig. 4.3 shows the frequency and step responses of design example 2. The cancellation
pattern is improved at cost of doubling the transient time. As in other systems such as
PLLs, there is a trade-off between filtering and transient response.
The S1 system proposed in the previous section has been simulated in order to test
its performance. Simulation results have been obtained through Matlab/Simulink, using
the fixed step discrete time solver at fs = 10 kHz.
The most important feature of time domain simulation with respect to real time
implementation is the possibility of obtaining curves of phase error, frequency error and
amplitude error in the time domain. These errors are defined as the difference between
the actual and estimated values.
The amplitudes of the input waves are in p.u. units, so they can represent both
voltages or currents. The magnitude displayed to indicate the amount of unbalance in
−
vabc is the negative sequence vector magnitude (va1 max
).
− +
Fig. 4.4 shows the phase error for an unbalanced (va1 max
= 0.1 · va1 max
) input wave
rotating at 51 Hz (ω1 = 2π51 rad/s). A −45 deg phase jump has been programmed to
show both steady-state and transient responses. The result is also displayed for the system
without predictive filters. As expected, the system without predictive filters has the non-
zero average steady-state phase error set by eq. (4.1). With predictive filter, steady-state
zero error is achieved. As also expected, the transient lasts 0.01 s.
142 Chapter 4 Predictive based SRF-MAF Synchronization Algorithms
2 1.6
Magnitude (abs)
1.5 1.4
1 1.2
Amplitude
0.5 1
0 0.8
360
Phase (deg)
0 0.6
-360
-720
0.4
-1080
-1440 0.2
-1800
-2160 00
0 50
100 150 200 250 300 350 400 450 500 550 0.005 0.01 0.015 0.02 0.025
Frequency (Hz) Time (sec)
(a) Frequency response (in Hz). (b) Step response (tw = 0.02 s).
Phase (deg) Magnitude (abs)
1.01
1.008
1.006
1.004
1.002
1
0.998
0.01
0
-0.01
-0.02
-0.03
-0.04
0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2
Va
1
Vc
Amplitude (p.u.)
Vb
-1
20 10
0
10
Average steady-state phase
Phase error (deg)
-20 -40
-30 -50
0.99 1 1.01 1.02 1.03 1.04 1.05 0.99 1 1.01 1.02 1.03 1.04 1.05
Time (s) Time (s)
(b) Phase error: transient and steady-state (c) Phase error: transient and steady-state
with predictive filters (H2 (z)). Zero average without predictive filters (H2 (z)). There is no
phase error is achieved. zero average phase error.
Fig. 4.5 shows the phase error when the input wave of the previous test has a big
frequency step in 0.2 s: from 48 Hz to 52 Hz. Before and after the transient of duration
0.01 s, the average phase and frequency error are zero. As shown, frequency deviation
and phase jump responses are equivalent, on the contrary to overdamped PLLs.
Input frequency (Hz)
53
52
51
50
49
48
47
0.17 0.18 0.19 0.2 0.21 0.22 0.23
Time (s)
2
Phase error (deg)
0
-0.5
0.17 0.18 0.19 0.2 0.21 0.22 0.23
Time (s)
Frequency error (Hz)
4
Average steady- Average steady-
state phase error state phase error
2 equal to 0 equal to 0
-2
0.17 0.18 0.19 0.2 0.21 0.22 0.23
Time (s)
− +
Figure 4.5: S1 response to a big frequency step at 0.2 s. Unbalanced (va1 max
= 0.1 · va1 max
) input wave. Frequency step (up), phase error (center) and frequency error (down). Zero
steady state error and transient duration of 0.01 s are achieved.
− +
Fig. 4.6 shows the results for an unbalanced (va1 max
= 0.1 · va1 max
) and harmonic
th th th
contaminated (≈ 10% 5 , 7% 7 , 4% 11 ) input wave rotating at 49.5 Hz. In 1 s a
deep magnitude change (sag) from 1 p.u. to 0.2 p.u. with a +45 deg phase jump has been
programmed. Fig. 4.6b shows how steady-state phase error is achieved; the transient
+ + + +
lasts 0.01 s. Fig. 4.6c shows v̂a1 max
, amplitude error, v̂d1 and v̂q1 ; as expected v̂d1 and
+
v̂q1 rotate at 0.5 Hz. The average amplitude error is non zero only during the transient
+ +
(0.01 s). Fig. 4.6d shows the Clarke variables (v̂α1 and v̂β1 ) employed in the calculation
of θ1 .
The proposed algorithm has been implemented in the dSpace platform DS1103 at
(fs = 10 kHz) and tested in the laboratory. The execution time of S1 and S2 was 11.2 µs
and 15.8 µs respectively. The three phase voltage system has been generated with a three
phase programmable AC source (three Chroma 61501 modules). In order to obtain the
4.4 Experimental Results 145
40
1.5
Va Vb Vc
20
1
0
0.5
-20
0
-40
-0.5
-60
-1
-80
-1.5
0.95 0.96 0.97 0.98 0.99 1 1.01 1.02 1.03 1.04 1.05 -100
0.95 0.96 0.97 0.98 0.99 1 1.01 1.02 1.03 1.04 1.05
(a) S1: set of distorted input waves in time domain. (b) Phase error: the transient lasts 0.01 s and zero
− +
Unbalance (va1 max
= 0.1 · va1 max
) and harmonics average steady-state error.
th th th
(≈ 10%5 , 7%7 , 4%11 ).
1.2
1
1 |Vp|
0.8
0.8
0.6
Vq
0.6
0.4
0.4 0.2
0.2 0
0 -0.2
-0.4
-0.2
Vd -0.6
-0.4
-0.8
-0.6
-1
-0.8
0.95 0.96 0.97 0.98 0.99 1 1.01 1.02 1.03 1.04 1.05 0.95 0.96 0.97 0.98 0.99 1 1.01 1.02 1.03 1.04 1.05
+ + + + +
(c) v̂a1 max
, v̂d1 and v̂q1 measurements. The tran- (d) vα1 and vβ1 estimations. They are not dis-
sient lasts 0.01 s and zero average steady-state er- torted.
ror.
Figure 4.6: S1 tested under a distorted set of input waves rotating at 49.5 Hz. At 1 s, a
1 p.u. to 0.2 p.u. sag with +45 deg phase jump has been programmed.
146 Chapter 4 Predictive based SRF-MAF Synchronization Algorithms
Vb Vc Va, Vα Va
Vα
Va–Vα
Va–Vα
(a) Balanced set of voltages oscillating at 48 Hz and (b) Zoom of Fig. 4.7a around the zero cross. The
+
Vα measurement. M1 is va −v̂α1 which tends to zero. average error is slightly positive due to the sampling
process.
Figure 4.7: S1: steady state error for a balanced set of inputs oscillating at 48 Hz.
test signals containing sags, unbalance, harmonics and notching signals the three phase AC
source has been used as an arbitrary power amplifier connected to a three phase arbitrary
waveform generator based on a DSP card. The input signals have been acquired through
the dSpace I/O interface by means of LEM LV25-P voltage transducers. As in previous
section, p.u. units have been employed.
As the system is an open loop system, no feedback error signals can be presented.
+
However, considering only the fundamental component, va = v̂α1 for balanced conditions
0 − 0
and for unbalalanced systems when va = −va , that is vabc and vabc
−
cancel each other
+
for the a phase. Therefore, testing the systems under such conditions va − v̂α1 represents
+
the error; that is va − v̂α1 = 0 implies zero error in phase, frequency and amplitude. The
subtraction function of the oscilloscope has been used to obtain this error (channel M 1).
Fig. 4.7 shows the error signal of S1 in steady-state when the set of inputs is balanced,
and oscillates at 48 Hz. As shown, the error is negligible. In the zoomed figure, it could
be noticed the small positive delay between the input (va ) and the output or processed
+
signal (v̂α1 ). This error is due to the sampling process (execution and conversion times).
Fig. 4.8 shows the error signal of S1 in steady-state for an unbalanced set of inputs
+
oscillating at 51 Hz. As explained before, va− = −va0 and va1 −
max
= 0.1 · va1 max
in order
to test the error signal. These figures also prove the absence of steady state error of the
algorithm. Fig. 4.8b shows again the small delay in the visualization due to the sampling
process.
Fig. 4.9 shows the error signal of S1 before, during and after a transient. The pro-
+
grammed transient is a sag with post-fault component [32]. During the fault va1 max
=
0 −
0.8 p.u. and va = −va with va1max = 0.05 p.u., and a −45 deg phase jump with respect to
−
4.4 Experimental Results 147
Vb Va
Va, Vα
Vc
Vα
Va–Vα
Va–Vα
(a) Steady state measurements for a balanced set of (b) Zoom of Fig. 4.8a around the zero cross. The
+
voltages oscillating at 51 Hz. M1 depicts va − v̂α1 average error is slightly positive due to the sampling
as error signal tends to zero in steady-state. process.
− +
Figure 4.8: S1: Steady state error for an unbalanced (va1 max
= 0.1 · va1 max
) set of inputs
oscillating at 51 Hz.
+
the balanced wave of va1 max
= 1 p.u..
Once proved the theoretical approach in terms of zero steady state error and transient
response, other interesting figures are shown. Because of the features of the input waves,
the error signal is not available for these tests.
Fig. 4.10 shows how the measurement of θ1 through S1 for a set of unbalanced
+
−
(va1 max
= 0.09 · va1 max
) and harmonic contaminated (≈ 9% 5th , 5% 7th , 3% 11th ) in-
put waves rotating at 48 Hz is rippleless.
Figs. 4.11) and 4.12 compare S1 with S2 in terms of the trade-off between filtering
and transient response.
Fig. 4.11 shows the test made for a balanced input wave containing notches, which,
+
under the frequency domain point of view, is noise. Fig. 4.11a shows v̂α1 measured with
+
S1 contains notches, even though smoother than in input waves. Fig. 4.11b shows as v̂α1
measured with S2 is clean. These results are expected from Figs. 4.2a and 4.3a.
Fig. 4.12 shows how S2 improves the frequency rejection of S1 at cost of incrementing
the resources (execution time) and transient response. This test has been realized with
− +
an unbalanced (va1 max
= 0.09 · va1 max
) input wave which presents a very deep sag: from
1 p.u. to 0.1 p.u. with −45 deg phase jump. S1 is faster than S2 as expected from Figs.
4.2e and 4.3b. Figs. 4.12 emphasize the fact that the system gain is independent from
the input amplitude.
148 Chapter 4 Predictive based SRF-MAF Synchronization Algorithms
Vb
Vc
Va Va
Vα
Vα
Va–Vα Va–Vα
(a) S1: Transients response to a sag with −45 deg (b) S1: Transients response to a sag with −45 deg
+ +
phase jump. M1 depicts va − v̂α1 as error signal phase jump. M1 depicts va − v̂α1 as error signal
which is zero in steady-state. As expected, the tran- which is zero in steady-state. As expected, the tran-
sients lasts 0.01 s. Time scale at 5 ms. sients lasts 0.01 s. Time scale at 2 ms.
Figure 4.9: S1: Transient response for a sag with −45 deg phase jump.
Table 4.3 shows a brief comparative with other significant proposals which successfully
deal with unbalance [108, 140, 144] 2 .
Table 4.3
Brief comparative among significant systems with good unbalance rejection
The settling time (ts ) is defined as the time required for the system to settle within a
certain percentage of the steady-state value [192].
As proved, for S1 and S2 ts is accurately set by the step response of the FIR filtering
stage (eq. (2.43)): 0.01 s and 0.02 s respectively. In relation to device implementation,
it is clear that the moving average filters are a part resource consuming as shown in the
2
The comparative is made with respect to data provided in those works. DSRF-PLL is the Double
SRF-PLL provided in [108]
4.4 Experimental Results 149
Figure 4.10: S1: steady-state phase measurement at 48 Hz. Ch1 is θ1 , Ch2 is va , Ch3 is
vb , Ch4 is vc (phase in ≈ 2 rad, voltages in p.u.). The measurement does not have ripple.
increment of execution time from S1 to S2. However, this and other implementations
[128, 157, 158] prove that current digital devices are powerful enough to implement them
in real time. With regard to amplitude dependence, due to the linearity of all the employed
digital filters the system is amplitude independent.
The settling time ts (to within 2% of the final value) of the DSRF-PLL has been
estimated using the data (ωc = 2π25 rad/s, ξ = 0.707 ) of the equivalent linearized
systems studied in [108] through the formula [192]:
4
ts = . (4.11)
ξ · ωc
The accuracy of this estimation can be checked in Figs. 11 and 12 of [108]. The
execution time of the DSRF-PLL is not shown in [108], but, it is smaller than the imple-
mentation sampling time (50 µs).
The non-linearity introduced by the phase detector in PLLs, and therefore also in the
DSRF-PLL has the drawback of amplitude dependence, even though this can be reduced
through a normalization stage [126, 127, 137].
ts of NPSF presents a high vary depending on the kind of transient, as shown in Figs
12 of [144], which is a non linear feature. This time is always higher than 0.02 s.
The WLSE algorithm , tested when the input frequency is tracked (Figs. 6 and 7 of
[140]) presents a very quick response and good harmonic/noise rejection. However, its
frequency adaptation algorithm is very slow when compared with the NPSF one. In fact,
the frequency adaptation seems to be the main lack of the WLSE algorithm [108].
150 Chapter 4 Predictive based SRF-MAF Synchronization Algorithms
Va Va
Va Va
+ +
(a) Measurement with S1. v̂α1 also contains (b) Measurement with S2. v̂α1 is clean.
notches.
+
Figure 4.11: Comparative between S1 and S2 in terms of noise rejection. Ch1 is va1 max
,
Ch2 is va , Ch3 is vb , Ch4 is vc (voltages in p.u., ω1 = 2π · 49.75 rad/s).
Va Va
Va Va
(a) Transient response of S1. The steady-state is (b) Transient response of S2. The steady-state is
reached in 0.01 s. reached in 0.02 s. The settling time is doubled.
+
Figure 4.12: S1 Vs S2 in terms of transient response. Ch1 is va1 max
, Ch2 is va , Ch3 is vb ,
Ch4 is vc (voltages in p.u., ω1 = 2π · 49 rad/s).
4.5 Conclusions 151
In general, it could be said that adaptive filtering based algorithms such as Kalman
based and WLSE have a trade-off between transient response and frequency adaptation,
as proved in [145]. The WLSE approach of [140] is in the extreme of very fast transient
response but with a very slow frequency adaptation.
From table 4.3, it is clear that S1 and S2 present very good dynamics and are suitable
for real time implementation with a high performance.
4.5 Conclusions
This chapter shows how the SRF-MAF systems can be made frequency adaptive by
means of predictive filters. The methodology developed to obtain FIR predictive filters is
contributed. Some interesting features of the proposal should be highlighted.
• Its dynamics are independent from the amplitude of the input waves, and therefore
the system is highly stable. This advantage is specially advantageous for phase-angle
tracking of variable rms waves such as the current in a SSSC [209].
• On the contrary to PLLs, specially overdamped tuned ones, there is not trade-off
between frequency and phase responses.
These features, bode well for the applicability of the algorithm in the control of grid
connected power converters, grid monitoring in distributed power generation systems, and
other applications where a fast and accurate on-line measurement of phase, frequency and
amplitude are mandatory.
Even though they were not developed or commented in the chapter, some interesting
points of this proposal should be also mentioned:
• The theoretical approach to achieve the predictive filters is based on predictive FIR
filters. However, IIR all-pass filters with a more advantageous amplitude response
(unitary gain) and positive linear-phase could be developed. In return, this solution
has a longer transient response.
Chapter 5
Abstract —
A 1 kVA rated lab prototype has been implemented and tested. Experimental tests show
how the system performs both in steady-state and under different transients. Perfect tracking
in steady-state for a wide range of grid-frequencies is achieved. Regarding transient response,
different tests were programmed such as load transients (change in the load), sudden and large
changes in the ac mains frequency (frequency steps) and strong source voltage faults (voltage
sags with phase-jump). Experimental results prove how the system is robust and fast responding
to all of these possible real operation faults.
153
154 Chapter 5 Frequency Adaptive PR Current Controller for APFs
5.1 Introduction
The issue of current control for power electronic converters connected to the grid is a
field of paramount interest at present [210–217]. More specifically, schemes including res-
onant controllers to achieve perfect tracking/rejection in steady-state of periodic currents
have been proposed for all kind of power converter applications, such as active power fil-
ters (APFs) [119, 120, 210], distributed power generation systems (DPGSs) [2, 217–219],
rectifiers [213, 220] and motor drives [36, 88, 221].
When comparing with other structures, PR current regulators have some interesting
features, specially when active filtering operation is considered; in sum:
• Hysteresis current controllers are simple and achieve perfect tracking but, in general,
they have poor switching characteristics (variable switching frequency, maximum on-
time). Linear regulators, as PR schemes, overcome these limitations by separating
the modulation and regulation functions [222].
• Basic schemes based on linear regulators such as simple proportional and dead-beat
schemes do not achieve zero average steady-state error. In a general way, it can
be said that these kinds of controllers perform worse as higher is the harmonic
component to compensate [3]. PR current regulators seem to be a much better
alternative for APFs.
• It has been demonstrated that PR current controllers can perform as the ones based
on Synchronous Reference Frame (SRF) [88]. Under the discrete implementation
point of view, PR controllers are an interesting alternative since Park’s transforma-
tions are not needed [88, 120].
• Lately, repetitive regulators based on the discrete cosine transform (DCT) have been
proposed as an alternative to PR controllers [219, 223]. There are more similarities
than differences when both schemes are compared [219]. However, the PR structure
has been chosen in this work due to the fact that its frequency adaptation is more
approachable, since less digital filter coefficients (taps) are involved.
Focusing the problem in PR current regulators for APFs, their open loop transfer
function should have resonant peaks at selected frequencies, as well as at the fundamental
one [119, 120]. The resonance at fundamental frequency provides perfect tracking at
5.1 Introduction 155
fundamental currents (i.e. for dc bus control) as well as total rejection to the fundamental
component of the grid voltage (disturbance) [119].
A practical problem of resonant filters, and hence in PR controllers, arises with grid-
frequency deviations owing to their high selectivity; if not compensated, frequency varia-
tions cause that resonant peaks do not coincide with input wave frequencies and, therefore,
perfect tracking/rejection is not assured [88]. This problem may be specially critical in
isolated systems where ranges of operation within a range of ≈ ±2 Hz, or higher, are
taken into account [224]. Indeed, the higher the frequency deviation, the lower the gain;
so, in practice, for so high non-compensated frequency deviations, a PR controller works
as a simple proportional one [88].
Table 5.1
Significant values of the power circuit.
Parameter Value
vdc
∗
220 V
vSrms 110 V
C 1 mF
ZF LF + R F
LF 5 mH
RF 0.5 Ω
LS 50 µH
fsw = fs 10 kHz
tcomp 12 µs
Fig. 5.1 depicts the scheme of the lab prototype and its discrete controller. Table 5.1
shows the significant values of the hardware.
The discrete controller has been implemented in the dSpace DS1103 platform, which
implements Matlab/Simulink models in real-time. The discrete solver has been chosen
so all the controller blocks are digital filters in the Z-domain (neither “ode” solvers nor
“continuous” blocks). The sampling frequency (fs ) and IGBTs switching rate (fsw ) have
been set to 10 kHz; the sampling period Ts is defined as 1/fs . System currents and voltages
have been sensed using LEM-LA55P and LEM-LV26V sensors, respectively. These sensed
signals are acquired through the I/O interface of the dSpace target. The average time of
operation tcomp was around 12 µs. Fig. 5.2 shows a picture of the built prototype as well
as a capture of a ControlDesk layout in real-time operation.
The goals of the digital control are: to compensate for the selected load harmonic
currents and to keep constant the dc-link voltage (vdc ). The proposed controller works as
follows.
AC REGULATOR
MANUAL
SWITCH
vS
LS iS PCC iL
vPCC
VSC
UNCONTROLLED
vF ZF iF RECTIFIER
vDC C
PWM
m
vPCC iL
P+RESONANT
∆ω
ˆ1 ω̂1 HARMONIC
CURRENT
REGULATOR
PLL EXTRACTION
vDC sin(θˆ 1 )
-
PI X
+ iF
- +
i1*
vDC *
+ +
iF* iLh*
DIGITAL CONTROLLER (dSpace DS1103)
• The reference harmonic currents to compensate (i∗F h ) are extracted from iL by means
of digital signal processing. A selective extraction of 3rd , 5th and 7th components is
performed using SRF-MAFs [148] (i∗F h = îL3 + îL5 + îL7 ).
• The total reference of current for the APF (i∗F ) is calculated as i∗F h + i∗F 1 .
• The PR current regulator assures that (i∗F − iF ) is zero in steady-state (for the
fundamental, 3rd , 5th and 7th harmonic components).
VSC
I/O Interf
Non-linear
Load circuits
Box with
sensors (PCC)
PC with
dSPace
Non-linear
DS1104 Load circuits
AC Sources
connected
in parallel
2π ·3
∆ω̂1
− 2π ·3
MAF2
2π ·47
cos(u)
−π
sin(θˆ )
1 sin(u)
A single-phase PLL has been implemented to track online the phase-angle (θ1 ) and
frequency (ω1 ) of vP CC fundamental component. Fig. 5.3 shows the PLL block diagram.
It uses a multiplier as phase detector. The loop filter is composed of a proportional
integrator (PI) controller and a moving average filter (MAF1), for which the equivalent
transfer functions are
c1 − c0 · z −1
C(z)P I = (5.1)
1 − z −1
and
1 1 − z −n
C(z)M AF 1 = · , (5.2)
n 1 − z −1
respectively. The PI controller assures that θ1 and ω1 are tracked with zero average
steady-state error, even though ω1 6= ω1n [78, 112–114]. A second MAF (MAF2) with
the same transfer function as C(z)M AF 1 can be placed before ∆ω̂1 estimation in order to
control the ∆ω̂1 ripple.
Table 5.2
Values of PLL parameters.
Parameter Value
c1 2
c0 1.995
n (MAF1) 100
n (MAF2) 100
100
50
Magnitude (dB)
-50
-100
-150
-200
-90
Phase (deg)
-135
PM=31 deg
-180
-225
-270
-1
work extends this approach to resonant controllers design: the difference equation
of each one is function of h · ω1n and h · ∆ω̂1 (see section 5.4).
PLLs have a trade-off between transient response and filtering: the higher the band-
width the faster the transient response but the worse the harmonic cancellation. Specially
critical is the internal second harmonic generation in multiplier based single-phase PLLs.
If not canceled, this second harmonic causes ripple in ∆ω̂1 , ω̂1 and θ̂1 , which could affect
to the whole controller performance [112–114].
Fig. 5.4 shows the open loop frequency response of the linear PLL. The values of the
coefficients are shown in table 5.2. Stability and bandwidth optimization has been sought
during the tuning process [112–114]. The phase margin (PM) could be considered a bit
low for a controller design, but, in the case of PLL tuning, a very big increase in vSrms is
not expected, so stability is assured with this PM [112–114].
5.4 PR Current Controller 161
Forward
Euler
iF*-iF Ts z − 1 output
1 − z -1
+
-
ω̂ 12
Ts
1 − z -1 X
Backward
Euler
From Fig. 5.4, when ω1 = ω1n , thanks to MAF1 all the harmonics, including the
second one, are canceled. However, when ω1 6= ω1n perfect harmonic cancellation is not
achieved.
It is out of the scope in this chapter to show how to optimize more the PLL loop filter
in order to reduce jittering. Instead of it, harmonic ripple effect in PR current controllers
is studied. In this work, control over ripple has been achieved by placing/removing MAF2.
Resonant filters are undamped GIs which can be implemented as two linked integra-
tors [119]. Frequency adaptation is provided by means of PLL estimation [2, 119, 218].
Regarding the discretization method, it has been suggested to discretize the direct integra-
tor using Forward Euler method while the feedback one is discretized using the Backward
Euler method, as shown in Fig. 5.5 [2]. The resulting transfer function in the Z-domain
is:
z −1 − z −2
Rtwo (z) = Ts . (5.3)
1 + z −1 (ω12 Ts2 − 2) + z −2
It can be checked that to discretize the two integrators separately results in a displace-
ment of the resonant peaks from the expected values. However, the linear dependence of
the different equation on ω12 eases the frequency adaptation.
To use the Z-transform of the cosine wave was proposed in [120]. This means, in
practice, to discretize a second order generalized integrator with the impulse invariant
162 Chapter 5 Frequency Adaptive PR Current Controller for APFs
1 − z −1 cos(ω1 Ts )
Rii (z) = Ts · . (5.4)
1 − 2z −1 cos(ω1 Ts ) + z −2
This method results much more accurate, as shown in Fig. 5.6. Its drawback ap-
pears when frequency adaptation is desired, since trigonometric functions are involved. A
method to avoid explicit cosine wave calculations is provided in section 5.4.2.
The error induced by the two integrators based implementation may be acceptable for
some applications handling with very low order harmonics and fundamental. However,
the loss of performance is very significant for higher harmonics. Rii (z) seems to be a
better choice, specially for APFs.
A PR controller (C(z)) of the form of (5.5) has been selected for implementation. Ts
is a constant term so it can be included in each Kh .
X ′ 1 − z −1 · cos(h · ω1 · Ts )
C(z) = KP + KRh · Ts · =
h=1,3,5,7 1 − 2 · z −1 · cos(h · ω1 · Ts ) + z −2
(5.5)
X 1 − z −1 · cos(h · ω1 · Ts )
KP + KRh · .
h=1,3,5,7 1 − 2 · z −1 · cos(h · ω1 · Ts ) + z −2
From (5.5), it seems immediate to update the terms cos(h · ω1 · Ts ) using ω̂1 from
the PLL [225]. The main drawback of this approach is that it requires computation of
trigonometric functions online. The explicit implementation of the cosine function can be
avoided, using the proposed Taylor approximation detailed as follows.
In a similar manner that the digital PLL of Fig. 5.3 works around the equilibrium
point established by ω1n , the PR current regulator of (5.6) has been derived from (5.5):
assuming that h · ∆ω̂1 · Ts ≈ 0, the “equilibrium point strategy” of PLL is also applied to
resonant controllers.
Fig. 5.7 shows the implementation block for each resonant controller. Block diagram
5.4 PR Current Controller 163
Hz
Hz
Figure 5.6: Comparative of the error induced by different implementations (fs = 10 kHz).
iF*-iF
KRh +
+ + To adder
- Z-1 ah ++ -
Z-1 bh X
∆ω
Precalculated constants:
ah = cos(h·w1n·Ts) ^ h·Ts
1
bh = sin(h·w1n·Ts) (From PLL)
algebra has been applied to optimize the implementation set by (5.6), so the number of
multiplications by non-fixed coefficients (∆ω̂1 ) has been reduced to one.
Fig. 5.8 shows the accuracy of the approximation for each resonant block. The higher
the harmonic order, the worse the approximation, since a shift of ±1 Hz at fundamental
results in a ±h · 1 Hz shift at the harmonic h. At any rate, this error can be considered
low enough, even for significant frequency deviations, as proved in section 5.5.
As explained, when ∆ω̂1 6= 0 the resonant peak is moved to the estimated frequency;
i.e. Fig. 5.9 shows the effect of the frequency correction around the 3rd harmonic resonant
peak. It could be said that when the peak is “well centered” the PR is working as an ideal
resonant controller (infinite gain), but in other case the performance tends to approach
164 Chapter 5 Frequency Adaptive PR Current Controller for APFs
0.35
Fundamental
3rd harmonic
5th harmonic
Hz
0.25 7th harmonic
0.15
0.05
100
90
∆ω1<0
Magnitude (dB)
80
∆ω1>0
70
60
50
40
30
Proportional Resonant Proportional
controller controller controller
20
45
Phase (deg)
0
-45
-90
-135
-180
149.8 149.9 149.98 150 150.02 150.1 150.2
Frequency (Hz)
Figure 5.9: Frequency response of C(z) · P (z) around 150 Hz. When ∆ω̂1 > 0 the peak
”moves” to higher frequencies and vice versa.
the one of a proportional controller. The exact place to depict the resonant/predictive
borderline in that figure could be considered a subjective issue. The idea is to show how
a practical very high gain is sought with frequency adaptation.
¯ 1 + ∆ω̂
∆ω̂1 = ∆ω̂ ˜1, (5.7)
where ∆ω̂¯ 1 and ∆ω̂
˜ 1 are the average value and an oscillating term associated with jittering,
respectively.
From Fig. 5.9, the best performance occurs when ∆ω̂ ¯ 1 is tracking perfectly, that is,
˜ 1 = 0 (no jittering). The first condition is
the resonant peak is well centered, and ∆ω̂
easily performed by any PLL, but the second one is more complicated, specially under
5.4 PR Current Controller 165
vPCC
iF
−1
iF* m -
+- C ( z) z + G (z )
iF Plant Model≡ P(z)
Fig. 5.10 depicts the current control system including the PR controller C(z) and the
model of the plant P (z). P (z) has been modeled including the computational delay (z −1 )
and the PWM converter operation. The PWM reference (m) is kept constant over each
sampling interval, so the power converter can be assumed to be a zero order hold (ZOH)
circuit. Therefore, the filter inductance discrete-time model (G(z)) should be obtained
through the ZOH method, as follows [3, 226]:
The effect of the ZOH circuit is noticeable at high frequencies, since an extra phase
lag is introduced in the current control loop, and it should be taken into account when
tuning C(z).
As said in the introduction, resonant controllers provide perfect tracking (and distur-
bance rejection) of currents for which frequency C(z) · P (z) has infinite gain.
Fig. 5.11 shows C(z) implementation. Four resonant blocks have been implemented
in the APF controller: one at fundamental component to provide perfect tracking of i∗F 1
(vdc control) and vP CC fundamental rejection, and the other three ones to provide perfect
tracking of i∗F 3 , i∗F 5 and i∗F 7 . The term 1/vdc
∗
is included so Kp and Kh tuning is made
independent from vdc (plant).
The controller C(z) has been tuned by inspection of C(z) · P (z) transfer function
[120, 219]; ω1 = ω1n has been considered. Fig. 5.12 shows C(z) · P (z) frequency response
and the parameters are specified in Table 5.3. From Fig. 5.12, the implemented PR
controller has the following features:
166 Chapter 5 Frequency Adaptive PR Current Controller for APFs
iF*-iF
KP +
Res.1st +
m
Res.3rd +
Res.5th +
∆ω
Res.7th +
^1
(From PLL)
Table 5.3
Values of parameters of the PR controller.
Parameter Value
KP 25
KR1 0.1
KR3 0.1
KR5 0.1
KR7 0.1
• A fast transient response is expected: the open loop cut-off frequency and hence the
system bandwidth are around 800 Hz.
5.5 Experimental Results 167
100
80
Magnitude (dB)
60
40
20
-20
180
135
Phase (deg)
90
45
0
-45
-90
-135
PM=46 deg.
-180
10 100 800 1000
Frequency (Hz)
Different tests have been carried out to show how the APF performs both in steady-
state and under transients.
Fig. 5.13 shows experimental results obtained from steady-state operation when an
“input frequency sweep” has been carried out. Oscilloscope figures show results at nomi-
nal (50 Hz) and very shifted (48 Hz) frequencies; system currents and vP CC are displayed.
It should be noticed that iL spectrum varies slightly with the frequency due to load reac-
tances. Fig. 5.13g depicts a table with all the results of the “input frequency sweep”. These
results prove that the 3rd , 5th and 7th harmonics of iL are not present in iS . Therefore,
perfect tracking of the APF harmonic reference is achieved. The fundamental component
of iS is slightly higher than iL1 , since vdc should be maintained.
Fig. 5.14 shows experimental results when there is a load transient. Initially only the
uncontrolled rectifier is connected to the PCC and then the ac regulator starts up. As
expected from the PR controller bandwidth (800 Hz) the system has a very fast transient
response. It should be noticed that the extraction algorithm settling time is ≈ 0.01 s and
also affects to dynamics [148].
Fig. 5.15 illustrates the APF response when there is a sudden step in f1 . Fig. 5.16
depicts results from a similar test but showing ∆ω̂1 from the PLL in Ch2. In both cases,
the PR current regulator and, therefore, the whole system presents a very good frequency
adaptation. The frequency step has been detected inside the dSpace model and connected
168 Chapter 5 Frequency Adaptive PR Current Controller for APFs
(a) Steady-state currents and voltage at the (b) Fourier spectra of iL in (c) Fourier spectra of iS in
PCC when f1 = 50 Hz. Fig. 5.13a (Ch1). Fig. 5.13a (Ch3).
(d) Steady-state currents and voltage at the (e) Fourier spectra of iL in (f) Fourier spectra of iS in
PCC when f1 = 48 Hz. Fig. 5.13d (Ch1). Fig. 5.13d (Ch3).
48 Hz 49 Hz 50 Hz 51 Hz 52 Hz
h iL iS iL iS iL iS iL iS iL iS
1 3.02 A 3.2 A 2.96 A 3.13 A 2.87 A 3A 2.79 A 2.94 A 2.71 A 2.87 A
3 886 mA 30 mA 874 mA 10 mA 856 mA 4 mA 826 mA 14 mA 738 mA 25 mA
5 223 mA 8 mA 206 mA 5 mA 199 mA 4 mA 190 mA 6 mA 186 mA 9 mA
7 176 mA 13 mA 153 mA 9 mA 134.6 mA 3 mA 115 mA 6 mA 94 mA 11 mA
(g) Values of harmonic current of the load and the source for different frequencies.
Figure 5.13: Steady-state currents and vP CC for different input frequencies. Ch1 is iL ,
Ch2 is iF , Ch3 is iS and Ch4 is vP CC .
5.5 Experimental Results 169
Figure 5.14: Transient response when there is a load change. Ch1 is iL , Ch2 is iF , Ch3 is
iS and Ch4 is vP CC .
Figure 5.15: Transient response when there is a frequency step in f1 from 48 Hz to 52 Hz.
Ch1 is iL , Ch2 is iF , Ch3 is iS and Ch4 is vP CC .
to the oscilloscope external trigger. Again, it is noticeable the change in iL spectrum due
to the frequency dependence of load reactances.
Figs. 5.15 and 5.16 have been obtained by implementing the PLL with MAF2. As
expected, ∆ω̂1 is ripple-less (two MAFs). Fig. 5.17 results have been obtained repeating
the previous test, but eliminating MAF2 from the PLL. In this test, a second-harmonic
oscillating term ∆ω̂˜ 1 oscillates ≈ ±1 Hz around ∆ω̂ ¯ 1 . This result is very interesting,
and even quite surprising, since the practical high performance of the PR controller is
kept. Even though, posterior tests made by the authors with a higher level of jittering
(±3 Hz) resulted in instability, it is clear that this implementation is very robust under
the presence of harmonics/noise ripple in the frequency estimation.
Another test has been made considering ∆ω̂ ˜ 1 = 0, that is, a PR without frequency
adaptation. Fig. 5.18 shows results obtained when the input frequency is 48 Hz. The
same results have been obtained testing with a current controller C ′ (z) = KP . Therefore,
the PR controller without frequency adaptation behaves equal that a simple proportional
regulator.
170 Chapter 5 Frequency Adaptive PR Current Controller for APFs
Figure 5.16: Transient response when there is a frequency step in f1 : from 52 Hz to 48 Hz.
Ch1 is iL , Ch2 is ∆ω̂1 (scale at 2π∆3 rad/div), Ch3 is iS and Ch4 is vP CC .
Figure 5.17: Transient response when there is a frequency step in f1 from 48 Hz to 52 Hz.
Effect of ripple of ≈ ±1 Hz in ∆ω̂1 . Ch1 is iL , Ch2 is ∆ωˆ1 (scale at 2π∆3 rad/div), Ch3
is iS and Ch4 is vP CC .
Finally, the prototype has been tested when there is a voltage sag (from 1 p.u. to
0.8 p.u.) with phase-angle jump (+45 deg) in vP CC (programmed in vS ). The test has
been made at 49 Hz (∆ω̂1 = −2π rad/s). When the fault occurs the PLL frequency
increases, but ∆ω̂1 to the PR is limited to 2π∆3 rad/s. As shown in Fig. 5.19, this
protection is crucial and steady-state is achieved in ≈ 1 − 2 cycles. It should be noticed
that the fault also affects to the extraction algorithm [148].
5.5 Experimental Results 171
(a) Steady-state currents and voltage at the (b) Fourier spectra of iL (c) Fourier spectra of iS
PCC when f1 = 48 Hz. (Ch1 of Fig. 5.18a). (Ch3 of Fig. 5.18a).
h 48 Hz 49 Hz 50 Hz 51 Hz 52 Hz
1 3.14 A 3.08 A 3.02 A 2.90 A 2.85 A
3 349 mA 282 mA 4 mA 297 mA 320 mA
5 71 mA 60 mA 4 mA 73 mA 81 mA
7 56 mA 38 mA 3 mA 29 mA 32 mA
(d) Values of iS for ∆ω̂1 = 0 (No frequency adaptation).
Figure 5.18: Steady state figures when error in estimation of ∆ω̂1 is considered.
∆ω̂1 = 0 rad/s and ∆ω1 = −4π rad/s (f1 = 48 Hz). Ch1 is iL , Ch2 is ∆ωˆ1 (scale at
2π∆3 rad/div), Ch3 is iS and Ch4 is vP CC .
Figure 5.19: Transient response when there is a voltage sag (1 p.u. → 0.8 p.u.) with phase-
angle jump of +45 deg in vP CC (vS ). Ch1 is iL , Ch2 is ∆ωˆ1 (scale at 2π∆3 rad/div), Ch3
is iS and Ch4 is vP CC .
172 Chapter 5 Frequency Adaptive PR Current Controller for APFs
5.6 Conclusions
2. The impulse invariant resonant controllers can be made frequency adaptive by means
of a PLL estimation of the grid-frequency deviation. The proposed implementation
has good performance and no needed of explicit trigonometric functions.
3. The most critical parameter of the PLL is its accuracy detecting the average value of
the fundamental frequency. Jittering in ∆ω̂1 should be reduced as much as possible,
even though high robustness to this parameter is provided.
4. The tested resonant controllers achieve perfect tracking even for the worst case (7th
harmonic and ±2 Hz deviation), so it is also expected a good performance in APF
applications compensating for higher order harmonics.
5. The proposed PR controller has a very high bandwidth and, therefore, the system
has a very fast transient response. The whole controller is robust under all kind of
transients such as load changes, frequency variations, and even input voltage sags.
It should be remarked that some PLL outputs (estimations) have been saturated to
avoid malfunctions.
Chapter 6
6.1 Conclusion
This dissertation addresses the issue of grid-synchronization for power electronics con-
verters. Its main contributions and conclusions are summarized below.
173
174 Chapter 6 Conclusion and Future Work
6.2 Publications
Research work included in the dissertation has given rise, at the moment, to three
journal papers [114, 147, 148] and eight conference papers [112, 113, 127, 146, 149–
151, 209]. A summary of the contributions of each journal paper is detailed as follows:
There are several interesting topics suggested for further research. Some of them are
described in the following:
• It is also expected to carry out solutions for industry based on the contributions of
this thesis.
Appendix A
Matlab Scripts
175
176 Chapter A Matlab Scripts
51 Vb=1*sin(offset+phaseGrid+phib)/sqrt(3)+0.1*sin(5*phaseGrid+0.1)+0.1*sin
52 Vc=1*sin(offset+phaseGrid+phic)/sqrt(3)+0.1*sin(5*phaseGrid+0.9)+0.1*sin
53
54 % Error signal vector update
55
56
Figure A.2: PLO system Matlab script. Function file (page 1 of 2).
178 Chapter A Matlab Scripts
60
61
62 % % VCO frequency update
63
64
65 % The phase must be in the range [0,2*pi]
66 while phaseGrid>=2*pi
67
68 end
69
70 while phaseVCO>=2*pi
71
72 end
73
74 while phaseVCO<0
75
76 end
77
78 % Set of Bcd as function of VCO phase (switching functions)
79 if phaseVCO<=pi/3
80
81
82 end
83 if phaseVCO>pi/3 && phaseVCO<=2*pi/3
84
85
86 end
87 if phaseVCO>2*pi/3 && phaseVCO<=pi
88
89
90 end
91 if phaseVCO>pi && phaseVCO<=4*pi/3
92
93
94 end
95 if phaseVCO>4*pi/3 && phaseVCO<=5*pi/3
96
97
98 end
99 if phaseVCO>5*pi/3
100
101
102 end
103
104 % Save output current vector
105
106 % Save Vd voltage
107 % Save line to neutral voltages
108 % Grid phase update
109 % VCO phase update
110 end
Figure A.3: PLO system Matlab script. Function file (page 2 of 2).
179
1 clear all;
2 t=1e-4:1e-4:0.1;
3
4 w1n=2*pi*50; % Kalman filter frequency = Nominal frequency.
5 w1=2*pi*50; % Fundamental frequency of the input wave.
6
7 % Sinusoidal input
8 % v=sin(w0i*t-pi/4);
9
10 % Non sinusoidal input (harmonics)
11 v=sin(w1*t-pi/4)+0.11*sin(3*w1*t)+0.08*sin(5*w1*t);
12
13 % Voltage Sag with pi/4 phase jump
14 % v=-sin(w0i*t(1:500));
15 % v=[v -0.5*sin(w0i*t(501:1000)-pi/4)];
16
17 %add white noise to the input
18 % noise=[];
19 % for i=1:1:1e3
20 % noise=[noise;randn*0.05];
21 % end
22 % v=v+noise';
23
24 xhat=[0;0];
25 M=[cos(w1n*1e-4) sin(w1n*1e-4);-sin(w1n*1e-4) cos(w1n*1e-4)];
26 H=[1 0];
27 p=100;
28 P=[p 0; 0 p]; % Set P(0).
29 q=0.001;
30 Q=[q 0; 0 q]; % States covariance Matrix. High q ==> high K.
31 R=5; % Measurement covariance. High R ==> low K.
32 x=[];
33 phase=[];
34 for i=1:1:1e3
35 % Innovation
36 Inn = v(i) - H * xhat;
37 % Covariance of Innovation
38 s = H * P * H' + R;
39 % Gain matrix.
40 K = M * P * H' * inv(s);
41 % State estimate
42 xhat = M * xhat + K * Inn;
43 % Covariance of prediction error
44 P = M * P * M' + Q - M * P * H' * inv(s) * H * P * M';
45 %Save values
46 x=[x xhat];
47 phase=[phase atan2(xhat(1),xhat(2))];
48 end
49 plot(t,v,t,x);
50 figure;
51 plot(t,phase);
Figure A.5: Matlab script of the Kalman Filter Single-phase synchronization example.
181
1 clear all;
2 Ts=1e-4; % Sampling time (= 1/fs).
3 Tfinal=0.8; % Time for the simulation.
4 t=0:Ts:Tfinal; % time vector.
5 wn=2*pi*50; % Nominal frequency.
6 Mysin=[0;0]; % Initialize Mysin.
7 Mycos=[0;0.99]; % Initialize Mycos.
8 ypd=[0;0]; % Initialize PD output.
9 ylf=[0;0]; % Initialize LF output.
10 ynotch=[0;0]; % Initialize notch filter output.
11 theta=[0;0]; % Initialize phase angle
12 % Create INPUT WAVE for SIMULATION
13 wu=2*pi*50.3; % Input wave frequency
14 u=sin(wu*t+pi); % Input wave definition
15 % SIMULATE THE PROCESS
16 for n = 2:Tfinal/Ts % Number ot iterations
17 ypd(n+1)=u(n)*Mycos(n); % Phase Detector (Q15)
18 % Notch Filter (Q15)
19 %ynotch(n+1)=ypd(n+1);
20 ynotch(n+1)=1.94*ynotch(n)-0.944*ynotch(n-1)+...
21 0.972*ypd(n+1)-1.94*ypd(n)+0.972*ypd(n-1);
22 % Loop Filter Q(8)
23 ylf(n+1)=(1*ylf(n)+250*ynotch(n+1)-247.8*ynotch(n));
24 % Limit LF according to its Q8 size pipeline
25 ylf(n+1)=max([ylf(n+1) -128]);
26 ylf(n+1)=min([ylf(n+1) 128]);
27 % Update Output frequency and compensate 1/2 (Q6)
28 wo=wn+2*ylf(n+1);
29 % Integration process (digital oscillation)
30 Mysin(n+1)=Mysin(n)+wo*Ts*(Mycos(n)); %(Q15)
31 Mycos(n+1)=Mycos(n)-wo*Ts*(Mysin(n)); %(Q15)
32 % Limit the oscillator integrators
33 Mysin(n+1)=max([Mysin(n+1) -0.99]);
34 Mysin(n+1)=min([Mysin(n+1) 0.99]);
35 Mycos(n+1)=max([Mycos(n+1) -0.99]);
36 Mycos(n+1)=min([Mycos(n+1) 0.99]);
37 % Update the output phase (Q12)
38 theta(n+1)=theta(n)+wo*Ts;
39 % Output phase reset condition
40 if Mysin(n)>=0 && Mysin(n+1)<=0
41 theta(n+1)=-pi;
42 end
43 end
44 plot(t,u,t,Mysin,t,theta); % Plot experimental results
Figure A.7: Matlab script of the single-phase PLL with RC-Oscillator based DCO.
References
[1] J. D. Ainsworth, “The phase-locked oscillator-a new control system for controlled
static convertors,” IEEE Transactions on Power Apparatus and Systems, vol. 87,
no. 3, pp. 859–865, Mar. 1968.
[3] H. Akagi, E. H. Watanabe, and M. Aredes, Instantaneous Power Theory and Ap-
plications to Power Conditioning, M. E. El-Hawari, Ed. Wiley-IEEE Press, 2007.
[5] S. Fryze, “Wirk-, blind- und scheinleistung in elektrischen stromkreisen mit nicht-
sinusförmigem verlauf von strom und spannung,” ETZ, Arch Electrotech, vol. 53,
pp. 596–599, 625–627, 1932.
[6] L. S. Czarnecki, “What is wrong with the budeanu. concept of distorted power and
why it should b e. abandoned ?” IEEE Trans. on Instr. Meas., vol. IM-36, pp.
834–837, 1987.
[8] J. Afonso, C. Couto, and J. Martins, “Active filters with control based on the p-q.
theory,” IEEE Industrial Electronics Society Newsletter, vol. 47, pp. 5–11, 2000.
183
184 REFERENCES
[13] ——, “Control and reduction of terminal voltage total harmonic distortion(THD)
in a hybrid series active and parallel passive filter system,” in Power Electronics
Specialists Conference, 1993. PESC ’93 Record., 24th Annual IEEE, Seattle, WA,
USA, Jun. 1993, pp. 779–786.
[15] ——, “Active filter solutions for utility interface of industrial loads,” in Power Elec-
tronics, Drives and Energy Systems for Industrial Growth, 1996., Proceedings of the
1996 International Conference on, vol. 2, New Delhi, India, Jan. 1996, pp. 1078–
1084.
[21] G. C. Paap, “Symmetrical components in the time domain and their application
topower network calculations,” IEEE Transactions on Power Systems, vol. 15, no. 2,
pp. 522–528, May 2000.
[22] S.-J. Lee, J.-K. Kang, and S.-K. Sul, “A new phase detecting method for power con-
version systemsconsidering distorted conditions in power system,” in Industry Ap-
plications Conference, 1999. Thirty-Fourth IAS Annual Meeting. Conference Record
of the 1999 IEEE, vol. 4, Phoenix, AZ, USA, 1999, pp. 2167–2172.
REFERENCES 185
[25] O. Lopez, “Space vector pulse-width modulation for multilevel multiphase voltage-
source converters,” Ph.D. dissertation, Department of Electronic Technology, Uni-
versity of Vigo, 2009.
[26] H.-S. Song and K. Nam, “Dual current control scheme for PWM converter under
unbalancedinput voltage conditions,” IEEE Transactions on Industrial Electronics,
vol. 46, no. 5, pp. 953–959, Oct. 1999.
[28] V. Kaura and V. Blasko, “Operation of a phase locked loop system under distorted
utilityconditions,” IEEE Transactions on Industry Applications, vol. 33, no. 1, pp.
58–63, Jan./Feb. 1997.
[30] P. Pillay and R. Krishnan, “Control characteristics and speed controller design for a
highperformance permanent magnet synchronous motor drive,” IEEE Transactions
on Power Electronics, vol. 5, no. 2, pp. 151–159, Apr. 1990.
[31] “IEEE Standard 1159-1995. IEEE Recommeded Practice for Monitoring Electric
Power Quality.”
[32] M. H. J. Bollen., Understanding power quality problems. Voltage sags and interru-
pions., R. J. Herrick., Ed. IEEE Press Editorial Board., 2000.
[33] “Ieee recommended practices and requirements for harmonic control in electrical
power systems. ieee std 519-1992.”
[34] K. R. Padiyar, HVDC Power Transmission Systems, ., Ed. New Age International,
1990.
[37] S. Hiti, D. Boroyevich, and C. Cuadros, “Small-signal modeling and control of three-
phase PWM converters,” in Industry Applications Society Annual Meeting, 1994.,
Conference Record of the 1994 IEEE, Denver, CO, USA, Oct. 1994, pp. 1143–1150.
[38] J. Doval-Gandoy and C. M. Penalver, “Dynamic and steady state analysis of a three
phase buck rectifier,” IEEE Transactions on Power Electronics, vol. 15, no. 6, pp.
953–959, Nov. 2000.
[40] B. Wang, G. Venkataramanan, and A. Bendre, “Unity power factor control for
three-phase three-level rectifiers without current sensors,” IEEE Transactions on
Industry Applications, vol. 43, no. 5, pp. 1341–1348, Sep./Oct. 2007.
[41] P. Verdelho and G. D. Marques, “An active power filter and unbalanced current
compensator,” IEEE Transactions on Industrial Electronics, vol. 44, no. 3, pp. 321–
328, Jun. 1997.
[43] V. Soares, P. Verdelho, and G. D. Marques, “An instantaneous active and reactive
current component method foractive filters,” IEEE Transactions on Power Elec-
tronics, vol. 15, no. 4, pp. 660–669, Jul. 2000.
[56] E. Monmasson and M. N. Cirstea, “Fpga design methodology for industrial control
systems—a review,” IEEE Transactions on Industrial Electronics, vol. 54, no. 4, pp.
1824–1842, Aug. 2007.
[59] P. Verdelho and G. D. Marques, “DC voltage control and stability analysis of
PWM-voltage-typereversible rectifiers,” IEEE Transactions on Industrial Electron-
ics, vol. 45, no. 2, pp. 263–273, Apr. 1998.
[61] J. Millman and H. Taub, Pulse, Digital and Switching Waveforms, M. G. Hill, Ed.
Mc Graw Hill International, 1965.
[65] J. D. Ainsworth, “Harmonic instability between controlled static convertors and a.c.
networks,” Proceedings of the IEE, vol. 114, pp. 949–957, 1967.
[67] R. Arockiasamy and S. Doraipandy, “A novel trigger scheme for thyristor operating
under variable-frequency anode supply,” IEEE Transactions on Industrial Electron-
ics and Control Instrumentation, vol. 22, no. 1, pp. 83–85, Feb. 1975.
[68] S. Murugesan and C. K. Rao, “Simple adaptive analog and digital trigger circuits
for thyristors working under wide range of supply frequencies,” IEEE Transactions
on Industrial Electronics and Control Instrumentation, vol. 24, no. 1, pp. 46–49,
Feb. 1977.
[70] O. Vainio and S. J. Ovaska, “Noise reduction in zero crossing detection by predictive
digitalfiltering,” IEEE Transactions on Industrial Electronics, vol. 42, no. 1, pp. 58–
62, Feb. 1995.
[72] A. Ekstrom and G. Liss, “A refined HVDC control system,” IEEE Transactions on
Power Apparatus and Systems, vol. 89, no. 5, pp. 723–732, May 1970.
[74] R. Simard and V. Rajagopalan, “Economical equidistant pulse firing scheme for
thyristorized DC drives,” IEEE Transactions on Industrial Electronics and Control
Instrumentation, vol. 22, no. 3, pp. 425–429, Aug. 1975.
[75] G.-C. Hsieh and J. C. Hung, “Phase-locked loop techniques. a survey,” IEEE Trans-
actions on Industrial Electronics, vol. 43, no. 6, pp. 609–615, Dec. 1996.
REFERENCES 189
[77] B. K. Bose and K. J. Jentzen, “Digital speed control of a DC motor with phase-
locked loop regulation,” IEEE Transactions on Industrial Electronics and Control
Instrumentation, vol. 25, no. 1, pp. 10–13, Feb. 1978.
[78] R. E. Best, Phase Locked Loops. Design, Simulation and Applications. 4th Edition.
McGraw-Hill, 1999.
[81] F. J. Bourbeau, “LSI based three-phase thyristor firing circuit,” IEEE Transactions
on Industry Applications, vol. 19, no. 4, pp. 571–578, Jul. 1983.
[85] A. Gole, V. K. Sood, and L. Mootoosamy, “Validation and analysis of a grid control
system using d-q-z transformation for static compensator systems,” in Proc. Can.
Conf. Elect. Comput. Eng., 1989, pp. 745–748.
[86] A. M. Gole and V. K. Sood, “A static compensator model for use with electro-
magnetic transients simulation programs,” IEEE Transactions on Power Delivery,
vol. 5, no. 3, pp. 1398–1407, Jul. 1990.
[87] V. Blasko, J. C. Moreira, and T. A. Lipo, “A new field oriented controller utilizing
spatial positionmeasurement of rotor end ring current,” in Power Electronics Spe-
cialists Conference, 1989. PESC ’89 Record., 20th Annual IEEE, Milwaukee, WI,
USA, Jun. 1989, pp. 295–300.
[89] T. Ahmed, K. Nishida, and M. Nakaoka, “Advanced control of PWM converter with
variable-speed induction generator,” IEEE Transactions on Industry Applications,
vol. 42, no. 4, pp. 934–945, Jul./Aug. 2006.
190 REFERENCES
[94] A. Timbus, “Grid monitoring and advanced control of distributed power generation
systems,” Ph.D. dissertation, Aalborg University, Institute of Energy Technology,
2007.
[99] S.-K. Chung, “A phase tracking system for three phase utility interface inverters,”
IEEE Transactions on Power Electronics, vol. 15, no. 3, pp. 431–438, May 2000.
[101] P. Rodriguez, L. Sainz, and J. Bergas, “Synchronous double reference frame PLL
applied to a unified power quality conditioner,” in Harmonics and Quality of Power,
2002. 10th International Conference on, vol. 2, Oct. 2002, pp. 614–619.
[102] H. Awad, J. Svensson, and M. J. Bollen, “Phase-locked loop for static series com-
pensator,” in Proceedings of EPE Conference, 2003.
[103] ——, “Tuning software phase-locked loop for series-connected converters,” IEEE
Transactions on Power Delivery, vol. 20, no. 1, pp. 300–308, Jan. 2005.
[114] ——, “Tuning of phase locked loops for power converters under distorted utility
conditions,” To be published in IEEE Transactions on Industry Applications, vol. .,
pp. 1–9, Nov. 2009.
[116] H. Awad and J. Svensson, “Compensation of unbalanced voltage dips using vector-
controlled static series compensator with LC-filter,” in Industry Applications Con-
ference, 2002. 37th IAS Annual Meeting. Conference Record of the, vol. 2, 2002, pp.
904–910.
[117] H. Awad, J. Svensson, and M. J. Bollen, “Tuning software phase-locked loop for
series-connected converters,” IEEE Transactions on Power Delivery, vol. 20, no. 1,
pp. 300–308, Jan. 2005.
[119] S. Fukuda and T. Yoda, “A novel current-tracking method for active filters based
on asinusoidal internal model [for PWM invertors],” IEEE Transactions on Industry
Applications, vol. 37, no. 3, pp. 888–895, May/Jun. 2001.
[124] R. Cutri and L. Matraska Jr, “A fast instantaneous method for sequence extraction,”
in Ninth Brazilian Conference on Power Electronics, 2007.
[125] G. H. Jung, G. C. Cho, S. W. Hong, and G. H. Cho, “DSP based control of high
power static VAr compensator using novelvector product phase locked loop,” in
Power Electronics Specialists Conference, 1996. PESC ’96 Record., 27th Annual
IEEE, vol. 1, Baveno, Italy, Jun. 1996, pp. 238–243.
[126] D. Jovcic, “Phase locked loop system for FACTS,” IEEE Transactions on Power
Systems, vol. 18, no. 3, pp. 1116–1124, Aug. 2003.
[129] L. N. Arruda, S. M. Silva, and B. J. C. Filho, “PLL structures for utility con-
nected systems,” in Industry Applications Conference, 2001. Thirty-Sixth IAS An-
nual Meeting. Conference Record of the 2001 IEEE, vol. 4, Chicago, IL, USA,
Sep./Oct. 2001, pp. 2655–2660.
[132] M. Ciobotaru, R. Teodorescu, and V. G. Agelidis, “Offset rejection for PLL based
synchronization in grid-connected converters,” in Applied Power Electronics Con-
ference and Exposition, 2008. APEC 2008. Twenty-Third Annual IEEE, Austin,
TX„ Feb. 2008, pp. 1611–1617.
[133] S. Shinnaka, “A robust single-phase PLL system with stable and fast tracking,”
IEEE Transactions on Industry Applications, vol. 44, no. 2, pp. 624–633, Mar./
2008.
194 REFERENCES
[154] A. Nakata, A. Ueda, and A. Torii, “A method of current detection for an active
power filter applyingmoving average to pq-theory,” in Power Electronics Specialists
Conference, 1998. PESC 98 Record. 29th Annual IEEE, vol. 1, Fukuoka, Japan,
May 1998, pp. 242–247.
[156] M. Albu and G. Heydt, “On the use of RMS values in power quality assessment,”
IEEE Transactions on Power Delivery, vol. 18, no. 4, pp. 1586–1587, Oct. 2003.
[159] S. W. Smith, The Scientist and Engineer’s Guide to Digital Signal Processing., .,
Ed. California Technical Publishing, 1998.
[160] E. Acha and M. Madrigal, Power Systems Harmonics, J. Willey, Ed. Jonh Willey
& Sons, Ltd, 2001.
[165] K. Zhou, K.-S. Low, D. Wang, F.-L. Luo, B. Zhang, and Y. Wang, “Zero-phase odd-
harmonic repetitive controller for a single-phase PWM inverter,” IEEE Transactions
on Power Electronics, vol. 21, no. 1, pp. 193–201, Jan. 2006.
[166] M. D. Kusljevic, “A simple method for design of adaptive filters for sinusoidal
signals,” IEEE Transactions on Instrumentation and Measurement, vol. 57, no. 10,
pp. 2242–2249, Oct. 2008.
[167] L.-P. Chau and W.-C. Siu, “Direct formulation for the realization of discrete cosine
transformusing recursive structure,” IEEE Transactions on Circuits and Systems
II: Analog and Digital Signal Processing, vol. 42, no. 1, pp. 50–52, Jan. 1995.
[168] J.-F. Yang and C.-P. Fan, “Recursive discrete cosine transforms with selectablefixed-
coefficient filters,” IEEE Transactions on Circuits and Systems II: Analog and Dig-
ital Signal Processing, vol. 46, no. 2, pp. 211–216, Feb. 1999.
[169] ——, “Compact recursive structures for discrete cosine transform,” IEEE Trans-
actions on Circuits and Systems II: Analog and Digital Signal Processing, vol. 47,
no. 4, pp. 314–321, Apr. 2000.
[170] C.-H. Chen, B.-D. Liu, J.-F. Yang, and J.-L. Wang, “Efficient recursive structures
for forward and inverse discrete cosine transform,” IEEE Transactions on Signal
Processing, vol. 52, no. 9, pp. 2665–2669, Sep. 2004.
[171] R. E. Kalman, “A new approach to linear filtering and prediction problems,” Trans-
actions on ASME, Journal of Basic Engineering, vol. 82, pp. 33–45, 1960.
[172] B. Widrow and M. E. Hoff, “Adaptive switching circuits,” in IRE WESCON Con-
vention Records, 1960.
REFERENCES 197
[175] P. K. Dash, D. P. Swain, A. C. Liew, and S. Rahman, “An adaptive linear com-
biner for on-line tracking of power systemharmonics,” IEEE Transactions on Power
Systems, vol. 11, no. 4, pp. 1730–1735, Nov. 1996.
[176] H.-S. Song, H.-G. Park, and K. Nam, “An instantaneous phase angle detection
algorithm under unbalancedline voltage condition,” in Power Electronics Specialists
Conference, 1999. PESC 99. 30th Annual IEEE, vol. 1, Charleston, SC, USA, Aug.
1999, pp. 533–537.
[177] H.-S. Song, K. Nam, and P. Mutschler, “Very fast phase angle estimation algorithm
for a single-phase system having sudden phase angle jumps,” in Industry Applica-
tions Conference, 2002. 37th IAS Annual Meeting. Conference Record of the, vol. 2,
2002, pp. 925–931.
[178] H.-S. Song, R. Keil, P. Mutschler, J. van der Weem, and K. Nam, “Advanced con-
trol scheme for a single-phase PWM rectifier in traction applications,” in Industry
Applications Conference, 2003. 38th IAS Annual Meeting. Conference Record of the,
vol. 3, Oct. 2003, pp. 1558–1565.
[180] B. Han and B. Bae, “Novel phase-locked loop using adaptive linear combiner,” IEEE
Transactions on Power Delivery, vol. 21, no. 1, pp. 513–514, Jan. 2006.
[190] C.-H. Huang, C.-H. Lee, K.-J. Shih, and Y.-J. Wang, “Frequency estimation of
distorted power system signals using a robust algorithm,” IEEE Transactions on
Power Delivery, vol. 23, no. 1, pp. 41–51, Jan. 2008.
[192] R. C. Dorf and R. H. Bishop, Modern Control Systems, Ninth Edition, ., Ed. Pren-
tice Hall, 2000.
[193] ., “Digital sine-wave generation using the tms320c2xx. spra179,” Texas Instruments,
Tech. Rep., 1998.
[194] D. Garcia, “Precision digital sine-wave generation with the tms32010. application
report spra007.” Texas Instruments., Tech. Rep., 1997.
[195] Y.-T. Cheng, “Tms320c62x algorithm: Sine wave generation. spra708.” Texas In-
struments, Tech. Rep., 2000.
[200] M. Liserre, R. Teodorescu, and F. Blaabjerg, “Multiple harmonics control for three-
phase grid converter systems with the use of PI-RES current controller in a rotating
frame,” IEEE Transactions on Power Electronics, vol. 21, no. 3, pp. 836–841, May
2006.
[202] R. Wu, S. B. Dewan, and G. R. Slemon, “A PWM AC-to-DC converter with fixed
switching frequency,” IEEE Transactions on Industry Applications, vol. 26, no. 5,
pp. 880–885, Sep./Oct. 1990.
[207] S.-J. Jeong and S.-H. Song, “Improvement of predictive current control performance
using online parameter estimation in phase controlled rectifier,” IEEE Transactions
on Power Electronics, vol. 22, no. 5, pp. 1820–1825, Sep. 2007.
[208] G. Abad, M. . Rodriguez, and J. Poza, “Two-level VSC based predictive direct
torque control of the doubly fed induction machine with reduced torque and flux
ripples at low constant switching frequency,” IEEE Transactions on Power Elec-
tronics, vol. 23, no. 3, pp. 1050–1061, May 2008.
[213] M. H. Bierhoff and F. W. Fuchs, “Active damping for three-phase PWM recti-
fiers with high-order line-side filters,” IEEE Transactions on Industrial Electronics,
vol. 56, no. 2, pp. 371–379, Feb. 2009.
[216] A. Luo, Z. Shuai, W. Zhu, and Z. J. Shen, “Combined system for harmonic sup-
pression and reactive power compensation,” IEEE Transactions on Industrial Elec-
tronics, vol. 56, no. 2, pp. 418–428, Feb. 2009.
[217] J. Hu, Y. He, L. Xu, and B. W. Williams, “Improved control of DFIG systems
during network unbalance using PI–r current regulators,” IEEE Transactions on
Industrial Electronics, vol. 56, no. 2, pp. 439–451, Feb. 2009.
[224] M. Bollen and I. Gu, Signal Processing of Power Quality Distrurbances, M. E. El-
Hawary, Ed. John Wiley and Sons, 2006.
[225] X. Guillaud, P. Degobert, and R. Teodorescu, “Use of resonant controller for grid-
connected converters in case of large frequency fluctuations,” in European Confer-
ence on Power Electronics and Applications, 2007, Aalborg, Sep. 2007, pp. 1–8.
[226] M. Sedighy, S. Dewan, and F. Dawson, “A robust digital current control method for
active power filters,” IEEE Transactions on Industry Applications, vol. 36, no. 4,
pp. 1158–1164, July-Aug. 2000.