Mathematical basis for protective relaying algorithms
3.1 Introduction
One of the attractions of the computer relaying area is the rich combination of aca-demic disciplines upon which it is based. In addition to protective relaying itself, computer relaying depends on computer engineering for an understanding of hard-ware selection and compromises, on communication systems for an understanding of the links between devices, and on elements of digital signal processing and estima-tion theory in understanding the algorithms. To understand a number of algorithms it is necessary to understand how the Fourier series and Fourier transform are used to extract the fundamental frequency component of voltage and current waveforms.
The first few sections of this chapter are devoted to a brief presentation of Fourier series and transform ideas along with a related expansion of a signal in terms of Walsh functions. Another important concept in evaluating relay algorithms is that of estimation. Since unwanted components are generally present in the signals that are sampled, it is necessary to estimate the parameters of interest (the fundamen-tal frequency component, for example) by processing a number of samples. The remaining material in this chapter is concerned with ideas of probability, random processes, and estimation including the Kalman filter. Our treatment of all of these subjects is, of necessity, brief. The interested reader is referred to more complete books on these subjects given as references at the end of the chapter.
3.2 Fourier series
Many of the input signals such as phase voltages and currents encountered in power systems are essentially periodic. Ideally the voltages and currents present in the system in steady state are pure sinusoids at the power system frequency (50 or
Computer Relaying for Power Systems 2e by A. G. Phadke and J. S. Thorp
2009 John Wiley & Sons, Ltd
60 Hz). Some devices (for example, power transformers, inverters, converters and loads) create harmonic distortion in the steady state signals. The signals seen by protective relays also fail to be pure sinusoids. The non-fundamental frequency content of the voltage and current seen by a relay are not truly periodic but change in time. The nature of these non-fundamental frequency signals has an important bearing on the performance of relaying algorithms. The Fourier series provides a technique for examining these signals and determining their harmonic content.
A signal r(t) is said to be periodic if there is a T such that
r(t) = r(t + T); for all t (3.1)
If r(t) is periodic and not a constant then let T0 be the smallest positive value of T for which Equation (3.1) is satisfied. The period T0 is called the fundamental period of r(t). The need for a concern with the smallest such T is made clear by considering a sinusoid. If r(t) = sin(ω0t) then Equation (3.1) is satisfied for
T = 2nπ ω0
; n = 1, 2, 3, . . . (3.2)
The smallest positive value is, of course, T = 2π/ω0. Associated with the funda-mental period is a fundafunda-mental frequency defined by
ω0= 2π T0
(3.3)
Example 3.1 If
r(t) = ejω0t then Equation (3.1) requires
ejω0(t+T)= ejω0t ejω0tejω0T−1 = 0; for all t
which implies thatω0T = 2nπ; n = 1, 2, 3, . . . The conclusion is that the funda-mental period is T0 = 2π/ω0, and the fundamental frequency is ω0.
Example 3.2
The real and imaginary parts of Example 3.1, viz. cos(ω0t) and sin(ω0t), have fundamental period T0 = 2π/ω0 and fundamental frequency ω0.
Example 3.3
The periodic square wave shown in Figure 3.1 (the dots indicate the signal is periodic) has fundamental period T0 and fundamental frequencyω0= 2π/T0.
r(t)
T0/2 T0 2T0
−T0/2
••••
t
Figure 3.1 Periodic square wave
If r1(t) and r2(t) are both periodic signals with fundamental periods T0 and T1, respectively, then the sum, r1(t) + r2(t), is not necessarily periodic. Consider
r(t) = sin(t) + sin(πt).
The fundamental period of sin(t) is 2π while the fundamental period of sin(πt) is 2. It is not possible to find integers n and m such that 2m = 2πn since π is irrational (not the ratio of integers) so that there is no T that satisfies Equation (3.1). On the other hand if
r(t) = ejω0t+ e2jω0t
then the two fundamental periods differ only by a factor of two, i.e. 2π/ω0 and π/ω0. Thus the fundamental period of the sum is the larger, 2π/ω0. In fact it is easy to see that any finite sum of the form
r(t) = c0+ c1ejω0t+ c2e2jω0t+ c3e3jω0t+ · · · + cNejNω0t
is periodic with fundamental frequency ω0. Including both positive and negative terms in the sum,
r(t) =
k=N
k=−N
ckejkω0t (3.4)
is also a periodic signal with fundamental frequency ω0. The objective of Fourier analysis is to decompose an arbitrary periodic signal into components as in Equation (3.4).
3.2.1 Exponential fourier series
Given a periodic signal with fundamental frequency ω0 the exponential Fourier series is written as1
r(t) =
k=∞
k=−∞
ckejkω0t (3.5)
The task at hand is to determine the coefficients ck. An important property of the exponentials makes the calculation a simple process. Note that
T0
since ω0T0= 2π. Equation (3.6) is also true for integration over any period, i.e.
the integrand could have been from τ to τ + T0. To compute the Fourier series coefficients it is only necessary to multiply Equation (3.5) by e−jnω0t and integrate over a period:
From Equation (3.6) every term on the right hand side vanishes except the nth, yielding
Equation (3.9) can be evaluated over any period that is convenient as will be seen in example to follow.
Example 3.4
Consider the square wave of Figure 3.1. The nth coefficient is given by
cn= 1 T0
T0/2
0
e−jnω0tdt =
e−jnω0t
−jnω0T0
T0/2 0
=
e−jnω0T0/2− 1
−jnω0T0
=
e−jnπ− 1
−jn2π
= (−1)n− 1
−j2nπ cn= 1
jnπ; n odd cn= 0; n even, n = 0 c0= 1/2
The coefficient c0 (the average value of the signal) must frequently be evaluated separately. The approximations formed by the finite sum
r(t) =
k=N
k=−N
ckejkω0t
for N = 1, 3, and 5 are shown in Figure 3.2.
T0
t r(t)
Figure 3.2 Finite Fourier series approximations to the square wave
3.2.2 Sine and cosine fourier series
Through the use of the Euler identity
ejkωot= cos(kωot) + j sin(kωot) (3.10) it is possible to write the exponential series given in Equation (3.4) in terms of sines and cosines
∞ k=−∞
ckejkωot = ao+
∞ k=1
akcos(kωot) +
∞ k=1
bksin(kωot) (3.11)
where
ao= co
ak= ck+ c−kk = 0 (3.12)
bk= j(ck− c−k) k = 0 (3.13) Or, using Equation (3.9),
ak= 2 To
To
0
r(t) cos(kωot) dt (3.14)
bk= 2 To
To
o
r(t) sin(kωot) dt (3.15)
From the results of Problem 3.2, it follows that real and even signals have expan-sions of the form of Equation (3.11) with only cosine terms, while real and odd signals have such expansions with only sine terms.
Equations (3.12) and (3.13) result from expanding the kth and −kth terms of the exponential series using the Euler expansion
c−ke−jkωot+ . . . + ckejkωot= c−kcos(ωot) + ckcos(ωot)
−c−kj sin(ωot) + ckj sinωot If the Fourier series is written as
r(t) = co+ (c1ejωot+ c−1e−jωot)+ (c2e2jωot+ c−2e2jωot) . . . + (ckejkωot+ c−ke−jkωot) + . . .
the various terms can be recognized as
co the dc component (average value) (c1ejωot+ c−1e−jωot) the fundamental frequency component (ckejkωot+ c−ke−jkωot) the kth harmonic
It is possible to think of the Fourier series expansion as the resolution of a peri-odic function into its frequency components. The frequencies present in a periperi-odic function with fundamental frequencyωo are: 0(DC), ±ωo (the first harmonic), 2ω0
(the second harmonic), ±3ωo (the third harmonic), etc. The coefficient ck then rep-resents the amount of the signal at the frequency kωo. The interpretation of the Fourier series coefficients as the frequency content of the signal can be summarized by plotting the magnitudes of the coefficients versus frequency.
Example 3.5
The half-wave rectified sinusoid shown in Figure 3.3 represents a first approxima-tion to a current waveform encountered in power transformers under a condiapproxima-tion of magnetizing inrush. The fundamental frequency is ωo and the Fourier series coefficients are given by
ck= 1 To
To
0
r(t)e−jkωotdt
r(t)
t A
ωπ0 2πω0
•••
Figure 3.3 Half-wave rectified sine. An approximation to an inrush current
The coefficient c1 is found to be A/4j while all other odd ck are zero and
ck= A
π(1 − k2) : k even Hence the first few terms of the Fourier expansion are
r(t) = A π +A
2 sin(ωot) −2A
3πcos(2ωot) − 2A
15πcos(4ωot) + . . . .
3.2.3 Phasors
Given a periodic signal with fundamental frequency ωo, we can compute a fun-damental frequency phasor from the funfun-damental term in the Fourier series. If we adopt the notation that a cosine waveform is the reference signal, that is, the voltage
v(t) =√
2V cos(ωot)
corresponds to a phasor V which has angle 0, and the voltage v(t) =√
2V cos(ωot +ϕ)
corresponds to a complex phasor, Vejφ, then the fundamental frequency phasor is directly related to the first exponential Fourier series coefficient:
Vejϕ=
√2 To
To
0
v(t)e−jωotdt (3.16)
The√
2 in Equation (3.16) is due to the convention that the magnitude of a phasor is the root-mean-square (rms) value of a sinusoid but can be omitted if a ratio of voltage and current phasors (an impedance calculation) is to be computed.