103
i Mixed Model Predictive Control with Energy Function Design for Power System Mana Tavahodi B.Eng (Electronics Engineering) M.Eng (Electrical Engineering) This thesis submitted in partial fulfilment of the requirement for the degree of Master of Engineering Centre for Built Environment and Engineering Research School of Engineering Systems Faulty of Built Environment and Engineering Queensland university of Technology 2007

Mana Tavahodi Thesis

Embed Size (px)

DESCRIPTION

prictive control

Citation preview

Page 1: Mana Tavahodi Thesis

i

Mixed Model Predictive Control with Energy

Function Design for Power System

Mana Tavahodi

B.Eng (Electronics Engineering)

M.Eng (Electrical Engineering)

This thesis submitted in partial fulfilment of the requirement for the degree of

Master of Engineering

Centre for Built Environment and Engineering Research

School of Engineering Systems

Faulty of Built Environment and Engineering

Queensland university of Technology

2007

Page 2: Mana Tavahodi Thesis

ii

Statement of Original Authorship

The work contained in this thesis has not been previously submitted for a

degree or diploma at any other education institution. To the best of my

knowledge and belief, the thesis contains no material previously published or

written by another except where due reference is made.

Signed:-------------------------------------

Date:----------------------------------------

Page 3: Mana Tavahodi Thesis

iii

Acknowledgement

The work on this thesis has been a challenging, inspiring and interesting

experience. I would like to express my sincerest appreciation to my principal

supervisor, Prof. Gerard Ledwich, for his patient, time and guidance during my

studies’ period. He has been one of the best supervisors throughout my

academic career. His endless support guided me to complete this thesis. I

would also like to thank my associate supervisor Dr. Ed Palmer, for his valuable

support and help.

I would like to thank the administration staff, secretarial staff and postgraduate

students of the school of Electrical and Electronic Systems Engineering, for

providing a helpful environment.

Finally, I would like to express my deepest gratitude to my parents, for their

patience, encouragement and their support. Without their generosity, I may

never have been able to survive and complete my studies.

Page 4: Mana Tavahodi Thesis

1

Abstract

For reliable service, a power system must remain stable and capable of withstanding

a wide range of disturbances especially for the large interconnected systems. In the

last decade and a half and in particular after the famous blackout in N.Y. U.S.A.

1965, considerable research effort has gone in to the stability investigation of power

systems. To deal with the requirements of real power systems, various stabilizing

control techniques were being developed over the last decade. Conventional control

engineering approaches are unable to effectively deal with system complexity,

nonlinearities, parameters variations and uncertainties.

This dissertation presents a non-linear control technique which relies on prediction of

the large power system behaviour. One example of a large modern power system

formed by interconnecting the power systems of various states is the South-Eastern

Australian power network made up of the power systems of Queensland, New South

Wales, Victoria and South Australia. The Model Predictive Control (MPC) for the total

power system has been shown to be successful in addressing many large scale

nonlinear control problems. However, for application to the high order problems of

power systems and given the fast control response required, total MPC is still

expensive and is structured for centralized control.

This thesis develops a MPC algorithm to control the field currents of generators

incorporating them in a decentralized overall control scheme. MPC decisions are

based on optimizing the control action in accordance with the predictions of an

identified power system model so that the desired response is obtained. Energy

Function based design provides good control for direct influence items such as SVC

(Static Var Compensators), FACTS (Flexible AC Transmission System) or series

compensators and can be used to define the desired flux for generator.

Page 5: Mana Tavahodi Thesis

2

The approach in this thesis is to use the design flux for best system control as a

reference for MPC. Given even a simple model of the relation between input control

signal and the resulting machine flux, the MPC can be used to find the control

sequence which will start the correct tracking. The continual recalculation of short

time optimal control and then using only the initial control value provides a form of

feedback control for the system in the desired tracking task but in a manner which

retains the nonlinearity of the model.

Page 6: Mana Tavahodi Thesis

3

Table of Contents

ABSTRACT ............................................................................................................................. 1

TABLE OF CONTENTS........................................................................................................ 3

TABLE OF FIGURES ............................................................................................................ 5

1. INTRODUCTION ............................................................................................................... 7

1.1 MOTIVATION................................................................................................................... 7 1.2 APPROACHES AND AIMS................................................................................................. 9 1.3 THESIS LAYOUT............................................................................................................. 11 1.4 PUBLICATION ................................................................................................................ 12 REFERENCE ............................................................................................................................ 13

2. POWER SYSTEM STABILITY...................................................................................... 15

2.1 INTRODUCTION................................................................................................................. 15 2.2 POWER-ANGLE ................................................................................................................. 17 2.3 THE SWING EQUATION ..................................................................................................... 18 2.4 MULTI-MACHINE MODEL................................................................................................. 22 2.5 EXCITATION SYSTEM ....................................................................................................... 23 2.5.1 RELATION BETWEEN EXCITER AND STABILITY............................................................... 23 2.5.2 EXCITER MODEL ............................................................................................................. 24 2.6 ANGLE STABILITY ............................................................................................................ 25 2.6.1 SMALL SIGNAL STABILITY .............................................................................................. 25 2.6.2 TRANSIENT STABILITY.................................................................................................... 27 2.7 ENERGY FUNCTION DESIGN ............................................................................................ 29 REFERENCES .......................................................................................................................... 32

3. MODEL PREDICTIVE CONTROL (MPC) .................................................................. 33

3.1 INTRODUCTION ............................................................................................................. 33 3.2 MPC METHODOLOGY ...................................................................................................... 34 3.3 MPC ELEMENTS ............................................................................................................... 36 3.3.1 THE PROCESS MODEL ...................................................................................................... 36 3.3.2 THE COST FUNCTION....................................................................................................... 38 3.3.3 THE OPTIMAL CONTROL.................................................................................................. 39 3.4 THE OPTIMIZER............................................................................................................ 39 3.6 THE APPLICATION OF MPC IN POWER SYSTEM.......................................................... 40 REFERENCE: ........................................................................................................................... 45

4. KALMAN FILTER........................................................................................................... 46

4.1 INTRODUCTION ............................................................................................................. 46 4.2 THE DISCRETE KALMAN FILTER................................................................................. 47 4.3 THE DISCRETE-TIME EXTENDED KALMAN FILTER (EKF) ....................................... 51

Page 7: Mana Tavahodi Thesis

4

4.4 SUMMARY...................................................................................................................... 54 REFERENCE: ........................................................................................................................... 55

5. CENTRALIZED MPC...................................................................................................... 56

5.1 SINGLE MACHINE INFINITE BUS (SMIB) .................................................................... 56 5.2 CENTRALIZED MPC FOR SMIB SYSTEM........................................................................ 59 5.3 TYPICAL EXCITATION CONTROLLER FOR SMIB SYSTEM ............................................. 65 5.4 SUMMARY...................................................................................................................... 68 REFERENCES .......................................................................................................................... 69

6. NOVEL DECENTRALIZED MPC APPROACH ......................................................... 70

6.1 COMBINATION OF DECENTRALISE MPC AND ENERGY FUNCTION DESIGN IN MULTI-MACHINE SYSTEM................................................................................................................... 71 6.2. APPLICATION TO MULTI-MACHINE SYSTEM................................................................ 73 6.3 KALMAN FILTER DESIGN ................................................................................................. 77 6.4 FIELD VOLTAGE PREDICTION UNIT................................................................................. 81 6.5 MPC UNIT ......................................................................................................................... 82

7. LIMITATION IN CURRENT APPROACH.................................................................. 88

7.1 SAMPLE TIME EFFECTS .................................................................................................... 88 7.2 COMMENTARY.................................................................................................................. 91

8. CONCLUSIONS................................................................................................................ 92

8.1 SUMMARY OF THE RESULTS......................................................................................... 93 8.1.1 CENTRALIZED MPC IN SMIB SYSTEM ........................................................................... 93 8.1.2 COMBINATION OF DECENTRALIZE MPC AND ENERGY FUNCTION DESIGN IN THREE-MACHINE SYSTEM .................................................................................................................... 93 8.2 CONTRIBUTION OF THIS THESIS................................................................................... 94 8.3 FUTURE RESEARCH ...................................................................................................... 95

BIBLIOGRAPHY ................................................................................................................. 96

APPENDIX MATLAB CODES (ON CD)......................................................................... 100

Page 8: Mana Tavahodi Thesis

5

Table of Figures

FIGURE 1: CONTROL STRUCTURE .........................................................................................................10 FIGURE 2.1: STABILITY CLASSIFICATION...............................................................................................16 FIGURE 2.2: TORQUE-ANGLE CHARACTERISTICS .................................................................................18 FIGURE 2.3: A) EQUAL-AREA CRITERION- SUDDEN CHANGE IN LOAD [3] .............................................21 B) EQUAL-AREA CRITERION- MAXIMUM POWER LIMIT [3] .......................................................................21 FIGURE 2.4: BLOCK DIAGRAM OF TYPE 1 EXCITATION SYSTEM ...........................................................24 FIGURE 2.5: EXCITER SATURATION CURVE ..........................................................................................25 FIGURE 2.6: SINGLE MACHINE INFINITE BUS, THREE-PHASE FAULT AT F.............................................28 FIGURE 3.1: MPC STRUCTURE ............................................................................................................35 FIGURE3.2: THE STEP RESPONSE OF THE LINEAR SECOND ORDER SYSTEM........................................41 FIGURE 4.1: KALMAN FILTER STRUCTURE ............................................................................................49 FIGURE 5.1: SINGLE MACHINE INFINITE BUS .........................................................................................56 FIGURE 5.2: UNCONTROLLED ANGLE BEHAVIOUR OF THE BASIC SMIB SYSTEM.................................60 FIGURE 5.2: MPC STRUCTURE.............................................................................................................61 FIGURE 5.3: CONTROLLED ANGLE BEHAVIOUR OF THE SMIB SYSTEM BY CENTRALIZED MPC..........61 FIGURE 5.4: POINT BY POINT CONTROL VALUE .....................................................................................62 FIGURE 5.5: COST FUNCTION VALUE THROUGH THE SIMULATION........................................................62 FIGURE 5.6: UNCONTROLLED ANGLE BEHAVIOR OF THE BASIC SMIB SYSTEM ...................................63 FIGURE 5.7: ANGLE BEHAVIOR OF THE SMIB SYSTEM CONTROLLED BY MPC ...................................64 FIGURE 5.8: ANGLE BEHAVIOUR OF THE SMIB SYSTEM CONTROLLED BY MPC WORKING IN NON-

LINEAR REGION .............................................................................................................................64 FIGURE 5.9: ANGLE BEHAVIOUR OF THE SMIB SYSTEM CONTROLLED BY MPC WORKING IN NON-

LINEAR REGION .............................................................................................................................65 FIGURE 5.10: THE POLE-ZERO PLACEMENT OF THE MACHINE .............................................................66 FIGURE 5.11: COMPENSATOR DESIGN ..................................................................................................66 FIGURE 5.12: ANGLE AFTER APPLYING A TYPICAL EXCITATION CONTROLLER .....................................67 FIGURE 5.13: VALUE OF A TYPICAL EXCITATION CONTROLLER .............................................................67 FIGURE 6.1: CONTROL STRUCTURE ......................................................................................................71 FIGURE 6.2: THREE MACHINES STRUCTURE.........................................................................................73 FIGURE 6.3: ANGLE DIFFERENCE BEHAVIOR WITHOUT ANY CONTROLLER...........................................76 FIGURE 6.4: DISCRETE TIME KALMAN ERROR.......................................................................................78 (C) 78 FIGURE 6.5: ANGLE DIFFERENCE OF THE REAL SYSTEM AND THE ESTIMATE ANGLE BY DISCRETE TIME

KALMAN FILTER .............................................................................................................................78 FIGURE 6.5: EXTENDED KALMAN FILTER ERROR..................................................................................80 FIGURE 6.6: ANGLE DIFFERENCE OF THE REAL SYSTEM AND THE ESTIMATE ANGLE BY EXTENDED

KALMAN FILTER .............................................................................................................................80

Page 9: Mana Tavahodi Thesis

6

FIGURE 6.7: A) DESIGNED FIELD VOLTAGE PREDICTION FOR MACHINE 2 ............................................82 B) DESIGNED FIELD VOLTAGE PREDICTION FOR MACHINE 3 ..................................................................82 FIGURE 6.8: A) REAL SYSTEM FIELD VOLTAGE TRACKS THE DESIRED FIELD VOLTAGE IN MACHINE 283 B) REAL SYSTEM FIELD VOLTAGE TRACKS THE DESIRED FIELD VOLTAGE IN MACHINE 3.......................83 FIGURE 6.9: CONTROL VALUES OF BOTH CONTROLLERS IN MACHINE 2 AND 3....................................83 FIGURE 6.10: ANGLE DIFFERENCE BEHAVIOUR OF THE MACHINES......................................................84 FIGURE 6.11: SATURATION FUNCTION AND THE FIELD VOLTAGE PREDICTION OF MACHINE 2 .............85 FIGURE 6.12: CONTROL VALUES OF BOTH CONTROLLERS IN MACHINE 2 AND 3 .................................85 FIGURE 6.13: A) REAL SYSTEM FIELD VOLTAGE TRACKS THE DESIRED FIELD VOLTAGE IN MACHINE 2

......................................................................................................................................................86 B) REAL SYSTEM FIELD VOLTAGE TRACKS THE DESIRED FIELD VOLTAGE IN MACHINE 3.......................86 FIGURE 6.14: ANGLE DIFFERENCE BEHAVIOUR OF THE MACHINES......................................................86 FIGURE 7.1: ROOT LOCUS OF THE SYSTEM ..........................................................................................89 FIGURE 7.2: VELOCITY CHANGES TO THE α ........................................................................................89 FIGURE 7.3: ROOT LOCUS OF THE SYSTEM ..........................................................................................90 FIGURE 7.4: VELOCITY CHANGES TO THE α ........................................................................................90

Page 10: Mana Tavahodi Thesis

7

Chapter 1

1. Introduction

1.1 Motivation

The reliability of a power system has been an important topic of study in recent

decades. Power system stability has been recognized as a factor for secure system

operation. A secure system provides a constant frequency and constant voltage

within limits to customers. To achieve this aim a highly reliable and cost effective long

term investment technology is required. Stability limits can define transfer capability.

Also in a complex interconnected system, stability has a great impact to increase the

reliability and the profits. An example of a large power system formed by

interconnection is the South-East Australia power network which connects the five

states of Queensland, New South Wales, Victoria, South Australia and Tasmania.

Although this interconnection gives the system a complicated dynamic it has

advantages such as reduced spinning reserves and a lower electricity price. To

achieve these benefits, appropriate control is required to synchronize the machines

after a disturbance occurs.

In angle stability there are two types of disturbance. Transient angle stability results

from an imbalance between accelerating torque and load torque on a group of

generators that is caused by a system disturbance such as the outage of a major

generator, line, transformer, busbar or load. The consequence may be a loss of

Page 11: Mana Tavahodi Thesis

8

synchronism, frequency instability, system separation and/or blackout. For blackout

occurrences and durations in major cities over the last two decades refer to table 1.

TABLE 1: Blackouts Incidents [1]

Small signal instability results from insufficient synchronizing torque or damping

torque leading to in oscillatory behaviour. If it is not damped, it will cause transient

instability, loss of synchronism, system separation and/or blackout [2], [3] and [4].

In a multi-machine system the voltages and currents of the stator in all the machines

should have the same frequency and the speed of the rotors also should also be

synchronized to that frequency [2]. In such a system which operates in a steady state

condition, when a disturbance occurs and causes readjustment of the voltage angles

the system starts oscillating according to the swing equation (equation 2.15).

Page 12: Mana Tavahodi Thesis

9

Various techniques have been employed to assist with the field based stabilization of

power systems, such as fast exciters and power system stabilizers [2]. Ideally, since

the system is inherently non-linear to stabilize the system using fast exciters or power

system stabilizers a nonlinear control design is needed.

The issue then is the control of a large complex non-linear system. MPC has been

shown to be successful in addressing many large scale nonlinear control problems

and therefore is worth considering for stabilization of a power system [5].

A fast control action is required to stabilize a power system. Using Energy Function

controllers, EEAC (extended equal area criterion) [6, 7] or TEF (transient energy

function) [8] on devices such as SVC and series compensators has been successful

in controlling the elements and has an immediate effect on the output power.

Controlling excitation to achieve the same end has not been as effective due to the

long time constants.

1.2 Approaches and Aims

The main focus of this thesis is to demonstrate the ability of the combination of

decentralized MPC and Energy function design for multi machine systems that have

faced large disturbances. Typically, MPC is implemented in a centralized fashion.

The complete system is modelled, and all control inputs are computed in a one

optimization problem [3]. Direct MPC on the system, as it will be shown in the single

machine infinite bus example, is very effective. However, in complex systems with

hundreds of machines there would be some difficulties. For instance, the first issue is

that in MPC we need to have a complete knowledge of the states at every step in

order for the model to predict the future control steps. In a complex system, due to

the lack of information, the predictions of the model would be difficult to achieve.

Page 13: Mana Tavahodi Thesis

10

The other issue is the computation cost. To optimize the cost function for all of the

large system would be very time consuming and may exceed the computational

capacity for real time optimization [9, 5].

To address these issues, it is proposed that an MPC be applied on machines in a

decentralized fashion. The best tool which provides the ability to design the flux

changes is to use Energy function design or extended EAC (EEAC) [10, 11]. By

maximizing the rate of reduction of kinetic energy, the required field voltage is

achieved to stabilize the system.

In implementing the controller, a KALMAN filter [5] can help in computing and

predicting the states for the machine from the little knowledge which is gained from

the system at each sampling time. From the estimation of the KALMAN filter, the

MPC will be able to have a reasonable estimated model of the system. Also the field

voltage prediction (from the energy function) acts as a reference for the optimizer.

(Fig. 1)

Figure 1: Control structure

Estimate states

(KALMAN filter)

Field voltage prediction

Optimization

MPC model

Reference for MPC Error

Page 14: Mana Tavahodi Thesis

11

1.3 Thesis layout

Introduction (chapter 1) Chapter 1 provides a brief introduction to power system stability (PSS), the facts that

have encouraged the idea of the research and the approaches of using the

combination of the energy function design and MPC.

Power system stability and control (chapter 2)

Chapter 2 will give the literature review on power system basic concepts such as the

characteristic of the power-angle and swing equation. The literature review has also

been extended in order to understand the problem associated with the disturbances

(small and large disturbances) and excitation systems. The literature review in wide

area of control and energy function design includes developing a model for a multi

machine system.

Model predictive control (chapter 3)

This chapter begins with the theory of optimal control, explaining the Hamiltonian

method of optimization, MPC algorithm and parameters such as prediction horizon

and control horizon. This is followed by an investigation into centralised and

decentralised MPC using Single machine infinite bus (SMIB), as an example for

demonstrating the ability of MPC in a centralized fashion.

KALMAN filter (chapter 4)

Chapter 4 shows how the filter is used to compute and predict the states for the

machine from the little knowledge which is gained from the on-line measurements in

each sampling time. This focuses on the discrete KALMAN filter and extended

KALMAN filter (EKF).

Page 15: Mana Tavahodi Thesis

12

Centralized MPC (chapter 5)

The MPC is applied to the SMIB system. The controller’s ability is shown in the

nonlinear region of the system. Also the typical lead compensation control for

exciters is designed to compare the behaviour of the two controllers.

Decentralized MPC approach and Multi-machine system application

(chapter 6)

The decentralized approach is explained in this chapter. In order to validate the

proposal method, the three machines model in chapter 2 is developed and MPC is

applied to this model in a decentralized fashion. Also the typical lead compensation

control for exciters is designed to compare the behaviour of the two controllers

Limitation in the current approach (chapter 7)

The limitation of decentralized approach is explained followed by the examples.

Conclusions (chapter 8)

Main conclusions and suggestions for further work are outlined.

1.4 Publication

Tavahodi, M., Ledwich, G., and Palmer, E., “Mixed Model Predictive Control/ Energy

Function Control Design for Power Systems”, in Australian Universities Power

engineering Conference, AUPEC’2006, 10-13 December 2006, The University of

Victoria, Melbourne, Australia.

Page 16: Mana Tavahodi Thesis

13

Reference

[1]. Information Sources on selected blackouts, PSerc News, Available ;

http://www.pserc.wisc.edu/Resources.htm

[2]. P. Kundur ”Power System Stability and Control” New York: McGraw-Hill,

1994

[3]. P. M. Anderson and A. A. Fouad, Power system control and stability.

A John Wiley & Sons INC Publication, 2003

[4]. P. W. Sauer and M. A. Pai, Power System Dynamic and Stability.

New Jersey: Prentice Hall, 1998.

[5]. EF Camacho and C. Bordons, “Model Predictive Control”, Springer-Verlag,

London, 1999.

[6]. V. Vittal, E.Z. Zhou, C. Hwang and A.A Fouad, “Derivation of stability limits

using analytical sensitivity of the transient energy margin” ”, IEEE

Transactions on Power System, November 1989, Vol. 4.

[7]. Y. Xue, T. Van Custem and M. Ribbbbens-Pavella, “Extended equal area

criterion justifications, generalizations, applications”, IEEE Transactions on

Power System, February 1989, Vol. 4, pp. 44-52.

[8]. Y. Xue, T. Van Custem and M. Ribbbbens-Pavella, “Real-time analytic

sensitivity method for transient security assessment and preventive control”,

IEE Proc. March 1988, Vol. 135, pp 107-117

[9]. EF Camacho and C. Bordons, “Model Predictive Control”, Springer-Verlag,

London, 1999.

[10]. F.Kentli, Y. Birbir and N. Onat, “Examination of the stability limit on the

synchronous machine depending on the excitation current wave shape”

Electric Machines and Drives Conference, 2001. IEMDC 2001. IEEE

International 2001, pp. 528 – 532

Page 17: Mana Tavahodi Thesis

14

[11]. G.Welch and G. Bishop, “An Introduction to Kalman Filter”. Available:

www.cs.unc.edu/~tracker/media/ pdf/SIGGRAPH2001_CoursePack_08.pdf

Page 18: Mana Tavahodi Thesis

15

Chapter 2

2. Power System Stability

2.1 Introduction

Operating a reliable system depends on the engineer’s ability to feed constant

voltage and frequency to the load at all times. Providing uninterrupted service to the

load will be difficult in a complex system which includes hundreds of generators,

protection switches and thousands of kilometres of transmission lines. A stable

power system is one that stays at the equilibrium points in the normal conditions and

will return to an acceptable state of equilibrium after a disturbance occurs. In

practice, both voltage and frequency must be held within close tolerance so that the

consumer’s equipment operates satisfactorily. Power systems rely on synchronous

machines. To achieve stability, synchronous machines are needed to stay in

synchronism. The dynamics of the generators, power-angle and rotor angle

characteristics will be considered in this study [1].

There are two fundamental elements in a synchronous machine: the field that

normally is on the rotor and the armature which is on stator. The rotor is driven by a

turbine and the field winding energized by direct current. Voltage is produced by a

rotating magnetic field in the armature’s winding of the stator. The frequency of the

stator is synchronized with the rotor’s mechanical speed. When two or more

synchronous machines are interconnected, the stator voltages and currents of all the

Page 19: Mana Tavahodi Thesis

16

machines must have the same frequency and the mechanical speed of the rotor in

each machine is synchronized to this frequency. Therefore, the rotors of all

interconnected synchronous machines must be in synchronism [2].

Security of the power system relies on its ability to survive any disturbances which

may occur without any interruption in the services. The stability of a power system

has different classifications.

Figure 2.1: Stability classification

Voltage instability occurs in a system due to disturbances such as increases in load

demand, or changes in the system’s condition [2]. The disturbances are classified

into two subclasses, large-disturbances and small-disturbances. Losses of

generation or circuit contingencies are the examples which cause the large-

disturbances. Large-disturbance stability is the ability to control voltage when the

system faces large-disturbances. Small-disturbance voltage stability is concerned

with a system’s ability to control voltages following small perturbations such as

incremental changes in the system load. Angle stability will be investigated

intensively in the following sections.

To start the stability concept the main characteristics of the power system will be

discussed.

Power system stability

Angle Stability

Frequency Stability

Voltage Stability

Small Signal

Stability

Transient Stability

Transient

Large Disturbance

Voltage Stability

Small Disturbance

Voltage Stability

Page 20: Mana Tavahodi Thesis

17

2.2 Power-angle

A stabilized rotor angle in synchronous machines is an important factor to consider

for the power system to remain synchronism. The electromagnetic torque was

applied from the turbine into the generator opposes rotation of the rotor. When the

system is in a steady-state condition, the stator and rotor fields have the same speed

with an angular separation between them. This angle depends on the output

electrical torque of the generator.

If fE and The general active and reactive powers are [3]:

)cos()cos(2

γδγss

f

ZV

Z

VEP −−= (2.1)

)sin()sin(2

γδγss

f

ZV

Z

VEQ −−= (2.2)

For the lossless line ss jXZ = and o90=γ therefore these two formulae reduced to:

)90cos()90cos(2

ss

f

XV

XVE

P −−= δ (2.3)

))cos(( VEXVQ f

s

−= δ (2.4)

)sin(δs

f

XVE

P = (2.5)

Where:

SX Synchronous reactance

0∠V Bus voltage

δ∠fE Field voltage

δ Angle between V and fE

Page 21: Mana Tavahodi Thesis

18

The maximum torque, known also as the pull-out torque is at δ = 90°. The machine

will lose synchronism if δ >90°. The pull-out torque can be increased by increasing

the excitation current fI .

The power varies as a sine of the angle in a highly nonlinear relationship. In equation

(2.5), δ= 0 means no power is transferred and as the angle is increased, the power

transfer increases up to a maximum. After a certain angle, technically 90° (The

maximum power, known also as the pull-out power), a further increase in angle

results in a decrease in power transferred, Fig 2.2. There is thus a maximum steady-

state power that can be transmitted between the two machines. When there are more

than two machines, their relative angular displacements affect the interchange of

power in a similar manner. However, limiting values of power transfers and angular

separation are a complex function of generation and load distribution.

Figure 2.2: Torque-angle characteristics

2.3 The swing equation

The angle between the rotor axis and the stator magnetic field is the load or torque

angle (δ ).This angle depends on the load of a machine. (A larger value of load

makes δ bigger)

Page 22: Mana Tavahodi Thesis

19

Changing δ causes the rotor acceleration and deceleration in synchronous

machines as a function of time which is known as the swing equation [2].

ema TTTdtdM −==δ2

(2.6)

Where:

M moment of inertia in Kg-m2

aT the net torque which produces acceleration

mT shaft torque, corrected for torque due to rotational losses

eT electromagnetic torque (positive for generator and negative for motor)

If we multiply this equation by the angular velocity ω ( aa TP ω= ), we obtain:

ema PPPdt

dM −==δ2

(2.7)

Where:

M is the inertia constant of the machine (momentum at synchronous speed which

depends on type and size of the machine)

Pa is the accelerating power, or difference between input and output in each

corrected for loses.

Pm is the shaft power input, corrected for rotational losses

Pe is electrical power output, corrected for electrical losses )sin( δx

VE

If we consider the damping in the power system we will have:

emam PPPdtdD

dtdM −==+

δδ2

(2.8)

mdm DD ω= is the damping coefficient. Where dD is the damping-torque coefficient

and

dtd

smmδωω += (2.9)

Page 23: Mana Tavahodi Thesis

20

If the constant flux linkage is considered in both direct and quadratic axis the

electrical power for a single machine infinite bus will be represented by equation

(2.10)[9]

δδ 2sin2

)(sin

2

qd

qd

de XX

XXVXVEP

−+= (2.10)

Where dX and qX are the d-axis and q-axis reactance of the generator, V is the

infinite busbar voltage and E is the field voltage.

If the transient saliency ignored which means qd XX ≈ , then the equation (2.10) will

be simplified to;

δsind

e XVEP = (2.11)

2.3.1 Equal Area Criterion Equal-area criterion method is used to predict the stability. This method is only

applicable for single machine infinite bus (SMIB) or two-machine system [10]. For a

SMIB system from the equation (2.7) the equation of speed of the machine can be

achieved. If dtdδ

multiplies to this equation and then integrating both sides, equation

(2.13) will be the speed equation of the machine with respect to the synchronously

revolving reference frame:

dtdPpM

dtdd em

δδ )(])[( 2 −= (2.12)

∫ −=δ

δ

δδ

0

)( dPPMdtd

em (2.13)

To assure the stability in equation (2.13) the integral should become zero sometime

after the disturbance. Consider the machine is operating at equilibrium point

0δ according to equation (2.13) at steady state em PP = . If the input power increases

Page 24: Mana Tavahodi Thesis

21

suddenly to mP′ , the rotor accelerating and the power angle δ will be increased,

which causes the incensement in electrical power until electrical power equal to new

input power. Although the acceleration power is zero but the rotor speed is above the

synchronous speed, therefore the δ will continue to increase to maxδ . In this stage

me PP > which causes the rotor to decelerate. The rotor will oscillate between 0δ and

maxδ until reaching the new steady state condition in point A Fig (2.3.a).The integral

will be zero if the areas ABE and ADC be equal which means the system will be

stable.

(a) (b)

Figure 2.3: a) Equal-area criterion- sudden change in load [3] b) Equal-area criterion- maximum power limit [3]

This method is also used to find the maximum input power that can be added before

the system becomes unstable. If we look at the Fig (2.3 b) it shows the limit of input

power when πδπ<< max2

as it was explained previously for stability the two

coloured areas in Fig 2.3.b should be equal. The Newton-Raphson method [3] can be

used to find the maximum permitted input power.

Page 25: Mana Tavahodi Thesis

22

2.4 Multi-machine model In the multi machine classical model [4], if the load flow is represented by a constant

admittance the load can be added to the bus admittance matrix [3]. In this research

this simplified one-axis classical model followed by the typical assumptions [10] is

used with an excitation system which is explained in the next section.

For a power system including n generators, the electromechanical equation for

generator i per unit (p.u.) can be written as:

Dieimiii pppM −−=..δ ..up (2.14)

Where

=iδ Rotor angle of generator i

=iM Inertia of generator i

=mip Mechanical power of generator i

=eip Electrical power if generator i

=Dip Damping power of generator i The electric power of generator i and damping power can be found from the following

equations.

∑≠=

−=n

ijj

jiij

jieij x

VEp

1

)sin( δδ (2.15)

iiDi Dp.δ= (2.16)

Where iE and jV are the voltage magnitude of bus i and j respectively, and iD is the

damping coefficient of generator i. Also ijx is the reactance between bus i and j.

Thus, the state equation of a multi-machine system will be:

Page 26: Mana Tavahodi Thesis

23

ii ωδ =&

)(1..

Dieijmii

i PPPM

−−=δ ..up ni ,...,1= (2.17)

Where eijP is the electric power change of generator i caused by an angle change

between machine i & j and iω is the speed of the rotor of ith machine.

Therefore we can substitute the appropriate values for all of the terms in equation

(2.17) and then linearizing the result around operating points.

2.5 Excitation system

The first suggestion for improving the power system stability is to increase the speed

of the exciter response [5]. The excitation system has the effect on both transient and

steady state stability. There are different types of design for excitation systems which

can be classified in two general categories “slow response” and “fast response”

[1],[5].

Primary models were very slow such as the self-excited main exciter, the main

exciter and pilot [5]. Gradually as the interconnected system operation becomes

more common the excitation systems will become more complicated. Since 1968

IEEE Committee reports on excitation system models [6], [7] and [8], the excitation

system has received more attention.

2.5.1 Relation between exciter and stability

In equation (2.15), the power transmitted between the two machines is proportional

to the internal voltages of the two machines, divided by the reactance. The power will

be increased if either internal voltage is increased in the equation (2.17). Therefore, it

is apparent that raising the internal voltage increases the stability limits. In the

transient condition when the fault occurs, during the fault the flux linkage decays by

Page 27: Mana Tavahodi Thesis

24

the short circuit time constant. If the fault is maintained for a long time the machine

might survive the first swing of its rotor, but because of the continued decrease in

filed flux linkage it might pull out of step in the second swing or the next one. A

controlled excitation system can control the flux linkage in order to prevent the loss of

synchronism. Hence the excitation system can assist transient stability even though

high-speed clearing of fault is applied. The faster the excitation system responds to

correct low voltage, the more effective improvement will be achieved in stability.

2.5.2 Exciter model In this section the Type-1 system [4], [1] is considered. The block diagram below

shows the part of the exciter model; note that there is no filter and the rate feed back

is zero.

Figure 2.4: Block diagram of Type 1 excitation system The exciter is represented by a first-order linear system with the time constant of Eτ .

However, a condition is made to include the effect of saturation in the exciter by the

saturation function ES .

)exp()( FDEXEXFDE EBAEfS == (2.18)

Where coefficients EXA and EXB are computed from the saturation data, and FDE is

the exciter output voltage.

According to the block diagram (Fig. 2.4) since FDE is a nonlinear function therefore

it will change the regulator output voltage RV by the following equation (2.19).

Page 28: Mana Tavahodi Thesis

25

FDERR ESVV −=& (2.19)

From the block diagram we can write:

FDERFDEFDE ESVEKsE −+−=τ (2.20)

equation (2.20) in time domain would be

)(1FDERFDE

EFD ESVEKE −+−=

τ& (2.21)

Note that equation (2.21) will be linear if FDE is very small. (Fig2.5)

Figure 2.5: Exciter saturation curve

2.6 Angle stability As it was mentioned before, angle stability will be discussed when either small or

large disturbances occurs in the system. In this thesis however we will concentrate

on large disturbances, In this section only a summary of small disturbances (small

signal) will be given and then the behaviour of a power system after it is subjected to

large disturbances (transient stability) will be intensively investigated.

2.6.1 Small signal stability Small signal stability is defined as the ability of a power system to remain in

synchronism while a small disturbance occurs. These types of disturbances arise due

Page 29: Mana Tavahodi Thesis

26

to the small changes in loads and generation which might cause certain instability in

the system. [2]

The stability of the rotor angle depends on two components, the synchronous torque

and the damping torque [10]. As a result of small disturbances the instability steadily

increases in the rotor due to insufficient synchronous torque, or the amplitude of rotor

oscillation increases due to insufficient damping torque [2],[10]. Losing the

synchronism can happen to any of them. It is convenient to assume that the

disturbance disappeared and if the system returns to its original state the stability is

corroborated. Due to the small changes this behaviour can be determined by

examining the linear system equations. By using the Taylor series we can linearize

the multi machine system equation around the equilibrium point (2.22) [2].

),(),(

uxgyuxfx

==&

uDxCyuBxAx

Δ+Δ=ΔΔ+Δ=Δ &

(2.22)

As it has been shown in [2], the poles of this system are the roots of the equation

(2.23) which is the Eigen values of A matrix. If all the Eigen values have the negative

real component then the system will be stable.

0)det( =− AIs (2.23)

Eigen values provide the valuable information about the nature of system response.

The time constant can be found from the real component of the Eigen values and the

damped frequency of the oscillation is given by the imaginary component. Note that

the linearized equation is valid for very small variation in power from the operating

state. To investigate the stability, when the multi machine system is subjected to the

small signal disturbances, the only thing that is required is to check the Eigen values.

Page 30: Mana Tavahodi Thesis

27

If all of them are in the left hand side of the imaginary axis, the system will be stable.

The linearized model of the system especially in multi-machine system is very useful

in designing the compensator series to control the machines. (Chapter 5)

2.6.2 Transient stability The transient stability studies investigate whether the system remains synchronised

after a severe disturbance such as a line tripping, loss of a generator or loss of a

large load. When this type of disturbances occur the linearized model of the system

won’t be able to give a correct answer, and the nonlinear swing equation should be

solved. The most severe type of disturbance is a short circuit therefore the effect of a

short circuit has to be determined in stability studies. There are different types of

short circuits: three-phase, one-line-to-ground, line-to-line or two-line-to-ground. If it

was a three-phase short circuit, the connection line of the machines will cut off the

power flow between the machines. Otherwise, some synchronising power can still be

transmitted. In some cases, despite the fault, the system will be stable. Whether the

system is stable during the fault will depend on: the system itself, the duration of the

fault, type of the fault, location of the fault, how fast it has been cleared, what method

has been used and other conditions referred as the transient stability limits. The

transient stability limit is a kind of power limit that was discussed in (2.3.1). In this

thesis the effect of three-phase short circuit is investigated in a multi machine

system.

When a fault occurs, certain generators which are electrically closer to the fault

location are disturbed to a greater extent than the other generators. These

generators tend to accelerate or decelerate depending on the nature of the fault, from

the rest of the generators in the system. If the fault lasts long enough, eventually one

machine or a group of machines separate from the system causing instability (loss of

synchronism) however; the power network is equipped with automatic devices that

Page 31: Mana Tavahodi Thesis

28

sense the existence of the faults in the network and initiate action to “clear” the fault,

in ways such as isolating the faulty section of the network.

The behaviour of the system which is subjected to three-phase short circuit can be

explained by the Equal-area criterion [3]. Also there are some numerical techniques

which can help us to study the effect of the faults in the nonlinear equation of the

system such as swing equation. Euler’s method is well known and the simplest

numerical method [3]. By studying this method we will be able to solve the deferential

equation and provide a better understanding about the numerical solution of ODE

and Runge-Kutta procedure. MATLAB has two commands ode23 and ode45 for

solving high order differential equation based on Runge-Kutta-Fehlberg method [4].

To investigate the transient stability in the SMIB system involves considering a three-

phase short circuit on the line connecting the generator to the infinite bus which

entirely cuts off the power flow (Fig. 2.6). As a result for the duration of the fault the

output electrical power becomes zero because the governor is slow in acting perhaps

for .7sec however the input power mP remains constant. Consequently, the torque

angle is accelerating and if the fault is not quickly removed the synchronism will be

lost.

Figure 2.6: Single Machine infinite Bus, three-phase fault at F

For this system mP has been assumed constant and under steady state condition

em PP = from equation (2.8) for the pre-fault, during the fault and post fault condition

the swing equation will be:

Page 32: Mana Tavahodi Thesis

29

)(12

dtdDPP

Mdtd

memδδ

−−= Pre-fault (2.24)

)(12

dtdDP

Mdtd

mmδδ

−= During the fault (2.25)

)(11

2

dtdDPP

Mdtd

memδδ

−−= Post- fault (2.26)

Where 1eP is the output power of the new states. In the next few chapters we are

explaining how to eliminate the oscillation which is caused by such a disturbances in

multi machine systems in order to keep them in synchronism.

2.7 Energy Function Design As mentioned in previous sections, the vital objective of nonlinear dynamic simulation

of power systems is to see whether synchronism is conserved when a disturbance

accrues. This is determined by the variation of rotor angles as a function of time. The

system would be unstable if the rotor angle of a machine continuous to increase with

respect to the rest of the system. The rotor angle of each machine can be measured

with respect to a fixed rotating reference frame that is the synchronous network

reference frame. Hence, instability of a machine means that the rotor angle of the ith

machine pulls away from the rest of the system. Thus relative rotor angles rather

than absolute rotor angles must be monitored to test stability/ instability [4].

Before 1979 much research had been done on the Lyapunov Function for the system

using state-space model [4]. This method is used where the transfer conductance is

zero. To incorporate the transfer conductance term, one of the approaches is to

integrate the motion equation generating what is called an Energy function[4]. In this

section an expression for the individual machine is developed. Multiplying the ith

swing equation (2.14) by post-fault swing equation iδ& :

Page 33: Mana Tavahodi Thesis

30

0)(..

=++− iDieimiii pppM δδ & (2.27)

There is general agreement that the first integral of motion with respect to time (2.17)

represents a proper energy function from (2.27) then we have:

dtpppMi

siiDieimiii∫ ++−

δ

δδδ &)(

..

(2.28)

Where iδ is the post-fault rotor angle and sδ is the rotor angle at the equilibrium

point. Therefore for ith machine we obtain:

)()()(21 2

siiDisiieisiimiiii PPPMV δδδδδδω −+−+−−= (2.29)

The first term is the kinetic energy ( KEV ) of ith machine and the remaining terms are

considered as the potential energy ( PEV ). The kinetic energy directly relates to

energy of the fault. At the time of fault clearing this energy will reach the maximum

value and it is oscillating later on. The kinetic energy as it has been discussed in [11]

is influenced byδ&& . Thus, the observation of the kinetic energy may reveal valuable

information on determination of the region of stability.

This thesis demonstrates that the energy function design is a valuable tool which

provides the ability to design a flux. In order to find the required flux of the machines

we are using the method that has been used in [11]. Since the first term of equation

(2.29) is the only term involving acceleration we only need to consider that one for

our calculation. Therefore:

2

21

iiKE MV δ&= (2.30)

iiiKE MV δδ &&&& = (2.31)

Page 34: Mana Tavahodi Thesis

31

If we substitute equation (2.17) into (2.31) we obtain:

)( DieijmiiKE PPPV ++−−= δ&& (2.32)

))sin((.

1ii

n

ijj

jiij

jimiiKE D

xVE

PV δδδδ −−−= ∑≠=

&& (2.33)

2.

1)sin( i

n

ijj

jiij

jiimiiKE x

VEPV δδδδδ −−−= ∑

≠=

&&& (2.34)

Furthermore when changing the flux of the machine from equation (2.34) we only

need to consider the relative term to field voltage which lead us to equation (2.35).

i

n

ijj

jiij

jiKE x

VEV δδδ && ∑

≠=

−−=1

)sin( (2.35)

To maximise the convergence rate of the kinetic energy function which can be

assured of being positive definite.

))sin((1

i

n

ijj

jiij

ji x

VE δδδα &∑

≠=

−−= (2.36)

With equation (2.36) we are able to find the required field voltage for establishes the

stability of our system, where in this equationα would be the control gain.

Page 35: Mana Tavahodi Thesis

32

References

[1]. P. M. Anderson, A. A. Fouad, and Institute of Electrical and Electronics

Engineers “Power System Control and Stability” 2nd ed. Piscataway, N.J.:

IEEE Press; Wiley-Interscience, 2003.

[2]. P. Kundur ”Power System Stability and Control” New York: McGraw-Hill,

1994

[3]. C.L. wadhwa “Electrical Power System” 3rd ed. New Age International (P) Ltd.

New Delhi, 2000

[4]. P. W. Sauer and M. A. Pai, “Power System Dynamic and Stability”, New

Jersey: Prentice Hall, 1998.

[5]. E.W Kimbark “Power System Stability Volume III Synchronous Machine”,

IEEE Press Power Systems Engineering Series, New York, 1995

[6]. IEEE Committee Report, “Computer Representation of Excitation Systems,”

IEEE Transactions on Power Apparatus and Systems, vol. PAS-87, no. 6, pp.

1460-1464, June 1968.

[7]. IEEE Committee Report, “Excitation System Dynamic Characteristics,” IEEE

Transactions on Power Apparatus and Systems, vol. PAS-92, pp. 64-75,

Jan/Feb 1973.

[8]. IEEE Committee Report, “Excitation System Models for Power Systems

Stability Studies,” IEEE Transactions on Power Apparatus and Systems, vol.

PAS-100, pp. 494-509, Feb. 1981.

[9]. A.F. Puchstein, T.C. Lioyd, A.G. Conrad, “Alternating-Current Machines” 3rd

ed. New Delhi 1996.

[10]. H. Saadat “ Power system Analysis” New York: McGraw-Hill, 1999

[11]. E. Palmer, G. Ledwich, “Switching control for power systems with line

losses” transmission and distribution, IEE Proceedings, volume 146, pp. 435

- 440 Sept. 1999.

Page 36: Mana Tavahodi Thesis

33

Chapter 3

3. Model Predictive Control (MPC)

3.1 Introduction

Since 1988 Model Predictive Control (MPC) with over 2000 industrial installation is

the most widely implemented advanced process control technology [1]. MPC has

gained significant popularity in industry as a tool to optimise system performance

while handing the limitation. However, computation competence has limited the

application range. The term Model Predictive Control does not delegate a specific

control strategy but rather a sufficient range of control methods which make explicit

use of a model of the process to obtain the control signal by minimizing an objective

function.

Model Predictive Control (MPC) has been shown to be successful in addressing

many large scale nonlinear control problems and therefore is worth considering for

stabilization of a power system. While MPC is suitable for almost any kind of

problem, it displays its main strength when applied to problems with:

• A large number of manipulated and controlled variables

• Constraints imposed on both the manipulated and controlled variables

• Changing control objectives and/or equipment (sensor/actuator) failure

Page 37: Mana Tavahodi Thesis

34

• Time delays

The strengths of MPC that are relevant to the task of power system stabilization are

the explicit handling of constraints such as the requirement for angles across lines to

be kept below 90 degrees.

There are many difficulties that derive from the use of this kind of model such as:

• The limitations of Nonlinear Model Predictive Control (NMPC)

• Lack of identification techniques for non linear processes

• The general tools for NMPC are not necessarily well developed for the specific

nonlinearities of the power system [3,4].

3.2 MPC methodology

Model predictive control is also called recede horizon predictive control [2]. The

receding horizon concept is used because at each sampling instant the optimized

control values for the model system over the prediction horizon are brought up to

date, and at each sampling instant only the first control signal of the sequence

calculated will be used to control the real system [2, 4]. The MPC strategy has been

demonstrated on the following chart Fig.3.1.

There are two important parameters in MPC, 1) Prediction Horizon 2) Control

Horizon.

• Prediction horizon is the length of time for the process outputs to approach

steady state values.

• Control horizon is the number of discrete time control actions to be optimized

along a future prediction horizon

Not that the control horizon in discrete-time MPC can be represented as the number

of time samples.

Page 38: Mana Tavahodi Thesis

35

Figure 3.1: MPC Structure

As shown in the above chart, at each time instant kt the future output will be

predicted through the length of prediction horizon by using the process model. This

output depends on the previous inputs and outputs. By optimising the cost function in

order to keep the model as close as possible to the reference trajectory combine with

a control penalty, the control value will be calculated. The cost function is in the form

of quadratic function of the error between the predicted output and the reference

trajectory. This calculation gives a set of control values through the prediction horizon

and at kt the first control action is applied to the real system. At the next sampling

instant everything is repeated and the calculated control values are updated.

Measurement from real

Solving the optimization problem Achieve the best future control

actions

Reference 1+→ kk tt

Time= 1+kt

Passing kt signal to the real system

Time= kt

Finding error

Model 1+→ kk tt

Predicted output

Page 39: Mana Tavahodi Thesis

36

The generalized predictive control (GPC) is the most popular predictive control

algorithm which is widely used in the academia and industry. This method was

proposed by Clarke et al [5] which has common ideas with the Model Predictive

control. The basic idea of GPC is to calculate a sequence of future control signals in

such a way that it minimizes a multistage cost function defined over a prediction

horizon. The index to be optimized is the expectation of a quadratic function

measuring the distance between the predicted system output and some predicted

reference sequence over the horizon plus a quadratic function measuring the control

effort. This method obtains a generalized pole placement controller [2] that is a

expansion of pole placement controller.

3.3 MPC elements

The methodology of MPC can be classified in three parts.

• The process model from where we obtain the predicted future outputs

• The cost function which is the quadratic function of the error between the

predicted output and the reference trajectory.

• The optimizer that it minimizes a multistage cost function defined over a

prediction horizon.

3.3.1 The process model

The early industrial MPC applications were time domain, input/output, step or

impulse response models; however state space model discussions are common in

recent research.

In continuous form:

DuCxy

BuAxdtdx

+=

+= (3.1)

Page 40: Mana Tavahodi Thesis

37

Discrete time model:

kkk

kkk

DuCxyBuAxx

+=+=+1 (3.2)

The continuous model probably is more recognizable to those with the classical

control background in transfer functions, but discrete model is more convenient for

digital computer implementation.

Linear model

In most industrial process when a small change around the operating point

occurs a linear model of the system is considered, which can often be of a

very high order. These very high order models are very hard to use for the

control process.

There are two main reasons for using linear model. First, the identification of

the linear model based on process data is relatively easy and also linear

model provides good results when the plant is operating in the neighbourhood

of operating point.

Nonlinear model

In some situations the nonlinearity is so severe that the linear model is

insufficient. Also there are some processes which spend great deal of time

from the steady state operating point or some which never are in the steady

state operating point. In such a case the linear control laws are not very

effective. Since there is no general model which clearly represent all

nonlinear systems, constructing the nonlinear model is difficult. System

identification is classified in to: parametric and nonparametric methods. In the

parametric methods the model of the system is assumed and the amounts to

an estimation of the model parameters. In non-parametric methods no

assumption is made and the identification of the system is developed by

computing the frequency response of the system. According to Zhu et al [6]

Page 41: Mana Tavahodi Thesis

38

parametric models are better for use in industrial process identification, since

these models are more accurate, require shorter test time, and can be more

user friendly than non parametric models. Thus for industrial processes which

are controlled by MPC, non-parametric models are not ideal. Therefore in this

research a parametric method has been used for identification of the model of

the system and the estimation of the parameters found by the KALMAN filter

which is discussed in the next chapter [6].

3.3.2 The cost function

The primary criterion for MPC is to determine the sequence of control actions over

the prediction horizon that will minimize the sum of the squared deviations of the

predicted output from the reference trajectory. This control objective function is called

the cost function. The cost function is defined for all possible output vectors and all

positive input price vectors. If the system is constrained on states and control actions,

which are given by UuXx kk ∈∈ , where X is a closed set and U is a compact

set. kx and ku are the states and the control action which applies to the system at

kt . The general form of the cost function is defined by equation (3.3) [7]

∑∞

=+ =

01),(

),()(mink

kkkuxuxIxJ

kk (3.3)

Where ),(1 kkk uxfx =+

According to this definition of the cost function, a simple criterion function will be:

])ˆ[( 22

0kk

m

kk uwyJ γ+−= ∑

= (3.4)

Page 42: Mana Tavahodi Thesis

39

Where 1ˆ +ky is the predicted output at time kt , 1+kw is the reference trajectory at time

kt and m is the prediction horizon. Now the controller output sequence optu over the

prediction horizon is obtained by minimization of J at each sampling instant [8].

3.3.3 The optimal control

The idea of the optimal control is to determine control signals which cause the plant

to satisfy some physical constraints and at the same time maximize or minimize a

criterion function (cost function). Three following formulations are required for the

optimal control:

1. Plant or model of the system

2. Performance criterion or Cost function

3. A statement of boundary conditions or physical constraints

The first two parts are explained in the above sections. The control )(tu and state

vectors )(tx regarding the physical situation of the system can be either unconstraint

or constraint. From the constrained problems we have control and state such as

currents or voltages constrained as:

maxmin uuu << and maxmin )( xtxx << (3.5)

This conditions lead to a boundary value problem. We often have the nonlinear two-

point boundary value problems [8]. The numerical techniques are usually used as a

solution for these types of problems.

3.4 The Optimizer

The problem in this research is examined using MATLAB software. The optimizer

command which is used is fmincon. This function can handle the nonlinear

constrained optimization problems. The fmincon function is based on the sequential

quadratic programming (SQP) methods. SQP has arguably become the most

Page 43: Mana Tavahodi Thesis

40

successful method for solving nonlinearly constrained programming problems [10,

11]. The limitation of the fmincon that it is a gradient-based method that is designed

to work on problems where the objective and constraint functions are both

continuous and have continuous first derivatives [12].

)(min xfx

Subjected to:

ubxlbbeqxAeq

bxAxceq

xc

≤≤=⋅

≤⋅=

≤0)(

0)(

Where x, b, beq, lb, and ub are vectors, A and Aeq are matrices, c(x) and ceq(x) are

functions that return vectors, and f(x) is a function that returns a scalar. f(x), c(x), and

ceq(x) can be nonlinear functions [ MATLAB Tool box].

The syntax of this function represented by:

options)nonlcon,ub,lb,beq,Aeq,b,A,x0,n,fmincon(fu x =

This command enable the solution for the optimum value for the controller in order to

minimize the cost function.

3.6 The application of MPC in power system

To show how the MPC is working, in this part we will demonstrate the two examples

with a second order linear and non-linear model which is simulated in MATLAB.

Page 44: Mana Tavahodi Thesis

41

Example 1

If the transfer function of the plant is:

95.7.11

2 +− ss

If this continues system will be changed to the discrete time system with the sampling

rate of 1 then the step response of this system would be:

0 10 20 30 40 50 60 701

2

3

4

5

6

7

Step Response

Time (sec)

Ampl

itude

Figure3.2: The step response of the linear second order system

In order to have a better prediction of the future behaviour of the plant, the prediction

horizon should be more than the period of the system. Therefore if the measurement

error exists in the first instant it would still enable the output to follow the reference

trajectory. Therefore we choose prediction horizon equal to 15 and control horizon of

5 for this system with the period of 10. It is not necessary that the control prediction

matches the prediction horizon.

The cost function will be.

The control penaltyγ in equation (3.4) chosen to be 1. Thus the result will be:

)()(min0

22

),( ∑∞

=

+=k

kknuxxuxJ

kk

Page 45: Mana Tavahodi Thesis

42

0 5 10 15 20 25-2

-1

0

1

2

Time (Sec)

Sta

tes

valu

es

0 5 10 15 20 25-1

-0.5

0

0.5

Time (Sec)

Con

trol v

alue

Figure3.3: The result of the MPC for second order linear system with no control penalty

If we change the control penalty γ to 10, the results will be:

0 5 10 15 20 25-2

-1

0

1

2

Time (Sec)

Sta

tes

valu

es

0 5 10 15 20 25-1

-0.5

0

0.5

1

Time (Sec)

Con

trol v

alue

Figure3.4: The result of the MPC for second order linear system with the 10 times bigger control penalty

Page 46: Mana Tavahodi Thesis

43

As it has been shown by increasing the control penalty, the controller will be less

effective; therefore the settling time is bigger.

Example 2

In this example we consider a non-linear second order plant, where the differential

equation of the system is:

uxxdt

dx

xdtdx

+−−=

=

212

21

1.)sin(

This can be considering as a simplified model of a SMIB (section 2.3). Here to solve

the differential equation the ODE23 command has been used (section 2.6.2). The

cost function will be the same as the previous example. The prediction horizon will be

30 with the control horizon of 15.

The behaviour of the system before applying the controller to it is shown in graph

bellow. (MATLAB codes are available in appendix1)

0 5 10 15 20 25 30 35-1.5

-1

-0.5

0

0.5

1

1.5

Time(sec)

State value

Figure3.5: The step response of the linear second order system

The result of the control action and the state response to the control at each

sampling instant is demonstrated in the following graphs. In this case the cost

function was

)()(min

0

22

2∑∞

=

+=k

k xuxJ

Page 47: Mana Tavahodi Thesis

44

0 5 10 15-1

0

1

Time(sec)

Con

trol v

alue

0 5 10 15-1

0

1

Time(sec)

Sta

te v

alue

0 5 10 150

1

2

Time(sec)

Cos

t val

ue

Figure3.6: The result of the MPC for second order nonlinear system

The performance of the MPC is seen figure 3.3, 3.4 and 3.5 in both systems

(nonlinear and linear) was effective enough to eliminate the oscillation after 10 secs.

This example shows that the MPC can easily handle nonlinearity in the system. The

sampling rate is an important factor for implementation. The period of the

electromechanical oscillations for this system is 6 seconds. Therefore, according to

the Nyquist theory the sampling frequency should be faster than 0.3 Hz. In this case

the sampling rate is chosen as 1Hz to achieve good control.

Page 48: Mana Tavahodi Thesis

45

Reference:

[1]. S.J. Qin, and T.A. Badgwell, “An overview of industrial model predictive control

technology”, In chemical process control CPC V, California, 1996.

[2]. EF. Camacho and C. Bordons, “Model Predictive Control”, Springer-Verlag, London,

1999.

[3]. N. Sandell et al, “Survey of decentralized control methods for large scale systems”,

IEEE Trans, Automat. Contr., Vol. 23, pp.108-128,April 1978,

[4]. H. Duwaish and W. Naeem, “Nonlinear model predictive control of Hammerstein and

Wiener Model using Genetic Algorithms”, Proceedings of the 2001 IEEE International

Conference, Sept. 2001

[5]. D.W. Clarcke, C. Mohtadi and P.S. tuffs, “Generalized predictive control. Part I. The

Basic Algorithm” Automatica, pp. 137-148, 1987

[6]. Y. Zhu, E. Arrieta, F.Butoyi and F.Coryes, “ Parametric versus Nonparametric models

in MPC Process Identification” Hydrocarbon Processing , Vol. 79, 2000.

[7]. D. Limon, T. Alamo, F. Salas and E.F. Camacho, “On the stability of constrained

MPC without terminal constraint”, IEEE Trans on Automat. Contr., May 2006, Vol.

51, pp. 832-836.

[8]. R. Kalaba and K. Spingarn, “Control, Identification, and Input Optimization”, New

York, 1982.

[9]. D.S. Naidu, “Optimal Control System”, CRC Press LLC, New York, 2003

[10]. P. Boggs and J. Tolle, “Sequential quadratic programming,” Acta Numerica , pp. 1–

52, 1995.

[11]. L. E. Scales, “Introduction to Non-Linear Optimization”, New York, Macmillan, 1985.

[12]. J.A. Snyman, “Practical Mathematical Optimization: An introduction to basic

optimization theory and classical and new gradient-based algorithms”, Kluwer

Academic Publishers, Dordrect, The Netherlands, 2004.

Page 49: Mana Tavahodi Thesis

46

Chapter 4

4. KALMAN Filter

It was mentioned in chapter 1 that a Kalman filter is utilized for estimation of the state

value in the decentralised MPC approach. In this chapter a brief review on the

theory behind the filter is discussed.

4.1 Introduction

The Wiener filter [4] is used to estimate a signal process in a set of noisy

observation, for stationary and continuous-time system. This limits the filter’s usage

in practical applications. A famous paper in 1960 by R.E Kalman described a

recursive solution to the discrete- data linear computing problem [1]. The Kalman

filter is an optimum estimator that estimates the state of a system developing

dynamically through time that can distribute the fixed condition which makes it more

applicable in variable processes.

This filter is a set of mathematical equations which provides an efficient

computational means to estimate the state of a process; in a way which it minimizes

the mean of the squared error. The Kalman filter is a very effective filter which is able

to estimate the past, present and future of the states even if the precise nature of the

modelled system is unknown. The Kalman filter is an on-line, recursive algorithm

trying to estimate the true state of a system where only (noisy) observations or

Page 50: Mana Tavahodi Thesis

47

measurements are available. The Kalman filter is a recursive estimator. This means

that only the estimated state from the previous time step and the current

measurement are needed to compute the estimate for the current state, and no

history of observations and/or estimates is required. The general idea of the Kalman

filter can be found in [2]. The Kalman function in MATLAB designs a Kalman state

estimator given a state-space model of the plant and the process and measurement

noise covariance data. The Kalman estimator is the optimal solution to the

continuous or discrete estimation problems. This filter is widely applied to control

application such as aerospace, tracking applications related to vessels, spacecraft,

and radar and target trajectories [3]. This chapter includes discussion of the basic

discrete Kalman filter and some discussion of the extended Kalman filter.

4.2 The Discrete Kalman Filter

Consider a discrete dynamic system, in other word, signals will be observed at

equally spaced points in time (sampling instant). If a linear discrete-time system

represented as.

kkkk uxx ω++=+ BA1 (State equation) (4.1)

kkk xy υ+= C (Measurement equation) (4.2)

Where the random variables kω and kυ represent the process and measurement

noise respectively ( kω is a zero mean white noise uncorrelated with kυ ).

0}{}{ == Tji

Tji υυεωωε if ji ≠ (4.3)

And their covariance are defined by:

R

QT

kk

Tkk

=

=

}{

}{

υυε

ωωε (4.4)

The optimum state estimation solution that minimizes the mean square error between

the estimate state )ˆ( kx and state )( kx is:

Page 51: Mana Tavahodi Thesis

48

)~(~ˆ kkkk xyxx CL −+= (4.5)

Where kx~ is a priori estimate, kx is the posterior estimate state, the term of

)~( kk xy C− is called residual which presents the discrepancy between the predicted

measurement kx~C and actual measurement ky . L is a constant matrix which is

known as the Kalman gain that defined by following equations.

If the ke and ke~ are the priori and posterior estimate error respectively:

kkk

kkk

xxexxe~~ˆˆ

−=−=

(4.6)

Therefore the priori and posterior estimate error covariance are:

]~~[~]ˆˆ[ˆ

Tkkk

Tkkk

eeEP

eeEP

=

= (4.7)

The mn× matrix L in (4.5) is the Kalman gain which minimizes the posterior error

covariance.

1)~(~ −+= RPP Tk

Tkk CCCL (4.8)

Equation (4.8) shows the maximum gain is when the measurement error covariance

R approaches zero which means that the actual measurement is more and more

reliable whilst the predicted measurement is less trusted. On the other hand if the

prior estimate error covariance kP~ approaches zero the again will move towards zero

in this case the actual measurement is less reliable while the predicted measurement

is more trusted.

Algorithm of the Kalman filter according to G.F. Franklin et al [4] can be divided in

two steps:

1. Time update

2. Measurement update (Fig. 4.1)

Page 52: Mana Tavahodi Thesis

49

Figure 4.1: Kalman filter structure

In the first step, at the k th sample by using the current states and the estimate

covariance error the priori estimates (4.9) for the next time step are obtained.

kkk uxx BA +=+ ˆ~1 (4.9)

QPP Tkk +=+ AA1

~ (4.10)

Where 1~

+kx is the priori state estimated for the next step and 1~

+kP is the priori

covariance estimate error in the next step whilst Q is the covariance of process noise

from (4.4). This step happens between the measurements.

In the next step the residue of the priori estimates and the new measurement

improves the posterior estimates and from the new measurement the Kalman gain

L is computed (4.12). This process is a form of feedback control which the filter

estimates the states at a sampling instant and get the feedback in a form of a noisy

measurement.

)~(~ˆ 11111 +++++ −+= kkkkk xyxx CL (4.11)

1111 )~(~ −+++ += RPP T

kT

kk CCCL (4.12)

Since L is time varying and obtain based on minimizing the errors, give us a priori

knowledge of the process and measurement noises magnitude [4]. It is obvious that

the smaller the error, the better state estimation.

y u

Plant

Kalman filter

+

Page 53: Mana Tavahodi Thesis

50

For infinite time horizon state estimation with White Gaussian noise the optimal

solution is constant Kalman gain. For finite time estimation problem Kalman gain is

time varying equation (4.12). For computational simulation and because time

duration is not clearly defined, we chose to implement constant Kalman gain. The

Kalman filter with constant gain has the same structure that has been explained

previously. The only difference is that in this case L and the estimate error is

computed for an assumed level of process and measurement noises. This method is

called steady-state optimal estimation. The steady-state Kalman filter gain is

obtained from (4.13):

1)~(~ −∞∞∞ += RPP TT CCCL (4.13)

This is the standard calculation which is used in MATLAB command KALMAN. in this

comment the Kalman gain L is obtained through an algebraic Riccati equation [5].

[kest,L,P] = kalman (sys,Qn,Rn,Nn)

With known inputs u, process noise w, measurement noise v, and noise covariances

E{ww'} = Qn E{vv'} = Rn E{wv'} = Nn. For steady-state filter design Qn and Rn

can be assumed to be one (as an initial value).

In the practical application, the modelling error for designing the filter causes some

problems. There are two major limitations for the value of the gain which affects the

robustness of the estimation. Firstly, for a small gain the estimation would not be

accurate, and that confuses the control actions. Secondly, the gain cannot be so big

that the small noises will be multiplied by the gain and large state error will remain at

the end.

This modelling error can be very severe for a nonlinear dynamic model which

involves the estimation base on the linear model of the system. In such cases

Page 54: Mana Tavahodi Thesis

51

Extended Kalman Filter (EKF) approach appears to be computationally efficient

candidate for nonlinear dynamics.

4.3 The Discrete-time Extended Kalman Filter (EKF)

The Kalman filter theory applies to linear-Gaussian problems, but most importantly

can contribute to real world applications which are nonlinear and/or non-Gaussian.

Although this nonlinear estimation problem is hard to solve, the engineer uses linear

approximation to make this theory fit the nonlinear problems that are encountered in

the real world. There are various practical approximation methods available; the

extended Kalman filter (EKF) [6] is the most useful method which has achieved broad

acceptance. To compare this approach to linear approximation in real time

implementation, linearised filtering is more computationally efficient but it is less

robust compared to the EKF. The EKF is the same as the Kalman filter which is a set

of mathematical equations which uses an underlying process model to make an

estimate of the current state of a system and then corrects the estimate using any

available sensor measurements.

The EKF assumes linearity only over the range of state estimation errors. The

estimation can be linearised around the current estimate using the partial derivatives

of the process and measurement functions to compute estimates even in face of

nonlinearity.

Consider a nonlinear discrete-time system represented by:

),,(1 kkkk uxfx ω=+ (4.14)

),( kkk xgy υ= (4.15)

Where kω and kυ are process and measurement noise respectively. f and g are the

nonlinear function in difference equation form. kx is the previous state estimation and

1+kx is the current state estimation.

Page 55: Mana Tavahodi Thesis

52

Following the same structure that was explained in the previous section, the prior and

posterior state estimation will be obtained by:

),(~1 kkk uxfx )=+ (4.16)

))~((~ˆ kkkk xgyxx −+= L (4.17)

In order to find the Kalman gain L and kx~ for updating the measurement we have to

find the covariance error which can be found by the following difference equations:

kxxk xfF =∂∂

= ˆ| (4.18)

tFkk Δ+=Φ I (4.19)

Where tΔ is the sampling interval and kF is the Jacobian matrix of partial derivatives

of f with respect to x .The covariance error updated value is obtained by:

kT

kkkk QPP +ΦΦ=+1~

(4.20)

If kG is the Jacobian matrix of partial derivatives of g with respect to x then the

Kalman gain will be calculated by equation (4.22).

kxxk xgG =∂∂

= ˆ| (4.21)

RGPG

GPT

k

Tk

k +=

+

++

1

11 ~

~L (4.22)

And finally the posterior state estimation obtains by:

))~((~ˆ 11111 +++++ −+= kkkkk xgyxx L (4.11)

Up to this point, the expected behaviour of the Kalman was discussed. As was

explained, the filter gain characterized by the covariance matrix of estimation

uncertainty is found by solving the Riccati difference equation. This should be optimal

with respect to all quadratic loss functions which the Kalman gain depends on. If this

is not true an ill-conditioned Kalman filter problem can occur.

Page 56: Mana Tavahodi Thesis

53

An ill-conditioned problem is defined as having the high sensitivity of the error in the

out put to variance in the input data.

This problem happens in the Kalman filter due to the:

• Modelling error(large uncertainties in the matrix parameters value

( Φ,,,,, RCBAQ )

• Poor choices of scaling or dimensional units which causes a large range of

actual values of these matrixes.

• Ill-conditioned theoretical of the matrix Riccati equation with numerical error

which will destabilize the filter estimation error

• Large matrix dimensions. The number of arithmetic operations grows as the

square or cube of matrix dimensions, and each operation can introduce round

off errors.

• Poor machine precision which makes the round off errors larger.

This problem doesn’t mean that the filter is not effective. Since in most of the

application these factors are unavoidable, they were mentioned here to be of concern

in the implementation [3].

In order to have better filtering implementation in designing the filter, there are some

methods to reduce the computational requirements. One of the practical

considerations in extended Kalman filter is to compute the Kalman gain in offline

processing. Therefore it is possible to pre-compute the gain and this reduces the real

time computational load. Another way is to reduce the complexities of matrix

products. Gain scheduling is another approximation method for estimation problems

[3]. Finally the steady-state gain for time-invariant systems is the most common use

of the algebraic Riccati equation.

Page 57: Mana Tavahodi Thesis

54

In this thesis the steady-state value is used to find the Kalman gain and as was

mentioned in the pervious section, the steady state method is used to reduce the

computation load. Thus the gain will be constant though the process.

4.4 Summary

The essential equations defining the discrete-time Kalman filter and the extended

discrete-time Kalman filter are summarized in table 4.1.

Discrete-time Kalman filter Extended discrete-time Kalman filter

kkkk uxx ω++=+ BA1 ),,(1 kkkk uxfx ω=+

kkk xy υ+= C ),( kkk xgy υ=

Step 1: Time update

kxxk xfF =∂∂

= ˆ|

kkk uxx BA +=+ ˆ~1

2)ˆ()ˆ(ˆ~

2

1txfFtxfxx kkkkk

Δ+Δ+=+

QPP Tkk +=+ AA1

~ k

Tkkkk QPP +ΦΦ=+1

~

kxxk xgG =∂∂

= ˆ|

Step 2: Measurement update

RPP

Tk

Tk

k +=

+

++ CC

CL

1

11 ~

~

RGPGGPT

k

Tk

k +=

+

++

1

11 ~

~L

)~(~ˆ 11111 +++++ −+= kkkkk xyxx CL ))~((~ˆ 11111 +++++ −+= kkkkk xgyxx L

Table 4.1: summarized equations defining the discrete-time Kalman filter and the extended discrete-

time Kalman filter

Page 58: Mana Tavahodi Thesis

55

Reference:

[1]. R.E. Kalman, “A New Approach to Linear Filtering and Prediction Problems”,

Transaction of the ASME-journal of Basic Engineering, pp.35-45, March 1960.

[2]. P.S Maybeck, “Stochastic Models, Estimation, and Control”, vol I, Academic Press,

Inc, 1979.

[3]. M.S. Grewal and A.P Andrews,”Kalman filtering: Theory and Practice”, Prentice-Hall,

New Jersey, 1993.

[4]. G.F. Franklin, J.D. Powell and M. Workman, “Digital Control of Dynamic System”,

Third Edition, Addison-Wesley, 1998.

[5]. B.N. Datta, “ Numerical Methods for Linear Control Systems”, Elsevier Academic

Press, London, 2004.

[6]. J.J. LaViola Jr. “A comparison of unscented and extended Kalman filtering for

estimating quaternion motion”, IEEE American Control Conference, Vol. 3, pp.2435-

2440, June, 2003.

Page 59: Mana Tavahodi Thesis

56

Chapter 5

5. Centralized MPC

In these case studies we will firstly implement a centralised MPC in order to control

the excitation in the SMIB system. Secondly evaluate the result with the typical

excitation control (lead compensator [1]) on the same system.

5.1 Single Machine Infinite Bus (SMIB)

Consider a single machine infinite bus Fig. 5.1, with an infinite bus voltage V, and the

internal voltage E. The acceleration of the machine voltage angle δ is given by the

swing equation (2.14) where Lx is the admittance of the line.

Figure 5.1: Single machine infinite bus

Page 60: Mana Tavahodi Thesis

57

To represent the flux change and the basic machine dynamics, the generating unit is

modelled by a third order system using the classical model and the first order IEEE

excitation system that was explained in chapter 2. Therefore for the lossless line

system, the state equations of this system will be:

ωδ=

dtd

(5.1)

mPEVx

DdtdM +−−= )sin(1 δωω

(5.2)

uVeAKETdt

dER

EBEXE

E

EX +++−= ])()[1( (5.3)

The system is working in the steady state condition. The large disturbance is applied

to the system for short period of time. The fault in this case is a three phase short

circuit in the line that has been explained before. The period of the electromechanical

oscillations for this system is 7 seconds. Therefore, according to Nyquist theory the

sampling frequency should be faster than 0.28 Hz. In this case the sampling rate is

chosen as 4Hz to achieve good control. The value of the system parameters and

control parameters value in the simulation are shown in the Table 5.1 and Table 5.2

respectively.

Note: the system values which are used here are based on the value from [2]

(appendix 2) and in order to design the control parameters for this system there are

some points that should be considered.

• To design the control horizon, the controller should observe at least two

cycles of the system oscillation which means that the control horizon should

be at least twice the period of the system.

Page 61: Mana Tavahodi Thesis

58

• Prediction horizon should be long enough to show the action of the controller

in the future.

• In order to have consistency in the result, the model of the system which is

being used in MPC should be similar to the real world system.

Parameters values

Mechanical power ( mP ) .8 p.u.

Damping factor .1

Machine reactance .1 p.u.

Line reactance .3 p.u.

Inertia constant .745

Derived saturation constant for rotating exciters ( EXA )

.0027

Derived saturation constant for rotating exciters ( EXB )

1.9185

Regulator output voltage ( RV ) 1 p.u.

Exciter time constant ( ET ) 1 sec

Exciter self-excitation at full load field voltage ( EK )

1 p.u.

Table 5.1: simulation parameters for SIMB system

Page 62: Mana Tavahodi Thesis

59

Parameters values

Simulation time 30 sec

Prediction horizon 30 sec

Control horizon 15 sample

Table 5.2: simulation parameters for MPC

In order to find the steady state condition of this system, we run the system with a

small disturbance long enough till the system reaches the steady state conditions.

These are the value that we got from this method for our three state values.

0970790.10686998=δ , 0=ω , 1=E

5.2 Centralized MPC for SMIB system

In this section we start our investigation by running the system in the linear region of

the exciter and then add the saturation parameter to the equations. Therefore the

equation (5.3) will be simplified to:

uEdtdE

+−−= )1(α (5.4)

The behaviour of the angle of the uncontrolled simplified system (without saturation

in the exciter) has been shown in the Fig. 5.2.

Page 63: Mana Tavahodi Thesis

60

0 5 10 15 20 25 30

0.7

0.8

0.9

1

1.1

1.2

Time (sec)

Ang

le (R

adia

n)

Figure 5.2: Uncontrolled angle behaviour of the basic SMIB system

The graph shows that at the start, the system is working at steady state condition;

after 1 second that the fault occurs, and the system starts oscillating. The figure

demonstrates that the oscillation is slowly damped. As the graph shows, after 30

seconds, the system still did not reach the steady state condition.

In equation (5.1), in order to reach the steady state condition, the value of velocity of

the machineω is equal to zero, and thus 0=dtdδ

. The cost function of the controller

for this system from equation (3.3) can be selected in equation (5.5):

22 ωγ += uJ (5.5)

The next step is to design a model of the system for MPC. Since we are using the

centralized MPC the MPC model would be the complete system (third order

machine).

First we start at stable initial condition, and then at each sampling instant the value of

state is sent to the MPC unit Fig. 5.2. Secondary the optimization will minimize the

cost function which is based on the MPC model. From this part the control vector will

be found which this vector is the control values through the prediction horizon. Finally

the first control value will be sent to the real system and for the next sample rate.

Page 64: Mana Tavahodi Thesis

61

Figure 5.2: MPC structure

The results of the simulation for the basic model of centralized MPC on SMIB system

are shown below.

0 5 10 15 20 25 300.9

0.95

1

1.05

1.1

1.15

1.2

1.25

Time(Sec)

Ang

le(R

adia

n)

Figure 5.3: Controlled angle behaviour of the SMIB system by centralized MPC

Fig. 5.3 shows the controlled angle behaviour of the SMIB system by centralized

MPC. If we compare this graph with the uncontrolled angle behaviour of the system

Fig. 5.2, it is clear that the controller is very effective in that it almost cancelled the

oscillation after the first cycle. Note that the control penalty γ which is used here was

Page 65: Mana Tavahodi Thesis

62

.01 with a limited band of 11 <<− u . The control result is shown point by point in

Fig.5.4

0 5 10 15 20 25 30-0.2

-0.15

-0.1

-0.05

0

0.05

0.1

0.15

Time(Sec)

cont

rol v

alue

Figure 5.4: Point by point control value

The optimization behaviour is shown in the Fig. 5.5. In this graph we will be able to

see how optimization process minimizes the cost function through the simulation.

0 5 10 15 20 25 300

0.01

0.02

0.03

0.04

0.05

0.06

Time (Sec)

cost val

ue

Figure 5.5: Cost function value through the simulation

The achieved result is satisfactory; we now add a saturation factor to the excitation in

order to show that using MPC can control the system in the nonlinear region. The

state equation for the general IEEE excitation system is mentioned at equation (5.3)

Page 66: Mana Tavahodi Thesis

63

and (2.18) by substituting the values of table 5.1 in (5.3) the equation (5.6) will be

found. This equation shows since E has a nonlinear component we expect some

frequency changes to compare with the previous system. The behaviour of the angle

before applying the controller will be shown in Fig. 5.6.

EB

EXFDEEXeAEfS == )(

uVSKETdt

dEREE

E

+++−= ])()[1(

ueAEdtdE EB

EXEX +++−= ]1)1([ (5.6)

0 5 10 15 20 25 300.04

0.06

0.08

0.1

0.12

0.14

0.16

0.18

0.2

0.22

0.24

Time (Sec)

Ang

le (R

adia

n)

Figure 5.6: Uncontrolled angle behavior of the basic SMIB system

Fig.5.6 shows that the oscillation damps gradually due to the damping factor which is

explained in section 2.3. As it was explained before, this system is faster than the

previous one. If we activate the controller the same as the previous system, we

expect angle oscillation to be damped after one or two cycles. The angle behaviour

of the machine is demonstrated in Fig. 5.7. This shows the system is working in

linear region. If we increase the band limit of the control which means forcing E to

Page 67: Mana Tavahodi Thesis

64

work closer to the saturation region the system will work in the non-linear region (Fig.

2.5).

0 5 10 15 20 25 300.04

0.06

0.08

0.1

0.12

0.14

0.16

0.18

0.2

0.22

0.24

Time (Sec)

Ang

le (R

adia

n)

Figure 5.7: Angle behavior of the SMIB system controlled by MPC

Fig.5.8 shows the angle behaviour in the nonlinear region when the band limits

increased by 10. As it has been shown in the figure below the damping of the

oscillation is acceptable in spite of the non linearity of the system will be settling

down after few cycles.

0 5 10 15 200.06

0.08

0.1

0.12

0.14

0.16

0.18

0.2

0.22

0.24

Time (Sec)

Ang

le (R

adia

n)

Figure 5.8: Angle behaviour of the SMIB system controlled by MPC working in non-linear

region

The control value of the simulation result is shown in Fig. 5.9.

Page 68: Mana Tavahodi Thesis

65

0 5 10 15 20 25 30-0.4

-0.3

-0.2

-0.1

0

0.1

0.2

0.3

Time (Sec)

cont

rol v

alue

Figure 5.9: Angle behaviour of the SMIB system controlled by MPC working in non-linear

region Up to here, the ability of the Centralised MPC on the SMIB system has been

explained and showed how effective it behaves in different situations. These results

support the idea of using centralized MPC to stabilize the system by controlling the

field voltage. This statement is confirmed by using the typical excitation control and

compares the results of these two controllers. The next section will investigate the

behaviour of the system by using the lead compensator for the above system.

5.3 Typical excitation controller for SMIB system

As it was mentioned previously in this section the basic SMIB system which is going

to be used. In order to design a lead compensator which is a linear control, the first

step is to linearise the system. There are different methods for linearising a nonlinear

system. Here we used the “linmod” command in MATLAB. LINMOD obtains the

state-space linear model of the system of ordinary differential equations (ODEs)

described in the S-function 'SFUNC' when the state variables and inputs are set to

zero. SFUNC can be a SIMULINK model or m-file models.

[A,B,C,D]=LINMOD('SFUNC',X,U)

Page 69: Mana Tavahodi Thesis

66

This command allows the state vector, X, and input, U, to be specified. A linear

model will then be obtained at this operating point.

The next step in controller design is to find the place of poles and zeros of the system

here we used the SISOTOOL command in MATLAB. The next two figures (Fig.5.10

and Fig.5.11) show the Root Locus of the system and the compensator design.

Figure 5.10: The pole-zero placement of the machine

Figure 5.11: compensator design

Page 70: Mana Tavahodi Thesis

67

As it has been shown in Fig.5.11 the designed of a standard lead compensator for

this machine is calculated at:

1111.36.5)(

++

=sssG (5.7)

The simulation result of using this controller for the excitation of the system is show in

the next two figures.

0 5 10 15 20 25 300.86

0.88

0.9

0.92

0.94

0.96

0.98

1

1.02

1.04

Time (Sec)

Ang

le (R

adia

n)

Figure 5.12: Angle after applying a typical excitation controller

0 5 10 15 20 25 30-0.015

-0.01

-0.005

0

0.005

0.01

0.015

Time(Sec)

cont

rol

Figure 5.13: value of a typical excitation controller

Page 71: Mana Tavahodi Thesis

68

The above figures show that the linear controller will damp the oscillation in the angle

but to compare it with the result of the MPC in Fig. 5.3, the system will achieve the

equilibrium point within one cycle of oscillation. This is a considerable improvement

over the system controlled by a typical excitation controller stabilized by standard

lead block equation (5.7) as it has been demonstrated in Fig. 5.12.

5.4 Summary

In this chapter we applied a direct MPC to the power system which was subjected to

a large disturbance (three phase short circuit). In direct or centralized MPC the whole

system is modelled and all the computation is done in one optimization. The results

of the simulation showed that the centralized MPC was an effective non-linear

controller which was able to damp the system oscillation significantly. MPC not only

was effective in the linear region but also showed that it can handle the stability in

non-linear region in an efficient way.

The result of MPC was compared to the typical excitation controller which is showed

that MPC is two times more effective than the lead compensator. MPC eliminated the

system oscillation after one cycle and system returned to steady state condition after

15 second which by using the compensator the system still oscillating after 30

second.

Page 72: Mana Tavahodi Thesis

69

References

[1]. L. Hajagos, “ An update on power system stabilization via excitation control”

Power Engineering Society General Meeting, 2003,IEEE, vol.3, July 20003

[2]. P. M. Anderson, A. A. Fouad, and Institute of Electrical and Electronics

Engineers “Power System Control and Stability” 2nd ed. Piscataway, N.J.:

IEEE Press; Wiley-Interscience, 2003.

Page 73: Mana Tavahodi Thesis

70

Chapter 6

6. Novel Decentralized MPC Approach

In the previous sections, MPC was implemented in a centralized fashion. The

complete system is modelled, and all control inputs are computed in one optimization

problem. Direct MPC on the system, as shown in single machine infinite bus

example, is very effective but in a complex system with hundreds of machines there

would be some difficulties. For instance

• The first issue is that in MPC we need to have a complete knowledge of the

states at every step for the model to predict the future control steps. In a

complex system, due to the lack of information, the prediction of the model

would be difficult to achieve.

• The other issue is the computation cost; in a large system, to optimize the

cost function for all the system with many controllers and steps would be very

time consuming and may exceed computational capacity for real time

optimization

Page 74: Mana Tavahodi Thesis

71

6.1 Combination of Decentralise MPC and Energy function

design in multi-machine system

To address these issues, it is proposed to apply a MPC on a local machine in a

decentralized fashion. The best tool which provides the ability to design changing flux

is to use the energy function design which was explained in section 2.7. By

maximizing the rate of reduction of kinetic energy, the required field voltage is

designed to stabilize the system.

In implementing the controller, a Kalman filter can help in computing and predicting

the states for the machine from the little knowledge which is gained from the system

at each sampling time. From the estimation of Kalman filter the MPC will be able to

have a reasonable understanding of the model and also using the field voltage

prediction (from the energy function) as a reference for the optimizer (Fig. 6.1).

Figure 6.1: control structure

Estimate states (Kalman filter)

Field voltageprediction

Optimization

MPC model

Reference for MPC Error

MPC

Page 75: Mana Tavahodi Thesis

72

Fig 5.14 shows that Kalman filter and Energy function design will assist in the use of

MPC in a decentralized fashion. The kalman filter provides the required information

of the whole system and the expected field voltage of the machine will be calculated

by using energy function. By using this decentralised method, the computation cost

in the optimization will be significantly reduced since we optimize using only the local

machine model instead of the model of the whole system. This computational gain is

a valuable advantage in large interconnected systems.

At each sampling instant, the state of the system will be estimated by Kalman filter

and the estimated state will be sent to the MPC model and the field voltage prediction

unit. In the prediction unit, the field voltage of the local machine is calculated by

maximizing the rate of reduction of kinetic energy at each sampling instant and the

field voltage of the machine will be predicted using the length of MPC prediction

horizon. The predicted field voltage will be sent to the optimization unit and it will be

used as a reference for MPC. In MPC unit the state estimated by kalman filter is used

to find the field voltage of the machine. Then the difference between the reference

and the value achieved in MPC model is minimized. This optimization of the error will

provide a vector of control values through out the prediction horizon. Then the first

control value will be applied to the machine. This procedure will be repeated for each

sampling instant.

Page 76: Mana Tavahodi Thesis

73

6.2. Application to Multi-Machine System

In this section the proposed method is applied to a three-machine system which is

subjected to a three-phase short circuit. The control is designed in three steps;

• Kalman filter design,

• Energy function design

• MPC.

The system which is considered here is a three machine system (Fig.6.2). The

simplified classical model followed by the typical assumptions is used with an IEEE

Type-1 excitation system [chapter 2]. Basically the same principle used for the single-

machine infinite bus case is followed here.

Figure 6.2: Three machines structure

The state equations for the system will be:

11 ω

δ=

dtd

(6.1)

1311113

211112

11 )sin(1)sin(1

mPVEx

VEx

Ddt

d+−−−−−= δδδδω

ω (6.2)

111 ])()[1( 1 uVeAKE

TdtdE

REB

EXEE

EX +++−= (6.3)

22 ω

δ=

dtd

(6.4)

Page 77: Mana Tavahodi Thesis

74

2322223

122221

22 )sin(1)sin(1

mPVEx

VEx

Ddt

d+−−−−−= δδδδω

ω (6.5)

222 ])()[1( 2 uVeAKE

TdtdE

REB

EXEE

EX +++−= (6.6)

33 ω

δ=

dtd

(6.7)

3233332

133331

33 )sin(1)sin(1

mPVEx

VEx

Ddt

d+−−−−−= δδδδω

ω (6.8)

333 ])()[1( 3 uVeAKE

TdtdE

REB

EXEE

EX +++−= (6.9)

Here machine 1 is considered to work as a generator and the other two machines act

as motors. The system is working in the steady state condition. A large disturbance

is applied to the system for short period of time. The fault in this case is a three

phase short circuit in the line between machine 2 and 3. The period of the

electromechanical oscillations for this system is slower than 2.5 seconds. Therefore,

according to Nyquist theory the sampling frequency should be faster than 0.4 Hz. In

this case the sampling rate is chosen as 2Hz to achieve good control. The value of

the system parameters and control parameters value in the simulation are shown in

the Table 6.1.

Page 78: Mana Tavahodi Thesis

75

Parameters

Machine 1

values

Machine 2

values Machine 3

values

Mechanical power ( mP ) .7 p.u. .35 p.u. .35 p.u.

Damping factor .1 .1 .1

Inertia constant 1.617 1.165 .745

Impedance 12B =1.513 23B =1.088 13B =1.226

Derived saturation constant for rotating exciters ( EXA )

1.1

1.1

1.1

Derived saturation constant for rotating exciters ( EXB )

2.3979

2.3979

2.3979

Regulator output voltage ( RV ) 1 p.u. 1 p.u. 1 p.u.

Exciter time constant ( ET ) 1 sec 1 sec 1 sec

Exciter self-excitation at full load field voltage ( EK )

1 p.u. 1 p.u. 1 p.u.

Simulation time 30 sec 30 sec 30 sec

Prediction horizon 30 sec 30 sec 30 sec

Control horizon 15 15 15

Control gain (α ) 8 8 8

Table 6.1: simulation parameters for three machine system

Page 79: Mana Tavahodi Thesis

76

The steady state condition of this system has been found by the same method for

SMIB system that explained before. These are the value that we got from this

method for all the states.

2624290.223034731 =δ , 01 =ω , 11 =E

1031470.02599372- 2 =δ , 02 =ω , 12 =E

1159279-0.04704103 =δ , 03 =ω , 13 =E

By looking at the Fig.6.3, the first step is to design a Kalman filter. In the next section

6.3 we will explain the application of the Kalman filter for estimating the states in this

system (the theory of the Kalman filter has been explained in chapter 4). The angle

difference behaviour of the basic system (without the saturation factor in excitation)

before applying the control is demonstrated in Fig.6.3 after system subjected to a

three phase short circuit disturbance.

0 2 4 6 8 10 12 14 16 18-0.03

-0.02

-0.01

0

0.01

0.02

0.03

0.04

0.05

0.06

0.07

Time (Sec)

Ang

le d

iffer

ence

(Rad

ian)

Angle difference between machine 2 and 3

0 5 10 150.245

0.25

0.255

0.26

0.265

0.27

0.275

0.28

0.285

0.29

0.295

Time (Sec)

Ang

le d

iffer

ence

(Rad

ian)

Angle difference between machine 1 and 3

0 2 4 6 8 10 12 14 16 180.2

0.22

0.24

0.26

0.28

0.3

0.32

Time(Sec)

Ang

le d

iffer

ence

(Rad

ian)

Angle difference between machine 1 and 2

Figure 6.3: Angle difference behavior without any controller

Page 80: Mana Tavahodi Thesis

77

To have a better control over the system, if there are n machines, n-1 controllers are

desirable. For example, in the three machine case there are controllers implemented

on two of the machines, where u2 and u3 represent the control actions on machine

two and three respectively.

6.3 Kalman filter design

The theory of this filter was explained in detail in chapter 4. A Kalman filter is located

at each machine. In order to use the discrete Kalman filter we need to linearise the

system as it was mentioned before to linearzie the system we used the LINMOD

command in MATLAB. Since the system is in continuous form by using the C2D

command we can change the system into a discrete form and then we used the

KALMAN command by considering a value of .1 for the process noise weight matrix

nQ by using the trial and error methods. The error of the designed filter for three

machines is shown in Fig.6.4. In part (a) the error of the filter between machine 1 and

machine 2 is demonstrated, in part (b) and(c) the Kalman error between machine

1&3 and the Kalman error between machine 2&3 is shown respectively. It can be

seen that for all the three machines a small error exist in the first cycle of our filter.

Note that for our filter design we don’t have complete knowledge of the whole

system. At each machine the only information that we have is the power flow

between two machines from equation (2.15) we can achieve the angle difference of

two connected machines and the field voltage of the local machine. Fig. 6.5 shows

the angle difference of the real system and the estimated states of three machines by

our filter. The model that is used is the basic form which means without considering

the saturation factor in the excitation.

Page 81: Mana Tavahodi Thesis

78

0 2 4 6 8 10 12 14 16 18-2

0

2

4

6

8

10

12x 10

-3

Time (Sec)

Kal

man

erro

r of m

achi

ne 1

&2

0 2 4 6 8 10 12 14 16 18

-10

-8

-6

-4

-2

0

2x 10

-3

Time (Sec)

kalm

an e

rror o

f mac

hine

1&

3

(a) (b)

0 2 4 6 8 10 12 14 16 18-12

-10

-8

-6

-4

-2

0

2x 10

-3

Time (Sec)

kalm

an e

rror o

f mac

hine

2&

3

(c)

Figure 6.4: discrete time Kalman error

0 2 4 6 8 10 12 14 16 180.2

0.22

0.24

0.26

0.28

0.3

0.32

Time(Sec)

Ang

le d

iffer

ence

(Rad

ian)

Angle difference 12Estimate angle difference 12

0 5 10 15

0.245

0.25

0.255

0.26

0.265

0.27

0.275

0.28

0.285

0.29

0.295

Time (Sec)

Ang

le d

iffer

ence

(Rad

ian)

Angle difference 13xhat 13

(a) (b)

0 2 4 6 8 10 12 14 16 18-0.03

-0.02

-0.01

0

0.01

0.02

0.03

0.04

0.05

0.06

0.07

Time (Sec)

Ang

le d

iffer

ence

(Rad

ian)

Angle difference 23xhat 23

(c)

Figure 6.5: Angle difference of the real system and the estimate angle by discrete time Kalman filter

Page 82: Mana Tavahodi Thesis

79

The problem with the discrete time Kalman filter in this system is that the linear

model system can be a good model when a small perturbation exists in the real

model and the non-linearity in the system could limit the control action. This deviation

between the linear model and the non-linear model lead us to use the extended

Kalman filter which has been explained previously in section 4.3. In order to use the

extended Kalman filter instead of the using LINMOD we can directly use the ODE23

of the simplified system. We used simplified system due to the lack of information of

the whole system.

Therefore here for example the state equation of the machine 1 can be written as:

1212 ωδ

=dt

d (6.10)

21121131223131131211212 )sin()sin()sin(2 mm PPDYEYEY

dtd

++−−−−−= ωδδδδω

(6.11)

1313 ωδ

=dt

d (6.12)

31131121323121121311313 )sin()sin()sin(2 mm PPDYEYEY

dtd

++−−−−−= ωδδδδω

(6.13)

1111 )( uVE

dtdE

R ++−= (6.14)

Since our controller works in discrete time the duration of the ODE23 time span

should be the same as our sampling time. Therefore we can estimate the states of

the system into the future based on the discrete non-linear values. The result of our

extended filter design has been shown in the next page.

The error of the designed filter for three machines is shown in Fig.6.5. In part (a) the

error of the filter between machine 1 and machine 2 is demonstrated, in part (b)

and(c) the Kalman error between machine 1&3 and the Kalman error between

machine 2&3 is shown respectively. It can be seen that for all the three machines still

there is a small error exist in the first cycle of our filter.

Page 83: Mana Tavahodi Thesis

80

0 2 4 6 8 10 12 14 16 18-0.05

0

0.05

0.1

0.15

0.2

0.25

0.3

Time (Sec)

kalm

an e

rror o

f mac

hine

1&

2

0 2 4 6 8 10 12 14 16 18

0

0.1

0.2

0.3

0.4

0.5

0.6

0.7

0.8

0.9

1

Time (Sec)

Kal

man

erro

r of m

achi

ne 1

&3

(a) (b)

0 5 10 15-0.005

0

0.005

0.01

0.015

0.02

0.025

Time (sec)

Kal

man

erro

r of m

achi

ne2&

3

(c)

Figure 6.5: Extended Kalman filter error

0 2 4 6 8 10 12 14 16 180.16

0.18

0.2

0.22

0.24

0.26

0.28

0.3

0.32

0.34

Time (Sec)

Ang

le d

iffer

ence

(Rad

ian)

Angle difference 12xhat 12

0 2 4 6 8 10 12 14 16 18

0.18

0.2

0.22

0.24

0.26

0.28

0.3

0.32

0.34

0.36

Time (Sec)

Ang

le d

iffer

ence

(Rad

ian)

Angle difference 13xhat 13

(a) (b)

0 2 4 6 8 10 12 14 16 18-0.02

-0.01

0

0.01

0.02

0.03

0.04

0.05

0.06

Time (Sec)

Ang

le d

iffer

ence

(Rad

ian)

Angle difference 23xhat 23

(c)

Figure 6.6: Angle difference of the real system and the estimate angle by extended Kalman filter

Page 84: Mana Tavahodi Thesis

81

6.4 Field voltage prediction unit

At each sampling time, we receive the measurement of the power angle differences

between local machine and the other two machines. Then the Kalman filter predicts

the states respect to the measurement error and process error. Another look at the

Fig 6.3 shows that this estimation from the Kalman filter can be sent to the MPC

model of the system and to the filed voltage prediction units.

After designing the Kalman filter the next step is predicting the field voltage by using

kinetic energy. At each sampling time the estimated state vector from the Kalman

filter passes through the voltage predictor. In the predictor, by using the method that

explained in chapter 2, equation (2.36), the desired flux of the local machine will be

predicted. Then the system will be simulated for a period of one sample time with the

new flux from maximising the convergence rate of the kinetic energy function which

can be assured of being positive definite. For the simulation we use ODE23 from

MATLAB of the system with the time span of the sampling time period. By using this

time span despite that ODE23 is continuous, the result would be in discrete. This

simulation of the system will be continuing in this unit for the duration of the

prediction horizon. At the end we will achieve the desired flux of the system for the

duration of the prediction horizon which can be used as a reference for the MPC.

Fig.6.7 will demonstrate the result of the field voltage prediction of the local machines

(machines 2 and 3) in this unit. It can be seen that if the controllers could not make

the exciter settle down fast enough, the designed flux for energy function design will

be the best reference for the controller to follow. The figure shows that the system

starts at the steady state condition and after the disturbance occurs, the flux

oscillates and gets back to the steady state conditions almost after three cycles.

Page 85: Mana Tavahodi Thesis

82

0 2 4 6 8 10 12 14 16 180.75

0.8

0.85

0.9

0.95

1

1.05

1.1

1.15

Time (sec)

Fiel

d vo

ltage

pre

dict

ion

Result in machine 2

0 2 4 6 8 10 12 14 16 180.8

0.85

0.9

0.95

1

1.05

1.1

1.15

1.2

Time (Sec)

Fiel

d vo

ltage

pre

dict

ion

Result in machine 3

(a) (b)

Figure 6.7: a) Designed field voltage prediction for machine 2

b) Designed field voltage prediction for machine 3

6.5 MPC unit

In this unit we will use the information from both the field voltage prediction unit and

Kalman filter estimation. The designed flux gained from the previous unit will be used

as a reference for the MPC and from the filter estimation the field voltage can be

found through the MPC model. As it was explained in chapter 3 equation (3.4) the

error of these two is used for the cost function in the optimizer followed by the control

value. Therefore; the same method used previously in the SMIB system we use

FMINCON command in MATLAB to optimizing the error at each sampling rate. Note

that in this approach the MPC model is just a first order equation for excitation. This

will reduce the computation cost in comparison to using the whole model of the

system.

Then at each sampling instant a vector of control value for the duration of prediction

horizon is the result of this unit. Then the first value of the control will be sent to the

real system. Fig.6.8 shows how the two controls in local machines (machine 2 and 3)

Page 86: Mana Tavahodi Thesis

83

will force the field voltage of the real system to track the desired designed field

voltage.

0 2 4 6 8 10 12 14 16 180.75

0.8

0.85

0.9

0.95

1

1.05

1.1

1.15

Time (sec)

Fiel

d vo

ltage

Result of machine 2

Er2Eref2

0 2 4 6 8 10 12 14 16 180.8

0.85

0.9

0.95

1

1.05

1.1

1.15

1.2

Time (Sec)

Fiel

d vo

ltage

Result in machine 3

Er3Eref3

(a) (b)

Figure 6.8: a) Real system field voltage tracks the desired field voltage in machine 2 b) Real system field voltage tracks the desired field voltage in machine 3

The next graphs demonstrate the control values point by point of two controllers

located in machine 2 and machine 3. Finally the effect of these controllers on the

angle differences is shown.

0 2 4 6 8 10 12 14 16 18-0.6

-0.5

-0.4

-0.3

-0.2

-0.1

0

0.1

0.2

0.3

Time(Sec)

Rea

l con

trol v

alue

Controller is located in machine2

0 2 4 6 8 10 12 14 16 18-0.8

-0.6

-0.4

-0.2

0

0.2

0.4

0.6

Time (Sec)

Rea

l con

trol v

alue

Controller is located in machine3

Figure 6.9: Control values of both controllers in machine 2 and 3

Page 87: Mana Tavahodi Thesis

84

0 2 4 6 8 10 12 14 16 18-0.02

-0.01

0

0.01

0.02

0.03

0.04

0.05

Time (Sec)

Ang

le d

iffer

ence

(Rad

ian)

Angle difference between machine 2 and 3

0 2 4 6 8 10 12 14 16 180.2

0.22

0.24

0.26

0.28

0.3

0.32

0.34

Time (Sec)

Ang

le d

iffer

ence

(Rad

ian)

Angle differene between machine 1 and 2

0 2 4 6 8 10 12 14 16 180.2

0.22

0.24

0.26

0.28

0.3

0.32

0.34

0.36

Time (Sec)

Ang

le d

iffer

ence

(Rad

ian)

Angle difference between machine 1 and 3

Figure 6.10: Angle difference behaviour of the machines

If we compare the result in Fig.6.5 and Fig. 6.10, clearly the additional controllers

were able to control the oscillation of the angle differences. The damping is more

obvious in the oscillation between machine 2 and 3 due to the existence of a

controller in each machine. It also was effective enough to control the oscillation

between one controlled machine (machine 2 or 3) and one uncontrolled machine

(machine 1).

Since we got a reasonable reason from the controllers (MPC and Energy function

design) we can add the saturation factor in the excitation function and start the

simulation. For the saturation factor we put the exponential function (equation 6.6)

Page 88: Mana Tavahodi Thesis

85

and in Fig 6.11 it has been shown that the predicted field voltage is in the nonlinear

region.

Figure 6.11: saturation function and the field voltage prediction of machine 2

The results of the two controllers’ behaviour, also how the MPC forces the field

voltages of the real system to track the desired designed field voltages has been

shown in the next figures.

0 2 4 6 8 10 12 14 16 18-0.7

-0.6

-0.5

-0.4

-0.3

-0.2

-0.1

0

0.1

0.2

Time (Sec)

Rea

l con

trol v

alue

controller located in machine 2

0 2 4 6 8 10 12 14 16 18-0.4

-0.3

-0.2

-0.1

0

0.1

0.2

0.3

Time (Sec)

Rea

l con

trol v

alue

controller located in machine 3

Figure 6.12: Control values of both controllers in machine 2 and 3

0 0.5 1 1.5 2 2.5 30

0.2

0.4

0.6

0.8

1

1.2

0 .6 0 .8 1 1 .2 1 .4 1 .6

0 .8

0 .8 5

0 .9

0 .9 5

1

1 .0 5

1 .1

1 .1 5Predicted Field voltage of machine 2

Page 89: Mana Tavahodi Thesis

86

0 2 4 6 8 10 12 14 16 180.8

0.85

0.9

0.95

1

1.05

1.1

1.15

Time (Sec)

Fiel

d vo

ltage

Results of machine 2

Er2Eref2

0 2 4 6 8 10 12 14 16 180.85

0.9

0.95

1

1.05

Time (Sec)

Fiel

d vo

ltage

Results of machine 3

Er3Eref3

(a) (b)

Figure 6.13: a) Real system field voltage tracks the desired field voltage in machine 2 b) Real system field voltage tracks the desired field voltage in machine 3

0 2 4 6 8 10 12 14 16 180.2

0.22

0.24

0.26

0.28

0.3

0.32

Time (Sec)

Ang

le d

iffer

ence

(Rad

ian)

Angle difference between machine 1 and 2

0 2 4 6 8 10 12 14 16 180.24

0.25

0.26

0.27

0.28

0.29

0.3

0.31

0.32

0.33

Time (Sec)

Ang

le d

iffer

ence

(Rad

ian)

Angle difference between machine 1 and 3

0 5 10 150.005

0.01

0.015

0.02

0.025

0.03

0.035

Time (Sec)

Ang

le d

iffer

ence

(Rad

ian)

Angle differrence between machine 2 and 3

Figure 6.14: Angle difference behaviour of the machines

These graphs show how effective the controller damps the oscillation, while the

excitation is in the nonlinear region. Although the controller was effective we can’t be

assured that this approach could handle the nonlinearity. The simulation results that

Page 90: Mana Tavahodi Thesis

87

have been proposed do not have enough nonlinearity existent in the system. It can

be described that still system acts like linear. Since there is a fundamental problem in

the system, therefore it limits the control actions.

Page 91: Mana Tavahodi Thesis

88

Chapter 7

7. Limitation in current approach

7.1 Sample time effects

In this section we explain the reason of the limitation of the current implementation of

proposed control method by a simple example.

Example 7.1:

Consider a simple second order nonlinear system:

21 x

dtdx

= (7.1)

uxxdt

dx+−−= 21

2 1.0)sin( (7.2)

This example is similar to our case. If we consider u as control value which is

proportional to 1x& similar to equation (2.36) we find that by increasing the control gain

in a sampled data controller the system will get unstable. This will examined by

looking at the discrete-time poles and zeros locations. The system is linearized with

the sampling frequency of 4 Hz. The discrete transfer function of the system will be:

9753.942.1

2455.2455.)()(

22

+−−

==zz

zzuzxf (7.3)

Page 92: Mana Tavahodi Thesis

89

And the root locus of the system will be:

Figure 7.1: Root locus of the system

Fig. 7.1 shows that there is limitation of increasing the control gain. Too much gain

can lead one pole to be unstable. The maximum gain that we could use before

system oscillated at the Nyquist rate in this example is 3=α . The result of behaviour

of 2x is demonstrated in Fig. 7.2. It can be seen how the system start to show

oscillation with the higher value of control gain.

0 2 4 6 8 10 12 14-0.4

-0.2

0

0.2

0.4

0.6

0.8

1

Time (Sec)

x2

alfa=3

0 2 4 6 8 10 12 14

-0.6

-0.4

-0.2

0

0.2

0.4

0.6

0.8

Time (Sec)

x2

alfa=5

Figure 7.2: velocity changes to the α

If we change the sampling rate for example if we use twice the frequency rate 8Hz

transfer function for this system will be:

9876.979.1

124.124.2

2

+−−

==zz

zux

f (7.4)

Page 93: Mana Tavahodi Thesis

90

Figure 7.3: Root locus of the system

Fig. 7.3 shows the root locus if sampling rate changes to 8 Hz. It can be seen that we

can have the same result as the pervious one by using higher gain.

0 1 2 3 4 5 6 7-0.2

0

0.2

0.4

0.6

0.8

1

1.2

Time (Sec)

x2

alfa=8

0 1 2 3 4 5 6 7

-0.4

-0.2

0

0.2

0.4

0.6

0.8

1

Time (Sec)

alfa=12

Figure 7.4: velocity changes to the α

If we compare the results we are able to increase the gain a bit further before it

started oscillating at the Nyquist rate by decreasing the sampling frequency. This is

expected since one of the poles for higher gain will go to the left hand of the axis Fig

7.3.

Page 94: Mana Tavahodi Thesis

91

7.2 Commentary

In our three-machine two mode case, we tried to use a low sample rate to avoid the

computation cost in the optimization unit of MPC and used the same sample rate for

the prediction unit. These oscillations also can be seen in the result in Fig. 6.7 that

was the starting point of oscillation. The idea here was to use continuous form of

δ& control in the prediction unit and applying that to the discrete system. The system

has also been tested with the real state value instead of the estimation but the same

problem has still existed in the system.

The above example shows that in our three-machine system if we increase the

factor of α in equation (2.36) too far the system will be unstable. This issue does not

let us push the field voltage to the nonlinear region enough to show the clear ability of

the MPC.

Page 95: Mana Tavahodi Thesis

92

Chapter 8

8. Conclusions

The work presented aimed to control the excitation system by predicting the flux of

the system in to the future, based on the energy function design as discussed in

chapter 2. The predicted flux used as a reference for the Model Predictive Control,

force the flux of the real system to track the reference. This method has been

proposed due to the difficulties of using centralized MPC in the system such as:

• The first issue is that in MPC we need to have a complete knowledge of the

states at every step for the model to predict the future control steps. In a

complex system, due to the lack of information, the prediction of the model

would be difficult to achieve.

• The other issue is the computation cost; in a large system to optimize the cost

function for all the system would be very time consuming and may exceed

computational capacity for real time optimization.

Based on the mentioned objective and requirements, novel method was developed

to:

• Design an extended Kalman filter to estimate the state of the system from the

little knowledge which is gain from the system at each sampling time.

Page 96: Mana Tavahodi Thesis

93

• Design changing the flux by using Energy function design. By maximizing the

rate of reduction of kinetic energy, the required field voltage is achieved to

stabilize the system.

• Apply a MPC on a local machine in a decentralized fashion and also using the

field voltage prediction as a reference for the optimizer.

8.1 Summary of the Results

In this section, the main conclusions of the thesis are summarized.

8.1.1 Centralized MPC in SMIB system Theory of the MPC was explained in details in chapter 3. The controller was applied

to a SMIB system after subjected to a three-phase short circuit disturbance.

Typically, MPC is implemented in a centralized fashion. The complete system is

modelled, and all control inputs are computed in a one optimization problem. Direct

MPC on the system as it was shown in SMIB is very effective and it was able to

eliminate the oscillation after one cycle.

8.1.2 Combination of decentralize MPC and energy function design

in three-machine system

Kalman filter design

In chapter 4, the theory of the filter was explained. Since in the discrete Kalman filter

the linear model of the system had been used, the linear model of system can be a

good model when a small perturbation exist in the real model and the non-linearity in

the system could limit the control action. This deviation between the linear model and

the non-linear model led us to use the extended Kalman filter. The extended Kalman

filter was designed for a local machine in the three-machine two mode system. The

Page 97: Mana Tavahodi Thesis

94

results of the simulation showed that filter was successful in estimation of the state

when compared to the real system state.

Field voltage prediction

In chapter 2, the idea of the energy function design has been investigated. The

prediction of the field voltage was based on the estimation of the state from the

Kalman filter. The system was simulated for a period of one sample time with the

new flux from maximising the convergence rate of the kinetic energy function which

can be assured of being positive definite. The result of this unit was the desire flux of

the system for the duration of the prediction horizon which can be used as a

reference for the MPC. In this case the low sample rate was used to avoid the

computation cost in the optimization unit in MPC. The low sample rate in this unit

limited the flux changes and by increasing the control gain system started to oscillate

at the Nyquist rate. Then this oscillation could confuse the optimization.

Model Predictive control

While MPC is used locally to achieve the desired flux, the results produced are

encouraging since it is an effective controller which handled the stability in an

efficient way. The limitation in the prediction unit did not let to drive the field voltage

into the nonlinear region enough to show the ability of the MPC. Dealing with a non-

linear complex model using the proposed algorithm is an area of continuing research.

8.2 Contribution of this thesis

The nonlinearity of the power system was a motivation for using MPC in a nonlinear

controller. The MPC usually is applied to the application in centralized fashion but

due to the complexity of the system, lack of knowledge of the system model and to

minimize the computation cost in optimization, decentralised MPC is preferable.

The tools which are demonstrated in this thesis which are used to prepare enough

information for the MPC to apply in decentralized fashion are:

Page 98: Mana Tavahodi Thesis

95

• Kalman filter

• Energy function design

The key idea of the work is to reduce the computational effort for decentralized MPC.

If we had direct control of machine flux then energy function design would give a

good non-linear controller. Because of the time delay and nonlinearity of the field we

could not directly design the field voltage and must use numerical techniques to

achieve the required flux. This thesis showed there was some promise in the

decentralised idea. The results produced in decentralized approach are encouraging

as an effective non-linear controller which handles stability in a computationally

efficient way.

8.3 Future Research

The proposed method of control the exciter was confirmed by the simulation result for

the case of low feedback gains. The first objective of the future work could be using

different sampling rate for the prediction unit from the one that is going to be used for

the MPC. The limitation of using the low sample rate for the whole system as it was

mentioned before was to reduce the computational cost in optimizations. This

limitation does not exist for the prediction unit. Therefore it is possible to use higher

sampling rate for this unit in to the future.

The second objective is since we are using the δ& product in our control to avoid the

higher frequency oscillation combination of lower sampling rate and using the low

pass filter to find the prediction of the flux. The filter can smooth the prediction results

therefore the MPC has a clear reference to follow.

Page 99: Mana Tavahodi Thesis

96

Bibliography

[1]. A. Atiya and A. Parlos, “ Nonlinear system identification using spatiotemporal neural

networks”, IEEE International joint conference, Vol. 2, pp. 504-509, June 1992.

[2]. A.A. Fouad and R. Sreedhara, “ Transient voltage DIP analysis using the transient

energy function method”, IEEE Power Symposium, pp. 264-273, October 1990.

[3]. A. Mehta, W. Wojsznis, D. Thiele and T. Blevins, “ Constraints handling in

multivariable system by managing MP C squared controller”, The Instrumentation,

System and Automation Society, 2003.

[4]. A.N. Michel and V. Vittal, ” Power System transient stability using Individual machine

energy functions”, IEEE Transactions, Vol. 30, pp. 266-276, May, 1983.

[5]. B. Miao, R. Zane and D. Maksimovic, “ System identification of power converters

with digital control through Cross-Correlation methods” , IEEE Transactions, Vol. 20,

pp. 1093-1099, September, 2005.

[6]. B. Terzic and M. Jadric, “ Design and implementation of the extended Kalman filter

for the Speed and rotor position estimation of Brushless DC motor”, IEEE

Transactions, Vol. 48, pp. 1065-1073, December, 2001.

[7]. C. Jing and J.D. McCalley, “Analysis of sustained interarea oscillations in power

systems using kinetic energy approach”, IEEE Conference, Vol. 4, pp. 4067-4073,

December, 1994.

[8]. C.L. Gupta and A.H. El-Abiad, “Determination of the closest unstable equilibrium

state for Liapunov method in transient stability studies”, IEEE Transactions, Vol.95,

September, 1976.

[9]. D. Dougherty and D. Cooper, “A practical multiple model adaptive strategy for

multivariable model predictive control”, Science Direct, Control Engineering practice,

pp. 649-664, 2003.

[10]. E. Camponogara, D. Jia, B.H. Krogh and S. Talukdar, “Distributed model predictive

control”, IEEE Control System Magazine, Vol. 22, pp. 44-52, February, 2002.

[11]. E. de Klerk and I. Craig, “Closed-loop system identification of a MIMO plant

controlled by a MPC controller”, IEEE AFRICON, Vol. 1, pp. 85-90, October, 2002.

Page 100: Mana Tavahodi Thesis

97

[12]. E.W Kimbark, “Power System Stability”, Vol. 1, IEEE Press, New York, 1995.

[13]. E.W Kimbark, “Power System Stability”, Vol. 2, IEEE Press, New York, 1995.

[14]. E.W Kimbark, “Power System Stability”, Vol. 3, IEEE Press, New York, 1995.

[15]. E.W. Palmer, “ Multi-mode damping of power system oscillations”, PHD thesis, the

university of Newcastle, NSW, Australia, June,1998

[16]. F. Borrelli, T. Keviczky and G.E. Stewart, “Decentralized constrained optimal

control approach to distributed paper machine control”, IEEE conference, pp. 3037-

3042, December, 2005.

[17]. F. Gustafsson, “Determining the initial States in forward-backward Filtering”, IEEE

Transaction, Vol. 44, pp. 988-992, April, 1996.

[18]. F.S. Prabhakara and A.H. El-Abiad, “A simplified determination of transient stability

regions for Lyapunov methods”, IEEE Transaction, Vol. 94 ,pp. 672-689, March,

1975.

[19]. G. Welch and G. Bishop, “An introduction to the Kalman filter”, Department of

Computer Science, University of North Carolina, Chapel Hill, April, 2004.

[20]. I.A. Hiskens and B. Gong, “Voltage Stability Enhancement via model predictive

control of load”, Power System Dynamics and Control, Cortina d’Ampezzo, Italy,

2004.

[21]. I. Kamwa, “Using MIMO system identification for model analysis and global

stabilization of large power system”, IEEE Transaction, 2000.

[22]. J.B. Rawlings, “Tutorial overview of model predictive control” IEEE Control System

Magazine, Vol. 20, pp. 38-52, June, 2000.

[23]. J.G. Juang and B.S Lin, “Nonlinear system identification by evolutionary

computation and recursive estimation method”, IEEE American Control Conference,

Vol. 7, pp. 5073-5078, June, 2005.

[24]. J. Hao, L. shi and C. Chen, “Nonlinear disturbance attenuation excitation control of

structure preserving power systems based on Hamiltonian theory”, IEEE Power

engineering Society General meeting, Vol. 2, pp. 1665-1670, June, 2005.

[25]. J.J Ford and G. Ledwich, “Nonlinear control of Single-machine –infinite-bus

transient stability”, IEEE Power engineering Society General meeting, June, 2006.

Page 101: Mana Tavahodi Thesis

98

[26]. J. Choi, H. Cho, H.F. VanLandingham, H. Mok and J. Song, “System identification

of power converters based on a Black-Box approach”, IEEE Transactions, Vol. 45,

pp. 1148-1158, November, 1998.

[27]. J.M. De Freitas, “ Digital Filter Design solutions”, Artech house, INC, Boston, 2005.

[28]. J. Machowski, J.W. Bialek and J.R. Bumby, “Power System Dynamics and

Stability”,John Wiley & sons Ltd. England, 1997.

[29]. J.Y. Wen, Q.H. Wu, D.R. Turner, S.J Cheng and J. Fitch, “Optimal coordinated

voltage control for power system voltage stability”, IEEE Transactions, Vol. 19, pp.

1115-1122, May, 2004.

[30]. K. Reif and R. Unbehauen, “the extended Kalman filter as an exponential observer

for nonlinear system”, IEEE Transactions, Vol. 47, pp. 2324-2328, August, 1999.

[31]. K.W. Mang, C.Y. Chung, C.T. Tse and K.M. Tsang, “ Multimachine eigenvalue

sensitivities of power system parameters”, IEEE Power Engineering Society Winter

Meeting, Vol. 2, January, 2000.

[32]. L. Faybusovich, “A Hamiltonian formalism for optimization problems”, Journal of

Mathematical System, Estimation, and Control, Vol. 5, pp. 1-13, 1995.

[33]. L.M. Hajagos and M.J. Basler, “Changes to IEEE 421.5 Recommended practice for

Excitation System models for power System Stability Studies”, IEEE Power

Engineering Society General Meeting, pp.334-336, June 2005.

[34]. M. Amin, “ Modelling and Control of Complex Interactive Networks”, IEEE Control

System Magazine, Vol. 22, pp.22-27, February, 2002.

[35]. M. Shahidehpour and Y. Wang, “ Communication and Control in Electric Power

Systems”, IEEE Press,New Jersey, 2003.

[36]. P. Rastgoufard and R.A. Schluster, “Determination of power system transient

stability via Global kinetic energy accounting”, IEEE System theory, pp. 244-248,

March, 1988.

[37]. R. Mehra and D.Bayard, “Adaptive Kalman filtering, failure detection and

identification for spacecraft attitude estimation”, IEEE Control Applications, pp. 176-

181, September, 1995.

Page 102: Mana Tavahodi Thesis

99

[38]. S. Drageset, L. Imsland and B.A. Foss, “Efficient model predictive control with

prediction dynamics”, IEEE Control Applications, pp. 176-181, September, 1995.

[39]. S.Gillijins, O. Barrero Mendoza, J. Chandrasekar, B.L.R. De Moor, D.S. Bernstein

and A. Ridley, “What is the ensemble Klaman filter and how well does it work?”,

IEEE American Control conference, Minnesota, June 2006.

[40]. S.K. Tso and S.P. Cheung, “Consideration of excitation control for transient stability

assessment”, IEEE Control Applications, Vol. 1, pp. 485-490, August, 1994.

[41]. T. Senjyu, N. Urasaki, H. Fujita and T. Funabashi, “Power System Stabilization

based on robust centralized and decentralized controllers”, IEEE Power Engineering

Conference, Vol. 2. pp. 905-910, December, 2005.

[42]. V. Vitta, S. Rajagopal, A.A. Fouad, M.A. El-Kady, E. Vaahedi and V.F. Carvalho,

“Transient stability analysis of stressed power systems using the energy function

method”, IEEE Transactions, Vol. 3, pp. 239-244, February, 1988.

[43]. X.C. Zhang, G.H. Cheng and Z. Xu, “User defined excitation system models for

power system stability analysis in PSASP”, IEEE Transition and Distribution

Conference, pp. 1-5, August, 2005.

[44]. Z. Liang, H. Zhang, H. Wang and H. Nie, “Holographic robust predictive control of

synchronous machine excitation for power systems”, IEEE Power Engineering

Society Winter Meeting, Vol. 1, pp. 181-185, January, 2000.

Page 103: Mana Tavahodi Thesis

100

Appendix MATLAB codes

(on CD) Content of the CD

• MATLAB codes

• Electronic copy of thesis

• Published Paper