# Obstacle Avoidance of Semi-Trailers Based on Nonlinear Model Predictive Control

^{1}

^{2}

^{*}

## Abstract

**:**

## 1. Introduction

## 2. Obstacle Avoidance Model

#### 2.1. Kinematics Model

_{f}and δ are the control inputs.

#### 2.2. Obstacle Avoidance Model

## 3. MPC Controller Design

#### 3.1. Prediction Model

#### 3.2. Optimization Function

**P**is the weight matrix.

## 4. Simulation

**Q**and

**R**are the weight matrices of the optimization function of the path tracking control.

#### 4.1. First Group

#### 4.2. Second Group

#### 4.3. Third Group

## 5. Conclusions

## Author Contributions

## Funding

## Conflicts of Interest

## Notation

δ | The angle of the steering wheels of the semi-trailer |

v_{f} | The longitudinal velocity of the tractor |

v_{r} | The longitudinal velocity of the trailer |

θ_{f} | Heading of the tractor |

θ_{r} | Heading of the trailer |

γ | The angle between the tractor and the trailer |

P (x_{f}, y_{f}) | The midpoint of the equivalent rear axle of the tractor The articulation point of the tractor and the trailer |

P_{ff} (x_{ff}, y_{ff}) | The midpoint of the front end of the tractor |

P_{fr} (x_{fr}, y_{fr}) | The midpoint of the rear end of the tractor |

P_{rf} (x_{rf}, y_{rf}) | The midpoint of the front end of the trailer |

P_{rr} (x_{rr}, y_{rr}) | The midpoint of the rear end of the trailer |

l_{fa} | Distance between the front axle and the front end of the tractor |

l_{fb} | The wheelbase of the tractor |

l_{fc} | Distance between the rear axle and the rear end of the tractor |

l_{ra} | Distance between the articulation point and the front end of the trailer |

l_{rb} | Distance between the articulation point and the axle of the trailer |

l_{rc} | Distance between the axle and the rear end of the trailer |

A | The area in front of the tractor |

B | The area on the side of the tractor |

C | The area behind the tractor |

l_{1} | The straight line perpendicular to the body at point P_{ff}, the parametric formula of lines y = cot(θ_{f})(x − x_{ff}) + y_{ff} |

l_{2} | The straight line perpendicular to the body at point P_{fr}, the parametric formula of lines y = cot(θ_{f})(x − x_{fr}) + y_{fr} |

l_{3} | Middle line of the tractor, parametric formula of lines y = tan(θ_{f})(x − x_{f}) + y_{f} |

d_{1} | Distance between the obstacle center and l_{1} |

d_{2} | Distance between the obstacle center and l_{2} |

d_{3} | Distance between the obstacle center and l_{3} |

D | The area in front of the trailer |

E | The area on the side of the trailer |

F | The area behind the trailer |

l_{4} | The straight line perpendicular to the body at point P_{rf}, the parametric formula of lines y = cot(θ_{r})(x − x_{rf}) + y_{rf} |

l_{5} | The straight line perpendicular to the body at point P_{fr}, the parametric formula of lines y = cot(θ_{r})(x − x_{rr}) + y_{rr} |

l_{6} | The middle line of the trailer, the parametric formula of lines y = tan(θ_{r})(x − x_{f}) + y_{f} |

d_{4} | Distance between the obstacle center and l_{4} |

d_{5} | Distance between the obstacle center and l_{5} |

d_{6} | Distance between the obstacle center and l_{6} |

## References

- Larson, J. Off-Road Obstacle Classification and Traversability Analysis in the Presence of Negative Obstacles. Master’s Thesis, University of California, San Diego, CA, USA, 2011. [Google Scholar]
- Qiu, Q.; Yang, T.W.; Han, J.D. A new real-time algorithm for off-road terrain estimation using laser data. Sci. China Ser. F (Inf. Sci.)
**2009**, 52, 1658–1667. [Google Scholar] [CrossRef] [Green Version] - Yuan, J. Hierarchical motion planning for multi-steering tractor-trailer mobile robots with on-axle hitching. IEEE-ASME Trans. Mech.
**2017**, 22, 1652–1662. [Google Scholar] [CrossRef] - Sgorbissa, A.; Zaccaria, R. Planning and obstacle avoidance in mobile robotics. Robot. Auton. Syst.
**2012**, 60, 628–638. [Google Scholar] [CrossRef] - Fahimi, F.; Nataraj, C.; Ashrafiuon, H. Real-time obstacle avoidance for multiple mobile robots. Robotica
**2009**, 27, 189–198. [Google Scholar] [CrossRef] - Maciejowski, J.M. Introduction. In Predictive Control: With Constraints; Pearson Education: New York, NY, USA, 2002; pp. 1–32. [Google Scholar]
- Yoon, Y.; Shin, J.; Kim, H.J.; Park, Y.; Sastry, S. Model-predictive active steering and obstacle avoidance for autonomous ground vehicles. Control Eng. Pract.
**2009**, 17, 741–750. [Google Scholar] [CrossRef] - Frasch, J.V.; Gray, A.; Zanon, M.; Ferreau, H.J. An auto-generated nonlinear MPC algorithm for real-time obstacle avoidance of ground vehicles. In Proceedings of the 2013 European Control Conference, Zurich, Switzerland, 17–19 July 2013. [Google Scholar] [CrossRef]
- Gong, J.W.; Jiang, Y.; Xu, W. Trajectory tracking control with planning layer. In Model Predictive Control for Self-Driving Vehicles; Beijing Institute of Technology Press: Beijing, China, 2014; Chapter 6; pp. 134–170. (In Chinese) [Google Scholar]
- Nayl, T.; Nikolakopoulos, G.; Gustafsson, T. Effect of kinematic parameters on MPC based on-line motion planning for an articulated vehicle. Robot. Auton. Syst.
**2015**, 70, 16–24. [Google Scholar] [CrossRef] [Green Version] - Wang, M.; Luo, J.; Walter, U. A non-linear model predictive controller with obstacle avoidance for a space robot. Adv. Space Res.
**2016**, 57, 1737–1746. [Google Scholar] [CrossRef] - Liu, J.; Jayakumar, P.; Stein, J.L.; Ersal, T. A double-worst-case formulation for improving the robustness of an MPC-based obstacle avoidance algorithm to parametric uncertainty. In Proceedings of the 2017 American Control Conference, Seattle, WA, USA, 24–26 May 2017. [Google Scholar] [CrossRef]
- Liu, J.; Jayakumar, P.; Stein, J.L.; Ersal, T. Combined speed and steering control in high-speed autonomous ground vehicles for obstacle avoidance using model predictive control. IEEE Trans. Veh. Technol.
**2017**, 66, 8746–8763. [Google Scholar] [CrossRef] - Hua, X.F.; Duan, J.M.; Tian, X.S. Research on vehicle obstacle avoidance based on restricted areas penalty function and MPC prediction multiplication. Comput. Eng. Appl.
**2018**, 54, 131–138. (In Chinese) [Google Scholar] - Bai, G.; Liu, L.; Meng, Y.; Luo, W.; Gu, Q.; Liang, C. Study of obstacle avoidance controller of agricultural tractor-trailers based on predictive control of nonlinear model. Trans. Chin. Soc. Agric. Mach.
**2019**, 50, 356–362. (In Chinese) [Google Scholar] [CrossRef] - Zong, C.; Zhu, T.; Wang, C.; Liu, H. Multi-objective stability control algorithm of heavy tractor semi-trailer based on differential braking. Chin. J. Mech. Eng.
**2012**, 25, 88–97. [Google Scholar] [CrossRef] - Lima, P.F.; Nilsson, M.; Trincavelli, M.; Martensson, J.; Wahlberg, B. Spatial model predictive control for smooth and accurate steering of an autonomous truck. IEEE Trans. Intell. Veh.
**2017**, 2, 238–250. [Google Scholar] [CrossRef] - Wu, T.; Hung, J.Y. Path following for a tractor-trailer system using model predictive control. In Proceedings of the SoutheastCon 2017, Charlotte, NC, USA, 30 March–2 April 2017. [Google Scholar] [CrossRef]
- Nayl, T.; Nikolakopoulos, G.; Gustafsson, T. A full error dynamics switching modeling and control scheme for an articulated vehicle. Int. J. Control Autom.
**2015**, 13, 1221–1232. [Google Scholar] [CrossRef] [Green Version] - Bin, Y.; Shim, T. Constrained model predictive control for backing-up tractor-trailer system. In Proceedings of the 10th World Congress on Intelligent Control and Automation, Beijing, China, 6–8 July 2012. [Google Scholar] [CrossRef]
- Astolfi, A.; Bolzern, P.; Locatelli, A. Path-tracking of a tractor-trailer vehicle along rectilinear and circular paths: A Lyapunov-based approach. IEEE Trans. Robot. Autom.
**2004**, 20, 154–160. [Google Scholar] [CrossRef] - Backman, J.; Oksanen, T.; Visala, A. Navigation system for agricultural machines: Nonlinear model predictive path tracking. Comput. Electron. Agric.
**2012**, 82, 32–43. [Google Scholar] [CrossRef] - Kraus, T.; Ferreau, H.J.; Kayacan, E.; Ramon, H.; De Baerdemaeker, J.; Diehl, M.; Saeys, W. Moving horizon estimation and nonlinear model predictive control for autonomous agricultural vehicles. Comput. Electron. Agric.
**2013**, 98, 25–33. [Google Scholar] [CrossRef] - Oyelere, S.S. The application of model predictive control (MPC) to fast systems such as autonomous ground vehicles (AGV). IOSR J. Comput. Eng.
**2014**, 16, 27–37. [Google Scholar] [CrossRef] - Kayacan, E.; Kayacan, E.; Ramon, H.; Saeys, W. Learning in centralized nonlinear model predictive control: Application to an autonomous tractor-trailer system. IEEE Trans. Control Syst. Technol.
**2015**, 23, 197–205. [Google Scholar] [CrossRef] - Du, X.; Htet, K.K.K.; Tan, K.K. Development of a genetic-algorithm-based nonlinear model predictive control scheme on velocity and steering of autonomous vehicles. IEEE Trans. Ind. Electron.
**2016**, 63, 6970–6977. [Google Scholar] [CrossRef] - Gong, J.W.; Xu, W.; Jiang, Y.; Liu, K.; Guo, H.F.; Sun, Y.J. Multi-constrained model predictive control for autonomous ground vehicle trajectory tracking. J. Beijing. Inst. Technol.
**2015**, 24, 441–443. [Google Scholar]

**Figure 7.**The trajectory of the obstacle avoidance controller based on the line model in the first group of simulations.

**Figure 8.**Partially enlarged view of Figure 7.

**Figure 9.**The trajectory of the obstacle avoidance controller based on the circumcircle model in the first group of simulations.

**Figure 10.**Partially enlarged view of Figure 9.

**Figure 14.**Heading error between the tractor and the reference path in the first group of simulations.

**Figure 15.**The trajectory of the obstacle avoidance controller based on the line model in the second group of simulations.

**Figure 16.**Partially enlarged view of Figure 15.

**Figure 17.**The trajectory of the obstacle avoidance controller based on the circumcircle model in the second group of simulations.

**Figure 18.**Partially enlarged view of Figure 17.

**Figure 22.**Heading error between the tractor and the reference path in the second group of simulations.

**Figure 23.**The trajectory of the obstacle avoidance controller based on the line model in the third group of simulations.

**Figure 24.**Partially enlarged view of Figure 23.

**Figure 28.**Heading error between the tractor and the reference path in the third group of simulations.

Parameter | Value | Parameter | Value | Parameter | Value |
---|---|---|---|---|---|

l_{fa} | 1 m | l_{b} | 1.25 m | P | 100,000 I |

l_{fb} | 4 m | l_{r} | 0.5 m | Q | 10 I |

l_{fc} | 1.5 m | l_{s} | 0.45 m | R | 0.01 I |

l_{ra} | 1.5 m | T | 0.05 s | I | identity matrix |

l_{rb} | 6.5 m | N_{p} | 200 | ||

l_{rc} | 2 m | N_{c} | 1 |

© 2019 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).

## Share and Cite

**MDPI and ACS Style**

Bai, G.; Liang, C.; Meng, Y.; Liu, L.; Luo, W.; Gu, Q.
Obstacle Avoidance of Semi-Trailers Based on Nonlinear Model Predictive Control. *World Electr. Veh. J.* **2019**, *10*, 72.
https://doi.org/10.3390/wevj10040072

**AMA Style**

Bai G, Liang C, Meng Y, Liu L, Luo W, Gu Q.
Obstacle Avoidance of Semi-Trailers Based on Nonlinear Model Predictive Control. *World Electric Vehicle Journal*. 2019; 10(4):72.
https://doi.org/10.3390/wevj10040072

**Chicago/Turabian Style**

Bai, Guoxing, Chen Liang, Yu Meng, Li Liu, Weidong Luo, and Qing Gu.
2019. "Obstacle Avoidance of Semi-Trailers Based on Nonlinear Model Predictive Control" *World Electric Vehicle Journal* 10, no. 4: 72.
https://doi.org/10.3390/wevj10040072