Anda di halaman 1dari 60

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID

POWER SYSTEM

CHAPTER 1

1.1 INTRODUCTION
Nowadays, electricity generation is very important because of its increasing
necessity and enhanced environmental awareness such as reducing pollutant emissions.
The dynamic behavior of the system depends on disturbances and on changes in the
operating point. The quality of generated electricity in power system is dependent on the
system output, which has to be of constant frequency and must maintain the scheduled
power and voltage. Therefore, load frequency control, LFC, is very important in order to
supply reliable electric power with good quality for power systems. The wind- micro
hydro diesel system is one of the hybrid systems utilizing more than one energy source.
For the increasing demand of electricity due to developments at a faster rate, it is
becoming difficult to meet the increasing demand of electricity only with conventional
sources.
In most remote and isolated areas, electric power is often supplied to the
local community by diesel generators. However, diesel generators cause significant
impacts on the environment. [2]. Due to the environmental and economic impacts of a
diesel generator, interest in alternative cost-efficient and pollution free energy generation
has grown enormously. Currently, wind is the fastest growing and most widely utilized
renewable energy technology in power systems. Wind power is economically attractive
when the wind speed of the proposed site is considerable for electrical generation and
electric energy is not easily available from the grid [1]. Wind power is intermittent due to
worst case weather conditions, so wind power generation is variable and unpredictable.
Wind power is not fully controllable and their availability depends on daily and seasonal
patterns [3]. As a result, conventional energy sources such as diesel generators are used in
conjunction with renewable energy for reliable operation. The hybrid wind power with
diesel generation has been suggested by [2] and [3] to handle the problem above. To meet
the increasing load demand for an isolated community, expansion of these hybrid power
systems is required. One possible option available is to add a micro hydro generating unit
in parallel, where water streams are abundantly available.
Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

The resulting wind-micro hydro-diesel hybrid power system must provide


good quality service to the consumer load, which depends mostly on the type and action
of the generation controller. The unsteady nature of wind and frequent change in load
demands may cause large and severe oscillation of power. The fluctuation of output
power of such renewable sources may cause a serious problem of frequency and voltage
fluctuation of the grid [2]. An effective controller for stabilizing frequency oscillations
and maintaining the system frequency within acceptable range is significantly required.
Therefore, a control system is required to detect the load changes and its mechanical
power production and stabilize the system frequency [4].
The supplementary controller of the diesel generating unit, called the Load
Frequency Controller, may satisfy these requirements. The load frequency control (LFC)
maintains the frequency deviation from its nominal value to within specified bounds and
dynamic performance of the system [7],[8],[9] . The function of the load frequency
controller is to eliminate a mismatch created either by the small real power load change or
due to a change in input wind power. The Load Frequency control (LFC) or Automatic
Generation Control (AGC) has been one of the most important subjects concerning power
system engineers in the last decades. Research studies were conducted for Load
Frequency control of Thermal and Hydro power system with conventional and intelligent
controllers [6],[11]-[14]. Load Frequency controller was designed with conventional PI
controller for wind- diesel hybrid system [5] and for wind-diesel- hydro hybrid power
system [1 6].[17]. LFC using Fuzzy logic controller with optimization techniques for
wind diesel hybrid system was presented in [1 5].
LFC using ANFIS based controllers for thermal and Hydro thermal
systems are presented in [20] and [21] respectively. In the proposed paper, adaptive
Neuro-Fuzzy Inference System based Neuro-Fuzzy controller is designed for Load
Frequency Control of wind micro hydro-diesel hybrid power system. The ANFIS based
Neuro-Fuzzy controller for a governor in diesel side and for a blade pitch control in wind
side are designed individually for performance improvement of the Wind-micro hydrodiesel hybrid system.

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

Simulations are performed for load frequency control in an isolated


wind micro hydro- diesel hybrid power system with different load disturbances by the
proposed ANFIS based Neuro-Fuzzy controller and also with conventional PI and fuzzy
logic controller for comparison. The proposed adative Neuro Fuzzy Inference System
trains the parameters of the Fuzzy logic controller and improves the system performance.
Simulation results show the superior performance of the proposed Neuro- fuzzy controller
in comparison with the conventional PI controller and fuzzy logic controller in terms of
the settling time, overshoot against various load changes.

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

CHAPTER 2
2.1 INTRODUCTION TO FUZZY LOGIC:
In recent years, the number and variety of applications of fuzzy logic have
increased significantly. The applications range from consumer products such as cameras,
camcorders, washing machines, and microwave ovens to industrial process control,
medical instrumentation, decision-support systems, and portfolio selection.
To understand why use of fuzzy logic has grown, you must first understand what
is meant by fuzzy logic.
Fuzzy logic has two different meanings. In a narrow sense, fuzzy logic is a logical
system, which is an extension of multivalve logic. However, in a wider sense fuzzy logic
(FL) is almost synonymous with the theory of fuzzy sets, a theory which relates to classes
of objects with unsharp boundaries in which membership is a matter of degree. In this
perspective, fuzzy logic in its narrow sense is a branch of fl. Even in its more narrow
definition, fuzzy logic differs both in concept and substance from traditional multivalve
logical systems.
In fuzzy Logic Toolbox software, fuzzy logic should be interpreted as FL, that is,
fuzzy logic in its wide sense. The basic ideas underlying FL are explained very clearly
and insightfully in Foundations of Fuzzy Logic. What might be added is that the basic
concept underlying FL is that of a linguistic variable, that is, a variable whose values are
words rather than numbers. In effect, much of FL may be viewed as a methodology for
computing with words rather than numbers. Although words are inherently less precise
than numbers, their use is closer to human intuition. Furthermore, computing with words
exploits the tolerance for imprecision and thereby lowers the cost of solution.
Another basic concept in FL, which plays a central role in most of its
applications, is that of a fuzzy if-then rule or, simply, fuzzy rule. Although rule-based
systems have a long history of use in Artificial Intelligence (AI), what is missing in such
systems is a mechanism for dealing with fuzzy consequents and fuzzy antecedents. In
fuzzy logic, this mechanism is provided by the calculus of fuzzy rules. The calculus of
fuzzy rules serves as a basis for what might be called the Fuzzy Dependency and
Command Language (FDCL). Although FDCL is not used explicitly in the toolbox, it is
Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

effectively one of its principal constituents. In most of the applications of fuzzy logic, a
fuzzy logic solution is, in reality, a translation of a human solution into FDCL.
A trend that is growing in visibility relates to the use of fuzzy logic in
combination with neuro computing and genetic algorithms. More generally, fuzzy logic,
neuro computing, and genetic algorithms may be viewed as the principal constituents of
what might be called soft computing. Unlike the traditional, hard computing, soft
computing accommodates the imprecision of the real world.
The guiding principle of soft computing is: Exploit the tolerance for imprecision,
uncertainty, and partial truth to achieve tractability, robustness, and low solution cost. In
the future, soft computing could play an increasingly important role in the conception and
design of systems whos MIQ (Machine IQ) is much higher than that of systems designed
by conventional methods.
Among various combinations of methodologies in soft computing, the one that
has highest visibility at this juncture is that of fuzzy logic and neuro computing, leading
to neuro-fuzzy systems. Within fuzzy logic, such systems play a particularly important
role in the induction of rules from observations. An effective method developed by Dr.
Roger Jang for this purpose is called ANFIS (Adaptive Neuro-Fuzzy Inference System).
This method is an important component of the toolbox.
The fuzzy logic toolbox is highly impressive in all respects. It makes fuzzy logic
an effective tool for the conception and design of intelligent systems. The fuzzy logic
toolbox is easy to master and convenient to use. And last, but not least important, it
provides a reader friendly and up-to-date introduction to methodology of fuzzy logic and
its wide ranging applications.

2.2 What is fuzzy logic:


Fuzzy logic is all about the relative importance of precision: How important is it
to be exactly right when a rough answer will do?
You can use Fuzzy Logic Toolbox software with MATLAB technical computing
software as a tool for solving problems with fuzzy logic. Fuzzy logic is a fascinating area
of research because it does a good job of trading off between significance and precision
something that humans have been managing for a very long time.
Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

In this sense, fuzzy logic is both old and new because, although the modern and
methodical science of fuzzy logic is still young, the concept of fuzzy logic relies on ageold skills of human reasoning.

fig 5.1 fuzzy description

2.3 Why use fuzzy logic:


Fuzzy logic is a convenient way to map an input space to an output space. Mapping
input to output is the starting point for everything. Consider the following examples:
With information about how good your service was at a restaurant, a fuzzy logic
system can tell you what the tip should be.
With your specification of how hot you want the water, a fuzzy logic system can
adjust the faucet valve to the right setting.

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

With information about how far away the subject of your photograph is, a fuzzy
logic system can focus the lens for you.
With information about how fast the car is going and how hard the motor is
working, a fuzzy logic system can shift gears for you.
To determine the appropriate amount of tip requires mapping inputs to the
appropriate outputs. Between the input and the output, the preceding figure shows a black
box that can contain any number of things: fuzzy systems, linear systems, expert systems,
neural networks, differential equations, interpolated multidimensional lookup tables, or
even a spiritual advisor, just to name a few of the possible options. Clearly the list could
go on and on.
Of the dozens of ways to make the black box work, it turns out that fuzzy is often
the very best way. Why should that be? As Lotfi Zadeh, who is considered to be the father
of fuzzy logic, once remarked: "In almost every case you can build the same product
without fuzzy logic, but fuzzy is faster and cheaper.".

2.4 When not to use fuzzy logic:


Fuzzy logic is not a cure-all. When should you not use fuzzy logic? The safest
statement is the first one made in this introduction: fuzzy logic is a convenient way to
map an input space to an output space. If you find it's not convenient, try something else.
If a simpler solution already exists, use it. Fuzzy logic is the codification of common
sense use common sense when you implement it and you will probably make the right
decision. Many controllers, for example, do a fine job without using fuzzy logic.
However, if you take the time to become familiar with fuzzy logic, you'll see it can be a
very powerful tool for dealing quickly and efficiently with imprecision and nonlinearity.

2.5 What can fuzzy logic toolbox software do:


You can create and edit fuzzy inference systems with Fuzzy Logic Toolbox
software. You can create these systems using graphical tools or command-line functions,
or you can generate them automatically using either clustering or adaptive neuro-fuzzy
techniques.
Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

If you have access to Simulink software, you can easily test your fuzzy system in
a block diagram simulation environment.
The toolbox also lets you run your own stand-alone C programs directly. This is made
possible by a stand-alone Fuzzy Inference Engine that reads the fuzzy systems saved from
a mat lab session. You can customize the stand-alone engine to build fuzzy inference into
your own code. All provided code is ansi compliant.
Because of the integrated nature of the mat lab environment, you can create your own
tools to customize the toolbox or harness it with another toolbox, such as the Control
System Toolbox, Neural Network Toolbox, or Optimization Toolbox software.

2.6 Fuzzy logic tool box:


The Fuzzy Logic Toolbox extends the MATLAB technical computing
environment with tools for designing systems based on fuzzy logic. Graphical user
interfaces (GUIs) guide you through the steps of fuzzy inference system design.
Functions are provided for many common fuzzy logic methods, including fuzzy
clustering and adaptive neuro fuzzy learning.
The toolbox lets you model complex system behaviors using simple logic rules and then
implements these rules in a fuzzy inference system. You can use the toolbox as a
standalone fuzzy inference engine. Alternatively, you can use fuzzy inference blocks in
simulink and simulate the fuzzy systems within a comprehensive model of the entire
dynamic system

2.6.1 Working with the fuzzy logic toolbox:


The Fuzzy Logic Toolbox provides GUIs to let you perform classical fuzzy
system development and pattern recognition. Using the toolbox, you can develop and
analyze fuzzy inference systems, develop adaptive neuro fuzzy inference systems, and
perform fuzzy clustering. In addition, the toolbox provides a fuzzy controller block that
you can use in Simulink to model and simulate a fuzzy logic control system. From
Simulink, you can generate C code for use in embedded applications that include fuzzy
logic.

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

2.6.2 Building a fuzzy inference system:


Fuzzy inference is a method that interprets the values in the input vector and, based on
user defined rules, assigns values to the output vector. Using the GUI editors and viewers
in the Fuzzy Logic Toolbox, you can build the rules set, define the membership functions,
and analyze the behavior of a fuzzy inference system (FIS). The following editors and
viewers are provided.

fig 2.2 fuzzy interference system

2.7 Key features:


Specialized GUIs for building fuzzy inference systems and viewing and analyzing
results
Membership functions for creating fuzzy inference systems
Support for AND, OR, and NOT logic in user-defined rules
Standard Mamdani and Sugeno-type fuzzy inference systems

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

Automated membership function shaping through neuroadaptive and fuzzy clustering


learning techniques
Ability to embed a fuzzy inference system in a Simulink model
Ability to generate embeddable C code or stand-alone executable fuzzy inference
engines.

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

CHAPTER 3
3.1primary Gui Tools Of The Fuzzy Logic Toolbox:
In this section we'll be building a simple tipping example using the graphical
user interface (GUI) tools provided by the Fuzzy Logic Toolbox. Although it's possible to
use the Fuzzy Logic Toolbox by working strictly from the command line, in general it's
much easier to build a system graphically. There are five primary GUI tools for building,
editing, and observing fuzzy inference systems in the Fuzzy Logic Toolbox. The Fuzzy
Inference System or FIS Editor, the Membership Function Editor, the Rule Editor, the
Rule Viewer, and the Surface Viewer. These GUIs are dynamically linked, in that changes
you make to the FIS using one of them, can affect what you see on any of the other open
GUIs. You can have any or all of them open for any given system. These are shown in
Fig.1

Fig. 3.1 Primary GUI Tools of the Fuzzy Logic Toolbox


The FIS Editor handles the high level issues for the system: How many input and output
variables? What are their names? The Fuzzy Logic Toolbox doesn't limit the number of
inputs. However, the number of inputs may be limited by the available memory of your
Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

machine. If the number of inputs is too large, or the number of membership functions is
too big, then it may also be difficult to analyze the FIS using the other GUI tools.
The Membership Function Editor is used to define the shapes of all the
membership functions associated with each variable. The Rule Editor is for editing the list
of rules that defines the behavior of the system.
The Rule Viewer and the Surface Viewer are used for looking at, as opposed to
editing, the FIS. They are strictly read-only tools. The Rule Viewer is a matlab-based
display of the fuzzy inference diagram shown at the end of the last section. Used as a
diagnostic, it can show (for example) which rules are active, or how individual
membership function shapes are influencing the results. The Surface Viewer is used to
display the dependency of one of the outputs on any one or two of the inputs that is, it
generates and plots an output surface map for the system.
The five primary GUIs can all interact and exchange information. Any one of
them can read and write both to the workspace and to the disk (the read-only viewers can
still exchange plots with the workspace and/or the disk). For any fuzzy inference system,
any or all of these five GUIs may be open. If more than one of these editors is open for a
single system, the various GUI windows are aware of the existence of the others, and will,
if necessary, update related windows. Thus if the names of the membership functions are
changed using the Membership Function Editor, those changes are reflected in the rules
shown in the Rule Editor. The editors for any number of different FIS systems may be
open simultaneously. The FIS Editor, the Membership Function Editor, and the Rule
Editor can all read and modify the FIS data, but the Rule Viewer and the Surface Viewer
do not modify the FIS data in any way.
We'll start with a basic description of a two-input, one-output tipping problem.
The Basic Tipping Problem. Given a number between 0 and 10 that represents the quality
of service at a restaurant (where 10 is excellent), and another number between 0 and 10
that represents the quality of the food at that restaurant (again, 10 is excellent), what
should the tip be?

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

3.2 Tripping Function:


The starting point is to write down the three golden rules of tipping, based on years of
personal experience in restaurants.

1. If the service is poor or the food is rancid, then tip is cheap.


2. If the service is good, then tip is average.
3. If the service is excellent or the food is delicious, then tip is generous.

We'll assume that an average tip is 15%, a generous tip is 25%, and a cheap tip is
5%. It's also useful to have a vague idea of what the tipping function should look like. A
simple tipping function is shown as in Fig.2. Obviously the numbers and the shape of the
curve are subject to local traditions, cultural bias, and so on, but the three rules are pretty
universal. Now we know the rules, and we have an idea of what the output should look
like. Let's begin working with the GUI tools to construct a fuzzy inference system for this
decision process.

Fig 3.2 the tipping Function

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

The following discussion walks you through building a new fuzzy inference
system from scratch. If you want to save time and follow along quickly, you can load the
already built system by typing fuzzy tipper This will load the FIS associated with the file
tipper.fis (the .fis is implied) and launch the FIS Editor. However, if you load the pre-built
system, you will not be building rules and constructing membership functions.
The FIS Editor displays general information about a fuzzy inference system.
There's a simple diagram as shown in Fig.3 that shows the names of each input variable
on the left, and those of each output variable on the right. The sample membership
functions shown in the boxes are just icons and do not depict the actual shapes of the
membership functions.
Below the diagram is the name of the system and the type of inference used. The
default, Madman-type inference, is what we'll continue to use for this example. Another
slightly different type of inference, called Surgeon-type inference, is also available.
Below the name of the fuzzy inference system, on the left side of the figure, are
the pop-up menus that allow you to modify the various pieces of the inference process.
On the right side at the bottom of the figure is the area that displays the name of an input
or output variable, its associated membership function type, and its range. The latter two
fields are specified only after the membership functions have been. Below that region are
the Help and Close buttons that call up online help and close the window, respectively. At
the bottom is a status line that relays information about the system.
To start this system from scratch, type fuzzy at the mat lab prompt. The
generic untitled FIS Editor opens, with one input, labeled input1, and one output, labeled
output1. For this example, we will construct a two-input, one output system, so go to the
Edit menu and select Add input. A second yellow box labeled input2 will appear. The two
inputs we will have in our example are service and food. Our one output is tip.

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

Fig 3.3 FIS Editor


We'd like to change the variable names to reflect that, though:

Click once on the left-hand (yellow) box marked input1 (the box will be
highlighted in red).

In the white edit field on the right, change input1 to service and press Return.

Click once on the left-hand (yellow) box marked input2 (the box will be
highlighted in red).

In the white edit field on the right, change input2 to food and press Return.

Click once on the right-hand (blue) box marked output1.

In the white edit field on the right, change output1 to tip.

From the File menu select Save to workspace as.. and a window appears as
shown in fig.4.

Enter the variable name tipper and click on ok.

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

You will see the diagram updated to reflect the new names of the input and output
variables. There is now a new variable in the workspace called tipper that contains all the
information about this system.

Fig. 3.4 Save to workspace as... Window


By saving to the workspace with a new name, you also rename the entire system. Your
window will look like as shown in Fig.5.

Fig 3.5 the updated FIS Editor

Leave the inference options in the lower left in their default positions for now. You've
entered all the information you need for this particular GUI. Next define the membership
Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

functions associated with each of the variables. To do this, open the Membership Function
Editor. You can open the Membership Function Editor in one of three ways:

Pull down the View menu item and select Edit Membership Functions....

Double-click on the icon for the output variable, tip.

Type mfedit at the command line.

The membership function editor:


The Membership Function Editor shares some features with the FIS Editor. In fact, all
of the five basic GUI tools have similar menu options, status lines, and Help and Close
buttons. The Membership Function Editor is the tool that lets you display and edit all of
the membership functions associated with all of the input and output variables for the
entire fuzzy inference system. Fig.6 shows the Membership Function Editor.
When you open the Membership Function Editor to work on a fuzzy inference system
that does not already exist in the workspace, there is not yet any membership functions
associated with the variables that you have just defined with the FIS Editor

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

Fig. 3.6 The Membership Function Editor


On the upper left side of the graph area in the Membership Function Editor is a "Variable
Palette" that lets you set the membership functions for a given variable. To set up your
membership functions associated with an input or an output variable for the FIS, select an
FIS variable in this region by clicking on it.
Next select the Edit pull-down menu, and choose Add MFs.... A new window will appear,
which allows you to select both the membership function type and the number of
membership functions associated with the selected variable. In the lower right corner of
the window are the controls that let you change the name, type, and parameters (shape),
of the membership function, once it has been selected.
The membership functions from the current variable are displayed in the main graph.
These membership functions can be manipulated in two ways. You can first use the
mouse to select a particular membership function associated with a given variable quality,
(such as poor, for the variable, service), and then drag the membership function from side
to side. This will affect the mathematical description of the quality associated with that
membership function for a given variable. The selected membership function can also be
tagged for dilation or contraction by clicking on the small square drag points on the
Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

membership function, and then dragging the function with the mouse toward the outside,
for dilation, or toward the inside, for contraction. This will change the parameters
associated with that membership function.
Below the Variable Palette is some information about the type and name of the current
variable. There is a text field in this region that lets you change the limits of the current
variable's range (universe of discourse) and another that lets you set the limits of the
current plot (which has no real effect on the system).
The process of specifying the input membership functions for this two input tipper
problem is as follows:

Select the input variable, service, by double-clicking on it. Set both the Range
and the Display Range to the vector [0 10].

Select Add MFs... from the Edit menu. A window pops open as shown in Fig.7.

Fig 6.7. Add MFs Window

Use the pull-down tab to choose gaussmf for MF Type and 3 for Number of
MFs. This adds three Gaussian curves to the input variable service.

Click once on the curve with the leftmost hump. Change the name of the curve
to poor. To adjust the shape of the membership function, either use the mouse, as
described above, or type in a desired parameter change, and then click on the
membership function. The default parameter listing for this curve is [1.5 0].

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

Name the curve with the middle hump, good, and the curve with the rightmost
hump, excellent. Reset the associated parameters if desired.

Select the input variable, food, by clicking on it. Set both the Range and the
Display Range to the vector [0 10].

Select Add MFs... from the Edit menu and add two trapmf curves to the input
variable food.

Click once directly on the curve with the leftmost trapezoid. Change the name of
the curve to rancid. To adjust the shape of the membership function, either use
the mouse, as described above, or type in a desired parameter change, and then
click on the membership function. The default parameter listing for this curve is
[0 0 1 3].

Name the curve with the rightmost trapezoid, delicious, and reset the associated
parameters if desired.

Next you need to create the membership functions for the output variable, tip. To create
the output variable membership functions, use the Variable Palette on the left, selecting
the output variable, tip. The inputs ranged from 0 to 10, but the output scale is going to be
a tip between 5 and 25 percent.
Use triangular membership function types for the output. First, set the Range (and the
Display Range) to [0 30], to cover the output range. Initially, the cheap membership
function will have the parameters [0 5 10], the average membership function will be [10
15 20],and the generous membership function will be [20 25 30].Your system should look
something like shown in Fig.8.

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

fig. 3.8 The updated Membership Function Editor


Now that the variables have been named, and the membership functions have appropriate
shapes and names, you're ready to write down the rules. To call up the Rule Editor, go to
the View menu and select Edit rules..., or type rule edit at the command line. The Rule
Editor Window pops open as shown in Fig 6.9
3.4 The rule editor:
Constructing rules using the graphical Rule Editor interface is fairly self-evident.
Based on the descriptions of the input and output variables defined with the FIS Editor,
the Rule Editor allows you to construct the rule statements automatically, by clicking on
and selecting one item in each input variable box, one item in each output box, and one
connection item. Choosing none as one of the variable qualities will exclude that variable

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

from a given rule. Choosing not under any variable name will negate the associated
quality. Rules may be changed, deleted, or added, by clicking on the appropriate button.
The Rule Editor also has some familiar landmarks, similar to those in the FIS
Editor and the Membership Function Editor, including the menu bar and the status line.
The Format pop-up menu is available from the Options pull-down menu from the top
menu bar -- this is used to set the format for the display. Similarly, Language can be set
from under Options as well. The Help button will bring up a MATLAB Help window.

Fig 3.9. The Rule Editor

To insert the first rule in the Rule Editor, select the following:
Poor under the variable service

Rancid under the variable food

The radio button, or, in the Connection block

Cheap, under the output variable, tip.

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

The resulting rule is


1. If (service is poor) or (food is rancid) then (tip is cheap) (1)
The numbers in the parentheses represent weights that can be applied to each rule if
desired. You can specify the weights by typing in a desired number between zero and one
under the Weight setting. If you do not specify them, the weights are assumed to be unity
(1).
Follow a similar procedure to insert the second and third rules in the Rule Editor to get
1. If (service is poor) or (food is rancid) then (tip is cheap) (1)
2. If (service is good) then (tip is average) (1)
3. If (service is excellent) or (food is delicious) then (tip is generous) (1)
To change a rule, first click on the rule to be changed. Next make the desired changes to
that rule, and then click on Change rule. For example, to change the first rule to
1. If (service not poor) or (food not rancid) then (tip is not cheap) (1)
click not under each variable, and then click Change rule.
The Format pop-up menu from the Options menu indicates that you're looking
at the verbose form of the rules. Try changing it to symbolic. You will see
1. (service==poor) => (tip=cheap) (1)
2. (service==good) => (tip=average) (1)

3. (service==excellent) => (tip=generous) (1)


There is not much difference in the display really, but it's slightly more language
neutral, since it doesn't depend on terms like "if" and "then." If you change the format to
indexed, you'll see an extremely compressed version of the rules that has squeezed all the
language out.
1, 1 (1): 1
Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

2, 2 (1): 1
3, 3 (1): 1
This is the version that the machine deals with. The first column in this structure
corresponds to the input variable, the second column corresponds to the output variable,
the third column displays the weight applied to each rule, and the fourth column is
shorthand that indicates whether this is an OR (2) rule or an AND (1) rule. The numbers
in the first two columns refer to the index number of the membership function. A literal
interpretation of rule 1 is: "if input 1 is MF1 (the first membership function associated
with input 1) then output 1 should be MF1 (the first membership function associated with
output 1) with the weight 1." Since there is only one input for this system, the AND
connective implied by the 1 in the last column is of no consequence.
The symbolic format doesn't bother with the terms, if, then, and so on. The
indexed format doesn't even bother with the names of your variables. Obviously the
functionality of your system doesn't depend on how well you have named your variables
and membership functions. The whole point of naming variables descriptively is, as
always, making the system easier for you to interpret. Thus, unless you have some special
purpose in mind, it will probably be easier for you to stick with the verbose format.
At this point, the fuzzy inference system has been completely defined, in that the
variables, membership functions, and the rules necessary to calculate tips are in place. It
would be nice, at this point, to look at a fuzzy inference diagram like the one presented at
the end of the previous section and verify that everything is behaving the way we think it
should. This is exactly the purpose of the Rule Viewer, the next of the GUI tools we'll
look at. From the View menu, select View rules....

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

3.5 The rule viewer:

Fig 3.10. The Rule Viewer


The Rule Viewer displays a roadmap of the whole fuzzy inference process. It's
based on the fuzzy inference diagram described in the previous section. You see a single
figure window as shown in fig.10 with 10 small plots nested in it. The three small plots
across the top of the figure represent the antecedent and consequent of the first rule. Each
rule is a row of plots, and each column is a variable. The first two columns of plots (the
six yellow plots) show the membership functions referenced by the antecedent, or the ifpart of each rule. The third column of plots (the three blue plots) shows the membership
functions referenced by the consequent, or the then-part of each rule. If you click once on
a rule number, the corresponding rule will be displayed at the bottom of the figure. Notice
that under food, there is a plot which is blank. This corresponds to the characterization of
none for the variable food in the second rule. The fourth plot in the third column of plots

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

represents the aggregate weighted decision for the given inference system. This decision
will depend on the input values for the system.
There are also the now familiar items like the status line and the menu bar. In the
lower right there is a text field into which you can enter specific input values. For the
two-input system, you will enter an input vector, [9 8], for example, and then click on
input. You can also adjust these input values by clicking anywhere on any of the three
plots for each input. This will move the red index line horizontally, to the point where you
have clicked. You can also just click and drag this line in order to change the input values.
When you release the line, (or after manually specifying the input), a new calculation is
performed, and you can see the whole fuzzy inference process take place. Where the
index line representing service crosses the membership function line "service is poor" in
the upper left plot will determine the degree to which rule one is activated. A yellow patch
of color under the actual membership function curve is used to make the fuzzy
membership value visually apparent. Each of the characterizations of each of the
variables is specified with respect to the input index line in this manner. If we follow rule
1 across the top of the diagram, we can see the consequent "tip is cheap" has been
truncated to exactly the same degree as the (composite) antecedent--this is the implication
process in action. The aggregation occurs down the third column, and the resultant
aggregate plot is shown in the single plot to be found in the lower right corner of the plot
field. The de-fuzzy fied output value is shown by the thick line passing through the
aggregate fuzzy set.
The Rule Viewer allows you to interpret the entire fuzzy inference process at
once. The Rule Viewer also shows how the shape of certain membership functions
influences the overall result. Since it plots every part of every rule, it can become
unwieldy for particularly large systems, but, for a relatively small number of inputs and
outputs, it performs well (depending on how much screen space you devote to it) with up
to 30 rules and as many as 6 or 7 variables.
The Rule Viewer shows one calculation at a time and in great detail. In this sense,
it presents a sort of micro view of the fuzzy inference system. If you want to see the entire
output surface of your system, that is, the entire span of the output set based on the entire
span of the input set, you need to open up the Surface Viewer. This is the last of our five
Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

basic GUI tools in the Fuzzy Logic Toolbox, and you open it by selecting View surface...
from the View menu. The Surface Viewer window pops open as shown in fig.10

The surface viewer:


Upon opening the Surface Viewer, we are presented with a two-dimensional curve
that represents the mapping from service quality to tip amount. Since this is a one-input
one-output case, we can see the entire mapping in one plot. Two-input one-output systems
also work well, as they generate three-dimensional plots that mat lab can adeptly manage.
When we move beyond three dimensions overall, we start to encounter trouble displaying
the results. Accordingly, the Surface Viewer is equipped with pop-up menus that let you
select any two inputs and any one output for plotting. Just below the pop-up menus are
two text input fields that let you determine how many x-axis and y-axis grid lines you
want to include. This allows you to keep the calculation time reasonable for complex
problems. Pushing the Evaluate button initiates the calculation, and the plot comes up
soon after the calculation is complete. To change the x-axis or y-axis grid after the surface
is in view, simply change the appropriate text field, and click on either X-grids or Y-grids,
according to which text field you changed, to redraw the plot.
The Surface Viewer has a special capability that is very helpful in cases with two
(or more) inputs and one output: you can actually grab the axes and reposition them to get
a different three-dimensional view on the data. The Ref. Input field is used in situations
when there are more inputs required by the system than the surface is mapping. Suppose
you have a four-input one-output system and would like to see the output surface. The
Surface Viewer can generate a three-dimensional output surface where any two of the
inputs vary, but two of the inputs must be held constant since computer monitors cannot
display a five-dimensional shape. In such a case the input would be a four-dimensional
vector with Na Ns holding the place of the varying inputs while numerical values would
indicate those values that remain fixed. An Na N is the IEEE symbol for "not a number."

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

Fig 3.11 The Surface Viewer


This concludes the quick walk-through of each of the main GUI tools. Notice that for the
tipping problem, the output of the fuzzy system matches our original idea of the shape of
the fuzzy mapping from service to tip fairly well. In hindsight, you might say, "Why
bother? I could have just drawn a quick lookup table and been done an hour ago!"
However, if you are interested in solving an entire class of similar decision-making
problems, fuzzy logic may provide an appropriate tool for the solution, given its ease with
which a system can be quickly modified.

Importing and exporting from the Gui tools:


When you save a fuzzy system to disk, you're saving an ascii text FIS file
representation of that system with the file suffix .fis. This text file can be edited and
modified and is simple to understand. When you save your fuzzy system to the mat lab
workspace, you're creating a variable (whose name you choose) that will act as a mat lab
structure for the FIS system. FIS files and FIS structures represent the same system.

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

CHAPTER 4
4.1 PI controller
The general block diagram of the PI speed controller is shown in Figure 2 [14].

The output
Of the speed controller (torque command) at n-th instant is expressed as follows:
Te (n)=Te(n1)+Kp_re(n)+Kire(n) (10)
Where Te (n) is the torque output of the controller at the n-th instant, and Kp and Ki the
proportional and integral gain constants, respectively.
A limit of the torque command is imposed as

The gains of PI controller shown in (10) can be selected by many methods such as trial
and error method, ZieglerNichols method and evolutionary techniques-based searching.
The numerical values of these controller gains depend on the ratings of the motor.

4.2 Advantages and disadvantages

The integral term in a PI controller causes the steady-state error to reduce to zero,
which is not the case for proportional-only control in general.

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

The lack of derivative action may make the system more steady in the steady state
in the case of noisy data. This is because derivative action is more sensitive to
higher-frequency terms in the inputs.

Without derivative action, a PI-controlled system is less responsive to real (nonnoise) and relatively fast alterations in state and so the system will be slower to
reach setpoint and slower to respond to perturbations than a well-tuned PID
system may be.

4.3 Integral Action and PI Control

Like the P-Only controller, the Proportional-Integral (PI) algorithm computes and transmits

output (CO) signal every sample time, T, to the final control element (e.g., valve, variable sp

The computed CO from the PI algorithm is influenced by the controller tuning paramet

controller error, e(t).


PI controllers have two tuning parameters to adjust. While this makes them more challeng

than a P-Only controller, they are not as complex as the three parameter PID controller.
Integral action enables PI controllers to eliminate offset, a major weakness of a P-only cont

PI controllers provide a balance of complexity and capability that makes them by far the m

used algorithm in process control applications.


The PI Algorithm While different vendors cast what is essentially the same algorithm in diffe

here we explore what is variously described as the dependent, ideal, continuous, position form

Where:
CO = controller output signal (the wire out)
CObias = controller bias or null value; set by bump less transfer as explained below
e(t) = current controller error, defined as SP PV
SP = set point
Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

PV = measured process variable (the wire in)


Kc = controller gain, a tuning parameter
Ti = reset time, a tuning parameter
The first two terms to the right of the equal sign are identical to the P-Only controller
referenced at the top of this article.
The integral mode of the controller is the last term of the equation. Its function is to
integrate or continually sum the controller error, e(t), over time.
Some things we should know about the reset time tuning parameter, Ti:
It provides a separate weight to the integral term so the influence of integral action can
be independently adjusted.
It is in the denominator so smaller values provide a larger weight to (i.e. increase the
influence of) the integral term.

It has units of time so it is always positive.

4.4 Function of the Proportional Term


As with the P-Only controller, the proportional term of the PI controller, Kce(t),
adds or subtracts from CObias based on the size of controller error e(t) at each time t.
As e(t) grows or shrinks, the amount added to CO bias grows or shrinks immediately and
proportionately. The past history and current trajectory of the controller error have no
influence on the proportional term computation.
The plot below (click for a large view) illustrates this idea for a set point response. The
error used in the proportional calculation is shown on the plot:
At time t = 25 min, e(25) = 6056 = 4
At time t = 40 min, e(40) = 6062 = 2

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

Recalling that controller error e(t) = SP PV, rather than viewing PV and SP as separate
traces as we do above, we can compute and plot e(t) at each point in time t.
Below (click for a large view) is the identical data to that above only it is recast as a plot
of e(t) itself. Notice that in the plot above, PV = SP = 50 for the first 10 min, while in the
error plot below, e(t) = 0 for the same time period.

This plot is useful as it helps us visualize how controller error continually changes size
and sign as time passes.

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

4.5 Function of the Integral Term


While the proportional term considers the current size of e(t) only at the time of the
controller calculation, the integral term considers the history of the error, or how long and
how far the measured process variable has been from the set point over time.
Integration is a continual summing. Integration of error over time means that we sum up
the complete controller error history up to the present time, starting from when the
controller was first switched to automatic.
Controller error is e(t) = SP PV. In the plot below (click for a large view), the integral
sum of error is computed as the shaded areas between the SP and PV traces.

Each box in the plot has an integral sum of 20 (2 high by 10 wide). If we count the
number of boxes (including fractions of boxes) contained in the shaded areas, we can
compute the integral sum of error.
So when the PV first crosses the set point at around t = 32, the integral sum has grown to
about 135. We write the integral term of the PI controller as:

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

Since it is controller error that drives the calculation, we get a direct view the situation
from a controller error plot as shown below (click for a large view):

Note that the integral of each shaded portion has the same sign as the error. Since the
integral sum starts accumulating when the controller is first put in automatic, the total
integral sum grows as long as e(t) is positive and shrinks when it is negative.
At time t = 60 min on the plots, the integral sum is 135 34 = 101. The response is
largely settled out at t = 90 min, and the integral sum is then 135 34 + 7 = 108.

4.6 Integral Action Eliminates Offset


The previous sentence makes a subtle yet very important observation. The response is
largely complete at time t = 90 min, yet the integral sum of all error is not zero.
In this example, the integral sum has a final or residual value of 108. It is this residual
value that enables integral action of the PI controller to eliminate offset.
As discussed in a previous article, most processes under P-only control experience offset
during normal operation. Offset is a sustained value for controller error (i.e., PV does not
equal SP at steady state).
We recognize from the P-Only controller:

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

that CO will always equal CObias unless we add or subtract something from it.
The only way we have something to add or subtract from CO bias in the P-Only equation
above is if e(t) is not zero. It e(t) is not steady at zero, then PV does not equal SP and we
have offset.
However, with the PI controller:

we now know that the integral sum of error can have a final or residual value after a
response is complete. This is important because it means that e(t) can be zero, yet we can
still have something to add or subtract from CObias to form the final controller output, CO.
So as long as there is any error (as long as e(t) is not zero), the integral term will grow or
shrink in size to impact CO. The changes in CO will only cease when PV equals SP
(when e(t) = 0) for a sustained period of time.
At that point, the integral term can have a residual value as just discussed. This residual
value from integration, when added to CObias, essentially creates a new overall bias value
that corresponds to the new level of operation.
In effect, integral action continually resets the bias value to eliminate offset as operating
level changes. PI-controllers have been applied to control almost any process one could
think of, from aerospace to motion control, from slow to fast systems. With changes in
system dynamics and variation in operating points PI-controllers should be retuned on a
regular basis. Adaptive PI-controllers avoid time-consuming manual tuning by providing
optimal PI-controllers settings automatically as the system dynamics or operating points
change[2]. There are various conventional methods used for tuning of PI-controller such
as :

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

1. Trial and error


2. Continuous cycling method (Ziegler Nichols method)
3. Process Reaction Curve Methods (Ziegler-Nichols and Cohen-Coon methods)
4. Ziegler-Nichols method (both types of responses)
5. Cohen-Coon method (self regulating response only

Trial and error [3]


PI-Controller equation is:

It is quite time consuming if a large number of trial are required or if the process
dynamics are slow. Testing can be expensive because of lost productivity or poor product
quality
Continuous cycling may be objectionable because the process is pushed to the stability
limit. Consequently, if external disturbances or a change in the process occurs during
controller tuning an unstable operation or a hazardous situation could result. The tuning
process is not applicable to processes that are open loop because such processes typically
are unstable at high and low values of Kc but are stable at intermediate range values.
This information is an analogy of knowledge of how the other agents around them have
performed. Namely, each agent tries to modify its position as shown in Fig. (1).

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID


POWER SYSTEM

Dr. KVSRIT

Department of EEE

Page

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

CHAPTER 5
MODELING OF PROPOSED THEORY
5.1 SYSTEM MODEL DESCRIPTION
The schematic block diagram of the isolated wind-micro hydro-diesel hybrid power
system is shown in Fig-1. In the hybrid system considered, synchronous generator is connected
on diesel-generator (DG) and induction generators connected on wind turbine and hydro
turbine[10]. Moreover, the Blade pitch controller is installed in the wind side while the governor
is equipped with the diesel side. In the wind-turbine generating unit, the ANFIS based NeuroFuzzy controller is designed as a supplement controller for the pitch control, which constantly
maintains the wind power generation . For the diesel generating unit, the ANFIS based NeuroFuzzy controller is designed to improve the performance of governor. The proposed NeuroFuzzy controller uses the system frequency deviation of the power system as a feedback input on
diesel side, so that it can offset the mismatch between generation and load demand by adjusting
the speed changer position.

Nomenclature:
Fs - deviations in system frequency
FT - speed of the wind-turbine induction generator.
PGD deviation in diesel power generation
PGW - deviation in wind power generation
PGH - deviation in hydro power generation
P
IW - deviation in input power
PIH - deviation in micro hydro power

Dr. KVSRIT

Department of EEE

Page 38

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

Figure-1: Configuration of isolated wind - micro hydro diesel hybrid system


Table 1: System parameters

The transfer function block diagram of a wind- micro hydrodiesel hybrid power system with
Neuro-Fuzzy controller used in this study is shown in Fig-2. The input power to the windpower
Dr. KVSRIT

Department of EEE

Page 39

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

generating unit is not controllable in the sense of generation control, but a supplementary
controller known as LFC can control the generation of the diesel unit and thereby of the system.
The transfer function block diagram of this hybrid system includes the LFC and also the bladepitch controller with ANFIS based Neuro-Fuzzy controller. The dynamics of the wind power
generating unit is described by a first order system. The continuous time dynamic behavior of the
load frequency control system is modeled by a set of state vector differential equations.

(1)
Where X, U and p are the state, control and disturbance vectors, respectively. A, B and are real
constant matrices, of the appropriate dimensions, associated with the above vectors.

Figure-2: Simulink model of wind -micro hydro- diesel hybrid system with ANFIS based NeuroFuzzy controller

Dr. KVSRIT

Department of EEE

Page 40

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

5.2 CONVENTIONAL PI CONTROLLER

Among the various types of load-frequency control, the PI controller is most widely applied to
speed-governor systems for LFC schemes [1 7]. One advantage of the PI controller is that it
reduces the steady-state error to zero. Fig-3 shows the block diagram of conventional PI
controller.

Figure-3:

Block

diagram

of

conventional

PI

controller

Mathematically it is represented as

(2)
However, since the conventional PI controller with fixed gains has been designed at nominal
operating conditions, it fails to provide the best control performance over a wide range of
operating conditions and exhibits poor dynamic performance. To solve this problem, Fuzzy
Logic techniques have been proposed in [6],[11]-[1 4]. System operating conditions are
monitored and used as inputs to a fuzzy system whose output signal controls the inputs to
governor for increasing or decreasing the generation for maintaining the system frequency.

Dr. KVSRIT

Department of EEE

Page 41

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

CHAPTER 6

6.1. FUZZY LOGIC CONTROLLER


Recently, the fuzzy logic based control has extensively received attentions in various
power systems applications [18]. FLCs are knowledge-based controllers usually derived
from a knowledge acquisition process or automatically synthesized from self-organizing control
architectures.

fuzzy

system

knowledge

base

consists

of

fuzzy

IF-THEN

rules and membership functions characterizing the fuzzy sets. The Fuzzy Logic Controller
considered here for comparison is based on Mamdani inference model. The LFC problem
considered here is composed of the sudden small load perturbations or a change in input wind
power which continuously disturb the normal operation of a power system. Hence, the deviations
of frequency must be controlled.

6.2 Fuzzification
Fuzzification is the process of transforming real-valued variable into a fuzzy set variable.
Fuzzy variables depend on nature of the system where it is implemented.

6.2 Knowledge Base


The heart of the fuzzy system is a knowledge base consisting of fuzzy IF-THEN rules.
The rule base consists of a set of fuzzy rules. The data base contains the membership function of
fuzzy subsets. A fuzzy rule may contain fuzzy variables and fuzzy subsets characterized by
membership function.

6.3 De-Fuzzification
The purpose of De-fuzzification is to convert the output fuzzy variable to a crisp value,
So that it can be used for control purpose. It is employed because crisp control action is
required in practical applications. Fig-4 shows the block diagram of Fuzzy logic controller
designed for comparison.

Dr. KVSRIT

Department of EEE

Page 42

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

Figure-4: Block diagram of Fuzzy logic controller


The heuristic rules of the knowledge base are used to determine the fuzzy controller action. The
membership functions, knowledge base and method of de-fuzzification essentially determine the
controller performance. The input variable (Fs) in diesel side for governor is used as error
signal for fuzzy logic controller. The membership functions with 7 linguistic variables
(NL,NM,NS,Z,PS,PM,PL) for two input and one output variable and rule base are shown in Fig5 and Table-2 for the designed fuzzy logic controller for comparison with the proposed controller
Table-2
Rule base (with 7 membership functions)

Dr. KVSRIT

Department of EEE

Page 43

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

Figure-5 Membership functions of input and output variable

Dr. KVSRIT

Department of EEE

Page 44

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

CHAPTER 7
7.1 ADAPTIVE NEURO-FUZZY INFERENCE SYSTEM (ANFIS)
ANFIS is a multi-layer adaptive neural network-based fuzzy inference system[19].
ANFIS algorithm is composed of fuzzy logic and neural networks with 5 layers to implement
different node functions to learn and tune parameters in a fuzzy inference system (FIS) structure
using a hybrid learning mode. In the forward pass of learning, with fixed premise
parameters, the least squared error estimate approach is employed to update the consequent
parameters and to pass the errors to the backward pass. In the backward pass of learning, the
consequent parameters are fixed and the gradient descent method is applied to update the
premise parameters. Premise and consequent parameters will be identified for membership
function (MF) and FIS by repeating the forward and backward passes. Adaptive Neuro-Fuzzy
Inference Systems are fuzzy Sugeno models put in the framework of adaptive systems to
facilitate learning and adaptation [19]. Such framework makes FLC more systematic and less
relying on expert knowledge. To present the ANFIS architecture, let us consider two-fuzzy
rules based on a first order Sugeno model:
Rule

1:

if

(x

is

A1)

and

(y

is

B1)

then

(f1

p1x

q1y

r1)

Rule 2: if (x is A2) and (y is B2) then (f2 = p2x + q2y + r2)

where x and y are the inputs, Ai and Bi are the fuzzy sets, fi are the outputs within the fuzzy
region specified by the fuzzy rule, pi, qi and ri are the design parameters that are
determined during the training process. Out of the five layers, the first and the fourth layers
consist of adaptive nodes while the second, third and fifth layers consist of fixed nodes. The
adaptive nodes are associated with their respective parameters, get duly updated with each
subsequent iteration while the fixed nodes are devoid of any parameters. The ANFIS architecture
to implement these two rules is shown in Fig. 6.

Dr. KVSRIT

Department of EEE

Page 45

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

Layer 1: fuzzification layer Every node I in the layer 1 is an adaptive node. The outputs of layer
1 are the fuzzy membership grade of the inputs, which are given

where x and y is the inputs to node i, where A is a linguistic label (small, large) and where Ai
(x), Bi-2 (y) can adopt any fuzzy membership function.
Layer 2: rule layer a fixed node labeled M whose output is the product of all the incoming
signals, The outputs of this layer can be represented as:

(5)

Figure-6. ANFIS architecture


Dr. KVSRIT

Department of EEE

Page 46

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

Layer 3: normalization layer are also fixed node is a circle node labeled N

(6)
Layer 4: defuzzification layer an adaptive node with a node .The output of each node in this
layer is simply the product of the normalized firing strength and a first order polynomial.

(7)
Layer5: summation neuron a fixed node which computes the overall output as the summation of
all incoming signals.

(8)

Dr. KVSRIT

Department of EEE

Page 47

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

CHAPTER 8
8.1 NEURO-FUZZY CONTROLLER
The development of the control strategy to control the frequency deviation of the windmicro hydro-diesel hybrid power system using the concepts of ANFIS control scheme is
presented here.. The neuro-fuzzy method combines the advantages of neural networks and fuzzy
theory to design a model that uses a fuzzy theory to represent knowledge in an interpretable
manner and the learning ability of a neural network to optimize its parameters . The proposed
controller
integrates fuzzy logic algorithm with a structure of artificial neural network (ANN) five-layer in
order to reap the benefits of both methods .ANFIS is a specific approach in neuro-fuzzy
development which was first introduced by Jang [1 9]. To start with, we design the controller
using the ANFIS scheme. The model considered here is based on Takagi-Sugeno Fuzzy inference
model. The block diagram of the proposed ANFIS based Neuro-Fuzzy controller for wind-micro
hydro-diesel hybrid power system consists of 4 parts, viz., fuzzification, knowledge base, neural
network and the de-fuzzification blocks, shown in Fig-7.

Figure-7 Block diagram of ANFIS based Neuro-Fuzzy Controller


ANFIS uses a hybrid learning algorithm to identify consequent parameters of Sugeno type fuzzy
inference systems. It applies a combination of the least squares method and back propagation
gradient descent method for training fuzzy inference system membership function parameters to
emulate a given training data set. The fuzzy inference system under consideration has two inputs.
Dr. KVSRIT

Department of EEE

Page 48

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

In the proposed paper, inputs to the ANFIS considered are error(Fs) and change in error(Fs)
whereas the output is the corresponding signal to the governor. Steps to design the Neuro-Fuzzy
Controller are as given below:
1. Draw the Simulink model with FLC (Takagi-Sugeno inference model) and simulate it with 7
membership functions for the two inputs(error(Fs) and change in error(Fs)) and with the
given rule base.
2. Collect the training data while simulating with FLC to design the Neuro-Fuzzy controller.
3. The two inputs, i.e., error(Fs) and change in error(Fs) and the output signal gives the
training data.
4. Use anfisedit to create the Neuro-Fuzzy FIS file.
5. Load the training data collected in Step.1 and load the Neuro-Fuzzy FIS file.
6.Choose the hybrid learning algorithm.
7. Train the collected data with generated FIS up to a particular no. of Epochs.
Fig-8 shows the ANFIS structure for the designed Neuro Fuzzy controller.

Figure 8. ANFIS model structure for LFC of wind-micro hydro-diesel hybrid power system
Dr. KVSRIT

Department of EEE

Page 49

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

CHAPTER 9
9.1 SIMULATION AND ANALYSIS
Simulations were performed using the proposed ANFIS based Neuro-Fuzzy controller ,
Fuzzy Logic controller (FLC Mamdani model) and the conventional PI controller to the windmicro hydro-diesel hybrid power system. All the performance criteria s such as settling time,
overshoot and zero steady state are considered to get minimized for all the cases such as change
in frequency, change in wind power, change in diesel power and change in hydro power during
various load disturbances to get the optimum performance of the wind- micro hydro-diesel
hybrid power system. The same system parameters given in Tables 1 were used for the above
three controllers for comparison. Simulation is carried out for 1 % ,2%, 3%,4% and 5%
step increase in the power load ( PL=0.01 p.u. ,0.02 p.u.,0.03 p.u.,0.04 p.u. and 0.05 p.u.) at t =
0s . The overshoot and setting time of proposed ANFIS based Neuro-Fuzzy controller are lower
than those of Fuzzy logic controller and conventional PI controller. The change in frequency of
the system, change in wind power generation, change in diesel power generation and change in
hydro power generation for 0.02 p.u. step load change is shown in Fig-9(a),9(b),9(c) and 9(d)
respectively. And the change in frequency of the system, change in wind power generation,
change in diesel power generation and change in hydro power generation for 0.04 p.u. step load
change is shown in Fig-10(a),10(b),10(c) and 10(d).

Dr. KVSRIT

Department of EEE

Page 50

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

9.2 MAT LAB CIRCUIT

Dr. KVSRIT

Department of EEE

Page 51

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

9.3 SIMULATION RESULTS


WITH PI CONTROLLER:

Fig-9(a) : Frequency deviation of the hybrid system for the step load change.

Fig-9(b) Change in wind power generation for the step load change.

Dr. KVSRIT

Department of EEE

Page 52

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

Fig-9(c) Change in diesel power generation for the step load change.

Fig-9(d) Change in hydro power generation for the step load change .

Dr. KVSRIT

Department of EEE

Page 53

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

WITH FUZZY CONTROLLER

Fig-10(e) Change in frequency for the step load change .

Fig-10(f) Change in wind power generation for the step load change.

Dr. KVSRIT

Department of EEE

Page 54

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

Fig-10(g) Change in diesel power generation for the step load change.

Fig-10(h) Change in hydro power generation for the step load change.

Dr. KVSRIT

Department of EEE

Page 55

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

WITH ANN CONTROLLER

Fig-10(i) Change in frequency for the step load change .

Fig-10(j) Change in wind power generation for the step load change.

Dr. KVSRIT

Department of EEE

Page 56

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

Fig-10(k) Change in diesel power generation for the step load change.

Fig-10(l) Change in hydro power generation for the step load change.

Dr. KVSRIT

Department of EEE

Page 57

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

CHAPTER 10
10.1CONCLUSION
The Neuro-Fuzzy controller is designed for Load frequency control of an isolated windmicro hydro-diesel hybrid power system, to regulate the frequency deviation and power
deviations, based on Adaptive Neuro-Fuzzy Inference System (ANFIS) architecture.
Performance comparison of the proposed paper indicates that the system response of the Load
Frequency Control with the application of ANFIS based Neuro-Fuzzy controller has a quite
shorter settling time. The results obtained by using ANFIS based NeuroFuzzy controller
proposed in this paper outperform than those of conventional PI controller and the fuzzy logic
controller by its hybrid learning algorithm. The main advantage of designing the ANFIS based
Neuro-Fuzzy controller is to control the frequency deviation and power deviation of the windmicro hydro-diesel hybrid power system and to increase the dynamic Performance. It has been
shown that the proposed controller is effective and provides significant improvement in system
performance by combing the benefits of Fuzzy logic and neural networks. The proposed
controller maintains the system reliable for sudden load changes and proves its superiority.

Dr. KVSRIT

Department of EEE

Page 58

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

CHAPTER 11
11.1 REFERENCES
[1] Ackermann, T., Wind power in power systems, John Wiley & Sons Ltd, 2005
[2] Ray Hunter, George Elliot, Wind-Diesel Systems; A guide to the technology and its
implementation, Cambridge university Press, 1994.
[3] Lipman, N.H., Wind-diesel and autonomous energy systems, Elservier Science Publishers
Ltd, 1989
[4] O.I. Elgerd and C. Fosha, Optimum megawatt frequency control of multi-area electric
energy systems, IEEE Trans Power Appl Syst 89 (4) (1970), pp. 556563.
[5]T.S Bhatti, A.A.F. AlAdemi and N.K. Bansal, Load Frequency Control of Isolated Wind
Diesel Hybrid Power System, Energy Conver.Mgnt Vol. 38. No. 9. pp. 829-837,1997
[6] Soundarrajan. A et al, Intelligent controllers for Automatic Generation Control,
Proceedings of The International conference on Robotics, Vision, Information and signal
processing, Malaysia, 2003, 307-311.
[7] P. Kundur, Power System Stability & Control. Tata McGraw Hill, New Delhi, Fifth reprint
2008,pp 581 -626
[8] Saadat, Hadi; Power System Analysis McGraw Hill,1999
[9] C.E. Fosha and O.I. Elgerd, The megawatt frequency control problem: a new approach via
optimal control theory, IEEE Trans Power Appl Syst 89 (4) (1970), pp. 563577.
[10] R.C. Bansal, T.S. Bhatti, D. P. Kothari, A bibliographical survey on induction generators
for application of non-conventional energy systems, IEEE Transactions on Energy Conversion.
18, (2003) 433-439.
[11] B. Anand and A. Ebenezer Jeyakumar Load Frequency Control with Fuzzy Logic
Controller Considering Non Linearities and Boiler Dynamics ICGST-ACSE Journal, ISSN
1687-4811, Volume 8, Issue III, January 2009
[1 2] Ertugrul Cam, Application of fuzzy logic for load frequency control of hydroelectrical
power plants, Energy Conversion and Management 48 (2007) 1281 1288
[1 3]Ertugrul Cam ,Ilhan Kocaarslan, Load frequency control in two area power systems using
fuzzy logic controller, Energy Conversion and Management 46 (2005) 233243
[1 4]A. Soundarrajan, S. Sumathi, Effect of Non-linearities in Fuzzy Based Load Frequency
Dr. KVSRIT

Department of EEE

Page 59

ANFIS BASED NEURO-FUZZY CONTROLLER IN LFC OF WINDMICRO HYDRO-DIESEL HYBRID POWER


SYSTEM

Control, International Journal of Electronic Engineering Research Volume 1 Number 1 (2009)


pp. 3751.
[15]C. Chokpanyasuwan, S. Pothiya, S. Anantasate, W. Pattaraprakorn, and P.
Bhasaputra ,Robust Fuzzy logic PID Controller for Wind-Diesel Power System using Particle
Swarm Optimization,GMSARN International Conference on Sustainable Development, Nov.
2008
[16]R. Dhanalakshmi, S. Palaniswami, Load Frequency Control of Wind Diesel Hydro Hybrid
Power System Using Conventional PI Controller, European Journal of Scientific Research
,ISSN 1450-216X Vol.60 No.4 (2011), pp. 630-641
[17] Bhatti T S, AlAdemi A A F et al,Load Frequency control of isolated wind-diesel-micro
hydro hybrid power systems. Elsevier-Energy, . (1997) , 22(5): 461 - 470.
[18] Ross T J , Fuzzy logic with Engineering Applications, second edition, John wiley&sons
Ltd. (2004)
[1 9] J.R. Jang, ANFIS: Adaptive-network-Based Fuzzy Inference System,IEEE Trans. On
Systems, Man and Cybernetics, Vol. 23, No.3, May.1993, pp.665-685.
[20]Gayadhar Panda, Sidhartha Panda and C. Ardil, Hybrid Neuro Fuzzy Approach for
Automatic Generation Control of TwoArea Interconnected Power System,
International Journal of Computational Intelligence, Vol. 5, No. 1, pp. 80-84, 2009.
[21] C.Srinivasa Rao , Adaptive Neuro-Fuzzy Based Inference System for Load Frequency
Control ofHydrothermal System under Deregulated EnvironmentI nternational Journal of
Engineering Science and TechnologyVol. 2(12), 2010, 6954-6962

Dr. KVSRIT

Department of EEE

Page 60

Anda mungkin juga menyukai