Top Banner

of 33

Full Report PBL

Apr 07, 2018

Download

Documents

khai22670
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
  • 8/3/2019 Full Report PBL

    1/33

    1.0 ABSTRACT

    Voltage stability problem has been one of the major concerns for electric utilities as a result of

    system heavy loading and needs to be solved. This paper presents the development of Artificial

    Intelligent technique in prediction of voltage stability in power system. The purpose of this paper

    is to develop Artificial Neural Network (ANN) program code in MATLAB software to perform

    ANN prediction process for voltage stability condition. In ANN, it considers load bus in order to

    analyze the voltage stability. The different values are tested in different bus at one time to

    analyze and collect historical data. The data will be trained and tested. Fast performance,

    accurate evaluation and good prediction for voltage stability have been obtained. A 14-system

    bus is used as input variables, which consists of real power value (PL) and reactive power (QL).

    This system analyzes the concerned variables and shows the stabilized value for load power (L)

    as the output.

    Uncontrollable decay of system voltage at one or more load buses or even over a significant

    portion of the network as a response to load variations, generation or structure disturbances etc

    has been observed in Power systems worldwide. This has been termed as voltage Instability and

    the process of voltage decrease has been termed as a voltage collapse process. Voltage collapse,

    a form of voltage instability, commonly occurs as a result of power deficiency. The reasons that

    cause voltage collapse is:

    1. Weakness of the transmission network

    2. The power transfer level

    3. Generator reactive power or voltage control limits

    4. The load characteristics (PL,QL)

    5. Characteristics of reactive compensation device

    6. The action of voltage control devices like transformer under load tap changing

    There are two kinds of disturbances that can make a power system unstable:-

    1

  • 8/3/2019 Full Report PBL

    2/33

    a) The variation of system condition, like a change at load bus

    b) Severe change of system conditions such as faults or losses of an important generator

    as bus.

    With the rest of the system conditions remaining in charged, if the load at a particular bus is

    varied, the voltage at the bus will also vary. Voltage at other nodes will also vary as a response to

    this load change. In other words voltage at a load bus is elastic with respect to the active power

    and reactive power delivered at that node. P, Q, V are active power, reactive power and voltage

    of the bus. Under stable conditions these factors are generally negative.

    2

  • 8/3/2019 Full Report PBL

    3/33

    3

  • 8/3/2019 Full Report PBL

    4/33

    LR Related info regarding the load flow, voltage stability and ANN is collected present in

    Chapter 2.

    NRLF The result analyses are collected and will be used as the training data to the ANN

    analysis.

    ANN the application of ANN in prediction the voltage stability where 2 algorithms are

    chosen, namely, Back-Propagation and General Regression Neural Network.Using for

    comparison to determine the acceptable error limits of the ANN applications.

    4

  • 8/3/2019 Full Report PBL

    5/33

    2.0 INTRODUCTION

    Power flow studies, commonly known as load flow, form an important part of power system

    analysis. They are necessary for planning, economic scheduling and control of existing system as

    well as planning expansion. The problem consists of determining the magnitudes and phase

    angle of voltages at each bus and active and reactive power flow in each line.

    In solving a power flow problem, the system is assumed to be operating under balanced

    conditions and a single-phase model is used. Four quantities are associated with each bus. These

    are voltage magnitude IVI, phase angle , real powerP, and reactive powerQ. the system buses

    are generally classified into three types:

    a) Slack Bus

    One bus, known as slack or swing bus, is taken as reference where the magnitude and

    phase angle of the voltage are specified. This bus makes up the difference between the

    scheduled loads and generated power that are caused by the losses in the network.

    b) Load buses

    At these buses the active and reactive powers are specified. The magnitude and the phase

    angle of the bus voltages are unknown. These buses are called PQ buses.

    c) Regulated buses

    These buses are the generator buses. They are also known as voltage-controlled buses. At

    these buses, the real power and voltage magnitude are specified. The phase angles of the

    voltages and the reactive power are also specified. These buses called PV buses.

    5

  • 8/3/2019 Full Report PBL

    6/33

    Power Flow Equation

    The real and reactive power at bus i is

    Pi +jQi = ViIi* or Ii = Pi jQi / Vi*

    Substituting for Ii in yield

    Pi jQi / Vi* = Viyij yijV j j i

    Load Flow Method

    a) Gauss Iterative Method

    b) Gauss-Seidel Method

    c) Newton-Raphson Method

    - Because of quadratic convergence

    - More efficient and practical

    - number of iteration

    d) Fast-Decoupled Method

    An artificial neural network is a system based on the operation of biological neural networks, inother words, is an emulation of biological neural system. Although computing these days is truly

    advanced, there are certain tasks that a program made for a common microprocessor is unable to

    perform; even so a software implementation of a neural network can be made with their

    advantages and disadvantages.

    6

  • 8/3/2019 Full Report PBL

    7/33

    Advantages:

    A neural network can perform tasks that a linear program can not performed. When an element of the neural network fails, it can continue without any problem by

    their parallel nature.

    A neural network learns and does not need to be reprogrammed.

    It can be implemented in any application.

    It can be implemented without any problem.

    Disadvantages:

    The neural network needs training to operate.

    The architecture of a neural network is different from the architecture of microprocessors

    therefore needs to be emulated.

    Requires high processing time for large neural networks.

    A artificial neural network is developed with a systematic step-by-step procedure which

    optimizes a criterion commonly known as the learning rule. The input/output training data is

    fundamental for these networks as it conveys the information which is necessary to discover the

    optimal operating point. In addition, a nonlinear nature makes neural network processing

    elements a very flexible system.

    ANN can categorize the learning situations in two distinct sorts. These are:

    Supervised learning or Associative learning in which the network is trained by

    providing it with input and matching output patterns. These input-output pairs can be

    provided by an external teacher, or by the system which contains the neural network

    (self-supervised).

    7

  • 8/3/2019 Full Report PBL

    8/33

    Unsupervised learning or Self-organization in which an (output) unit is trained to

    respond to clusters of pattern within the input. In this paradigm the system is supposed to

    discover statistically salient features of the input population. Unlike the supervised

    learning paradigm, there is no a priori set of categories into which the patterns are to be

    classified; rather the system must develop its own representation of the input stimuli.

    8

  • 8/3/2019 Full Report PBL

    9/33

    3.0 METHODOLOGY

    Development of ANN Model

    Development of ANN training codes

    9

  • 8/3/2019 Full Report PBL

    10/33

    Development of ANN testing codes

    10

  • 8/3/2019 Full Report PBL

    11/33

    3.1 PROBLEM SOLVING TIME- LINE

    11

  • 8/3/2019 Full Report PBL

    12/33

    4.0 RESULTS AND DISCUSSIONS

    12

  • 8/3/2019 Full Report PBL

    13/33

    Test System

    The test system for this study is 14- Bus Reliability Test System (RTS). This system

    consists of two generators buses, four load buses and transmission lines.

    13

  • 8/3/2019 Full Report PBL

    14/33

    4.1 RESULT

    function [basemva,accuracy,maxiter,busdata,linedata]=pbl14bus

    basemva = 100; accuracy = 0.0001; maxiter =100;

    % Bus code: 0 = load bus; 1 = slack bus; 2 = generator bus

    % load generator Injected

    % bus code voltage angle MW Mvar MW Mvar Qmin Qmax Mvar

    busdata=[ 1 1 1.006 0.000 0.000 0.0 0 0.0 0.0 0.0 0

    2 2 1.045 0.000 21.7 12.7 0 40.0 -40 50 0

    3 2 1.010 0.000 94.2 19.0 0 0.0 -30 40 0

    4 2 1.070 0.000 11.2 7.5 0 0.0 -40 50 0

    5 2 1.090 0.000 0.00 0.0 0 0.0 -20 40 0

    6 0 1.000 0.000 47.8 -3.9 0 0.0 0.0 0.0 0

    7 0 1.000 0.000 0.0 0.0 0 0.0 0.0 0.0 0

    8 0 1.000 0.000 76.0 1.6 0 0.0 0.0 0.0 0

    9 0 1.000 0.000 29.5 16.6 0 0.0 0.0 0.0 0

    10 0 1.000 0.000 9.0 5.8 0 0.0 0.0 0.0 0

    11 0 1.000 0.000 3.5 1.8 0 0.0 0.0 0.0 0

    12 0 1.000 0.000 6.1 0.6 0 0.0 0.0 0.0 013 0 1.022 0.000 13.5 5.8 0 0.0 0.0 0.0 0

    14 0 1.015 0.000 14.9 5.0 0 0.0 0.0 0.0 0];

    % In the 14 bus case, there is no Mvar injected since there is no capacitive compensation

    %

    14

  • 8/3/2019 Full Report PBL

    15/33

    % line data

    % from to R X 1/2B tr-tap

    linedata=[ 1 2 0.0194 0.0592 0.0264 1

    1 8 0.0540 0.2230 0.0246 1

    2 3 0.0470 0.1980 0.0219 1

    2 6 0.0581 0.1763 0.0187 1

    2 8 0.0570 0.1739 0.0170 1

    3 6 0.0670 0.1710 0.0173 1

    6 8 0.0134 0.0421 0.0064 1

    6 7 0.0000 0.2091 0.0000 1

    6 9 0.0000 0.5562 0.0000 1

    8 4 0.0000 0.2520 0.0000 1

    4 11 0.0950 0.1989 0.0000 1

    4 12 0.1229 0.2558 0.0000 1

    4 13 0.0662 0.1303 0.0000 1

    7 5 0.0000 0.1762 0.0000 1

    7 9 0.0000 0.1100 0.0000 1

    9 10 0.0318 0.0845 0.0000 19 14 0.1271 0.2704 0.0000 1

    10 11 0.0821 0.1921 0.0000 1

    12 13 0.2209 0.1999 0.0000 1

    13 14 0.1709 0.3480 0.0000 1];

    end

    Program for 14 bus data

    count=0

    kira=0

    15

  • 8/3/2019 Full Report PBL

    16/33

    while count

  • 8/3/2019 Full Report PBL

    17/33

    op_ok(kira,:)=[busdata(6,6) busdata(8,6) busdata(9,6) busdata(10,6)

    busdata(11,6) busdata(12,6) busdata(13,6) busdata(14,6) busdata(6,5) busdata(8,5) busdata(9,5)

    busdata(10,5) busdata(11,5) busdata(12,5) busdata(13,5) busdata(14,5) fit]

    else

    count=count+1

    op_xok(count,:)=[busdata(6,6) busdata(8,6) busdata(9,6) busdata(10,6)

    busdata(11,6) busdata(12,6) busdata(13,6) busdata(14,6) busdata(6,5) busdata(8,5) busdata(9,5)

    busdata(10,5) busdata(11,5) busdata(12,5) busdata(13,5) busdata(14,5) fit]

    end

    ifNilai_Q==500 && Nilai_P==500 && bus_no==8

    return

    end

    end

    end

    end

    end

    endprogram for generate training and testing data

    Data are collected from Newton Raphson load flow analysis

    Only consider load bus. The value of Pd, Qd and Vm from load flow was taking.

    In targeted output, write 1 for converge and 0 for diverge.

    Data will be get from array and called historical data

    The historical data will divided into two, which is:-

    i. Training data

    ii. Testing data

    17

  • 8/3/2019 Full Report PBL

    18/33

    Control variable = 16 which is reactive power Q for each load bus (slack bus and

    generator bus is not required) and indicator

    Targeted output = 1-stable (converge)

    0-unstable (diverge)

    Patterns = 20 pattern data for training and another 24 pattern data for testing

    % ANN3_norm.m

    function [pn,minp,maxp,tn,mint,maxt] = pbltr_norm(p,t)

    %MATMAX Preprocesses data so that minimum is -1 and maximum is 1.

    %

    % Syntax

    %

    % [pn,minp,maxp,tn,mint,maxt] = premnmx(p,t)

    % [pn,minp,maxp] = premnmx(p)

    %

    % Description

    %

    % MATMAX preprocesses the network training

    % set by normalizing the inputs and targets so that

    % they fall in the interval [-1,1].

    %

    % MATMAX(P,T) takes these inputs,

    % P - RxQ matrix of input (column) vectors.% T - SxQ matrix of target vectors.

    % and returns,

    % PN - RxQ matrix of normalized input vectors

    % MINP- Rx1 vector containing minimums for each P

    % MAXP- Rx1 vector containing maximums for each P

    18

  • 8/3/2019 Full Report PBL

    19/33

    % TN - SxQ matrix of normalized target vectors

    % MINT- Sx1 vector containing minimums for each T

    % MAXT- Sx1 vector containing maximums for each T

    %

    % Examples

    %

    % Here is how to normalize a given data set so

    % that the inputs and targets will fall in the

    % range [-1,1].

    %

    % p = [-10 -7.5 -5 -2.5 0 2.5 5 7.5 10];

    % t = [0 7.07 -10 -7.07 0 7.07 10 7.07 0];

    % [pn,minp,maxp,tn,mint,maxt] = premnmx(p,t);

    %

    % If you just want to normalize the input:

    %

    % [pn,minp,maxp] = premnmx(p);

    %

    % Algorithm%

    % pn = 2*(p-minp)/(maxp-minp) - 1;

    %

    % See also PRESTD, PREPCA, POSTMNMX, TRAMNMX.

    % Copyright (c) 1992-1998 by The MathWorks, Inc.

    % $Revision: 1.3 $

    ifnargin > 2

    error('Wrong number of arguments.');

    end

    19

  • 8/3/2019 Full Report PBL

    20/33

    load minp1

    load maxp1

    minp =minp1;%min(p')';

    maxp =maxp1;%max(p')';

    [R,Q]=size(p);

    oneQ = ones(1,Q);

    equal = minp==maxp;

    nequal = ~equal;

    ifsum(equal) ~= 0

    warning('Some maximums and minimums are equal. Those inputs won''t be transformed.');

    minp0 = minp.*nequal - 0.1*equal;

    maxp0 = maxp.*nequal + 0.9*equal;

    else

    minp0 = minp;

    maxp0 = maxp;

    end

    pn = 0.8*(p-minp0*oneQ)./((maxp0-minp0)*oneQ) +0.1;

    ifnargin==2

    mint = min(t')';

    maxt = max(t')';

    equal = mint==maxt;

    nequal = ~equal;

    ifsum(equal) ~= 0

    warning('Some maximums and minimums are equal. Those targets won''t be transformed.');

    mint0 = mint.*nequal - 0.1*equal;

    maxt0 = maxt.*nequal + 0.9*equal;

    20

  • 8/3/2019 Full Report PBL

    21/33

    else

    mint0 = mint;

    maxt0 = maxt;

    end

    tn = 0.8*(t-mint0*oneQ)./((maxt0-mint0)*oneQ) +0.1;

    end

    end

    program for normalize data training

    After setting the parameter of the training, the next step is to train the ANN. We had loaded the

    data from the previous which is load ztrain.mat.

    clc

    clear

    % a=0

    %

    % if a

  • 8/3/2019 Full Report PBL

    22/33

    [pn,minp,maxp,tn,mint,maxt] = pbltr_norm(p,t) % this is to normalise the input and target

    training data

    % The next step is to design the network

    net = newff(minmax(pn),[8,5,1],{'logsig','logsig','purelin'},'trainlm');% minmax(pn) =

    minimum & maximum value

    % for normalised input p. i.e: pn.

    % to initialise

    net = init(net);

    net.trainParam.show = 1;

    net.trainParam.lr = 0.95;% Learning rate used in some gradient schemes

    net.trainParam.mc = 0.3415; % Momentum is used for slight tolerence on the learning rate

    net.trainParam.epochs =1000; % Max number of iterations

    net.trainParam.goal = 1e-8; % Error tolerance; stopping criterion

    %Train network

    net = train(net, pn, tn); % TRain the network based on the normalised p and t

    an = sim(net, pn)

    %[p] = matmin_24_baru(an,mint,maxt) % denormalise the training output

    [p] = postmnmx(an,mint,maxt) % denormalise the training output

    % if net.trainParam.goal>1e-8

    % return

    22

  • 8/3/2019 Full Report PBL

    23/33

    % a=a+1

    % end

    %

    % end

    net_baru=net

    save net_baru

    fprintf('Press enter to continue with testing')

    pause

    program for training data

    This is the best results for the convergence performance (mse vs epochs) for training after we

    had trained the program more than one time.

    23

  • 8/3/2019 Full Report PBL

    24/33

    Result for training

    After that, we had written and run testing program as following:

    % ANN3_norm.m

    function [pn,minp,maxp,tn,mint,maxt] = pblts_norm(p,t)

    %MATMAX Preprocesses data so that minimum is -1 and maximum is 1.

    %

    % Syntax

    %

    % [pn,minp,maxp,tn,mint,maxt] = premnmx(p,t)

    24

  • 8/3/2019 Full Report PBL

    25/33

    % [pn,minp,maxp] = premnmx(p)

    %

    % Description

    %

    % MATMAX preprocesses the network training

    % set by normalizing the inputs and targets so that

    % they fall in the interval [-1,1].

    %

    % MATMAX(P,T) takes these inputs,

    % P - RxQ matrix of input (column) vectors.

    % T - SxQ matrix of target vectors.

    % and returns,

    % PN - RxQ matrix of normalized input vectors

    % MINP- Rx1 vector containing minimums for each P

    % MAXP- Rx1 vector containing maximums for each P

    % TN - SxQ matrix of normalized target vectors

    % MINT- Sx1 vector containing minimums for each T

    % MAXT- Sx1 vector containing maximums for each T

    %% Examples

    %

    % Here is how to normalize a given data set so

    % that the inputs and targets will fall in the

    % range [-1,1].

    %

    % p = [-10 -7.5 -5 -2.5 0 2.5 5 7.5 10];

    % t = [0 7.07 -10 -7.07 0 7.07 10 7.07 0];

    % [pn,minp,maxp,tn,mint,maxt] = premnmx(p,t);

    %

    % If you just want to normalize the input:

    %

    25

  • 8/3/2019 Full Report PBL

    26/33

    % [pn,minp,maxp] = premnmx(p);

    %

    % Algorithm

    %

    % pn = 2*(p-minp)/(maxp-minp) - 1;

    %

    % See also PRESTD, PREPCA, POSTMNMX, TRAMNMX.

    % Copyright (c) 1992-1998 by The MathWorks, Inc.

    % $Revision: 1.3 $

    ifnargin > 2

    error('Wrong number of arguments.');

    end

    load minp2

    load maxp2

    minp =minp2;%min(p')';maxp =maxp2;%max(p')';

    [R,Q]=size(p);

    oneQ = ones(1,Q);

    equal = minp==maxp;

    nequal = ~equal;

    ifsum(equal) ~= 0

    warning('Some maximums and minimums are equal. Those inputs won''t be transformed.');

    minp0 = minp.*nequal - 0.1*equal;

    maxp0 = maxp.*nequal + 0.9*equal;

    26

  • 8/3/2019 Full Report PBL

    27/33

    else

    minp0 = minp;

    maxp0 = maxp;

    end

    pn = 0.8*(p-minp0*oneQ)./((maxp0-minp0)*oneQ) +0.1;

    ifnargin==2

    mint = min(t')';

    maxt = max(t')';

    equal = mint==maxt;

    nequal = ~equal;

    ifsum(equal) ~= 0

    warning('Some maximums and minimums are equal. Those targets won''t be transformed.');

    mint0 = mint.*nequal - 0.1*equal;

    maxt0 = maxt.*nequal + 0.9*equal;

    else

    mint0 = mint;

    maxt0 = maxt; end

    tn = 0.8*(t-mint0*oneQ)./((maxt0-mint0)*oneQ) +0.1;

    end

    end

    program for normalize data testing

    clc

    clear

    load ztest

    load zt2

    27

  • 8/3/2019 Full Report PBL

    28/33

    p=ztest

    t=zt2

    y= minmax(p)

    minp2=[min(p')']

    maxp2=[max(p')']

    save minp2

    save maxp2

    [pn,minp,maxp,tn,mint,maxt] = pblts_norm(p,t)

    load net_baru

    %Setting the minimum and maximum training target

    mint = [0];%min(t')'

    maxt = [1]; %max(t')'

    an = sim(net, pn) % output

    [p] = postmnmx(an,mint,maxt)

    [m,b,r] = postreg(p,t);

    an=sim(net,pn); %a) Provide the outputs (an) based on the trained network

    [m,b,r]=postreg(an,tn); %a) Regression analysis which computes the correlation coefficient

    % between the outputs and the targets.

    results=[an' tn'] %a) To compare between the network outputs and the targets

    Program for testing

    28

  • 8/3/2019 Full Report PBL

    29/33

    This is the results of the testing:

    results=[an' tn']

    Bil an tn Bil an tn

    1 0.9 0.9 1 0.1 0.1

    2 0.9 0.9 2 0.1 0.13 0.9 0.9 3 0.1 0.1

    4 0.9 0.9 4 0.1 0.1

    0.906 0.9 0.1 0.1

    0.9 0.9 0.1 0.1

    0.9 0.9 0.1 0.1

    0.9 0.9 0.1 0.1

    0.9 0.9 0.1 0.1

    29

  • 8/3/2019 Full Report PBL

    30/33

    0.9 0.9 0.1 0.1

    0.8998

    0.9 0.1 0.1

    0.9001

    0.9 0.1 0.1

    0.9 0.9 0.1 0.10.9 0.9 0.1 0.1

    0.9 0.9 0.1 0.1

    0.9 0.9 0.1 0.1

    0.9 0.9 0.1 0.1

    0.9 0.9 0.1 0.1

    0.9 0.9 0.1 0.1

    0.9 0.9 0.1 0.1

    0.9 0.9 0.1 0.1

    0.9 0.9 0.1 0.1

    0.9 0.9 0.1 0.1

    0.9 0.9 0.1 0.10.9 0.9 0.1 0.1

    0.9 0.9 0.1 0.1

    0.9 0.9 0.1 0.1

    0.9 0.9 0.1 0.1

    0.9 0.9 0.1 0.1

    0.9 0.9 0.1002

    0.1

    0.9 0.9 0.0997

    0.1

    188 0.9003

    0.9 288 0.1002

    0.1

    30

  • 8/3/2019 Full Report PBL

    31/33

    Result for testing

    31

  • 8/3/2019 Full Report PBL

    32/33

    5.0 CONCLUSION

    From this ANNprogram code in MATLAB software, we learned on how to perform

    ANN prediction process for voltage stability condition. The training process produced result for

    the convergence performance (mse vs epochs) and the testing process produced results of

    results=[an' tn'], where if the targeted output is 1 = stable (converge) and 0 = unstable (diverge).

    Post regression analysis showed that we were manage to get the best line (R=1), and the

    comparison of each bus outputs showed that the output obtained were accurate. The performance

    of this testing and training process also depends on the size of the power system network under

    consideration.

    32

  • 8/3/2019 Full Report PBL

    33/33

    6.0 REFRRENCES

    [I] P. A. Lof, et aI., "Voltage Stability Indices For Stressed Power Systems", IEEE Irans. On

    Power System, Vol. 8. no_ I, Feb 1993, pp.326-335.

    [2] B. Gao, ct aI., "Voltage Stabilily Evalualion Using Modal Analysis", IEEE trans. On Power

    System. Vol. 7, nO .. 4, Nov 1992, PI'. 1529-1542.

    [3] N. Flatabo, et aI., "Voltage Stability Condition in a Power Transmission Calculated by

    Sensitivity Method", IEEE trans. On Power Systems, Vol.5, no. 4,Nov. 1990, pp. 12861293.

    [4] M. M. Begovic, A. O. Phadke, "Control of Voltage Stability using sensitivity Analysis",

    IEEE trans. On Power Systems, Vol. 7, no. I, Feb 1992, pp. 1 14123.

    [5] T. K Abdul Rahman and G. B Jasmon, "A New Technique for Voltage Stability Analysis In

    A Power System and Improved Loadnow Algorithm For Distribution Network",

    Intrcll1ation.1Conference on EMPD, Vol.2, pg 7 I 4-719, Nov. I 995.

    [6) A.A. ElKeib, X.Ma, "Application of Artificial Neurat Networks in Voltage stability

    Assessment" IEEE tr3ns. on power system. 1