A method and device for adjusting the posture of a marine floating body, an electronic device and a medium

By introducing a two-dimensional planar hydrodynamic control equation as a physical constraint in the attitude adjustment of floating bodies at sea, and training a neural network to optimize the horizontal eddy viscosity coefficient, the problems of low computational efficiency and insufficient real-time prediction in existing technologies are solved, and high-precision and rapid attitude adjustment of floating bodies at sea is achieved.

CN122239751APending Publication Date: 2026-06-19CHINA THREE GORGES CORPORATION

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
CHINA THREE GORGES CORPORATION
Filing Date
2026-04-07
Publication Date
2026-06-19

AI Technical Summary

Technical Problem

Existing technologies rely on empirical parameters, have low computational efficiency, and are difficult to predict the movement trend of floating bodies under complex hydrodynamic characteristics in real time, resulting in insufficient accuracy and timeliness of attitude adjustment of floating bodies at sea.

Method used

By establishing a two-dimensional planar hydrodynamic control equation as a physical constraint, constructing an objective function based on measured data, training a neural network to optimize the horizontal eddy viscosity coefficient, and building a prediction model, high-speed, real-time calculation of hydrodynamic state and attitude adjustment can be achieved.

Benefits of technology

It improves the adaptive control accuracy and response speed of floating bodies in complex marine environments, ensuring the accuracy and timeliness of attitude adjustment.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122239751A_ABST
    Figure CN122239751A_ABST
Patent Text Reader

Abstract

This invention relates to the field of offshore wind farm engineering technology, and discloses a method, device, electronic equipment, and medium for adjusting the motion attitude of offshore floating bodies. This invention uses the two-dimensional planar hydrodynamic control equations describing the ocean dynamic mechanism as physical constraints, directly embedding them into the training of a neural network. During training, the neural network not only learns the statistical characteristics of measured data but is also required to satisfy the physical laws of mass and momentum conservation. Based on this, an objective function is constructed and the neural network is trained to obtain a predictive model. During prediction, it can achieve high-speed, real-time calculation of the hydrodynamic field state, enabling the offshore floating body to generate and execute attitude adjustment commands in real time based on more accurate environmental trend predictions. This significantly improves the accuracy, response speed, and overall reliability of adaptive control in complex and variable marine environments.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of offshore wind farm engineering technology, specifically to a method, device, electronic equipment, and medium for adjusting the motion attitude of a floating body at sea. Background Technology

[0002] The development and construction of offshore wind farms is in a phase of rapid growth. Large-scale marine modeling and complex ocean hydrodynamic conditions are difficult to achieve through physical models; therefore, their design, construction, and operation largely rely on numerical simulations. Currently, the key to the design, construction, and operation of offshore floating wind farms is the floating body. To ensure the structural safety, operational stability, and energy capture efficiency of the floating body in the complex and ever-changing marine environment, real-time and accurate attitude adjustment is essential. The motion of the floating body under the coupled effects of waves, currents, and wind loads directly affects the load distribution of its critical components, structural fatigue life, and the wind resistance performance and power generation efficiency of the turbine. Therefore, predicting and adjusting the floating body's attitude is a necessary technical means to ensure its long-term reliable and efficient operation.

[0003] Existing methods for predicting the attitude and trends of floating bodies largely rely on commercial software. However, marine environmental factors such as hydrology, meteorology, and geology are complex and variable. Current marine floating body analysis software often simply overlays hydrodynamic modules, failing to fully describe the complex hydrodynamic characteristics under the influence of marine structures and the true motion state of systems such as offshore wind turbines. For nearshore waters, hydrodynamic simulation requires two-dimensional planar features, necessitating advance prediction of surface current velocity to forecast the floating body's motion trend and adjust its attitude accordingly. Traditional hydrodynamic simulation processes are complex, relying heavily on experience for results, resulting in poor computational efficiency and an inability to reflect the floating body's motion in real time. Summary of the Invention

[0004] This invention provides a method, device, electronic device, and medium for adjusting the motion attitude of a floating body at sea, in order to solve the problems of insufficient accuracy and timeliness of attitude adjustment caused by relying on empirical parameters, low computational efficiency, and difficulty in real-time prediction of the motion trend of a floating body under complex hydrodynamic characteristics in the prior art.

[0005] In a first aspect, the present invention provides a method for adjusting the motion attitude of a floating body at sea, comprising: establishing a two-dimensional planar hydrodynamic control equation for a target sea area, wherein the control equation includes hydrodynamic state variables and horizontal eddy viscosity coefficients to be solved; constructing a neural network with spatiotemporal coordinates as input and hydrodynamic state variables as output; using the two-dimensional planar hydrodynamic control equation as a physical constraint and integrating it with measured data from the target sea area to construct an objective function for training the neural network; optimizing the objective function to solve for the optimal parameters of the neural network and the horizontal eddy viscosity coefficient in the control equation, thereby obtaining a trained neural network as a prediction model; inputting the spatiotemporal coordinates of the target position of the floating body at sea into the prediction model to obtain predicted values ​​of the hydrodynamic state variables; and generating control commands for adjusting the motion attitude of the floating body based on the predicted values.

[0006] This invention directly embeds the two-dimensional planar hydrodynamic control equations describing ocean dynamics as physical constraints into the training of a neural network. This allows the neural network to not only learn the statistical characteristics of measured data during training but also to satisfy the physical laws of mass and momentum conservation. The introduction of this physical constraint enables key physical parameters that were previously difficult to directly observe and accurately calibrate—namely, the eddy viscosity coefficients in both horizontal directions—to be solved synchronously with the neural network weights within the same optimization framework. This process utilizes the strong regularity provided by the physical equations to effectively constrain the parameter solution space, resulting in a set of optimal parameters that both conform to the data distribution and strictly satisfy physical laws. Based on this, the trained neural network becomes a predictive model capable of high-speed, real-time calculation of the hydrodynamic field state, fundamentally solving the bottlenecks of traditional methods that rely on empirical parameters, have low computational efficiency, and are difficult to apply in real time. This invention enables floating bodies at sea to generate and execute attitude adjustment commands in real time based on more accurate and forward-looking environmental trend predictions, thereby significantly improving the accuracy, response speed, and overall reliability of adaptive control in complex and variable marine environments.

[0007] In one optional implementation, the step of establishing the two-dimensional hydrodynamic control equations for the target sea area includes: establishing a continuity equation describing the relationship between the rate of change of water level and the net flow in the horizontal direction based on the law of conservation of mass; establishing a first momentum balance equation in the first horizontal direction based on the law of conservation of momentum; and establishing a second momentum balance equation in the second horizontal direction based on the law of conservation of momentum; wherein the first horizontal direction and the second horizontal direction are two mutually orthogonal horizontal directions, and both the first and second momentum balance equations include the horizontal eddy viscosity coefficient.

[0008] This implementation method, by strictly adhering to the laws of conservation of mass and momentum, establishes two-dimensional hydrodynamic control equations in two orthogonal horizontal directions, incorporating the horizontal eddy viscosity coefficient. This embeds the key physical parameter describing the turbulent mixing effect, namely the horizontal eddy viscosity coefficient, into the control equations, thus laying a precise mathematical and physical foundation for subsequent steps. In this way, necessary constraints are provided for subsequent neural network training, ensuring that the network parameters obtained from the final inversion and the prediction results based on them are fundamentally consistent with the physical laws governing actual ocean dynamic processes.

[0009] In one optional implementation, the neural network adopts a physical information neural network, and the output node is a hydrodynamic state variable. The hydrodynamic state variable includes the relative water surface height, the vertical average flow velocity in the first horizontal direction, and the vertical average flow velocity in the second horizontal direction. The first horizontal direction and the second horizontal direction are two mutually orthogonal horizontal directions.

[0010] The aforementioned physical information neural network is built upon a deep feedforward neural network. This network consists of a series of nonlinear activation functions, which ultimately combine to form an output function. This output function can approximate any function in terms of nonlinear function optimization. This implementation leverages the powerful function approximation capabilities of neural networks, enabling flexible mapping of complex ocean conditions. Furthermore, it provides a data interface for embedding physical equations as constraints into the training process. This ensures that the final trained model not only fits the data but also satisfies physical conservation laws, thereby significantly improving the reliability and physical plausibility of predictions.

[0011] In one alternative implementation, the step of using the two-dimensional planar hydrodynamic control equations as physical constraints and fusing them with measured data from the target sea area to construct an objective function for training a neural network includes: converting the control equations into corresponding physical constraint residuals; calculating the data fitting residuals between the neural network output and the measured data; and combining the physical constraint residuals with the data fitting residuals to construct the objective function.

[0012] This implementation method constructs the objective function by transforming the hydrodynamic control equations into physically constrained residuals and combining them with residuals from fitting measured data, achieving a deep integration of physical mechanisms and data-driven approaches. Specifically, the physically constrained residuals force the neural network to satisfy fundamental physical laws such as mass and momentum conservation during training, ensuring the physical rationality and reliability of the model output. The data fitting residuals, on the other hand, drive the neural network to learn the observational characteristics of specific sea areas, guaranteeing the consistency between the predicted results and the actual situation. The combination of these two approaches allows the training process to achieve an optimal trade-off between "following objective physical laws" and "fitting specific observational data," thereby obtaining a highly reliable prediction model that possesses both physical consistency and data adaptability. This provides a crucial guarantee for the subsequent accurate and efficient attitude adjustment of floating bodies at sea.

[0013] In one optional implementation, the step of transforming the governing equations into corresponding physical constraint residual terms includes: constructing a first physical constraint residual term based on the continuity equation in the governing equations to measure the deviation of mass conservation; constructing a second physical constraint residual term based on the first momentum balance equation in the governing equations to measure the deviation of momentum conservation in the first horizontal direction; and constructing a third physical constraint residual term based on the second momentum balance equation in the governing equations to measure the deviation of momentum conservation in the second horizontal direction; wherein the first, second, and third physical constraint residual terms together constitute the physical constraint residual terms, and the second and third physical constraint residual terms both contain the horizontal eddy viscosity coefficient.

[0014] This implementation method achieves a mathematical expression of the laws of conservation of mass and momentum by constructing physical constraint residual terms corresponding to the continuity equation and the momentum equations in two directions, transforming abstract physical constraints into concrete indicators and providing clear physical constraints for the neural network. Simultaneously, this implementation method introduces the horizontal eddy viscosity coefficient into the residual term of momentum balance, ensuring that this key physical parameter can directly participate in the training process. This allows parameter inversion and network optimization to be performed synchronously within a unified physical constraint framework, laying a solid foundation for generating a predictive model that combines strict physical consistency with high-precision data fitting capabilities.

[0015] In one optional implementation, the step of calculating the data fitting residual term between the neural network output and the measured data includes: acquiring measured data of the target sea area, the measured data including measured water level data and measured current velocity data; constructing a first data fitting residual term based on the deviation between the relative water surface height output by the neural network and the measured water level data; constructing a second data fitting residual term based on the deviation between the vertical average current velocity in the first horizontal direction output by the neural network and the corresponding directional component in the measured current velocity data; and constructing a third data fitting residual term based on the deviation between the vertical average current velocity in the second horizontal direction output by the neural network and the corresponding directional component in the measured current velocity data; wherein the first, second, and third data fitting residual terms together constitute the data fitting residual term.

[0016] This implementation method constructs independent data fitting residual terms for water level and flow velocity in two orthogonal directions, thereby achieving refined utilization of multi-source heterogeneous measured data. This ensures that the neural network can learn the true distribution of each hydrodynamic element in a balanced manner, avoids optimization bias caused by mixing data of different dimensions, and effectively improves the model's accuracy and generalization ability in depicting the real marine environment.

[0017] In one optional implementation, the steps of optimizing the objective function to solve for the optimal parameters of the neural network and the horizontal eddy viscosity coefficient in the control equation, thereby obtaining the trained neural network as a prediction model, include: optimizing the objective function, simultaneously determining the value of the horizontal eddy viscosity coefficient and the initial parameters of the neural network, the initial parameters including the weight parameters of the neural network activation function; substituting the determined value of the horizontal eddy viscosity coefficient into the physical constraint residual term; using the weight parameters as optimization variables, optimizing the weight parameters by minimizing the physical constraint residual term after substituting the horizontal eddy viscosity coefficient, until the convergence condition is met, the obtained weight parameters are the optimal weight parameters of the neural network activation function, thus obtaining the optimal parameters of the neural network, and using the neural network corresponding to the optimal parameters as the prediction model.

[0018] This implementation first determines the viscosity coefficient and initial network parameters through an objective function, providing initial data for subsequent fine-tuning. Then, the initially derived viscosity coefficient is substituted into physical constraints to optimize the weights of the neural network activation function, obtaining the optimal parameters for the neural network. This phased optimization path not only improves the stability and accuracy of parameter inversion but also ensures, through physical constraints, that the final prediction model possesses both strict physical consistency and high data adaptability.

[0019] Secondly, the present invention provides a device for adjusting the motion attitude of a floating body at sea, comprising: a control equation construction module for establishing a two-dimensional planar hydrodynamic control equation for a target sea area, wherein the control equation includes hydrodynamic state variables and horizontal eddy viscosity coefficients to be solved; a neural network construction module for constructing a neural network with spatiotemporal coordinates as input and hydrodynamic state variables as output; a training target determination module for using the two-dimensional planar hydrodynamic control equation as a physical constraint and integrating it with measured data from the target sea area to construct an objective function for training the neural network; a parameter optimization module for optimizing the objective function to solve for the optimal parameters of the neural network and the horizontal eddy viscosity coefficient in the control equation, thereby obtaining a trained neural network as a prediction model; a variable prediction module for inputting the spatiotemporal coordinates of the floating body target position into the prediction model to obtain predicted values ​​of the hydrodynamic state variables; and a command adjustment module for generating control commands for adjusting the motion attitude of the floating body based on the predicted values.

[0020] Thirdly, the present invention provides an electronic device, comprising: a memory and a processor, the memory and the processor being communicatively connected to each other, the memory storing computer instructions, and the processor executing the computer instructions to perform the above-described method for adjusting the motion attitude of a floating body at sea, or any of its corresponding embodiments.

[0021] Fourthly, the present invention provides a computer-readable storage medium storing computer instructions for causing a computer to execute the method for adjusting the motion attitude of a floating body at sea as described in the first aspect or any corresponding embodiment thereof. Attached Figure Description

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

[0023] Figure 1 This is a schematic flowchart of a first method for adjusting the motion attitude of a floating body at sea according to an embodiment of the present invention. Figure 2 This is a schematic diagram of the second process of the method for adjusting the motion attitude of a floating body at sea according to an embodiment of the present invention; Figure 3 This is a structural block diagram of a marine floating body motion attitude adjustment device according to an embodiment of the present invention; Figure 4 This is a schematic diagram of the hardware structure of an electronic device according to an embodiment of the present invention. Detailed Implementation

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

[0025] It is understood that before using the technical solutions disclosed in the various embodiments of the present invention, users should be informed of the types, scope of use, and usage scenarios of the personal information involved in the present invention and their authorization should be obtained in accordance with relevant laws and regulations through appropriate means.

[0026] The terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature. In the description of this invention, "a plurality of" means two or more, unless otherwise explicitly specified.

[0027] While offshore wind power is developing rapidly, the precise attitude control of its floating platforms still faces severe challenges. Traditional numerical simulation methods, which rely on commercial software and empirical parameters, struggle to fully characterize the coupling effects of complex marine environments and structures. Furthermore, they suffer from low computational efficiency and the inability to predict in real time, resulting in insufficient accuracy and timeliness in attitude control. This directly threatens platform safety and affects power generation efficiency. Therefore, this invention provides a method, device, electronic equipment, and medium for adjusting the attitude of offshore floating bodies, addressing the problems of insufficient accuracy and timeliness in attitude control caused by existing technologies that rely on empirical parameters, have low computational efficiency, and struggle to predict the motion trends of floating bodies under complex hydrodynamic characteristics in real time.

[0028] According to an embodiment of the present invention, a method for adjusting the motion attitude of a floating body at sea is provided. It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions. Furthermore, although a logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in a different order than that shown here.

[0029] This embodiment provides a method for adjusting the motion attitude of a floating body at sea. Figure 1 This is a flowchart of a method for adjusting the motion attitude of a floating body at sea according to an embodiment of the present invention, such as... Figure 1 As shown, the process includes the following steps: Step S101: Establish the two-dimensional hydrodynamic control equations for the target sea area. The control equations include the hydrodynamic state variables and horizontal eddy viscosity coefficients to be solved.

[0030] Among them, the two-dimensional planar hydrodynamic control equations refer to a set of partial differential equations constructed based on the basic physical laws of fluid mechanics to describe the motion of water bodies in the target sea area.

[0031] The governing equations of this invention explicitly include two types of unknowns: one type is the hydrodynamic state variables that directly reflect the dynamic state of the sea area, mainly including the relative water surface height, the vertically averaged velocity in the first horizontal direction, and the vertically averaged velocity in the second horizontal direction, where the first and second horizontal directions are two mutually orthogonal horizontal directions; the other type is the key physical parameter characterizing the turbulent mixing effect of the water body, namely the horizontal eddy viscosity coefficient. This coefficient reflects the diffusion intensity of momentum in the horizontal direction due to turbulence. In traditional methods, it usually relies on empirical values, but in this invention, it is used as one of the core unknown parameters to be inverted. By establishing this physical equation containing specific unknown parameters, a precise mathematical description and constraint foundation is provided for the subsequent intelligent solution method that integrates physical mechanisms and data-driven approaches.

[0032] Step S102: Construct a neural network with spatiotemporal coordinates as input and hydrodynamic state variables as output.

[0033] This step is used to build the initial neural network framework. Specifically, it takes spatiotemporal coordinates as input, representing the planar position and specific time of any point in the target sea area; and hydrodynamic state variables as output, which directly correspond to the unknowns to be solved in the governing equations: the relative water surface height and the vertical average flow velocity in two mutually orthogonal horizontal directions.

[0034] Step S103: The two-dimensional hydrodynamic control equations are used as physical constraints and fused with the measured data of the target sea area to construct an objective function for training the neural network.

[0035] This step first transforms the governing equations established in step S101 into physical constraint residuals, quantifying the degree to which the network output violates physical laws. Second, based on measured data from the target sea area, the deviation between the neural network output and the measured values ​​is calculated, forming a data fitting residual term, which quantifies the gap between the network output and the actual observation data. Finally, the physical constraint residual term and the data fitting residual term are combined to construct a unified objective function, ensuring that the neural network output satisfies the physical equations as much as possible while approximating the measured data as closely as possible.

[0036] Step S104: By optimizing the objective function, the optimal parameters of the neural network and the horizontal eddy viscosity coefficient in the control equation are solved to obtain the trained neural network as a prediction model.

[0037] This step first treats the neural network parameters and the horizontal eddy viscosity coefficient from the physical equations as optimizable variables. The optimization algorithm iteratively adjusts these variables to minimize the objective function constructed in step S103. During optimization, the constraints provided by the physical equations ensure that the retrieved horizontal eddy viscosity coefficient conforms to the inherent laws of fluid dynamics, while the measured data ensures that the neural network parameters accurately fit the observed characteristics of a specific sea area. When the optimization process converges, the obtained neural network weight parameters are the optimal network parameters, and the obtained horizontal eddy viscosity coefficient value is the optimal physical parameter corresponding to that sea area.

[0038] Step S105: Input the spatiotemporal coordinates of the floating target position at sea into the prediction model to obtain the predicted values ​​of the hydrodynamic state variables.

[0039] This step first obtains the spatiotemporal coordinates of the target position of interest to the floating body at sea and the future time. After inputting these coordinates into the model, the predicted values ​​of the hydrodynamic state variables corresponding to these spatiotemporal coordinates are directly predicted and output. This enables real-time and rapid prediction of the hydrodynamic state at any specified position and time, providing a key reference for the subsequent real-time control of the floating body's attitude.

[0040] Step S106: Generate control commands for adjusting the motion attitude of the floating body based on the predicted values.

[0041] The method for adjusting the motion attitude of a floating body at sea provided in this embodiment directly embeds the two-dimensional hydrodynamic control equations describing the ocean dynamic mechanism into the training of a neural network. This allows the neural network to not only learn the statistical characteristics of measured data during training but also to satisfy the physical laws of mass and momentum conservation. The introduction of this physical constraint enables key physical parameters that were previously difficult to directly observe and accurately calibrate—namely, the eddy viscosity coefficients in the two horizontal directions—to be solved synchronously with the neural network weights within the same optimization framework. This process utilizes the strong regularity provided by the physical equations to effectively constrain the parameter solution space, thereby obtaining a set of optimal parameters that both conform to the data distribution and strictly satisfy physical laws. Based on this, the trained neural network becomes a predictive model, capable of high-speed, real-time calculation of the hydrodynamic field state during prediction. This fundamentally solves the bottlenecks of traditional methods, which rely on empirical parameters, have low computational efficiency, and are difficult to apply in real time. This method enables floating bodies at sea to generate and execute attitude adjustment commands in real time based on more accurate and forward-looking environmental trend predictions, thus significantly improving the accuracy, response speed, and overall reliability of adaptive control in complex and variable marine environments.

[0042] This embodiment provides a method for adjusting the motion attitude of a floating body at sea. Figure 2This is a flowchart of a method for adjusting the motion attitude of a floating body at sea according to an embodiment of the present invention, such as... Figure 2 As shown, the process includes the following steps: Step S201: Establish the two-dimensional planar hydrodynamic control equations for the target sea area. The control equations include the hydrodynamic state variables and horizontal eddy viscosity coefficients to be solved.

[0043] Specifically, step S201 above includes: Step S2011: Based on the law of conservation of mass, establish a continuity equation describing the relationship between the rate of change of water level and the net flow in the horizontal direction; Step S2012: Based on the law of conservation of momentum, establish the first momentum balance equation in the first horizontal direction; Step S2013: Based on the law of conservation of momentum, establish a second momentum balance equation in the second horizontal direction; Among them, the first horizontal direction and the second horizontal direction are two mutually orthogonal horizontal directions, and both the first and second momentum balance equations include the horizontal eddy viscosity coefficient.

[0044] Specifically, the first momentum balance equation includes the horizontal eddy viscosity coefficient in the first horizontal direction, and the second momentum balance equation includes the horizontal eddy viscosity coefficient in the second horizontal direction.

[0045] In one alternative implementation, the first horizontal direction is the x-direction, and the second horizontal direction is the y-direction, with the two directions being perpendicular to each other.

[0046] In one optional implementation, the established two-dimensional planar hydrodynamic control equations are as follows:

[0047] Where t represents time, and x and y represent the right-handed Cartesian coordinate system. The water level is represented by the height of the water surface relative to the undisturbed water surface, where h represents the still water depth and H represents the total water depth. H = , The vertical average velocity represents the flow velocity in the x and y directions, g is the gravitational acceleration, f is the Coriolis force parameter, and u is the Earth's rotational angular velocity and the latitude of the calculated sea area. and Let C be the acceleration caused by the Earth's rotation, C be the Chezy coefficient, and n be the Manning coefficient used in the model calculations. and is the horizontal eddy viscosity coefficient function in the x and y directions.

[0048] Step S202: Construct a neural network with spatiotemporal coordinates as input and hydrodynamic state variables as output.

[0049] In some alternative implementations, the neural network employs Physical Information Neural Networks (PINNs), with output nodes representing hydrodynamic state variables, including relative water surface height. Vertical average velocity in the first horizontal direction and the vertical average velocity in the second horizontal direction The first and second horizontal directions are two mutually orthogonal horizontal directions. PINNs are built on deep feedforward neural networks, which consist of a series of nonlinear activation functions. These activation functions are ultimately combined into an output function, which can approximate any function in nonlinear function optimization.

[0050] Construct the neural network output function for three hydrodynamic state variables:

[0051]

[0052]

[0053] in and These represent the vertical average flow velocity in the first horizontal direction (x-direction) and the second horizontal direction (y-direction) output by the neural network, respectively; x and y represent spatial locations, and t represents time. It is a set of weights for the activation function in a neural network.

[0054] Step S203: The two-dimensional hydrodynamic control equations are used as physical constraints and fused with the measured data of the target sea area to construct an objective function for training the neural network.

[0055] Specifically, step S203 above includes: Step S2031: Transform the governing equations into the corresponding physical constraint residuals.

[0056] In some optional implementations, step S2031 above includes: Step a1: Based on the continuity equation in the governing equations, construct the first physical constraint residual term to measure the deviation from mass conservation.

[0057] Step a2: Based on the first momentum balance equation in the governing equations, construct the second physical constraint residual term to measure the deviation of momentum conservation in the first horizontal direction:

[0058] Step a3: Based on the second momentum balance equation in the governing equations, construct the third physical constraint residual term to measure the deviation of momentum conservation in the second horizontal direction.

[0059] in, and Let be the horizontal eddy viscosity coefficients in the x and y directions to be determined.

[0060] The first, second, and third physical constraint residuals mentioned above together constitute the physical constraint residuals. The second and third physical constraint residuals both include the horizontal eddy viscosity coefficient.

[0061] Step S2032: Calculate the data fitting residual term between the neural network output and the measured data.

[0062] In some optional implementations, step S2032 above includes: Step b1: Obtain measured data of the target sea area, including measured water level data and measured current velocity data.

[0063] Optionally, tidal data such as temperature and salinity of the target sea area can also be collected. Furthermore, the sea boundaries of the target sea area need to be determined.

[0064] Step b2: Based on the deviation between the relative water level height output by the neural network and the measured water level data, construct the first data fitting residual term: -

[0065] Step b3: Based on the deviation between the vertical average velocity in the first horizontal direction output by the neural network and the corresponding directional component in the measured velocity data, construct the second data fitting residual term:

[0066] Step b4: Based on the deviation between the vertical average velocity in the second horizontal direction output by the neural network and the corresponding directional component in the measured velocity data, construct the third data fitting residual term:

[0067] in, , , These are the measured water level data (i.e., relative water surface height), the measured vertical average flow velocity in the first horizontal direction, and the measured vertical average flow velocity in the second horizontal direction. The data fitting residuals of the first, second, and third data fitting terms together constitute the data fitting residual term.

[0068] Step S2033: Combine the physical constraint residuals with the data fitting residuals to construct the objective function:

[0069] Where ||·||² represents the L2 norm of the vector. This step can use classic gradient descent methods to solve the objective function until the optimal neural network parameters are found, such that the neural network output satisfies the governing equations as closely as possible and approximates the observed data. After optimization, the optimal solution is found, which represents the parameters of the equation. and .

[0070] Step S204: By optimizing the objective function, the optimal parameters of the neural network and the horizontal eddy viscosity coefficient in the control equation are solved to obtain the trained neural network as a prediction model.

[0071] Specifically, step S204 above includes: Step S2041: Optimize the objective function and simultaneously determine the value of the horizontal eddy viscosity coefficient and the initial parameters of the neural network. The initial parameters include the weight parameters of the neural network activation function. Step S2042: Substitute the determined value of the horizontal eddy viscosity coefficient into the physical constraint residual term:

[0072] It is evident that the closer the values ​​of the three residuals are to zero simultaneously, the closer the approximate solution of PINNs is to the true solution.

[0073] Step S2043: Using the weight parameters as optimization variables, optimize the weight parameters by minimizing the physical constraint residual term after substituting the horizontal eddy viscosity coefficient until the convergence condition is met. The weight parameters obtained at this time are the optimal weight parameters of the neural network activation function, thus obtaining the optimal parameters of the neural network. The neural network corresponding to the optimal parameters is used as the prediction model.

[0074] Specifically, by adjusting the weights To reduce the value of the residuals, the output function of the neural network is made to approximate the governing equations. Here, a gradient algorithm suitable for convex optimization is used, with the basic form as follows:

[0075] in The residual function in step S2042, The Adam algorithm employs an adaptive learning rate to improve learning efficiency and introduces momentum to enhance algorithm stability, making it more suitable for complex non-convex optimization problems. If local convergence issues occur, global optimization algorithms such as Genetic Algorithm (GA) and Particle Swarm Optimization (PSO) can be used; however, these methods are inefficient and cannot obtain water surface line results quickly. After residual convergence, the neural network's output function represents the three unknowns in the hydrodynamic equations relative to the water surface height. Vertical average velocity in the x-direction and the vertical average velocity in the y direction .

[0076] Step S205: Input the spatiotemporal coordinates of the floating target position at sea into the prediction model to obtain the predicted values ​​of the hydrodynamic state variables.

[0077] Step S206: Generate control commands for adjusting the motion attitude of the floating body based on the predicted values.

[0078] Specifically, the predicted values ​​are uploaded to the float controller to provide a reference for the adaptive adjustment of the float's motion attitude.

[0079] The method for adjusting the motion attitude of a floating body at sea provided in this embodiment utilizes a two-dimensional hydrodynamic model of the ocean plane as a physical element, adding strong constraints to the calibration process of eddy viscosity coefficients in both horizontal directions. This establishes a neural network model constrained by the physical information of the two-dimensional hydrodynamic model of the ocean plane. Data directly drives the model to predict surface current velocity, thereby predicting the motion trend of the floating body and adjusting its motion attitude to achieve adaptive adjustment. The advantage of this method is that by using the two-dimensional hydrodynamic model of the ocean plane to establish physical constraints in the parameter inversion process, it obtains eddy viscosity coefficients in both horizontal directions that conform to the ocean dynamic process, thus accurately predicting the ocean dynamic process and achieving adaptive adjustment of the motion attitude of the floating body at sea.

[0080] This embodiment also provides a marine floating body motion attitude adjustment device, which is used to implement the above embodiments and preferred embodiments, and will not be repeated as already described. As used below, the term "module" can be a combination of software and / or hardware that implements a predetermined function. Although the device described in the following embodiments is preferably implemented in software, hardware implementation, or a combination of software and hardware, is also possible and contemplated.

[0081] This embodiment provides a device for adjusting the motion attitude of a floating body at sea, such as... Figure 3 As shown, it includes: The control equation construction module 301 is used to establish the two-dimensional planar hydrodynamic control equations for the target sea area. The control equations include the hydrodynamic state variables and horizontal eddy viscosity coefficients to be solved. The neural network construction module 302 is used to construct a neural network that takes spatiotemporal coordinates as input and hydrodynamic state variables as output. The training target determination module 303 is used to integrate the two-dimensional hydrodynamic control equations as physical constraints with the measured data of the target sea area to construct the target function for training the neural network. The parameter optimization module 304 is used to solve for the optimal parameters of the neural network and the horizontal eddy viscosity coefficient in the control equation by optimizing the objective function, so as to obtain the trained neural network as a prediction model. The variable prediction module 305 is used to input the spatiotemporal coordinates of the floating target position at sea into the prediction model to obtain the predicted values ​​of the hydrodynamic state variables. The instruction adjustment module 306 is used to generate control instructions for adjusting the motion attitude of the floating body based on the predicted value.

[0082] The floating body motion attitude adjustment device provided in this embodiment of the invention can execute the floating body motion attitude adjustment method provided in any embodiment of the invention, and has the corresponding functional modules and beneficial effects for executing the method. Further functional descriptions of the above modules and units are the same as in the corresponding embodiments described above, and will not be repeated here.

[0083] Figure 4 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present invention.

[0084] The following is a detailed reference. Figure 4 This diagram illustrates a structural schematic suitable for implementing an electronic device according to embodiments of the present invention. The electronic device may include a processor (e.g., a central processing unit, graphics processor, etc.) 401, which can perform various appropriate actions and processes according to a program stored in read-only memory (ROM) 402 or a program loaded from memory 408 into random access memory (RAM) 403. The RAM 403 also stores various programs and data required for the operation of the electronic device. The processor 401, ROM 402, and RAM 403 are interconnected via a bus 404. An input / output (I / O) interface 405 is also connected to the bus 404.

[0085] Typically, the following devices can be connected to I / O interface 405: input devices 406 including, for example, touchscreens, touchpads, keyboards, mice, cameras, microphones, accelerometers, gyroscopes, etc.; output devices 407 including, for example, liquid crystal displays (LCDs), speakers, vibrators, etc.; memory devices 408 including, for example, magnetic tapes, hard disks, etc.; and communication devices 409. Communication device 409 allows electronic devices to communicate wirelessly or wiredly with other devices to exchange data. Although Figure 4Electronic devices with various devices are shown, but it should be understood that it is not required to implement or have all of the devices shown, and more or fewer devices may be implemented or have instead.

[0086] In particular, according to embodiments of the present invention, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments of the present invention include a computer program product comprising a computer program carried on a non-transitory computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via a communication device 409, or installed from a memory 408, or installed from a ROM 402. When the computer program is executed by the processor 401, it performs the functions defined in the method for adjusting the motion attitude of a marine floating body according to embodiments of the present invention.

[0087] Figure 4 The electronic device shown is merely an example and should not be construed as limiting the functionality and scope of use of the embodiments of the present invention.

[0088] This invention also provides a computer-readable storage medium. The methods described above according to embodiments of the invention can be implemented in hardware or firmware, or implemented as computer code that can be recorded on a storage medium, or implemented as computer code downloaded via a network and originally stored on a remote storage medium or a non-transitory machine-readable storage medium and then stored on a local storage medium. Thus, the methods described herein can be processed by software stored on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. The storage medium can be a magnetic disk, optical disk, read-only memory, random access memory, flash memory, hard disk, or solid-state drive, etc.; further, the storage medium can also include combinations of the above types of memory. It is understood that computers, processors, microprocessor controllers, or programmable hardware include storage components capable of storing or receiving software or computer code. When the software or computer code is accessed and executed by the computer, processor, or hardware, the method for adjusting the motion attitude of a floating body at sea as shown in the above embodiments is implemented.

[0089] A portion of this invention can be applied as a computer program product, such as computer program instructions, which, when executed by a computer, can invoke or provide the methods and / or technical solutions according to the invention through the operation of the computer. Those skilled in the art will understand that the forms in which computer program instructions exist in a computer-readable medium include, but are not limited to, source files, executable files, installation package files, etc. Correspondingly, the ways in which computer program instructions are executed by a computer include, but are not limited to: the computer directly executing the instructions, or the computer compiling the instructions and then executing the corresponding compiled program, or the computer reading and executing the instructions, or the computer reading and installing the instructions and then executing the corresponding installed program. Here, the computer-readable medium can be any available computer-readable storage medium or communication medium accessible to a computer.

[0090] Although embodiments of the invention have been described in conjunction with the accompanying drawings, those skilled in the art can make various modifications and variations without departing from the spirit and scope of the invention, and such modifications and variations all fall within the scope defined by the appended claims.

Claims

1. A method of adjusting the attitude of a marine floating body, characterized in that, The method includes: Establish two-dimensional hydrodynamic control equations for the target sea area, which include the hydrodynamic state variables and horizontal eddy viscosity coefficients to be solved. Construct a neural network that takes spatiotemporal coordinates as input and hydrodynamic state variables as output; The planar two-dimensional hydrodynamic control equations are used as physical constraints and fused with the measured data of the target sea area to construct an objective function for training the neural network. By optimizing the objective function, the optimal parameters of the neural network and the horizontal eddy viscosity coefficient in the control equation are solved, and the trained neural network is obtained as a prediction model. The spatiotemporal coordinates of the floating target's location at sea are input into the prediction model to obtain the predicted values ​​of the hydrodynamic state variables. Control commands for adjusting the motion attitude of the floating body are generated based on the predicted values.

2. The method for adjusting the motion attitude of a floating body at sea according to claim 1, characterized in that, The steps for establishing the two-dimensional hydrodynamic control equations for the target sea area include: Based on the law of conservation of mass, a continuity equation is established to describe the relationship between the rate of change of water level and the net flow in the horizontal direction. Based on the law of conservation of momentum, a first momentum balance equation is established in the first horizontal direction; Based on the law of conservation of momentum, a second momentum balance equation is established in the second horizontal direction; The first horizontal direction and the second horizontal direction are two mutually orthogonal horizontal directions, and the first and second momentum balance equations both include the horizontal eddy viscosity coefficient.

3. The method for adjusting the motion attitude of a floating body at sea according to claim 1, characterized in that, The neural network adopts a physical information neural network, and the output node is the hydrodynamic state variable. The hydrodynamic state variable includes the relative water surface height, the vertical average flow velocity in the first horizontal direction, and the vertical average flow velocity in the second horizontal direction. The first horizontal direction and the second horizontal direction are two mutually orthogonal horizontal directions.

4. The method for adjusting the motion attitude of a floating body at sea according to claim 2, characterized in that, The step of fusing the two-dimensional hydrodynamic control equations as physical constraints with measured data from the target sea area to construct an objective function for training the neural network includes: The governing equations are then transformed into corresponding physical constraint residuals. Calculate the data fitting residual term between the output of the neural network and the measured data; The objective function is constructed by combining the physical constraint residual term with the data fitting residual term.

5. The method for adjusting the motion attitude of a floating body at sea according to claim 4, characterized in that, The step of converting the governing equations into corresponding physical constraint residuals includes: Based on the continuity equation in the governing equations, a first physical constraint residual term is constructed to measure the deviation from the mass conservation. Based on the first momentum balance equation in the control equation, a second physical constraint residual term is constructed to measure the deviation of momentum conservation in the first horizontal direction. Based on the second momentum balance equation in the governing equations, a third physical constraint residual term is constructed to measure the deviation of momentum conservation in the second horizontal direction. The first, second, and third physical constraint residual terms together constitute the physical constraint residual term, and the second and third physical constraint residual terms both include the horizontal eddy viscosity coefficient.

6. The method for adjusting the motion attitude of a floating body at sea according to claim 4, characterized in that, The step of calculating the data fitting residual term between the neural network output and the measured data includes: Acquire measured data of the target sea area, including measured water level data and measured current velocity data; Based on the deviation between the relative water surface height output by the neural network and the measured water level data, a first data fitting residual term is constructed; Based on the deviation between the vertical average flow velocity in the first horizontal direction output by the neural network and the corresponding directional component in the measured flow velocity data, a second data fitting residual term is constructed. Based on the deviation between the vertical average flow velocity in the second horizontal direction output by the neural network and the corresponding directional component in the measured flow velocity data, a third data fitting residual term is constructed. The first, second, and third data fitting residual terms together constitute the data fitting residual term.

7. The method for adjusting the motion attitude of a floating body at sea according to claim 4, characterized in that, The step of optimizing the objective function, solving for the optimal parameters of the neural network and the horizontal eddy viscosity coefficient in the control equation, and obtaining the trained neural network as a prediction model includes: The objective function is optimized, and the value of the horizontal eddy viscosity coefficient and the initial parameters of the neural network are determined simultaneously. The initial parameters include the weight parameters of the neural network activation function. Substitute the determined value of the horizontal eddy viscosity coefficient into the physical constraint residual term; Using the weight parameters as optimization variables, the weight parameters are optimized by minimizing the physical constraint residual term after substituting the horizontal eddy viscosity coefficient until the convergence condition is met. The weight parameters obtained at this time are the optimal weight parameters of the neural network activation function, thereby obtaining the optimal parameters of the neural network. The neural network corresponding to the optimal parameters is used as the prediction model.

8. A device for adjusting the motion attitude of a marine floating body, characterized in that, The device includes: The control equation construction module is used to establish the two-dimensional planar hydrodynamic control equations for the target sea area. The control equations include the hydrodynamic state variables and horizontal eddy viscosity coefficients to be solved. The neural network building module is used to construct neural networks that take spatiotemporal coordinates as input and hydrodynamic state variables as output. The training target determination module is used to integrate the two-dimensional hydrodynamic control equations as physical constraints with the measured data of the target sea area to construct an objective function for training the neural network. The parameter optimization module is used to optimize the objective function, solve for the optimal parameters of the neural network and the horizontal eddy viscosity coefficient in the control equation, and obtain the trained neural network as a prediction model. The variable prediction module is used to input the spatiotemporal coordinates of the floating target position at sea into the prediction model to obtain the predicted values ​​of the hydrodynamic state variables. The command adjustment module is used to generate control commands for adjusting the motion attitude of the floating body based on the predicted values.

9. An electronic device, characterized in that, include: The system includes a memory and a processor, which are interconnected. The memory stores computer instructions, and the processor executes the computer instructions to perform the method for adjusting the motion attitude of a floating body at sea as described in any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions for causing the computer to execute the method for adjusting the motion attitude of a floating body at sea as described in any one of claims 1 to 7.