Fictitious Fuzzy-Magnet Concept in Solving Mobile–Robot Target Navigation, Obstacle Avoidance and Garaging Problems

A human driver can successfully execute different vehicle navigation tasks, such as: forward garaging, reverse garaging, parallel parking, diagonal parking, following a given trajectory, stopping at a given point, avoiding one or more obstacles, and the like. These processes are either too difficult to model accurately or too complex to model at all, while experienced drivers are able to successfully execute the tasks without any knowledge of the vehicle’s mathematical model, even when they switch vehicles. Existing knowledge about how such problems are solved and the ability to express this knowledge, are benefits which can be put to good use when designing controllers for wheeled mobile robot (WMR) navigation tasks. It is well known that fuzzy logic is the most effective tool for solving a problem for which there is a human solution (Zadeh, 2001), because it offers a mathematical apparatus in the background of an inaccurate, qualitative description, which projects input variables into output variables through several stages. However, describing the tasks executed by a driver in spoken language is not a simple process. When we drive a car, we rely on our driving skills and prefer to use our hands and feet, rather than our brain. It is safe to assume that compiling rules based on driver skills will not be an easy task. In view of the above, this chapter presents a new approach to the modeling of driver skills, based on a fuzzy model and an original virtual fuzzy-magnet concept. Driver experience is used to solve simple tasks (turn left or right, slow down or accelerate), while the entire problem is solved by specifying an appropriate number of fictitious fuzzy magnets and defining their tasks. Each fictitious fuzzymagnet is defined by its position and a set (or subset) of fuzzy rules which determine its action. For example, to solve a target navigation problem in open space requires only one fuzzy magnet which attracts the mobile robot to the target, while a more complex problem, such as bidirectional garaging of a mobile robot, requires two fuzzy magnets: one immediately in front of the garage and the other inside the garage. The first point is used to approach the garage and while the vehicle is entering the garage, it serves as a reference point for proper orientation, similar to human driving skills. The second point is both a target and a reference point. Compared to other algorithms which address this type of problem, the proposed algorithms are very simple; they are not based on the WMR model. The proposed fuzzy controllers are of the Takagi-Sugeno (T-S) type; they are manually 12


Introduction
A human driver can successfully execute different vehicle navigation tasks, such as: forward garaging, reverse garaging, parallel parking, diagonal parking, following a given trajectory, stopping at a given point, avoiding one or more obstacles, and the like.These processes are either too difficult to model accurately or too complex to model at all, while experienced drivers are able to successfully execute the tasks without any knowledge of the vehicle's mathematical model, even when they switch vehicles.Existing knowledge about how such problems are solved and the ability to express this knowledge, are benefits which can be put to good use when designing controllers for wheeled mobile robot (WMR) navigation tasks.It is well known that fuzzy logic is the most effective tool for solving a problem for which there is a human solution (Zadeh, 2001), because it offers a mathematical apparatus in the background of an inaccurate, qualitative description, which projects input variables into output variables through several stages.However, describing the tasks executed by a driver in spoken language is not a simple process.When we drive a car, we rely on our driving skills and prefer to use our hands and feet, rather than our brain.It is safe to assume that compiling rules based on driver skills will not be an easy task.In view of the above, this chapter presents a new approach to the modeling of driver skills, based on a fuzzy model and an original virtual fuzzy-magnet concept.Driver experience is used to solve simple tasks (turn left or right, slow down or accelerate), while the entire problem is solved by specifying an appropriate number of fictitious fuzzy magnets and defining their tasks.Each fictitious fuzzy magnet is defined by its position and a set (or subset) of fuzzy rules which determine its action.For example, to solve a target navigation problem in open space requires only one fuzzy magnet which attracts the mobile robot to the target, while a more complex problem, such as bidirectional garaging of a mobile robot, requires two fuzzy magnets: one immediately in front of the garage and the other inside the garage.The first point is used to approach the garage and while the vehicle is entering the garage, it serves as a reference point for proper orientation, similar to human driving skills.The second point is both a target and a reference point.Compared to other algorithms which address this type of problem, the proposed algorithms are very simple; they are not based on the WMR model.The proposed fuzzy controllers are of the Takagi-Sugeno (T-S) type; they are manually generated (in a manner similar to human driving skills), and have clearly-defined physical parameters.The first section of this chapter describes the fictitious fuzzy-magnet concept and its application in solving target navigation problems in an obstacle-free environment.It further analyzes the application of a pair of fuzzy magnets in solving a garaging problem involving a differential-drive mobile robot.The fictitious fuzzy magnet concept allows navigation to the target in a single maneuver, without changing the direction of WMR travel.The symmetry of the differential-drive WMR is utilized fully, such that the algorithm provides a bidirectional solution to the WMR garaging problem.The robot is automatically parked from the end of the robot that is closer to the garage entrance.The algorithm can be applied when the control variable is of the discrete type and where there are relatively few quantization levels.The efficiency and shortfalls of the proposed algorithm are analyzed by means of both detailed simulations and multiple re-runs of a real experiment.Special attention is devoted to the analysis of different initial robot configurations and the effect of an error in the estimation of the current position of the robot on garaging efficiency.The third section of this chapter analyzes the possibility of applying the fictitious fuzzy-magnet concept to navigate a mobile robot to a target in a workspace which contains one or more obstacles.At the preprocessing stage, the left and right side of the obstacle in the robot's line of sight are determined based on the mutual positions of the robot and the obstacle.Since controller inputs are based on the relative dimensions of the obstacle, the controller can be applied to obstacles of different shapes and sizes.Following the design of the above-described controllers, and the successful testing of navigation efficiency to the goal in a workspace which includes a single stationary obstacle, the algorithm was applied, without modification, to avoid an obstacle moving along a straight line at a constant speed equal to one-third of the maximum speed of the robot.Here the proposed algorithm demonstrated limited efficiency.The final section of the chapter proposes a method for a simple but efficient generalization of the algorithm to support a group of obstacles, using parallel data processing, illustrated by several computer simulations of WMR navigation to the target point through a group of obstacles.The disadvantages of the proposed algorithm when applied in complex environments are discussed at the end of the chapter.

Fictitious fuzzy magnets concept
A given point A(x A , y A ), is assumed to be in the Cartesian coordinate system and to represent the position of the fictitious fuzzy magnet FM.The FM is defined as an arranged pair comprised of its position A and an added sub-set of fuzzy rules, FRsS (Fuzzy Rules subSet): The FRsS enables the determination of the zone of influence of the fuzzy magnet, as well as the definition of the action it causes.To establish the structure of the fuzzy rules, it is necessary to adopt input and output variables (i.e., premise variables and conclusion variables).Figure 1 shows the position of the WMR relative to the point A, which represents the position of the fictitious fuzzy magnet, FM.
Point (x R , y R ) is the center of the WMR, and its orientation relative to the x axis is denoted by θ R , such that the configuration of the WMR q R is unequivocally defined by three coordinates: q R (x R , y R , θ R ).The bold line denotes the front end of the robot.The angle formed by the 1.Mutual spatial positions of wheeled mobile robot and fictitious fuzzy magnet.longitudinal line of symmetry of the WMR, S R , and the segment which connects the points (x R , y R ) and A is denoted by α A .If the coordinates of the WMR center are denoted by (x R (k), y R (k)) at the sample time k, the distance between the WMR and the fictitious fuzzy magnet, d A (k), is: (2) The position of the WMR at the sample time k, relative to the point A, is unequivocally determined by its orientation relative to the point A -angle α A (k) and the distance d A (k), which will be adopted as input variables of the FRsS.In the general case, we will state that the output velocity variables are v 1 and v 2 .The FRsS of r rules for the discrete T-S fuzzy system is defined as: where d A (k) and α A (k) are premise variables.The membership function which corresponds to the i th control rule and the j th premise variable is denoted by µ ij , and C ij are constants.System outputs are v 1 (k) and v 2 (k), obtained from: where As is well known, the control of a differential drive mobile robot can be designed in two ways: using the speed of the left and right wheels, or using the linear and angular velocities of the robot.Consequently, the general definition of the FRsS can be written more precisely in two ways.The navigation of a differential drive mobile robot was designed in (Mitrović & Ðurović, 2010a) based on wheel speed control, such that the output variables of the FRsS are the speed of the left wheelv L and the speed of the right wheelv R , such that (3-4) become:

237
Fictitious Fuzzy-Magnet Concept in Solving Mobile-Robot Target Navigation, Obstacle Avoidance and Garaging Problems while in (Mitrović & Ðurović, 2010b) the output variables of the FRsS are linear and angular velocities of the robot v R and ω R , and in this case (3-4), can be written as:

Navigation in an obstacle-free environment
The application of the proposed concept will be illustrated by an example involving WMR navigation to a target in an obstacle-free environment.The WMR configuration (x R , y R , θ R ) and the target position (x A , y A ) are shown in Fig. 1.We will assume the robot control inputs (v R , ω R ) to be the outputs of the fuzzy logic controller for navigation in an obstacle free environment (FLC OFE ).The WMR angle relative to the target α A and the distance to the target d A are fuzzy controller inputs, and the corresponding membership functions are shown in Fig. 2. The linguistic variable α A is defined through the following membership functions: Back, Right}  (9)   or abbreviated as: FL, FR, B, BL, BR}  (10)   as shown in Figure 2(b).In order to enable bidirectional navigation, the variable α A is strictly divided into two groups -the angles related to orientation at the front {F, FL, FR}, and the angles related to orientation at the rear {B, BL, BR}.The method proposed in this chapter analyzes mobile objects with an equal ability of maneuvering by front and rear pace; therefore, the objective of defined membership functions and fuzzy rules is to provide identical performance in both cases.For this reason, the membership function B (Back)i s divided into two sub-functions B ′ and B ′′ , in the following manner: where S represents the operator of S − norm, which corresponds to the fact that the union of sets B ′ and B ′′ produces set B. Since the sets B ′ and B ′′ are disjunctive, the calculation of S − norm is not important (Mitrović & Ðurović, 2010a).
The distance-to-target linguistic variable d A is described by means of a single membership functionnear (Fig. 2(a)), and its task is to stop the WMR in close proximity to the target.This is ensured by adjustment of free parameters c 1 and c 2 .The designed FLC is of the T-S type, with two inputs: the distance between the robot and the targetd A and the orientation of the robot relative to the targetα A , and two outputs: linear velocity v R and angular velocity ω R of the robot.The fuzzy controller rules for robot navigation to the target in an obstacle-free environment are shown in Table 1.
Table 1.Fuzzy Logic Controller for navigation in an Obstacle-Free Environment (FLC OFE )fuzzy rules base.
The maximum linear velocity of the analyzed robot is V m = 0.5 m/s and its maximum angular velocity is ω m = 7.14 rad/s.The approximate dynamic model of a mobile robot (Mitrović, 2006) was used for the simulations, and the distance between robot wheels was 7 cm.Figure 3 shows WMR trajectories to the target (coordinate origin), from three initial configurations.
Figure 4 shows controller outputs for the navigation scenarios depicted in Fig. 3.It is apparent from Fig. 4 that during navigation, one of the controller outputs assumes maximum values and this reduces the duration of the navigation process.

Bidirectional garage parking
The WMR garage parking (garaging) problem can also be viewed as a navigation problem in an environment with an obstacle, where the garage is the obstacle of a specific shape, but is also the target.When navigation problems with obstacles are solved, the goal is to achieve the ultimate configuration without colliding with the obstacle, which involves obstacle avoidance.Numerous obstacle avoidance and mobile robot navigation methods are discussed in literature.The potential field method, originally proposed by Khatib (1986) for obstacle avoidance in real-time by manipulators and mobile robots, plays a major role in solving this type of problem.A robot is navigated in a potential field which represents the sum of attractive forces originating from the target, and repulsive forces originating from the obstacles, while the analytical solution is the negative gradient of a potential function.
Additionally, the resulting potential field may contain local minima where navigation ends without reaching the target, which is the greatest disadvantage of this method (Koren & Borenstein, 1991) [m] q A (0.5, 0, π/2) q B (0, 0.2, π/12) q C (0.3, 0.3, −π/3) Fig. 3. Robot navigation trajectories from three initial postures (x R , y R , θ R ) to the target (0, 0). are deployed in such a way that they form a concave U barrier, such that the algorithm enters into an infinite loop or halts at the local minimum (Krishna & Kalra, 2001;Motlagh et al., 2009).Since the garage is a concave obstacle, the main shortfall of the potential field method could also be a solution to the garaging problem; however, analyzed literature does not provide an example of the use of the potential field method to solve mobile robot garaging problems.A probable reason for this is that the goal of garaging is to reach the target configuration in a controlled manner, with limited deviations, while the completion of navigation at the local minimum of the potential field is accompanied by oscillatory behavior of the object being parked, or the entry into an infinite loop (Koren & Borenstein, 1991), which is certainly not a desirable conclusion of the process.The garaging/parking problem implies that a mobile robot is guided from an initial configuration (x R(0) , y R(0) , θ R(0) ) to a desired one (x G , y G , θ G ), such that it does not collide with the garage.Figure 5 shows the garage and robot parameters; the position of the garage is defined by the coordinates of its center -C m , while its orientation is defined by the angle of the axis of symmetry of the garage -S G relative to the x axis, identified as β in the figure.
The width of the garage is denoted by W G and the length by L G , and it is understood that garage dimensions enable the garaging of the observed object.The implication is that the goal (x G , y G ) is inside the garage and is set to coincide with the center of the garage C m , such that C m (x G , y G ).In the case of bidirectional garaging, the targeted configuration is not uniquely defined because the objective is for the longitudinal axis of symmetry of the robot to coincide with that of the garage, such that δ = 0o rδ = π, meaning that there are two solutions for the angle For reasons of efficiency, the choice between these two possibilities should provide the shortest travel distance of the mobile robot.The controller proposed in this section does not require a priori setting of the angle θ G , because it has been designed in such a way that the mobile robot initiates the garaging process from the end closer to the garage.The bidirectional garaging problem is similar to the stabilization problem, also known as the "parking problem", formulated by Oriolo et al. (2002): "the robot must reach a desired configuration q G (x G , y G , θ G ) starting from a given initial configuration q (0) (x R(0) , y R(0) , θ R(0) )".The differences are that there are two solutions for the desired configuration in bidirectional garaging problems and that the stabilization problem need not necessarily involve constrains imposed by the presence of the garage.
Although the bidirectional garaging problem is addressed in this chapter as a stabilization problem, the proposed solution can also be used as a garaging trajectory generator because it includes non-holonomic constraints of the mobile robot.

System of two fictitious fuzzy magnets
From a human control skill perspective, the garaging of a vehicle is comprised of at least two stages: approach to the garage and entry into the garage.The adjustment of the vehicle's position inside the garage might be the third stage, but the need for this stage depends on the success of the second stage (i.e., driver skills).Since there is much less experience in differential drive mobile vehicle control than in car and car-like mobile robot control, and based on recommendations in (Sugeno & Nishida, 1985), the proposed WMR garaging system is a model of operator control actions, designed by means of two fictitious fuzzy magnets, one of which is located immediately in front of the garage and the other inside the garage.The first point is used to approach the garage and while the vehicle is entering the garage, it serves as a reference point for proper orientation, similar to human driving skills.The second point

241
Fictitious Fuzzy-Magnet Concept in Solving Mobile-Robot Target Navigation, Obstacle Avoidance and Garaging Problems www.intechopen.com is both the target and a reference point for the WMR when it enters the garage and when it completes the garaging process.Contrary to the well-known point-to-point navigation approach, navigation aided by a system of two fuzzy magnets is executed in a single stage since the garaging process requires the robot to approach the area in front of the garage, but not to also reach the point which is the center of this area.The fictitious fuzzy magnets are denoted by FM Fm (Forward magnet) and FM Cm (Central magnet), and created according to (1): In Fig. 6, their positions are denoted by C m and F m .The point F m lies on the garage axis of symmetry S G at a distance d F from the front line.Let us imagine that these points are fictitious fuzzy magnets with attraction regions around them and if the mobile object/vehicle finds itself in that region, the attraction force will act on it.The activity of these fictitious fuzzy magnets will be neutralized in point C m , thus finishing the garaging process.The implementation of this concept requires the definition of the interaction between the fictitious fuzzy magnets and the vehicle, consistent with the definition of the fictitious fuzzy magnets.Figure 6 also shows the parameters which define the relationship between the fictitious fuzzy magnets and the vehicle.The orientation of the WMR relative to the point F m is denoted by α Fm , and relative to the point C m by α Cm .The distance between the WMR and the fictitious fuzzy magnet C m is d Cm , while the distance to the fictitious magnet F m is d Fm .The key step in the design of such an approach is the observation of these two distances as fuzzy sets which need to be attributed appropriate membership functions.The first task of the FM Fm is to guide the WMR to the area immediately in front of the garage, such that the linguistic variable d Fm is assigned a single membership function, denoted by farin Fig. 7(a).The membership function was not assigned to the linguistic variable µ far (d Fm ) in the standard manner because the entire universe of discourse is not covered (since F 1 > 0).This practically means that FM Fm will have no effect on the robot when d Fm < F 1 , but FM Cm will; the membership function for the distance to its position C m is shown in Fig. 7  of attraction of at least one fictitious fuzzy magnet at all times.A more detailed procedure for the selection of parameters and fuzzy rules will be presented later in the text.The next step in the definition of fuzzy rules subsets is the definition of the second input variable, associated with the WMR orientation relative to the fictitious fuzzy magnets.The angles are denoted by α Fm and α Cm in Fig. 6.If angle α Fm is close to zero, then the vehicle's front end is oriented toward the fictitious fuzzy magnet F m , and if the value of angle α Fm is close to π, the vehicle's rear end is oriented toward F m .This fact is important, as will be shown later in the text, from the perspective that the objective of vehicle control will be to reduce the angles α Fm and α Cm to a zero or π level, depending on initial positioning conditions.Linguistic variables α Fm and α Cm are together identified as Direction and are described by membership functions which should point to the orientation of the WMR relative to the fictitious fuzzy magnets according to ( 9) and ( 10), whose form is shown in Fig. 8.

Definition of fuzzy rules
Since the WMR bidirectional garaging system is comprised of two fictitious fuzzy magnets, FM F m and FM C m , the fuzzy rules base is created from the rules subsets of each fuzzy magnet.It follows from the definition of the concept (3) that a fuzzy rules subset is determined by two inputs (WMR distance and orientation relative to fuzzy magnet position), meaning that the number of fuzzy controller inputs is equal to K × 2, where K is the number of fuzzy magnets which make up the system, such that the number of inputs into a fuzzy system comprised of two fuzzy magnets is four.This concept is convenient because inherence rules for each fuzzy magnet are generated from inputs related to that magnet, such that the addition of a fuzzy magnet increases the number of rules in the controller base only in its subset of fuzzy rules.We will now specifically define two fuzzy rules subsets, FRsS F m and FRsS C m .Since the 243 Fictitious Fuzzy-Magnet Concept in Solving Mobile-Robot Target Navigation, Obstacle Avoidance and Garaging Problems www.intechopen.comfuzzy rules subsets are created for the same object, the output variables are defined equally, regardless of whether concept (5-6) or (7-8) is applied.The definition of output variables of the FLC requires a clear definition of the object of control.The algorithm described in this chapter is primarily intended for the control of two-wheeled, differential drive mobile robots.The wheels of this type of vehicle are excited independently and their speeds are defined autonomously.Guidance is controlled by the wheel speed difference, and the fuzzy rules subsets will be generated in the form of (5-6).We will assume that the physical characteristics of the actuators of both wheels are identical, and that the object has identical front-and back-drive capabilities.Since the inherence rules will be defined in general, we will assume certain general characteristics of the object of control, which will not affect the practical application of the concept.The maximum wheel speed will be denoted by the positive constant V m , where −V m means that the wheel is rotating at maximum velocity which induces the object to move in reverse.We will also assume a nonnegative constant V 1 , which satisfies the condition: Fuzzy rules are defined based on the following principles (Mitrović & Ðurović, 2010a): • As the distance from the vehicle to the garage grows, the total speed of the vehicle should increase; • As the distance from the vehicle to the garage shrinks, the total speed of the vehicle should drop; • The difference between the wheel speeds causes turning, which must depend on the robot's orientation toward the garage; • In the case of good orientation, the robot speed may be maximal.We will identify the fuzzy logic controller for bidirectional garaging using the fictitious fuzzy magnet concept as FLC BG .The fuzzy rules base of the FLC BG is comprised of two subsets: the FRsS Fm subset, which corresponds to the fictitious fuzzy magnet FM Fm , shown in   2), an action which results in a considerable reduction in the number of rules.The rule which produces zero commands on both wheels does not exist; this might lead to the wrong conclusion that the vehicle never stops and does not take a final position.Since the points C m and F m are on the garage axis of symmetry, when the vehicle finds itself near its final position the difference between orientation angles α Fm and α Cm is close to ±π.In this case, at least two rules generating opposite commands are activated, and their influence becomes annulled (Mitrović & Ðurović, 2010a).

Selection of fuzzy controller parameters
However, with regard to the endless set of possible combinations of input variables, the selection of fuzzy rules does not guarantee that the vehicle will stop at the desired position.
It is therefore, necessary to pay close attention to the selection of parameters d F , M, N, F 1 , F2, C 1 , C 2 , C 3 , and C 4 .
3.3.1 Parameter d F FM Fm is described by ( 12) and, before the parameters which define the membership functions of the linguistic variables of FRsS Fm are determined, the position F m of FM Fm needs to be established.In Fig. 6, the point F m is located on the longitudinal axis of symmetry of the garage and its distance from the garage door is d F .The parameter d F should be adopted in the first iteration, observing the following limitation: where W R is the robot width, and L R is the robot length, with the recommendation d F ≈ W R .

Parameters M and N
The selection of parameters M and N, in their geometrical sense as presented in Fig. 8, influences the nature of the maneuver (curve and speed of turning) performed by the vehicle during garaging, especially at the beginning of the garaging process when the robot is at some distance from the garage.When the values of M and N are low, the vehicle rotates with a very small curve diameter; as these values increase, the arches circumscribed by the vehicle also increase (Mitrović & Ðurović, 2010a).During the selection of these values, a compromise must be made to maintain the maneuvering capabilities of the vehicle, as well as the constraints imposed by geometry, namely, the ratio between the vehicle dimensions and the width of the garage.Generally, these parameters are adjusted in such a way that the vehicle circumscribes larger arches when distant from the garage, whereas more vivid maneuvers are needed in the vicinity of the garage.As such, in the second iteration, parameters M and N related to input α Fm are adjusted, followed by those related to the input α Cm , with the following constraints:  within this region, the distance between the robot and the point F m , which was earlier denoted by d Fm is greater than F 2 and µ far (d F m > F 2 )=1, as shown in Fig. 7(a).
The coefficients C 1 and C 2 (Fig. 7(b)) should initially be set at C 1 = 1 and C 2 = 0. Figure 9(b) illustrates the activity of FM Cm .Outside the circle of radius C 4 , whose center is at C m , the activity of this fuzzy magnet is equal to zero (i.e., µ near (d Cm > C 4 )=0).The activity of FM Cm increases as the robot approaches the point C m , through to the edge of the circle of radius C 3 , within which the activity of this fuzzy magnet is maximal (i.e., µ near (d Cm ≤ C 3 )=1), shown in dark gray in the figure).To ensure that at least one fuzzy magnet is active at any point in time, the following constraint must strictly be observed: This constraint ensures that the circle of radius F 1 is included in the circle of radius C 4 , which practically means that the vehicle is within the region of attraction of at least one fuzzy magnet at all times.The dominant impact on vehicle garaging is obtained by overlapping fictitious fuzzy magnet attraction regions, and proper vehicle garaging is achieved through the adjustment of the region in which both fictitious fuzzy magnets are active.

Coefficients C 1 and C 2
The selection of the above parameters might enable vehicle stopping near point C m .The simultaneous adjustment of the garaging path and stopping at the target position, due to a large number of free parameters, requires a compromise which may have a considerable impact on the quality of the controller.The introduction of parameters C 1 and C 2 enables unharnessed adjustment of vehicle stopping.The selection of parameters C 1 and C 2 , enabled by theoretically exact stopping of vehicles at point C m , will cause oscillations in movement around point C m due to the dynamics of the vehicle, a factor which was neglected in the process of controller design.Accordingly, the selected desired final point of garaging is in the immediate vicinity of the fictitious magnet C m location.Coefficients C 1 and C 2 take into account the neglected dynamics of the vehicle, and their adjustment is performed experimentally, observing the following constraints: The above relation ensures that at least two opposed rule-generating commands are always activated around the point C m .If the variable d Fm assumes a value larger than L G /2 + d F , meaning that the vehicle has practically surpassed the target point, the angles α Cm and α Fm will become nearly equal, and results in the activation of rules that generate commands of the same sign, which in turn causes oscillations around the point C m .

Simulation results
An approximate dynamic model of the Hemisson robot (Mitrović, 2006) was used for the simulations.This is a mobile vehicle of symmetrical shape, with two wheels and a differential drive.Wheels are independently excited, and their speeds may be defined independently from each other.Guidance is controlled by the difference in wheel speeds.Each of these speeds can be set as one of the integer values in the interval [−9, 9], (Table 3), where a negative value means a change in the direction of wheel rotation.The dependence of the command on wheel speed is not exactly linear causing certain additional problems in the process of vehicle control (Mišković et al., 2002).Specifically, for the subject case, the selected output variables of the FLC are the speed commands of the left and right wheels: VL and VR, respectively.Accordingly, this discrete set of integer values from the interval [−9, 9] is selected as the domain of membership functions attributed to the output variables.The sampling period of the FLC was T s = 0.2 s.The size of the garage was 16 cm × 20 cm, and the size of the robot was 10 cm × 12 cm.The FLC BG was designed to conform to the constraints defined in the previous section, with the objective of ensuring successful garaging.The experimentally-determined values of these parameters, for the examined case of the Hemisson robot, are presented in Table 4.

Wheel Speed
Figure 10 shows WMR garaging trajectories for a set of 17 different initial conditions.Depending on the initial configuration, the WMR is guided to the target by forward or back drive, which illustrates the bidirectional feature of the proposed fictitious fuzzy magnets concept.To test the efficiency and applicability of the proposed method using an extended set of initial configurations, a new test set of N initial conditions was created.This set of initial configurations (x Ri,(t=0) , y Ri,(t=0) , and θ Ri,(t=0) ), i = 1:N, was formed such that the robot is placed at equidistant points on the x and y axes spaced 1 cm apart, while the angle θ Ri,(t=0) was a uniform-distribution random variable in the interval [−π/2, π/2].The test configuration set was divided into two sub-sets: the first satisfies the condition that the robot in its initial configuration is at an adequate distance from the garage and contains N d elements, while the other includes initial configurations near the garage and contains N c = N − N d elements.Garaging performance was measured by the distance of the robot from the target position d Cm (Fig. 6), and the angle δ (Fig. 5), which showed that the robot and garage axes of symmetry did not coincide: The results of simulations with the FLC BG , for the set of initial conditions N d , are shown in Fig. 11.In all N d cases, the garaging process was completed with no collision occurring between the robot and the garage.In view of the non-linear setting of the speeds and the long sampling period, the conclusion is that the results of garaging were satisfactory.The average deviation in N d cases was d Cm = 1.1 cm, while the average angle error was δ = 1.4

Robustness of the system
Since the system was designed for use with a real vehicle, its efficiency needed to be examined under less-than-ideal conditions.To operate the system, the positions and orientations of the robot for each selection period must be determined, whereby the robot position and orientation need not necessarily coincide with the real position and orientation.Since inputs into the system consist of two distances and two angles whose accuracy depends directly on the accuracy of the determination of the position of the robot during the garaging process, the effect of inaccuracies of the vehicle coordinates on the efficiency of the garaging process were analyzed.The set of experiments was repeated for the FLC BG with N d initial conditions, and the WMR coordinate determination error was modeled by noise with uniform distribution within the range [−1 cm, 1 cm].Figure 12 shows histograms of distance and orientation deviations from the targeted configuration, under the conditions of simulated sensor noise.It was found that the system retained its functionality but that the deviations were greater than those seen in the experiment illustrated in Fig. 11.Table 5 shows extreme and mean values derived from the garaging experiments.The subscript N denotes that the simulations were conducted under simulated sensor noise conditions.The sensor noise mostly affected the maximum distances from the target position d Cm max ; the mean values of angle error δ were unexpectedly lower under simulated sensor noise conditions.

Limitations of the proposed FLC
Simulations were conducted for the sub-set N c of initial conditions, under which the robot was not at a sufficient distance from the garage and was placed at the points of an equidistant grid, spaced 0.25 cm apart, where the initial orientation of the robot θ Ri,(t=0) was a uniform-distribution random variable in the interval [−π/2, π/2].Figure 13 shows the regions of initial conditions where the probability of collision of the robot with the garage is greater than zero.Full lines identify the limits of the region under ideal conditions, while dotted lines denote simulated sensor noise conditions.Figure 13 shows that sensor noise has little effect on the restricted area of initial conditions, which is an indicator of the robustness of the system to sensor noise.13.Limits of the system -region of initial configurations with probable collision of the WMR with the garage: full line -ideal conditions (FLC BG ); dotted line -with sensor noise conditions (FLC BG N ).

Experimental results
An analogous experiment was performed with a real mobile vehicle (Hemisson mobile robot) and a real garage whose dimensions are 16 cm × 20 cm.A block diagram of the garaging experiment is shown in Fig. 14.A personal computer with a Bluetooth interface (D) and web camera (F) -resolution 640 × 480 pixels, were used during the experiment.The initial conditions were determined prior to the initiation of the garaging process, namely (A): the position and orientation of the garage q G , and the posture (position and orientation) of the robot q R(t=0) .Based on the posture of the robot and the position and orientation of the garage, in block (B), input variables d Cm , d Fm , α Cm and α Fm were calculated for the FLC BG (C).FLC outputs were wheel speed commands for the Hemisson robot (VL and VR), which were issued to the robot via the Bluetooth interface.The web camera performed a successive acquisition of frames in real time, with a 0.2 s repetition time, which dictated the sampling period for the entire fuzzy controller.In block (G), web camera frames were used to estimate the position of the robot and compute its orientation (Ðurović & Kovačević, 1995;Kovačević et al., 1992).During the garaging process, wheel speed commands were different from zero.When both commands became equal to zero, garaging was completed and block (H) halted the execution of the algorithm.Figures 15(a) and 15(b) show 12 typical trajectories obtained during the process of garaging of a Hemisson robot in a real experiment.The illustrative trajectories shown in Fig. 15(a) deviate from expected trajectories and are mildly oscillatory in nature, which is a result of robot wheel eccentricity and the ultimate resolution of the camera used to estimate the position and orientation of the robot.The system which tracks the WMR to the target can be upgraded by a non-linear algorithm (Ðurović & Kovačević, 2008) or instantaneous acquisition by two sensors (Ðurović et al., 2009).Figure 15(b) shows trajectories obtained during the course of garaging from "difficult" initial positions (initial angle between the axis of symmetry of the robot and the axis of symmetry of the garage near π/2 ).These trajectories were obtained 251 Fictitious Fuzzy-Magnet Concept in Solving Mobile-Robot Target Navigation, Obstacle Avoidance and Garaging Problems www.intechopen.comequally under front-and back-drive conditions (the front of the robot is identified by a thicker line).All of the illustrated trajectories are indicative of good performance of the proposed garaging algorithm.

Obstacle avoidance
The navigation of a mobile robot in a workspace with obstacles is a current problem which has been extensively researched over the past few decades.Depending on the definition of the problem, the literature offers several approaches based on different methodologies.Relative to the environment, these approaches can be classified depending on whether the vehicle moves in a known (Kermiche et al., 2006), partially known (Rusu et al., 2003), or totally unknown environment (Pradhan et al., 2009).Further, the environment can be stationary or dynamicwith moving obstacles (Hui & Pratihar, 2009), or a moving target (Glasius et al., 1995).With regard to the ultimate target, the mobile robot is navigated to a given point (Mitrović et al., 2009), or a given configuration -a point and a given orientation at that point (Mitrović& Ðurović, 2010a), or navigated to reach and follow a given trajectory (Tanaka & Sano, 1995).The problems are solved both in real-time and off-line.
Numerous obstacle avoidance methods are discussed in literature.The potential field method (Khatib, 1986) plays a major role in solving this type of problem.The potential function has to be derived for each individual obstacle and this can be a drawback from a real-time perspective if there are a large number of obstacles.Additionally, the resulting potential field may contain local minima where navigation ends without reaching the goal (Koren & Borenstein, 1991).Fuzzy-logic-based controllers are widely applied to address obstacle avoidance and mobile robot navigation problems, and they range from reactive fuzzy controllers (which do not include a planning stage and generate outputs based on real-time sensor signals) to controllers which resolve the trajectory planning problem of a WMR through the synthesis of fuzzy logic with genetic algorithms, neural networks, or the potential field approach.Reignier (1994) proposed a reactive FLC for WMR navigation through a workspace with obstacles, based on data from 24 ultrasonic sensors.Abdessemed et al. (2004) proposed a reactive controller inspired by the potential field method, with a rule base optimized by evolutionary techniques.Hui & Pratihar (2009) compared the potential field method with soft computing methods used to solve moving obstacle avoidance problems.This section proposes a new methodology for robot navigation in a workspace which contains one or more obstacles.The approach is based on the fictitious fuzzy magnet concept but, contrary to the system described in the previous section, the rules are generated such that the action of the fuzzy magnet is to repel the vehicle.It should be noted that the inputs into the controller based on the fuzzy magnet concept are the distance and orientation relative to the fuzzy magnet position, which is a point, while the obstacles have dimensions which must be taken into account at the controller design stage.The controller proposed in this section uses information about the relative dimensions of the obstacle.At the preprocessing stage, the left and right side of the obstacle in the robot's line of sight are determined based on the mutual positions of the robot and the obstacle.Since controller inputs are based on the relative dimensions of the obstacle, the controller can be applied to obstacles of different shapes and sizes.

Navigation in a single-obstacle environment
In general, WMR navigation to a target in a workspace with obstacles is comprised of two tasks: avoidance of obstacles and navigation to the target.The controller may be designed to integrate these two tasks, or the tasks can be performed independently but in parallel.Parallel processing of target and obstacle data, contrary to integrated approaches, offers a number of advantages, ranging from fewer FLC inputs to parallel distribute compensation discussed by Wang et al. (1996).To allow for the algorithm to be used for navigation in an environment which contains an unknown number of obstacles, the parallel fuzzy controller data processing approach was selected.The FLC OFE controller discussed in Section 2.1 was used to execute a navigation task to a target in an obstacle-free environment.Instead of v R and ω R , in this section its outputs will be denoted by v OFE and ω OFE , respectively, since notations with R are reserved for outputs from the entire navigation system.Variables which will reflect the mutual positions of the robot and the obstacle need to be defined and efficient navigation in real-time enabled, regardless of the position and size of the obstacle relative to the target and the current configuration of the robot.Figure 16 shows the WMR and obstacle parameters.Since we address the WMR navigation problem in planar form, we will assume that the obstacle in the robot's workspace is a circle defined by its center coordinates and radius: O(x O , y O , r O ). Figure 16 shows a real obstacle whose radius is r r ,i n light gray.Because of the finite dimensions of the robot, it is extended by a circular ring of width r cl (dark gray).Hereafter we will use r O for the radius of the obstacle, computed from the equation: In Fig. 16, the distance between the WMR center and the obstacle is denoted by d RO .Point P C lies at the intersection of the WMR course line and the obstacle's radius which form a right angle and represent a virtual collision point.When this intersection is an empty set, the obstacle does not lie on the WMR trajectory and point P C is not defined.The portion of the radius which is located to the left of the point P C relative to the WMR is denoted by l L , while the portion of the radius to the right of P C is denoted by l R .We will use variables l L and l R to define the obstacle avoidance algorithm.Since l L and l R are dimensional lengths and since

253
Fictitious Fuzzy-Magnet Concept in Solving Mobile-Robot Target Navigation, Obstacle Avoidance and Garaging Problems www.intechopen.comtheir values depend on the WMR position and obstacle dimensions, we will normalize them based on the equation: where L L and L R are the left and right side of the obstacle, respectively, and can assume values from the interval [0, 1], regardless of obstacle dimensions, since L L + L R = 1.If L L or L R is equal to 1, the robot will follow a course which will bypass the obstacle.If point P C is not defined, we will assume that L L and L R are equal to zero, meaning that the obstacle does not lie on the robot's course.Based on the position of the virtual collision point P C and the linear velocity of the robot v R , we will generate the obstacle avoidance controller input using: The variable Side provides information about the position of the obstacle relative to the robot and is equal to zero if the obstacle does not lie on the robot's course.The corresponding membership functions are shown in Fig. 17(a).In the name of the membership function, subscript B stands for Backward and F for Forward.To ensure efficient bypassing of the obstacle, in addition to the position of the obstacle relative to the WMR, the controller has to be provided with the distance between the WMR and the obstacle, denoted by d RO in Fig. 16, whose membership functions are shown in Fig. 17(b).The outputs of the obstacle avoidance controller are the linear velocity v OA and the angular velocity ω OA of the robot.The respective fuzzy rules are shown in Table 6.FLC OA -fuzzy rules base.
from the following relation: To decrease the duration of the navigation process, the controller output v R was post-processed to ensure maximum linear velocity v Rmax of the robot based on (Mitrović& Ðurović, 2010b): where D is the distance between the robot wheels.The maximum linear velocity of the robot is a function of the angular velocity ω R and the physical constraints of the robot.Figure 18 illustrates the trajectories followed by the WMR to avoid two obstacles: O 1 (−0.4,0, 0.15) and O 2 (0.3, 0.1, 0.05), from four initial positions: q A (−0.8, 0, π), q B (−0.7, 0.2, π/4), q C (0.45, 0.25, 0), and q D (0.6, 0.2, −2π/3).

Moving obstacle avoidance
The proposed algorithm, without modification, was applied in a single moving obstacle avoidance scenario.It was assumed that the obstacle travels along a straight line at a constant speed v obs , which is equal to one-third of the maximum speed of the robot.The outcome was successful when the robot overtook or directly passed by the obstacle.However, if it attempted to pass by at an angle, the robot collided with the obstacle.This was as expected, since the controller does not take the speed of the obstacle into account.Figure 19 illustrates the scenarios in which the robot overtakes, directly passes by, and meets with the moving obstacle at an angle.

255
Fuzzy-Magnet Concept in Solving Mobile-Robot Target Navigation, Obstacle Avoidance and Garaging Problems [ m] Fig. 19.Avoidance of moving obstacles: S I -overtaking, S II -directly passing, S III -meeting at an angle.

Navigation trough a group of obstacles
We will now address the scenario in which there is a group of N obstacles in the workspace of the robot, where N > 1.To benefit from the approach described in the previous section, we will use the single-obstacle FLC OA for each individual obstacle and thus obtain N values for the robot's linear and angular velocities.We will then compute the final angular velocity from the following equation: where ω OAk is the FLC OA output for the k th obstacle and d ROk is the distance between the robot and the k th obstacle.As the distance from the vehicle to the k th obstacle shrinks, its influence to the controller outputs should increase.Using the coefficient C k , we will take into account only those obstacles which lie on the robot's course.It is computed using (25), as

256
Recent Advances in Mobile Robotics www.intechopen.comfollows: We will derive the speed for the system of N obstacle avoidance controllers in a manner similar to (28), from: where v OAk is the FLC OA output for the k th obstacle.Outputs from the system of NF L C OA and FLC OFE controllers are integrated by means of ( 26), and the speed of the robot is maximized based on (27).Figure 20 shows a scenario with several randomly-distributed obstacles.Initial positions and the target (coordinate origin) are beyond the obstacle area.
It is apparent from the figure that the proposed methodology efficiently solves the problem of navigation through an area which includes obstacles.

Constraints of the system
Although the positions of the obstacles and the target are known, a closer analysis of the proposed approach leads to the conclusion that navigation to the target takes place in an unknown environment.The position of the target is known in all of the illustrated scenarios, but obstacles are taken into account only after they have triggered appropriate FLC rules, that is, when the distance between the robot and the obstacle is not greater than 40 cm (universe of It is well-known that a basic FLC cannot solve navigation through a workspace with arbitrarily distributed obstacles, if prior information about them is not available.A special problem is encountered when the obstacles are deployed such that they create a concave, U, barrier, in which case the robot enters an infinite loop or local minima (Krishna & Kalra, 2001;Motlagh et al., 2009).

Conclusion
A fictitious fuzzy magnet concept was introduced and its application analyzed in this chapter, using different navigation problems of differential drive mobile robots.The concept allows for navigation to the target in a single maneuver, without changing the direction of travel of the mobile robot.The symmetricity of the differential drive mobile robot is fully utilized, such that approaches based on the fictitious fuzzy magnet concept provide bidirectional solutions to mobile robot navigation problems.For example, during garaging, the mobile robot is automatically parked from the end of the robot which is closer to the entrance.The algorithm can be applied when the control variable is of the discrete type and where there are relatively few quantization levels.
When applied to a mobile robot garaging problem, a detailed analysis of simulation and experimental results illustrates the efficiency of the proposed algorithm and its robustness in the case of a random or systematic WMR position estimation error, as well as its limitations.
The most significant shortfall of the proposed algorithm is that it does not provide a solution which will ensure that regardless of initial conditions the garage parking process is completed with no collision with the garage.The geometrical position of the initial conditions which lead to a collision of the robot with the garage is a compact, finite area which is discussed in the chapter.Some of the constraints mentioned here could be overcome in further research aimed at improving the proposed algorithm through a higher level of FLC complexity.Additionally, if a larger number of fictitious fuzzy magnets are introduced, the concept could be used to perform more intricate garage parking tasks.Re-configuration of controller outputs would render the proposed algorithm applicable for garage parking of a broader class of car-like mobile robots.Additionally, it was shown that a larger number of fictitious fuzzy magnets can be introduced to execute tasks more complex than garage parking.Specifically, the feasibility was explored of applying the fictitious fuzzy magnet concept to execute the task of mobile robot navigation to a target in an environment which contains one or more obstacles.It was shown that the algorithm designed to avoid a single stationary obstacle can be successfully generalized to a multiple obstacles avoidance problem, preserving the bidirectional capability.The proposed algorithm can be extended by fuzzification of the coefficients C k , taking into account the probability of collision with obstacles which lie on the robot's course.

258
Recent Advances in Mobile Robotics www.intechopen.com

Fig. 2 .
Fig. 2. Membership functions of input linguistic variables: (a) Orientation relative to the targetα A , (b) Distance relative to the target d A .

Fig. 5 .
Fig. 5. Mutual spatial positions of wheeled mobile robot and garage.

Fig. 6 .
Fig. 6.Mutual spatial positions of wheeled mobile robot and fictitious fuzzy magnet.
C 3 , C 4 , F 1 , and F 2 The trapezoidal membership function far of the linguistic variable d Fm (Fig.7(a)) is determined by the coefficients F 1 and F 2 , while the membership function near of the linguistic variable d Cm is determined by the coefficients C 1 , C 2 , C 3 and C 4 (Fig.7(a)).The coefficients C 3 , C 4 , F 1 and F 2 enable gradual activation of fictitious magnet C m and the deactivation of fictitious magnet F m , as the robot approaches its destination.The selection of these parameters has a critical impact on the performance of the entire fuzzy controller.Inequalities (17) and (18) guarantee the form of the membership functions shown in Fig.7(a) and Fig.7(b), respectively.

Figure 9
Figure 9(a) illustrates the action of FM F m .Outside the circle of radius F 2 , with its center at F m (dark gray in the figure), this fuzzy magnet exhibits maximum activity.When the WMR is Fig. 9. Illustration of fictitious fuzzy magnet activity.The activity of FM Fm declines as the position of the robot approaches the point F m , through to the edge of the circle of radius F 1 , inside which the activity of this fuzzy magnet equals zero (i.e., µ far (d Fm ≤ F 1 )=0).To facilitate adjustment of the overlap region of the two fuzzy magnets, it is convenient for the point C m , which determines both the position of FM Cm and the position of the center of the garage, to lie within the circle of radius F 2 , which can be expressed, based on Fig.9(a), by the following inequality:

Fig. 10 .
Fig. 10.Illustrative trajectories for front-and back-drive garaging Fig. 11.Results of simulations with FLC BG , for the set of initial conditions N d .
Fig. 12. Results of simulations with FLC BG with simulated sensor noise, for the N d initial conditions.

Fig. 14 .
Fig. 14.Block diagram of real-time experiment: (A) Determining of initial conditions; (B) Calculation of: d Cm , d Fm , α Cm and α Fm ; (C) Fuzzy logic controller for bidirectional garaging; (D) Bluetooth interface; (E) Hemisson mobile robot; (F) Web camera; (G) Estimation of the WMR posture; (H) Examination of VL and VR values.

Fig. 18 .
Fig. 18.Bypass trajectories of the robot from four initial positions around two obstacles of different dimensions.

Fig. 20 .
Fig. 20.Navigation to the goal (coordinate origin) through a group of obstacles.

257Fictitious
Fuzzy-Magnet Concept in Solving Mobile-Robot Target Navigation, Obstacle Avoidance and Garaging Problems www.intechopen.comdiscourse of the linguistic variable d RO , Fig.17(b)).This basically means that the robot takes into account obstacles within a 40 cm radius.
(b).The membership function µ near (d Cm ) allows the action of fuzzy magnet C m to affect the WMR only when the WMR is near FM Cm , or when the distance of d Cm is less than C 4 .Even though no linguistic variable related to distance covers the entire set of possible values, the WMR is in the region

Table 2
(a), and the FRsS C m subset shown in Table 2(b).

Table 2 .
Fuzzy rules base for bidirectional garaging fuzzy controller -FLC BG .Membership functions of input variables d Fm and d Cm independently activate particular rules (Table

Table 3 .
Wheel speed of the Hemisson robot as a function of wheel speed command.

Table 5 .
Extreme and mean values derived from garaging experiments.

Table 6 .
It is important to note that the outputs of the obstacle avoidance controller are equal to zero when the obstacle does not lie on the robot's course.For this reason the algorithm for WMR navigation to the target point in a single-obstacle environment must integrate FLC OFE and FLC OA solutions.The linear velocity v R and the angular velocity ω R of the robot are computed