**5.1 Validation of steering angle against the human driver**

For this analysis, three responses were observed, namely, vehicle trajectories, lateral error, and vehicle wheel angle throughout the manoeuvrings, which are single lane change and double lane change from **Figure 11**, and described in detail in Section 4.1. The actual data from the instrumented vehicle are compared against the simulation results with the adaptive controller using the same trajectory and road courses in **Figure 12** and constant vehicle speed of 20 km/h. **Figure 21** shows the comparison between experimental results by the human driver and simulation results by the adaptive controller for the single lane change manoeuvring. Meanwhile, **Figure 22** shows the same comparison for the double lane change manoeuvring.

In both figures, graphs in (*a*) show the vehicle trajectories, which indicate that the proposed controller managed to automatically provide correctional steering input in guiding the vehicle closer to the desired trajectories. There is a noticeable

#### **Figure 21.**

*Comparison between experimental results and simulations for single lane change road: (a) vehicle trajectory, (b) lateral error w.r.t. trajectory, (c) steering input required.*

*Knowledge-Based Controller Optimised with Particle Swarm Optimisation for Adaptive Path… DOI: http://dx.doi.org/10.5772/intechopen.92667*

#### **Figure 22.**

*Comparison between experimental results and simulations for double lane change road: (a) vehicle trajectory, (b) lateral error w.r.t. trajectory, (c) steering input required.*

overshoot in vehicle trajectory from simulation (*X* = 80 m) for both manoeuvrings, which can be attributed to the speed of the vehicle. In the experiment, it was hard to keep the constant speed, and human instinct has caused the driver to slow down the vehicle while navigating sharp corners, whereby the speed was kept constant throughout the simulations. This has caused dissimilarities between the two results. Also, the road courses used here are very short, which may account to the inabilities of the controller, as well as the human driver, to perfectly track the trajectories. Nevertheless, the controller did well in steering the vehicle. This can be further studied through the lateral error results shown in graphs (*b*). The adaptive controller recorded better lateral error 82 and 78% less RMS values for single lane change and double lane change manoeuvrings, respectively.

Looking at the wheel angle from graphs (*c*), one can observe the correctional steering input provided by the human driver in the experiment, as well as the inputs from the adaptive controller in simulation. Compared against the human driver for the same manoeuvrings, the controller provides the steering input to the wheel with the same trend and input shape as the human driver, but with a faster response. Having a fast controller is always advantageous for any unaccountable delays and uncertainties that may happen in real implementation. Also, the controller is able to adapt to various speeds and trajectories while mimicking the human driver actions, which was proven from the results presented here.

#### **6. Conclusions**

In this study, an adaptive controller for an autonomous heavy vehicle is presented. The controller was developed based on an established Stanley controller that was modified to increase its sensitivity to the parameter changes. An adaptive algorithm was constructed to automatically tune the controller parameters based on the instantaneous vehicle speeds, *v*, and heading error, *ϕ*, between the vehicle and road course

trajectory. In constructing the adaptive algorithm, a knowledge database was built by optimising a set of parameters for the modified Stanley controller that corresponds to various combinations of *v* and *ϕ* using particle swarm optimisation.

The developed controller was applied on a validated 7DOF, nonlinear heavy vehicle model. Six trajectories were chosen representing long and short courses as well as courses with large and very small turning curvatures. With these, a series of simulations were carried out, and the performance of the proposed controller was compared against the basic original Stanley and also the modified Stanley controllers.

From the simulations, it was found that the proposed adaptive controller performed well in guiding the vehicle along all trajectories. It recorded significantly lower lateral error RMS between 61 and 82*%* improvement when compared against the original Stanley controller. However, 48–89*%* increases in lateral error RMS were observed when comparing the controller against the modified Stanley controller. This can be explained by the fact that the Mod St controller was optimised specifically for the respective courses and, therefore, performed exceptionally well on the roads.

In terms of the controller's ability in adapting to various trajectories and vehicle speeds, the controller was tested with various vehicle speeds within and outside of the knowledge database region. It was capable of navigating the vehicle smoothly regardless of the vehicle speed, with understandably larger error in maximum speed. However, the overall lateral error was well kept below 1 *m*. While the maximum testing speed was 30 m/s, the autonomous heavy vehicle will be operating with speeds much lower than that. Previous studies and implementations of autonomous passenger's vehicles have been recorded to operate with about 10 m/s and lower [4, 25, 26]. In this study, the proposed adaptive controller has managed to perform well without depending on any planner to provide a smooth trajectory. This ensures the applicability of the proposed controller to be operated on a heavy vehicle on various trajectories and vehicle speed values.
