# Research on Decision-Making Methods for Autonomous Navigation in Inland Tribitary Waterways
## 2 Analysis of the Autonomous Navigation Process
### Autonomous Route Tracking Without the Risk of Collision
#### 2.1.2 Route Tracking Model  
The target waypoint on the recommended route defines the desired course angle \(\psi_{\text{LOS}}\) between true north and the line connecting the ship to the target waypoint. The target waypoint position is determined by the forward distance (longitudinal tracking error), specifically as a point located a predefined distance ahead of the ship's orthogonal projection onto the recommended route. Here, \(y_{e}(t)\) denotes the cross-track error (lateral deviation from the recommended route), while \(\Delta\) represents the along-track error. The line connecting the target waypoint to the ship defines the planned tracking trajectory, with the ultimate objective of restoring the ship to the recommended route. Furthermore, the system must regulate the ship's heading to align with the recommended route direction, ensuring stable navigation along the prescribed path. This paper employs an enhanced Line-of-Sight (LOS) guidance algorithm to compute both target waypoints and desired headings, whose operational principle is illustrated in the following Figure 2.  
Based on this, the ship's target course \(\psi_{\text{LOS}}\) is calculated as follows, with \(\gamma_{p}\) denoting the course of the recommended route.  
\[\psi_{\text{LOS}}\triangleq\gamma_{p}-\tan^{-1}\bigg{(}\frac{y_{e}(t)}{\Delta }\bigg{)} \tag{7}\]  
Figure 2: Improved LOS guidance algorithm.  
A larger longitudinal tracking error correlates with slower convergence rates. However, given a ship's significant inertia and underactuated maneuvering characteristics, vessels cannot instantaneously respond to course correction commands to align with the recommended route. This inherent limitation often causes trajectory overshoot during route recovery. Setting the longitudinal tracking error as a fixed parameter fails to guarantee rapid and smooth route tracking across all operational scenarios. To enable fast yet stable route tracking under varying deviation magnitudes, we define an adaptive longitudinal tracking error function as Equations (8) and (9).  
\[f(x)=\left\{\begin{array}{l}0\quad\quad\quad x\leq x_{\min}\\ \frac{1}{2}\Big{(}1-\cos\frac{\pi(x-x_{\min})}{s_{\max}-x_{\min}}\Big{)}\;\;x_ {\min}\leq x\leq x_{\max}\\ 1\quad\quad\quad\quad\quad\quad\quad x\geq x_{\max}\end{array}\right. \tag{8}\]  
\[\Delta=\Delta_{\min}+(\Delta_{\max}-\Delta_{\min})[1-f(y_{e}(t))] \tag{9}\]  
The function \(f(x)\) is an S-shaped saturation function where the independent variable \(x\) represents the cross-track error \(y_{e}(t)\). With \(y_{min}\) and \(y_{max}\) defining the operational bounds of cross-track error, \(f(x)\) smoothly transitions from 0 to 1 with S-curvature as \(y_{e}(t)\) varies between \(y_{min}\) and \(y_{max}\). Consequently, the lookahead distance \(\Delta\) adaptively adjusts based on the cross-track error. The target heading angle \(\psi_{LOS}\) is formulated as  
\[\psi_{LOS}\triangleq\gamma_{p}-\tan^{-1}\bigg{(}\frac{y_{e}(t)}{\Delta_{\min }+(\Delta_{\max}-\Delta_{\min})[1-f(y_{e}(t))]}\bigg{)} \tag{10}\]  
\(\Delta_{\min}\) and \(\Delta_{\max}\) are the minimum and maximum values of the predefined forward-looking distance \(\Delta\), respectively. When the lateral distance error exceeds \(y_{\max}\), the forward-looking distance \(\Delta\) is set to its minimum value \(\Delta_{\min}\). This increases the angle between the line connecting the ship to the target waypoint and the recommended route, enabling the ship to rapidly approach the desired trajectory while avoiding control overshoots caused by excessive path deviation. Conversely, when the lateral distance error falls below \(y_{\min}\), the forward-looking distance \(\Delta\) is maximized to \(\Delta_{\max}\). This reduces the aforementioned angle, allowing the ship to converge smoothly to the recommended route.