## 4 Conclusions  
Motorcycle balancing is achieved through front-wheel steering, which compensates for the steering angle to maintain stability during cornering and lane changes, thereby avoiding obstacles. Additionally, pre-emptive braking adjusts the speed to a desired value while navigating curves, enhancing the motorcycle's active safety performance. In motorcycle control, there is a particularly high demand for real-time performance and stability. The PID controller, known for its maturity and widespread application, offers excellent versatility and robustness in system design, effectively managing various operational conditions. While fuzzy logic control can address uncertainty, its design and tuning process is more \begin{table}
\begin{tabular}{c c c c c c} \hline \hline \multirow{2}{*}{**Scenarios**} & **Max Lateral** & **Max Roll Angle** & **Max Steering** & **Max Torque** & **Whether It Is** \\  & **Deviation (m)** & **(deg)** & **Angle (deg)** & **(N-m)** & **Stable** \\ \hline Double lane change & 0.6 & 12 & 0.35 & 10 & Yes \\ High-friction cornering & 0.48 & 39 & 0.4 & 10 & Yes \\ Low-friction cornering (without pre-braking) & Exceed & Rollover & - & - & No \\ Low-friction cornering (with pre-braking) & 0.25 & 15 & 1.6 & 3.2 & Yes \\ Low-friction cornering with driver lean & 0.15 & 11 & 1.5 & 2.5 & Yes \\ consideration (with pre-braking) & & & & & \\ \hline \hline \end{tabular}
\end{table} 
Table 2: Summary of results under different scenarios. Figure 13: Results on slippery curved road (initial \(v=72\) km/h, \(R=60\) m, \(\mu=0.3\)). complex and requires a thorough understanding of fuzzy rules and membership functions. In contrast, the PID controller has a straightforward structure that is easy to implement and debug, with intuitive parameter adjustments, making it well-suited for rapid iteration. The effectiveness of the proposed control system is validated through joint simulations using Matlab/Simulink and BikeSim under three typical operating conditions. The study concludes with the following findings:  
(1) In the double lane change collision avoidance scenario, the actual trajectory remained within the lane width, ensuring that the motorcycle stayed within the lane throughout the maneuver. The maximum lateral tracking error did not exceed 0.6 m, and the maximum lateral inclination angle remained below 15 degrees. The adjustments in front-wheel steering angle and handlebar torque were gradual, resulting in the eventual stabilization of the motorcycle. (2) In the dry pavement curve condition, navigating a circular curve with a radius of 60 m at a speed of 72 km/h resulted in a maximum lateral inclination angle of nearly 40\({}^{\circ}\), compared to approximately 15\({}^{\circ}\) in the double lane change scenario. Despite this increased inclination, lateral deviation was maintained within \(\pm\)0.6 m, ensuring the motorcycle remained within the lane at all times. The compensation of the front-wheel steering angle effectively mitigated any risk of rollover. (3) Under wet and slippery road conditions, the motorcycle entered the curve at a speed of 72 km/h without pre-emptive braking intervention. Within a second, the motorcycle overturned as the lateral inclination angle rapidly exceeded 80 degrees. However, by integrating the pre-emptive braking system with the self-balancing system, the motorcycle decelerated to a safe speed before entering the curve. During the passage through the curve, the lateral inclination angle stabilized at a maximum of approximately 15\({}^{\circ}\), and lateral deviation was reduced to within 0.25 m, resulting in improved stability. In this study, we focused solely on the self-balancing trajectory tracking of motorcycles at medium speeds with a fixed road curvature. We did not investigate motorcycle trajectory tracking at speeds below 36 km/h or above 72 km/h. Future studies should address stability control at low and high speeds, as well as the impact of varying road curvatures and speeds on motorcycle stability.