Academic Journal of Science and Technology ISSN: 2771-3032 | Vol. 13, No. 2, 2024 302 Research on Complex Motion Path Optimisation Based on PDE Constraints and DeepONet Neural Network Models Yuhao Fang1, †, *, Yixuan Wang1, †, Zhenyuan Wei2, † 1Faculty of Engineering, Shenzhen MSU-BIT University, Shenzhen, China 2Faculty of Computational Mathematics and Cybernetics, Shenzhen MSU-BIT University, Shenzhen, China † These authors also contributed equally to this work *Corresponding author: fangyuhao@gmail.com Abstract: Aiming at the key motion path and speed control problem in a traditional folk performance, this paper designs a comprehensive optimization scheme. Combined with the constraints of partial differential equation (PDE), the position and velocity changes of each time node are calculated to ensure the smoothness of the motion and the rationality of the speed. In order to further improve the optimization effect, alternate direction multiplier method (ADMM) and DeepONet neural network model are introduced to realize the fine adjustment of path planning and speed control. The results show that this scheme not only improves the performance's appreciation, but also significantly enhances the execution's accuracy and operability. Keywords: Path planning, ADMM algorithm, DeepONet, PDE. 1. Introduction The purpose of this study is to solve the problem of path planning and speed control of performing teams in complex paths through mathematical modeling and numerical optimization [1]. We deeply analyze the motion characteristics of each component in the performance process, build an accurate motion model, and calculate the position and speed changes of each time node combined with PDE constraints [2]. On this basis, alternate direction multiplier method (ADMM) [3] and DeepONet neural network model were further introduced to optimize the path planning and speed control [4], in order to achieve the best performance effect. 2. The Establishment and Analysis of Spiral Motion Model Based on the complex movement trajectory, this paper takes the dragon dance activity as an example to analyze, aiming at the situation that the movement theme is rotated clockwise along the isometric spiral, it is necessary to establish a mathematical model to describe the whole movement process. Based on the pitch and the speed of the handle in front of the dragon head, the position and speed per second of each segment of the dragon dance team were calculated. In the whole process of the dragon dance team moving along the spiral line, in order to accurately describe the trajectory, the position of the center of the front handle of the board is calculated by geometric modeling section by section. These positions depend on the distance between the boards and their changes in position relative to the spiral, especially the connection between the body and the tail of the dragon. To this end, we use differential equations and wave equations to analyze its motion patterns, trajectories and velocity changes. 2.1. The Helix Model is Established The faucet is rotated clockwise along the isometric helix and the position is determined by time 𝑡. The polar coordinate equation of the helix can be expressed as [5]:   0 2 p r r     (1) Where, 𝑟 is the starting radius; 𝑝 is pitch; 𝜃 is the polar Angle, which varies with time. Parametric equation of a helix: A helix is a two- dimensional curve that can be described by a parametric equation, the two main variables of a helix are the radius and the Angle. The false faucet moves along the helix, and the position is determined by time. The equation for the helix can be expressed as:               cos sin x t r t t y t r t t       (2) Where, 𝑥 represents the coordinates of the movement of the faucet on the coordinate axis 𝑥 ; 𝑦 represents the coordinates of the movement of the faucet on the coordinate axis 𝑦. The speed at which the faucet is moving along a spiral 1 m/s. In order to calculate the position of the faucet, it is necessary to know the radius and Angle of the helix. Radius change: set the initial radius of the helix as 𝑟 0 , the time as 𝑡, and the pitch of the helix as ℎ. Radius of the helix per second:   head 0 2 v r t r t    (3) 303 Among them, 𝑣head the speed of the head. Angle change: the angular speed of movement of the faucet on the helix is:     head 0 v t t r t    (4) Position of the faucet: According to the helix equation, the two-dimensional plane position 𝑥, 𝑦 of the faucet at the moment of time 𝑡 is:               head head cos sin x t r t t y t r t t       (5) Rigid constraint model: Using the directional Angle 𝜃 𝑡 and the rigid rod length 𝐿 , the position of the first section 𝑖 board can be derived from the position of the previous section:               1 1 1 1 cos sin i i i i i i x t x t L t y t y t L t             (6) This method of calculation ensures that the section 𝑖 is always kept at a distance 𝑖 1 from the section as 𝑖 1. The wave equation: Since the movement of each stage of the dragon's body is lagging behind that of the previous stage, this effect can be described by the wave equation. Over time, the movement of the dragon head is gradually transmitted to the dragon body and tail like a wave. This wave effect makes the dragon dance team's movement on the spiral line appear a curved S-shaped motion. The Angle of each board of the dragon body and tail lags behind the dragon head. Assume that the length of each board boarding is 𝐿 220 cm , and the relative position of the position of the first board 𝑖 boarding and the head is:         lag i i r t r t i L t t i           (7) Where 𝜃 is the angular lag value of each section board, which is defined as a fixed value. The two-dimensional plane position 𝑥 , 𝑦 of the first section 𝑖 board boarding at the time moment 𝑡 is:               cos , sin . i i i i i i x t r t t y t r t t       (8)         2 2 2 2 2 2 2 2 2 2 , , , , , , x s t x s t c t s y s t y s t c t s            (9) Where, 𝑥 𝑠, 𝑡 and 𝑦 𝑠, 𝑡 respectively represents the horizontal and vertical coordinates of the dragon body in space position 𝑠 and time 𝑡, is the wave speed, 𝑐 represents the speed of the dragon dance team. Wave speed 𝑐 : The wave speed can be estimated by the speed of the dragon head and the physical parameters of the dragon body (such as the length of the board, the rigidity of the connection). The speed of the head determines the propagation speed of the wave, and the wave speed also affects the overall shape of the dragon dance team when it enters the plate. Wave Equation is used here to simulate the wave and delay effects of the dragon's body and tail. As shown in Figure 1, the motion of each part of the dragon dance team (head, body, tail) in time 𝑡 and space position 𝑠 (where the coordinates 𝑐 represent the direction of the dragon's length) can be described by the position field 𝑥 𝑠, 𝑡 and 𝑦 𝑠, 𝑡 [6]. The equation for the movement of the dragon head is: 2 2( ) d v dt a a      (10) Figure 1. Example of the position of the disc entry spiral 304 After it is discretized, the value of the polar Angle 𝜃 in each time step is computed iteratively by Runge Kutta method, and then the radial distance 𝑟 and position of the faucet 𝑥, 𝑦 are obtained. 2.2. Spiral Model Solution In order to calculate the position and velocity of each handle at the moment in time 𝑡, we need to take the derivative of 𝑟 0 and 𝜃 respectively with respect to time 𝑡. The steps are as follows: Calculation of the faucet: Speed is the derivative of position with respect to time. Velocity in the polar coordinate system can be decomposed into radial velocity and angular velocity. Radial velocity, radial velocity is the time derivative of the position: 𝑣 had , which can be obtained by simplification 𝑣 . Since 𝑟 𝜃 it changes over time, we need to update recursively according to the relationship between 𝜃 and 𝑡. Total velocity: The total velocity of the faucet is the combined velocity of the radial velocity and the tangential velocity:   2 2 head rv t v v  (11) Calculation of the speed of the dragon body and tail: Similarly, the speed of the 𝑖 section board is also synthesized from the radial and tangential velocity, the formula is similar to the speed of the dragon head, just replace the radius 𝑟 𝑡 and Angle with the corresponding sum 𝜃 𝑡 . But pay attention to the additional lag of the handle behind the dragon's tail. Boundary conditions and initial conditions: The boundary conditions of the faucet: The speed 1 m/s at which the handle of the faucet moves along the helix, and the position is controlled by the equation of the helix. At this point:                 0, cos 0, sin x t r t t y t r t t         (12) Among them, 𝜃 𝑡 is the polar Angle of the time moment faucet 𝑡 . From the speed of the faucet 𝑣head 1 m/s , the angular velocity can be obtained:     head 0, 0 vd dt r t       (13) This can be obtained from these assumptions 𝜃 𝑡 . The boundary condition of the dragon's tail: the movement of the dragon's tail lags behind the movement of the dragon and is affected by the fluctuations transmitted by the dragon's body. Its position can be solved by the wave equation. Initial condition: At time 𝑡 0, the whole dragon is in the form of the initial helix, and the initial velocity is zero.                     ,0 cos , ,0 sin ,0 ,0 0, 0 s r s s y s r s s x s y s t t            (14) In order to solve the partial differential equation of the dragon dance team movement, we use the finite difference method to discretize and numerically integrate the partial differential equation, and gradually solve the position and speed of each moment [7]. This method discretizes the continuous space and time and converts the PDE into a difference equation that can be solved by a computer algorithm to get the position and velocity of each moment By discretizing time and space, an approximate equation in the following format is obtained using the finite difference method:   2 1 1 1 1 Δ 2 2 Δ n n n n n n i i i i i i c t u u u u u u x              (15) Where: 𝑢 is the displacement of the section board 𝑖 boarding in the first time step 𝑛; 𝛥𝑡 is the time step length, 𝛥𝑥 is the space step length. 3. Dynamic Collision Detection Model Based on the spiral motion model established above, this chapter needs to determine the end time of the dragon dance team's disc entry, so that there is no collision between boards. As shown in Figure 2, by simulating the relative motion trajectory between boards and boards, the limit time of the dragon dance team's disc entry is found without collision. Step 1: Calculate the distance between adjacent nodes. We need to calculate the distance between each pair of adjacent nodes 𝑖 and 𝑖 1 . The distance formula based on polar coordinates is:               22 1 1i i i i i id t r t r t r t t t       (16) Where, 𝑟 𝑡 is the radial position of the time point 𝑡 and 𝜃 𝑡 is the polar Angle of the node. Step 2: Judgment of collision condition. If for any 𝑖 , there is 𝑑 𝑡 𝐿min 30 cm , then it is considered that the node 𝑖 and 𝑖 1 the collision occurred. In this case, record the time 𝑡collision。 when the collision occurred and the location and number of the collision node 𝑥 , 𝑦 . 305 Figure 2. An example of the position of the disc entry spiral Step 3: Output at the time of collision. Using the discretization method, update the motion of each node by time step Δ𝑡 . At each time step, we update the specific position of each node according to the changes in the polar Angle and radial position. The position update formula:         head head lag ,i i r t r t i L t t i           (17) Thus, the output of the position at this time is obtained and the position information of the dragon dance team is obtained at this time. Where L is the fixed distance of adjacent nodes and 𝜃 the Angle difference of node lag. The speed can be obtained by calculating the difference in position of each node between the two time steps. For each time step 𝑡, the speed can be approximated by:             Δ Δ Δ Δi i i i i i r t t r t v t t t t t v t t           (18) 4. Pitch Turning Space Model In order to ensure that the front handle of the faucet can be disc into the boundary of the turning space, the minimum pitch is designed. At the same time, the overall path planning is optimized globally, the movement model of the dragon is extended, the movement of the dragon body and the dragon tail is included, and a complete three-dimensional path planning model is constructed. By analyzing the relationship between the position and speed of each node at different time points, the path length and speed control are further optimized, and unnecessary route detour or sudden change is avoided. 4.1. U-turn Space Model Establishment Based on the above complex path model, a dragon dance path optimization and constraint analysis model is established: assuming that the movement of the dragon head is uniform, the polar diameter 𝑟 𝜃 and polar Angle 𝜃 change with time. The objective function can be defined as: end 2 2 2 0 min t dr d r dt dt dt            (19) Determining the minimum pitch so that the front handle of the faucet can follow the corresponding spiral disc into the boundary of the turning space can be viewed as a path optimization problem, with the goal of minimizing the path length or turning time of the faucet from the starting point to the turning space. In this condition, the following constraints exist: U-turn space constraint: the faucet must stop at the boundary of U-turn space, and the radius of the faucet cannot exceed the radius of U-turn space:     0 2 4.5m p r r r           (20) Motion smoothness constraint: centripetal acceleration and velocity constraint: With the change of path radius, the board in the dragon dance team will be subject to different acceleration, resulting in complicated motion equation. Because the movement of the dragon head is smooth, the centripetal acceleration cannot exceed a certain upper limit 𝑎 , and the centripetal acceleration of each board is required not to exceed, that is 𝑎 , the centripetal acceleration is: 2 head maxc v a a a b    (21) At the same time, in order to ensure the smooth movement of the dragon dance team, the smoothness regularization constraint is introduced. The angular velocity and angular acceleration of the dragon head are expressed as follows: head 2 2( ) vd dt b a b      (22) 306 The angular acceleration is:     22 head 3/22 2 2( ) v b a bd dt b a b        (23) For the speed 𝑣head in the formula, because the faucet speed can not exceed 1 m/s , so there is 𝑣head 1 m/s, so the requirement 𝑎angular . No collision constraint: the dragon head can not collide with the dragon body or tail in the process of turning, so it is necessary to ensure that the minimum distance between the adjacent board and meet:    2 22 1 1 mini i i i ir r r d      (24) Distance constraint between boards: The distance between adjacent boards can not be lower than a threshold value 𝑑 , which is also a nonlinear geometric constraint. Due to the above constraints, coupled with the nonlinear geometric properties of the helix 𝑟 𝜃 𝑎 𝑏𝜃: the polar coordinate equation of the helix is nonlinear. We can formalize the problem as the following non-convex optimization problem, by minimizing the travel distance or travel time of the faucet, ensuring that the faucet enters the turning space with the optimal path with the smallest pitch. The objective function is as follows:       end end turn 2 22 1 1 min 2 hade max min , , b i i i i i c b r a b R r r r d i v a a a b                         (25) According to the above objective function, the following objective function with constraints can be obtained: end 22 20 min b d b dt dt           (26) Where, 𝜆 is the smoothness regularization parameter. In non-convex optimization problems, the objective function and constraints often have multiple local optimal solutions. 4.2. U-turn Path Optimization In order to further optimize the speed control, the DeepONet neural network model is introduced to analyze the path planning and speed control [8]. Through the combination of branch and backbone network, DeepONet can effectively predict the speed and position changes of the dragon head, body and tail at different time points. Under the given initial conditions and physical constraints, the path and speed were dynamically optimized through the neural network. The introduction of neural network not only improves the computational efficiency, but also increases the adaptability of the model in complex performance situations. With the given pitch, we can determine the spiral equation of the disc entry spiral:   in initial 2in p r t r      (27) Where, 𝑟 is the initial radius. Since the disc out spiral is symmetric with the center of the disc in spiral, the two curves are similar in form, and we can get:   out out initial 2 p r t r       (28) According to Figure 2, the faucet enters the U-turn path from the right tangent point, 𝑟 corresponding to the arc radius of the entering part and 𝑟 the arc radius of the leaving part, and the red line is the U-turn path. According to the analysis of known conditions, since the points of entry and departure are uniquely determined and the centers of the two points are symmetric, we connect the two points, and the length of the two points 𝐷 is the diameter of the U-turn area. we can get the following relations 𝐷 ⋅ cos 𝛼 𝑟 𝑟 𝑟 𝑟 cos 2𝛼. According to the arc length formula, the total length of the turn-around path is 𝑆turn 𝑟 𝑟 ⋅ 𝜋 2𝛼 . Figure 3. Schematic diagram of U-turn path As shown in Figure 3, the traditional method needs to calculate the turn-around path and speed change of the dragon dance team through complex geometric analysis, differential equation solving and other methods. In this chapter, the tangential conditions of spirals, arcs, velocity curves, etc., involve a variety of geometric and physical laws, which can make the analytical solution process very tedious. DeepONe can map these complex relationships to the process of learning by the neural network, which learns directly from the input data (such as parameters such as pitch, curvature, velocity, time) to the output (position and velocity), avoiding the steps of manually solving complex equations. DeepONet is a network structure for learning operators, suitable for mapping input functions to output functions. We hope to learn the movement of each node of the dragon dance team through DeepONet, especially in the process of disc entry, turn around and disc out, and calculate the position and speed of the dragon head, body and tail. DeepONet consists of a two-part network: 307 • Branch Net (Branch Network) : For processing inputs (such as initial conditions, system parameters, etc.). • Trunk Net (Trunk network) : Used to handle solutions at predicted points in time and space. Define the inputs as the geometric parameters of the dragon dance team and time, and the outputs as the position information and velocity information of the front and back handles at these points in time. The modeling is based on the wave equation: 2 2 2 2 2 u u c t x      (29) By introducing DeepONet deep learning model, the computational efficiency and path planning accuracy of the model are improved. DeepONet is able to learn complex nonlinear relationships, and combined with path optimization algorithms, ensure smooth progress and speed expectations of the dragon dance team under different space and time conditions. 5. Conclusions Aiming at the problem of path and speed control in traditional folk performance, this paper proposes a set of solutions based on mathematical modeling, numerical optimization and deep learning model. By accurately describing the movement mode of the performing team, combined with PDE constraint and optimization algorithm, we realized the fine adjustment of the path and speed. The research results show that this scheme can significantly improve the performance's appreciation and execution accuracy, while ensuring the smoothness of the movement and the rationality of the speed. In addition, we also verified the robustness of the model through sensitivity analysis, and further improved the precision and efficiency of path planning by introducing DeepONet deep learning model. References [1] Jiayi L ,Bin Z ,Fang X .Dynamic path planning of intelligent robot in power equipment maintenance environment[J].Energy Reports,2023,9(S8):784-791. [2] Georgios K ,N. E K ,Fotios T .Discrete empirical interpolation and unfitted mesh FEMs: application in PDE-constrained optimization[J].Optimization,2023,72(6):1609-1642. [3] Zamani M ,Abbaszadehpeivasti H ,Klerk D E .The exact worst- case convergence rate of the alternating direction method of multipliers[J].Mathematical Programming,2023,208(1-2):243- 276. [4] Christian M ,Shiqi Z ,Guang L , et al.DeepONet-grid-UQ: A trustworthy deep operator framework for predicting the power grid’s post-fault trajectories[J].Neurocomputing,2023,535166- 182. [5] Hajer T ,Imene S B ,Mohamed H .On the helix equation [J]. ESAIM: Proceedings and Surveys,2012,36197-208. [6] Kaltenbacher B ,Lehner P .A first order in time wave equation modeling nonlinear acoustics[J].Journal of Mathematical Analysis and Applications,2025,543(2P2):128933-128933. [7] Oleg D ,Thi D O ,Manh N T .Improved stencil selection for meshless finite difference methods in 3D[J].Journal of Computational and Applied Mathematics,2023,425. [8] Junyan H ,Shashank K ,Jaewan P , et al.Sequential Deep Operator Networks (S-DeepONet) for predicting full-field solutions under time-dependent loads [J]. Engineering Applications of Artificial Intelligence,2024,127(PA):