Next Article in Journal
Whole-Body Control for a Torque-Controlled Legged Mobile Manipulator
Next Article in Special Issue
Smooth Trajectory Planning at the Handling Limits for Oval Racing
Previous Article in Journal
Overview of the SmartX Wing Technology Integrator
Previous Article in Special Issue
Path Planning for Multiple Unmanned Vehicles (MUVs) Formation Shape Generation Based on Dual RRT Optimization
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

An Enhanced Navigation Algorithm with an Adaptive Controller for Wheeled Mobile Robot Based on Bidirectional RRT

Department of Mechatronic Engineering, National Taiwan Normal University, Taipei 106308, Taiwan
*
Author to whom correspondence should be addressed.
Actuators 2022, 11(10), 303; https://doi.org/10.3390/act11100303
Submission received: 16 August 2022 / Revised: 11 October 2022 / Accepted: 19 October 2022 / Published: 21 October 2022
(This article belongs to the Special Issue Intelligent Control and Robotic System in Path Planning)

Abstract

:
A navigation algorithm providing motion planning for two-wheeled mobile robots is proposed in this paper. The motion planning integrates path planning, velocity planning and controller design. Bidirectional rapidly-exploring random trees algorithms (RRT) with path pruning and smoothing mechanism are firstly used to obtain a collision-free path to the robot destination with directional continuity. Secondly, velocity planning based on trapezoidal velocity profile is used in both linear and angular velocities, but the position error of the endpoint of the curve appears due to the coupling problem of the nonlinear system. To reduce the error, an approximation method is used to gradually modify several parts of time length of the trapezoidal velocity profile, so the continuity of the path can still be maintained. Thirdly, the controller keeping the robot on the planned path and velocity is designed based on the dynamic model of the robot. The parameters of this controller are estimated by the adaptive low, and the gain of controller is dynamic adjusted by fuzzy logic control to avoid the case that the control value is saturated. The controller stability and the convergence of tracking error is guaranteed by Lyapunov theory. Simulation results are presented to illustrate the effectiveness and efficiency.

1. Introduction

In the past years, many studies of wheeled mobile robots have been presented. Among them, the differential wheel type mobile robot is still the most important development project in the indoor flat environment because of its flexibility and cost advantages. Common applications include unmanned factories [1], automated warehouses, and home sweeping robots [2]. Robot navigation is the basic ability to realize application functions, and path planning is the most important ability. A* algorithm is one of most representative algorithms for path planning because of its best priority search and heuristic exploration strategy to obtain good application value in most cases [3,4]. However, the exponential growth of time and space complexity makes it difficult to be applied to large or high-dimensional maps. Relatively, those algorithms with only probabilistic completeness, such as RRT algorithms, are usually able to complete path planning tasks in less time, but it is also difficult to ensure optimality and requires subsequent improvement measures [5,6,7,8]. Therefore, this paper improves the traditional RRT algorithm and designs a series of optimization mechanisms to improve the path quality and solve the problems faced by the traditional RRT algorithm.
Although path planning provides a feasible solution to the goal point, there may be some unexpected situations, such as moving obstacles overlapping the path, so that the robot cannot proceed along the predetermined path. In addition, the robot itself will deviate from the predetermined path due to some disturbances or uncertainties, so a good controller is needed to correct the state error of the robot, such as PID, feedback linearization, backstepping, sliding mode control, neural networks, and the hybrids of the above controllers [9,10,11,12]. According to the level of the controllers, they can be classified into two types, depending on the controller designed with only kinematic [13,14,15,16] or both kinematic and dynamic methods [17,18]. Generally, the former is much more simple but still enough for general cases and suitable for those motors with the ability to control velocity already. The latter is applied to high-speed cases where accuracy is required, but it requires more computing.
At the only-kinematic level, there are some research studies that have improved existing controllers. For instance, Simon X. Yang et al. [13] proposed a controller based on bioinspired neurodynamics, which can produce smooth continuous robot control signals with zero initial velocities. Thanks to the continuity of velocities, the robot reduces the overshoot at startup. Sašo Blažič [14] proposed a periodic controller, which let the convergence of the orientation error be 2kπ or kπ with k being an integer constant for different condition instead of zero. Thus, there is no need for excessive rotation of the mobile robots in the case that the initial orientation error is large. Sašo Blažič also proposed a controller design role to determine a suitable control law. Many controllers can be obtained by following this design role. Zhong-Ping Jiang et al. [15] proposed one local and one global backstepping controller for path tracking. Limiting of the denominator may be zero, and the local controller is only for small initial errors. This problem is solved in global controllers by choosing a different way for the convergence path. In this study, the global controller also expands to a very simple dynamic model.
At both kinematic and dynamic levels, Bong Seok Park [17] proposed an adaptive controller with dynamic surface control and parameter estimators. The dynamic also includes motors, and all system parameters are obtained by the four update laws estimator. Chih-Lyang Hwang [18] proposed hierarchical variable structure tracking control for car-like mobile robots. The control output is composed of equivalent and switching parts. Instead of using the PID controller of kinematic errors as the only surface to be the input of the switch function, it also considers the dynamic errors and virtual reference as the second surface so that the system has better performance against disturbances. However, saturation problems of the controller output, which are not considered in most controller designs, may become more serious, especially in the high-speed or large-initial-error cases. When the controller output is saturated, the system stability and the convergence of errors guaranteed by Lyapunov theory is invalid, which means the system may diverge. One way to avoid this is reducing the controller gain, although doing so reduces the transient response. Thus, Xiaohan Chen [16] proposed a controller with diamond-shaped input constraints to guarantee the control value is limited by the input constraints. However, this controller only works in kinematic models. To solve this, we introduce a dynamic gain adjustment [19] considering the system errors and current output based on fuzzy logic control. Once the output is saturated, the controller gain reduces automatically, and then a limited increase of the gain occurs if it finds that there is still room to increase the amount of control. By adjusting the gain, the system can still have a good transient response when solving the saturation problem.
This paper is derived from the short conference paper published in [20]. In the initial conference paper, we focused on the controller design only. This paper extends the previous research and integrates the path planning as a reference signal to the controller, which finally enables the robot to follow the predetermined path to the destination. This paper is organized as follows. The problem statement is proposed in Section 2. Path planning is proposed in Section 3. The controller design and its stability analysis are presented in Section 4. Experimental results and conclusion are proposed in Section 5 and Section 6, respectively.

2. Problem Statement

2.1. Definition of Environment and Robot

It is assumed that the robot moves on a known and bounded two-dimensional plane, which is discretized into a grid map. Each grid point corresponds to a small area of actual space. If the space in this area is completely passable, its state is regarded as free, otherwise it is regarded as occupied. The structure of wheeled mobile robot with two actuated wheels on left and right sides is shown in Figure 1. Pc is the center of mass of mobile robot. Q is the middle point of two actuated wheels. d is the distance between Pc and Q. R is the half width from left to right actuated wheel. r is the radius of the wheel. Ro is the radius of the smallest circle with its center Q that covers the entire robot. The three variables related to robot coordinates are as follows. θ is the heading angle of mobile robot. x and y are the coordinates of Q. If the wheels are non-slipping, then the nonholonomic constraint is given as:
x ˙ sin θ y ˙ cos θ = 0
The kinematic model of mobile robots is given in (2). q = [x, y, θ]T is the vector of position. z = [vwr, vwf]T is the vector of velocity, where vwr and vwl are the angular velocity of right and left wheel, respectively.
q ˙ = J ( q ) z = r 2 [ cos θ cos θ sin θ sin θ R 1 R 1 ] [ v w r v w f ] τ = M z ˙ + C ( q ˙ ) z + D z + τ d
The dynamic of motion of the mobile robot is given in (3). mc is the mass of the body, and mω is the mass of wheel with a motor. Ic, Iω and Im are the moment of inertia of the body about the vertical axis, through the wheel with a motor about the wheel axis, and the wheel with a motor about the wheel diameter, respectively. τ is the vector of control torque applied to the wheels of the robot. τd is disturbances with the unmodeled dynamic and assumed as bounded as |τdi| ≤ bmi for i = 1, 2. d11 and d12 are the damping coefficients.
M = [ m 11 m 12 m 12 m 11 ] C ( q ˙ ) = r 2 m c d 2 R [ 0 θ ˙ θ ˙ 0 ] D = [ d 11 0 0 d 22 ] m 11 = r 2 4 R 2 ( m R 2 + I ) + I ω m 12 = r 2 4 R 2 ( m R 2 I ) m = m c + 2 m ω I = m c d 2 + 2 m ω R 2 + I c + 2 I m τ = [ τ r , τ f ] T τ d = [ τ d 1 , τ d 2 ] T
Neglecting motor inductance, the dynamic of DC motors to the actuated wheels are represented as (4). τm = [τmr, τml]T is the torque vector generated by DC motors. im = [imr, iml]T is the current vector of motors. The controller output is defined as u = [ur, ul]T, which is also the voltage vector of motors. θm = [θmr, θml]T is the rotation angle vector of the motors. Under reasonable assumptions, the voltage should be bounded as |ur| ≤ umax and |ul| ≤ umax. The parameters KT, KE and Ra are represented the motor torque constant, the back electromotive force coefficient, and the resistance, respectively.
τ m = K T i a   u = R a i a + K E θ ˙ m
In most cases, a gearbox is installed between the motor and the wheel to increase the torque output of the motor, which gives the relationship in (5). ni is the gear ratio.
n i = θ ˙ m i ν w i = τ i τ m i , i = r , l
By integrating (2)–(5), the complete dynamic model of two-wheeled mobile robot including kinematics is written as (6), where P1 = Ra−1N2KTKE and N = diag(nr, nl).
q ˙ = J ( q ) z z ˙ = M 1 ( R a 1 N K T u ( C ( q ˙ ) + D + P 1 ) z τ d )

2.2. Path Planning

The process of planning a path satisfying the conditions in (7) from starting point S to ending point E is called path planning. The path planned by this process is symbolized by P. Since P is composed of multiple points, we use P(k) to represent the k + 1th point of P, where k is a non-negative integer from 0 to np − 1, and np is the number of points in P. The subscript symbols x, y, θ correspond to the state variables of P(k), so that Px(k), Py(k) are the coordinates, and Pθ(k) is the orientation. Function B(x, y) is used to find the space where the coordinate (x, y) locates. Function State(B) returns the state of space B that State(B) ∈ {free, occupied}. Function N(B) returns a set of points which are the neighbors of space B.
P ( 0 ) = S , P ( n p 1 ) = E , S t a t e ( B ( P x ( k ) , P y ( k ) ) ) = f r e e , k , k < n p , P ( k + 1 ) N ( P ) , k , k < n p 1
As applying the planned path to robot navigation of two-wheeled mobile robots, the property of orientation continuity should be considered. Because of the nonholonomic constraint in (1), the robot needs to follow the “stop–turn–go” process every time it encounters a discontinuous point of direction, which takes lots of time and energy due to the large velocity change. Therefore, we expect the planned path to have the property of directional continuity to satisfy the inequality in (8), where θth is the threshold angle that the robot can turn in a single step Δk.
| P θ ( k + 1 ) P θ ( k ) | < θ t h , k , k < n p 1
Another issue needs to be considered is the volume of the robot. To avoid that the robot crashes into the wall or other obstacles, the condition in (9) must satisfied, where R0 is given in Figure 1.
S t a t e ( B ( P x ( k ) + x 0 , P y ( k ) + y 0 ) ) = f r e e , k , k < n p , x 0 , y 0 x 0 2 + y 0 2 R 0
If we need to obtain further dynamic information of the path, which is the linear velocity Pv(k) and angular velocity Pω(k), the variable k in (7) should be regarded as the discrete time. More constraints in (10) need to be satisfied, where Δk is the time interval, amax is the max linear acceleration, and αmax is the max angular acceleration.
| P v ( k + 1 ) P v ( k ) | a m a x Δ k , | P ω ( k + 1 ) P ω ( k ) | α m a x Δ k , k , k < n p 1
In addition, the linear velocity Pv(k) and angular velocity Pω(k) should be bounded because of the physical limitations, which shows in (11). vmax and ωmax are the max linear and angular velocities.
| P v ( k ) | v m a x , | P ω ( k ) | ω m a x , k , k < n p

2.3. Obstacle Avoidance

Although the path planning algorithm proposes an obstacle-free path to the ending point, the robot may encounter some unexpected obstacles when moving, causing collision problems when moving along a predetermined path. There are at least two ways to solve this problem. The first method is updating the map with the unexpected obstacles and path planning aging to obtain a new obstacle-free path. Its advantage is global searching to avoid local maximum problem, but it usually takes more time because of constantly re-planning, especially in the dynamic environment. The second method is to perform local path adjustments to satisfy the condition in (12), where Po is given in Figure 1, and O(k) is the coordinates of the obstacle at discrete time k so that the distance between Po and O(k) is always greater the threshold distance Ro. The advantages of the second method are that it is fast and convenient. However, the problem is that there is no guarantee that the original predetermined path can be correctly returned to after obstacle avoidance. In practice, the second method is usually used first, and if the problem occurs, the first method is used to solve the problem.
D i s ( P o ( k ) , O ( k ) ) > R 0

2.4. Controller Design

The main purpose of the controller is to reduce the error between the planned path and the coordinates of the actual robot, which is also called path tracking. In controller design, the reference target is given from the planned path showing in (13). x, y, θ, v, ω are defined as the x-coordinate, y-coordinate, orientation, linear velocity and angular velocity of Q in Figure 1, respectively.
x r = P x , y r = P y , θ r = P θ , v r = P v , ω r = P ω
The path tracking problem of wheeled mobile robots can be described as follows. We introduce the virtual wheeled mobile robot with the same structure as the actual robot, which gives the kinematic model in (14), and qr = [xr, yr, θr]T.
x ˙ r = ν r cos θ r , y ˙ r = ν r sin θ r , θ ˙ r = ω r
The tracking error Xe is defined as:
X e = [ x e y e θ e ] = [ cos θ sin θ 0 sin θ cos θ 0 0 0 1 ] [ x r x y r y θ r θ ]
Taking the time differential of tracking error, the dynamic of tracking error becomes
x ˙ e = v r cos θ e v + ω y y ˙ e = v r sin θ e ω x e θ ˙ e = ω r ω
The control objective is to design a law of u such that
| X e | < δ a s t ,
where δ is an acceptable position error range for path tracking. In other words, the errors need to converge to the range δ as time goes to infinity.

3. Path Planning

Traditional RRT algorithm is a random sampling method and with non-heuristic iteratives. The general operation process of the RRT algorithm is given in Algorithm 1.
Algorithm1. RRT
1:
T.Initialize(S)
2:
for i = 0 to Parameters.MaxSearchingNumber
3:
    nr = RandomSampling(Map)
4:
    nc = FindNearest(T, nr)
5:
    nn = Extend(nc, nr)
6:
    if CollisionCheck (Map, nc, nn) continue
7:
    nn.parent = nc
8:
    T.Add(nn)
9:
    if !GoalTest(Map, nn, E) continue
10:
  return SelectPath (T, E)
11:
end
12:
return Error.PathPlanningFailed.OutOfSearchingNumber
If the robot can move freely in the environment, a two-way searching strategy may reduce the search range. Bidirectional RRT (BRRT), an improved algorithm from RRT, searches from starting point and ending point. The pseudocode is given in Algorithm 2. Therefore, there are two search trees Ts and Te. The pseudo-code of bidirectional RRT is given as follows. In the initialize state, only S in Ts and only E in Te. T is the cell array, including Ts and Te. nr is a point of random sampling on the map. Lines 7 to 15 are a twice-loop for two-side searching. nc is the closest point in the current searching tree to nr. nn is a point extending from nc with a random distance. CollisionCheck(Map, nc, nn) is to check if there are some obstacles between nc and nn to cause a collision. GoalTest(Map, nn, N(j)) is to check if there are no obstacle between nn and the target N(j). SelectPath (T(j), T(1 − j), nn, S, E) is to construct the path form S to E. This function constructs the first path Path1 based on T(j) starting at nn, constructs the second path Path2 based on T(1 − j) starting at nn, reverses Path1 as Path3, combines Path3 and Path2 as Path, and finally returns Path or its reversed vision Reverse(Path) based on whether the first point of Path is S or E. If i reaches the max searching number, BRRT returns an error to indicate the searching number is reached.
Algorithm2. BRRT
1:
Ts.Initialize(S)
2:
Te.Initialize(E)
3:
T = {Ts, Te}
4:
N = {S, E}
5:
for i = 0 to Parameters.MaxSearchingNumber
6:
    nr = RandomSampling(Map)
7:
    for j = 0 to 1
8:
        nc = FindNearest(T(j), nr)
9:
        nn = Extend(nc, nr)
10:
      if CollisionCheck(Map, nc, nn) continue
11:
      nn.parent = nc
12:
      T(j).Add(nn)
13:
      if !GoalTest(Map, nn, N(j)) continue
14:
      return SelectPath (T(j), T(1 − j), nn, S, E)
15:
    end
16:
end
17:
return Error.PathPlanningFailed.OutOfSearchingNumber
Both RRT and BRRT algorithms create many unnecessary and time-consuming turns. Therefore, a path-improving mechanism is needed. Three mechanisms, which are path pruning, path smoothing, and trapezoidal velocity profile, are used to improve the path.

3.1. Path Pruning

The concept of path pruning is established by the greedy method. Although it is not guaranteed that the best path is selected, it is suitable for matching with RRT or BRRT algorithms because of its fast convergence. The pseudocode of path pruning is given in Algorithm 3. PrunedPath is initialized with only Path(0). Once the condition in Line 5 is satisfied, the point Path(j) is added in PrunedPath, because it is the furthest point from Path(i). If the condition on Line 3 is no longer satisfied, PathPrunning() returns PrunedPath.
Algorithm3. Path Pruning
1:
PrunedPath.Initialize(Path(0))
2:
i = 0
3:
while i < length(Path) − 1
4:
       for j = length(Path) −1 to i + 1 by −1
5:
                if CollisionCheck(Map, Path(i), Path(j)) continue
6:
                PrunedPath.Add(Path(j))
7:
                i = j
8:
                break
9:
       end
10:
end
11:
return Pruned

3.2. Path Smoothing

The purpose of path smoothing is to find an arc to replace the path around the path points so that the continuity of the orientation is obtained. Figure 2 shows an example of path smoothing on a five-point path. In this example, we have three arcs to replace part of the original path. For each point of path except the first and the last, its rotation radius, rotation center, and two tangent points are represented as ri, P i r , P i a , and P i b , respectively. The relations between these points are given in (18).
[ x i a y i a ] = [ x i r i sin ( | Δ θ i | / 2 ) cos ( θ i ) x i r i sin ( | Δ θ i | / 2 ) sin ( θ i ) ] [ x i b y i b ] = [ x i + r i sin ( | Δ θ i | / 2 ) cos ( θ i + 1 ) x i + r i sin ( | Δ θ i | / 2 ) sin ( θ i + 1 ) ] θ i = tan 1 ( y i y i 1 x i x i 1 ) + 2 m i π , m i , s . t . 0 θ i < 2 π Δ θ i = θ i θ i 1 + 2 n i π , n i , s . t . π θ i < π
With a larger rotation radius, robots may move with less angular velocity to obtain higher linear velocity. Therefore, path smoothing becomes an optimization problem, and the fitness function is designed in (19) to maximum the rotation radius. c is a positive constant satisfying c > 1 to maintain log(ri + c) > 0.
max r i ( 0 , r max ] i = 1 n 1 log ( r i + c )
The conditions of the optimization problem are given in (20).
P i P i b ¯ + P i + 1 P i + 1 a ¯ P i P i + 1 ¯ , i + , i < n 2 P 1 P 1 a ¯ P 0 P 1 ¯ P n 2 P n 2 b ¯ P n 2 P n 1 ¯ S t a t e ( B ( I n d e x B ( x , y ) ) ) = f r e e , P ( x , y ) P i a P i b , i + , i < n 1

3.3. Trapezoidal Velocity Profile

The trapezoidal velocity profile (TVP) is a simple and common method for motion planning by giving a fixed distance. In our case, the robot moves in a 2-D plane with two control inputs. Therefore, we consider implementing the trapezoidal velocity profile on both linear and angular velocities with the kinematic model of wheeled mobile robots in (21).
x ˙ = v cos θ , y ˙ = v sin θ , θ ˙ = ω
Figure 3 shows an example of the trapezoidal velocity profile with (21) to replace an arc curve. Both linear and angular velocities are designed by TVP as (22) and shown in Figure 3b. The initial location of the robot is [x, y, θ] = [0, 0, 0]. In Figure 3a, an arc curve with same starting and ending point is added in to compare with the moving trajectory. The state of ending point in this example is [1.7100, 1.5934, 1.4997].
v = { 0 0 t < 0.5 2 ( t 0.5 ) 0.5 t < 1 1 1 t < 3 1 2 ( t 3 ) 3 t < 3.5 0 3.5 t < 4 , ω = { 0.5 t 0 t < 1 0.5 1 t < 3 0.5 ( 3 t ) 3 t < 4
Taking the example in Figure 2, three arc curves are replaced with the TVP method. Then, the linear velocities of three straight segments, which are P0 to P a 1, P b 1 to P a 2, and P b 3 to P4, are simply applied with traditional TVP, and their angular velocities are kept at zero. After combining three curves and three straight segments, the velocity profile from P0 to P4 is obtained, and the time function of this path can also be further obtained. Therefore, the time plan of this path is obtained.
The step-by-step process of the proposed path planning in this paper is given in Figure 4, including BRRT and three improving methods.

4. Controller Design and Stability Analysis

In this section, we develop a controller in four parts. The first part is at the kinematic level to determine the virtual reference velocities. The dynamic for controller design is included in the second part. In the second part, the controller law is also obtained to determine the control value with the virtual reference velocities. The mechanism of dynamic gain adjustment is shown in the third part to solve the saturation problem. Obstacle avoidance is shown in the last part.

4.1. Kinematic Controller

From the kinematic controller in (2), there are two parameters, r and R, in the system. For the convenience of parameter estimation, we define a1 = 1/r, a2 = R/r, and âi is the estimation of ai as i = 1, 2. The Lyapunov function V1 is chosen as:
V 1 = 1 2 r x e 2 + 1 2 r y e 2 + R r V θ ( θ e ) + 1 2 γ 1 a ˜ 1 2 + 1 2 γ 2 a ˜ 2 2
where Vθ(θe) is a Lyapunov function of θe to Vθ > 0 as θe ≠ 2kπ and Vθ = 0 as θe = 2kπ with k ∈ ℤ. The estimation errors are defined as ãi = aiâi, i = 1, 2. γ1 and γ2 are positive constants, the gain of estimators. Using the error dynamic Equation (15), the time derivative of V1 becomes:
V ˙ 1 = x e ( ν w r + ν w l 2 + a 1 ν r cos θ e ) + a 1 y e ν r sin θ e + V e θ e ( ν w r ν w l 2 + a 2 ω r ) i = 1 2 a ˜ i a ^ ˙ i γ i
The virtual control law z ¯ = [ ν ¯ w r , ν ¯ w l ] T is chosen as ν ¯ w r = h 1 + h 2 and ν ¯ w l = h 1 h 2 , where h1 and h2 are given in (25).
h 1 = a ^ 1 ν r cos θ e + k x x e h 2 = a ^ 2 ω r + a ^ 1 k y y e ν r Ω y + k θ Ω θ
Then, the time derivative of V1 becomes:
V ˙ 1 = k x x e 2 + a 1 y e ν r ( sin θ e k y V e θ e Ω y ) k θ Ω θ V e θ e γ 1 1 a ˜ 1 ( a ^ ˙ 1 + γ 1 x e ν r cos θ e + γ 1 y e ν r sin θ e ) γ 2 1 a ˜ 2 ( a ^ ˙ 2 + γ 2 k y 1 Ω y 1 ω r sin θ e ) + q 0
with
q 0 = 0.5 x e ( ν w r ν w l + ν ¯ w r + ν ¯ w l ) + 0.5 ( k y 1 Ω y 1 sin θ e ) ( ν w r + ν w l + ν ¯ w r ν ¯ w l )
Ωy and Ωθ are chosen as:
sin θ e k y Ω y d V 1 d θ e = 0 Ω θ d V 1 d θ e { = 0 , θ e = 2 k π , k Z > 0 , elsewhere
with â1 and â2 are updated by:
a ^ ˙ 1 = γ 1 ( x e ν r cos θ e + γ 1 y e ν r sin θ e ) a ^ ˙ 2 = γ 2 ( k y 1 Ω y 1 ω r sin θ e )
Then, V1 becomes:
V ˙ 1 = k x x e 2 k θ Ω θ ( V e / θ e ) + q 0
q0 comes from the error between virtual control law and the angular velocity of wheels, which should deal with the dynamic controller. For this reason, it can be ignored only considering the kinematic level, which gives that time derivative of V1 ≤ 0.

4.2. Dynamic Controller

To simplify the complexity of the controller, the dynamic surface control is introduced though a first-order equation as:
τ ν z ˙ f + z f = z ¯ , z f ( 0 ) = z ¯ ( 0 ) , τ ν > 0
The velocity error is defined as:
z e = z z f
Its time derivative is given as:
z ˙ e = z ˙ z ˙ f = M 1 ( R a 1 N K T u ( C ( q ˙ ) + D + P 1 ) z τ d ) z ˙ f ( M R a ) 1 N K T ( u + Φ W )
In (33), the vector of system parameter W can be estimated by â3 with the update law in (24), such that a3 = WTW. Φ is a based matrix of system variable. Both W and Φ are shown in (34).
W = [ r a r r 3 4 R 2 n r k t r r a l r 3 4 R 2 n l k t l r a r d 11 n r k t r + n r k e r r a l d 22 n l k t l + n l k e l r a r m 11 n r k t r r a r m 12 n r k t r r a l m 12 n l k t l r a l m 11 n l k t l r a r d m 1 n r k t r r a l d m 2 n l k t l ] T Φ = [ ν w f ( ν w r ν w f ) 0 ν w r 0 z ˙ f 1 z ˙ f 2 0 0 1 0 0 ν w r ( ν w r ν w f ) 0 ν w f 0 0 z ˙ f 2 z ˙ f 1 0 1 ]
Notice that żf1 and żf2 can be obtained easily with (31), and that is the reason why dynamic surface control can reduce the complexity of the controller. Then, the control law is chosen by:
u = k ν z e 0.5 δ 1 2 a ^ 3 Φ Φ T z e
The update law of â3 is designed as:
a ^ ˙ 3 = 0.5 γ 3 δ 1 2 z e T Φ Φ T z e a ^ 3 ( 0 ) = 0
Instead of estimating all the parameters in the dynamic equation, â3 is the estimator of WTW. Therefore, although this dynamic controller is simple, it can work without precise parameters.

4.3. Dynamic Gain Adjustment

To overcome the saturation problem, we adjust the gain of the controller by fuzzy logic control. As the conditions in (28) must be maintained, only kx and kθ are tuned. In this fuzzy logic control, the position error e and the duty of control value are the input, and the output tunes the ratio of gain rk to achieve dynamic gain adjustment.
The major target is to reduce controller saturation. Therefore, we choose the larger one of u to define the duty of control value u0 as (37).
u 0 = max ( | u | ) u max
umax is max driving voltage of the motors, so that 0 ≤ u0 ≤ 1. The position error e is defined in (38).
e = ( x e 2 + y e 2 + θ e 2 ) 1 / 2
The membership function of the two inputs in shown in Figure 5. It is clear shown that the scale design of u0 is asymmetric. This is because of the best duty of the motors should be put in the m scale to keep a good operating space.
Table 1 is the rules to determine to increase or decrease the gain of the controller in each case. The output given in five levels in each case are: heavy increasing (HI), smooth increasing (SI), non-change (NC), smooth reducing (SR) and heavy reducing (HR).
Finally, the controller gain can be tuned as follows:
k x * = r k k x , k θ * = r k k θ , r ˙ k = FLC ( u 0 , e )
The structure diagram of proposed controller is shown on Figure 6. The reference velocity Vr of the virtual wheeled mobile robot and the path Xr based on the kinematic model are obtained from path planning algorithm. The tracking error Xe, obtained from (15) with a rotation is further provided to estimator 1 and 2 in (29) to obtain â1 and â2, provided to the fuzzy logic controller in (39) to obtain the gain ratio rk, and provided to the kinematic controller in (25) with â1, â2, rk, and a converter to obtain the virtual control law z ¯ . The dynamic surface control proposes zf from z ¯ with the first-order differential equation in (31). The based matrix Φ in (34) is provided to estimator 3 to obtain â3 in (36). Finally, the dynamic controller for the mobile robot is designed in (35) with â3, Φ, and ze. The gain of the kinematic controller is also adjusted by u according to (37) and (39).
For traditional path planning algorithms, such as the A* algorithm and RRT algorithm in the grid, only the path Xr is provided, and its differentiability is not guaranteed. Hence, some controllers, such as PD, PID, and the proposed controller, are not suitable for direct application to traditional path planning algorithms. Take the PD controller as an example: the design of orientation control is given as the following:
u b = k p θ e + k d θ ˙ e
According to the definition of θe in (15), its time differential is obtained as ωrω. Because the differentiability of Xr is not guaranteed, the angular velocity of the virtual wheeled mobile robot ωr does not always exist. In this case, the time differential needs to be obtained by the numerical difference method from θe, which may cause approximation errors and the huge peak problem because of the discontinuity of orientation. However, ωr is the second state of Vr in proposed path planning algorithm, so that ωr always exists. Therefore, ub has been fully defined, so that PD controller can be easily implemented in robot control with the proposed path planning algorithm.

4.4. Obstacle Avoidance

In this section, we focus on the ability of obstacle avoidance. The pseudo-code of obstacle avoidance is shown in Algorithm 4, where n is the number of levels. Figure 7 shows an example with four obstacles close to the original path with three obstacle avoidance levels. In this case, the obstacles are too close to the path and may cause collisions. Here, we define two parameters d0 and d1. d0 is the hard-safe range so that the distance d between the obstacles and the robot should be larger than d0. d1 is the soft-safe range, which is also the threshold for obstacle avoidance design to take effect.
Algorithm4. Obstacle Avoidance
1:
for i = 1 to length(Path)
2:
    for j = 1 to n
3:
        NewPath(i) = Path(i)
4:
        for k = 1 to length(Obstacles)
5:
            d = Distance(Path(i), Obstacles(k))
6:
            theta = Orientation(Obstacles(k), Path(i))
7:
            m = min(max(−(dd1)/(d1d0), 0), 1)
8:
            NewPath(i) = NewPath(i) + m * d1 * [cos(theta), sin(theta)]
9:
        end
10:
        Path = NewPath
11:
    end
12:
end
13:
return NewPath

5. Experimental Results

The size of the map is 512 × 512 pixels and the origin is defined in the upper left corner of the map. Figure 8 shows the results of path planning. In Figure 8a, the start point is marked as a circle and located at (15, −30). The goal point is marked as a diamond and located at (270, −212). The blue polyline is the planned path by BRRT, and the red line is the tree of BRRT. Clearly, lots of unnecessary turns are included in the path. Therefore, a smoothed path is given in Figure 8b, including the original path by BRRT, path pruning, and path smoothing. The minimum and maximum extension distance of BRRT is set between 3 to 10. The linear and angular velocities of the smoothed path are shown in Figure 9. The parameters of path smoothing are given in Table 2.
In Table 3, a 100-times test is proposed to compare the paths in different stage, which are the original path, pruned path, and smoothed path. With the mechanism of path pruning, the average length is reduced from 1640.3 m to 1357.8 m, and the number of turns is reduced from 269.69 to 22.210. Data show that a lot of unnecessary turns are removed in path pruning. Although the mechanism of path smoothing does not change the number of turns required, the continuity of the path angle is improved, and the average length is further reduced to 1284.8 m.
The proposed controller is compared with P controller, which is a simple but widely used feedback control algorithm. The controller is designed as (41). Two errors, which are expected to be suppressed by the P controller, are defined as the position error e0 and the orientation error e1. The controller value ub(0) and ub(1) are designed proportional to the error e0 and e1, respectively. Both kp0 and kp1 are the positive gains of the P controller. Just like the design of ν ¯ w r = h 1 + h 2 and ν ¯ w l = h 1 h 2 , a converter is required to convert ub to u in (40) according to the geometric relationship between the motor angle and the robot position.
e 0 = ( x e 2 + y e 2 ) 1 / 2 , e 1 = θ e u b ( 0 ) = k p 0 e 0 , u b ( 1 ) = k p 1 e 1 u = [ u b ( 0 ) + u b ( 1 ) , u b ( 0 ) u b ( 1 ) ]
The gains of the P controller are choosing as kp0 = 6 and kp1 = 8. The parameters of the robot and the gains of proposed controller are given in Table 4. The tracking results are shown in Figure 10, the tracking errors are shown in Figure 11, and the cumulative errors are shown in Figure 12. The tracking error is defined as e0 in (40), and the orientation error is defined as the absolute value of e1. Table 5 shows the average tracking errors. The results show that the controller proposed in this paper outperforms the P controller in both position and orientation errors.

6. Conclusions

In this paper, we propose a navigation algorithm by using BRRT with several improvement measures to find the path with its time function, and by using an adaptive controller with dynamic gain adjustment in both the kinematics and dynamic models to reduce the tracking error and estimate the system parameters. A three-level obstacle avoidance algorithm is also proposed. In 100 simulations, this measure can save about 86% of the path planning time and 84% of the number of nodes. The robot’s movement time can also be reduced. The path planned in this way has the characteristics of velocity continuity, so it is suitable for application to control methods that require high order, especially in the design of controllers where the control term includes a differential term. Compared with P control, the proposed controller has better tracking ability to reduce the tracking errors in both position and orientation.

Author Contributions

Conceptualization, B.-G.J. and M.-Y.C.; methodology, B.-G.J. and M.-Y.C.; software, B.-G.J.; validation, M.-Y.C.; formal analysis, B.-G.J.; investigation, B.-G.J.; resources, B.-G.J. and M.-Y.C.; data curation, B.-G.J. and M.-Y.C.; writing—original draft preparation, B.-G.J.; writing—review and editing, M.-Y.C.; visualization, B.-G.J.; supervision, M.-Y.C.; project administration, M.-Y.C.; funding acquisition, M.-Y.C. All authors have read and agreed to the published version of the manuscript.

Funding

This research was funded by the National Science and Technology Council, grant number MOST 110-2221-E-003-022.

Data Availability Statement

Not applicable.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Mercy, T.; Van Parys, R.; Pipeleers, G. Spline-Based Motion Planning for Autonomous Guided Vehicles in a Dynamic Environment. IEEE Trans. Control Syst. Technol. 2018, 26, 2182–2189. [Google Scholar] [CrossRef]
  2. Doh, N.L.; Kim, C.; Chung, W.K. A Practical Path Planner for the Robotic Vacuum Cleaner in Rectilinear Environments. IEEE Trans. Consum. Electron. 2007, 53, 519–527. [Google Scholar] [CrossRef]
  3. Stephan, J.; Fink, J.; Kumar, V.; Ribeiro, A. Concurrent Control of Mobility and Communication in Multirobot Systems. IEEE Trans. Robot. 2017, 33, 1245–1254. [Google Scholar] [CrossRef]
  4. Yao, J.; Lin, C.; Xie, X.; Wang, A.J.; Hung, C.C. Path Planning for Virtual Human Motion Using Improved A* Star Algorithm. In Proceedings of the 7th International Conference on Information Technology: New Generations, Las Vegas, NV, USA, 12–14 April 2010. [Google Scholar]
  5. Salzman, O.; Halperin, D. Asymptotically Near-Optimal RRT for Fast, High-Quality Motion Planning. IEEE Trans. Robot. 2016, 32, 473–483. [Google Scholar] [CrossRef] [Green Version]
  6. Cui, R.; Li, Y.; Yan, W. Mutual Information-Based Multi-AUV Path Planning for Scalar Field Sampling Using Multidimensional RRT*. IEEE Trans. Syst. Man Cybern. Syst. 2016, 45, 993–1004. [Google Scholar] [CrossRef]
  7. Chen, L.; Shan, Y.; Tian, W.; Li, B.; Cao, D. A Fast and Efficient Double-Tree RRT*-Like Sampling-Based Planner Applying on Mobile Robotic Systems. IEEE ASME Trans. Mechatron. 2018, 23, 2568–2578. [Google Scholar] [CrossRef]
  8. Cheon, H.; Kim, B.K. Online Bidirectional Trajectory Planning for Mobile Robots in State-Time Space. IEEE Trans. Ind. Electron. 2019, 66, 4555–4565. [Google Scholar] [CrossRef]
  9. Kim, D.H.; Oh, J.H. Tracking control of a two-wheeled mobile robot using input–output linearization. Control Eng. Pract. 1999, 7, 369–373. [Google Scholar] [CrossRef]
  10. Samson, C. Time-varying feedback stabilization of car like wheeled mobile robot. Int. J. Robot. Res. 1993, 12, 55–64. [Google Scholar] [CrossRef]
  11. Defoort, M.; Murakami, T. Sliding-Mode Control Scheme for an Intelligent Bicycle. IEEE Trans. Ind. Electron. 2009, 56, 3357–3368. [Google Scholar] [CrossRef]
  12. Tsai, C.C.; Huang, H.C.; Lin, S.C. Adaptive Neural Network Control of a Self-Balancing Two-Wheeled Scooter. IEEE Trans. Ind. Electron. 2010, 57, 1420–1428. [Google Scholar] [CrossRef]
  13. Yang, S.X.; Zhu, A.; Yuan, G.; Meng, M.Q.H. A Bioinspired Neurodynamics-Based Approach to Tracking Control of Mobile Robots. IEEE Trans. Ind. Electron. IEEE Trans. Ind. Electron. 2012, 59, 3211–3220. [Google Scholar] [CrossRef] [Green Version]
  14. Sašo, B. On periodic control laws for mobile robots. IEEE Trans. Ind. Electron. 2014, 61, 3660–3670. [Google Scholar]
  15. Jiang, Z.-P.; Nijmeijer, H. Tracking Control of Mobile Robots: A Case Study in Backstepping. Automatica 1997, 33, 1393–1399. [Google Scholar]
  16. Chen, X.; Jia, Y.; Matsuno, F. Tracking Control for Differential-Drive Mobile Robots with Diamond-Shaped Input Constraints. IEEE Trans. Control Syst. Technol. 2014, 22, 1999–2006. [Google Scholar] [CrossRef]
  17. Park, B.S.; Yoo, S.J.; Park, J.B.; Choi, Y.H. A Simple Adaptive Control Approach for Trajectory Tracking of Electrically Driven Nonholonomic Mobile Robots. IEEE Trans. Control Syst. Technol. 2010, 18, 1199–1206. [Google Scholar] [CrossRef]
  18. Hwang, C.-L. Comparison of Path Tracking Control of a Car-Like Mobile Robot with and without Motor Dynamics. IEEE/ASME Trans. Mechatrons. 2016, 21, 1801–1811. [Google Scholar] [CrossRef]
  19. Do, K.D.; Jiang, Z.-P.; Pan, J. Simultaneous tracking and stabilization of mobile robots: An adaptive approach. IEEE Trans. Autom. Control 2004, 49, 1147–1152. [Google Scholar] [CrossRef]
  20. Jhong, B.-G.; Yang, Z.-X.; Chen, M.-Y. An Adaptive Controller with Dynamic Gain Adjustment for Wheeled Mobile Robot. In Proceedings of the Joint 10th International Conference on Soft Computing and Intelligent Systems (SCIS) and 19th International Symposium on Advanced Intelligent Systems (ISIS), Toyama, Japan, 5–8 December 2018. [Google Scholar]
Figure 1. The kinematic model of two-wheeled differential mobile robot in 2-D plane.
Figure 1. The kinematic model of two-wheeled differential mobile robot in 2-D plane.
Actuators 11 00303 g001
Figure 2. An example of path smoothing on a 5-point path.
Figure 2. An example of path smoothing on a 5-point path.
Actuators 11 00303 g002
Figure 3. An example of trapezoidal velocity profile to replace an arc curve. (a) Moving trajectory from [0, 0, 0] to [1.7100, 1.5934, 1.4997]; (b) trapezoidal linear and angular velocities.
Figure 3. An example of trapezoidal velocity profile to replace an arc curve. (a) Moving trajectory from [0, 0, 0] to [1.7100, 1.5934, 1.4997]; (b) trapezoidal linear and angular velocities.
Actuators 11 00303 g003
Figure 4. The complete path planning process proposed in this paper.
Figure 4. The complete path planning process proposed in this paper.
Actuators 11 00303 g004
Figure 5. The membership functions of e and u0. [es, em, el] is the three-level scale of e, and the [z, s, m, l, f] is the five-level scale of u0.
Figure 5. The membership functions of e and u0. [es, em, el] is the three-level scale of e, and the [z, s, m, l, f] is the five-level scale of u0.
Actuators 11 00303 g005
Figure 6. The structure diagram of the proposed controller.
Figure 6. The structure diagram of the proposed controller.
Actuators 11 00303 g006
Figure 7. An example to show the results of obstacle avoidance.
Figure 7. An example to show the results of obstacle avoidance.
Actuators 11 00303 g007
Figure 8. This path planning results from start point (15, −30) to goal point (270, −212). The origin is set at the upper left corner. (a) The path planned by BRRT (blue line) and the searching tree (red line). (b) The improved path by path pruning and path smoothing.
Figure 8. This path planning results from start point (15, −30) to goal point (270, −212). The origin is set at the upper left corner. (a) The path planned by BRRT (blue line) and the searching tree (red line). (b) The improved path by path pruning and path smoothing.
Actuators 11 00303 g008
Figure 9. The linear and angular velocities of the smoothed path.
Figure 9. The linear and angular velocities of the smoothed path.
Actuators 11 00303 g009
Figure 10. The tracking results of P controller and proposed controller: (a) global view and (b) enlarged view to the goal point.
Figure 10. The tracking results of P controller and proposed controller: (a) global view and (b) enlarged view to the goal point.
Actuators 11 00303 g010
Figure 11. The tracking errors of P controller and proposed controller: (a) position error and (b) orientation error.
Figure 11. The tracking errors of P controller and proposed controller: (a) position error and (b) orientation error.
Actuators 11 00303 g011
Figure 12. The cumulative errors of P controller and proposed controller: (a) cumulative position error and (b) cumulative orientation error.
Figure 12. The cumulative errors of P controller and proposed controller: (a) cumulative position error and (b) cumulative orientation error.
Actuators 11 00303 g012
Table 1. The role table of fuzzy logic control.
Table 1. The role table of fuzzy logic control.
u0zsmlf
e
sSRNCNCNCSI
mSRSRNCSISI
lHRSRNCSIHI
Table 2. Parameters of path smoothing.
Table 2. Parameters of path smoothing.
NameValueNameValue
vmax10 m/sωmax0.12 rad/s
amax0.5 m/s2αmax0.04 rad/s2
vratio0.95rmax1000 m
h0.01 s
Table 3. Performance of path pruning and path smoothing.
Table 3. Performance of path pruning and path smoothing.
Original PathPruned PathSmoothed Path
Length (m)Num of TurnsLength (m)Num of TurnsLength (m)Num of Turns
average1640.3269.691357.822.2101284.822.210
minimum1550.02451304.6181258.518
maximum1747.42951430.5261333.126
std. dev.44.85410.22528.2831.695516.7071.6955
Table 4. The parameters of the robot and the gains of proposed controller.
Table 4. The parameters of the robot and the gains of proposed controller.
Parameters
NameValueNameValue
R0.6 mmw0.7 kg
d0.2 mIc14.73 kgm2
r0.1 mIw0.004 kgm2
mc25 kgIm0.002 kgm2
rar, ral2.2 ΩKtr, ktl0.281 oz-in/A
d11, d123 mnar, nal50
ker, kel0.18 V/rad/sumax48 V
Gains
NameValueNameValue
kx3γ130
ky3γ230
kθ3γ30.001
kv4δ110
Table 5. Average tracking errors of P controller and proposed controller.
Table 5. Average tracking errors of P controller and proposed controller.
P ControllerProposed Controller
Position Error (m)Orientation Error (rad)Position Error (m)Orientation Error (rad)
average8.93940.11590.01770.0070
Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Share and Cite

MDPI and ACS Style

Jhong, B.-G.; Chen, M.-Y. An Enhanced Navigation Algorithm with an Adaptive Controller for Wheeled Mobile Robot Based on Bidirectional RRT. Actuators 2022, 11, 303. https://doi.org/10.3390/act11100303

AMA Style

Jhong B-G, Chen M-Y. An Enhanced Navigation Algorithm with an Adaptive Controller for Wheeled Mobile Robot Based on Bidirectional RRT. Actuators. 2022; 11(10):303. https://doi.org/10.3390/act11100303

Chicago/Turabian Style

Jhong, Bing-Gang, and Mei-Yung Chen. 2022. "An Enhanced Navigation Algorithm with an Adaptive Controller for Wheeled Mobile Robot Based on Bidirectional RRT" Actuators 11, no. 10: 303. https://doi.org/10.3390/act11100303

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop