%bEiF
SYsrems RESEFIRCH
Electric Power Systems Research 36 11996) 67 72
A recursive Newton Vladimir Fuculty
of’ Electrical
Engineering,
type algorithm
V. Terzija, Milenko University
qf Belgrade,
for digital frequency relaying
B. DjuriC, Nenad z. JeremiC Bulrcar
Rerolucije
7.3, PO
Box
816.
I1001
Belgrade.
Yugosluvia
Received 30 May 1995; accepted 14 September 1995
Abstract This paper presents a new recursive Newton type algorithm devoted to frequency relaying. The algorithm is designed from the nonrecursive Newton type algorithm and recursive least error squares algorithm. The frequency is estimated from the uniformly sampled voltage signal. The algorithm testing based on computer simulated and experimentally obtained data record processing confirmed the good features of the algorithm developed. Due to its computational efficiency. the algorithm is suitable for various real-time power system measurement applications. Keywords:
Frequency relaying; Data processing: Recursive algorithms
1. Introduction A generator basically controls two of the key parameters in a power system: the amount of power being generated to meet frequency specifications, and the amount of reactive power being supplied to meet voltage specifications. Norma1 load changes, which are stochastic in nature, can be absorbed by the spinning reserve in the system. Resulting from a major transfer of power either within the system or between two interconnected systems,the load requirements could significantly exceed the generation capabilities, producing a rapid system frequency drop. The change in frequency is a measureof the instantaneous balance between the generation and the load. Underfrequency relays measure frequency to detect overload, to disconnect a portion of the load automatically, to stop the frequency drop, to preserve the power system’s integrity and to prevent a power system collapse such as was experienced in the infamous 1965 Northeast Power Pool blackout in the US. With the introduction of microcomputers in substations, digital frequency measuring has become feasible. Hitherto developed digital algorithms aimed at the real-time measurement of voltage phasor and frequency deviation can be divided into two recognizable categories: (1) nonrecursive algorithms, or finite impulse response (FIR) filters, and 0378-7796:96/$15.00 0 1996 Elsevier Science S.A. All rights reserved SSDI
033%7796(95)01015-S
(2) recursive algorithms, or infinite impulse response (IIR) filters. Algorithms belonging to the first category [l-5] use a data window of a finite length and provide results depending on the data in the selectedwindow. Recursive algorithms are computationally more efficient than the corresponding nonrecursive algorithms. The recursive least error squares algorithm [6,7], the recursive form of the discrete Fourier transform [S] and Kalman filtering [9] are such examples. Statistical properties of the signal to be processed are needed for Kalman filtering, whereas the other aforementioned methods
are deterministic
in nature.
This paper proposes a recursive Newton type algorithm aimed at frequency relaying and capable of precise and fast frequency estimation over a wide range of frequency changes. Frequency is treated as an unknown parameter in the tnathematical mode1 of the voltage signal which therefore became nonlinear. This motivated the authors to apply the well-known Newton-Raphson method for solving the overdetermined system of nonlinear equations, which resulted in a nonrecursive Newton type algorithm for voltage phasor and power system frequency estimation. In order to reduce the computer requirements, using equations describing the recursive least error squares algorithm, a new recursive Newton type algorithm devoted to voltage phasor and frequency estimation is developed.
The first part of the paper refers to a basic nonlinear and time-varying model of the system voltage. The second part gives the theoretical background of the nonrecursive Newton type algorithm and the recursive least error squares algorithm. The third part presents a new recursive Newton type algorithm. The new algorithm is tested using computer simulated and experimentally obtained data records, and is presented in the fourth part of the paper.
3. Theoretical
3.1. Nonrecursit:e Newton type algorithm By uniformly sampling the voltage signal t’(t) with a sampling frequency fs = l/T Hz during a finite period of time (data window), the value of t at a discrete time index k is given by t, = kT. By taking m samples from the data window at t, = (n + l)T, a set of m (WI 3 4) nonlinear equations in four unknowns is determined:
u(k) = h(x,, tk) + [k
2. Model of the system voltage
= VOA+ Vk sin(o,tk
Let us assume the following observation model of the phase voltage at a given power system node: u(t) = h(x(t),
t) + <(f)
(1)
in which t(t) is a zero mean random noise, n(t) suitably chosen time-varying parameter vector h(n(t), t) is expressed in the following way: h(x(t),
is a and
t) = Vo(t) + V(r) sin[c0(r)t + q(t)]
(2)
From the generic model (2), a suitable parameter tor is deduced: x(t) = [Vo(t), v(t). dt),
background
vec-
q$f)l’-
(3)
where v,,(t) is the magnitude of the DC component, v(t) is the peak value of the voltage, w(t) is the angular velocity (equal to 2lrf’(t), where f(t) is the frequency) and q(t) is an arbitrary phase angle. It can be noticed that the model is a highly nonlinear function of the unknown frequency. Given a model without frequency as an unknown parameter, the nonlinearity disappears and such a problem can be solved without difficulty by means of the recursive least error squares algorithm [6]. Given voltage sample values, the following discrete representation can be used:
+ (Pi) + ;’
k=n+l,...,n+m Eq. (4) can be rewritten
in the following
(5) vector form:
u = h(x, t) + r
(6)
where u=[v(n+ I), . ., u(n + m)lT is an (m x I) measurement vector, h(w, t) = [h(x,,+ ,, t, + 1), . . , h(xntm, ,, + 171 r is an (m x 1) vector of nonlinear functions 1’ is an (m x :ivenbyEq.(4)and<=[5,,+,,.. r 1) error vector. Vector equation (;) lit be solved by employing Newton’s iteration [4]. The key relation of the iterative Newton type algorithm is given by the following equation: xi+
I =x,+J;[u-h(q,l)]
(7)
where i is an iteration index and Jr =(JjT Ji)- ‘JiT is referred to as a left pseudo-inverse of Jacobian Jj, given as J, =
V,t, cos(w,t, + q,)
Vi cOs(w$, + q,)
V,tz COS(fD,t,+
vi cos(w~I*+(pi)
p,)
sin(w,f,,, + P,) V,r,,, cos(W,, + (0,) V, Cos(W, = V,, + VA sin(w,r,
+ cpk) + ;
k = 1, 2, 3:
.
(4)
where tk, VOA, V,, c+, cpk, and 1, refer to the values t(t), Vo(t), V(t), w(t), q(t), and t at the discrete time index k. The voltage observation model excludes the existence of the higher order harmonics. Thus, to alleviate errors due to these higher order harmonics, the input voltage signal should be prefiltered before processing. If auxiliary terms are included in Eq. (2) to account for all the physical phenomena in modern power systems, a more accurate model should be achieved but it would involve an extensive number of parameters, which would increase the algorithm’s complexity.
+ v,>
The use of this algorithm necessitates inverting a (4 x 4) matrix J,‘J, (the normal-equation matrix) in each iteration. In the simplest case the number of iterations i can be reduced to i,,, = 1. The parameter vector obtained in the previous estimation (estimation k, provided by the samples belonging to the kth data window) can now be used as an initial guess in the next estimation step (provided by the samples belonging to the (k + 1)th data window), thus considerably reducing the computational burden. For the numerical algorithm derived it is important to begin the first iteration with an estimate which is close to the true parameter values. Otherwise, the scheme may be ineffi-
I’. 1’. Trr:(ja
et al. :’ Electric
Powr
cient or even diverge. For the purpose of the algorithm initialization, i.e. for the determination of the initial guess, the common least error squares algorithm can be used [lO,l 11. Further reduction of the computational burden can be realized by changing the form of the algorithm. Instead of applying the nonrecursive form of the algorithm, the recursive form can be used. The next section presents the recursive least error squares algorithm, from which the new recursive Newton type algorithm will be designed. 3.2. Recursive least error squures algorithm Given a mathematical the form
model of the input
y(t) = VT(t)3 + v(t)
signal in
where y(t) is the measurement at time t, q-‘(t) is the regression vector, 9 is the vector of unknown parameters, and v(t) is the random noise, the following quadratic criterion can be formed to estimate the unknown parameter vector 9:
where y, is the kth measurement (with sampling interval T we have y, = y(kT)) and /i is the so-called forgetting vector. The forgetting factor i imposes an exponential forgetting of old data. In the case of a constant forgetting factor A, the past samples are forgotten more slowly as the value of i. increases. By minimizing the quadratic criterion (lo), the following recursive least error squares algorithm is obtained for estimation of the unknown parameter vector 9 [12,13]: (11) (12) It can be noticed that the costly matrix inversion is avoided by introducing matrix P,,,, which is recursively updated here. A major part of the calculations in the recursive least error squares algorithm is used to update the gain k,,, = P,,,q ,,,. The elements of k,, are the timevariant gains. The algorithm requires the starting values for P, and 9,. Usually, 9, = 0 (zero vector) and P, = NI (N is a relatively large number and I is the identity matrix) are selected, as suggested in Ref. [13].
4. Recursive Newton
Resrarch
type algorithm
Taking into account Eqs. (10) and (1 l), it is not difficult to derive the recursive Newton type algorithm from the nonrecursive one (Eq. (7)):
36 (1996)
67
72
69
x,,,= Xl,,~ I + p,,,j,,,[L’,,,- k,(x,,, ~ 1,I P,,, = A P,,, ~ , /, (
P 1,1~ Ii,J,rlTP,n
, i +.i,,TP,,z ~ ,j,,, 1
(13) (14)
with , TJ ,n -
(3@,,* s,,, d@,,, M,,, i! v, ) c’v’ &id 1 &p
1
= [ 1, sin( IL),,, it,,, + cpm~ IL V1?,~ I t/u COS(% Y,,
(9)
%7 = 4, - I + p,,,%,~,>? - 40,nT~,,, I)
Systems
I
1t,,, + (Pm~ I )3
cos(wm~ It,,,+ qo,,,dl
(15)
Vector j,’ represents the nzth row of Jacobian matrix (8) with the estimates from the previous (m - 1)th iteration. Here, residual r,,, expresses the difference between c,,, and &(x,,,~ ,), i.e. r,,, = r,,-hh,(x,,,-,). The inversion of the normal equation matrix (J’J) is performing recursively through Eq. (14). The algorithm design procedure requires the appropriate choice of the following parameters: (1) sampling frequencyf, and (2) the forgetting factor R. The algorithm developed can be applied without difficulty to the extended signal models, taking into account some other phenomena occurring in a power system, e.g. decaying DC component or higher order harmonic components. The recursive Newton type algorithm has not yet been applied in the field of computer relaying, so it is extensively tested, as described in the following section.
5. Testing the recursive algorithm The algorithm presented in the previous section is tested by means of the input data obtained through the computer simulation and by using data records from a programmable pulse/function generator. The following tests are performed using computer simulated test signals: (1) static tests, (2) dynamic tests, and (3) noise tests. The testing is evaluated from the point of view of frequency estimation, so only the results of the frequency estimation will be given. 5.1. Stutic tests In this test, computer simulated sinusoidal test signals with frequencies in the range lo-200 Hz in steps of 10 Hz were provided as input to the algorithm. The sampling frequency fY = 600 Hz (12 samples per fundamental period T,, = l/50 = 0.02 s) was selected. When the initial guess is exactly selected/calculated, the true values are obtained in the frequency range defined by Shannon’s sampling theorem [14], i.e. for frequencies f
V. Y. Terziju
Fig.
1. Frequency
estimation
error
rt al. : Electric
III static
Power
Systems
Researc,h
36 (1996)
tests.
67-72
Fig. 3. Dynamic
test results
obtained after a short convergency process, lasting t,,,. For the purpose of the initial guess calculation, the nonrecursive least error squares algorithm is applied, as suggested in Ref. [l 11. In Fig. 1 the maximum frequency estimation errors E in terms of the exact input signal frequency are shown for two values of the forgetting factor i, and for incorrectly selected initial guesses. The best accuracy is achieved for i = 0.8. It would have been even better if the value 2 2 1 had been used. Further tests will give more ideas and suggestions concerning the selection of the forgetting factor E,.
vergence for the present example should be achieved if i = 0.8 is selected. The results obtained confirm a good dynamic response of the algorithm for the parameter step change. In reality, power system frequency changes slowly, so the algorithm should satisfy the frequency relaying requirements as well. The ability of the frequency estimation over a wide range of frequency changes is investigated using two sinusoidal test signals with the following time dependences: (a) j;(t) = 50 - 5r - 5t2 Hz
dj;(t)jdt
= -5 - lot Hz/s
5.2. Dynurnic
(b) f;(t)
df,(t)/dt
= 5 + lot Hz/s
tests
First, the influence of the forgetting factor i. on the algorithm’s convergence and accuracy is investigated. An input sinusoidal test signal, only frequency modulated (step frequency change from 50 to 45 Hz at t=0.02 s), is processed with ie10.5; 0.8; 0.9; 1.0). As shown in Fig. 2, faster convergence is achieved as the value of i, decreases, and the accuracy improves as 2 increases. A compromise between accuracy and con-
1 2 3 4 0
64 t~~,“~‘~“““““~“~‘L”‘~~~~‘~““‘l’~””~””’~”””i 0 00 0.04
O.D.3
estimation
lombdo=0.5 lombda=0.8 lambda=0.9 lombdo=l.O
0.16
of the forgetting
5.3. Noise tests with superimposed noise is used as an noise is selected to signal-to-noise ratio
A KsNR = 20 log __ $0
0.20
0 24
(s)
in terms
As shown in Fig. 3, somewhat larger estimation errors are obtained for t > 1.5 s as the rate of frequency took extremely high values, greater than 20 Hz/s. As stated before, the frequency measurement range is limited in practice only by Shannon’s sampling theorem [141.
A sinusoidal 50 Hz test signal additive white zero-mean Gaussian input for the test. The random obtain a prescribed value of the k4R~ defined as
- true value
0 12
time
Fig. 2. Frequency
-
= 50 + 5r + 5t2 Hz
factor
i
where A is the magnitude of the signal’s fundamental harmonic and u is the standard deviation of the noise. The maximum frequency estimation errors E in terms of k4RI with f? = 600 Hz and i~{0.5; 0.8; 0.9; 1.01, are shown in Fig. 4. The accuracy improves as 1 increases. This conclusion confirms the results obtained in the static and dynamic tests.
1 2 -
lambco=0.5 lombca=0.5
KSNR (dB) Fig. 4. Maximum ratio.
estimation
5.4. Experimentul
errors
in terms
of the signal-to-noise
test
Fig. 6. Experimental
test results.
6. Conclusion
Fig. 5 shows the block diagram of the experimental testing. The data records are obtained from a HewlettPackard HP 8 116A 50 MHz programmable pulse/function generator. The output analog signal G(t) is digitized using an 8-bit Tektronix 2430 digital oscilloscope with sampling frequency fs = 500 Hz. The actual signal frequency is measured using a Hewlett-Packard 5234L electronic counter. The recorded data c(kT) are processed offline on a PC-486. In the test the input signal frequency was changed from 50 to 47 Hz in steps of 1 Hz. The test results are displayed in Fig. 6. The main source of the errors was the quantization errors. The estimates obtained would be better if a 12-bit A/D converter were used. In addition, as pointed out in Section 2, the algorithm’s application requires signal prefiltering. From the point of view of algorithm convergence, the results presented in Fig. 6 confirm its very good properties. The estimates oscillate around the actual frequency, which could be simply avoided by using a moving-average filter.
In this paper a new recursive Newton type algorithm for estimating power system frequency is presented. It is derived from the processing of the voltage sine wave, distorted by the DC component and random noise. The theoretical background, i.e. the nonrecursive least error squares algorithm and the Newton type algorithm for frequency estimation, is given. The new algorithm is computationally more efficient than the corresponding nonrecursive algorithm. It requires the starting parameter vector to provide the algorithm’s convergence. The least error squares algorithm is suggested for the algorithm’s initialization, i.e. for the starting parameter vector calculation. Through extensive testing using computer simulated and experimental data, the main features of the algorithm and its sensitivity to the key parameters affecting its performance are investigated. The algorithm provided high measurement accuracy over a wide range of frequency changes. The results confirmed a high level of robustness and a very good dynamic response of the algorithm. The algorithm developed could be a very useful tool, not only in frequency relaying, but also in some other microprocessor based power system measurement applications.
References
liewlett Packard Eleclronlc Counier HP 52451
Fig. 5. Global
block
diagram
of the experimental
testing.
[I] M. Sachdev and M. Giray. A least error squares technique for determining power system frequency, IEEE Trans. Power Appar. Sj:sr.. PAS-IO4 (1985) 437-443. [2] S.A. Soliman. G.S. Christensen, D.H. Kelly and N. Liu, An algorithm for frequency relaying based on least absolute value approximations, Electr. Power Sysr. Res.. 19 (1990) 73-84. [3] M. KezunoviC, P. SpasojeviC and B. PeruniEiC. New digital signal processing algorithms for frequency deviation measurements, IEEE Truns. Po,tw Deliwrv, 7 (3) (1992) 1563-1573.
72
V. V. Terzgu
et ul. : Electric
Pmaer
[4] V. Terzija. M. Djuric and B. Kovacevic. Voltage phasor and local system frequency estimation using Newton type algorithm, IEEE Trans. Power Delivery, 9 (3) (1994) 1368- 1374. [5] V. Terzija, M. Djuric and KovaEevid. A new self-tuning algorithm for the frequency estimation of distorted signals, IEEE Trans. Power Delivery, 10 (4) (1995) 1779- 1785. [6] M.S. Sachdev and M. Nagpal, A recursive least square error algorithm for power system relaying and measurement applications, fEEE Trans. Power Delivery, 6 (3) (1991) 100881015. [7] I. Kamwa and R. Grondin, Fast adaptive scheme for tracking voltage phasor and local system frequency in power transmission and distribution systems, IEEE Trans. Power Delivery, 7 (2) (1992) 7899795. [8] A. Phadke, J. Thorp and M. Adamiak, A new measurement technique for tracking voltage phasors, local system frequency, and rate of change of frequency, IEEE Trans. Power Appar.
Systems
Research
36 (1996)
67-72
SJst., PAS-102 (1983) 102551038. [9] A.A. Girgis and T.L.D. Hwang, Optimal estimation of voltage phasors and frequency deviation using linear and nonlinear Kalman filtering: theory and limitations, IEEE Trans. Power Appar. Syst., PAS-103 (1984) 294332950. [lo] V. Terzija, Voltage wave frequency measurement for digital power system protection, M.Sc. Thesis, Faculty of Electrical Engineering, University of Belgrade. Yugoslavia, 1993. [I I] M. DjuriC, V. Terzija and 1. Skokljev, Power system frequency estimation utilizing the Newton-Raphson method, Arch. Elektrotech.. 77 (3) (1994) 221-226. [12] L. Ljung and T. Soderstrom, Theory and Practice of‘ Recursive Identification, MIT Press, Cambridge, MA, 1986. [I 31 R. Isermann, Prozessidentijikaiion, Springer, Berlin, 1990. [14] C.E. Shannon, Communication in the presence of noise, Proc. IRE, 37 (1949).