DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

Embed Size (px)

Citation preview

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    1/67

    ASCET

    Chapter 1. Introduction

    In 1988 almost all electric power utilities throughout the world operated with an

    organizational model in which one controlling authority-the utility-operated the

    generation, transmission, and distribution systems located in a fixed geographic area.

    Economists for some time had questioned whether this monopoly organization was

    efficient. With the example of the economic benefits to society resulting from the

    deregulation of other industries such as telecommunications and airlines, and in a

    political climate friendly to the notion of deregulation, the United Kingdom was the first

    to restructure its nationally owned power system, creating privately owned companies to

    compete with each other to sell electric energy. Deregulation followed in Norway,

    Australia, and New Zealand, and then, in the 1992 National Energy Policy Act (NEPA),

    in the United States.

    The electricity industries in number of countries have recently been deregulated to

    introduce competition. In a centralized power industry, the planning is done to minimise

    the production cost. In a competitive electricity market, generation resources are,

    scheduled based on offers and bids of the suppliers and consumers. Many approacheshave been proposed in literature to solve the optimal power dispatch problem for

    electricity markets [1,3,4].

    One of the competitive electricity market models is the auction market model, in which

    participants place their bids to sell or buy electricity. In an electricity auction market, the

    two main participants are distribution companies and generation companies. These

    participants will submit their bids to an independent system operation (ISO) company. A

    supply bid is given as a cost per MW and a quantity in MW which a generation company

    is willing to generate in a particular period. Each generation company may place several

    bids. A demand bid is given as a cost per MW and a quantity in MW which a distribution

    company is willing to consume in a particular period. Several demand bids may be placed

    by each distribution company.

    1

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    2/67

    ASCET

    A strong motive for considering auctions for the pricing of electric power is given by the

    assumption that the electric power industry will move from regulated rate of return

    pricing to market-based pricing in the near future. This requires consideration of various

    pricing mechanisms. An additional reason is that the natural gas industry spent much time

    and effort in researching auction mechanisms for the pricing of natural gas when their

    industry underwent deregulation. The electric power industry is quite similar to the

    natural gas industry in that both industries produce, transport, and sell their respective

    commodities. The need for a pricing mechanism coupled with the example of the natural

    gas industry is sufficient reason for considering auctions in the electric power pricing

    arena.

    The optimal power dispatch models proposed by several researchers [1,3,4] have the

    objective to maximize the total benefit to the participants in the multinode auction

    market. This thesis demonstrates the application of a genetic algorithm to solve the

    optimal power dispatch problem for a multi-node auction market. The model used in this

    thesis, like most of the models available in literature, does not directly consider the

    reactive power market and the transmission cost. The advantage of the proposed genetic

    algorithm is the simplicity of handling non-linear constraints, without having to simplify

    the power flow constraints. In addition, the algorithm is easy to implement and additional

    features such as security constraints can be easily incorporated in the algorithm.

    A new model using genetic algorithm is developed to solve the optimal power dispatch

    problem for a multi-node auction market. The above methods are tested on 17-node 26-

    line system and compared to demonstrate their performance.

    2

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    3/67

    ASCET

    Chapter 2. Power System Deregulation

    2.1 Introduction

    Electrical power industry has been dominated by large utilities that have overall

    authorities overall activities in generation, transmission and distribution of power refer to

    as vertically integrated utilities. During the nineties many electrical utilities and power

    network companies world wide have been forced to changed their ways of doing business

    from vertically integrated mechanism to open market system. This kind of process is

    called as deregulation or restructuring.

    Deregulation word refers to un-bundling of electrical utility or restructuring of electrical

    utility and allowing private companies to participate. The aim of deregulation is to

    introduce an element of competition into electrical energy delivery and thereby allow

    market forces to price energy at low rates for the customer and higher efficiency for the

    suppliers.

    2.2 Vertically Integrated Electrical Utility (VIEU)

    VIEU is referred as Regulated Electrical Power Industry.

    Regulation means that the Government has set down laws and rules that put limits on

    and define how a particular industry or company can operate.

    2.2.1 Need for regulation

    1. Risk free way to finance the creation of electric industry

    2. Recognition and support from local government to utilities

    3. Assured return on investments

    4. Establishment of local monopoly

    3

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    4/67

    ASCET

    In Fig. 2-1 shows the basic structure of regulated power system, in which one controlling

    authority-the utility-operated the generation, transmission and distribution systems

    located in a fixed geographic area.

    Fig. 2-1: Basic structure of VIEU

    2.2.2 Features of VIEU

    1. Overall authority, overall activities in generation transmission distribution of

    power utility lie within its domain of operation.

    2. VIEU will be the only electricity provider in the region and it has obligation to

    provide electricity to every one in the region.

    3. Information flow is a bilateral one between generation and transmission system

    but money flow was unidirectional.

    2.2.3 Demerits of VIEU

    1. It was often difficult to regulate the cost incurred in generation transmission and

    losses occurred in distribution.

    4

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    5/67

    ASCET

    2. Losses occurred in distribution is accounted by spreading the cost over all three

    components. Hence utilities often charged their customers at an average tariff

    depending upon their aggregated cost during the particular period.

    3. The prices setting is done by an external regulator agency often involved

    considerations other than economics. (Political party interferences or government

    policies on new issues etc.)

    4. The main objective of VIEU is to minimize the total cost while satisfying all the

    associated problems and constraints, but this leads to complex operation issues

    because of the big size VIEU. Further VIEU needs centralized planning for long-

    term generation, transmission expansion, midterm planning activities such as

    maintenance, production scheduling, fuel scheduling for optimal cost.

    In spite of all the above demerits VIEU have performed satisfactorily over the long years

    with respect to operation, control and planning. But after 1990 there has been very big

    mismatch between the growth of the load and the generation expansion. This has led to

    ineffective operation of the system. Hence the concept of deregulation has been mooted.

    When the generation, transmission and distribution system control are separated in terms

    of management and ownership, the power system is said to be deregulated.

    2.3 Deregulated electrical power industry

    Deregulation in power industry is a restructuring of the rules and economic incentives

    that governments set up to control and drive the electric power industry.

    5

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    6/67

    Competitive

    Generation

    Market

    Multiple sellers

    Competitive

    Retail market

    Multiple Buyers

    Transco & Disco

    ASCET

    Fig. 2-2: Unbundling the system

    Fig. 2-3: Typical configuration of restructured or deregulated power system

    Competition Regulated monopoly Competition

    6

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    7/67

    ASCET

    Fig. 2-4: The competition

    ISO

    ISO was appointed for the whole system and its main responsibility is to keep the system

    in balance. i.e.,

    Imports + productions = Exports + Consumption + losses.

    Thus ISO must be an independent authority without any involvement in market

    competition. But it validates all the transactions before the actual operation takes place

    from the point of view of security of the systems, congestion management, real time

    operation etc.

    Responsibilities of Independent System Operator

    1. System security and reliability

    2. Power delivery

    3. Transmission pricing

    4. Service quality assurance

    5. Promotion of economic efficiency and equity

    6. Fair market

    Market trader/Market operator (Retailer)

    Market operator is an entity in the de-regulated environment and is responsible for the

    operation of market trading of electricity. He receives the bid offers from various market

    participants and determines the markets price based on certain criteria in accordance with

    the market structure.

    2.3.1 Need for Deregulation

    1. To provide cheaper electricity.

    2. To offer greater choice to the customer in purchasing the economic energy.

    3. To give more choice of generation.

    7

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    8/67

    ASCET

    4. To offer better services w.r.t power quality i.e. Constant voltage, constant freq.

    and uninterrupted power supply.

    2.3.2 Benefits of deregulated power system

    1. Cheaper electricity.

    2. Efficient capacity expansion planning at GENCO level, TRANSCO level and

    DISCO level.

    3. Pricing is cost effective rather than a set tariff.

    4. More choice of generation.

    5. Better service is possible.

    8

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    9/67

    ASCET

    Chapter 3. Genetic Algorithms

    3.1 Introduction

    Genetic Algorithms (GAs) were invented and developed by John Holland. He invented

    genetic algorithm with decision theory for discrete domains. Holland emphasized the

    importance of recombination in large populations.

    Genetic algorithms are search algorithms based on the mechanics of natural selection and

    natural genetics, inspired from the biological evolution, survival of the fittest among

    string structures with a structured yet, randomized information exchange with in the

    population to form a search algorithm with some of the innovative flair of human search.

    In every generation a new set of artificial creatures (strings) created using bits and piece

    of the old, an occasional new part is tried for good measure. Being randomized GAs

    exploit historical information to speculate on new search points with expecting improved

    performance. The current literature identifies three main types of search methods or

    optimization techniques. They are:

    i. Calculus based method

    ii. Enumerate method

    iii. Random search techniques

    Calculus based and enumerative methods are comfortable in their ability to deliver

    solutions in applications involving search spaces of limited problem domain. Both

    methods are local in scope, the optima they seek are the best in a neighborhood of the

    current search point. But in their application to real world of search, which is fraught withdiscontinuities of functions and their derivatives and vast multi-modal noisy search

    spaces, they break down on problems of even moderate size and complexity. Their

    inability and inefficiency to overcome the local optima and reach the global optimum

    make them insufficiently robust, precluding their application to complex problems as

    search method.

    9

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    10/67

    ASCET

    On the other hand, random search algorithms managed to overcome the inherent

    disabilities of the calculus and enumerative methods. Yet, random schemes that searches

    and save the best must also be discounted because of the efficiency requirement. Random

    searches, in the long run can be expected to do no better than enumerative schemes. In

    our haste to discount strictly random search methods, we must be careful to separate them

    from randomized techniques.

    The randomized search techniques incorporated the basic advantages of random search

    but used it only as a tool to guide a more highly exploitative search. In these methods, the

    search is carried out randomly and information gained from a search is used in guiding

    the next search. Genetic algorithm is an example of such technique, which drew

    inspiration from the robustness of nature.

    Genetic algorithms in their quest for robustness surpassed their traditional cousins and

    differ in some very fundamental ways. GAs are different in the following aspects:

    i. GAs work with a coding of the parameter set, not the parameters themselves.

    ii. GAs searches from a population of points, not from a single point as in

    conventional search algorithms.

    iii. GAs uses objective function information, not derivatives or other auxiliary

    knowledge.

    iv. GAs use probabilistic tradition rules but not deterministic rules.

    In this chapter, Genetic algorithm and its operators have been discussed in detail.

    3.2 Phases of Genetic Algorithm

    The first step in Genetic Algorithm is the random generation of large number of search

    points from the total search space. Each and every point in the search space corresponds

    to one set of values for the parameters of the problem. Each parameter is coded with a

    string of bits. The individual bit is called gene. The content of each gene is called

    10

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    11/67

    ASCET

    allele. The total string of such genes of all parameters written in a sequence is called

    chromosome. So, there exits a chromosome for each point in the search space. The set

    of search points selected and used for processing is called a population. i.e., population

    is a set of chromosomes. The number of chromosomes in a population is called

    population size and the total number of genes in a string is called string length. The

    population is evaluated through various operators of GA to generate a new population.

    This process is carried out until global optimum point is reached. Typically it consist of

    three phases,

    i. Generation

    ii. Evaluation

    iii. Genetic operation

    3.2.1. Generation

    In this phase number of chromosomes equal to population size is generated and each is of

    length equals to string length. The size of population is direct indication of effective

    representation of whole search space in one population. The population size affects both

    the ultimate performance and efficiency of GA. If it is too small it leads to local optimum

    solution. The selection of string length depends on the accuracy and resolution

    requirement of the optimization problem. The higher the string length, the better the

    accuracy and resolution. But this may lead to slow convergence. Also, the number of

    parameters in the problem will have a direct effect on the string length of the

    chromosome, for a particular resolution and accuracy requirements the string length is

    chosen appropriately. The chromosome should in some way contain the information

    about solution, which it represents. After the selection of string length and population

    size, the initial population is encoded. Most commonly used encoding schemes are :

    a) Binary encoding

    In binary encoding every chromosome is a string of bits 0 or 1. The chromosome looks

    like

    Chromosome 1: 110110010011

    11

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    12/67

    ASCET

    Chromosome 2: 110111100001

    Each chromosome has one binary string. Each bit in this string can represent some

    characteristic of the solution or the whole string can represent a number.

    b) Permutation encoding

    In permutation encoding every chromosome is a string of numbers, which represent

    number in a sequence. Permutation encoding is only useful for ordering problems. The

    chromosomes in this encoding looks like

    Chromosome 1: 1 5 3 2 6 4 7 9 8

    Chromosome 2 : 8 5 6 7 2 3 1 4 9

    c) Value encoding

    Direct value encoding can be used in problems, where some complicated value, such as

    real numbers, is used. Use of binary encoding for this type of problems would be very

    difficult. In the encoding, every chromosome is a string of some values. Values can be

    anything connected to problem, real numbers or characteristics to some complicated

    objects. The chromosomes in this encoding looks like:

    Chromosome 1: 1234 5.3243 0.4556 2.3293 2.4545

    Chromosome 2: ABDJEIFJDHDIERJFDLDFLFEGT

    Value encoding is very good for some special problems. On the other hand, for this

    encoding is often necessary to develop some new crossover and mutation specific for the

    problem.

    Random generation techniques are used in accomplishing this task. Any of the encoding

    techniques can be used but binary encoding is mostly used.

    Now, the initial population of chromosomes is decoded and all the parameters are

    calculated for each chromosome. This results in a set of solutions whose size is equal to

    population size.

    12

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    13/67

    ASCET

    3.2.2. Evaluation

    In the evaluation phase, suitability of each of the solutions from the initial set as the

    solution of the optimization problem is determined. For this function called fitness

    function is defined. This is used as a deterministic tool to evaluate the fitness of eachchromosome. The optimization problem may be minimization or maximization type. In

    the case of maximization type, the fitness function can be a function of variables that bear

    direct proportionality relationship with the objective function. For minimization type

    problems, fitness function can be function of variables that bear inverse proportionality

    relationship with the objective function or can be reciprocal of a function of variables

    with direct proportionality relation ship with the objective function. In either case, fitness

    function is so selected that the most fit solution is the nearest to the global optimum

    point. The programmer of GA is allowed to use any fitness function that adheres to the

    above requirements. This flexibility with the GA is one of its fortes.

    On the whole for a typical optimization problem, evaluation phase consists of calculation

    of individual parameters, testing of any equality or inequality constraints that need to be

    satisfied, evaluation of objective function, and finally evaluation of fitness from fitness

    function. This evaluation is discrete in nature vis--vis some genetic operators which

    operate on more than one chromosome at a time.

    3.2.3. Genetic operation

    In this phase, the objective is the generation of new population from the existing

    population with the examination of fitness values of chromosomes and application of

    genetic operators. These genetic operators are reproduction, crossover, and mutation.

    This phase is carried out if we are not satisfied with the solution obtained earlier. The GA

    utilizes the notion of survival of the fittest by transferring the highly fit chromosomes to

    the next generation of strings and combining different strings to explore new search

    points.

    13

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    14/67

    ASCET

    Reproduction

    Reproduction is simply an operator where by an old chromosome is copied into a Mating

    pool according to its fitness value. Highly fit chromosomes receive higher number of

    copies in the next generation. Copying chromosomes according to their fitness means that

    the chromosomes with a higher fitness value have higher probability of contributing one

    or more offspring in the next generation.

    Crossover

    It is recombination operation. Here the gene information (information in a bit) contained

    in the two selected parents is utilized in certain fashion to generate two children who bear

    some of the useful characteristics of parents and expected to be more fit than parents.

    There are various techniques that are used for performing this crossover. But first of all

    we need to pick up two parents from the existing population to perform crossover. This

    selection can be done using two methods.

    a) Random selection b) Roulette Wheel selection

    In the random selection technique, the parents are picked up randomly from the existing

    population. In roulette wheel selection technique, selection is usually implemented as a

    linear search through roulette wheel with slots weighed in proportion to string fitness

    values. This is achieved using the following steps.

    i. Total sum of the fitness (fitsum) of all the strings is calculated.

    ii. A random real number (rand-sum) between 0 and fitsum is generated.

    iii. Starting with the first member of existing population, for each member n the

    fitness sum of members 1 to n is compared with the randomly generated

    number.

    iv. If (fitness of member n) > rand-sum, n is selected as parent. Otherwise the

    process is continued by incrementing n.

    14

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    15/67

    ASCET

    All the above steps are useful in selecting a parent. Therefore, before performing each

    crossover, we have to execute the above steps twice. Obviously, through this Roulette

    wheel selection we are giving more reproductive chances to those population members

    that are the fit. Thus, we are ensuring that the picking of chromosomes as parents is

    according to their objective function values. It is important to note that the convergence

    rates and efficiency of GA with roulette wheel selection techniques far vis--vis random

    selection technique. In the roulette wheel selection technique, still faster rate of

    convergence can be achieved by sorting the members of the population in the descending

    order of their fitness before selecting parents.

    Now crossover is carried out using any of the following three methods.

    a) Simple or Single Point Crossover

    b) Multi-point Crossover

    c) Uniform Crossover

    a) Single Point Crossover

    In this method crossover is carried out at a single point. This is illustrated in the

    following example. Let Par1 and Par2 be the two parents selected for crossover. Assume

    the strings par1 and par2 as below.

    Par 1: 1 1 0 0 0 1 0 1 Par 2: 1 0 1 1 0 1 1 1

    Now, a crossover site is selected randomly as an integer between 1 and string length. For

    illustration the string length is taken as 8, but in the project work we used 10 as string

    length. Let this crossover site is 4. Then children Child 1 and Child 2 are generated as

    below.

    Child 1: 1 2 3 4 5 6 7 8 = 1 1 0 0 0 1 1 1

    |

    Child 2: 1 2 3 4 5 6 7 8 = 1 0 1 1 0 1 0 1

    |

    15

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    16/67

    ASCET

    b) Multi Point Crossover

    Two or more crossover points are selected, binary string from the beginning of the

    chromosome to the first crossover point is copied from the first parent, the part from the

    first to the second crossover point is copied from the other parent and the rest is copied

    from the first parent again.

    Par1 = 111 010 10

    Par2 = 110 011 11

    If two crossover points (3 & 6) are selected,

    Child1 = 111 011 10

    Child2 = 110 010 11

    c) Uniform Crossover

    In this method, crossover is performed over the entire length of the string of bits. For this,

    a mask is generated randomly. This mask is nothing but a string of bits of value 0 or 1

    and sizes same as string length. With the information in the mask, we generate the

    children as below.

    Par1 : 1 1 0 0 1 0 1 1

    Par2 : 0 1 0 0 0 1 0 0

    Mask : 0 0 1 0 1 1 0 1

    Child 1: 1 1 0 0 0 1 1 0 (If mask=0, Child 1= Par 1 & Child 2= Par 2)

    Child 2: 01 0 0 1 0 0 1 (If mask=1, Child 1= Par 2 & Child 2= Par 1)

    Here we need to generate a mask for each crossover but we dont need to store them, so

    number of masks needed is equal to the no of crossover need to be performed. We

    generate them as and when required and discard them thereafter.

    Thus we have seen that each crossover resulted in two children. So the number of

    crossovers required to be performed for next generation depends on the number of

    children we need. Usually it is a general practice to copy some of the best parents as it is

    into the next generation the required strings as children. This phenomenon of copying

    16

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    17/67

    ASCET

    best parents into the next generation is called Elitism and the number of parents so

    copied is indicated by a parameter of GA called Percentage of Elitism (Pe). This is

    nothing but the % of parents so copied of the total number of parents. This Elitism is

    basically carried out to not to loose the best strings obtained so far which otherwise may

    be lost.

    In order to control crossover also there is a parameter called Crossover Probability

    (Pc). This probability is used as a decision variable before performing the crossover.

    This is done as follows. A random number between 0 and 1 is generated and if that

    number is less then Pc, crossover is performed. The randomly generated number is

    greater than Pc, Child1 and Child2 are directly selected as Par1 and Par2. This is

    equivalent to the case of crossover where crossover site is equal to the string length.

    There are various other techniques too for implementing the Pc and the programmer of

    GA is given freedom to choose any one. But the above technique is mostly used.

    Mutation

    This operator is capable of creating new genetic material in the population to maintain the

    population diversity. It is nothing but random alteration of a bit value at a particular bit

    position in the chromosome. The following example illustrates the mutation operation.

    Original String: 1011001 Mutation site: 4 (assumption)

    String after mutation: 1010001

    Some programmers prefer to choose random mutation or alternate bit mutation.

    Mutation Probability (Pm) is a parameter used to control the mutation. For each string

    a random number between 0 and 1 is generated and compared with the Pm. if it is less

    than Pm mutation is performed on the string. Some times mutation is performed bit-by-

    bit also instead of strings. These results in substantial increase in CPU time but

    performance of GA will not increase to the recognizable extent. So this is usually not

    preferred.

    17

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    18/67

    ASCET

    Thus obviously mutation brings in some points from the regions of search space which

    otherwise may not be explored. Generally mutation probability will be in the range of

    0.001 to 0.01. This concludes the description of Genetic Operators.

    3.3 Standard genetic algorithm

    Begin

    Initialize

    chromosomes in the population

    evaluate fitness of all chromosomes

    do until

    number of generations is large enough

    do until

    the new population is formed

    select parents from the old population

    produce offsprings via reproduction, crossover or mutation process

    evaluate fitness of offsprings

    enddo

    enddo

    end

    18

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    19/67

    ASCET

    Chapter 4. Application of Genetic Algorithm to Optimal

    power dispatch

    4.1 Problem description for single node electricity market

    For a single node auction market, the supply and demand curves at each single node can

    be illustrated as shown in Fig. 1. The supply curve is obtained by ordering selling bids in

    increasing order of price, where as the demand curve is obtained by ordering buying bids

    in decreasing order of price. In this figure, the x-axis gives the cumulative value of the

    bidding quantity and the y-axis gives the bidding price. The spot price at a single node is

    the price which matches the supply and demand bids, i.e. the point at which the supply

    and demand curves intersect each other. At the spot price, the benefit of participants is

    maximised and this is illustrated by the shaded area in Fig. 4-1. This single node auction

    model can be mathematically described as follows:

    Fig. 4-1:An example of the supply and demand curves

    19

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    20/67

    ASCET

    Assuming that there areMksupply bids andNkdemand bids at the kth node. Let Sikbe the

    ith supply bid at node kand is given by Sik= {xs

    ik, psik}, wherex

    sikis the selling price and

    psikis the selling quantity. In addition, letBikbe the ith demand bid at node kand is given

    byBik = {xdik, p

    dik}, wherex

    dikis the buying price andpdikis the buying quantity. If kx

    denotes the spot price and kp denotes the spot quantity, then the maximum participants

    benefit, which is the sum of suppliers benefit and consumers benefit, can be given as

    ( ) ( )s dk k

    s s d d

    k k ik ik jk k jk

    i M j N

    B x x p x x p

    = + % % ----------- (4.1)

    whered

    ikp% ands

    ikp% are consumers and suppliers dispatched quantity, respectively,s

    kM

    andd

    kN are the sets of all dispatched suppliers and dispatched consumers, respectively.

    The following table 4.1 shows the participants benefit and spot prices for a single node

    electricity market of the 17-node, 26-line system.

    20

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    21/67

    ASCET

    Table 4.1

    Node Spot price($/MW) Participants benefit($)

    1 1.140000 14.4400002 0.700000 376.500000

    3 ----- -----

    4 1.400000 2.700000

    5 1.100000 8.300000

    6 1.000000 2.000000

    7 0.010000 30.760000

    8 ----- -----

    9 ----- -----

    10 1.000000 12.900000

    11 1.400000 34.200000

    12 1.000000 4.80000013 1.300000 35.500000

    14 ----- -----

    15 1.000000 65.500000

    16 1.000000 63.800000

    17 ----- -----

    Total 651.56

    4.2 Problem description for multi node electricity market

    For a multi-node electricity auction market, there are transmission lines connected

    between bidding nodes. The connections result in real power pk and reactive power qk

    injection to the network at each node. The real power injection to a node can be modelled

    as an additional demand bid (or a supply bid if the real power injection is negative) by the

    network for the quantity pkat the selling (or buying) price kx , which is equal to the spot

    price. This network effect is described in detail in [1]. As an example, Fig. 4-2 illustrates

    the dispatch of the bids when the real power injection is considered. In Fig. 4-2a , the

    injection ofPk to the node is supplied by the partly dispatched generator bid. The spot

    quantity has increased and the price has not changed. If the injected power is greater than

    the undispatched amount of the partly dispatched supply bid then the additional amount

    cannot be supplied at the same price. Therefore, the spot price will increase as shown in

    21

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    22/67

    ASCET

    Fig. 4-2b. This will result in displacing some consumers as shown by dc in Fig. 4-2b. It

    can be seen in Fig. 4-2 that the spot price and spot quantity may be changed due to the

    effect of the real power injection. This may result in changing the sets Bikand Sikof all

    dispatched suppliers and dispatched consumers. Consequently, the participants benefit at

    node kis now given by [1]

    ' ( ) ( )s dk k

    s s d d

    k k ik ik jk k jk k k

    i M j N

    B x x p x x p x p

    = + & &

    & % & % &-------------(4.2)

    wheres

    kM& and

    d

    kN& are the new sets of all dispatched suppliers and dispatched

    consumers respectively, kx& is the new spot price and the last term is the amount paid by

    the transmission line. In addition, the total participants benefit at all nodes can be

    expressedas

    '

    1

    ( ) ( )s dk k

    Ks s d d

    k k ik ik jk k jk k k

    k i M j N

    B x x p x x p x p=

    = +

    & &

    & % & % & ------------(4.3)

    whereKis the number of nodes.

    22

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    23/67

    ASCET

    Fig. 4-2a

    Fig. 4-2b

    Fig. 4-2: Examples of the network effects.

    23

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    24/67

    ASCET

    It can be easily seen that the participants benefit at each node ('

    kB ) is a function of the

    real power injection. Therefore, the optimization problem of the total participants benefit

    at all nodes is similar to the conventional optimal load flow problem, with the exception

    that the objective is to maximize the participants benefit, rather than minimize thegeneration cost. This optimization problem can be described as

    Maximize

    1

    ( ) ( )s dk k

    Ks s d d

    k ik ik jk k jk k k

    k i M j N

    x x p x x p x p=

    +

    & &

    & % & % & -------------- (4.4)

    subject to the following constraints:

    The capacity constraints which provide the limits on real power (pk) and reactive power

    (qk) injection to the network by any node, i.e.

    k k kp p p ------------------ (4.5)

    k k kq q q ------------------ (4.6)

    where kp , kp are the minimum and maximum real power injection limit associate with

    node k and kq , kq are the minimum and maximum reactive power output limits of

    generators associate with node k.

    Constraints on the limit of power flow along lines which are given by

    kl kl p p --------------------- (4.7)

    where klp is the maximum limit of a power flow in a line connecting node kand node l.

    In addition, the real and reactive power injection at each node can be determined as a

    summation of the real and reactive power flows along lines which are connected to that

    node. These are given by

    24

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    25/67

    ASCET

    1

    K

    k kl

    ll k

    p p=

    = -------------------- (4.8)

    1

    K

    k kl

    ll k

    q q=

    = -------------------- (4.9)

    wherepkland qklare the real power and reactive power flow along the transmission line

    connecting node k and node l, respectively. Furthermore, the real power and reactive

    power flow are given by the following equations

    2

    ( cos( )) ( sin( ))kl kl k k l k l kl k l k l p G v v v B v v = ----------------- (4.10)

    2( cos( )) ( sin( ))kl kl k k l k l kl k l k l q B v v v G v v = + ----------------- (4.11)

    where Gkl and Bkl are real and imaginary component of the admittance of the line

    connecting node k and node l, k and l are angles at node k and l and vk and vlare

    voltages at node kand node l.

    This optimisation problem has non-linear constraints which is difficult to solve using the

    linear programming technique. A genetic algorithm is proposed in the following section

    to solve the above problem. The genetic algorithms are simple to implement and it is easy

    to incorporate additional constraints into the problem.

    25

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    26/67

    ASCET

    Fig. 4.3 One line diagram of the 17 bus test system

    26

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    27/67

    ASCET

    Table: 1.Transmission line data

    Line

    data

    From

    node

    To

    node

    X(pu) B(pu) Capacity(mw)

    L1 1 16 0.015 0.06045 960

    L2 2 4 0.00115 0.0073 2470

    L3 3 1 0.000733 0.002967 858

    L4 3 4 0.00065 0.00535 1494

    L5 4 5 0.0164 0.0966 286

    L6 4 9 0.0678 0.1912 69

    L7 5 7 0.0107 0.0631 286

    L8 6 4 0.01525 0.07235 488

    L9 7 12 0.0014 0.0082 286

    L10 8 7 0.00125 0.00925 1144

    L11 8 10 0.0099 0.0239 207

    L12 9 1 0.1595 0.4272 69

    L13 9 11 0.02535 0.06695 138

    L14 11 12 0.0008 0.0045 1492

    L15 11 14 0.1951 0.3683 61

    L16 11 15 0.1467 0.3999 69

    L17 12 6 0.0063 0.02995 488

    L18 13 11 0.043 0.0823 122

    L19 13 12 0.0084 0.0543 488

    L20 13 14 0.053167 0.0108 183

    L21 14 15 0.0111 0.02405 152

    L22 15 12 0.000967 0.008633 975

    L23 16 13 0.0046 0.0323 488

    L24 16 15 0.00395 0.0271 976

    L25 16 17 0.0068 0.0645 747

    L26 17 15 0.0023 0.0191 716

    Table:2.Reactive power constraints at nodes

    Node No Qk(min)MW Qk(max)MW

    1 187.6 -119

    2 400 -400

    3 0 0

    4 32.2 -21.68

    27

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    28/67

    ASCET

    5 58.1 -92.4

    6 96 -140

    7 66 -71.6

    8 50 -50

    9 0 0

    10 64 -72.811 47 -62.6

    12 403 -531

    13 43.5 -63

    14 0 0

    15 140 -124

    16 468 -432

    17 0 0

    5. Implementation of genetic algorithm

    Several essential schemes need to be designed in order to apply a genetic algorithm to a

    multi-node electricity market. These are the encoding scheme, fitness function, crossover

    method and control parameters.

    5.1. Encoding scheme

    The optimisation problem considered in this case is to find the spot price and spot

    quantity at all nodes which maximise the participants benefit (given in Eq. (4.4)). As

    mentioned earlier, the spot price and quantity at each node depend on the real power (pk)

    injection which is in turn depending on the voltage (vk) and the angle ( k ). Therefore, a

    candidate solution at each node can be either an array of the real power and reactive

    power injection or an array of the voltage and angle. Although an array of random

    voltages and angles at all nodes may lead to easy evaluation of power flows (using Eqs.

    (4.10) and (4.11)) and real power injections (using Eq. (4.8)) at all nodes, the evaluated

    28

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    29/67

    ASCET

    results are unlikely to satisfy the power capacity limit constraints at all nodes and the line

    capacity constraints at all transmission lines.

    Fig. 5.1: Encoding Scheme.

    On the other hand, with an array of real power and reactive power injections (as shown in

    Fig. 4-3), power flows in the network can only be determined via an iterative load flow

    solution [6], but the power capacity limit constraints can be incorporated into the

    encoding scheme. Both representations were tried during the early part of our work and it

    was found that the choice of real power and reactive power is better than voltage and

    phase angle. The encoding chromosome consists of 2*10*(K- 1) bits, in which each 10-

    bit binary string is used to represent a range between the maximum and minimum real

    power (or reactive power) limit at each node. In addition, the real power and reactive

    power injection at the reference node can be obtained from the load flow solution.

    5.2. Fitness value

    The objective function in this optimisation problem is given by Eq. (4.4) and this can be

    used as a fitness function in the genetic algorithm. Therefore, the fitness value of each

    chromosome can be determined by

    1

    ( ) ( )s dk k

    Ks s d d

    k ik ik jk k jk k k

    k i M j N

    F x x p x x p x p=

    = +

    & &

    & % & % & ------------------

    (5.12)

    29

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    30/67

    ASCET

    In addition, the load flow problem need to be evaluated for each chromosome to ensure

    that none of the power flows along transmission lines violates the line capacity constraint.

    In this thesis, the fast-decoupledload flow method is used to solve the load flow problem

    [7]. If a chromosome has violated the power flow limit, a penalty value will be assigned

    to its fitness. This will result in a small fitness value and the violated chromosome is

    unlikely to be selected as a parent in the next reproduction process.

    5.3. Crossover and mutation schemes

    Several crossover methods have been proposed in the literature, these include one point

    crossover, two point crossoverand uniform crossover. The one point crossover method

    selects a random crossover point along the parents and swaps binary bits of the parent

    chromosomes beyond the selected point. The two point crossover method is similar to

    one point crossover except two random crossover positions are selected and binary bits

    between two selected points are swapped. In the uniform crossover method, crossover

    positions are randomly selected and a binary bit at each selected point is swapped. There

    is no simple way of choosing the best crossover method; the success or failure of a

    particular crossover method also depends on the selection of the fitness function and

    control parameters. A simple mutation method is to randomly toggle the content of each

    binary bit position in a chromosome. As an example, if mutation occurring at the third bit

    position of the string 1001011 would give 1011011.

    5.4. Control parameters

    The performance of the genetic algorithm also depends on control parameters, such as

    population size, crossover probability and mutation probability. The population size is the

    number of chromosomes in each generation, typically the size increasing according to the

    problem difficulty. The crossover probability is a probability that crossover occurs after

    the reproduction process. Typical value for the crossover probability ranges from 0.5 to

    0.95. The mutation probability is the probability of the mutation operator in each bit

    position. The mutation probability is typically very small (0.0010.01).

    30

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    31/67

    ASCET

    5.5. Algorithm for multi node electricity market using GA:

    1. Read the system data such as no.of buses, no.of lines, slack bus no., line data, bus

    data.

    2. Read the genetic algorithm data such as Pe, Pc, Pm, maximum no.of generations,

    chromosome length, population size.

    3. Read the suppliers bidding data and consumers bidding data. A bidding data is

    comprised of quantity of power injection, price.

    4. Form Ybus with given system data.

    5. Form B1, B2 matrices in the fast decoupled algorithm.

    6. Generate random population of given population size each having given

    chromosome length.

    7. Decode the chromosome into decimal value and apply the maximum and

    minimum limits.

    8. The decoded values gives the real power and reactive power injections at all the

    buses except slack bus.

    9. Supply these power injections as inputs to fast decoupled load flow.

    10. The output of fast decoupled load flow will be voltage magnitudes and phase

    angles at all the buses.

    11. After the convergence of the load flow compute power flows through all the lines,

    real and reactive power injections of slack bus.

    12. Evaluate fitness value (total benefit) using Eq.(4.12).

    13. Generate a new population from the present population using the following steps:

    14. Copy chromosomes with the best fit 10% to the new population.

    15. The remaining offsprings can be generated by repeating the following steps until

    the new population is filled.

    16. Using Roulette wheel technique select two parents.

    17. Generate a random number and if it is greater than the crossover probability then

    generate two offsprings via the crossover process else the two parents becomes

    offsprings.

    31

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    32/67

    ASCET

    18. With the mutation probability, apply the mutation process to the offspring.

    19. Check for convergence of genetic algorithm by calculating the error in each

    chromosome.

    20. If error < tolerance go to step 22 else go to step15.

    21. If total no.of offsprings equal to population size update old population with new

    population and go to step 7.

    22. Print the power injections, voltages, phase angles, power flows, spot price,

    participants benefit, lines benefit and total benefit at all the nodes.

    23. End.

    5.5 Case studies

    The genetic algorithm was implemented on a Pentium-133

    microcomputer using a C__ programming language and it was applied

    to a test system with 17 nodes and 26 lines shown in Fig. 4.3. The

    transmission line data of the network are given in Table 1 and the

    reactive power capacity limits are given in Table 2. The real power

    injection at a given node is maximum when all selling bids are

    dispatched. Therefore the maximum possible injection is equal to thetotal amount of power offered by suppliers at that node. Similarly, the

    minimum power injection (i.e. maximum negative injection) is when no

    selling bids are dispatched and all buying bids are dispatched. In this

    case, it is equal to the total amount of power bid by the consumers.

    One difficulty in using a genetic algorithm is the selection of the control

    parameters and the crossover methods. In this study, genetic

    algorithms were executed with different combinations of the control

    parameters which were varied from the following list:

    . population size: 100, 200, 400

    . crossover probability: 0.5, 0.7, 0.9

    . mutation probability: 0.01, 0.001

    . crossover methods: two-point, uniform

    32

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    33/67

    ASCET

    Each genetic algorithm was run 20 times and each run was carried out

    over 200 generations. The average final objective function value of all

    runs in each genetic algorithm is used as a measure of the algorithms

    performance. The genetic algorithms with the population size of 400

    requires a computational time of approximately 20 times that of 200

    population for the test system. The results have shown that the

    uniform crossover method performs better than the two point

    crossover method. In addition, the genetic algorithms performed well

    with the population size of 400, the crossover probability of 0.7 and the

    mutation probability of 0.01. Nevertheless, most of the genetic

    algorithms converged to good solutions for this test system. The result

    obtained from the genetic algorithm associated with the chosen control

    parameters are given in Tables 57. Table 5 gives the results of the

    real power and reactive power injection to the system and the

    associated voltages and angles at the nodes. Table 6 gives the results

    of the power flows along transmission lines. Table 7 gives the

    participants benefits and spot prices at all nodes. It can be seen that

    the total participants benefit is 658.96 when trading within the node.

    (i.e. without transmission network) When the trading among the nodestake place through the network, the genetic algorithm gives a total

    participants benefit of 1278.14. In addition, the spot price differences

    among nodes have been decreased due to trading on the network, in

    which the spot price at each node is equal or close to 1.20. Results

    show that the transaction across the network has resulted in

    decreasing the price differences between nodes. Further, the total

    benefit to the participants has increased as expected. According to

    basic concepts, there cannot be a price difference between two ends of

    an a line if the line has not reached the capacity limit. Further, if there

    is a price difference due to line capacity limits, the power flow must be

    in the direction of the low price node to the high price node. The

    results obtained are consistent with the above concepts excepts for

    33

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    34/67

    ASCET

    some lines.These exceptions are lines L3, L4 and L5. Inspection of

    dispatched bids at node 3 reveals that, although the price at node 3 is

    1.1, it is at the corner of 1.1 and 1.2; and theoretically the price can be

    anywhere between 1.1 and 1.2. If the spot price at node 3 is 1.2

    instead of 1.1, the direction of power flow in lines L3 and L4 are not

    unusual. Further the network topology is such that the route to channel

    power from node 2 to 8 is through node 5 (the generation at node 7 is

    fully utilised). This explains why the power in line L5 is from node 4 to

    5. The network earns a surplus due to price differences at the ends of

    lines, while it lose revenue due to power losses in the lines. In this test

    system the price differences are very small. As a result the benefit to

    the network is very small.

    34

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    35/67

    ASCET

    Table 5: Power injection, voltage and phase angles

    Node P(MW) Q(MVAR) Voltage(V) Angle(degree)

    1 162.00 139.51 1.05 7.00

    2 281.34 11.72 1.05 8.993 -51.16 -38.19 1.049 6.92

    4 -123.55 -39.37 1.05 6.90

    5 46.40 -36.98 1.05 5.18

    6 15.23 30.54 1.05 3.47

    7 234.84 81.92 1.05 2.50

    8 -156.52 -85.05 1.05 1.72

    9 -35.0 -2.17 1.042 2.42

    10 -3.26 12.99 1.05 1.67

    11 -234.14 -160.73 1.05 1.32

    12 231.23 363.40 1.05 1.82

    13 -113.96 -60.97 1.05 1.76

    14 -30.10 -5.26 1.041 0.751

    15 -437.96 -158.88 1.05 0.58

    16 443.20 126.14 1.05 4.24

    17 -213.00 -310.80 1.0 0.0

    Table 6: Power flows

    Line no. Pkl (MW) Plk(MW) Line no. Pkl(MW) Plk(MW)

    L1 85.64 -84.93 L14 -209.06 209.38

    L2 281.34 -279.66 L15 3.35 -3.33

    L3 -57.50 57.53 L16 3.14 -3.12

    L4 6.33 -6.33 L17 -101.09 101.71

    35

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    36/67

    ASCET

    L5 33.35 -33.18 L18 8.14 -8.11

    L6 41.51 -40.40 L19 -2.15 2.15

    L7 79.59 -78.96 L20 24.02 -23.26

    L8 -86.47 87.57 L21 -3.49 3.63

    L9 153.72 -153.41 L22 -273.54 274.20

    L10 -159.78 160.08 L23 144.87 -143.99L11 3.26 -3.26 L24 255.23 -252.87

    L12 -18.28 18.82 L25 128.01 -126.68

    L13 23.68 -23.46 L26 -86.31 87.94

    Table 7: Participants benefits and spot prices

    Node With Network Effect

    Spot

    price($/MW)

    Total

    benefit($)

    Participants

    benefit($)

    Lines

    benefit($)

    1 1.14 -170.08 14.60 -184.68

    2 1.20 118.98 456.60 -337.61

    3 1.10 72.48 16.20 56.28

    4 1.20 161.66 13.40 148.265 1.10 -42.74 8.30 -51.04

    6 1.20 -7.68 10.60 -18.28

    7 1.10 2.42 260.75 -258.32

    8 1.20 204.72 16.90 187.82

    9 1.20 44.7 2.70 42.00

    10 1.20 21.71 17.8 3.91

    11 1.20 333.16 52.20 280.96

    36

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    37/67

    ASCET

    12 1.20 -245.67 31.80 -277.47

    13 1.20 177.25 40.50 136.75

    14 1.20 40.82 4.70 36.12

    15 1.20 640.16 114.60 525.56

    16 1.20 -378.94 157.90 -531.84

    17 1.20 295.90 40.30 255.60Total 1278.88 1259.85 14.03

    Table 8: Participants benefits and spot prices comparison

    Node With Network Effect Without

    network

    Without

    network

    Spot

    price($/MW)

    Total

    benefit($)

    Participants

    benefit($)

    Lines

    benefit($)

    Spot price Participants

    benefit

    1 1.14 -170.08 14.60 -184.68 1.14 14.60

    2 1.20 118.98 456.60 -337.61 0.70 376.50

    3 1.10 72.48 16.20 56.28 0.69 15.09

    4 1.20 161.66 13.40 148.26 1.40 2.70

    5 1.10 -42.74 8.30 -51.04 1.10 8.30

    6 1.20 -7.68 10.60 -18.28 1.00 2.00

    7 1.10 2.42 260.75 -258.32 0.01 30.76

    8 1.20 204.72 16.90 187.82 0.25 35.79

    9 1.20 44.7 2.70 42.00 1.00 2.45

    37

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    38/67

    ASCET

    10 1.20 21.71 17.8 3.91 1.00 12.90

    11 1.20 333.16 52.20 280.96 1.30 38.20

    12 1.20 -245.67 31.80 -277.47 1.00 4.80

    13 1.20 177.25 40.50 136.75 1.30 38.90

    14 1.20 40.82 4.70 36.12 1.20 35.27

    15 1.20 640.16 114.60 525.56 1.00 65.5016 1.20 -378.94 157.90 -531.84 1.00 63.80

    17 1.20 295.90 40.30 255.60 1.00 2.24

    Total 1278.88 1259.85 14.03 658.96

    The following graph shows the error Vs generation .

    Fig 6: Graph of Error Vs Generation

    38

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    39/67

    ASCET

    Chapter 6: source code

    clc;

    clear;

    ip=fopen('new1105.in','r+');

    op=fopen('new1105.out','w+');

    n=fscanf(ip,'%d',1);

    fprintf(op,'THE NUMBER OF BUSES ARE %d\n',n);

    nline=fscanf(ip,'%d',1);

    fprintf(op,'THE NUMBER OF LINES ARE %d\n',nline);

    nslack=fscanf(ip,'%d',1);

    fprintf(op,'THE SLACK BUS %d\n',nslack);

    itermax=fscanf(ip,'%d',1);fprintf(op,'THE MAXIMUM NUMBER OF ITERATIONS ARE

    %d\n',itermax);

    Linedata=fscanf(ip,'%f',[8,nline]);

    Linedata=Linedata';

    lp=Linedata(:,1); % ASSIGNING COLUMN 1 OF

    DATA TO Fm

    lq=Linedata(:,2); % ASSIGNING COLUMN 2 OF

    DATA TO To

    R=Linedata(:,3); % ASSIGNING COLUMN 3 OF

    DATA TO RX=Linedata(:,4); % ASSIGNING COLUMN 4 OF

    DATA TO X

    ycp=complex(0,Linedata(:,5)); %ASSIGNING

    COLUMN 5 OF DATA TO Ycharg

    ycq=complex(0,Linedata(:,6));

    tap=Linedata(:,7); %ASSIGNING COLUMN 7 OF DATA TO

    tap ratios

    cap=Linedata(:,8);

    fprintf(op,'\nLINE DATA OF THE SYSTEM \n');

    fprintf(op,'\nNo Fm TO R(k) X(k) Ycp(k)Ycq(k) tap(k)\n');

    for k=1:nline

    fprintf(op,'%d\t%d\t%d\t%f\t%f\t%f\t%f\t

    %f\n',k,lp(k),lq(k),R(k),X(k),imag(ycp(k)),imag(ycq(k)),tap

    (k));

    end

    39

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    40/67

    ASCET

    ycap=fscanf(ip,'%f',[1,n]);

    ycap=ycap';

    fprintf(op,'\nTHE SHUNT ADMITTANCES ARE\n');

    for i=1:n

    Yshunt(i)=complex(0,ycap(i));

    fprintf(op,'%d\t%f\n',i,ycap(i));end

    pop_size=40;

    chro_size=320;

    maxgen=100;

    pop=round(rand(pop_size,chro_size));

    Busvltg=fscanf(ip,'%f',[6,n]);

    Busvltg=Busvltg';

    Itype=Busvltg(:,1);

    Vspec=Busvltg(:,2);

    pmax=Busvltg(:,3);

    pmin=Busvltg(:,4);

    Qmax=Busvltg(:,5);

    Qmin=Busvltg(:,6);

    fprintf(op,'\nTHE BUS VOLTAGES ARE\n');

    fprintf(op,'bus itype Vspec Qmax

    Qmin\n');

    for i=1:n

    fprintf(op,'%d\t%f\t%f\t%f\t

    %f\n',i,Itype(i),Vspec(i),Qmax(i),Qmin(i));end

    sell=fscanf(ip,'%f',[14,n]);

    sell=sell';

    sum_piks=fscanf(ip,'%f',[1,17]);

    sum_piks=sum_piks';

    xjkd=fscanf(ip,'%f',[1,8]);

    pjkd=fscanf(ip,'%f',[8,17]);

    pjkd=pjkd';

    sum_pjkd=fscanf(ip,'%f',[1,17]);

    sum_pjkd=sum_pjkd';j=1;

    for i=1:7

    xiks(:,i)=sell(:,j);

    j=j+1;

    piks(:,i)=sell(:,j);

    j=j+1;

    40

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    41/67

    ASCET

    end

    xk=[1.14

    1.2

    1.1

    1.2

    1.11.2

    1.1

    1.2

    1.2

    1.2

    1.2

    1.2

    1.2

    1.2

    1.2

    1.2

    1.2];

    %****************FLAT VOLTAGE

    START****************************

    for i=1:n

    if Itype(i)==1

    Ebus(i)=complex(1,0);

    else

    Ebus(i)=complex( Vspec(i),0); end

    Vmag(i)=abs(Ebus(i));

    delA(i)=0;

    end

    %***********************READING BUS DATA

    OVER*****************************

    %FORMING RESERVATION CHART

    for k=1:n

    nlcont(k)=0;

    endfor k=1:nline

    p=lp(k);

    q=lq(k);

    nlcont(p)=nlcont(p)+1;

    nlcont(q)=nlcont(q)+1;

    end

    41

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    42/67

    ASCET

    %FORMATION OF ITAGF AND ITAGTO VECTORS

    itagf(1)=1;

    itagto(1)=nlcont(1);

    for i=2:n

    itagf(i)=itagto(i-1)+1;

    itagto(i)=itagto(i-1)+nlcont(i);end

    %FORMATION OF ADJQ AND ADJL VECTORS

    for k=1:n

    nlcont(k)=0 ; %reintialisation

    end

    for k=1:nline

    p=lp(k);

    q=lq(k);

    lpq=itagf(p)+nlcont(p);

    lqp=itagf(q)+nlcont(q);

    nlcont(p)=nlcont(p)+1; %UPDATE NLCOUNT

    nlcont(q)=nlcont(q)+1;

    adjq(lpq)=q; %FORMING ADJQ VECTOR

    adjl(lpq)=k; %FORMING ADJL VECTOR

    adjq(lqp)=p;

    adjl(lqp)=k;

    end

    for k=1:nline

    Z(k)=complex(R(k),X(k));yline(k)=1/Z(k);

    end

    %MODELLING OF OFF NOMINAL TAP CHANGING TRANSFORMER

    for k=1:nline

    a=tap(k);

    if a~=1

    a1=1-1/a;

    a2=-a1/a;

    ycp(k)=a2*yline(k);

    yline(k)=yline(k)/a;ycq(k)=a1*yline(k);

    else,end

    end

    % FORMATION OF DIAGONAL ELEMENTS OF YBUS

    for i=1:n

    ypp(i)=complex(0,0);

    42

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    43/67

    ASCET

    end

    for k=1:nline

    p=lp(k);

    q=lq(k);

    ypp(p)=ypp(p)+yline(k)+ycp(k);

    ypp(q)=ypp(q)+yline(k)+ycq(k);end

    for i=1:n

    ypp(i)=ypp(i)+Yshunt(i);

    end

    fprintf(op,'\nTHE DIAGONAL ELEMENTS ARE\n');

    for i=1:n

    fprintf(op,'ypp(%d)= %f

    %fi\n',i,real(ypp(i)),imag(ypp(i)));

    end

    %FORMATION OF OFF DIAGONAL ELEMENTS OF YBUS

    for i=1:2*nline

    k=adjl(i);

    ypq(i)=-yline(k);

    end

    fprintf(op, '\nTHE OFF DIAGONAL ELEMENTS ARE\n');

    for i=1:2*nline

    fprintf(op,'ypq(%d)=%f +

    %fi\n',i,real(ypq(i)),imag(ypq(i)));

    end%******************FORMING YBUS HAS BEEN

    COMPLETED*************************/

    %FORMATION OF B1 MATRIX

    for i=1:n

    for j=1:n

    B1(i,j)=0;

    B2(i,j)=0;

    end

    end

    for k=1:nlinep=lp(k);

    q=lq(k);

    temp=1/(X(k));

    B1(p,q)=-temp;

    B1(q,p)=B1(p,q);

    B1(p,p)=B1(p,p)+temp;

    43

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    44/67

    ASCET

    B1(q,q)=B1(q,q)+temp;

    end

    B1(nslack,nslack)= 10^20;

    %Formation of B1 matrices over

    for i=1:n

    for j=1:n if B1(i,j)~=0

    fprintf( op,'B1(%d,%d)=%f+

    %f\n',i,j,real(B1(i,j)),imag(B1(i,j)));

    end

    end

    end

    %DECOMPOSITION OF B1 MATRIX BY CHOLESKY METHOD

    B1(1,1)=sqrt(B1(1,1));

    for j=2:n

    B1(1,j)=B1(1,j)/B1(1,1);

    B1(j,1)=B1(1,j);

    end

    for i=2:n

    for j=i:n

    if i==j

    sum=0;

    for k=1:i-1

    sum=sum+B1(i,k)^2;

    endB1(i,i)=sqrt(B1(i,i)-sum);

    else

    sum=0;

    for k=1:i-1

    sum=sum+B1(i,k)*B1(k,j);

    end

    B1(i,j)=(B1(i,j)-sum)/B1(i,i);

    B1(j,i)=B1(i,j);

    end

    endend

    %Formation of B1 matrices over

    %FORMATION OF B2 MATRIX

    for i=1:n %diagonal elements

    B2(i,i)=-imag(ypp(i));

    end

    44

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    45/67

    ASCET

    for i=1:n

    Jstart=itagf(i);

    Jstop=itagto(i);

    for j=Jstart:Jstop

    q=adjq(j);

    k=adjl(j);B2(i,q)=imag(yline(k)); %off diagonal elements

    end

    end

    for i=1:n

    if(Itype(i)==2)

    B2(i,i)=10^20;

    end

    B2(nslack,nslack)=10^20;

    end

    for i=1:n

    for j=1:n

    if B2(i,j)~=0

    fprintf( op,'B2(%d,%d)=%f\n',i,j,B2(i,j));

    end

    end

    end

    %formation of B2 matrix over

    %DECOMPOSITION OF B2 MATRIX BY CHOLESKY METHOD

    B2(1,1)=sqrt(B2(1,1));for j=2:n

    B2(1,j)=B2(1,j)/B2(1,1);

    B2(j,1)=B2(1,j);

    end

    for i=2:n

    for j=i:n

    if i==j

    sum=0;

    for k=1:i-1

    sum=sum+B2(i,k)^2; end

    B2(i,i)=sqrt(B2(i,i)-sum);

    else

    sum=0;

    for k=1:i-1

    sum=sum+B2(i,k)*B2(k,j);

    45

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    46/67

    ASCET

    end

    B2(i,j)=(B2(i,j)-sum)/B2(i,i);

    B2(j,i)=B2(i,j);

    end

    end

    end%**********************************************************

    ******%

    tic

    t=0;

    generation=1;

    while(t==0)

    %calculation of coded values

    for c=1:pop_size

    failure(c)=0;

    j1=0;

    for i=1:n-1

    psp(i)=0;

    for j=1:10

    psp(i)=psp(i)+(2^-j)*pop(c,j+j1);

    end

    j1=j1+j;

    Pspec(i)=pmin(i)+(pmax(i)-pmin(i))*psp(i);

    end

    next=i+1;nextnext=2*(n-1);

    for i=next:nextnext

    l=i+1-next;

    x1(l)=0;

    for j=1:10

    x1(l)=x1(l)+(2^-j)*pop(c,j+j1);

    end

    j1=j1+j;

    Qspec(l)=Qmin(l)+(Qmax(l)-Qmin(l))*x1(l);

    endfor iter=0:itermax

    dPmax=0;

    dQmax=0;

    %CALCULATION OF INJECTED POWERS AT ALL BUSES

    for i=1:n

    if i~=nslack

    46

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    47/67

    ASCET

    Inew=ypp(i)*Ebus(i);

    Jstart=itagf(i);

    Jstop=itagto(i);

    for j=Jstart:Jstop

    q=adjq(j);

    Inew=Inew+ypq(j)*Ebus(q); end

    s=Ebus(i)*conj(Inew);

    Pcal(i)=real(s);

    Qcal(i)=imag(s);

    else, end %if closing

    end

    % CALCULATION OF INJECTED POWERS OVER

    %CALCULATION OF MISMATCHES

    for i=1:n

    if i~=nslack

    dP(i)=Pspec(i)-Pcal(i);

    if Itype(i)==1

    dQ(i)=Qspec(i)-Qcal(i);

    else

    dQ(i)=0.0; %for PV bus

    end

    else

    dP(i)=0.0; %for slack bus

    dQ(i)=0.0;end

    end

    dPmax=max(abs(dP));

    dQmax=max(abs(dQ)) ;

    for i=1:n

    dP(i)=dP(i)/Vmag(i);

    end

    %FORWARD SUBSTITUTION

    if(dPmax> 0.0001||dQmax>0.0001)

    Y(1)=dP(1)/B1(1,1);for i=2:n

    temp=0.0;

    for j=1:i-1

    temp=temp+B1(i,j)*Y(j);

    end

    Y(i)=(dP(i)-temp)/B1(i,i);

    47

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    48/67

    ASCET

    end

    %BACKWARD SUBSTITUTION

    X1(n)=Y(n)/B1(n,n);

    for i=n-1:-1:1

    temp=0.0;

    for j=i+1:ntemp=temp+B1(i,j)*X1(j);

    X1(i)=(Y(i)-temp)/B1(i,i);

    end

    end

    %UPDATING PHASE ANGLES

    for i=1:n

    delA(i)=delA(i)+X1(i);

    e(i)= Vmag(i)*cos(delA(i));

    f(i)= Vmag(i)*sin(delA(i));

    Ebus(i)=complex(e(i),f(i));

    end

    iter=iter+.5;

    else

    converged=1;

    break;

    end

    %HALF ITERATION OVER**************************

    dPmax=0;

    dQmax=0;%CALCULATION OF INJECTED POWERS AT ALL BUSES

    for i=1:n

    if i~=nslack

    Inew=ypp(i)*Ebus(i);

    Jstart=itagf(i);

    Jstop=itagto(i);

    for j=Jstart:Jstop

    q=adjq(j);

    Inew=Inew+ypq(j)*Ebus(q);

    ends=Ebus(i)*conj(Inew);

    Pcal(i)=real(s);

    Qcal(i)=imag(s);

    else, end %if closing

    end %end of ith loop

    % CALCULATION OF INJECTED POWERS OVER

    48

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    49/67

    ASCET

    for i=1:n

    if i~=nslack

    dP(i)=Pspec(i)-Pcal(i);

    if Itype(i)==1

    dQ(i)=Qspec(i)-Qcal(i);

    elsedQ(i)=0.0; %for PV bus

    end

    else

    dP(i)=0.0; %for slack bus

    dQ(i)=0.0;

    end

    end

    dPmax=max(abs(dP));

    dQmax=max(abs(dQ)) ;

    for i=1:n

    dQ(i)=dQ(i)/Vmag(i);

    end

    %FORWARD SUBSTITUTION

    if(dPmax>0.0001||dQmax>0.0001)

    Y(1)=dQ(1)/B2(1,1);

    for i=2:n

    temp=0.0;

    for j=1:i-1

    temp=temp+B2(i,j)*Y(j); end

    Y(i)=(dQ(i)-temp)/B2(i,i);

    end

    %BACKWARD SUBSTITUTION

    dV(n)=Y(n)/B2(n,n);

    for i=n-1:-1:1

    temp=0.0;

    for j=i+1:n

    temp=temp+B2(i,j)*dV(j);

    enddV(i)=(Y(i)-temp)/B2(i,i);

    end

    %UPDATING THE VOLTAGE MAGNITUDES

    for i=1:n

    Vmag(i)=Vmag(i)+dV(i);

    e(i)= Vmag(i)*cos(delA(i));

    49

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    50/67

    ASCET

    f(i)= Vmag(i)*sin(delA(i));

    Ebus(i)=complex(e(i),f(i));

    end

    iter=iter+0.5;

    else

    converged=1;break;

    end

    end% iter loop

    if(converged==1)

    fprintf(op,'PROBLEM CONVERGED IN %f ITERATIONS\n',iter);

    fprintf(op,'THE BUS VOLTAGES ARE\n');

    for i=1:n

    fprintf(op,'%f\t%f\n',Vmag(i),delA(i)*180/3.14);

    end

    else

    fprintf(op,'THE PROBLEM FAILED TO CONVERGE IN %d

    ITERATIONS\n',iter);

    end

    %PROBLEM CONVERGED,COMPUTE POWER FLOWS

    for k=1:nline

    p=lp(k);

    q=lq(k);

    temp1=conj(Ebus(p))*((Ebus(p)-Ebus(q))*yline(k)

    +Ebus(p)*ycp(k));temp2=conj(Ebus(q))*((Ebus(q)-Ebus(p))*yline(k)

    +Ebus(q)*ycq(k));

    Ppq(k)=real(temp1);

    Pqp(k)=real(temp2);

    end

    for i=1:nline

    fprintf(op,'L%d\t%f\n',i,Ppq(i)*100);

    end

    limit=zeros(1,nline);

    for k=1:nline if abs(Ppq(k))>(cap(k)/100)

    limit(k)=1;

    % fprintf(op,'\n%dth line limit has exceeded \n',k);

    break;

    end

    %assigning chromosome to 1

    50

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    51/67

    ASCET

    if limit(k)==1

    failure(c)=1;

    end

    end

    %calculation of slackbus power

    Islack=ypp(nslack)*Ebus(nslack);for i=nslack

    jstart=itagf(i);

    jto=itagto(i);

    for g1=jstart:jto

    q=adjq(g1);

    Islack=Islack+ypq(g1)*Ebus(q);

    end

    end

    P1=Ebus(nslack)*conj(Islack);

    Pslack=real(P1);

    Qslack=imag(P1);

    fprintf(op,'\nthe active power of slack bus is %f',Pslack);

    fprintf(op,'\nthe reactive power of slack bus is

    %f',Qslack);

    Pk=[Pspec Pslack];

    %***********************************************************

    %CALCULATION OF FITNESS VALUE

    for i=1:17

    disps(i)=0; for j=1:7

    if xiks(i,j)0

    if xk(i)>xiks(i,j)

    pbenefit(i)=pbenefit(i)+(xk(i)-

    xiks(i,j))*piks(i,j);

    end

    sdisp=sdisp-piks(i,j);

    51

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    52/67

    ASCET

    end

    end

    for j=1:8

    if xjkd(j)>xk(i)

    pbenefit(i)=pbenefit(i)+(xjkd(j)-

    xk(i))*pjkd(i,j); end

    end

    end

    lbenefit=0;

    for i=1:17

    lbenefit(i)=-(xk(i)*(Pk(i)*100));

    end

    tbenefit(i)=0;

    for i=1:17

    tbenefit(i)=pbenefit(i)+lbenefit(i);

    end

    benefit=tbenefit(1);

    for i=2:17

    benefit=benefit+tbenefit(i);

    end

    fprintf(op,'\nc=%d,benefit=%f',c,benefit);

    benefit

    sum2(c)=benefit;

    if failure(c)==1sum2(c)=sum2(c)*0.1;

    end

    end%end of pop_size

    population=[pop sum2'];

    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

    %%%%%%%

    %Sorting the population

    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

    %%%%%%%

    for i=1:pop_sizefor j=i+1:pop_size

    if population(j,321)>population(i,321)

    temp=population(i,:);

    population(i,:)=population(j,:);

    population(j,:)=temp;

    end

    52

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    53/67

    ASCET

    end

    end

    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

    %%%%%%%%

    %Calculation of Fitness Sum

    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

    Fitsum=zeros(1,pop_size);

    Fitsum(1)=population(1,321);

    for i=2:pop_size

    Fitsum(i)=Fitsum(i-1)+population(i,321);

    end

    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

    %%%%%%%%

    population=[population Fitsum'];

    %EVALUATION OF NEXT POPULATION

    nextpop=zeros(pop_size,chro_size);

    for i=1:(.1*pop_size)

    for j=1:320

    nextpop(i,j)=population(i,j);

    end

    end

    Tfit=population(pop_size,322);

    g=(.1*pop_size)+1;

    while gr && failure(i)~=1

    kk=kk+1;

    for h=1:320

    parent(kk,h)=population(i,h); end

    break;

    end

    end

    end

    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

    53

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    54/67

    ASCET

    a=0;

    b=1;

    r1=a+(b-a)*rand;

    %checking for pc

    if r1

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    55/67

    ASCET

    nextpop(g,:)=child(1,:);

    nextpop(g+1,:)=child(2,:);

    g=g+2;

    end%end of population generation

    %cheking for convergence

    error(generation)=abs(population(1,321)-population(pop_size,321));

    if(abs(population(1,321)-population(pop_size,321))maxgen)

    t=1;

    else

    generation=generation+1;

    pop=nextpop;

    end

    end

    t=toc

    k=1:generation;

    plot(k,error);

    fclose('all');

    Chapter 7: Results

    THE NUMBER OF BUSES ARE 17THE NUMBER OF LINES ARE 26

    55

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    56/67

    ASCET

    THE SLACK BUS 17

    THE MAXIMUM NUMBER OF ITERATIONS ARE 30

    LINE DATA OF THE SYSTEM

    No Fm TO R(k) X(k) Ycp(k) Ycq(k) tap(k)

    1 1 16 0.010500 0.060450 0.000000 0.000000 1.000000

    2 2 4 0.002300 0.014000 0.000000 0.000000 1.000000

    3 3 1 0.000733 0.002967 0.000000 0.000000 1.000000

    4 3 4 0.000650 0.005350 0.000000 0.000000 1.000000

    5 4 5 0.016400 0.096600 0.000000 0.000000 1.000000

    6 4 9 0.067800 0.191200 0.000000 0.000000 1.000000

    7 5 7 0.010700 0.063100 0.000000 0.000000 1.000000

    8 6 4 0.015250 0.072350 0.000000 0.000000 1.000000

    9 7 12 0.001400 0.008200 0.000000 0.000000 1.000000

    10 8 7 0.001250 0.009250 0.000000 0.000000 1.000000

    11 8 10 0.009900 0.023900 0.000000 0.000000 1.000000

    12 9 1 0.159500 0.427200 0.000000 0.000000 1.000000

    13 9 11 0.025350 0.066950 0.000000 0.000000 1.000000

    14 11 12 0.000800 0.004500 0.000000 0.000000 1.000000

    15 11 14 0.195100 0.368300 0.000000 0.000000 1.000000

    16 11 15 0.146700 0.399900 0.000000 0.000000 1.000000

    17 12 6 0.006300 0.029950 0.000000 0.000000 1.000000

    18 13 11 0.043000 0.082300 0.000000 0.000000 1.000000

    19 13 12 0.008400 0.054300 0.000000 0.000000 1.000000

    20 13 14 0.053167 0.010800 0.000000 0.000000 1.000000

    21 14 15 0.011100 0.024050 0.000000 0.000000 1.000000

    22 15 12 0.000967 0.008633 0.000000 0.000000 1.000000

    23 16 13 0.004600 0.032300 0.000000 0.000000 1.000000

    24 16 15 0.003950 0.027100 0.000000 0.000000 1.000000

    25 16 17 0.006800 0.064500 0.000000 0.000000 1.000000

    26 17 15 0.002300 0.019100 0.000000 0.000000 1.000000

    THE SHUNT ADMITTANCES ARE

    1 0.000000

    2 0.000000

    3 0.000000

    4 0.000000

    5 0.000000

    6 0.000000

    7 0.000000

    8 0.000000

    9 0.000000

    10 0.000000

    11 0.00000012 0.000000

    13 0.000000

    14 0.000000

    15 0.000000

    16 0.000000

    17 0.000000

    THE BUS VOLTAGES ARE

    56

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    57/67

    ASCET

    bus itype Vspec Qmax Qmin

    1 2.000000 1.050000 1.876000 -1.190000

    2 2.000000 1.050000 4.000000 -4.000000

    3 1.000000 1.050000 0.000000 0.000000

    4 2.000000 1.050000 0.322000 -0.216800

    5 2.000000 1.030000 0.581000 -0.924000

    6 2.000000 1.040000 0.960000 -1.4000007 2.000000 1.030000 0.660000 -0.716000

    8 2.000000 1.020000 0.500000 -0.500000

    9 1.000000 1.020000 0.000000 0.000000

    10 2.000000 1.020000 0.640000 -0.728000

    11 2.000000 1.020000 0.470000 -0.626000

    12 2.000000 1.020000 4.030000 -5.310000

    13 2.000000 1.010000 0.435000 -0.630000

    14 1.000000 1.000000 0.000000 0.000000

    15 2.000000 1.010000 1.400000 -1.240000

    16 2.000000 1.030000 4.680000 -4.320000

    17 0.000000 1.000000 0.000000 0.000000

    6th line limit has exceeded

    9th line limit has exceeded

    6th line limit has exceeded

    6th line limit has exceeded

    6th line limit has exceeded

    9th line limit has exceeded

    9th line limit has exceeded

    6th line limit has exceeded

    6th line limit has exceeded

    9th line limit has exceeded

    6th line limit has exceeded

    6th line limit has exceeded

    6th line limit has exceeded

    6th line limit has exceeded

    6th line limit has exceeded

    9th line limit has exceeded

    PROBLEM CONVERGED IN 73 GENERATIONS

    Power injection,voltage and angle results

    -----------------------------------------------

    Node P(MW) Q(MVAR) Voltage(V) Angle(degree)

    57

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    58/67

    ASCET

    -----------------------------------------------

    1 5.893125 -0.357629 1.050000 4.221735

    2 -2.782500 3.031250 1.050000 0.247870

    3 -0.069727 0.000000 1.048874 3.533069

    4 -0.872461 -0.216800 1.050000 2.334715

    5 0.332471 0.144491 1.030000 2.605349

    6 0.240937 -0.330625 1.040000 1.0605957 2.324707 0.501437 1.030000 1.497762

    8 -0.175312 -0.047852 1.020000 1.662875

    9 -0.130313 0.000000 1.027778 0.484511

    10 0.351680 -0.085414 1.020000 2.204400

    11 -2.590918 -0.530742 1.020000 -0.303904

    12 0.213867 2.014238 1.020000 0.300300

    13 0.246875 0.387158 1.010000 0.164960

    14 -0.359365 0.000000 1.004618 -0.399732

    15 -1.146094 1.111250 1.010000 -0.202966

    16 -1.518750 2.763984 1.030000 -0.270507

    Power flow results

    -----------------------------------------------

    Line no. Ppq(MW) Pqp(MW)

    -----------------------------------------------

    L1 142.738696 -140.775589

    L2 -278.250000 279.919288

    L3 -428.907134 430.164406

    L4 421.934534 -420.854679

    L5 -1.548066 1.620513L6 20.116044 -19.849499

    L7 31.626554 -31.523100

    L8 -34.942917 35.121282

    L9 281.337198 -280.207456

    L10 17.499373 -17.343396

    L11 -35.030623 35.167969

    L12 -16.019793 16.409369

    L13 22.838045 -22.710034

    L14 -235.993826 236.436445

    L15 2.125563 -2.098666

    L16 0.425020 -0.416676

    L17 -58.642028 59.036562

    L18 3.022868 -2.938628L19 -7.183938 7.213359

    L20 13.575977 -13.345797

    L21 -20.483598 20.548344

    L22 -116.356567 116.586454

    L23 -15.064500 15.263302

    L24 6.420731 -6.209307

    L25 -2.455677 2.604874

    L26 12.244453 -12.174439

    58

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    59/67

    ASCET

    the active power of slack bus is 0.148493

    the reactive power of slack bus is -1.005658

    Participants benefits and spot prices

    ------------------------------------------------------

    Node Spot price Total benefit Participan benefit line benefit

    ------------------------------------------------------1 1.140000 -657.216250 14.600000 -671.816250

    2 1.200000 790.500000 456.600000 333.900000

    3 1.100000 23.869922 16.200000 7.669922

    4 1.200000 118.095312 13.400000 104.695312

    5 1.100000 -28.271777 8.300000 -36.571777

    6 1.200000 -18.312500 10.600000 -28.912500

    7 1.100000 5.032227 260.750000 -255.717773

    8 1.200000 37.937500 16.900000 21.037500

    9 1.200000 18.337500 2.700000 15.637500

    10 1.200000 -24.401563 17.800000 -42.201563

    11 1.200000 363.110156 52.200000 310.910156

    12 1.200000 6.135937 31.800000 -25.664063

    13 1.200000 10.875000 40.500000 -29.62500014 1.200000 47.823828 4.700000 43.123828

    15 1.200000 252.131250 114.600000 137.531250

    16 1.200000 348.150000 157.900000 182.250000

    17 1.200000 22.480808 40.300000 -17.819192

    ------------------------------------------------------

    1278.003 1259.850000 48.427351

    THE EXECUTION TIME IN SEC=9.734134

    benefit =1.2717e+003

    benefit =1.2304e+003

    benefit = 976.2094

    benefit =1.0612e+003

    benefit = 1.2461e+003

    benefit = 1.2718e+003

    benefit = 1.2403e+003

    benefit = 1.2234e+003

    benefit = 1.2564e+003

    benefit = 1.1792e+003

    benefit = 1.1752e+003

    benefit = 1.2414e+003

    benefit = 1.2785e+003

    benefit = 1.1287e+003

    59

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    60/67

    ASCET

    benefit = 1.2381e+003

    benefit = 1.0501e+003

    benefit = 1.2595e+003

    benefit = 1.2654e+003

    benefit = 1.0235e+003

    benefit = 1.2377e+003

    benefit = 1.2573e+003

    benefit = 1.2306e+003

    benefit = 1.1140e+003

    benefit = 1.1241e+003

    benefit = 1.1508e+003

    benefit = 1.2557e+003

    benefit = 1.1563e+003

    benefit = 1.2443e+003

    benefit = 1.2784e+003

    benefit = 1.2332e+003

    benefit = 1.2355e+003

    benefit = 1.1013e+003

    benefit = 1.1821e+003

    benefit = 1.1010e+003

    benefit = 1.1176e+003

    benefit = 1.2389e+003

    benefit = 1.1565e+003

    benefit = 1.0173e+003

    benefit = 1.0964e+003

    benefit = 1.2785e+003

    benefit = 1.2784e+003

    benefit = 1.2718e+003

    benefit = 1.2717e+003

    benefit = 1.2414e+003

    benefit = 932.5910

    60

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    61/67

    ASCET

    benefit =976.2076

    benefit = 1.2785e+003

    benefit = 1.1563e+003

    benefit = 1.2595e+003

    benefit = 1.1792e+003

    benefit = 1.2377e+003

    benefit = 1.2403e+003

    benefit = 1.2573e+003

    benefit = 1.2785e+003

    benefit = 1.1010e+003

    benefit = 932.5909

    benefit = 1.1176e+003

    benefit = 1.1563e+003

    benefit = 1.2654e+003

    benefit = 1.2785e+003

    benefit = 1.2381e+003

    benefit = 1.1010e+003

    benefit = 1.2557e+003

    benefit = 1.2332e+003

    benefit = 1.2414e+003

    benefit = 1.0612e+003

    benefit = 1.2654e+003

    benefit = 1.1792e+003

    benefit = 1.0173e+003

    benefit = 1.1140e+003

    benefit = 1.0964e+003

    benefit = 1.0964e+003

    benefit = 1.1508e+003

    benefit = 1.1324e+003

    benefit = 956.3551

    benefit = 1.2654e+003

    61

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    62/67

    ASCET

    benefit = 1.2785e+003

    benefit = 1.2304e+003

    benefit = 1.2403e+003

    benefit = 1.2785e+003

    benefit = 1.2785e+003

    benefit = 1.2785e+003

    benefit = 1.2785e+003

    benefit = 1.2332e+003

    benefit = 1.2573e+003

    benefit = 1.1140e+003

    benefit = 1.2654e+003

    benefit = 1.2654e+003

    benefit = 1.2377e+003

    benefit =1.2403e+003

    benefit = 1.1792e+003

    benefit = 1.2403e+003

    benefit = 1.1563e+003

    benefit = 1.2717e+003

    benefit = 1.0964e+003

    benefit = 1.0173e+003

    benefit = 1.2654e+003

    benefit = 1.2785e+003

    benefit = 1.2332e+003

    benefit = 1.1792e+003

    benefit = 976.2074

    benefit = 1.1253e+003

    benefit = 1.2515e+003

    benefit = 1.2414e+003

    benefit = 1.1140e+003

    benefit = 1.1324e+003

    benefit = 1.1563e+003

    62

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    63/67

    ASCET

    benefit = 1.2381e+003

    benefit = 932.5911

    benefit = 1.2381e+003

    benefit = 1.0173e+003

    benefit =1.2717e+003

    benefit = 1.2654e+003

    benefit = 1.2595e+003

    benefit = 1.1563e+003

    benefit = 1.0964e+003

    benefit = 1.1508e+003

    benefit = 1.2414e+003

    benefit = 1.2573e+003

    benefit = 1.2785e+003

    benefit = 1.2785e+003

    benefit = 1.2785e+003

    benefit = 1.2785e+003

    benefit = 1.1792e+003

    benefit = 1.1253e+003

    benefit = 932.5909

    benefit = 1.1324e+003

    benefit = 1.2381e+003

    benefit = 1.2785e+003

    benefit = 1.2403e+003

    benefit = 1.2785e+003

    benefit = 1.2785e+003

    benefit = 1.2785e+003

    benefit = 1.2785e+003

    benefit = 1.2785e+003

    benefit = 1.2785e+003

    benefit = 1.2785e+003

    benefit = 1.2785e+003

    63

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    64/67

    ASCET

    benefit = 1.2785e+003

    t = 9.0496

    error vs generation

    0 5 10 15 20 250

    50

    100

    150

    200

    250

    300

    350

    64

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    65/67

    ASCET

    Chapter 8. Conclusion& Future Scope

    In this thesis the genetic algorithm approach for solving the optimal power dispatch in a

    multi-node electricity market has been proposed. The objective of the algorithm is to

    maximise the total participants benefit at all nodes in the system, which in turn depends

    on the real power injection to the system.

    The algorithm has been implemented by using the real power and reactive power

    injection at all nodes as a candidate (chromosome). The total participants benefit is given

    as a chromosomes fitness and it hasbeen determined by solving the load flow problem.

    The genetic algorithm has been implemented with various control parameters and tested

    on a 17-node, 26-line system. The results have shown that the proposed algorithm

    provides a good solution

    In future days micro genetic algorithm is developed ,which will become even more

    efficient when specialists knowledge (Eg. Fuzzy Logic) about the problem is included.

    In this way, it is possible to reduce search space and, consequently, decrease the

    execution time, increasing the chances to reach global optimal solution.

    65

  • 7/29/2019 DocumeOPTIMAL POWER DISPATCH IN MULTI NODE ELECTRICITY MARKET USING GENETIC ALGORITHM

    66/67

    ASCET

    Bibliography

    [1] D.L. Post, S.S. Coppinger, G.B. Sheble, Application of auctions

    as a pricing mechanism for the interchange of electric power, IEEE

    Trans. Power Syst. 10 (1995) 15801584.

    [2] U.D. Annakkage, R.A.S.K. Ranatunga, Optimal power dispatch

    of multi-node electricity markets, in: VI SEPOPE, Salvador,

    Brazil, 1998.

    [3] R.W. Ferrero, S.M. Shahidehpour, Optimality conditions in

    power transactions in deregulated power pools, Elect. Power Syst.

    Res. 42 (1997) 209214.

    [4] N. Pamudji, R.J. Kaye, H.R. Outhred, Network effects in a

    competitive electricity industry: No linear and linear nodal auction

    models, in: Stockholm Power Tech Conference, 1995.

    [5] H.R. Outhred, R.J. Kaye, Incorporating network effects in a

    competitive electricity industry: an Australian perspective, Electricity

    Transmission Pricing and Technology, Kluwer, Dordrecht,

    1996.

    [6] M. Mitchell, An Introduction to Genetic Algorithms, MIT Press,

    Cambridge, MA, 1996.

    [7] D.E. Goldberg, Genetic Algorithms in Search, Optimisation and

    Machine Learning, Addison-Wesley, Reading, MA, 1989.

    [8] T.T. Maifeld, G.B. Sheble, Genetic-based unit commitment

    algorithm,

    IEEE Trans. Power Syst. 11 (1996) 13591370.

    [9] S.O. Orero, M.R. Irving, Economic dispatch of generators withprohibited operating zones:: A genetic algorithm approach, IEE

    Proc. Gener. Trans. Distrib. 143 (1996)