Professional Documents
Culture Documents
Sebastian B. Tidikwe
2014
By Sebastian B. Tidikwe
I. ABSTRACT
Modern technology is evolving at an exponential rate, with engineers continuing to
produce more human like automation and Fuzzy Logic has proved to be one of the
major contributors to this reality. The objective of this report is to provide an
understanding of fuzzy logic with an aim to develop a fuzzy controller for an automated
guided vehicle. In this report the author provides a detailed understanding of fuzzy
logic and its implementation on MATLAB followed by an insight into Automated
Guided Vehicles where the problem can be identified. A solution to the problem is
implemented in MATLAB Fuzzy Logic Toolbox then tested in Simulink with assumed
conditions. Positive results obtained from the experiment prove the viability of Fuzzy
Logic programming hence readers can use this document as basis to real-time
programming.
TABLE OF CONTENTS
I.ABSTRACT....................................................................................................................................... 3
II.TABLE OF FIGURES..................................................................................................................... 5
III.ACKNOWLEDGEMENTS........................................................................................................... 5
1.INTRODUCTION............................................................................................................................ 5
1.1.BACKGROUND............................................................................................... 5
1.2.OUTLINE OF REPORT..................................................................................... 6
1.3.AIMS AND OBJECTIVES.................................................................................. 8
1.3.1.AIM:........................................................................................................ 8
1.3.2.OBJECTIVES:........................................................................................... 8
2.LITERATURE REVIEW................................................................................................................. 9
3.1. DEVELOPMENT........................................................................................... 48
3.1.1. MEMBERSHIP FUNCTIONS.................................................................... 48
3.1.2. RULES................................................................................................. 55
4.RESULTS AND DISCUSSION...................................................................................................... 59
5.1. CONCLUSION............................................................................................. 63
5.2. RECOMMENDATIONS.................................................................................. 64
6.REFERENCES AND BIBLIOGRAPHY...................................................................................... 65
7.APPENDIX...................................................................................................................................... 67
7.1.GANTT CHART............................................................................................. 67
7.2.HEALTH & SAFETY, ETHICS AND SUSTAINABILITY....................................... 68
7.3.PARAMETERS.............................................................................................. 68
III. ACKNOWLEDGEMENTS
I would like to express my very great appreciation to Dr H.S.Qi for his valuable and
constructive suggestions during the planning and development of this report. His
willingness to give his time so generously has been highly appreciated. I would also like
to thank all the colleagues and friends who contributed to the successful completion of
this project. My grateful thanks are also extended to Dr Readle for his valuable advice
upon completion of the project.
1. INTRODUCTION
1.1. BACKGROUND
The issue of uncertainty has not always been embraced within the scientific
community; uncertainty represents an undesirable state, a state that must be avoided at
all costs. The leading theory in quantifying uncertainty in specific models from the late
nineteenth century until the late twentieth century had been probability theory.
However, the gradual evolution of the expression of uncertainty using probability theory
was challenged, first in 1937 by Max Black, with his studies in vagueness, followed by
the introduction of fuzzy sets by Lofti Zadeh in 1965 whos work had a profound
influence on the philosophy about uncertainty because he challenged not only
probability theory as a sole representation of uncertainty, but the very fundamentals
upon which probability theory was based: classical binary (two valued) logic [Klir and
Yuan, 1995 cited in (Ross, 2004)].
This project has been inspired by the fuzzy computer research which focuses in
achieving high speed characteristics with fuzzy interference computer relationships
together with fuzzy computer architecture, fuzzy logic vague and fuzzy computer
programming language.
During research it was gathered that AGVs are installed with a basic safety mode. This
safety mode is too basic in the sense that it could slow production as the AGVs cannot
avoid the obstacle but rather wait until the obstruction has been removed. As a result
this project was undertaken as means to find a solution around this problem. The main
aim and objectives of the report are listed in chapter 1.2.
Chapter 1: Introduction
Critical analysis of work done previously, main achievements and existing problems.
This chapter also proves lack of solutions which justifies the significance of this report.
Achieved by the use of University library services and electronic documentation.
This chapter provides a detailed formulation and solution of the simplified software
model. A physical model is transformed into a software model for testing the fuzzy
controller developed using methods explained in section 2.1. of literature review.
The last main section of the report, this chapter focusses on providing a summary of
technical conclusions drawn from the report. The conclusion constitutes a review of the
project with respect to the aim and objectives. This chapter also states further work that
could be carried out to improve the project, extension of ideas and optimisation of
concepts. By thinking around the subject, it displays an awareness of relevance to other
applications critique and future preference.
Chapter 7: Appendix
Supports the report and has information that impedes the main text such as Gantt chart
and simulation parameters. Also includes a critical reflection on Health and Safety,
Ethics and Sustainability.
1.3.1. AIM:
1.3.2. OBJECTIVES:
Discuss results
2. LITERATURE REVIEW
Fuzzy logic is a form of multivalued logic derived from fuzzy set theory to deal with
reasoning that is approximate rather than precise. Just as in the fuzzy set theory the set
membership values can range (inclusively) between 0 and 1, in fuzzy logic the degree of
truth of a statement can range between 0 and 1 and is not constrained to the two truth
values {true, false} as in classic predicate logic (Vargus, 2009, p. vii). With the use of
logistic variables, these degrees may be managed by specific functions.
Mankind often uses notions which are quite vague; for example, a man is considered
young or old, an object light or heavy, a car slow or fast and so on. Take young as an
illustration; Suppose A is a 20 year old man, who is reflected to be certainly young. Now
comes another man B, only one day older than A. Of course, B is also young but how
about a man only one day older than B. Continuing in this way, it quite difficult to
determine an exact age beyond which a man will be considered middle aged. As a
matter of fact, there is no distinct line between the two but rather a gradual transition
from one concept to another.
In 1965, Zadeh introduced the concepts of fuzzy sets just in order to represent this class
of sets. Providing a number to every element in the universe, which indicates the degree
(grade) to which the element belongs to a fuzzy set. In this interpretation, everybody has
a degree to which he or she is young (eventually the degree is 0 or 1). (Xushu, et al.,
2009, pp. 21-22)
In order to introduce the concept of fuzzy sets, the elementary set theory in classical
mathematics must first be reviewed briefly as it shows how the fuzzy set theory is a
natural extension of the classical set theory.
A set consists of some elements which are definite, in other words, it should be clear
whether or not an element belongs to a particular set. As a result, a set can only be
employed to describe a concept which is crisply defined. For example, a collection of
universities with the population more than 1 million forms a set since we can judge that
a given university is in this set or not with vagueness. (Xushu, et al., 2009, p. 21)
i.e. T : u U (0,1)
Example 1. Let P be the proposition the structural beam is an 18WF45 and let Q be
the proposition the structural beam is made of steel. Let X be the universe of
structural members comprised of girders, beams and columns; x is an element (beam),
A is the set of all wide-flange (WF) beams, and B is the set of all steel beams. Hence
P : x is in A
Q : x is in B
A propositional calculus (also known as algebra of propositions) will exist for the case
where proposition P measures the truth of the statement that an element, x, from the
universe X is contained in set A and the truth of the statement Q that this element, x, is
contained in set B, or more conventionally.
P : truth that x A
Q : truth that x B
or using the characteristic function to represent truth (1) and falsity (0), the following
notation results:
Set Operations
In its simplest meaning, an operation is a procedure which produces a new value from
one or more input values. In ordinary arithmetic and algebra the four common
operations that can be performed are namely; addition, subtraction, multiplication and
division. Similarly we also define several operations on sets, the most fundamental
operations being union, intersection and complement of any set with respect to some
superset of it.
Union: The union of two sets A and B is written as A B and defined as that set which
contains all the elements lying within either A or B or both. In the basic representation
the definition is:
A B = { x: x A or x B}
Then: A B = (a,b,c,d,e,f)
Intersection: The intersection of two sets A and B is written as A B and defined as that
set which contains all the elements lying within both A or B. In the basic representation
the definition is:
A B = { x: x A and x B}
Then: A B = (b,d)
Both Union and Intersection obey the associative, commutative and distributive law and
can be used in any combination.
Complement: the complement of a set A is the set of elements which do not belong to A,
that is, the difference between the universal set U and A. we denote the complement of A
by:
A' = {x: x U, x A}
A' = {x: x A}
A basic concept of fuzzy logic is that, instead of strictly true or strictly false, all things
can be conceptualized as having a position on a sliding scale in the way they belong to
categories. In order to express this position, objects (observations, properties, etc.) are
assigned a degree of membership. (Dijk & Geert, 2009)
The word fuzziness has evolved to portray the information associated with the human
language which is being used in our everyday decision making process and in a
mathematical sense, not very precise. For example in Botswana in the month of
September daytime temperature is usually around 37C to 42C. A resident of Botswana
will classify this temperature as not very hot. By a friend just arriving from England,
his classification for this temperature would be very very hot. (Xushu, et al., 2009, p. V)
Mathematical Modelling
The basic concept of fuzziness as shown in the examples above needs to be represented
in a mathematical manner. This is a requirement in getting to the sentiment of the
notion, in manipulating fuzzy statements, and in applying them. (Nguyen & Walker,
1997, p. 2). The succeeding definition expresses this concept of fuzzy sets
mathematically.
Definition: Let X be the universe. A mapping A : X [0,1] is called a fuzzy set on X. the
value A(x) of A at x X stands for the degree of membership of x in A. The set of all
fuzzy sets on X will be denoted by F(X).
A(x) = 1 means full membership, A(x) = 0 means non membership and intermediate
values between 0 and 1 mean partial membership. A(x) is referred to as membership
function or characteristic function as x varies in X.
Defined as
Example: let O denote old and Y denote young. We limit the scope of age to X = [0,100]
then both O and Y are fuzzy sets that are respectively defined as follows:
Different functions of A can be considered. The choice of the function A is subjective and
depends on particular circumstances. Suppose we want to model the notion of high
wages with a fuzzy set. By reviewing a large number of people it could be observed that
Supervised By: Dr. H.S.Qi
Report By: Sebastian Baboni Tidikwe Page 14
Fuzzy Logic Controller for Automated Guided Vehicle
no one thinks that an income under 20 000 is high, but that the fraction p of people
think that an income x between 20 000 and 75 000 is high is approximately
One of the most frequently used examples of a fuzzy set against classic set is the set of
human height. In this case, the universe of discourse is all heights that have the potential
of being perceived as tall, say from 1 meter to 2 meters, and the word tall would
correspond to a curve that defines the degree to which any person is tall. If the set of tall
people is given the distinct boundary of a classical set, it could be assumed that all
people taller than 1 meter are officially considered tall. However, such a distinction is
clearly ludicrous. It may make more sense to consider the set of all real numbers greater
than 1 because numbers belong on an abstract plane, but when we want to talk about
real people, it is unreasonable to call one person short and another one tall when they
differ in height by the width of a hair.
If the kind of distinction shown previously is impractical, then what is the right way to
define the set of tall people? The following figure shows a smoothly varying curve that
passes from not-tall to tall. The output-axis is the membership value between 0 and 1
where is the membership function that defines the transition from not tall to tall.
Crisp output
Fuzzy output
The only condition a membership function must really satisfy is that it must vary
between 0 and 1. The function itself can be subjective to suit us from the point of view of
simplicity, convenience, speed, and efficiency.
Piece-wise linear functions consist of the triangle and trapezoidal functions, trimf and
trapmf respectively. These are straight line membership functions that have the
advantage of simplicity.
concise notation, Gaussian and bell membership functions are popular methods for
specifying fuzzy sets.
The sigmoidal membership function is open either left or right. Closed membership
functions can be synthesised using two sigmoidal functions, so in addition to the
basic sigmf, you also have the difference between two sigmoidal functions, dsigmf,
and the product of two sigmoidal functions psigmf.
Polynomial based curves include Z, S, and Pi curves, all named because of their shape.
The function zmf is the asymmetrical polynomial curve open to the left, smf is the
mirror-image function that opens to the right, and pimf is zero on both extremes with
a rise in the middle.
(MathWorks, 1994-2014)
Logical Operations
Fuzzy logic, just as fuzzy sets, borrows notion from crisp logic. As in our extension of
classical set theory to fuzzy set theory, our extension of crisp logic to fuzzy logic is made
by replacing membership functions of crisp logic with fuzzy memberships. (Bandemer
& Gottwald, 1995). If you keep the fuzzy values at their extremes of 1 (completely true)
and 0 (completely false), standard logic operations will hold.
Now, because in fuzzy logic the truth of any statement is a matter of degree, these truth
tables can be altered.
AND: this operation is almost similar to the classical set intersection but with a
difference that an element can partly belong to both the sets but still with a different
memberships.
OR: In a similar way to classical set union, means how many of the element is in either
set.
NOT: Similar to the classical set complement, implicates to what extent elements are not
the member of the set
With the above awareness, statement A AND B can be resolved by using the function
min(A,B), using the same reasoning, the OR operation can be replaced with the
maximum function so that A OR B becomes equal to max(A,B). Finally the operation
NOT A becomes equal to the operation 1-A.
Notice how the previous truth table is completely unaffected by this substitution.
Because there is a function behind the truth table rather than just the truth table itself,
you can now consider values other than 1 and 0. Figure 10 uses a graph to show the
same information, the truth table is converted to a plot of two fuzzy sets applied
together to create one fuzzy set. The upper part of the figure displays plots
corresponding to the preceding two-valued truth tables while the lower part of the
figure shows how the operations work over a continuously changing range of truth
values A and B according to the fuzzy operations.
In this case, we have defined what is called Fuzzy Intersection (AND), Fuzzy Union
(OR) and Fuzzy Complement (NOT).
These fuzzy operators which are often referred to as T-norm and S-norm operators
respectively, meet the following basic requirements:
The first requirement imposes the correct generalization to crisp sets. The second
requirement implies that a decrease in the membership values in A or B cannot produce
an increase in the membership value in A intersection/union B. the third requirement
indicates that the operator is indifferent to the order of the fuzzy sets to be combined.
Finally, the fourth requirement permits the intersection/union of any number of sets in
any order of pair-wide groupings.
Fuzzy Rules
If x is A then y is B
Where A and B are linguistic values defined by fuzzy sets on the ranges X and Y,
respectively. The if-part of the rule x is A is called the antecedent, while the then-part
of the rule y is B is called the consequent or conclusion. An example of such a rule
might be;
The concept far is represented by numbers 0 and 1, and so the antecedent is and
interpretation that returns a single number between 0 and 1. On the contrary, fast is
represented as a fuzzy set, and so the consequent is a consignment that assigns the entire
fuzzy set B to the output variable y.
In general, the input to an if-then rule is the current state for the input variable (in this
case, object) and the output is an entire fuzzy set (in this case, fast). This set will later be
defuzzified. The concept of defuzzification is described later in the next section.
Interpreting an if-then rule involves distinct parts; first evaluating the antecedent and
second applying that result to the consequent. In the case of two-valued or binary logic,
if-then rules do not present much difficulty, if the antecedent is true then the conclusion
is true. If the restrictions of two-valued logic are released to allow the antecedent to be a
fuzzy statement, how does this reflect on the conclusion? The answer is a simple one; if
the antecedent is true to some degree of membership then the consequent is also true to
that degree.
Thus:
In which case all parts of the antecedent are calculated simultaneously and resolved to a
single number using logical operators.
The consequent of a rule can also have multiple parts.
If temperature is cold then hot water valve is open and cold water valve is shut
(MathWorks, 1994-2014)
The process of fuzzy inference involves all the pieces described in the previous sections:
membership functions, fuzzy logic operators and if-then rules. There are two types of
fuzzy inference systems that can be implemented in the MATLAB Fuzzy Logic
Toolbox: Mandani-type and Sugeno-type. These two types of inference systems vary
somewhat in the way outputs are determined.
Mandanis fuzzy inference method is the most commonly seen fuzzy methodology and
as defined for the Fuzzy Logic Toolbox, expects the output membership functions to be
fuzzy sets. After the aggregation process, there is a fuzzy set for each output variable
that needs defuzzification. It is possible, and in many cases efficient, to use a single spike
as the output membership function rather than a distributed fuzzy set. This is
sometimes known as singleton output membership function, and it can be thought of as
a pre-defuzzified fuzzy set. It enhances the efficiency of the defuzzification process
because it greatly simplifies the computation required by the more general Mandani
Example
The Basic Tipping Problem: consider the tipping problem; Given a number between 0
and 10 that represents the quality of service at a restaurant (where 10 is excellent), what
is the right amount to tip your waitperson?
With information flowing from left to right, from two inputs to a single output, the
diagram below shows a basic structure of the example problem;
In the Fuzzy Logic Toolbox there are five parts of the fuzzy inference process:
Fuzzification of the input variables
Application of fuzzy operator (AND or OR) in the antecedent
Implication from the antecedent to the consequent
Aggregation of the consequents acroos the rules
Defuzzification
The first step is to take the inputs and determine the degree to which they belong to
each of the appropriate fuzzy sets via membership functions. The input is always a crisp
numerical value limited to the universe of discourse of the input variable and the output
is a fuzzy degree of membership in the qualifying linguistic set. Fuzzification of the
input amounts to either a table lookup or a function evaluation.
This example is built on three rules, and each of the rules depends on resolving the
inputs into a number of different fuzzy linguistic sets.. Before the rules can be evaluated,
the inputs must be fuzzified according to each of these linguistic sets. For example to
what extend is the food really delicious?
Figure 13 shows how well the food at the hypothetic restaurant (rated on a scale of 0 to
10) qualifies via its membership function, as the linguistic variable delicious. In this
case, the food is rated an 8, which, given your graphical definition of delicious
corresponds to = 0.7 for the delicious membership function.
In this manner, each
input is fuzzified over
all the qualifying
membership functions
required by the rules.
If the antecedent of a given rule has more than one part, the fuzzy operator is applied to
obtain one number that represents the result of the antecedent for that rule.
In the toolbox, two built-in AND methods are supported: min (minimum) and prod
(product). Two built-in OR methods are also supported: max (maximum), and the
Probor(a,b) = a + b ab
Figure 14 shows the OR operator max evaluation of the antecedent of the rule 3 yielding
fuzzy membership values 0.0 and 0.7 respectively.
Before applying the implication method, rule weight must be determined, a number
between 0 and 1 which is applied to the number given by the antecedent. Generally this
weight is 1 (as it is for this example) and thus has no effect at all on the implication
process.
After proper weighting has been assigned to each rule, the implication method can be
applied. The consequent is reshaped using a function associated with the antecedent.
The input of the implication process is a single number given by the antecedent, and the
output is a fuzzy set. Two built in methods are supported and they are the same
functions that are used by the AND method: min (minimum), which truncates the
output fuzzy set, and prod (product), which scales the output fuzzy set.
Aggregation is the process by which the fuzzy sets that represent the outputs of each
rule are combined into a single fuzzy set. The input of the aggregation process is the list
of condensed output functions returned by the implication process for each rule. The
output of the aggregation process is one fuzzy set for each output variable.
Three built-in methods are supported:
max (maximum)
figure 16 shows all three rules placed together to show how the output of each rule is
combined, or aggregated, into a single fuzzy set whose membership function assigns
a weighting for every output (tip) value.
Step 5. DEFUZZIFY
The input of the defuzzification process is the aggregate output fuzzy set and the output
is a crisp number. As much as fuzziness helps the rule evaluation during the transitional
steps, the final desired output for each variable is generally a crisp number. However,
the aggregate of a fuzzy set incorporates a range of output variables, and so must be
defuzzified in order to resolve a single output value from the set.
The most common defuzzification method is the centroid calculation, which returns the
centre of area under the curve. There are five built-in methods supported: centroid,
bisector, middle of maximum (the average of the maximum value of the output set),
largest of maximum and smallest of maximum.
Figure 14 Defuzzification
(MathWorks, 1994-2014)
Definitions
The AGVS product section of the Material Handling Institute defines an automatic
guided vehicle as:
A vehicle equipped with automatic guidance equipment, either electromagnetic
or optical. Such a vehicle is capable of following prescribed guide paths and may
be equipped for vehicle programming and stop selection, blocking and any other
special functions required by the system.
Wire guidance was the major AGV guidance technology in the 70s where an electronic
frequency is induced in a wire buried in the floor. An antenna is then fixed on the AGV
that would seek out the frequency and guide the vehicle based on the strength of the
signal. For decisions points and intersections, multiple wires are installed but only the
wire corresponding to the intended direction is energised.
This principal navigation scheme was expensive to install as the strict path of the AVG
needed to be cut in the floor in order to bury the wire and the cut for a turn had to
follow the radius curve that the vehicle will make when turning. Usually systems had to
embed four wires, three for guidance and one for communications. Also sometimes
electronic signals would interfere with the guidance signals in the wires. Smart floor,
dumb vehicles was the name given to these systems as the core intelligence of the system
was in the floor controllers. As of today this technology is sometimes applied on very
basic applications as new guidance systems have emerged.
Within industrial environments, the use of AVGs has evolved radically. Originally
designed for horizontal transportation of palletized material, the design and application
of AVGs and controls are now as varied as those of industrial robots. They can be stand
alone systems, an integral part of another system, or aid in pulling together islands of
automation.
Outside industrial environents, Automated Guided Vehicles are now also being applied
for transhipment at ports, as people movers and in the entertainment industry. (FROG
AGV Systems, 2014)
UNUSUAL APPLICATIONS
Two unique applications of a very customized AVGS are the two Mars rovers, Spirit and
Opportunity. These are automated guided vehicles that operate on mars and are
engaged via radio transmitted instructions from earth by a team at the National
Aeronatics and Space Administration (NASA). They have spent nearly eleven years
(originally landing injanuary 2003) on mars, travelling several miles and frequently
stopping to do scientific analysis. Their mission is a big success for NASA and represents
one of the more unusual applications of AVG to date. (Inc., 2014).
ADVANTAGES
The material handling institute provides the following list of benefits of an AGVS:
Economic Justification. In more and more material handling situations, AGVSs are
proving themselves as the most economical method of moving material.
Automatic Interface with Other Systems. An AGVS is designed to interface
automatically with other material handling systems including conveyors, automatic
storage / retrieval systems, production lines and other devices including elevators,
doors, draw bridges, robots and shrink and stretch wrap tunnels.
System Liability. Computer control allows material tracking between stations and
delivery confirmation in real time.
Increased Productivity. In cases where driverless vehicles are used, a substantial
savings is incurred due to labour reduction. Order picking vehicles require
operators to perform the picking and stowing functions; however, a substantial
LIMITATIONS
No matter how marvellous an automation device may be, there are always associated
drawbacks. AGVS are no exception. In some instances these drawbacks may prevent a
system from being installed or necessitate extensive modification of the existing facility
to permit use of the device. Negative management and/or employee attitudes should be
considered as a possible drawback.
Expense. Experienced users claim that the initial investment for large assembly-type
AGVS may be two or three times that of traditional material handling methods.
Worker Attitudes. Not only must management be committed to successful system
implementation, but equal support from the work-force is also essential. Many of the
early AGV systems failed because the unions saw them as a direct threat. Systems
were forced out because of sabotage by employees.
Ramp Gradients. Ramp gradients are usually limited to 4-6%, although gradients of
up to 10% are permissible with reduced load capacity. Long ramps may create such
problems as overheating of motors and my further reduce the load capacities. In
addition, if the vehicle is required to stop on the ramp (either emergency or
programmed stop), the motor may not have sufficient restart power.
Complexity. Use of higher level of software and hardware prevents the majority of
electricians from troubleshooting and repairing AGVs. (Hammond, 1986, pp. 17-19).
The main aspect of AGVs is navigation; there are two basic principles of the navigation
of an Automated Guided Vehicle:
1. Fixed path
2. Free ranging
Fixed path navigation is the oldest method of navigation. Most of the systems that are
being installed are now free ranging AGVS that allow greater flexibility and better
maintainability.
The first three methods require a sensor under the Automated Guided Vehicle which
can detect the existence of the surface mounted path. If the path makes a turn the
sensor detects a turn providing feedback to the onboard vehicle controller, which in
turn causes the Automated Guided vehicle to steer in the direction of the path.
In case of a current carrying wire, the sensor underneath the AVG is usually a small
antennae consisting of magnetic coils. With current flowing, a magnetic field surrounds
the buried wire. The closer the buried wire is to the AGV antennae, the stronger the
field. The magnetic field is completely symmetrical around the conductor or the buried
wire. At a given instance from the wire the field has the same strength on either side of
the cable. The field strength is detected by the antennaes magnetic coil and induces
voltage in the coil.
The Automated Guided Vehicle steers itself to follow the magnetic field surrounding the
buried wire. To get a steering correction signal the AGVs sensing antennae consists of
two coils, when the vehicle is centered directly above the buried wires, equal voltages
are induced in the two coils. If the Automated Guided Vehicle moves a bit to one side of
the wires, a difference in signal strength in the coil proportional to side displacement of
the coil is produced and this difference is fed back to control an onboard servo motor,
which turns the guide wheel or wheels until both coils receive equal signs, and therefore
the course will be corrected.
A map of the area in which the AGV can operate contained in the vehicles
computer memory.
Multiple, fixed reference points located within the operating area that can be
detected or seen by the AGV.
During travel the AVG will measure distance and direction by counting the number of
wheel revolutions and measuring the steering angle (odometry). Sensors attached to the
wheels provide the data that determine the distance covered as well as the change in
direction.
Errors are revised by relating the calculated position of the vehicle with actual position
of the vehicle which is determined by means of external reference points. There are
three different types of calibration for free ranging AGVs:
Laser
Grid
GPS
The GPS option is only applicable outdoors. Grid and laser are calibration alternatives
suited for indoor environments, while the grid can also be applied in outdoor AGV
applications.
Laser
Commonly used in industry environments, laser guidance involves reference
points strategically located as targets (super-
high reflective reflectors)
mounted to a vertical surface
such as a wall or column on
known X and Y locations. A
guiding light on top of the vehicle emmits
a rotating laser beam, which is reflected back to the
vehicle when it strikes the reflector. An Automated Guided Vehicle needs only two (but
idealy three or four) targets in order to calculate a relative coordinate location and
heading using simple geometry.
Grid
Tuning by means of grid is less common as it
is original to only a selected group of licencees
such as FROG AGV Systems. The grid
consists of small magnets implanted in the
road surface and the AVG re-calibrates its
position everytime the vehicle travels over one
of the magnets. A magnets ruler (sensor) mounted underneath the AGV is used to detect
the magnets.
Laser and grid calibration are just as accurate and companies will always select the
calibration principle most suited to the AGV application. (FROG AGV Systems, 2014)
GUIDANCE
There are two basic types of AGVS steering control differential speed steer control
and steered wheel steer control.
COMMUNICATION
Message commands such as where to go, when to start, when to slow down and when to
stop and also includes fault condition reporting. Computer-controlled systems
overseeing remote objects need a means of communication commands, and in many
cases confirming replies between a supervisory computer and the objects being
controlled. Depending on the application, there are four types of basic communication
media being used within AGVSs:
Radio Communication
Infrared Communication
There are two classifications for AGV communication systems: continuous and
discrete. Continuous indicates that the supervisory controller can always communicate
with any vehicle; whereas discrete means that the supervisory controller can only
communicate with a particular vehicle at certain times (usually determined by vehicle
positioning). Such positions are commonly referred to as communication points.
(Hammond, 1986, p. 75)
Radio communication provides maximum flexibility in system control, new routings and
maps can be downloaded quickly and system speed of response to changing load
movement demands is improved. (FROG AGV Systems, 2014). In manufacturing
applications, large motors or spot welding processes in the vicinity of the AGVS system
can create radio frequency noise interference with the communication broadcasts.
As a result, some suppliers provide Inductive Communication systems whereby a
second set of wires is layered in the floor with the guidepath wires or alternatively
multiplex digital data is transmitted through the guidewire itself. (Hammond, 1986, pp.
75-76). Electronic commands in the form of programmed frequencies are sent out via
the wire loops where antennas on the underside of the vehicles can sense the frequencies
which are then decoded and acted on by the AGV. (FROG AGV Systems, 2014).
Infrared Communication is highly reliable but has the advantage of not being
continuous but rather point to point. AGVs are stopped during this data exchange
which usually occurs at load stations where the fixed and mobile units are aligned and
in close proximity (e.g. hokuyo sensors). Otherwise, the AGV communicates at fixed
points along its guidepath as the AGV travels through a given zone. Usually infrared
communication is not used any longer to communicate between Automated Guided
vehicles and the supervisory control system. Infrared is now used for local
communication such as lining up with a conveyor belt. (FROG AGV Systems, 2014).
Guide Wire Data Communication as it is involves data being transmitted on the guide
wire by the guide line. It provides almost the same flexibility as radio, with the exception
of vehicle movement off the wire. Since the distance between the guide wire and the on
board responders is constant, there are no transmission dead spots, as there may be
with radio. The techniques to accomplish this type of data link are not widespread.
(FROG AGV Systems, 2014).
ENERGY MANAGEMENT
Power on virtually all AGVs is provided by batteries. Different battery technologies are
available for AGVs, but the selection of most appropriate battery type for each AGV-
application is determined by factors such as ambient temperature, throughput, number
of shifts in operation, the type of AGV used to handle the loads, the load weight, and
specific customer requirements.
SAFETY
The purpose of an AGV obstacle detection is to detect any obstacle on the path, in the
time, so that the AGV can slow down and stop, if necessary until the path is clear. As the
path clears, the AGVs will automatically continue their trip.
Bumpers: Some AGVs are equipped with bumpers and/or contact strips which work
upon impact causing the vehicle to stop immediately when in contact with an obstacle.
This is the most basic form of obstacle detection but is perfectly adequate for certain
AGV acoording to application.
Supervised By: Dr. H.S.Qi
Report By: Sebastian Baboni Tidikwe Page 43
Fuzzy Logic Controller for Automated Guided Vehicle
Non-Contact Detection: Same as sensors assisting truck drivers when backing, AGVs
also have familiar systems of obstacle detection where sensors based on non-contact
detection are used to provide a signal before collision occurs. This type of detection
especially important in environments involving people. The sensor system is
programmed to transmit two digital signals: upon early detection of obstacles, a
warning signal is activated, causing the AGV to steadily reduce speed and as the AGV
reaches a pre-set distance, a stop signal is triggered, bringing the AGV to a full halt.
The range of warning and stop zones is flexible to the speed of the vehicle.
Once the object moves or is removed the AGV will delay for a set period of time, and
then start in snail speed. After achieving takeoff speed and finding no obstructions, the
AGV will resume its previous travel speed.
As seen on the previous chapter, AGVs are somehow limited when it gets to obstacle
avoidance. This could be a major drawback in the technology as one of the main factors
to be considered in technology progression is safety at large. However, technology grows
in all directions and when we make ends meet we come up with better solutions to our
continuously evolving problems.
With the use of modern programming, sensors and actuators, we can improve the safety
of Automated Guided Vehicles and this chapter shows us how. In this chapter we shall
design and make a model of an automated guided vehicle that can avoid obstacles using
MATLAB Simulink.
This model can be annexed to any complete guide-path program and will override the
guide-path whenever an obstacle has been detected. Like any control system it involves
an input a processing unit and an output. These vary according to the kind of detection
and steering system used. In this case we assume the model uses infrared sensors as
inputs and differential motor steering as the form of output. As explained in the
previous section most current AGV that use non-contact obstacle detection are limited
to only two commands; stop when an obstacle is detected, and go when obstacle has
Supervised By: Dr. H.S.Qi
Report By: Sebastian Baboni Tidikwe Page 45
Fuzzy Logic Controller for Automated Guided Vehicle
passed. This provides room for improvement hence the fuzzy logic model implemented
in this project.
In order to have a functioning fuzzy logic system we need an input and a desired output.
Below is the designed Mandani model which involves two inputs, distance and angle
of the object, and two outputs, W1 and W2.
3.1. DEVELOPMENT
Infrared rangers use triangulation and a small linear CCD array to compute the
distance and/or presence of objects in the field of view. In order to triangulate, a pulse of
IR light is emitted by the emitter. The light travels out into the field of view and either
hits an object or just keeps on going. In the case of no object, the light is never reflected
and the reading shows no object. If the light reflects off an object, it returns to the
detector and creates a triangle between the point of reflection, the emitter and the
detector.
The incident angle of the reflected light varies based on the distance to the object. The
reciever portion of the IR rangers consists of a precision lens that transmits reflected
light onto various portions of the enclosed linear CCD array based on the incident angle
of the reflected light. The CCD array can then determine the incident angle and thus
calculate the distance to the object..
Unfortunately, due to the trigonometry involved in computing the distance based on the
reflected light incident angle, the output of these detectors is non-linear with respect to
the distance being measured. In other words a big change in output voltage does not
always indicate a big change in distance to an object. The graph below taken off the
Acroname website shows an
example of the analog
output voltage vs distance to
an object.
80cm) is not linear but rather somewhat logarithmic. This curve will vary slightly from detector
to detector so it is a good idea to normalise the output with a lookup table or parameterized
function, this way each detector can be calibrated to be consitent and result in data which varies
nearly linearly realtive to the distance to the object.
Notice that the output drops rapidly once the object is closer than the minimum distance (less
than 10cm) , as a result the output could be confused with a longer range reading. Such readings
can be disastrous if confused with the apparently long range reading. If this errant reading is
not handled correctly, the robot may drive full-speed into the objects. The easisets way to avoid
this is to cross fire the detectors across the width or length of the robot as shown below.
The sensor output can be linearized by plotting the analog output voltage against the
inverse of the distance of obstacle as shown below.
Using the acquired data about the IR sensor above, the Distance membership
functions can be customized to suit the Sharp IR sensor. Due to the logarithmic change
in the analog output, the gaussmf will be a suitable membership function for the sensor.
With corresponding parameters obtained from the linearized graph, assume NR to be
0cm to 40cm, MID to be 30cm to 70cm and FAR to be 60cm+. Cross-firing the sensors
will result in the sensor detection range being between 10cm and 80cm thus eliminating
interference confusion. Figure 33 shows the modified Distance membership functions.
Most Sharp IR sensors have a viewing angle that ranges between 25 and 35 so it will
be reasonable to give the sensors an average viewing angle of 30. Figure 34 below
shows the modified Angle membership functions as according to viewing angle.
Angles 0 to 35 and 145 to 180 are not included in detection range because any
obstacles that could be detected on these angles will be on the side but this project
mainly focuses on obstacles on the robot guide-path. During further development, more
sensors can be added to the system in order to detect obstacles approaching the AGV
from the sides.
Output: DC MOTOR
The output involves a differential drive configuration with two DC motors, Vl and Vr.
Since the motors have a rated voltage of 12V, the output from the inference system will
Supervised By: Dr. H.S.Qi
Report By: Sebastian Baboni Tidikwe Page 50
Fuzzy Logic Controller for Automated Guided Vehicle
be a voltage ranging from 0 to 12V and because the motors speed has a linear
relationship of speed vs voltage the trapmf is suitable for the membership function as
illustrated below.
Since the motor voltage is regarded as output of the system, a DC motor simulation has
been deemed necessary. To be able to simulate the output, it must be understood how
the DC motors convert electrical energy into mechanical energy.
Figure 24 DC motor
Above is the electrical diagram of a DC motor, its working principle lies in the Lorenz
force created as a consequence of having an electric current going through a conductor
which is placed within an external magnetic field. Following are briefly explained
equations that govern the DC motor.
(1)
(2)
(3)
(4)
From these equations it can noticed that there is a linear relationship between the
current in the winding () and the rotor torque () and there a correspondence between
the back e.m.f. ( ) and the rotor rotational speed (). The torque is exerted to accelerate
the rotor and ultimately this mechanical power will be transmitted through a gear set to
the wheel. Therefore part of the torque will cause a rotational acceleration of the rotor,
depending on its inertia, and the rest of the energy will be dissipated in the bearings
according to its viscous friction and the rotational speed. The application will require
certain reduction in order to adapt to the speed (reduced) and torque (increased) and
meet the wheel kinematics needs. Therefore the desired modelling would be:
Figure 25
Moving on to studying the gear reduction effect in more detail it is evident that not only
does it adapt the mechanical variables but it also reduces quadratically the dynamic
effect of the wheel inertial and viscous friction on the motor. These equations reveal this
idea precisely:
Once these equations are gathered, they are arranged and Laplace transformation is
applied. Working out the calculations, the outcome could be represented on the block
diagram as follows;
The input of this sub-system is the voltage of the motor (V1) and it has as outputs, the
linear speed generated by the rotation of the wheel (m/s) and its displacement (m),
which is simply its integral. The large transfer function relates the rotor torque with the
rotor speed considering the wheel dynamic influence and also the gear efficiency. For a
differential drive steering two of these subsystems will be required.
Where:
and are the linear speed of the right and left wheels, respectively.
The average speed and the rotational speed of the mobile platform can be simply
determined as;
Bearing in mind that the linear velocity is the cross product of the rotational velocity
and the distance from the turning point to the centre, in other words the turning radius
as we just need its absolute value:
Next is the modelling of all the differential drive equations in Simulink and related the
according blocks. Therefore, the centre of the robot can be tracked.
The subsystem at the bottom represents the position of the robot in function of its angle
through time.
(Raul, 2011)
3.1.2. RULES
With information flowing from left to right, from two inputs to two outputs with three
membership functions each, the result is 9 rules as shown below.
Figure 28 rules
These rules are decided using human logic and can be altered depending on ones
preference. Once decided the rules can be implemented on the rule editor and viewed on
the rule viewer as shown below.
Once the rules have been implemented the model can be imported to the workspace to
be used in Simulink to simulate the steering model. On the Simulink library is the fuzzy
logic controller block under the fuzzy logic toolbox which is used to interface the fuzzy
model into the simulation. Once in the fuzzy controller block parameters, the matrix
can be viewed by looking under the mask, figure 43 shows how it looks like.
Now that the fuzzy controller has been implemented, it can now be introduced to the
differential drive kinematic model. The diagram below shows the complete model with
inputs distance and angle as constants in the universe of their respective discourse.
In order to see the behaviour of the vehicle, scopes have been placed on points of
interest. With parameters taken off the Faulhaber website for a 2224SR009 DC motor,
the open loop dynamic model was simulated and works as expected. When
uninterrupted the car makes a complete circle which is a sign of steady state steering.
Bear in mind that this will be just a fraction of the whole AGV navigation program.
Once the obstacle has been avoided the vehicle control system will end this program and
return to following the guidepath. All parameters used in the model can be found in the
appendix.
When testing the model, inputs can be any desired constants depending on where you
assume an obstacle to be. The model was tested on three cases of different conditions as
follows;
Case 1: Assume an obstacle 40cm away (0.72V, mid-range) on the right (110), plugged
as the inputs to the system, below are the resulting output graphs;
The graphs above illustrate the voltage output from the fuzzy controller in Volts, this
voltage is then fed to the motors to produce the desired steering of the vehicle.
The results are positive as they show the differential speed of the motors, this can be
checked with any input and it works fine. The graph below shows the location of the car
on an X and Y graph.
Case 2: Assume
an obstacle 15cm away (1.65V, near) on the left (50).
Case 3: Assume an obstacle more than 80cm away (0.0V, far) on the left (50),
Notice the difference in all three cases. Case 1 demonstrates a greater turning radius to
Case 2 because of the differences in distances. The nearer the obstacle to the vehicle the
sharp the turn is expected hence the behaviour in Case 2. The direction of the turn can
also be noticed to change according to angle of obstacle. Case 3 demonstrates the
response of the vehicle when an obstacle is detected far. When left for longer the
vehicle tends to turn to the right gradually, this could be due to the controller error and
can be avoided by optimising.
This model would be most efficient for Free Range AGV Navigation Systems as they are
not required to follow a fixed path to reach their destination. For Fixed Path Navigation
Systems it might require too many modifications to the system program in order for the
obstacle avoidance to be effective as the AGV will have to leave the path to avoid the
obstacle.
5.1. CONCLUSION
In this report the automated guided vehicle has been researched and understood.
this includes historical background, applications, benefits and limitations, safety
as well as general technology
The fuzziness of the AGV was identified needed as most AGVs would only stop
when detecting a vehicle rather than avoiding it. This means if obstacle is
stagnant, AGV will have to stop until object has been moved thus slowing
production and efficiency.
The concepts of fuzzy logic had been well understood and applied to the
fuzziness in the AGV safety. Defining the relevant membership functions and
rules and finally building the fuzzy controller using MATLAB fuzzy control
toolbox according to the requirement of the system.
Once the fuzzy controller was implemented it was integrated with Simulink to
test its viability and results came positive showing a steady state cornering of the
AGV with assumed conditions.
5.2. RECOMMENDATIONS
Now that it is understood how fuzzy logic operates, there is infinite directions to take
from here. As this report only demonstrates the function of the fuzzy logic, its only a
basic stage of the fuzzy logic application. Given more time and resources, more can be
accomplished through fuzzy logic. Currently most control systems use C software to
program their control systems which also means most of the microcontrollers would
also support C rather than MATLAB. To be able to integrate the MATLAB fuzzy
logic into a C program, one needs to understand both MATLAB and C. One way to
transfer variables from MATLAB to C is by using the MATLAB coder which can be a
whole report by itself. Also C code can be generated through Kalman Filtering or the
use of MATLAB libraries in C or vice versa.
If there was work done in this project in the future, it is recommended that the program
be tested on physical applications. This includes learning and understanding MATLAB
embedded coding or the use of fuzzy logic libraries in C in order to be able to program a
microcontroller to use on a test robot. From there fuzzy logic interface can be modified
to avoid moving objects by adding more rules and membership functions that can
anticipate non stationary obstacles.
There have been numerous researches on how to optimise fuzzy logic controllers to get
the best outputs from the system, it also recommended to look into optimising the
controller once it has been proven to work on physical test robots. One way to optimise
the system would be by using rotating sensors that will be able to tell exactly where the
object is from the AGV.
For AGV users such as manufacturers with heavy and mass inventory, it is highly
recommended to have fuzzy logic obstacle avoidance systems annexed to the main
vehicle program to reduce time lost in AGVs when encountering obstacles.
2. Bandemer, H. & Gottwald, S., 1995. Fuzzy Sets, Fuzzy Logic, Fuzzy
Methods and Applications. reprint ed. England: John Wiley and
Sons.
3. Belohlavek, R. & Klir, G. J., 2011. Concepts and Fuzzy logic, s.l.:
Cambridge.
19. Nguyen, H. T. & Walker, E. A., 1997. A First Course in Fuzzy Logic.
Florida: CRC Press.
20. Nguyen, H. T. & Walker, E. A., 1997. A First Course in Fuzzy Logic.
Florida: CRC Press, p. 2.
21. Nguyen, H. T. & Walker, E. A., 1997. A First Course in Fuzzy Logic.
Florida: CRC Press, p. 3-5.
23. Ross, T. J., 2004. fuzzy logic with engineering applications. West
Sussex: john wiley and sons.
26. Xushu, W., Da, R. & Kerre, E. E., 2009. Mathematics of Fuzziness -
Basic Issues. vol 245 ed. Berlin: Springer.
27. Xushu, W., Da, R. & Kerre, E. E., 2009. Mathematics of Fuzziness -
Basic Issues. vol 245 ed. Berlin: Springer, p. 21-22.
28. Xushu, W., Da, R. & Kerre, E. E., 2009. Mathematics of Fuzziness -
Basic Issues. vol 245 ed. Berlin: Springer, p. 21.
29. Xushu, W., Da, R. & Kerre, E. E., 2009. Mathematics of Fuzziness -
Basic Issues. vol 245 ed. Berlin: Springer, p. V.
30. Xushu, W., Da, R. & Kerre, E. E., 2009. Mathematics of Fuzziness -
Basic Issues. vol 245 ed. Berlin: Springer, p. 22
7. APPENDIX
The principal aim of this report is to solve safety problems in automated guided
vehicles. Components needed for the proposed model to function are already installed in
AGVs being produced at the moment. The AGVs themselves can have long term
consequences to the environment as they use components such as batteries which
require exploitation of natural resources to be produced. Progression in this sector of
technology threatens human welfare as it replaces manual labour leaving work for only
the qualified and professionals in higher education. On the bright side, this model can
be annexed to almost any kind of automated guided vehicle with only little modification
made to the vehicle and in most cases only the control program needs to be edited,
leaving a safer working environment for human, robots and inventory.
7.3. PARAMETERS
clear
clc
Dist_wheels=0.12; %m