Professional Documents
Culture Documents
i
) =
V I
2
sin () (3)
where the + and signs point to the load and generator
powers, respectively. For the case of multiphase sinusoidal
systems, there is no unique denition for the total reactive
power. According to the IEEE [10], the total reactive power in a
multiphase system is an algebraic sum of single-phase powers.
The active power P is a mean value in the time of the instant
power p(t) = v(t)i(t). For sinusoidal signals v(t) and i(t), it
follows that
p(t) =V sin (t +
v
)I sin (t +
i
)
=
V I
2
cos (
v
i
)
V I
2
cos (2t +
v
+
i
) (4)
P =
1
T
0
T
0
_
0
p(t)dt =
V I
2
cos (
v
i
) (5)
where T
0
= 2/. From (3)(5), it is shown that the measure-
ment of the reactive power of sinusoidal signals v(t) and i(t)
could be reduced to the measurement of the active power of
signals v
(t) and i
(t), i.e.,
v
(t) =V sin (t +
v
) (6)
i
(t) =I sin (t +
i
) (7)
where the phases of the voltage and the current are changed
such that an additional phase shift of /2 is introduced, i.e.,
i
=
v
i
(/2).
According to (4) and (5), the active power of signals v
(t)
and i
(t) amounts to
P
=
V I
2
cos (
i
) (8)
which is equal to the reactive power Q of signals v(t) and i(t)
according to denition (3). This result enables the measurement
of the fundamental reactive energy by conventional meters of
the active energy in such a way that an additional phase shift of
/2 is added between the voltage and the current prior to the
introduction of the signals into the active-energy meter.
III. PROPOSED ALGORITHM
The general block diagram of the proposed algorithm is
shown in Fig. 1. As shown, the proposed technique employs
two decoupled parts. The rst part consists of the cascade
of antialiasing cascaded-integrator-comb (CIC) and adaptive-
bandpass FIR lters to lter out the fundamental components
of voltage and current signals. The second part is used to esti-
mate the fundamental reactive-power component of the power
signals and their frequency.
A. Simultaneous Frequency and Reactive-Power Estimations
Let us suppose that the discrete voltage and current signals
v
(t) and i
n
=V sin (nT +
v
) (9)
i
n
=I sin (nT +
i
) . (10)
By multiplying voltage and current signals dened in (9) and
(10), respectively, it follows
p
n
= v
n
i
n
= QS cos (2nT +
) (11)
where
S =V I/2
Q =S cos
= S sin
i
=
2
v
+
i
.
The three consecutive samples of signal p
n
, which were
sampled at instants n 2, n 1, and n, are connected with the
3862 IEEE TRANSACTIONS ON INSTRUMENTATION AND MEASUREMENT, VOL. 60, NO. 12, DECEMBER 2011
following equation, as well as the samples of the active-power
signal p
n
in [9]:
a
T
n
x
n
= b
n
(12)
where
x
n
=
_
x
1
x
2
_
n
=
_
x
1,n
x
2,n
_
=
_
Q(1 cos (2T))
cos (2T)
_
a
n
=
_
2
2p
n1
_
b
n
=p
n
+p
n2
.
By substituting n = 1, 2, . . . , k (k > 2) in (12), we get the
following linear equation system:
Ax = b (13)
where
b =
_
_
W
k1
b
1
W
k2
b
2
. . .
b
k
_
_ A =
_
_
W
k1
a
T
1
W
k2
a
T
2
. . .
a
T
k
_
_. (14)
The weighting (forgetting) factor (0 < W < 1) is involved
to ensure higher impact on the newer samples.
The solution to (13), at instant k, based on the least-square
error method is given by
x
k
=
_
A
T
k
A
k
_
1
A
T
k
b
k
. (15)
By solving (15), the components of vector x
k
can be calcu-
lated using (16) and (17), shown at the bottom of this page.
To implement (16) and (17) in a recursive fashion, fth
accumulators are introduced, i.e.,
Acc_1
k
=W
2
Acc_1
k1
+ 1
Acc_p
k
=W
2
Acc_p
k1
+p
k
Acc_p
2
k
=W
2
Acc_p
2
k1
+p
2
k
Acc_b
k
=W
2
Acc_b
k1
+b
k
Acc_p
b
k
=W
2
Acc_p
b
k1
+p
k
b
k
(18)
x
1,k
=
1
2
Acc_p
k
Acc_b
k
+ Acc_1
k
Acc_p
b
k
Acc_1
k
Acc_p
2
k
(Acc_p
k
)
2
(19)
x
2,k
=
1
2
Acc_p
2
k
Acc_b
k
Acc_p
k
Acc_p
b
k
Acc_1
k
Acc_p
2
k
(Acc_p
k
)
2
. (20)
The results are weighted-least-mean-square estimations of
the quantities at instant k, which are based on the measurement
until instant k.
Having obtained vector x
k
, the frequency and the reactive
power are then derived by
f
k
= arccos (x
2,k
)/(4RT) (21)
Q
k
=x
1,k
/(1 x
2,k
). (22)
Equations (21) and (22) have to be only calculated in order to
form output signals. It can be noticed that the algorithm is very
simple and suitable for implementation.
The forgetting factor ensures the higher impact of new data
and the weakening of older data. The algorithm has the possi-
bility of trading speed for accuracy by specifying the forgetting
factor W
2
. The estimation can be either fast and less accurate
(for smaller W
2
) or slow and more accurate (for higher W
2
).
For W
2
= 0, the estimation is the fastest and is only based
on the last three signal samples, but in this case, the accuracy
is least. As have been shown in [9] and [11], a compromise
between accuracy and convergence for the presented example
should be achieved for the adaptation of W
2
during the estima-
tion procedure.
Let us dene a value of the residual error at the kth iteration,
which can be calculated as
e
k
= b
k
A
k
x
k
. (23)
We can dene a covariance of the estimation error as follows:
R
k
= e
T
k
e
k
= (b
k
A
k
x
k
)
T
(b
k
A
k
x
k
). (24)
Using the form of matrices b, A, and x that is given in (13)
and (14), we obtain
R
k
= W
2
k1
R
k1
+
_
b
k
a
T
k
x
k
_
2
. (25)
The forgetting factor W
2
can be calculated as follows
[9], [11]:
W
2
k
= W
min
+
W
max
W
min
1 +|R
k
/R
0
|
p
(26)
or [5]
W
2
k
= W
min
+ (W
max
W
min
)e
|R
k
/R
0
|
p
(27)
where W
min
, W
max
, R
0
, and p are the chosen values. These
parameters have to be heuristically selected, depending on the
x
1,k
=
1
2
i=0
W
2(ki)
p
i
k
i=0
W
2(ki)
b
i
+
k
i=0
W
2(ki)
k
i=0
W
2(ki)
p
i
b
i
k
i=0
W
2(ki)
k
i=0
W
2(ki)
p
2
i
_
k
i=0
W
2(ki)
p
i
_
2
(16)
x
2,k
=
1
2
k
i=0
W
2(ki)
p
2
i
k
i=0
W
2(ki)
b
i
i=0
W
2(ki)
p
i
k
i=0
W
2(ki)
p
i
b
i
k
i=0
W
2(ki)
k
i=0
W
2(ki)
p
2
i
_
k
i=0
W
2(ki)
p
i
_
2
(17)
KULJEVI
C AND POLJAK: SIMULTANEOUS REACTIVE-POWER AND FREQUENCY ESTIMATIONS 3863
signal parameters dynamic. W
min
and W
max
bound an interval
in which W
2
can take place during tuning (W
min
W
2
W
max
). Smaller W
min
allows faster but, at the same time, more
oscillatory estimation. Higher W
max
allows more accurate but,
at the same time, slower estimation. Smaller R
0
and higher p
provide faster but more oscillatory estimation.
Bad data corresponding to poor frequency and reactive-
power estimates is identied and ignored by median lters.
In contrast, the output of a linear lter is calculated from a
linear combination of data samples, including bad data. Another
advantage in median ltering is that there is no need to specify
the cutoff frequency [12].
B. Adaptive Filtering of Power System Signals
Both the troubling synchronization to the signal fundamental
frequency and the use of restricting window functions could
be avoided using adaptive digital FIR lters for sinusoidal
signals [11]. The FIR digital lters are also used to process
input voltage and current signals to minimize the noise effect
and are not affected by the presence of harmonics. It means
that the frequency response of the lters must have nulls at
the harmonic frequencies that are expected to be present in
the signal. Thus, the estimation of the frequency requires the
design of new lters at each iteration. The method proposed
in [11] uses closed forms for calculating lter coefcients. The
complete lter can be realized as a cascade of the second-order
subsections that eliminate direct-current (dc) component and all
harmonic frequencies, except the measured one for which has
to have unity gain.
The second-order subsection that eliminates the dc compo-
nent and frequency
s
/2 = /T and has unity gain at the
fundamental frequency is given by the following z-domain
transfer function [11]:
H
0
(z) =
1 z
2
|1 z
2
1
|
(28)
where |1 z
2
1
| = 2 sin (T) [11]. The subsection that rejects
harmonic
m
= m and has unity gain at the fundamental
frequency is shown as follows:
H
m
(z) =
1 2 cos (
m
T)z
1
+z
2
1 2 cos (
m
T)z
1
1
+z
2
1
, m = 2, 3, . . . , M
(29)
where |12 cos (
m
T)z
1
1
+z
2
1
| =2| cos (T)cos (mT)|
[11], where M denotes the maximum integer part of
S
/(2).
It is equal to the number of the subsections in cascade.
The transfer function of the complete lter is given as
follows:
H
1
(z) = H
0
(z)
M
m=2
H
m
(z). (30)
It is shown that a calculation of the lter coefcients can be
easily implemented if the fundamental frequency is known.
Particularly convenient are the algorithms for the frequency
measurement where either cos (T) or cos (2T) is directly
Fig. 2. Frequency responses of the rst harmonic lter for different funda-
mental frequencies and the sampling frequency of fs = 800 Hz.
estimated, such is that in the previously described algorithm. In
this case, cos (mT) can be easily calculated using trigonomet-
ric formulas.
The frequency responses of the lters for the fundamental
harmonic for different fundamental frequencies and a sam-
pling frequency of f
s
= 800 Hz (16 samples per period; T
0
=
1/50 = 0.02 s) are given in Fig. 2.
C. Adaptive Phase Shifter
The measurement of the reactive power under sinusoidal
conditions, according to the IEEE denition [10], requires the
introduction of a phase shift of /2 exactly between the voltage
and current signals. This phase shift should be equal to /2
exactly and should be independent on the frequency of the
input signals. [13] describes a digital realization of a circuit
for an additional phase shift of /2 between input signals,
with a constant amplication nondependent on the frequency.
A versatile method for high-precision frequency-insensitive
quadrature phase shifting is described in [14].
A phase shift corrector with the following transfer function
can perform a phase shift of /2 on the fundamental fre-
quency [6], [11]:
H
PHSH
_
z,
2
_
=
cos (T) +z
1
sin (T)
. (31)
The cascade connection of the phase shift corrector, i.e.,
(31) and lter (30), gives a new lter that, together with lter
(30), forms an orthogonal pair for the fundamental frequency
[11], i.e.,
H
2
(z) = H
PHSH
_
z,
2
_
H
0
(z)
M
m=2
H
m
(z). (32)
D. Decimation Filtering
In the case of signals with a low signal-to-noise ratio (SNR),
the accuracy of the algorithm can be further improved by
the oversampling of the input signal combined with high-
order antialiasing lters and decimation. Each doubling of the
sampling frequency will lower the in-band noise by 3 dB and
will increase the resolution of the measurement by 1/2 bit [15].
In addition, implementation problems regarding coefcient
sensitivity for large-order FIR cascade comb lters are present.
On the other hand, the low-pass lter (LPF) cannot eliminate
all harmonic components unless a high-order LPF is selected.
3864 IEEE TRANSACTIONS ON INSTRUMENTATION AND MEASUREMENT, VOL. 60, NO. 12, DECEMBER 2011
Fig. 3. Frequency responses of the CIC lters for different numbers of stages
in cascade and fs = 6400 Hz and D = 8.
In the case of choosing a high-order LPF, the transient response
of the frequency estimation method decreases, which is not
desired. Fortunately, good properties could be achieved by the
cascade connection of the antialiasing LPF with the cutoff
frequency that is high enough to ensure fast response (up to
816 harmonics) and the reduced-order FIR comb lter that is
applied on the decimated signal. This way, both coefcient sen-
sitivity problems will be avoided, and the parameter estimation
accuracy will be improved.
The CIC lters are computationally efcient implementa-
tions of narrow-band LPF and are often embedded in hardware
implementations of decimation and interpolation in modern
communications systems. The CIC lters were introduced to
the signal processing community about three decades ago,
but their application possibilities have grown in the recent
years. Improvements in chip technology, the increased use of
polyphase ltering techniques, advances in deltasigma con-
verter implementations, and the signicant growth in wireless
communications have all spurred much interest in CIC lters
[15], [16].
The CIC lters originate from the notion of a recursive
running-sum lter, which is itself an efcient form of a
nonrecursive moving averager. A z-domain H
CIC
(z) transfer
function of the CIC lter for the D-point moving-average
process is
H
CIC
(z) =
1
D
1 z
D
1 z
1
. (33)
The most common method to improve the CIC lter an-
tialiasing and image-reject attenuation is by increasing order
S of the CIC lter using multiple stages. For S CIC stages
in cascade, the overall frequency magnitude response is the
product of their individual responses, or [16]
H
CIC,Sthorder
(e
j2f
)
2), where
A is the magnitude of the signal fundamental harmonics and
is the noise standard deviation. The results obtained conrm the
good dynamic response of the algorithm for the frequency step
change, as well as the accuracy of parameter estimation. We
have a technique that provides accurate estimates for SNR =
60 dB with the frequency estimation error in the range of
0.002 Hz and the reactive-power estimation errors in the range
of 0.03% with respect to the fundamental apparent power, in
about 25 ms (see Fig. 4). A comparison is made between the
proposed and FFT-based techniques. Note that sliding frames
of the incoming samples for computing the FFT are collected.
A total of 128 input samples (one fundamental period) are used
to generate the magnitudes of 128 complex FFT values. It can
be noted that the proposed algorithm has much less estimation
error compared with the FFT-based algorithm.
The ability of the frequency and reactive-power estimations
over a wide range of frequency changes is investigated using
a sinusoidal test signal with the time dependence of f(t) =
50 + 0.5 sin (10t). This situation exceeds the real power-line
frequency deviation and rate of change. The estimation is
shown in Fig. 5. The good dynamic responses and the high
KULJEVI
C AND POLJAK: SIMULTANEOUS REACTIVE-POWER AND FREQUENCY ESTIMATIONS 3865
Fig. 5. Frequency and reactive-power estimations for y(t) = sin (2ft),
where f(t) = 50 + 0.5 sin (10t) and SNR = 60 dB.
Fig. 6. Maximum estimation errors for noisy input signals.
accuracy of measurement can be noticed. The arguments and
the conclusions of the preceding frequency-step-change case
are conrmed again in this experiment.
The effect of the noise presence in the signals was studied by
estimating the frequency and the reactive power of signals that
contain noise. A sinusoidal 50-Hz input test signal with the su-
perimposed additive white zero-mean Gaussian noise was used
as input for the test. The random noise was selected to obtain
a prescribed value of the SNR. The maximum reactive-power
estimation errors in terms of the SNR in the range 4070 dB,
when the decimation factors were 2, 4, and 8 (the sampling
frequencies were 3200, 6400, and 12800 Hz, respectively) so
that the reduced sampling frequency was always 1600 Hz, are
shown in Fig. 6. As shown, the uncertainty of the reactive-
power estimation smoothly increases with a decrease in the
Fig. 7. Maximum estimation errors for the harmonic presence.
SNR, but very little error is expected for the noise level that
is usually present in practice. The maximum error for R = 8,
as shown in Fig. 6, is about 0.28% with a low SNR of 40 dB.
The estimation method with R = 2 gave a maximumerror of up
to about 0.50% for waveforms in a similar noise environment.
This comparison indicates better performance of the proposed
method for a higher decimation factor.
To demonstrate the effectiveness of the proposed technique
in estimating the frequency and the reactive power in the
presence of harmonics, an input signal having a fundamental
frequency of 50 Hz, a third-harmonic component in the range
from 0% to 20%, and a fth-harmonic component equal to
half of the third component have been used. Fig. 7 shows
the maximum errors for the proposed technique when the
decimation factors of 2, 4, and 8 (the sampling frequencies of
3200, 6400, and 12 800 Hz, respectively) having 0%, 5%, 10%,
15%, and 20% third harmonic were used. The errors of estimate
values are nearly zero despite the presence of the harmonic
component. It can be noted that the proposed algorithm has
very small reactive-power estimation errors (30 ppm). The
errors of estimate values are nearly zero despite the presence
of harmonic components. As shown, the performance of the
proposed method does not depend on the number of the present
phase signals and the level of the harmonic disturbances.
V. EXPERIMENTAL RESULTS
The proposed algorithm has been tested by means of the
rapid prototyping system that had been developed. The com-
puter controls the experimental procedure using the LabView
software package. The environment of LabView is very friendly
for developing programs using graphical programming lan-
guage. LabView offers analysis and mathematical routines that
natively work together with data acquisition functions and
display capabilities so that they can be easily built into
any application. In addition, LabView offers analysis routines
3866 IEEE TRANSACTIONS ON INSTRUMENTATION AND MEASUREMENT, VOL. 60, NO. 12, DECEMBER 2011
TABLE I
TEST CONDITIONS. (a) FUNDAMENTAL VOLTAGE: V
1
= 230 V; PHASE = 0