0% found this document useful (0 votes)
25 views21 pages

Topic 3 Notes - Fuzzy Logic & Artificial Neural Networks

DUT Process Control Systems Note - Fuzzy Logic and Artificial Neural Networks
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
25 views21 pages

Topic 3 Notes - Fuzzy Logic & Artificial Neural Networks

DUT Process Control Systems Note - Fuzzy Logic and Artificial Neural Networks
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 21

––

PROCESS CONTROL SYSTEMS 3B (PCSB301)


TOPIC 3 NOTES – FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
N.B Prescribed/Recommended Books
Instrument Engineers Handbook (Vol 2): Process Control and Optimization
Programmable Logic Controllers W. Bolton
Programmable Logic Controllers F. Petruzella
Control Guru - Practical Process Control
PCSB NOTES

TOPIC 2 - PID CONTROLLER TUNING


• Refer to Chapter 2.25
TOPIC 3 NOTES – FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
• Refer to Chapter 2,31 (Fuzzy Logic) & Chapter 2,18 (Artificial Neural Networks.)
▪ Fuzzy Logic Control (FCL) and Artificial Neural Networks (ANN’s) are two different techniques but can be
used both to modelling control because they have some similarities.
▪ They can be applied in non-linear processes where the conventional PID controller does not work.
▪ These are applied where there are difficulties in the traditional linear controllers like PID controller or
ON/OFF controller.
▪ The PID outweighs these techniques because they are poorly understood and PID control is sufficiently
enough to provide adequate control.

PART 1 - FUZZY LOGIC


Invented by Prof Lofti Zadeh in 1969,
First method which allowed linguistic terms to be used as opposed to mathematical algorithms.
Fuzzy Logic control can be found in motor vehicles, washing machines, air conditioners, train control,
process control etc.
Fuzzy Logic converts linguistic terms to numerical terms.
It was successfully applied in Japan subway car speed control, when a subway train is accelerating or
deaccelerating the transition when the car was stationery and from the time it adjourned the control
was smooth without any algorithm only used Fuzzy Logic control.
Fuzzy Logic control uses “if-then” rules if something occurs, then something else must happen.

Advantages of Fuzzy Logic Control


▪ Cheaper − Developing a FLC is comparatively cheaper than developing model based or other controller
in terms of performance.
▪ Robust − FLCs are more robust than PID controllers because of their capability to cover a huge range of
operating conditions.
▪ Customizable − FLCs are customizable.
▪ Emulate human deductive thinking − Basically FLC is designed to emulate human deductive thinking, the
process people use to infer conclusion from what they know.
▪ Efficiency − Fuzzy logic provides more efficiency when applied in difficult control systems

Disadvantages of Fuzzy Logic Control


▪ Requires lots of data − FLC needs lots of data to be applied.
▪ Computational cost − Computational cost increases with increasing rule base.
▪ Needs high human expertise − This is one drawback as the accuracy of the system depends on the
knowledge and expertise of human beings.
▪ Needs regular updating of rules − The rules must be updated with time if the system dynamics deviate.

Page | 1
FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
FLC BLOCK DIAGRAM
➢ The setpoint is added to the sensor feedback.

The Error is negative, Knowledge Database is from the human; Knowledge Database is the user telling
the fuzzy the linguistic terms.
The Fuzzified Linguistic Variables are taken to the Rule Base where the “If-then” sits; For Example, if the
temperature of the process is very low, the valve must open fully (100%), if the fuzzy controller only has
this rule then the temperature of “very cold” is between 0 ℃ and 10 ℃ , the valve will open 100% and
stick to that; when it is above 10 ℃ it would close. It behaves like ON/OFF controller and prevent that
more rules have to be added.
Once the rules trigger the output Defuzzification is added, because the valve cannot handle fuzzified
values; so, they are converted to numerical values or range.
The valve can be closed, medium open, but if the temperature is low, the valve is opened.
The open membership function is triggered, sending the correct value to the valve.

MAJOR COMPONENTS OF THE FLC


1. Fuzzifier − The role of fuzzifier is to convert the crisp input values into fuzzy values.
2. Fuzzy Knowledge Base − It stores the knowledge about all the input-output fuzzy relationships. It also
has the membership function which defines the input variables to the fuzzy rule base and the output
variables to the plant under control.
3. Fuzzy Rule Base − It stores the knowledge about the operation of the process of domain.
4. Inference Engine − Basically it simulates human decisions by performing approximate reasoning.
5. De-fuzzifier − The role of De-fuzzifier is to convert the fuzzy values into crisp values getting from fuzzy
inference engine.

Page | 2
FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
STEPS IN DESIGNING FLC
1. Identification of variables − Here, the input, output and state variables of the plant which is under
consideration must be identified.
2. Fuzzy subset configuration − The universe of information is divided into number of fuzzy subsets and
each subset is assigned a linguistic label.
3. Obtaining membership function − Now obtain the membership function for each fuzzy subset that we
get in the above step.
4. Fuzzy rule base configuration − Now formulate the fuzzy rule base by assigning relationship between
fuzzy input and output.
5. Fuzzification − The fuzzification process is initiated in this step.
6. Combining fuzzy outputs − By applying fuzzy approximate reasoning, locate the fuzzy output and merge
them.
7. Defuzzification − Finally, initiate defuzzification process to form a crisp output.

Heat Exchanger Example Process Liquid

Steam

Heat Exchanger

Set Point

❖ The temperature Transmitter (TT) is the sensor, Heat Exchanger and the valve is the plant.
❖ The output comes from the controller (TC), input to the controller is the sensor (TT) which is negative
feedback.
❖ The set point is also the input to the fuzzy controller which is (TC).
❖ TC gives an output to the valve
❖ In fuzzy logic controller signals are numbers; the input error goes to the fuzzification table.

Fuzzy Input Subset Creation


Example Of Temperature.
Linguistic Variable = [x ; T(x) ; U ; G ; M ]
x – name of variable
T(x) – set of terms (Represent terms like Cold, Very Hot, Hot etc)
U – universe of discourse (range of the system e.g 0 ℃ to 30 ℃)
G – syntax rules (used to convert crisp variable to fuzzified set like “0 ℃ & 10 ℃, Very Cold”, “10 ℃ is Warm”,
between “15 ℃ to 30 ℃, Very Hot”
M – semantic rules (this is where the set of terms are attached, Cold, Very Cold to the fuzzy subset)

Page | 3
FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
Fuzzy Input Membership Functions
▪ Membership functions are the fuzzified membership function represented by the dotted line.
▪ Crisp variable is the straight vertical line
▪ In fuzzy logic values ranging from 0 and 1 are considered.

Fuzzifying The Input


Example Of Temperature.

For Example: if the temperature ranges from 10 ℃ to 30℃; the temperature reading is taken and converted
to linguistic terms because fuzzy controller does not work with numbers.
From 10℃ to 15 ℃ it is “Very Cold” which is a linguistic term.
From 15℃ to 20℃ it is “Warm”; from 20℃ to 30℃ it is “Very Hot”
Fuzzification is taking a range of temperatures and change them to linguistic terms.
A numerical value of a variable is turned into a fuzzy variable; it is neither 0 nor 1, it is a number in
between.
The crisp variable is 0 and increases to 1, anything below 21℃ is Very Cold and anything above 21 ℃ is
Very Hot.

▪ Temperature variable x; VC, C, W, H, VH are Syntax


Rules
▪ Very Cold, Cold, Warm, Hot, Very Hot are Set of
Terms T(x).
▪ Sematic Rules (M)
▪ 0 to 40 is the Universe of Discourse
▪ The temperature variable is broken down in a
fuzzified variable
▪ The lines represent membership functions, which
represent zones ranging from 0 to 1.

Page | 4
FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
On the example Very Cold lies between 0 and 10, it is subjective.
If the temperature is measured at 3 ℃ since VC and C are overlapping, 3 ℃ can be shown as intersecting
VC at 1 and intersect C at 0.4 a set can be created 3 ℃ [1; 0.4; 0; 0; 0] where 1 is VC, 0.4 is C, 0 is W, 0 is
H, and 0 is VH.
This set of numbers is applied to a set of rules then the outputs are fired then defuzzied to crisp variables.
Fuzzified variables are used to work out at which point these membership functions of the fuzzified
variables are fired or triggered.
Then the set is used in a Rule Base to give an output.

FLC OF NON-LINEAR TANK LEVEL

▪ FLC controls the valve.


▪ If the valve is fully open, the time it takes for the level to go from 0 to 25 is fast, from 25% to 50% This is
non-linear because of the shape.
▪ The liquid fills much faster because the rate of change at 25% will be different as a result of the volume
of the tank at this point.
▪ As the level increases it fills much quicker with the valve in one position.
▪ If a standard PID controller is used once tuned it will be applied to a certain rate range only.
For example, the PID can be employed to control the level between a certain range like 40% and 60%
and it will work in that range only.

FLC Of Tank Level


Inputs: a) Error (E)
b) Derivative of Error (Delta E)
Error is derived by the setpoint minus the sensor value which is the level in this case.
Delta E is large at the bottom and the top; it is less at the middle because of the shape.
Outputs: a) Control valve signal (U)
This is coming from the FLC; there must be membership function of the Error which is the range of the
Error; there must be a membership function for the rate of change of error (Delta E) as well.
The control signal (u) also must have a membership function, where the valve will be closed, medium
open or fully open.
Rules: Rules come from user intuition when the level is close to 0 or very low the valve must open fully, the
level will increase, the rate of change (Delta E) will change rapidly.
On the middle, when the level is between 40 and 60 valve must be in a medium position.
Page | 5
FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
1. Fuzzification
For the Error

if the set point is 50% the error will go from Negative to Positive; if the setpoint is 50% the error is -50;
if the level is at 100% the error will be +50.
Error is Negative between -100 to 0; it is Zero between -50 and +50; it is Positive between 0 and +100.
The error has a range of 0 and 1.
For Delta E

Delta E is fuzzified between 0 and 1; Delta E is Negative between -100 and 0; -50 to +50 it is Zero;
between 0 to 100 it is Positive.
The rate of change is Negative, then goes to Zero (no change occurred); then it goes to Positive.

2. De-fuzzification
For the Control Valve (U)

Page | 6
FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
The fuzzified valve is converted to crisp value.
Between 0 and 50, valve is fully Closed; between 25% and 75% the valve is at Medium; between 50%
and 100% the valve is Open.

3. Rule Base
➢ This is second order response there is no deadtime.
➢ The rules can be extracted from this response.

Rules E Delta E U Points


1 P Z O a,e,i
2 Z N C b,f,j
3 N Z C c,g,k
4 Z P O d,h,l
5 Z Z M setpoint

When the Error is Positive, Delta E is Zero, Output to the valve must fully Open; if the level is below the
setpoint the valve must Open shown by Rule 1.
Rule 2, Error is Zero, Delta E is Negative, this crosses the setpoint (b,f,j) the valve must start Closing.
Rule 3 Error is Negative, Delta E is Zero; the level is above the setpoint, the valve must Close fully.
Rule 4 Error is Zero, Delta E is Positive (d,h,l) valve must fully Open.
Rule 5 Error is Zero, Delta E is Zero, the level is Constant, or the process is at the setpoint; the valve must
at Medium.

Determining The Output to The Valve


Just using one rule: If E is P & Delta E is Z then U is O
E=1

Let : Error = 80%


Delta E = +10

At 80% the P membership function is triggered E =1.


This is fuzzified between 0 and 1, because of the intersection.
Delta E = 0,75
Page | 7
FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
X1 X2 Y
0 0 0
0 1 0
1 0 0
1 1 1

If E = 1 and Delta E = 0.75, O = 0.75 using the logic (1+1=1).


{AND =min (1 ; 0.75) =0.75}

40%
U = 85% and the center of gravity of the
shaded shape is given by:
0.375 (𝒂+𝒃𝟐) × 𝒉 (𝟓𝟎+𝟐(𝟒𝟎))×𝟎.𝟕𝟓
𝒙= = =
𝟑(𝒂+𝒃) 𝟑(𝟓𝟎+𝟒𝟎)
𝟎. 𝟑𝟔 × 𝟏𝟎𝟎 = 𝟑𝟔%
50% 36% 𝒉 𝟎.𝟕𝟓
𝒚= = = 𝟎. 𝟑𝟕𝟓
𝟐 𝟐

Page | 8
FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
FUZZY LOGIC FOR FUNCTION APPROXIMATION (MODELLING)
Relationship Between Input (X) And Output (Y)
➢ Any system can be approximated by looking at the inputs and outputs.
➢ For Example:

▪ On this example the input is the valve position, and the


output is the tank level.
▪ If the valve position is increased, the level of the tank
increase at a certain rate
▪ Values obtained can be extracted and plotted on a graph.
▪ This can be used to design or develop a model which is
mathematical.

Y = mx + c

The line y does not give accurate approximation; Fuzzy logic is then used; inputs are broken up into
memberships.
A set of rules is developed, its input is at x1; at x1 the output is y2.
If the input is at x2, the output is y1.
Fuzzy logic can be used to find key relationship between inputs (x) and outputs (y) by using linguistic
terms.

Crisp values are fuzzified between 0 and 1 then that is applied to a rule base.
The fuzzified values are turned into crisp values.

Page | 9
FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
ALTERNATE CONTROL SCHEMES USING A FUZZY LOGIC
Scheme A: Fuzzy Replaces PID
In this configuration, it is up to the operator to control
the process in the existing (conventional) mode or to
switch the controls over to a fuzzy control strategy.
Often, the conventional loops represent an existing
control scheme that has been controlling installing of
a high-level strategy. The operator must decide which
of the two alternatives is the most likely to produce
the best control performance.

PID and fuzzy logic scheme can be employed, in parallel.


This is for systems finding it difficult to operate at certain points using PID, then the control can switch
over to a fuzzy logic controller.

Scheme B: Fuzzy Adjusts PID Parameters

In this configuration, the high-level strategy is used to adjust the tuning parameters of the conventional
control loops. A common problem with linear PID controllers used for control of highly non-linear processes
is that the set of controller parameters produces satisfactory performance only when the process is within
a small operational region. Outside this region, other controller settings are necessary, and these
adjustments may be made automatically by a high-level strategy. This is called Gain Scheduling since such
algorithms were originally used to change controller gains. A gain scheduling controller contains a linear
controller whose parameters are changed as a function of the operating point in a preprogrammed way. It
requires a thorough knowledge of the plant, but it is often a good way to compensate for nonlinearities and
parameter variations. Additional sensor measurements can be used as scheduling variables that govern the
change of the controller parameters often by means of look-up table.
The fuzzy logic controller controls the gains of the PID ( 𝑲𝒄 , 𝑻𝒊 , & 𝑻𝒅 ), the dynamics at these gains are
changes based on the error.
For Example, the tank level would be a set point of gain in certain regions.
The PID controller can be made to operate in a non-linear fashion by altering the gains using fuzzy logic
scheme.
Fuzzy logic is not the controller on this scheme, but PID is the controller, the Fuzzy logic adjusts the
parameters of PID.
The input to the fuzzy logic is Delta E and the output will be 3 outputs which is the adjusting values of
𝑲𝒄 , 𝑻𝒊 , & 𝑻𝒅 .
Page | 10
FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
Scheme B: Fuzzy Adds to PID Output.

This scheme can be viewed as a collaboration of linear and nonlinear control actions; the controller may be
a linear PID controller, while the fuzzy controller is a supplementary nonlinear controller. Normally,
conventional control systems using PID controllers can control the process when the operation is steady and
close to normal conditions. However, if sudden changes occur or if the process enters abnormal situations,
then this configuration may be useful to bring the process back to normal operation as fast as possible. This
scheme can also be interpreted as feedforward–feedback control, where a measurable disturbance is
compensated. Generally, this solution requires a good model, but if a mathematical model is difficult or
expensive to obtain, a fuzzy model may be useful.
The output PID controller and fuzzy logic controller are added.
When the PID controller is not operated, it is compensated by the fuzzy logic controller taking over.

Page | 11
FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
PART 2 - ARTIFICIAL NEURAL NETWORKS (ANN’s)
➢ Used to identify and/or control non-linear time varying systems.
➢ Applications: Modelling, Prediction, Classification, Decision Making, Anomaly Detection & Control.

3 Ways of Model Identification/Modelling:


1. White box/ 1st principles: This model is constructed of previous knowledge and physical insight. The
models here are delivered based on the energy, mass and momentum balances of the process.
2. Fuzzy logic modelling: A linguistically interpretable rule-based model is formed, that is based on the
available expert knowledge and measured data.
3. Black box/ empirical: No physical insight is available or used, but the chosen model structure belongs to
families that are known have good flexibility and have been “successful in the past”

Artificial Neural Network are used to identify non-linear varying systems.


Non-Linear Systems are systems that change over a certain period of time.
Time Varying Systems are systems where there is a change in dynamics as time progresses, this includes
systems like pH control.
Neural Networks model the systems or non-linear time varying dynamics, and that model is used in a
control scheme.
Can be used for prediction based on model of the process it can be predicted what the output will be.
Used for classification like image or text recognition; speech or visual input such as an image can be used,
the neural network can then be designed or trained to recognize the input and generate an output from
it.
Used in decision making, like economics, forecasting and stock markets.
Anomaly detection, this includes false detection, the artificial neural network can detect faults then give
an indication to the operator regarding the fault.
Used for control, for identification and control of process control plants.

White Box/ 1st Principles


➢ From all the knowns of the system like pipe dimensions, flowrate, constants, temperatures, the level of
the process in a tank, pressures and viscosity of the liquid, density of the liquid an idealised model from
first principles can be developed using energy balance equations.

Fuzzy Logic Modelling


➢ Fuzzy logic modeling involves creating a model that can handle imprecise inputs and provide accurate
outputs.
➢ This is particularly useful in systems where traditional mathematical models are difficult to apply.

Page | 12
FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
Black Box/ Empirical
➢ This technique lies upon giving a process input and outputs on the model.

▪ The model is fed the inputs and outputs.


Process
▪ The model will then learn the characteristics of the dynamics of
this process.
▪ Neural networks learn functional patterns from the inputs and
outputs.
▪ Process model is determined without any graphical analysis,
deadtime, time constants or gain by feeding the inputs and
outputs to the model.

CHARACTERISTICS OF ANN’S
1. Exhibit mapping patterns, i.e. input patterns to associated output patterns

Input Output

➢ When the inputs and outputs are applied to the neural network, the ANN will map out of the patterns of
the system.
2. Learn by example
3. Predict new outcomes from past trends.
4. Robust and fault tolerant
5. Process information in a parallel manner.
6. Ability to generalize

McCULLOCH-PITTS NEURON MODEL (1943)

Developed by McCulloch-Pitts Neuron model in 1943.


The neuron has a nucleus, dendrites which are the inputs to the neuron, there is an output going past axon.
Based on the inputs the pulse goes past the synopsis and to the output.

Page | 13
FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
Structure of Neural Networks

▪ Each input is weighted(w), the inputs are added to the


summer, the activation function allows the output to fire
or not fire.
▪ The function is given by the hard limiting function, where
it goes beyond a certain threshold, it changes from zero to
one depending on the inputs.

➢ The McCulloch-Pitts neuron has multiple inputs and a single output. Each of the inputs has an associated
weight. The weight sum of the inputs is passed through a nonlinearity of the output of the neuron as
seen in the previous diagram.
• 𝑿𝒊 are the inputs
• Y is the output of the neurons
• F(z) is the nonlinear activation function in the form of the step function
• 𝑾𝒊 are the strength of the connections.

Perceptron's and Multilayer Feedforward Neural Networks


▪This network’s structure has one input layer, one
output layer, and a number of hidden layer
between them.
▪The input layer neuron do not perform any
computations:
They merely distribute the inputs 𝑿𝒌 to the
weights 𝑾𝒋𝒌 of the hidden layer.
The hidden layer, the weighted sum of the input
is calculated.
A nonlinear transfer function (activation
function) is applied to the result to calculate each
processing element’s output.

➢ The inputs are connected to the Perceptron the outputs then go out.
➢ There are 3 layers Input, Hidden Layer and Output Layers.
➢ This is used to model the system in most process applications.
➢ The perceptron is a McCulloch-Pitts neuron model, with Activation Function, Summer; The Output is
weighted then goes to the next layer.

Page | 14
FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
Perceptron View

➢ This has a Bias Function which is an input to the neuron.


➢ The output can be fed to other neurons and perceptron.
Activation Functions.

1. Linear Transfer Function


• Whatever is sent out is the linear transfer of the input; Example, if n is positive one, the output will be
positive 1.
2. Symmetric Hard Limit Transfer Function
• If the input greater than 0, the output will be one, if less than zero output will be minus 1.
3. Satlin Transfer Function
4. Tan-Sigmoid Transfer Function
• Depending on the inputs it gives a particular output for that Activation Function.
5. Log-Sigmoid Transfer Function
6. Radial Basis Function

Page | 15
FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
DEVELOPING AND BUILDING NEURAL NETWORK
The phases of a neural network life cycle are concept, design, implementation, and maintenance:
• Concept: The first step in implementation of a neural network is to select a neural paradigm. Selection is
based upon the traits of the problem, size of the problem, method of training, and time constraints.
• Design: Specifies initial parameters and conditions for selected neural paradigm. The type and number
of processing elements (neurons), the number of layers, the connectivity of the layers, the transfer
function, and the learning algorithm are design decisions that must be made.
• Implementation: This involves applying the design criteria using customized environment.
• Maintenance: Involves modifying the deployed neural network application because of decreasing
accuracy due to conditions encountered for which the network was not trained.

A THREE LAYER ANN.


➢ The input is a matrix and gives 1x1 output.
➢ a1 is equal to the Activation Function multiplied by the weighted output plus the bias.
➢ a3 is combination of a1, a2 & a3.

TRAINING OF ANN’s
Supervised:

➢ Neurons are interconnected together; in supervised scheme the neural network is fed a set of patterns,
and they are compared to what the output needs to be.

Page | 16
FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
The Desired Output (D) comes from the process; it is the actual pattern given to the Neural Network.
After feeding the Neural Network the first set of Inputs (X) and the Desired Output/patterns (D).
If it does not give the adequate pattern or the correct signal there will be a large Error generated.
The Error Signal is fed back to the Neural Network; overtime the Weights, Biases of each neuron are
increased such that the Error is reduced and such that the output of the Neural Network (Y) is similar to
the Desired Output (D).
After that the Neural Network has learned or has been successfully trained.

Un-Supervised:

In Unsupervised there is no desired output shown to the Neural Network; the Neural Network learns on
its own.
Input pattern comes in, there is an Output(Y); this is used for classification or pattern recognition.
If a pattern of numbers belonging to one group are fed to the Neural Network, the network will be able
to classify or recognize that.

The ANN Training:

In Stochastic method, the values of the weights and the biases are altered randomly.
The optimization reduces the error based on the backpropagation or least mean square.
Backpropagation is where in the first iteration there are initial values set up for weights and biases; the
first pass is done then detect the error then the values of the weights and biases are changed.
On the next iteration, weights and biases will converge into a suitable output solution.
Least Mean squares converge is reached over a period of time based on the steepest gradient descent
method, which use the derivative of the error and reduce it.

Page | 17
FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
The ANN Training Procedure:
1. Collect suitable number of input and output data - ANN has to be given suitable input/information from
the past.
2. Apply principal component analysis (PCA) – Remove outliers from the collected data.
3. Normalize the data set – Data must fit either between 0 and 1 or -1 and +1.
4. Separate data into “training” and “validation” data sets – There must be a data set for training and data
set for validation if used for process identification.
5. Select ANN architecture and train. Increase or “Prune” network and re-train if unsuccessful
6. Test ANN using validation data set.

ANN’S AS FUNCTION APPROXIMATORS

Neural Network can be used to approximate any unknown function.


If Unknown Function is tank level, temperature control, loop process, it can be fed into inputs as ANN.
The inputs are summed, the Error is developed.
There is Adaptation algorithm, overtime the Neural Network will change the weights and biases, and the
Error will be reduced overtime.
The ANN Over-Training
Increasing the number of neurons can lead to a reduction in error.
Overtraining can lead to more error, where the system is tied down to a specific solution too much, and
when given a set of new inputs it becomes very irrational.

Page | 18
FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
MODELLING APPLICATION OF A DISTILLATION PROCESS USING ANN’S

Inputs (Feed flowrate, Distillate flowrate, bottoms flowrate, steam flowrate, feed temperature etc.)
these are all fed to neurons of a, there are 4 Hidden Layers.
Output Layer gives off indication of the concentration of bottom product and the top distillate product
concentration.
The Inputs are inferred in order to workout RVP in Bottom and Distillate 95% BP.
The Inferential sensors outputs are compared to the Neural Network outputs.
Results are validated and the sensor is removed since the Neural Network is trained it can estimate the
concentrations.

Training ANN’s Using MATLAB Example


Step-by-Step Beginners Tutorial: How to Train an Artificial Neural Network with MATLAB

PLANT IDENTIFICATION

The Input(u) goes to a Plant and Neural Network Model.


The Output of the Plant is fed back to the Neural Network Model.
An Error is generated based on the Neural Network Model output and the plant actual output.
The Error goes to the Learning Algorithm, which adjusts weights and biases on the Neural Network.
Then the Error is reduced.
Page | 19
FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS
SMITH PREDICTOR FOR PROCESSES WITH VERY LONG DEAD TIMES.
➢ Large deadtime, if the ratio in a process is very large then the system is difficult to control.
➢ Smith predictor is a model-based approach, the model of the process can be without the deadtime by
manipulating inputs and outputs.
➢ System with the deadtime is neural network in this case.

A signal is sent to the Plant, then the signal is added up (if the Plant and System Deadtime is adequately
determined by the Neural Network, the Output (𝒆𝒑 ) will be zero because if the Process Model and the
Plant are the same, the output should be zero.)
If disturbance signal is added to the Output (y), 𝒆𝒑 will not be zero anymore, 𝒆𝒑 will be equal to the
disturbance then it will be added to the Output of the Process Model without the deadtime (𝒚𝒑 ).
Then the PID Controller will use the disturbance to bring the Plant back to the setpoint.

PLANT CONTROL USING ANN’S

NN Controller reduces error signal from the Robustness Filter which is a normal first order filter.
Robustness Filter makes the system robust and prevents the system from giving too large or too low
values.
NN Controller looks at the error and gives suitable Control Output to the Plant which has non-linear
dynamics.
Non-linear dynamics of the plant can be modelled using NN Plant Model.
Predictive control applied when output goes to the Plant, the NN Plant gives out the Predicted
Output.
Difference between Plant Output and Predicted Output are sent back to the error, then the error is
reduced by the Filter; Error is reduced based on the Predicted Output.

Page | 20
FUZZY LOGIC & ARTIFICIAL NEURAL NETWORKS

You might also like