Self-adaptive rapid sea wave height simulation calculation method, equipment and medium
By adopting an adaptive fast wave height simulation calculation method, based on wave type and parameter correction grid matrix, the problems of low computational efficiency and insufficient accuracy in existing technologies are solved, and efficient and accurate wave height simulation is achieved.
Patent Information
- Application Number
- CN202511855824.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-10
- Publication Date
- 2026-03-03
AI Technical Summary
Existing methods for simulating ocean wave height are computationally inefficient and produce inaccurate results. In particular, they struggle to accurately identify the dominant frequency characteristics of the wave spectrum under different sea conditions, which affects the accuracy of the simulation results.
An adaptive fast wave height simulation method is adopted. By obtaining wave type and parameters, the mesh matrix is corrected based on different processing strategies, and mesh assignment and rotation are performed to achieve adaptive wave height simulation.
This improves the accuracy and efficiency of ocean wave height simulation results, meeting the needs of real-time, high-precision simulation.
Smart Images

Figure CN121598633A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of ocean wave simulation calculation technology, and in particular to an adaptive fast ocean wave height simulation calculation method, device and medium. Background Technology
[0002] In the field of digital simulation for marine engineering, wave simulation is one of the key technologies for realizing numerical calculations of ship performance and the generation of virtual ocean animations. Its foundation lies in the accurate modeling of wave waveforms and their changing characteristics. Currently, the widely adopted wave height time-domain superposition method first extracts parameters such as amplitude, frequency, and propagation direction of several regular waves from the wave spectrum, and then linearly superimposes them in the time domain to form irregular wave heights. This method has a clear physical concept, is simple to implement, and can effectively reduce simulation errors caused by modeling deviations in the wave model. The more regular waves superimposed, the more realistic wave details can be obtained.
[0003] However, the time-domain superposition method requires summing a large number of regular waves in the time domain, and the computational load increases significantly with the number of regular waves, making it difficult to meet the requirements of real-time fine simulation. At the same time, the bandwidth and peak position of the wave spectrum vary under different sea states. If the dominant frequency characteristics are not accurately identified, the accuracy of the simulation results will be directly affected. Summary of the Invention
[0004] To address the aforementioned problems and technical requirements, the applicant proposes an adaptive and rapid method, device, and medium for simulating ocean wave height. This method aims to solve the problems of low simulation efficiency and low accuracy of simulation results in existing technologies, thereby achieving adaptive and rapid ocean wave height simulation and improving the accuracy of the simulation results.
[0005] This application provides an adaptive fast simulation calculation method for ocean wave height, the method comprising: Obtain the wave type and wave parameters corresponding to the wave to be simulated; At time t, if the wave type is a regular wave, the preset initial grid matrix is corrected based on the wave parameters and the preset first processing strategy, and a value is assigned to the corrected grid matrix; if the wave type is an irregular wave, the initial grid matrix is corrected based on the wave parameters and the preset second processing strategy, and a value is assigned to the corrected grid matrix. Based on the assigned grid matrix, calculate the wave height matrix at time t; Perform the following wave height processing procedure on the wave height matrix: The wave height matrix is repeatedly expanded by tiling along its side length to obtain the target wave height matrix corresponding to the preset range; the target wave height matrix is rotated and resampled based on the wave parameters to obtain the final wave height matrix corresponding to time t. If t is less than the preset total duration T, calculate t+dt and execute the step of obtaining the wave parameters of the wave type corresponding to the wave to be simulated, where dt represents the simulation time interval.
[0006] According to the adaptive fast ocean wave height simulation calculation method provided in the embodiments of this application, the wave parameters include: first wave parameters corresponding to regular waves and second wave parameters corresponding to irregular waves; The first wave parameters include: first wave height, first circular frequency, and first phase; The second wave parameters include: wave spectrum, the maximum frequency corresponding to the wave spectrum, and the minimum frequency corresponding to the wave spectrum; Based on the wave parameters and a preset first processing strategy, the preset initial grid matrix is corrected, and values are assigned to the corrected grid matrix, including: The initial grid matrix is corrected based on the first circular frequency, and the corrected grid matrix is assigned values using the first wave height, the first circular frequency, and the first phase. The initial grid matrix is corrected based on the wave parameters and a preset second processing strategy, and values are assigned to the corrected grid matrix, including: The initial grid matrix is corrected based on the wave spectrum, maximum frequency, and minimum frequency, and the corrected grid matrix is then assigned values using the wave spectrum, maximum frequency, and minimum frequency.
[0007] According to the adaptive fast ocean wave height simulation calculation method provided in the embodiments of this application, the initial grid matrix is a square matrix composed of N*N grid cells, wherein the grid cells are square. The initial grid matrix is corrected based on the first circular frequency, including: Input the first circular frequency into the preset grid length calculation formula to obtain the grid length of the grid cell in the grid matrix; The formula for calculating the grid length includes: ; in, Indicates the grid length of the grid cell. Represents gravitational acceleration, and N represents the number of rows and columns of the initial grid matrix. Indicates the first angular frequency; Based on the calculated grid length and the number of rows and columns of the initial grid matrix, the corrected grid matrix is obtained.
[0008] According to the adaptive fast wave height simulation calculation method provided in the embodiments of this application, the first wave height, the first circular frequency, and the first phase are used to assign values to the corrected mesh matrix, including: Input the first circular frequency, the first wave height and the first phase into the preset first element calculation formula to obtain the first matrix element value corresponding to the first preset position; The formula for calculating the first element includes: ; in, This represents the value of the first matrix element in the m-th row and n-th column of the grid matrix. Indicates the first wave high. Indicates the first phase. The first circular frequency is represented by N, which represents the number of rows and columns of the initial grid matrix. Based on the preset first element symmetry relationship, a first symmetric position that is symmetrical to the first preset position is determined, and the conjugate value of the first matrix element value is assigned to the first symmetric position to obtain the assigned grid matrix.
[0009] According to the adaptive fast ocean wave height simulation calculation method provided in the embodiments of this application, the initial grid matrix is a square matrix composed of N*N grid cells, wherein the grid cells are square. The initial grid matrix is corrected based on the wave spectrum, maximum frequency, and minimum frequency, including: Based on N and the minimum frequency, the ratio between the physical space length corresponding to the initial grid matrix and the total length of the ship is determined; The N is updated based on preset grid creation conditions, wherein the grid creation conditions are obtained based on multiple relationships, maximum frequency, and N; The grid length of the grid cells in the grid matrix is calculated based on the updated N; Based on the calculated grid length and the updated N, the corrected grid matrix is obtained.
[0010] According to the adaptive fast ocean wave height simulation calculation method provided in the embodiments of this application, irregular waves include: long-peaked irregular waves; The corrected grid matrix is assigned values using the wave spectrum, maximum frequency, and minimum frequency, including: The wave spectrum is sampled for the first time, and the second wave height at different wave numbers corresponding to the first sampling results is calculated. Input the second wave height into the preset second element calculation formula to obtain the second matrix element value corresponding to the second preset position; The formula for calculating the second element includes: ; in, This represents the value of the second matrix element in the m-th row and n-th column of the grid matrix. This represents the second wave height corresponding to the m-th row and n-th column in the grid matrix, where N represents the number of rows and columns in the initial grid matrix. This represents the randomly generated second phase corresponding to the m-th row and n-th column of the grid matrix. This represents the second circular frequency corresponding to the m-th row and n-th column of the grid matrix; Based on the preset second element symmetry relationship, a second symmetric position that is symmetrical to the second preset position is determined, and the conjugate value of the second matrix element value is assigned to the second symmetric position to obtain the assigned grid matrix.
[0011] According to the adaptive fast ocean wave height simulation calculation method provided in the embodiments of this application, irregular waves include: short-peak irregular waves; The corrected grid matrix is assigned values using the wave spectrum, maximum frequency, and minimum frequency, including: The wave spectrum is subjected to a second sampling process, and the third wave height at different wave numbers corresponding to the second sampling results is calculated. Input the third wave height into the preset third element calculation formula to obtain the third matrix element value corresponding to the third preset position; The formula for calculating the third element includes: ; in, This represents the value of the third matrix element in the m-th row and n-th column of the grid matrix. This represents the height of the third wave corresponding to the m-th row and n-th column in the grid matrix. This represents the third phase corresponding to the m-th row and n-th column in the grid matrix. This represents the third circular frequency corresponding to the m-th row and n-th column in the grid matrix. Based on the preset symmetry relationship of the third element, the third symmetric position that is symmetrical to the third preset position is determined, and the conjugate value of the third matrix element value is assigned to the third symmetric position to obtain the assigned grid matrix.
[0012] According to the adaptive fast wave height simulation calculation method provided in the embodiments of this application, the wave height matrix at time t is calculated based on the assigned grid matrix, including: ; in, This represents the wave height matrix corresponding to the grid matrix in the m-th row and n-th column. Let i represent the matrix element value corresponding to different waves in row p and column q, where i represents the imaginary unit and the square of i is -1.
[0013] This application also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, it implements the steps of the adaptive fast ocean wave height simulation calculation method as described above.
[0014] This application also provides a non-transitory computer-readable storage medium storing a computer program thereon, which, when executed by a processor, implements the steps of the adaptive fast ocean wave height simulation calculation method as described above.
[0015] The adaptive and rapid wave height simulation calculation method, device, and medium provided in this application obtain the wave type and wave parameters corresponding to the wave to be simulated; at time t, if the wave type is a regular wave, a preset initial grid matrix is corrected based on the wave parameters and a preset first processing strategy, and a value is assigned to the corrected grid matrix; if the wave type is an irregular wave, the initial grid matrix is corrected based on the wave parameters and a preset second processing strategy, and a value is assigned to the corrected grid matrix. This application uses different processing strategies to correct the grid matrix based on different wave types, and assigns values to the grid matrix based on the wave parameters; then, the wave height matrix corresponding to time t is calculated for the assigned grid matrix; finally, a wave height processing process is performed on the wave height matrix: the wave height matrix is repeatedly tiled and expanded along its side length direction to obtain the target wave height matrix corresponding to a preset range; the target wave height matrix is rotated and resampled based on the wave parameters to obtain the final wave height matrix corresponding to time t; when t is determined to be less than the preset total duration T, t+dt is calculated, and the above process is iteratively executed to achieve adaptive and rapid completion of wave height simulation, and improve the accuracy of wave height simulation results. Attached Figure Description
[0016] To more clearly illustrate the technical solutions in the embodiments of this application 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 the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0017] Figure 1 This is one of the flowcharts illustrating the adaptive fast ocean wave height simulation calculation provided in the embodiments of this application; Figure 2 This is a schematic diagram of wave spectrum energy threshold division provided in an embodiment of this application; Figure 3 This is the second flowchart illustrating the adaptive fast ocean wave height simulation calculation provided in this application embodiment; Figure 4 This is the third flowchart illustrating the adaptive fast ocean wave height simulation calculation provided in this application embodiment; Figure 5 This is a schematic diagram of the distribution of elements in a regular wave grid matrix provided in an embodiment of this application; Figure 6This is the fourth flowchart illustrating the adaptive fast ocean wave height simulation calculation provided in this application embodiment; Figure 7 This is the fifth flowchart illustrating the adaptive fast ocean wave height simulation calculation provided in the embodiments of this application; Figure 8 This is a schematic diagram of the distribution of elements in a long-peaked irregular wave grid matrix provided in an embodiment of this application; Figure 9 This is the sixth flowchart illustrating the adaptive fast ocean wave height simulation calculation provided in this application embodiment; Figure 10 This is a schematic diagram of the distribution of elements in the short-peak irregular wave grid matrix provided in an embodiment of this application; Figure 11 This is the seventh flowchart illustrating the adaptive fast ocean wave height simulation calculation provided in this application embodiment; Figure 12 This is a schematic diagram of the tiled high-wave matrix provided in an embodiment of this application; Figure 13 This is a schematic diagram of the structure of the electronic device provided in the embodiments of this application. Detailed Implementation
[0018] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this invention.
[0019] This application provides an adaptive and fast method for simulating ocean wave height. This method can be applied to smart terminals and servers. This application uses the application of this method in a server as an example for illustration, and some other descriptions in the embodiments are illustrative and not intended to limit the scope of protection of this application, and will not be described in detail thereafter. The specific implementation of the method is as follows... Figure 1 As shown: Step 101: Obtain the wave type and wave parameters corresponding to the wave to be simulated.
[0020] Step 102: At time t, if the wave type is a regular wave, modify the preset initial grid matrix based on the wave parameters and the preset first processing strategy, and assign values to the modified grid matrix; if the wave type is an irregular wave, modify the initial grid matrix based on the wave parameters and the preset second processing strategy, and assign values to the modified grid matrix.
[0021] The initial grid matrix is a square matrix consisting of N*N grid cells, where each grid cell is a square.
[0022] Step 103: Calculate the wave height matrix at time t based on the assigned grid matrix.
[0023] Step 104: Perform the following wave height processing on the wave height matrix: repeatedly tile and expand the wave height matrix along its side length to obtain the target wave height matrix corresponding to the preset range; rotate and resample the target wave height matrix based on the wave parameters to obtain the final wave height matrix corresponding to time t.
[0024] Specifically, the target wave height matrix is rotated and resampled based on the wave propagation direction to obtain the final wave height matrix corresponding to different wave propagation directions at time t.
[0025] Step 105: If t is less than the preset total duration T, calculate t+dt and execute the step of obtaining the wave parameters of the wave type corresponding to the wave to be simulated.
[0026] Where dt represents the simulation time interval.
[0027] Specifically, simulation parameters are obtained in advance, including: total simulation duration (preset total duration T), simulation time interval, initial mesh matrix, and current simulation time point t, etc.
[0028] The adaptive and fast wave height simulation calculation method provided in this application obtains the wave type and wave parameters corresponding to the wave to be simulated; at time t, if the wave type is a regular wave, the preset initial grid matrix is corrected based on the wave parameters and a preset first processing strategy, and a value is assigned to the corrected grid matrix; if the wave type is an irregular wave, the initial grid matrix is corrected based on the wave parameters and a preset second processing strategy, and a value is assigned to the corrected grid matrix. This application uses different processing strategies to correct the grid matrix based on different wave types, and assigns values to the grid matrix based on the wave parameters; then, the wave height matrix corresponding to time t is calculated for the assigned grid matrix; finally, the wave height matrix is processed: the wave height matrix is repeatedly tiled and expanded along its side length to obtain the target wave height matrix corresponding to a preset range; the target wave height matrix is rotated and resampled based on the wave parameters to obtain the final wave height matrix corresponding to time t; when t is determined to be less than the preset total duration T, t+dt is calculated, and the above process is iteratively executed to achieve adaptive and fast completion of wave height simulation, and improve the accuracy of wave height simulation results.
[0029] In one specific embodiment, the wave parameters include: a first wave parameter corresponding to a regular wave and a second wave parameter corresponding to an irregular wave.
[0030] The first wave parameters include: first wave height, first circular frequency, and first phase.
[0031] The second wave parameters include: wave spectrum, maximum frequency corresponding to the wave spectrum, minimum frequency corresponding to the wave spectrum, second wave height, second circular frequency, second phase, and wave direction of the ship.
[0032] Among them, through Figure 2 This diagram illustrates the energy threshold division of the ocean wave spectrum to obtain the maximum frequency of the ocean wave spectrum at the threshold boundary. and minimum frequency .
[0033] Where S(f) represents the wave spectrum and Frequency represents the frequency.
[0034] In one specific embodiment, the specific implementation of correcting the preset initial grid matrix based on wave parameters and a preset first processing strategy, and assigning values to the corrected grid matrix, includes: The initial grid matrix is corrected based on the first circular frequency, and the corrected grid matrix is assigned values using the first wave height, the first circular frequency, and the first phase.
[0035] In one specific embodiment, the specific implementation of correcting the initial grid matrix based on wave parameters and a preset second processing strategy, and assigning values to the corrected grid matrix, includes: The initial grid matrix is corrected based on the wave spectrum, maximum frequency, and minimum frequency, and then the corrected grid matrix is assigned values using the wave spectrum, maximum frequency, and minimum frequency.
[0036] In one specific embodiment, the specific implementation of correcting the initial grid matrix based on the first circular frequency is as follows: Figure 3 As shown: Step 301: Input the first circular frequency into the preset grid length calculation formula to obtain the grid length of the grid cell in the grid matrix.
[0037] Step 302: Based on the calculated grid length and the number of rows and columns of the initial grid matrix, the corrected grid matrix is obtained.
[0038] The formula for calculating the grid length is shown in formula (1): ……………………………………(1) in, Indicates the grid length of the grid cell. Represents gravitational acceleration, and N represents the number of rows and columns of the initial grid matrix. This represents the first angular frequency.
[0039] In one specific embodiment, the specific implementation of assigning values to the corrected grid matrix using the first wave height, the first circular frequency, and the first phase is as follows: Figure 4 As shown: Step 401: Input the first circular frequency, the first wave height, and the first phase into the preset first element calculation formula to obtain the first matrix element value corresponding to the first preset position.
[0040] Step 402: Based on the preset first element symmetry relationship, determine the first symmetric position that is symmetrical to the first preset position, and assign the conjugate value of the first matrix element value to the first symmetric position to obtain the assigned grid matrix.
[0041] The formula for calculating the first element is shown in formula (2): ………………(2) in, This represents the value of the first matrix element in the m-th row and n-th column of the grid matrix. Indicates the first wave high. Indicates the first phase. The first circular frequency is represented by N, and N represents the number of rows and columns of the initial grid matrix.
[0042] Specifically, for the first preset position of the regular wave, which is the position in the 1st row and 0th column of the grid matrix, the symmetry relationship of the first element can be found in [reference needed]. Figure 5 The diagram illustrates the correspondence between elements in a matrix.
[0043] Among them, Figure 5 middle This represents the specific symbolic value of the element in the first matrix. The specific schematic value representing the conjugate value of the element value of the first matrix.
[0044] Specifically, the conjugate value of the element value of the first matrix is calculated using formula (3).
[0045] ………………(3) in, This represents the conjugate value of the element value of the first matrix.
[0046] In one specific embodiment, the specific implementation of correcting the initial grid matrix based on the wave spectrum, maximum frequency, and minimum frequency is as follows: Figure 6 As shown: Step 601: Based on N and the minimum frequency, determine the ratio between the physical space length corresponding to the initial grid matrix and the total length of the ship.
[0047] Step 602: Update N based on the preset grid creation conditions.
[0048] Step 603: Calculate the grid length of the grid cells in the grid matrix based on the updated N.
[0049] Step 604: Based on the calculated grid length and the updated N, obtain the corrected grid matrix.
[0050] The grid creation conditions are based on multiple relationships, maximum frequency, and N.
[0051] Specifically, N, minimum frequency, and total ship length are input into a preset multiple calculation formula to obtain the multiple relationship.
[0052] The formula for calculating the multiple is shown in formula (4): …………………………(4) in, Indicates a multiple relationship. Indicates the minimum frequency. Indicates the total length of the ship.
[0053] Among them, in order to meet the maximum frequency The frequency requirement dictates that the calculated N must satisfy the mesh creation conditions, i.e., formula (5): …………………………(5) Specifically, the c obtained from formula (4) is substituted into formula (5) for verification. If the mesh creation conditions are not met, N is recalculated from the left term of formula (5), and the mesh length is obtained using the updated N, the second circular frequency and formula (1).
[0054] In one specific embodiment, the irregular wave includes: a long-peaked irregular wave.
[0055] In one specific embodiment, the specific implementation of assigning values to the corrected grid matrix using the wave spectrum, maximum frequency, and minimum frequency is as follows: Figure 7 As shown: Step 701: Perform a first sampling process on the wave spectrum and calculate the second wave height at different wave numbers corresponding to the first sampling results.
[0056] Step 702: Input the second wave height into the preset second element calculation formula to obtain the second matrix element value corresponding to the second preset position.
[0057] Step 703: Based on the preset second element symmetry relationship, determine the second symmetric position that is symmetric to the second preset position, and assign the conjugate value of the second matrix element value to the second symmetric position to obtain the assigned grid matrix.
[0058] The second wave height is the wave height corresponding to the regular wave.
[0059] The formula for calculating the second element is shown in formula (6): …(6) in, This represents the value of the second matrix element in the m-th row and n-th column of the grid matrix. This represents the second wave height corresponding to the m-th row and n-th column in the grid matrix, where N represents the number of rows and columns in the initial grid matrix. This represents the randomly generated second phase corresponding to the m-th row and n-th column of the grid matrix. This represents the second circular frequency corresponding to the m-th row and n-th column of the grid matrix.
[0060] in, .
[0061] in, .
[0062] in, .
[0063] in, .
[0064] Specifically, the first sampling process is shown in formula (7): ……………………(7) in, .
[0065] in, This indicates the first sampling result. The wave spectrum representing long-peaked irregular waves. This represents the wave spectral frequency corresponding to long-peaked irregular waves. This represents the wave number corresponding to the m-th row and n-th column of the grid matrix.
[0066] Specifically, the first sampling result is input into the preset first wave height calculation formula to obtain the second wave height.
[0067] The formula for calculating the first wave height is shown in formula (8): ………………(8) in, .
[0068] in, This represents the second wave height corresponding to the m-th row and n-th column of the grid matrix.
[0069] Specifically, the conjugate values of the elements of the second matrix are calculated using formula (9): …………(9) in, This represents the conjugate value of the element in the second matrix.
[0070] Specifically, for long-peaked irregular waves, the second preset position is the [missing information] position in the grid matrix. The symmetrical relationship between the second element at row 0 and column 0 can be found in [reference needed]. Figure 8 The diagram illustrates the correspondence between elements in a matrix.
[0071] Among them, Figure 8 middle , ..., This represents the specific symbolic value of the element in the second matrix. , ..., The specific schematic value representing the conjugate value of the element value of the second matrix.
[0072] Where j represents an element of the complex sequence.
[0073] In one specific embodiment, the irregular wave also includes: short-peak irregular wave.
[0074] In one specific embodiment, the specific implementation of assigning values to the corrected grid matrix using the wave spectrum, maximum frequency, and minimum frequency is as follows: Figure 9 As shown: Step 901: Perform a second sampling process on the wave spectrum and calculate the third wave height at different wave numbers corresponding to the second sampling results.
[0075] Step 902: Input the third wave height into the preset third element calculation formula to obtain the third matrix element value corresponding to the third preset position.
[0076] Step 903: Based on the preset symmetry relationship of the third element, determine the third symmetric position that is symmetric to the third preset position, and assign the conjugate value of the third matrix element value to the third symmetric position to obtain the assigned grid matrix.
[0077] The third wave height is the wave height corresponding to the regular wave.
[0078] The formula for calculating the third element is shown in formula (10): …(10) in, This represents the value of the third matrix element in the m-th row and n-th column of the grid matrix. This represents the height of the third wave corresponding to the m-th row and n-th column in the grid matrix. This represents the third phase corresponding to the m-th row and n-th column in the grid matrix. This represents the third circular frequency corresponding to the m-th row and n-th column in the grid matrix.
[0079] Specifically, the second sampling process is shown in formula (11): ………………(11) in, .
[0080] in, This indicates the second sampling result. This represents the extended wave spectrum obtained based on the wave spectrum of short-peak irregular waves. This represents the wave spectral frequency corresponding to short-peaked irregular waves. This represents the wave number corresponding to the m-th row and n-th column of the grid matrix.
[0081] in, .
[0082] in, Indicates a short-peaked irregular wave. This represents the wave spread function.
[0083] in, .
[0084] Here, 's' represents the variable value, which users can set according to their actual needs; this application does not impose any restrictions. This represents the wave direction angle corresponding to the m-th row and n-th column in the grid matrix. This represents the gamma function.
[0085] in, .
[0086] in, .
[0087] in, .
[0088] Specifically, the second sampling result is input into the preset second wave height calculation formula to obtain the third wave height.
[0089] The formula for calculating the second wave height is shown in formula (12): ………………(12) in, .
[0090] in, This represents the third wave height corresponding to the m-th row and n-th column of the grid matrix.
[0091] Specifically, for short-peak irregular waves, the third preset position is the... Line number The column positions and the symmetry of the third element can be found in [reference]. Figure 10 The diagram illustrates the correspondence between elements in a matrix.
[0092] Among them, Figure 10In the diagram, A, B, C, and D represent the specific values of the elements of the third matrix under short-peak irregular waves. , , and The specific symbolic value representing the conjugate value of the element of the third matrix is given by the subscript i, which represents the i-th element of the complex sequence, and the subscript j, which represents the j-th element of the complex sequence.
[0093] In one specific embodiment, the specific implementation of calculating the wave height matrix at time t based on the assigned grid matrix is shown in formula (13): …………(13) in, This represents the wave height matrix corresponding to the grid matrix in the m-th row and n-th column. Let i represent the matrix element value corresponding to different waves in row p and column q, where i represents the imaginary unit and the square of i is -1.
[0094] Specifically, such as Figure 11 The following illustrates the overall implementation process: Step 1101: Determine if the wave type is a regular wave. If yes, proceed to step 1102; otherwise, proceed to step 1103.
[0095] Step 1102: Calculate the grid length of the grid cell based on the preset grid matrix size N, and calculate the matrix element value at the first preset position in the grid matrix at time t, as well as the conjugate value at the first symmetric position.
[0096] Step 1103: Determine whether the irregular wave is a long-peak irregular wave. If yes, proceed to step 1104; otherwise, proceed to step 1105.
[0097] Step 1104: Calculate the first wave number. Based on the relationship between the first wave number and the first wave spectrum frequency, sample the wave spectrum and obtain the matrix element values at the second preset position and the conjugate values at the second symmetric position.
[0098] Step 1105: Calculate the second wave number. Based on the relationship between the second wave number and the frequency of the second wave spectrum, sample the wave spectrum and obtain the matrix element values at the third preset position and the conjugate value at the third symmetric position.
[0099] Step 1106: Calculate the wave height matrix using the inverse fast Fourier transform.
[0100] Step 1107: Determine if t is less than T. If yes, proceed to step 1001; otherwise, proceed to step 1008.
[0101] Step 1108: Confirm that the wave height simulation is complete.
[0102] Specifically, through Figure 12 A schematic diagram of the tiled high-wave matrix is provided.
[0103] in, Figure 12 In This represents the wave height matrix after tiling.
[0104] This application simulates the wave heights of regular waves, long-peak irregular waves, and short-peak irregular waves by adaptively identifying wave types and wave spectra. By constructing a two-dimensional spectrum, the wave heights are obtained in real time through inverse fast Fourier transform (IFFT), achieving rapid and accurate simulation of wave heights.
[0105] Figure 13 An example is a schematic diagram of the physical structure of an electronic device, such as... Figure 13 As shown, the electronic device may include a processor 1301, a communications interface 1302, a memory 1303, and a communication bus 1304. The processor 1301, communications interface 1302, and memory 1303 communicate with each other via the communication bus 1304. The processor 1301 can call logic instructions from the memory 1303 to execute an adaptive fast ocean wave height simulation calculation method.
[0106] Furthermore, the logical instructions in the aforementioned memory 1303 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, 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.
[0107] On the other hand, the present invention also provides a computer program product, the computer program product comprising a computer program stored on a non-transitory computer-readable storage medium, the computer program comprising program instructions, and when the program instructions are executed by a computer, the computer is able to execute the adaptive fast ocean wave height simulation calculation method provided by the above methods.
[0108] 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, is implemented to perform the adaptive fast ocean wave height simulation calculation method provided in the above embodiments.
[0109] 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.
[0110] 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.
[0111] Finally, it should be noted that the above descriptions are merely preferred embodiments of this application, and this application is not limited to the above embodiments. It is understood that other improvements and variations directly derived or conceived by those skilled in the art without departing from the spirit and concept of this application should be considered to be included within the protection scope of this application.
Claims
1. An adaptive and fast simulation calculation method for ocean wave height, characterized in that, The method includes: Obtain the wave type and wave parameters corresponding to the wave to be simulated; At time t, if the wave type is a regular wave, the preset initial grid matrix is corrected based on the wave parameters and the preset first processing strategy, and a value is assigned to the corrected grid matrix; if the wave type is an irregular wave, the initial grid matrix is corrected based on the wave parameters and the preset second processing strategy, and a value is assigned to the corrected grid matrix. Based on the assigned grid matrix, calculate the wave height matrix at time t; Perform the following wave height processing procedure on the wave height matrix: The wave height matrix is repeatedly expanded by tiling along its side length to obtain the target wave height matrix corresponding to the preset range; the target wave height matrix is rotated and resampled based on the wave parameters to obtain the final wave height matrix corresponding to time t. If t is less than the preset total duration T, calculate t+dt and execute the step of obtaining the wave parameters of the wave type corresponding to the wave to be simulated, where dt represents the simulation time interval.
2. The adaptive fast ocean wave height simulation calculation method according to claim 1, characterized in that, The wave parameters include: first wave parameters corresponding to regular waves and second wave parameters corresponding to irregular waves; The first wave parameters include: first wave height, first circular frequency, and first phase; The second wave parameters include: wave spectrum, the maximum frequency corresponding to the wave spectrum, and the minimum frequency corresponding to the wave spectrum; Based on the wave parameters and a preset first processing strategy, the preset initial grid matrix is corrected, and values are assigned to the corrected grid matrix, including: The initial grid matrix is corrected based on the first circular frequency, and the corrected grid matrix is assigned values using the first wave height, the first circular frequency, and the first phase. The initial grid matrix is corrected based on the wave parameters and a preset second processing strategy, and values are assigned to the corrected grid matrix, including: The initial grid matrix is corrected based on the wave spectrum, maximum frequency, and minimum frequency, and the corrected grid matrix is then assigned values using the wave spectrum, maximum frequency, and minimum frequency.
3. The adaptive fast ocean wave height simulation calculation method according to claim 2, characterized in that, The initial grid matrix is a square matrix composed of N*N grid cells, where each grid cell is a square. The initial grid matrix is corrected based on the first circular frequency, including: Input the first circular frequency into the preset grid length calculation formula to obtain the grid length of the grid cell in the grid matrix; The formula for calculating the grid length includes: ; in, Indicates the grid length of the grid cell. Represents gravitational acceleration, and N represents the number of rows and columns of the initial grid matrix. Indicates the first angular frequency; Based on the calculated grid length and the number of rows and columns of the initial grid matrix, the corrected grid matrix is obtained.
4. The adaptive fast ocean wave height simulation calculation method according to claim 2, characterized in that, The modified grid matrix is assigned values using the first wave height, first circular frequency, and first phase, including: Input the first circular frequency, the first wave height and the first phase into the preset first element calculation formula to obtain the first matrix element value corresponding to the first preset position; The formula for calculating the first element includes: ; in, This represents the value of the first matrix element in the m-th row and n-th column of the grid matrix. Indicates the first wave high. Indicates the first phase. The first circular frequency is represented by N, which represents the number of rows and columns of the initial grid matrix. Based on the preset first element symmetry relationship, a first symmetric position that is symmetrical to the first preset position is determined, and the conjugate value of the first matrix element value is assigned to the first symmetric position to obtain the assigned grid matrix.
5. The adaptive fast ocean wave height simulation calculation method according to claim 2, characterized in that, The initial grid matrix is a square matrix composed of N*N grid cells, where each grid cell is a square. The initial grid matrix is corrected based on the wave spectrum, maximum frequency, and minimum frequency, including: Based on N and the minimum frequency, the ratio between the physical space length corresponding to the initial grid matrix and the total length of the ship is determined; The N is updated based on preset grid creation conditions, wherein the grid creation conditions are obtained based on multiple relationships, maximum frequency, and N; The grid length of the grid cells in the grid matrix is calculated based on the updated N; Based on the calculated grid length and the updated N, the corrected grid matrix is obtained.
6. The adaptive fast ocean wave height simulation calculation method according to claim 2, characterized in that, Irregular waves include: long-peaked irregular waves; The corrected grid matrix is assigned values using the wave spectrum, maximum frequency, and minimum frequency, including: The wave spectrum is sampled for the first time, and the second wave height at different wave numbers corresponding to the first sampling results is calculated. Input the second wave height into the preset second element calculation formula to obtain the second matrix element value corresponding to the second preset position; The formula for calculating the second element includes: ; in, This represents the value of the second matrix element in the m-th row and n-th column of the grid matrix. This represents the second wave height corresponding to the m-th row and n-th column in the grid matrix, where N represents the number of rows and columns in the initial grid matrix. This represents the randomly generated second phase corresponding to the m-th row and n-th column of the grid matrix. This represents the second circular frequency corresponding to the m-th row and n-th column of the grid matrix; Based on the preset second element symmetry relationship, a second symmetric position that is symmetrical to the second preset position is determined, and the conjugate value of the second matrix element value is assigned to the second symmetric position to obtain the assigned grid matrix.
7. The adaptive fast ocean wave height simulation calculation method according to claim 2, characterized in that, Irregular waves include: short-peak irregular waves; The corrected grid matrix is assigned values using the wave spectrum, maximum frequency, and minimum frequency, including: The wave spectrum is subjected to a second sampling process, and the third wave height at different wave numbers corresponding to the second sampling results is calculated. Input the third wave height into the preset third element calculation formula to obtain the third matrix element value corresponding to the third preset position; The formula for calculating the third element includes: ; in, This represents the value of the third matrix element in the m-th row and n-th column of the grid matrix. This represents the height of the third wave corresponding to the m-th row and n-th column in the grid matrix. This represents the third phase corresponding to the m-th row and n-th column in the grid matrix. This represents the third circular frequency corresponding to the m-th row and n-th column in the grid matrix. Based on the preset symmetry relationship of the third element, the third symmetric position that is symmetrical to the third preset position is determined, and the conjugate value of the third matrix element value is assigned to the third symmetric position to obtain the assigned grid matrix.
8. The adaptive fast ocean wave height simulation calculation method according to any one of claims 1-7, characterized in that, Based on the assigned grid matrix, the wave height matrix at time t is calculated, including: ; in, This represents the wave height matrix corresponding to the grid matrix in the m-th row and n-th column. Let i represent the matrix element value corresponding to different waves in row p and column q, where i represents the imaginary unit and the square of i is -1.
9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the steps of the adaptive fast ocean wave height simulation calculation method as described in any one of claims 1 to 8.
10. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the adaptive fast wave height simulation calculation method as described in any one of claims 1 to 8.