A berthing trajectory tracking control method applied to a twin-hull ship
By using error calculation, planning the desired heading, and calculating the command thrust and torque, combined with the virtual ship leadership method and the improved integral line-of-sight method, a trajectory tracking control law was designed. By optimizing the maneuvering commands through grid search, the problem of trajectory tracking control for ships with dual pods was solved, achieving smooth tracking and high-precision control.
Patent Information
- Application Number
- CN202510179239.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-18
- Publication Date
- 2025-11-25
- Estimated Expiration
- 2045-02-18
AI Technical Summary
Existing technologies are difficult to effectively track and control the trajectory of ships with dual pods, and their engineering feasibility is poor, failing to meet the control requirements of actual ships.
By employing methods such as error calculation and processing, planning the desired heading, calculating the command forward thrust and bow turning moment, and combining the virtual ship leadership method and the improved integral line-of-sight method, a trajectory tracking control law is designed. The maneuvering commands are optimized through grid search, taking into account actuator capability constraints.
It achieves smooth trajectory tracking of dual-pod vessels during berthing, balancing engineering practicality with high control precision, and adapting to the maneuverability and actuator capabilities of different real-world vessels.
Smart Images

Figure CN120044951B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of ship trajectory tracking control and automatic berthing control technology, and in particular to a berthing trajectory tracking control method applied to a double-pod ship. Background Technology
[0002] With the rapid development of the shipping industry in recent years, the requirements for the application scenarios of autonomous navigation have become more sophisticated and demanding. A fundamental technology for autonomous navigation is trajectory tracking, which involves a ship traveling from its initial position to its destination along a planned route. This is further divided into trajectory tracking and path tracking. Path tracking is geometric position tracking that does not consider time, requiring only the convergence of the deviation between the ship and the planned route, without the need for closed-loop speed control. In contrast, trajectory tracking requires the ship to have a specified speed and arrive at a specific position on the route at a specific time, thus generally making it more difficult to implement than path tracking.
[0003] Typically, autonomous navigation of vessels employs path tracking, which is sufficient for navigation missions in open waters without strict time constraints. However, in scenarios such as navigation in traffic-controlled areas, taking advantage of tides in shallow waters, and picking up or dropping off pilots at ports, where time requirements are more stringent, trajectory tracking control is necessary. In particular, trajectory tracking control is suitable for missions involving vessels approaching berths from anchorages, where port speeds are extremely low, berthing paths are mostly continuous smooth curves, and high precision in position and speed control is required.
[0004] Twin-pod vessels are a relatively new type of ship, characterized by using two podded, azimuth-equipped electric propulsion units for power and lacking a stern rudder. They offer high maneuverability and agile steering, and under certain conditions, can provide excellent all-wheel-drive characteristics. However, their motion mechanisms and control methods differ significantly from conventional ships. Because their steering and forward motion are highly coupled, and the forward thrust inevitably decreases during steering, trajectory tracking control becomes more challenging.
[0005] Some existing trajectory tracking control schemes only consider control at the dynamic level, with thrust and torque as the control variables. Based on advanced control strategies such as backstepping, RBF network adaptive control, and sliding mode adaptive control, a high-precision controller was designed, and its stability and adaptability were proven. However, on the one hand, due to the large number of internal parameters and the unclear physical meaning of these parameters, it is particularly difficult to adjust the parameters according to the ship's motion during actual deployment, and it can only rely on the parameters from simulation tests. On the other hand, the control variables are not the manipulation commands to the actuators, which limits its practicality.
[0006] A few existing technologies go a step further, using maneuvering commands as control variables. These solutions primarily control small unmanned surface vessels (USVs) or conventional stern-ruddered ships. The forward navigation and steering / turning of these controlled objects are uncoupled; their dynamic mathematical expressions do not include rotational speed and rudder angle. Therefore, control laws for rotational speed / rudder angle can be designed separately, or they can be simply calculated from thrust / torque. However, as mentioned earlier, twin-pod ships are not within the scope of this type of solution.
[0007] Among existing solutions, the one proposed by Qingdao University of Science and Technology is noteworthy for its consideration of both the control variable being the actuator state combination and the selection of a scaled-down model of a double-pod ship as the controlled object. It first obtains the ship's motion model by training an RNN network, then utilizes the RNN's multi-step prediction capability (calculating outputs at multiple future moments) to implement MPC control. In MPC, this scheme first designs an objective function that balances tracking error, actuator wear (chattering), and actuator motion energy consumption (where the timing of actuator state combinations is used as the independent / decision variable), then uses PSO to find the optimal timing sequence, and finally, following MPC convention, only the first state combination in the optimal timing sequence is selected.
[0008] The output of this scheme is a ship maneuvering command of {rotation speed * 3, turning angle * 2}, which aligns with engineering practice. However, due to the generally low hardware performance of shipborne controllers and the lack of neural network toolkits or machine learning libraries commonly used in simulations, deploying and training a 3-layer RNN model is particularly difficult, resulting in poor engineering feasibility. Furthermore, MPC requires the time sequence of the control variables as input (rather than control variables at a specific moment). Therefore, the optimization problem in this scheme is more dimensional, has a more significant nonlinear objective function, and requires more computation compared to common thrust allocation optimization problems. This inevitably leads to a larger particle swarm and a greater tendency to get trapped in local optima, which also poses potential problems for controller performance. Summary of the Invention
[0009] To address the technical problem that traditional trajectory tracking algorithms for dual-pod vessels cannot achieve effective trajectory tracking control and have poor engineering feasibility, this invention proposes a berthing trajectory tracking control method for dual-pod vessels. This method enables the actual vessel to track the reference trajectory more smoothly, while considering the feasibility and safety of actual control. The accuracy of the final solution meets the control requirements of actuators in real-world vessels, comprehensively balancing engineering practicality and high control precision.
[0010] The technical solution of the present invention is as follows:
[0011] A method for tracking and controlling the berthing trajectory of a vessel with two pods includes:
[0012] Step S1, Error Calculation and Processing: Calculate the positional error between the ship and the berthing reference trajectory, and convert it to the attached coordinate system;
[0013] Step S2, planning the desired heading and calculating the heading error: Using a guidance law combining the virtual ship leadership method and the improved integral line-of-sight method, a desired heading that converges the lateral position error is planned; the heading error is calculated based on the desired heading; the error signal is smoothed using a tracking differentiator and its derivative is extracted; the virtual ship leadership method obtains the track deviation in the guidance law by constructing a virtual ship and performing projection conversion; the improved integral line-of-sight method resets the integral term in the guidance law when the actual ship is too far from the trajectory;
[0014] Step S3, calculate the command forward thrust: Based on the ship dynamics model, construct the longitudinal tracking control law, and use the algorithm of estimating the reference value + feedback correction value to calculate the command forward thrust that makes the longitudinal position error converge.
[0015] Step S4, calculate the command bow torque: The input is the heading error mentioned in step S1. Based on the PID algorithm, a heading control law is constructed, and the command bow torque that makes the heading error converge is calculated and limited to a safe range.
[0016] Step S5, Command Calculation: Establish a ship dynamics model, construct a trajectory tracking control law based on the command forward thrust described in Step 3 and the command bow turning torque described in Step 4. The trajectory tracking control law controls the ship's bow and longitudinal motion. Combined with the characteristics of actual ship maneuvering, establish a constrained optimization problem. Based on the strategy of divide and conquer followed by local optimization, perform a grid search to solve the constrained optimization problem and obtain the optimal maneuvering command, namely the twin propeller speed and turning angle.
[0017] Preferably, step S1 includes:
[0018] Step S11: Calculate the actual position of the ship. Expected location The error between the two in the Earth coordinate system;
[0019] Define position error in Earth coordinate system for:
[0020] (1)
[0021] Step S12, based on the current ship heading Position error in Earth coordinate system Position error converted to attached coordinate system The expression is:
[0022] (2)
[0023] Preferably, step S2 includes:
[0024] Step S21, Lateral error conversion: using the position error Current heading The heading of the reference trajectory The virtual ship leadership method, which involves projecting and converting the positional and angular relationships between the real and virtual ships, yields the trajectory deviation. ;
[0025] Step S22, Calculate the forward look vector: Given three parameters Based on the current track deviation The dynamically adjusted forward look vector is obtained. ;
[0026] (3)
[0027] in, ; Among the requirements ; Example: Determination threshold Length of the forward look vector ;
[0028] Step S23, update the integral term: using the Børhaug integration algorithm, given the parameters ,Depend on and Calculate the change in the integral term;
[0029] (4)
[0030] in, The integral term gain is the parameter to be tuned; when the actual ship is too far from the trajectory ( The integral term is prone to saturation, so to prevent overshoot, it is directly reset;
[0031] Step S24, Expected heading calculation: based on the reference trajectory Based on this, calculate the line-of-sight angle. To obtain the desired heading through correction. ;
[0032] Step S25, calculate the current heading error: For heading hold control, based on the desired heading... The heading error is defined as follows: Calculate the current heading error;
[0033] Step S26, smooth the error and extract its derivative: extract the derivative of the position error. Heading error Each is processed using a tracking differentiator algorithm to obtain the smoothed error. Extracted differential .
[0034] Preferably, step S3 includes:
[0035] Step S31: Calculate the desired speed based on the speed relationship between the two ships in the virtual ship leadership method. ;
[0036] in, For the virtual ship's longitudinal velocity; For the expected speed of the actual ship, Let be the cosine of the angle between the bows of the two ships;
[0037] Step S32: Based on the ship's dynamic model, calculate the desired speed. Matching estimated baseline value ;
[0038] Step S33: Calculate the feedback correction value from the smoothed longitudinal position error and its differential value. ;
[0039] Specifically, the calculation formula is as follows:
[0040] (5)
[0041] in, The vertical PID coefficients to be tuned; The error and error derivative are used for longitudinal PID calculation. ;
[0042] Step S34: Using the estimated baseline value plus the feedback correction value, the command forward thrust is obtained. ;
[0043] Step S35: Construct safe thrust thresholds for different ships and limit... To the safe zone.
[0044] Preferably, step S4 includes:
[0045] Step S41: Based on the heading error, calculate the command bow torque output by the controller. ;
[0046] Step S42: Set safe turning moment thresholds for different real-world vessels, based on vessel model limitations. To the safe zone.
[0047] Preferably, step S5 includes:
[0048] Step S51, establish the optimization problem: Using the sensor-measured water speed... , controller calculation Given weight parameters Substitute into the objective function And define the solution space range, including: the actual rotational speed of the ship. Safe feasible range, turning angle The safe and feasible range;
[0049] Step S52, Block partitioning: The search space is divided into 20 equally spaced blocks, and... The search space is also divided into 20 equally spaced blocks, and the side length of each block is recorded.
[0050] Step S53, Determine the optimal block: Determine the block that makes... The block with the smallest value is the center point of the block, and the block containing it is the optimal block.
[0051] Step S54, Local Optimization: Perform grid search only on the optimal block obtained in step S53 to obtain the final numerical solution. .
[0052] Preferably, in step S51, the constructed objective function for:
[0053] (6)
[0054] in: These are weight parameters; for The standardized result of numerical bias, a very small amount It can prevent the divisor from zero; The independent variable is The remaining variables are coefficients of the dual-pod ship dynamics model.
[0055] Preferably, step S53, the method for determining the optimal block, is as follows:
[0056] Visit each block one by one, but only the block center point is accessed. Substitute the objective function given in S51 to calculate the objective function value at the center point. .like If the value is lower than the historical best value, the current block is considered the best block, the historical best value is updated, and the calculation, comparison and update are repeated until all blocks have been visited.
[0057] Preferably, the method for performing the grid search in step S54 is as follows: for each grid point, the objective function value is calculated using the objective function given in S51. If the value is lower than the historical best, then record this grid point as the best. Simultaneously update the historical best values; continue until all grid points have been processed, so that... Lowest value This refers to the required manipulation instructions.
[0058] Compared with the prior art, the present invention has the following beneficial effects:
[0059] The berthing trajectory tracking control method for vessels with two pods provided by this invention primarily considers the highly coupled nature of the forward and bow-turning motions of such vessels, addressing the challenge of applying existing conventional trajectory tracking control methods. Secondly, considering the need for a simple and intuitive method, oriented towards practical engineering applications, it is necessary to design a feasible implementation plan that balances engineering practicality with high control precision. Through the execution of this control method, smooth and navigationally accurate maneuvering commands can be obtained during berthing, enabling relatively precise control of the vessel's actual position and heading.
[0060] This invention proposes a berthing trajectory tracking control method for vessels with two pods. Steps S3 and S4 together solve the control law design problem; specifically,
[0061] In step 1, error calculation is performed to convert the position error in the Earth coordinate system to the position error in the attached coordinate system, facilitating the design of the trajectory tracking control law. In step 2, the desired heading that allows the lateral position error to converge is planned using the improved ILOS method. In the improved ILOS method, the track deviation calculation steps are simplified by combining it with the virtual ship leadership method; the proposed function fixes the classical ILOS method. The improvement makes the integral term variable, and when the actual ship is too far from the trajectory, the integral term is reset, thereby dynamically adjusting the length of the forward look-ahead vector to adapt to the current deviation. This achieves faster convergence while reducing oscillations, allowing the actual ship to track the reference trajectory more smoothly. By using the tracking differentiator technology, effective differential information can be extracted from noisy signals, while smoothing the signal, ultimately providing higher quality input to the controller.
[0062] In steps 3 and 4, the commanded forward thrust and commanded bow turning moment are calculated through trajectory tracking control law design. Specifically, a longitudinal tracking control law is constructed using error feedback and a ship dynamics model to obtain the commanded thrust that converges the longitudinal position error, and a bow control law is constructed to obtain the commanded bow turning moment that converges the bow error. Considering actuator capability constraints, the calculation results are limited to ensure feasibility and safety in actual control.
[0063] In step 5, a divide-and-conquer grid search is employed to solve the actual maneuvering command computation problem. The search space is divided into multiple blocks. First, the block containing the optimal solution is determined, and then the grid search algorithm is implemented within that local block, significantly reducing the overall computational cost. This design not only offers high computational efficiency but also provides solutions with the accuracy required for actuator control in real-world ships.
[0064] In summary, the control method of this invention, with its basically clear physical meaning of parameters and allowing for certain specific adjustments, ensures scalability and adaptability to the maneuverability and actuator capabilities of different real-world vessels. Furthermore, this invention provides a reference for the development of unmanned vessel control systems under complex scenarios, narrow waterways, and limited time conditions. Attached Figure Description
[0065] Figure 1 This is a flowchart illustrating a berthing trajectory tracking control method applied to a vessel with two pods, as described in this embodiment.
[0066] Figure 2 This is a flowchart of step S1 in the control method.
[0067] Figure 3 Here is a flowchart of step S2 in the control method.
[0068] Figure 4 This is a guidance principle diagram corresponding to step S2 in the control method.
[0069] Figure 5 This is an example diagram showing the result of step S2 in the control method.
[0070] Figure 6 This is a flowchart of step S3 in the control method.
[0071] Figure 7 This is a block diagram of the speed control system corresponding to step S3 in the control method.
[0072] Figure 8 This is a flowchart of step S4 in the control method.
[0073] Figure 9 This is a block diagram of the forward control system involving steps S1, S2, and S4 in the control method.
[0074] Figure 10 This is a flowchart of step S5 in the control method.
[0075] Figure 11 The graph shows the results of the effectiveness test of the control method. Specific implementation methods
[0076] The present invention will be further described below with reference to the accompanying drawings and embodiments.
[0077] In a preferred embodiment of the present invention, based on the above-mentioned problems existing in the prior art, a method for tracking and controlling the berthing trajectory of a vessel with two pods is provided, such as... Figure 1 As shown, it includes:
[0078] Step S1, Error Calculation and Processing: Calculate the positional error between the ship and the berthing reference trajectory, and convert it to the attached coordinate system;
[0079] Step S2, planning the desired heading and calculating the heading error: Using a guidance law combining the virtual ship leadership method and the improved integral line-of-sight method, a desired heading that converges the lateral position error is planned; the heading error is calculated based on the desired heading; the error signal is smoothed using a tracking differentiator and its derivative is extracted; the virtual ship leadership method obtains the track deviation in the guidance law by constructing a virtual ship and performing projection conversion; the improved integral line-of-sight method resets the integral term in the guidance law when the actual ship is too far from the trajectory;
[0080] Step S3, calculate the command forward thrust: Based on the ship dynamics model, construct the longitudinal tracking control law, and use the algorithm of estimating the reference value + feedback correction value to calculate the command forward thrust that makes the longitudinal position error converge.
[0081] Step S4, calculate the command bow torque: The input is the heading error mentioned in step S1. Based on the PID algorithm, a heading control law is constructed, and the command bow torque that makes the heading error converge is calculated and limited to a safe range.
[0082] Step S5, Command Calculation: Establish a ship dynamics model, construct a trajectory tracking control law based on the command forward thrust described in Step 3 and the command bow turning torque described in Step 4. The trajectory tracking control law controls the ship's bow and longitudinal motion. Combined with the characteristics of actual ship maneuvering, establish a constrained optimization problem. Based on the strategy of divide and conquer followed by local optimization, perform a grid search to solve the constrained optimization problem and obtain the optimal maneuvering command, namely the twin propeller speed and turning angle.
[0083] In a preferred embodiment of the present invention, such as Figure 2 As shown, step S1 includes:
[0084] Step S11: Calculate the actual position of the ship. Expected location The error between the two in the Earth coordinate system;
[0085] Specifically, the position error in the Earth coordinate system is defined as:
[0086] (1)
[0087] In this embodiment, the desired location Derived from existing, planned reference trajectories And it is time-varying;
[0088] Step S12, based on the current ship heading The position error in the Earth coordinate system is converted into the position error in the attached coordinate system;
[0089] Specifically, the expression is:
[0090] (2)
[0091] In this embodiment, converting the position error to the attached coordinate system is a requirement for the trajectory tracking control law design. This approach facilitates the design of control and guidance algorithms using position error feedback.
[0092] In a preferred embodiment of the present invention, such as Figure 3 As shown, step S2 includes:
[0093] Step S21, Lateral error conversion: using the position error Current heading The heading of the reference trajectory The virtual ship leadership method, which involves projecting and converting the positional and angular relationships between the real and virtual ships, yields the trajectory deviation. ;
[0094] Specifically, the following convenient conversion (projection) method is used.
[0095] (7)
[0096] in, It is the distance perpendicular to the trajectory segment and can be used as an approximation of the track deviation; Based on existing reference trajectories;
[0097] In this embodiment, in the virtual ship leadership method, the aforementioned It is merely the lateral position error between the ship and the virtual ship in the attached coordinate system, and not the "cross-track error" required by the ILOS method, so it needs to be converted;
[0098] In this embodiment, S21 obtains the track deviation, and its calculation steps are significantly simpler than the classic ILOS method because it skips the calculation of some intermediate variables.
[0099] In this embodiment, this embodiment uses Figure 4 This is a schematic diagram illustrating the principle, which describes... Geometric relationships; Figure 4 The principles of other steps in S2 (such as S23) are also illustrated, which helps to understand the geometric relationships of key variables (the physical meanings of these variables are length or angle).
[0100] Step S22, Calculate the forward look vector: Given three parameters Based on the current track deviation The dynamically adjusted forward look vector is obtained. ;;
[0101] Specifically, the forward vector length algorithm is designed as follows:
[0102] (3)
[0103] in, ; Among the requirements ; Example: Determination threshold ;
[0104] In this embodiment, the length of the forward look-ahead vector The setting of this is particularly important. In the classical method, the forward look vector is a constant value, represented as a multiple of the ship's length L. When the deviation is large, the ship turns smoothly, but the deviation convergence speed is slow. When the value is small, the actual ship's steering is aggressive and the deviation converges quickly, but it is prone to oscillations.
[0105] In this embodiment, the improved method dynamically adjusts based on the current deviation. This provides adaptive capabilities, which helps to converge faster while reducing oscillations, allowing the actual ship to track the reference trajectory more smoothly. When the actual ship moves away from the reference trajectory, As the size increases, in order to make it converge as quickly as possible... The size should be reduced to allow the ship to turn more quickly; conversely, when... When smaller, The heading should be increased to allow for smooth, fine-tuning of the ship's heading.
[0106] In this embodiment, analysis of the proposed function shows that if This indicates that the deviation is too large. The minimum value should be taken. Conversely, if Then, based on the cosine decay function and the relative magnitude of the deviation, the variable... .when At that time, there should be Therefore, the function meets the design intent;
[0107] In this embodiment, since the reference trajectory starts from the ship's initial coordinates, the track deviation throughout the entire journey should be relatively small under normal control conditions. Therefore, it can be concluded that... Allowing a value less than L. This differs significantly from the traditional LOS / ILOS method used for path tracking: in classic methods, the minimum look-forward vector is typically set to L;
[0108] Step S23, update the integral term. Using the integration algorithm proposed by Børhaug, given the parameters... ,Depend on and Calculate the change in the integral term; selectively update the integral term while preventing it from becoming too large (which would lead to overshoot);
[0109] In this embodiment, the following method for calculating the integral term is provided:
[0110] (4)
[0111] in, The integral term gain is the parameter to be tuned; when the actual ship is too far from the trajectory ( The integral term is prone to saturation, so to prevent overshoot, it is directly reset;
[0112] In this embodiment, in practical applications, accumulation is used instead of integration, so the algorithm needs to be set at the beginning. ;
[0113] Step S24, Calculate the desired heading. Using the reference trajectory... Based on this, calculate the line-of-sight angle. To obtain the desired heading through correction. ;
[0114] Specifically, calculation The algorithm (guidance law) is as follows:
[0115] (8)
[0116] In this embodiment, It is an integral term Adjusted track deviation; desired heading Therefore, there is Based on, by and Jointly determined line of sight The correction is made to bring the deviation closer together and counteract any potential persistent lateral disturbances (the integral term is used to compensate for the steady-state deviation).
[0117] As a supplementary explanation to step S2, although the ILOS method has been proven to be stable for small disturbances and to converge lateral position errors, in practical applications, the convergence effect of the deviation still highly depends on parameter tuning and the ship's navigation environment. To ensure the applicability and robustness of the algorithm, the parameters need to be tuned in experiments.
[0118] Step S25, for heading control, the heading error is defined as... Calculate the current heading error;
[0119] In this embodiment, the desired heading As planned in S24, this error definition ensures that the proportional term coefficient in the subsequent PID control law is positive.
[0120] Step S26, Smooth the error and extract its derivative: The error signal... Each is processed using a tracking differentiator algorithm to obtain the smoothed error. Extracted differential ;
[0121] In this embodiment, the subsequent control law needs to utilize... Differential (But not required) The differential, (Already used in step S21). Signal In practice, signals often contain noise, which may include measurement noise or random disturbances caused by gusts of wind and high-frequency waves. Finding the derivative of a discrete signal is generally done using a difference approximation; however, this is unreasonable for noisy signals, as it amplifies the high-frequency components of the noise in the signal, leading to inaccurate or even distorted results.
[0122] In this embodiment, the tracking differentiator (TD) can be used to extract the derivative from a noisy signal. It simultaneously achieves high-frequency noise suppression and signal change response, making it suitable for control systems with high real-time requirements. The tracking differentiator was first proposed by Han Jingqing in the 1990s and is one of the three core components of Active Disturbance Rejection Control (ADRC). A typical linear second-order TD is:
[0123] (9)
[0124] in, It is the original noisy error signal, specifically... or ; These are adjustable TD parameters, specifically: or ; It is an error signal that has been smoothed by TD; It is the differential extracted by TD ( ).
[0125] In this embodiment, in order to utilize the aforementioned second-order TD, its discrete form is given as follows:
[0126] (10)
[0127] in, It is the control cycle; in this embodiment, it is taken as... ; This represents past values; initially, all past values are set to zero. This represents the current value. In this embodiment, this formula is used for TD processing.
[0128] As a supplementary explanation to step S26, this embodiment uses Figure 5 For example, let's show the result of executing S26. In this example, let... , , All are sinusoidal signals. White noise with an amplitude of 10m and a variance of 1m. The signal has an amplitude of 10deg and contains white noise with a variance of 1deg. The signal sampling rate is 1Hz, and the total simulation time is 80s (4 cycles, 20s per cycle). Figure 5 The results demonstrate the effectiveness of linear second-order TD in S26. Wherein, diff It is a noisy signal The difference, and its relationship with The comparison shows that the derivative extracted using TD is more accurate.
[0129] In a preferred embodiment of the present invention, such as Figure 6 As shown, step S3 includes:
[0130] Step S31: Calculate the desired speed based on the speed relationship between the two ships in the virtual ship leadership method. ;
[0131] Specifically, according to the virtual ship leadership method, the following speed relationships exist:
[0132] (11)
[0133] in, The longitudinal velocity of the virtual ship (obtained by differentiating with respect to the reference trajectory, and is a known quantity); The expected speed of the actual ship, and the bow direction of the two ships. Related; the unit of speed is m / s. From the above formula, we can obtain... ;
[0134] Step S32: Based on the ship's dynamic model, calculate the desired speed. Matching estimated baseline value ;
[0135] Specifically, the calculation formula is: ; It is a gain coefficient to be tuned, which is equal to or approximately equal to 1. Its design purpose is to allow fine-tuning of the estimated reference value when the current interference is severe (when sailing downstream). When sailing against the current From the dynamic model, we can obtain Longitudinal hydrodynamic resistance of the hull at speed ;
[0136] In this embodiment, The physical meaning is longitudinal fluid resistance. The opposite of the number, this design is equivalent to based on Implement feedforward control;
[0137] In this embodiment, The model is given by the fluid viscosity force model, neglecting the drift resistance (angular velocity during low-speed docking). The absolute value of (is limited to ensure it is small enough); in this embodiment, Different real-world ships have similar forms but different specific coefficients. expression;
[0138] Step S33: Calculate the feedback correction value from the smoothed longitudinal position error and its differential value. ;
[0139] Specifically, the calculation formula is as follows:
[0140] (5)
[0141] in, The vertical PID coefficients to be tuned;
[0142] In this embodiment, The design aims to eventually converge the longitudinal position error.
[0143] In this embodiment, Theoretically, it is It is obtained through PID control law, and A difference approximation should be used; however, error processing has already been done by S14, so the actual error used for longitudinal PID calculation is... The error differential is ;
[0144] Step S34: Using the estimated baseline value plus the feedback correction value, the command forward thrust is obtained. ;
[0145] Specifically, the forward thrust command output by the speed controller is:
[0146] (12)
[0147] In this embodiment, since there is an estimated reference value, similar to feedforward control, a relatively fast control response and minimal overshoot can be achieved. The purpose of using PID control with high differential signal quality is to converge the longitudinal position error and provide some compensation for external disturbances.
[0148] Step S35, Restriction To the safe zone;
[0149] Specifically, different real-world ships have different safe thrust thresholds; in this embodiment, based on the thrust calculation model of a certain ship, when both pods are working synchronously and outputting 80% power, the longitudinal thrust generated is approximately ,therefore Should be limited to interval;
[0150] As a supplementary explanation to step S3, this embodiment provides a corresponding speed control system block diagram, such as... Figure 7 As shown in the figure (this figure also involves the error calculation and processing of S1 and S26, which is part of the input of S3).
[0151] In a preferred embodiment of the present invention, such as Figure 8 As shown, step S4 includes:
[0152] Step S41: Based on the heading error, calculate the command bow torque output by the controller. ;
[0153] Specifically, the calculation expression is:
[0154] (13)
[0155] in, The forward PID coefficients to be tuned;
[0156] In this embodiment, Theoretically, due to heading error Its derivative is obtained through the PID control law; previously, the derivative of the error was extracted and smoothed by S14, so the actual error used for the forward PID calculation is Differential is ;
[0157] Step S42, restriction To the safe zone;
[0158] Specifically, different real-world vessels have different safe turning moment thresholds; in this embodiment, based on the moment calculation model of a certain vessel, when both pods are working synchronously, considering the restricted area angle, and outputting 80% power, the generated moment is approximately Therefore, the calculation Should be limited to The interval, where positive and negative represent clockwise and counterclockwise directions, respectively;
[0159] As a supplementary explanation to step S4, this embodiment provides a corresponding bow control system block diagram, as follows: Figure 9 As shown; but Figure 9 Besides S4, the calculation also involves S1 position error, S2 planned expected heading and heading error calculation, and error processing. The variables and processing procedures are described below. Figure 9 They are linked together in a form that together achieves the important goal of reducing lateral errors.
[0160] In summary, two position errors were calculated in S1. In S2, based on the design concept of the indirect track-keeping controller, a system is planned that enables... Expected convergence direction This allows for the "convergence" "The mission is transformed into a heading maintenance control mission; based on..." The heading error can then be calculated. To avoid noise-inducing errors By directly calculating the difference, and then using TD for smoothing and simultaneously extracting the differential signal, we obtain... ;
[0161] In S3 and S4, based on the ship's motion model, a trajectory tracking error feedback controller is designed to ensure that the tracking error is zero or converges to a very small neighborhood of zero; specifically, the speed controller outputs a command for forward thrust. The bow outputs a command to the controller to control the bow torque. And limit the amplitude according to the actual situation.
[0162] In a preferred embodiment of the present invention, such as Figure 10 As shown, step S5 includes:
[0163] Step S51, establish the optimization problem. The water speed measured by the sensor... , controller calculation Given weight parameters Substitute these known quantities into the objective function of this design scheme. Based on the actual situation, determine the solution space range, that is, the actual rotational speed of the ship. Safe feasible range, turning angle The safe and feasible range;
[0164] Specifically, the objective function is constructed according to the following formula. :
[0165] (6)
[0166] in: These are weight parameters; for The standardized result of numerical bias, a very small amount It can prevent the divisor from zero; The independent variable is The remaining variables are coefficients of the dual-pod ship dynamics model, which vary for different real-world ships but are constants for a specific ship, and are known in this embodiment. In S51, because... They are all assigned specific values, therefore The value is determined by and only by The combination determines;
[0167] Specifically, in this embodiment, based on the results of the speed test, speeds of 4 knots and below are considered acceptable. When both pods are working synchronously, Based on this, the scope of the understood space is determined;
[0168] In this embodiment, the prototype of the above optimization problem is the following system of equations based on the dynamics model of a dual-pod ship, containing two nonlinear equations:
[0169] (14)
[0170] Among them, command thrust Command steering torque It is a known quantity. The coefficients of each model are also known, and the command speed is... Command slewing angle It refers to the unknown quantity to be determined, and the actual maneuvering instructions for the ship.
[0171] In this embodiment, if the above system of equations has a solution, then the solution is unique; if there is no solution, engineering requirements dictate that the second equation should be made true first (prioritizing the realization of steering control); therefore, weights are introduced. Design;
[0172] In this embodiment, to avoid the difficulty of finding analytical solutions to nonlinear equations, a numerical solution method is considered to obtain an approximate solution (rather than an analytical solution) of the equations that meets the accuracy requirements. Following this approach, the problem of solving the equations is transformed into a constrained optimization problem as described in S51, and optimization is performed through subsequent steps S52 to S54.
[0173] Step S52, block division. The search space is divided into 20 equally spaced blocks, and... The search space is also divided into 20 equally spaced blocks; therefore, the entire solution space is divided into 400 blocks; the side length of each block is recorded.
[0174] In this embodiment, by recording and saving the side length (division step size) of the block, the boundary and center point of each block can be quickly located and accessed.
[0175] In this embodiment, in order to speed up the optimization process, instead of performing a grid search on the entire solution space, a divide-and-conquer approach is adopted, firstly dividing the entire solution space into several blocks.
[0176] Step S53, determine the optimal block. Determine if... The block center with the smallest value is denoted as the optimal block.
[0177] Specifically, each block is accessed sequentially, but only the block center point is accessed. Substitute the objective function given in S51 to calculate the objective function value at the center point. .like If the value is lower than the historical best value, the current block is considered the best block, and the historical best value is updated. This process of calculation, comparison, and updating is repeated until all blocks have been visited.
[0178] In this embodiment, S53 determines the optimal block by traversing the area, thereby significantly reducing the area for performing grid search, thus improving the optimization efficiency.
[0179] Step S54, Local Optimization. Perform a grid search only within the obtained optimal block to obtain the final numerical solution. ;
[0180] Specifically, in this embodiment, The feasible resolution is 1deg. The feasible resolution is 1 rpm (set according to the actual engineering situation); the above feasible resolution is used as the granularity of the grid to ensure that all feasible solutions within the optimal block can be accessed; for each grid point, the objective function value is calculated using the objective function given in S51. If the value is lower than the historical best, then record this grid point as the best. Simultaneously update the historical best values; continue until all grid points have been processed, so that... Lowest value This refers to the required manipulation instructions;
[0181] In this embodiment, "local optimization" means performing a grid search only within a given optimal block (rather than across the entire solution space); The accuracy is sufficient to meet the control requirements of actuators in real ships, because the accuracy of the solution does not need to be higher than the feasible resolution;
[0182] As a supplementary explanation to step S5, if the grid search method is used directly, refining the grid granularity to the same level as the feasible resolution, it can certainly ensure that the global optimum is not missed. However, when searching the entire solution space of this embodiment, a total of 180*100=18000 state combinations need to be tried, which is obviously too computationally expensive. This solution reduces the number of state combinations to be tried to 400+18000 / 400=445 by using a divide-and-conquer approach, thereby significantly reducing the computational cost. S5, based on the ship dynamics model, obtains the maneuvering commands from the command force / torque given by the controller. Its importance lies in the fact that the command speed / turning angle is the actual maneuvering command applied to the double-pod ship.
[0183] Solution effectiveness verification:
[0184] As a supplementary explanation to this embodiment, a simulation experiment was conducted to test the berthing trajectory tracking control method proposed in this scheme for ships with dual pods.
[0185] The simulation conditions are set as follows: (1) Initial position and heading: The initial position of the ship is The initial heading is Under these initial conditions, according to the relevant berthing agreement, the ship's heading needs to decrease first and then increase, so the berthing reference trajectory is relatively complex and can fully test the effect of the heading controller; (2) Initial speed, speed, and turning angle: the ship's initial speed initial rotational speed rpm, initial rotation angle (3) Ideal speed:
[0186] Set the ideal speed as m / s, and Special distinctions were made; (4) Disturbance settings: Disturbances were added to the position and heading, and the standard deviation of the white noise for the position disturbance was calculated. and The standard deviation of the white noise for bow disturbance is 0.25m. (5) Time and period: Total simulation time Set to 600s; control cycle Model update cycle .
[0187] The control parameters are set according to the following table: Table 2 shows the tuning results of the trajectory tracking parameters;
[0188] Table 2
[0189]
[0190] Results visualization: Test results are as follows Figure 11 As shown. Figure 11 (a) Shows the ship's motion process (track chart) and berthing reference trajectory; prints the time-history curves of key variables, including Figure 11 (b) shows the speed ( and ), Figure 11 (c) shows the heading ( Errors in trajectory tracking control, including Figure 11 (d) The heading error shown, Figure 11 (e) Display positional error; check if the actuator is functioning correctly, including... Figure 11 (f) shows the pod rotation angle (distinguishing between commanded and actual values). Figure 11 (g) shows the dual propeller speeds (distinguishing between commanded and actual values). A comprehensive analysis of the test results confirms that the proposed control method is effective.
[0191] It should be noted that the specific embodiments described above enable those skilled in the art to more fully understand the present invention, but do not limit the present invention in any way. Therefore, although the present invention has been described in detail with reference to the accompanying drawings and embodiments, those skilled in the art should understand that modifications or equivalent substitutions can still be made to the present invention. In short, all technical solutions and improvements that do not depart from the spirit and scope of the present invention should be covered within the protection scope of the present invention patent.
Claims
1. A method for tracking and controlling the berthing trajectory of a vessel with two pods, characterized in that, include: Step S1, Error Calculation and Processing: Calculate the positional error between the ship and the berthing reference trajectory, and convert it to the attached coordinate system; Step S2, plan the desired heading and calculate the heading error: using a guidance law combining the virtual ship leadership method and the improved integral line-of-sight method, plan the desired heading that makes the lateral position error converge; calculate the heading error based on the desired heading; smooth the error signal using a tracking differentiator and extract its derivative; The virtual ship leadership method obtains the trajectory deviation in the guidance law by constructing a virtual ship and performing projection conversion; the improved integral line-of-sight method resets the integral term in the guidance law when the actual ship is too far from the trajectory. Step S3, calculate the command forward thrust: Based on the ship dynamics model, construct the longitudinal tracking control law, and use the algorithm of estimating the reference value + feedback correction value to calculate the command forward thrust that makes the longitudinal position error converge. Step S4, calculate the command bow torque: The input is the heading error mentioned in step S1. Based on the PID algorithm, a heading control law is constructed, and the command bow torque that makes the heading error converge is calculated and limited to a safe range. Step S5, Command Calculation: Establish a ship dynamics model, construct a trajectory tracking control law based on the command forward thrust described in Step S3 and the command bow turning torque described in Step S4. The trajectory tracking control law controls the ship's bow and longitudinal motion. Combined with the characteristics of actual ship maneuvering, establish a constrained optimization problem. Based on the strategy of divide and conquer followed by local optimization, perform a grid search to solve the constrained optimization problem and obtain the optimal maneuvering command, propeller speed and turning angle. Step S51, establish the optimization problem: Using the sensor-measured water speed... The controller calculates the forward thrust. Command steering torque Given weight parameters Substitute into the objective function ; And define the solution space range, including: the actual rotational speed of the ship. Safe feasible range, turning angle The safe and feasible range; Constructed target function for: (6) in: These are weight parameters; for The standardized result of numerical bias, a very small amount It can prevent the divisor from zero; The independent variable is ; This is the thrust reduction factor. For the density of water, The diameter of the propeller. This is the mooring thrust coefficient. The longitudinal hydrodynamic coefficient of the pod. The hydrodynamic coefficient for pod turning. This is the longitudinal coordinate of the pod's rotation axis in the ship's coordinate system; Step S52, Block partitioning: The search space is divided into 20 equally spaced blocks, and... The search space is also divided into 20 equally spaced blocks, and the side length of each block is recorded. Step S53, Determine the optimal block: Determine the block that makes... The block with the smallest value is the center point of the block, and the block containing it is the optimal block. Step S54, Local Optimization: Perform grid search only on the optimal block obtained in step S53 to obtain the final numerical solution. .
2. The berthing trajectory tracking and control method for a vessel with two pods as described in claim 1, characterized in that, Step S1 includes: Step S11: Calculate the actual position of the ship. Expected location The error between the two in the Earth coordinate system; Define position error in Earth coordinate system for: (1) Step S12, based on the current ship heading Position error in Earth coordinate system The position error converted to the attached coordinate system is expressed as: (2) in, This refers to the position error in the attached coordinate system. For longitudinal error, This represents the lateral error.
3. A method for tracking and controlling the berthing trajectory of a vessel with two pods, as described in claim 2, is characterized in that... Step S2 includes: Step S21, Lateral error conversion: using the position error Current heading The heading of the reference trajectory Based on the virtual ship leadership method, the trajectory deviation is obtained by projecting and converting the positional and angular relationship between the real ship and the virtual ship. ; Step S22, Calculate the forward look vector: Given three parameters Based on the current track deviation The dynamically adjusted forward look vector is obtained. ; (3) in, ; Captain L, among other requirements Take the deviation threshold Length of the forward look vector And it is variable; Step S23, update the integral term: using the Børhaug integration algorithm, given the parameters ,Depend on and Calculate the change in the integral term; (4) in, The integral term gain is the parameter to be tuned; when the actual ship is too far from the trajectory, The points were reset; Step S24, Expected heading calculation: based on the reference trajectory Based on this, calculate the line-of-sight angle. To obtain the desired heading through correction. ; Step S25, calculate the current heading error: For heading hold control, based on the desired heading... The heading error is defined as follows: Calculate the current heading error. This is the current heading of the vessel; Step S26, smooth the error and extract its derivative: the longitudinal error Heading error Each is processed using a tracking differentiator algorithm to obtain the smoothed error. Extracted differential .
4. A method for tracking and controlling the berthing trajectory of a vessel with two pods as described in claim 1, characterized in that, Step S3 includes: Step S31: Calculate the desired speed based on the speed relationship between the two ships in the virtual ship leadership method. ; in, For the virtual ship's longitudinal velocity; For the expected speed of the actual ship, Let be the cosine of the angle between the bows of the two ships; Step S32: Based on the ship's dynamic model, calculate the desired speed. Matching estimated baseline value ; Step S33: Calculate the feedback correction value from the smoothed longitudinal position error and its differential value. The formula for its calculation is: (5) in, The vertical PID coefficients to be tuned; It is the error used for longitudinal PID calculation; the error derivative is ; Step S34: Using the estimated baseline value plus the feedback correction value, the command forward thrust is obtained. ; Step S35: Construct safe thrust thresholds for different ships and limit... To the safe zone.
5. A method for tracking and controlling the berthing trajectory of a vessel with two pods, as described in claim 1, characterized in that, Step S4 includes: Step S41: Based on the heading error, calculate the command bow torque output by the controller. ; Step S42: Set safe turning moment thresholds for different real-world vessels, based on vessel model limitations. To the safe zone.
6. A method for tracking and controlling the berthing trajectory of a vessel with two pods, as described in claim 1, characterized in that, Step S53, the method for determining the optimal block is as follows: Visit each block one by one, but only the center point of the block is accessed. Substitute the objective function described in S51 to calculate the objective function value at the center point. ,when If the value is lower than the historical best value, the current block is considered the best block, the historical best value is updated, and the calculation, comparison and update are repeated until all blocks have been visited.
7. A method for tracking and controlling the berthing trajectory of a vessel with two pods as described in claim 1, characterized in that, Step S54 involves performing a grid search by calculating the objective function value for each grid point using the objective function described in S51. When the value is lower than the historical best, record this grid point as the best. Simultaneously update the historical best values; continue until all grid points have been processed, so that... Lowest value This refers to the required manipulation instructions.
Citation Information
Patent Citations
Ship course adaptive control method based on improved particle swarm algorithm
CN117930844A
Automatic guiding method of vessel, automatic guiding program of vessel, automatic guiding system of vessel, and vessel
US20230192262A1