# Trajectory Optimization with Dynamic Drivable Corridor-Based Collision Avoidance
## 4 Simulation Results and Discussion  
To verify the effectiveness of the proposed approach, the formulated continuous-time OCP (6) is solved numerically. By discretizing the time domain, the formulated continuous-time OCP (6) is transformed into a nonlinear programming (NLP) problem [30]. In this process, the state variables \((x(t),y(t),\theta(t),v(t),\phi(t))\) and control variables \((a(t),\omega(t))\) are discretized in the time domain, representing them as a set of discrete decision variables. Furthermore, the objective function (5) and constraints associated with the problem, such as the vehicle kinematic constraints (1) and (2) and collision avoidance constraints (11), also need to be discretized, converting them into algebraic equations or inequality constraints at discrete time points. In this study, we selected the interior point method [31] as the solver for the NLP problem, leveraging its efficient and stable characteristics to rapidly obtain the optimal solution, providing accurate numerical results for trajectory planning or motion control. All simulations were performed in MATLAB 2023a and executed on an R7-7735H CPU with 16 GB RAM that runs at 3.2 \(\times\) 8 GHz. The basic simulation parameters are listed in Table 2 These parameters are based on the physical specifications of a typical passenger vehicle, ensuring that the simulation settings reflect realistic vehicle dynamics. The deployment scenarios are predominantly composed of stochastically generated, unstructured environments that capture a broad spectrum of obstacle complexity and variability. These settings are intended to simulate realistic and demanding conditions, thereby offering a rigorous and representative benchmark for assessing the proposed method's generalizability and robustness. In these simulations, Hybrid A* is employed to generate initial trajectories due to its effectiveness in unstructured environments with nonholonomic constraints. However, it is important to note that this work focuses on accelerating the modeling of collision avoidance constraints during the trajectory optimization stage. The proposed scheme is designed to be independent of any specific initial path generation strategy and is compatible with a wide range of planners. As shown in Figure 8, the effectiveness of the proposed DC construction scheme is validated in an unstructured scenario with randomly generated obstacles. In Figure 8, obstacles influencing the DC construction process are represented by blue grids, while polygonal obstacles not covered by blue grids are identified as irrelevant to DC construction through an intelligent filtering mechanism and excluded from the process. The figure demonstrates that both front and rear DCs remain collision-free with the expanded obstacles, satisfying safety requirements. This result preliminarily indicates that our scheme not only intelligently filters out irrelevant obstacles but also ensures safety compliance. In Figure 9, we present the performance of the proposed planning algorithm in four typical scenarios. As the vehicle follows the optimized path, it successfully avoids all occupied cells, remaining free of collisions with the transformed grid-based obstacles. This indicates that the planned trajectory ensures both spatial safety and feasibility. The vehicle thus satisfies collision avoidance requirements and remains kinematically feasible, providing preliminary evidence for the validity of our algorithm.