Electric unmanned ship trajectory tracking method, device, equipment, medium and product

By combining a two-layer controller structure and a fixed-time gradient template, the trajectory tracking problem of electric unmanned surface vessels (USVs) under resource-constrained conditions is solved, achieving fixed-time convergence and energy consumption suppression, thereby improving the endurance and mission completion reliability of USVs.

CN121785329BActive Publication Date: 2026-06-02TSINGHUA SHENZHEN INTERNATIONAL GRADUATE SCHOOL

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
TSINGHUA SHENZHEN INTERNATIONAL GRADUATE SCHOOL
Filing Date
2026-03-05
Publication Date
2026-06-02

AI Technical Summary

Technical Problem

Existing electric unmanned surface vessel trajectory tracking and control methods are difficult to achieve fixed-time convergence and explicit energy consumption constraints under resource-constrained conditions. In particular, under external disturbances and parameter uncertainties, this leads to a decrease in endurance and an increase in the risk of mission interruption.

Method used

A two-layer controller structure is adopted, in which the kinematic controller and the dynamic controller share a fixed-time gradient template. The cost function of the kinematic controller includes an energy consumption control index. Supervised data is generated by constructing an expert controller for pre-training. Low-rank basis is extracted using singular value decomposition to achieve online updates and energy consumption suppression.

Benefits of technology

It achieves fixed-time convergence and energy consumption suppression of electric unmanned surface vessels under resource-constrained conditions, reduces control fluctuations and energy consumption, and improves the stability and efficiency of trajectory tracking.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121785329B_ABST
    Figure CN121785329B_ABST
Patent Text Reader

Abstract

The application provides an electric unmanned ship trajectory tracking method, device, equipment, medium and product, and relates to the field of electric unmanned ships. Based on the current position of the electric unmanned ship, the coordinate error and the heading error of the electric unmanned ship are determined. The coordinate error and the heading error are input into a kinematics controller to obtain a virtual speed instruction. The virtual speed instruction is input into a dynamics controller to obtain a virtual thrust instruction. Based on the virtual thrust instruction, a target control instruction is determined and sent to the electric unmanned ship. The above steps are cyclically executed under the condition that the tracking is not completed until the tracking is completed. The kinematics controller and the dynamics controller share a fixed time gradient template, and the cost function of the kinematics controller contains an energy consumption control index. The application adopts a two-layer controller structure and shares a fixed time gradient template, and sets an energy consumption control index in the cost function corresponding to the kinematics controller, so that fixed time convergence and energy consumption suppression can be realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of electric unmanned surface vessel (USV) technology, and in particular to a method, apparatus, equipment, medium, and product for tracking the trajectory of an electric USV. Background Technology

[0002] The trajectory tracking control of electric unmanned surface vessels (USVs) aims to enable underactuated USVs to achieve convergence of position and heading errors along a parameterized reference trajectory at a given time under external disturbances such as wind, waves, and currents, as well as under parameter uncertainties, while taking into account propulsion energy consumption, thrust smoothness, and execution constraints.

[0003] Electric unmanned surface vessels (USVs) are limited by battery capacity and onboard computing power. External disturbances and parameter uncertainties can amplify control input fluctuations and increase energy consumption, leading to reduced range and increased risk of mission interruption. Meanwhile, trajectory tracking tasks typically have defined time windows and operational mode switching requirements. Engineeringly, this necessitates both rapid error convergence and predictable convergence time that is as independent as possible of the initial error. Therefore, energy consumption and fixed-time convergence are two key performance indicators for electric USV mission execution.

[0004] Existing trajectory tracking and control methods for electric unmanned surface vessels fall into two categories: traditional control methods and data-driven methods.

[0005] Traditional control methods design trajectory tracking control laws using nonlinear dynamic models, including adaptive and robust control, backstepping control, dynamic surface control and sliding mode control, and fixed-time and preset-time control, to improve transient performance and enhance resistance to disturbances and uncertainties. These methods often require information on the dynamic structure and disturbance boundaries, making gain tuning complex in engineering implementation. Performance is easily degraded by changes in sea state and parameter drift, and energy consumption is often treated as a secondary factor, indirectly handled through control effort penalties, making it difficult to form a unified design framework centered on explicit minimization of energy consumption. While traditional control methods can utilize optimization and predictive control to explicitly encode the trajectory objective, input constraints, and energy-related costs into an optimal control problem, and can achieve energy consumption optimization through economic indicators, they typically require online solving of the optimization problem. This places high demands on the accuracy of the predictive model and real-time computing resources, making long-term stable operation on embedded platforms difficult, and the initial value-independent upper bound for fixed-time convergence is usually difficult to provide directly. If optimization and predictive control simultaneously consider energy consumption and fixed-time convergence, the problems of large initial errors and policy instability in the online phase are more likely to appear, leading to increased energy consumption and control fluctuations.

[0006] Data-driven approaches utilize reinforcement learning and approximate dynamic programming to directly incorporate thrust into the cost function through empirical data approximation functions and policies, thus possessing energy consumption optimization potential for tasks such as unmanned surface vessel (USV) trajectory tracking and path following. However, data-driven approaches have high resource requirements and still face practical constraints such as online adaptive overhead and deployment security on resource-constrained platforms.

[0007] Therefore, it is necessary to provide a scheme to achieve fixed-time convergence and explicit energy consumption constraints under resource-constrained conditions. Summary of the Invention

[0008] This invention provides a method, apparatus, equipment, medium, and product for tracking the trajectory of an electric unmanned surface vessel, which can achieve fixed-time convergence and explicit energy consumption constraints under resource-constrained conditions.

[0009] This invention provides a method for tracking the trajectory of an electric unmanned surface vessel, comprising:

[0010] Based on the current position of the electric unmanned surface vessel (USV), determine the coordinate error and heading error of the USV.

[0011] The coordinate error and the heading error are input to the kinematics controller of the electric unmanned surface vessel to obtain the virtual speed command output by the kinematics controller;

[0012] The virtual speed command is input to the dynamics controller of the electric unmanned surface vessel to obtain the virtual thrust command output by the dynamics controller;

[0013] Based on the virtual thrust command, a target control command is determined and sent to the electric unmanned surface vessel.

[0014] If it is determined that tracking has not been completed, return to the current position based on the electric unmanned surface vessel, determine the coordinate error and heading error of the electric unmanned surface vessel, and continue until it is determined that tracking has been completed;

[0015] The kinematic controller and the dynamic controller share a fixed-time gradient template, and the cost function corresponding to the kinematic controller includes an energy consumption control index.

[0016] As one embodiment, determining the target control command based on the virtual thrust command includes:

[0017] Based on the fixed time gradient template, the low-rank parameters of the kinematic controller and the dynamic controller are updated online to obtain online thrust commands.

[0018] Based on the online thrust command and the virtual thrust command, the target control command is determined.

[0019] As one embodiment, determining the target control command based on the online thrust command and the virtual thrust command includes:

[0020] Based on the gating fusion mechanism and the abnormal rollback mechanism, the online thrust command and the virtual thrust command are fused to obtain the target control command;

[0021] The gating signal in the gating fusion mechanism is determined based on a time confidence rule or a cost comparison rule. The abnormal rollback mechanism is used to characterize the virtual thrust command as the target control command when the residual in the gating fusion mechanism increases to a threshold.

[0022] As an example, the abnormal rollback mechanism is also used to roll back the target control command to the virtual thrust command if it is determined that the electric unmanned surface vessel has an abnormal command execution after the target control command is sent to the electric unmanned surface vessel.

[0023] As one embodiment, it also includes:

[0024] Construct an expert controller, and generate supervision data based on the expert controller;

[0025] The kinematic controller and the dynamic controller are pre-trained based on the supervised data to obtain gradient priors;

[0026] The gradient prior is subjected to singular value decomposition to obtain a low-rank basis, which is used as a safety prior when the kinematic controller and the dynamic controller are updated online.

[0027] As one embodiment, it also includes:

[0028] Construct dynamic, kinematic, and error models for electric unmanned surface vessels;

[0029] Based on the dynamic model, the kinematic model, and the error model, a first control affine model and a second control affine model are determined. The first control affine model is used to characterize the correlation between the virtual command corresponding to the kinematic model and the error of the electric unmanned surface vessel. The second control affine model is used to characterize the tracking error of the affine control form of the virtual command of the kinematic model.

[0030] Based on the first control affine model and the kinematic cost function, the kinematic HJB equations are determined, and based on the second control affine model and the dynamic cost function, the dynamic HJB equations are determined.

[0031] Based on a fixed-time gradient template, determine the gradient of a value function with low-rank parameters;

[0032] Based on the value function gradient and the kinematic HJB equation, a kinematic controller is determined; based on the value function gradient and the dynamic HJB equation, a dynamic controller is determined.

[0033] The present invention also provides an electric unmanned surface vessel trajectory tracking device, comprising:

[0034] An error determination module is used to determine the coordinate error and heading error of the electric unmanned surface vessel based on its current position.

[0035] The first instruction determination module is used to input the coordinate error and the heading error into the kinematic controller of the electric unmanned surface vessel to obtain a virtual velocity instruction output by the kinematic controller; and to input the virtual velocity instruction into the dynamic controller of the electric unmanned surface vessel to obtain a virtual thrust instruction output by the dynamic controller.

[0036] The second instruction determination module is used to determine the target control instruction based on the virtual thrust instruction and send the target control instruction to the electric unmanned surface vessel.

[0037] The electric unmanned surface vessel (USV) tracking module is used to return to the steps of determining the coordinate error and heading error of the USV based on its current position if tracking is not completed, until tracking is determined to be completed.

[0038] The kinematic controller and the dynamic controller share a fixed-time gradient template, and the cost function corresponding to the kinematic controller includes an energy consumption control index.

[0039] The present invention also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the electric unmanned surface vessel trajectory tracking method as described above.

[0040] The present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the electric unmanned surface vessel trajectory tracking method as described above.

[0041] The present invention also provides a computer program product, including a computer program that, when executed by a processor, implements the electric unmanned surface vessel trajectory tracking method as described above.

[0042] The present invention provides an electric unmanned surface vessel (USV) trajectory tracking method, apparatus, device, medium, and product. Based on the current position of the USV, the method determines the coordinate error and heading error of the USV; inputs the coordinate error and heading error to the kinematic controller of the USV to obtain a virtual velocity command output by the kinematic controller; inputs the virtual velocity command to the dynamic controller of the USV to obtain a virtual thrust command output by the dynamic controller; based on the virtual thrust command, a target control command is determined and sent to the USV; if tracking is not completed, the method returns to the steps of determining the coordinate error and heading error based on the current position of the USV, until tracking is determined to be completed. The kinematic controller and the dynamic controller share a fixed-time gradient template, and the cost function corresponding to the kinematic controller includes an energy consumption control index. This invention employs a two-layer controller structure, with the kinematic controller and dynamic controller sharing a fixed-time gradient template and setting an energy consumption control index in the cost function corresponding to the kinematic controller, achieving fixed-time convergence and energy consumption suppression. Attached Figure Description

[0043] To more clearly illustrate the technical solutions in this invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.

[0044] Figure 1 This is one of the flowcharts illustrating the electric unmanned surface vessel trajectory tracking method provided by the present invention.

[0045] Figure 2 This is a schematic diagram of trajectory tracking modeling in the horizontal coordinate system of the electric unmanned surface vessel provided by the present invention.

[0046] Figure 3 This is the second flowchart illustrating the electric unmanned surface vessel trajectory tracking method provided by the present invention.

[0047] Figure 4 This is one of the structural schematic diagrams of the electric unmanned surface vessel trajectory tracking device provided by the present invention.

[0048] Figure 5 This is the second schematic diagram of the electric unmanned surface vessel trajectory tracking device provided by the present invention.

[0049] Figure 6 This is a schematic diagram of the structure of the electronic device provided by the present invention. Detailed Implementation

[0050] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without creative effort are within the scope of protection of this invention.

[0051] Figure 1 This is one of the flowcharts illustrating the electric unmanned surface vessel trajectory tracking method provided by the present invention, such as... Figure 1 As shown, the method may include steps S110-S150.

[0052] Step S110: Based on the current position of the electric unmanned surface vessel (USV), determine the coordinate error and heading error of the USV.

[0053] The current position of the electric unmanned surface vessel includes coordinate information and heading information. The coordinate information is determined by latitude and longitude coordinates obtained through a high-precision global navigation satellite system, and the heading information is determined by the attitude and acceleration of the vessel sensed by an inertial measurement unit.

[0054] The coordinate error of the electric unmanned surface vessel (USV) is determined based on the coordinate information of the current position and the coordinate information of the desired position. The heading error is determined based on the heading information of the current position and the heading information of the desired position. The desired position can be pre-stored in the USV or the USV's control platform. This invention does not limit this.

[0055] Step S120: Input the coordinate error and the heading error into the kinematics controller of the electric unmanned surface vessel to obtain the virtual speed command output by the kinematics controller.

[0056] The kinematic controller can characterize the mapping relationship between coordinate error, heading error and virtual speed command. Therefore, the coordinate error and heading error are input to the kinematic controller of the electric unmanned surface vessel to obtain the virtual speed command output by the kinematic controller. The virtual speed command includes virtual longitudinal speed command and virtual yaw angle command.

[0057] Step S130: Input the virtual speed command to the dynamics controller of the electric unmanned surface vessel to obtain the virtual thrust command output by the dynamics controller.

[0058] The dynamics controller can characterize the tracking error of the virtual speed command and the virtual thrust command required to reduce the tracking error. Therefore, by inputting the virtual speed command into the dynamics controller of the electric unmanned surface vessel, the virtual thrust command output by the dynamics controller can be obtained.

[0059] Step S140: Based on the virtual thrust command, determine the target control command and send the target control command to the electric unmanned surface vessel.

[0060] Optionally, based on the virtual thrust command, a target control command is determined, including: using the virtual thrust command as the target control command, or updating the low-rank parameters of the kinematic controller and the dynamic controller online to obtain an online thrust command, and fusing the online thrust command with the virtual thrust command to obtain the target control command. It should be understood that the kinematic controller and the dynamic controller before the online update are obtained offline. The virtual thrust command output in step S130 can be understood as an offline strategy, and the online thrust command is an online strategy. The fusion of the online thrust command and the virtual thrust command is the fusion of the offline strategy and the online strategy.

[0061] Step S150: If it is determined that tracking has not been completed, return to the steps of determining the current position of the electric unmanned surface vessel and determining the coordinate error and heading error of the electric unmanned surface vessel, until it is determined that tracking has been completed.

[0062] The kinematic controller and the dynamic controller share a fixed-time gradient template, and the cost function corresponding to the kinematic controller includes an energy consumption control index.

[0063] Optionally, the tracking can be determined by whether the position of the electric unmanned surface vessel after executing the target control command is the target position. If it is, the tracking is considered complete; otherwise, steps S110-S140 are executed repeatedly until the tracking is completed.

[0064] Optionally, a fixed-time gradient template is used to determine an upper bound on the convergence time, independent of the initial value, during the construction of the kinematic and dynamic controllers, achieving fixed-time convergence. An energy consumption control index is set in the cost function corresponding to the kinematic controller; specifically, this refers to explicitly penalizing control effort and energy consumption in the control objective, achieving low energy consumption and smooth thrust.

[0065] It is understood that the present invention adopts a two-layer controller structure and shares a fixed-time gradient template, which can achieve fixed-time convergence and energy consumption suppression.

[0066] As an example, the electric unmanned surface vessel trajectory tracking method provided by the present invention further includes:

[0067] Construct dynamic, kinematic, and error models for electric unmanned surface vessels;

[0068] Based on the dynamic model, the kinematic model, and the error model, a first control affine model and a second control affine model are determined. The first control affine model is used to characterize the correlation between the virtual command corresponding to the kinematic model and the error of the electric unmanned surface vessel. The second control affine model is used to characterize the tracking error of the affine control form of the virtual command of the kinematic model.

[0069] Based on the first control affine model and the kinematic cost function, the kinematic HJB equations are determined, and based on the second control affine model and the dynamic cost function, the dynamic HJB equations are determined.

[0070] Based on a fixed-time gradient template, determine the gradient of a value function with low-rank parameters;

[0071] Based on the value function gradient and the kinematic HJB equation, a kinematic controller is determined; based on the value function gradient and the dynamic HJB equation, a dynamic controller is determined.

[0072] The embodiments of the present invention provide a detailed description of the construction methods for kinematic controllers and dynamic controllers.

[0073] Figure 2 The diagram shows a trajectory tracking modeling diagram of an electric unmanned surface vessel (USV) in a horizontal coordinate system. The USV is tracked for a fixed time. The solid arc line represents the desired trajectory. The parameters in the diagram are the relevant parameters for trajectory tracking modeling.

[0074] In this embodiment of the invention, a three-degree-of-freedom model is constructed in a horizontal coordinate system. The ground-fixed pose and body-fixed velocity of the electric unmanned surface vessel are expressed as Equation (1):

[0075] (1)

[0076] in, This represents the pose vector of the electric unmanned surface vessel in a ground-fixed frame. and These represent the planar position coordinates under the Earth-fixed system; Indicates the heading angle (yaw angle); This represents the velocity vector of the electric unmanned surface vessel in a solid-state frame. and These represent the longitudinal (surge) velocity and the lateral (sway) velocity in a solid-state system, respectively. This represents the yaw rate in a solid-body frame. The kinematic model expression is shown below:

[0077] (2)

[0078] in, Represents the pose vector The derivative with respect to time; This represents the rotation matrix from the solid-body system to the earth-solid system.

[0079] The dynamic model uses diagonal inertia and linear damping approximations, and external disturbances and unmodeled terms are approximated. The summary is as follows:

[0080] (3)

[0081] in, Represents the inertia matrix (using a diagonal approximation); Represent the Coriolis and eccentricity terms matrix; Represents the linear damping matrix (using a diagonal approximation); Represents the velocity vector The derivative with respect to time; Represents the control input vector; This indicates longitudinal thrust (surge force). This represents the yaw moment; a middle component of 0 indicates that there is no direct lateral control force under underactuated conditions. This represents the equivalent composition of external disturbances and unmodeled dynamics.

[0082] The controlled channel in equation (3) can be written in fractional form as follows:

[0083] (4)

[0084] in, These represent the equivalent inertia parameters for the longitudinal, lateral, and yaw channels, respectively. These represent the linear damping coefficients for the longitudinal, lateral, and yaw channels, respectively. These represent the equivalent disturbance / unmodeled components in the longitudinal, lateral, and yaw channels, respectively; They represent speeds respectively. With angular velocity The time derivative. Let the planar coordinate vector of the electric unmanned surface vessel be represented as... The reference coordinate vector is represented as Correspondingly, the initial expression for the body-fixed coordinate error of the electric unmanned surface vessel is as follows:

[0085] (5)

[0086] in, This represents the planar position vector of the unmanned surface vessel in the Earth-fixed system. This represents the planar position vector of the reference trajectory in the Earth-fixed system. These represent the coordinates of the reference plane position; The rotation matrix in expression (2) top left corner Submatrix; This represents the error vector after rotating the position error from the Earth-fixed frame to the volume-fixed frame. Let represent the longitudinal and lateral error components in the solid-state system, respectively. Differentiating equation (5) yields the following equation:

[0087] (6)

[0088] in, express The derivative with respect to time; and Let represent the time derivatives of the actual position vector and the reference position vector, respectively. The two-dimensional antisymmetric matrix is ​​defined as follows:

[0089] (7)

[0090] in, Indicated by yaw rate A two-dimensional antisymmetric (skew-symmetric) matrix is ​​constructed to describe the coupling terms of the plane rotation error.

[0091] Substitute equation (7) into equation (6), and use The final expression for the coordinate error of the solid-fixed system is obtained as follows:

[0092] (8)

[0093] in, Represents the planar velocity components of a solid-body system; Indicates the reference trajectory velocity The feedforward velocity term after rotating to a solid-body system.

[0094] The heading error is wrapped by the principal value to avoid Jump, expression as follows

[0095] (9)

[0096] in, Indicates the reference (expected) heading angle; Represents the arctangent function in the four quadrants; interval This indicates the main range of heading error values.

[0097] Equations (4), (8), and (9) together constitute the error model.

[0098] The steps for determining the first control affine model are as follows:

[0099] The reference body fixed frame feedforward velocity and feedforward yaw rate are defined as follows:

[0100] (10)

[0101] in, These represent the feedforward longitudinal velocity and feedforward lateral velocity of the reference trajectory in a solid-state system, respectively. Represents the reference yaw rate (i.e. (time derivative) This represents the velocity vector in the reference plane.

[0102] The actual longitudinal velocity and yaw rate are decomposed into feedforward terms and feedback virtual terms, as shown below:

[0103] (11)

[0104] in, This represents the virtual longitudinal velocity feedback term of the kinematic layer; This represents the virtual yaw rate feedback term at the kinematic layer.

[0105] Substituting into equation (8) and rearranging, we obtain the following expression for the error kinematics:

[0106] (12)

[0107] (13)

[0108] in, This represents the summation uncertainty in the error kinematics, used to characterize the uncertainty caused by the virtual yaw feedback. Introduced coupling terms And lateral speed mismatch .

[0109] From equations (11) and (9), the dynamic expression for heading error can be obtained as follows:

[0110] (14)

[0111] in, This represents the derivative of the heading error with respect to time.

[0112] Define the state and control of the kinematic layer as follows:

[0113] (15)

[0114] in, Represents the state vector of the kinematic layer; This represents the kinematic layer control (virtual command) vector.

[0115] Equations (12) and (14) are written in affine form, and the expression of the first affine model is as follows:

[0116] (16)

[0117] (17)

[0118] in, Indicates the nominal drift term of the kinematic layer; Represents the input matrix of the kinematic layer; This represents the sum of uncertainties in the kinematic layers; The velocity vector, as shown in equation (1), is used to characterize... Dependence on actual speed conditions.

[0119] item The summarization of lateral velocity mismatch and higher-order coupling will be compensated by the learning residuals and fixed-time templates.

[0120] The steps for determining the second control affine model are as follows:

[0121] The velocity and angular velocity tracking errors are defined as follows:

[0122] (18)

[0123] in, Represents longitudinal velocity For virtual vertical instructions Tracking error; Indicates yaw rate Virtual yaw command Tracking error; This represents the error vector of the dynamic layer.

[0124] Extract the controlled channel from equation (4) and write it in a controlled affine form as follows:

[0125] (19)

[0126]

[0127] (20)

[0128] in, and These represent the nominal nonlinear drift terms for the longitudinal and yaw channels, respectively; and These represent the input gain of the corresponding channel; Represent the equivalent disturbance / unmodeled term for the longitudinal and yaw channels respectively (and in equation (4)). (Consistent or equivalent) The meaning is the same as in formula (3).

[0129] Differentiating equation (18) and substituting it into equation (19), we obtain the following equation:

[0130] (twenty one)

[0131] in, and They represent virtual instructions respectively. and The derivative with respect to time.

[0132] By superimposing the two channels, the expression for the second control affine model is obtained as follows:

[0133] (twenty two)

[0134] (twenty three)

[0135] in, Represents the nominal drift term of the dynamic layer; Represents the input matrix of the dynamics layer; This represents the sum of uncertainties in the dynamic layer; This represents an operator that constructs a diagonal matrix from the elements within the parentheses.

[0136] To achieve low-energy-consumption control, this invention employs an infinite-time-domain performance index of error and control effort in both the kinematic cost function and the dynamic cost function.

[0137] The kinematic cost function is defined as follows:

[0138] (twenty four)

[0139] in, Represents the infinite time-domain performance index of the kinematic layer; Indicates the error in kinematic state The weighted matrix; Indicates the amount of kinematic control The weighted matrix; symbol Represents a symmetric positive definite matrix; upper and lower limits of integration. It represents the infinite time domain.

[0140] Desirable To penalize control efforts for virtual longitudinal velocity and virtual yaw rate separately. This is a corresponding value function. Ignore. The nominal HJB equation is as follows:

[0141] (25)

[0142] in, Represents the kinematic layer value function; Value function represents state The gradient vector; Indicates the control variable Find the minimum value.

[0143] Let the expression in parentheses be Hamiltonian, then... Taking the partial derivative and setting it to zero, we get the following equation:

[0144] (26)

[0145] The optimal feedback form is as follows:

[0146] (27)

[0147] in, This represents the optimal control law for the kinematic layer; Representation matrix The inverse matrix.

[0148] Expanding equation (27) into component form, the expression is as follows:

[0149] (28)

[0150] in, This represents the optimal longitudinal control parameters for the electric unmanned surface vessel. This represents the optimal steering control parameters for the electric unmanned surface vessel. This represents the vertical control weight matrix. The control weight matrix represents the steering parameters. This represents the partial derivative with respect to coordinate error. This represents the partial derivative with respect to the heading error.

[0151] The expression for the dynamic cost function is defined as follows:

[0152] (29)

[0153] in, Represents the infinite time-domain performance index of the dynamics layer; Indicates the dynamic error The weighted matrix; Indicates the dynamic control input The weighted matrix.

[0154] make For corresponding value functions, ignore The nominal HJB equation is shown below:

[0155] (30)

[0156] in, Represents the dynamic layer value function; Value function with respect to error The gradient vector.

[0157] right Taking the partial derivative and setting it to zero, we get the following equation:

[0158] (31)

[0159] The optimal feedback form is as follows:

[0160] (32)

[0161] in, This represents the optimal control law for the dynamic layer; Representation matrix The inverse matrix.

[0162] like The component form is as follows:

[0163] (33)

[0164] in, They represent respectively to and Weighting coefficients for controlled effort; Representing value functions respectively For error components The partial derivatives of .

[0165] As can be seen from equations (27) and (32), the optimal laws of both the kinematic HJB equation and the dynamic HJB equation depend on the gradient of the value function. The key is to construct a fixed-time gradient template and approximate the gradient residual with a low-rank structure.

[0166] The steps for constructing a fixed-time gradient template are as follows:

[0167] scalar error Define a fixed-time Lyapunov component.

[0168] (34)

[0169] in, Represents a Lyapunov component with a fixed time interval; A positive Lyapunov gain coefficient; For the power exponent parameter.

[0170] Its gradient is as follows:

[0171] (35)

[0172] in, Represents a fixed-time gradient function; Represents a symbolic function.

[0173] If the closed loop satisfies ,but:

[0174] (36) The mixed power-type inequalities can be obtained as follows:

[0175] (37)

[0176] in, A positive comparison coefficient; To meet The power exponent parameter.

[0177] By the fixed-time stability lemma, the convergence time is uniformly bounded, as shown below:

[0178] (38)

[0179] in, This represents the upper bound of the fixed-time convergence period.

[0180] The gradient template is constructed by summing the components of the vector state.

[0181] The kinematic gradient and dynamic gradient are as follows:

[0182] (39)

[0183] in, and These represent fixed-time gradient templates for the kinematic and dynamic layers, respectively. The fixed-time gradient function is shown in equation (35).

[0184] A stable skeleton is provided using a fixed-time gradient template, and gradient residuals are fitted using offline / online low-rank structures. For each layer... ,make Let be the gradient dimension of this layer, and take a fixed feature vector. Freeze the last layer of weights .

[0185] in, Representation layer index, Indicates kinematic layers, Indicates the dynamic layer; This indicates the dimension of the gradient vector of the corresponding layer; Indicates the dimension of the feature vector; This indicates a fixed feature map for that layer; This represents the full-rank linear head weight matrix frozen during the offline phase.

[0186] Online weight parameterization is as follows:

[0187] (40)

[0188] in, Represents the linear head weights during the online phase; Represents the low-rank coefficient matrix for online adaptation; Represents the frozen low-rank basis matrix; This represents a low-rank order. We introduce compact notation as follows:

[0189] (41)

[0190] in, This represents the input variables of this layer (which can be taken for kinematic layers). For the dynamic layer, it is possible to take ); Indicates that the entire rank is frozen. The generated offline priors; Indicates features in low-rank basis Projection on; This represents a vectorization operator that stacks matrices column-wise into a vector; Indicates to The vectorized online parameter vector.

[0191] The regression matrix is ​​constructed using the Kronecker identity as follows:

[0192] (42)

[0193] in, Represents the regression matrix; express identity matrix of order 1; symbol This represents the Kronecker product.

[0194] Therefore, the approximate unified expression for the gradient of the two-layer value function is as follows:

[0195] (43)

[0196] in, Presentation layer The value of the function is approximated by the gradient; Presentation layer The low-dimensional parameter vector of the online actor (used to generate the control law). Substituting equation (43) into equation (27), the implementable kinematic layer controller is obtained as follows:

[0197] (44)

[0198] in, and These are the offline prior terms and regression matrix corresponding to the kinematic layer, respectively; For online actor parameters in the kinematic layer.

[0199] Substituting equation (43) into equation (32), we obtain the following achievable dynamic layer controller:

[0200] (45)

[0201] in, and These are the offline prior terms and regression matrix corresponding to the dynamics layer, respectively; These are the parameters for online actors in the dynamics layer.

[0202] Understandably, this invention provides a two-layer fixed-time low-energy control architecture that decomposes trajectory tracking into kinematic virtual command generation and dynamic generalized force tracking. Both layers construct performance indicators based on error and control effort and embed fixed-time Lyapunov gradient templates, providing an upper bound on the convergence time independent of the initial value and explicitly suppressing energy consumption.

[0203] As an example, the electric unmanned surface vessel trajectory tracking method provided by the present invention further includes:

[0204] Construct an expert controller, and generate supervision data based on the expert controller;

[0205] The kinematic controller and the dynamic controller are pre-trained based on the supervised data to obtain gradient priors;

[0206] The gradient prior is subjected to singular value decomposition to obtain a low-rank basis, which is used as a safety prior when the kinematic controller and the dynamic controller are updated online.

[0207] like Figure 3 As shown, the electric unmanned surface vessel trajectory tracking method provided by this invention includes an offline stage and an online stage. In the offline stage, an expert controller is constructed to generate supervised data, and shared features and a frozen linear head are pre-trained to form a gradient prior. And extract low-rank basis through singular value decomposition. .

[0208] Specifically, the kinematic state and dynamic state are first defined as follows:

[0209] (46)

[0210] in, and The meaning is the same as that of equation (15) and equation (18).

[0211] The expert feedforward quantity is defined as follows:

[0212] (47)

[0213] in, The meaning is the same as in formula (10).

[0214] The kinesiology experts provided the following virtual instructions:

[0215] (48)

[0216] in, These represent the virtual longitudinal velocity command and the virtual yaw rate command output by the kinematics expert, respectively. This represents the nominal feedforward longitudinal velocity adopted by the experts (which can be a constant or a reference velocity). These represent the longitudinal errors respectively. lateral error With heading error Expert feedback on gain coefficient; The fixed-time gradient function is shown in equation (35).

[0217] The dynamics expert rewrites the controlled channel as Equation (19) and solves for the expert generalized force in the inverse dynamics form as follows:

[0218]

[0219] (49)

[0220] in, These represent the longitudinal thrust and yaw moment output by the dynamics expert, respectively. These represent expert virtual instructions. The time derivative; The meaning is the same as in formula (20); These represent the dynamic errors respectively. The gain coefficient is based on expert feedback.

[0221] And perform safety saturation as follows:

[0222] (50)

[0223] in, This indicates a saturation operator used to limit the control input to the range of amplitude allowed by the thruster / actuator; This represents the expert control input vector after saturation.

[0224] Offline data samples consist of states, expert outputs, and metadata. The state vector expression is as follows: (51)

[0225] in, This represents the input state vector for offline supervised learning; Let represent the time derivatives of the reference position and reference heading, respectively; the meanings of the other symbols are the same as those in equations (1), (9), (10), (15), and (4), respectively; Incorporating states enhances robustness and adaptability to changes in dynamic parameters.

[0226] The expert's objectives are as follows:

[0227] (52)

[0228] in, This represents the labeled action vector from offline supervised learning.

[0229] Using a shared feature extractor The outputs of the two linear heads are as follows:

[0230] (53)

[0231] in, This represents the feature vector output by the shared feature extractor; These represent the frozen full-rank linear weights of the kinematic head and the dynamic head, respectively; These represent the virtual instructions for network prediction; These represent the control input components for network prediction.

[0232] Offline training primarily uses behavior cloning, with added energy consumption and smoothing regularization. Let... The definition is as follows:

[0233] (54)

[0234] in, Indicates behavioral cloning loss; Represents the Euclidean norm; Indicates the weight coefficients of the control fitting term; This represents the weighting coefficient of the control energy consumption regularization term (used to penalize the control input amplitude). Indicates residual placeholder output The suppression weight coefficient; This represents a placeholder output for a low-rank increment. To embed the HJB structure, a commentator-based approach is introduced. The HJB residual matching term is obtained as follows:

[0235] (55)

[0236] in, Indicates HJB residual matching loss; Indicates by parameters A critic-valued function approximator; Indicates its state The gradient; Represents the positive semidefinite weight matrix for the state term (symbol) (representing symmetric positive semidefinite) This represents the positive definite weight matrix for the control terms; and Represent the drift term and input matrix of the nominal system in the state, respectively. The expression at the location.

[0237] The overall offline objectives are as follows:

[0238] (56)

[0239] in, This represents the total loss during offline training; Indicates the weighting coefficient of the HJB residual term; This represents the coefficient of the weight decay regularization term; This indicates the L2 norm regularization of the network parameters.

[0240] After offline pre-training is completed, singular value decomposition is performed on the weight residuals or gradient matrix of the last layer, and the first few values ​​are taken. Each principal direction serves as a low-rank basis. Freeze Feature Extractor with Full Rank Head In the online phase, only the matrix in adaptive equation (40) .

[0241] in, These represent the frozen low-rank basis matrices of the kinematic and dynamical layers, respectively. For a lower rank, the same as in equation (40).

[0242] It is understood that the present invention generates supervised data by an expert controller, pre-trains shared features to form a stable prior with the full-rank head, and extracts the dominant low-rank direction as a frozen basis through singular value decomposition, so that online exploration starts from a safe prior and reduces the risk of exploration.

[0243] As one embodiment, determining the target control command based on the virtual thrust command includes:

[0244] Based on the fixed time gradient template, the low-rank parameters of the kinematic controller and the dynamic controller are updated online to obtain online thrust commands.

[0245] Based on the online thrust command and the virtual thrust command, the target control command is determined.

[0246] Specifically, during the online phase, commentator parameters are maintained separately for each layer. With actor parameters And based on the regression matrix The Gram matrix is ​​constructed as follows:

[0247] (57)

[0248] in, Represents the Gram matrix; Represents the regularization coefficient; Represents the identity matrix that matches the dimension; Presentation layer Online commentator parameter vector; Presentation layer Online actor parameter vector.

[0249] The fixed-time update law using two sets of parameters is as follows:

[0250] (58)

[0251] in, Representing parameters respectively The derivative with respect to time; This represents the update gain (learning rate) coefficient; This represents the gain coefficient of the actor-commentator coupling term; This represents the gain coefficient of a fixed-time higher-order suppression term; Representing vectors element-wise exponentiation, Representing vectors The element-wise exponentiation.

[0252] Control laws use actor parameters That is, equations (44) and (45).

[0253] Fixed-time convergence can be established using composite Lyapunov functions, for layer... The definition is as follows:

[0254] (59)

[0255] in, Presentation layer Composite Lyapunov functions; Presentation layer The fixed-time Lyapunov component used is the same vector extension as (34). These represent the weighting matrices respectively; The weighted L2 norm square is defined as follows: .

[0256] Its derivative can be used to derive the following mixed power inequality:

[0257] (60)

[0258] in, Representing layers The corresponding positive comparison coefficient; To meet The power exponent parameter.

[0259] Therefore, the convergence time is uniformly bounded as follows:

[0260] (61)

[0261] in, Presentation layer The upper bound of the fixed-time convergence time.

[0262] It is understood that this invention uses a gradient approximation structure consisting of a fixed-time gradient template, offline prior, and online low-rank residual to update only low-dimensional parameters online instead of the entire network weights, thus significantly reducing the computational, storage, and energy overhead of online learning.

[0263] As one embodiment, determining the target control command based on the online thrust command and the virtual thrust command includes:

[0264] Based on the gating fusion mechanism and the abnormal rollback mechanism, the online thrust command and the virtual thrust command are fused to obtain the target control command;

[0265] The gating signal in the gating fusion mechanism is determined based on a time confidence rule or a cost comparison rule. The abnormal rollback mechanism is used to characterize the virtual thrust command as the target control command when the residual in the gating fusion mechanism increases to a threshold.

[0266] Optionally, the abnormal rollback mechanism is also used to roll back the target control command to the virtual thrust command if it is determined that the electric unmanned surface vessel has an abnormal command execution after the target control command is sent to the electric unmanned surface vessel.

[0267] During the deployment phase, online adaptive strategies and offline frozen priors will be gating and integrated.

[0268] Let the online output be The offline prior output is The fusion command is defined as follows:

[0269] (62)

[0270] in, These represent the virtual instructions and control inputs output by the online adaptive strategy, respectively. These represent the offline freeze prior outputs; Represents the kinematic layer gating fusion coefficient; Represents the dynamic layer gated fusion coefficient; inequality The constraint dynamics layer fusion is not faster than the kinematics layer fusion, and both are in... Inside.

[0271] The gating signal can be generated using time confidence rules. Let the residual index be... Represents HJB residuals or time difference residuals, take

[0272] (63)

[0273] in, Represents the unfiltered gated expectation (symbol) express or ); This represents the truncation operator, used to restrict the gate value to a certain range. interval; Indicates the initial gating bias; This represents the time scale coefficient of the term that increases with time. This represents the weighting coefficient of the confidence term; This represents the confidence factor constructed from the residuals; Represents an exponential function; This represents the scaling factor for the residual-to-confidence mapping; This represents the residual index.

[0274] To avoid chattering, a first-order low-pass filter is applied to the gating, as shown below:

[0275] (64)

[0276] in, This represents the gated fusion coefficients after filtering; This represents the cutoff frequency (or filter gain) parameter of a first-order low-pass filter. express The derivative with respect to time.

[0277] Gating can also be generated by cost comparison rules, with the instantaneous cost as follows:

[0278] (65)

[0279] in, Indicates instantaneous cost; This represents the state vector used for evaluation (which can be either the kinematic layer state or the dynamic layer error state). This represents the corresponding control vector (which can be a virtual command or thrust input). These represent the weight matrices for the state term and the control term, respectively.

[0280] Calculate online and offline separately and Take the following formula:

[0281] (66)

[0282] in, This represents the instantaneous cost corresponding to the online strategy; This represents the instantaneous cost corresponding to the offline prior; This represents the scaling factor used to map the cost difference to the gate quantity; Represents an sigmoid function; This represents the independent variable of the sigmoid function; The base of the natural constant.

[0283] It should be noted that strategies with better cost and smaller residuals will receive greater weight.

[0284] If an abnormal increase in residuals or unstable execution occurs during the online phase, the gating will be quickly reduced and reverted to the offline prior, thereby ensuring safety and controllable energy consumption.

[0285] It is understood that the gating mechanism based on time confidence and cost comparison in this invention enables lower energy consumption and higher accuracy after the online strategy matures, and quickly reverts to offline priors in case of anomalies to ensure safety.

[0286] The electric unmanned surface vessel (USV) trajectory tracking device provided by the present invention is described below. The electric USV trajectory tracking device described below can be referred to in correspondence with the electric USV trajectory tracking method described above.

[0287] Figure 4 This is one of the structural schematic diagrams of the electric unmanned surface vessel trajectory tracking device provided by the present invention. Figure 5 This is the second structural schematic diagram of the electric unmanned surface vessel trajectory tracking device provided by the present invention, as shown below. Figure 4 and Figure 5 As shown, the present invention also provides an electric unmanned surface vessel trajectory tracking device, comprising:

[0288] Error determination module 410 is used to determine the coordinate error and heading error of the electric unmanned surface vessel based on its current position.

[0289] The first instruction determination module 420 is used to input the coordinate error and the heading error to the kinematic controller of the electric unmanned surface vessel to obtain the virtual speed command output by the kinematic controller; and to input the virtual speed command to the dynamic controller of the electric unmanned surface vessel to obtain the virtual thrust command output by the dynamic controller.

[0290] The second instruction determination module 430 is used to determine the target control instruction based on the virtual thrust instruction and send the target control instruction to the electric unmanned surface vessel.

[0291] The electric unmanned surface vessel (USV) tracking module 440 is used to return to the steps of determining the coordinate error and heading error of the USV based on its current position if the tracking is not completed, until the tracking is determined to be completed.

[0292] The kinematic controller and the dynamic controller share a fixed-time gradient template, and the cost function corresponding to the kinematic controller includes an energy consumption control index.

[0293] As one embodiment, the second instruction determining module 430 is used for:

[0294] Based on the fixed time gradient template, the low-rank parameters of the kinematic controller and the dynamic controller are updated online to obtain online thrust commands.

[0295] Based on the online thrust command and the virtual thrust command, the target control command is determined.

[0296] As one embodiment, the second instruction determining module 430 is used for:

[0297] Based on the gating fusion mechanism and the abnormal rollback mechanism, the online thrust command and the virtual thrust command are fused to obtain the target control command;

[0298] The gating signal in the gating fusion mechanism is determined based on a time confidence rule or a cost comparison rule. The abnormal rollback mechanism is used to characterize the virtual thrust command as the target control command when the residual in the gating fusion mechanism increases to a threshold.

[0299] As an example, the abnormal rollback mechanism is also used to roll back the target control command to the virtual thrust command if it is determined that the electric unmanned surface vessel has an abnormal command execution after the target control command is sent to the electric unmanned surface vessel.

[0300] As one embodiment, it also includes:

[0301] An offline preprocessing module is used to construct an expert controller and generate supervision data based on the expert controller; pre-train the kinematic controller and the dynamic controller based on the supervision data to obtain gradient priors; perform singular value decomposition on the gradient priors to obtain low-rank basis, which is used as a safety prior for online updates of the kinematic controller and the dynamic controller.

[0302] As one embodiment, it also includes:

[0303] The controller determination module is used to construct a dynamic model, a kinematic model, and an error model of the electric unmanned surface vessel (USV); based on the dynamic model, the kinematic model, and the error model, it determines a first control affine model and a second control affine model. The first control affine model is used to characterize the correlation between the virtual commands corresponding to the kinematic model and the errors of the USV through affine control forms, and the second control affine model is used to characterize the tracking error of the affine control forms of the virtual commands of the kinematic model; based on the first control affine model and the kinematic cost function, it determines the kinematic HJB equations, and based on the second control affine model and the dynamic cost function, it determines the dynamic HJB equations; based on a fixed-time gradient template, it determines the value function gradient with low-rank parameters; based on the value function gradient and the kinematic HJB equations, it determines the kinematic controller, and based on the value function gradient and the dynamic HJB equations, it determines the dynamic controller.

[0304] It should be noted that the electric unmanned surface vessel trajectory tracking device provided by this invention has the same technical effects as the electric unmanned surface vessel trajectory tracking method, which will not be elaborated further.

[0305] Figure 6 An example is a schematic diagram of the physical structure of an electronic device, such as... Figure 6As shown, the electronic device may include: a processor 610, a communications interface 620, a memory 630, and a communication bus 640, wherein the processor 610, the communications interface 620, and the memory 630 communicate with each other via the communication bus 640. The processor 610 can call logical instructions in the memory 630 to execute an electric unmanned surface vessel trajectory tracking method, which includes:

[0306] Based on the current position of the electric unmanned surface vessel (USV), determine the coordinate error and heading error of the USV.

[0307] The coordinate error and the heading error are input to the kinematics controller of the electric unmanned surface vessel to obtain the virtual speed command output by the kinematics controller;

[0308] The virtual speed command is input to the dynamics controller of the electric unmanned surface vessel to obtain the virtual thrust command output by the dynamics controller;

[0309] Based on the virtual thrust command, a target control command is determined and sent to the electric unmanned surface vessel.

[0310] If it is determined that tracking has not been completed, return to the current position based on the electric unmanned surface vessel, determine the coordinate error and heading error of the electric unmanned surface vessel, and continue until it is determined that tracking has been completed;

[0311] The kinematic controller and the dynamic controller share a fixed-time gradient template, and the cost function corresponding to the kinematic controller includes an energy consumption control index.

[0312] Furthermore, the logical instructions in the aforementioned memory 630 can be implemented as software functional units and, when sold or used as independent products, can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0313] On the other hand, the present invention also provides a computer program product, the computer program product comprising a computer program that can be stored on a non-transitory computer-readable storage medium, wherein when the computer program is executed by a processor, the computer is able to execute the electric unmanned surface vessel trajectory tracking method provided by the above methods, the method comprising:

[0314] Based on the current position of the electric unmanned surface vessel (USV), determine the coordinate error and heading error of the USV.

[0315] The coordinate error and the heading error are input to the kinematics controller of the electric unmanned surface vessel to obtain the virtual speed command output by the kinematics controller;

[0316] The virtual speed command is input to the dynamics controller of the electric unmanned surface vessel to obtain the virtual thrust command output by the dynamics controller;

[0317] Based on the virtual thrust command, a target control command is determined and sent to the electric unmanned surface vessel.

[0318] If it is determined that tracking has not been completed, return to the current position based on the electric unmanned surface vessel, determine the coordinate error and heading error of the electric unmanned surface vessel, and continue until it is determined that tracking has been completed;

[0319] The kinematic controller and the dynamic controller share a fixed-time gradient template, and the cost function corresponding to the kinematic controller includes an energy consumption control index.

[0320] In another aspect, the present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the electric unmanned surface vessel trajectory tracking method provided by the methods described above, the method comprising:

[0321] Based on the current position of the electric unmanned surface vessel (USV), determine the coordinate error and heading error of the USV.

[0322] The coordinate error and the heading error are input to the kinematics controller of the electric unmanned surface vessel to obtain the virtual speed command output by the kinematics controller;

[0323] The virtual speed command is input to the dynamics controller of the electric unmanned surface vessel to obtain the virtual thrust command output by the dynamics controller;

[0324] Based on the virtual thrust command, a target control command is determined and sent to the electric unmanned surface vessel.

[0325] If it is determined that tracking has not been completed, return to the current position based on the electric unmanned surface vessel, determine the coordinate error and heading error of the electric unmanned surface vessel, and continue until it is determined that tracking has been completed;

[0326] The kinematic controller and the dynamic controller share a fixed-time gradient template, and the cost function corresponding to the kinematic controller includes an energy consumption control index.

[0327] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.

[0328] Through the above description of the embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in the various embodiments or some parts of the embodiments.

[0329] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A method for tracking the trajectory of an electric unmanned surface vessel, characterized in that, include: Based on the current position of the electric unmanned surface vessel (USV), determine the coordinate error and heading error of the USV. The coordinate error and the heading error are input to the kinematics controller of the electric unmanned surface vessel to obtain the virtual speed command output by the kinematics controller; The virtual speed command is input to the dynamics controller of the electric unmanned surface vessel to obtain the virtual thrust command output by the dynamics controller; Based on the virtual thrust command, a target control command is determined and sent to the electric unmanned surface vessel. If it is determined that tracking has not been completed, return to the current position based on the electric unmanned surface vessel, determine the coordinate error and heading error of the electric unmanned surface vessel, and continue until it is determined that tracking has been completed; The kinematic controller and the dynamic controller share a fixed-time gradient template, and the cost function corresponding to the kinematic controller includes an energy consumption control index. Fixed-time gradient templates are used to determine an upper bound on the convergence time that is independent of the initial value during the construction of kinematic and dynamic controllers, thereby achieving fixed-time convergence. The steps for constructing a fixed-time gradient template are as follows: scalar error Define a fixed-time Lyapunov component as follows: ; in, Represents a Lyapunov component with a fixed time interval; A positive Lyapunov gain coefficient; For the power exponent parameter; The gradient is as follows: ; in, Represents a fixed-time gradient function; Represents a symbolic function; If the closed loop satisfies ,but: ; The mixed power-type inequalities are obtained as follows: ; in, A positive comparison coefficient; To meet The power exponent parameter.

2. The electric unmanned surface vessel trajectory tracking method according to claim 1, characterized in that, The determination of the target control command based on the virtual thrust command includes: Based on the fixed time gradient template, the low-rank parameters of the kinematic controller and the dynamic controller are updated online to obtain online thrust commands. Based on the online thrust command and the virtual thrust command, the target control command is determined.

3. The electric unmanned surface vessel trajectory tracking method according to claim 2, characterized in that, The determination of the target control command based on the online thrust command and the virtual thrust command includes: Based on the gating fusion mechanism and the abnormal rollback mechanism, the online thrust command and the virtual thrust command are fused to obtain the target control command; The gating signal in the gating fusion mechanism is determined based on a time confidence rule or a cost comparison rule. The abnormal rollback mechanism is used to characterize the virtual thrust command as the target control command when the residual in the gating fusion mechanism increases to a threshold.

4. The electric unmanned surface vessel trajectory tracking method according to claim 3, characterized in that, The abnormal rollback mechanism is also used to roll back the target control command to the virtual thrust command if, after sending the target control command to the electric unmanned surface vessel, it is determined that the electric unmanned surface vessel has an abnormal command execution.

5. The electric unmanned surface vessel trajectory tracking method according to any one of claims 2 to 4, characterized in that, Also includes: Construct an expert controller, and generate supervision data based on the expert controller; The kinematic controller and the dynamic controller are pre-trained based on the supervised data to obtain gradient priors; The gradient prior is subjected to singular value decomposition to obtain a low-rank basis, which is used as a safety prior when the kinematic controller and the dynamic controller are updated online.

6. The electric unmanned surface vessel trajectory tracking method according to claim 1, characterized in that, Also includes: Construct dynamic, kinematic, and error models for electric unmanned surface vessels; Based on the dynamic model, the kinematic model, and the error model, a first control affine model and a second control affine model are determined. The first control affine model is used to characterize the correlation between the virtual command corresponding to the kinematic model and the error of the electric unmanned surface vessel. The second control affine model is used to characterize the tracking error of the affine control form of the virtual command of the kinematic model. Based on the first control affine model and the kinematic cost function, the kinematic HJB equations are determined, and based on the second control affine model and the dynamic cost function, the dynamic HJB equations are determined. Based on a fixed-time gradient template, determine the gradient of a value function with low-rank parameters; Based on the value function gradient and the kinematic HJB equations, a kinematic controller is determined; based on the value function gradient and the dynamic HJB equations, a dynamic controller is determined.

7. An electric unmanned surface vessel trajectory tracking device, characterized in that, The apparatus for implementing the electric unmanned surface vessel trajectory tracking method according to any one of claims 1 to 6 includes: An error determination module is used to determine the coordinate error and heading error of the electric unmanned surface vessel based on its current position. The first instruction determination module is used to input the coordinate error and the heading error into the kinematic controller of the electric unmanned surface vessel to obtain a virtual velocity instruction output by the kinematic controller; and to input the virtual velocity instruction into the dynamic controller of the electric unmanned surface vessel to obtain a virtual thrust instruction output by the dynamic controller. The second instruction determination module is used to determine the target control instruction based on the virtual thrust instruction and send the target control instruction to the electric unmanned surface vessel. The electric unmanned surface vessel (USV) tracking module is used to return to the steps of determining the coordinate error and heading error of the USV based on its current position if tracking is not completed, until tracking is determined to be completed. The kinematic controller and the dynamic controller share a fixed-time gradient template, and the cost function corresponding to the kinematic controller includes an energy consumption control index.

8. An electronic device comprising a memory, a processor, and a computer program stored in the memory and running on the processor, characterized in that, When the processor executes the computer program, it implements the electric unmanned surface vessel trajectory tracking method as described in any one of claims 1 to 6.

9. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the electric unmanned surface vessel trajectory tracking method as described in any one of claims 1 to 6.

10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by the processor, it implements the electric unmanned surface vessel trajectory tracking method as described in any one of claims 1 to 6.