Sea Surface Flow Field Inversion Method Based on AIS Data
By using a direction-aware adaptive clustering algorithm to filter out the dual constraints of heading diversity and spatial proximity, and adaptively aggregating AIS data points, the error in sea surface current field inversion caused by fixed grid division is solved, and more accurate and robust ocean current inversion is achieved.
Patent Information
- Application Number
- CN202511340611.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-09-19
- Publication Date
- 2025-12-02
- Estimated Expiration
- 2045-09-19
AI Technical Summary
In existing technologies, the fixed grid division method leads to non-uniform distribution of AIS data points in sea surface flow field inversion, which violates the continuity of the flow field, introduces heterogeneous data, reduces the reliability of the inversion results, and lacks theoretical discussion on systematically selecting high-quality AIS data.
An orientation-aware adaptive clustering algorithm is adopted, which uses the orientation circle mechanism to filter the dual constraints of heading diversity and spatial proximity, adaptively aggregates AIS data points to form high-quality clusters, and constructs a numerically stable function matrix for inversion.
It improves the accuracy and reliability of sea surface flow field inversion, overcomes the rigid constraints of traditional grid generation, and enhances the numerical stability and inversion accuracy of the solution process.
Smart Images

Figure CN120832836B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of marine monitoring technology and relates to a method for inverting sea surface flow fields based on AIS data. Background Technology
[0002] As an advanced shipborne communication device, AIS can broadcast dynamic information such as ship position, speed, course, and timestamps in near real-time and continuously. Especially in densely populated nearshore waters, AIS data exhibits unique advantages such as wide coverage and high spatiotemporal resolution, providing a solid data foundation for high-precision sea surface flow field inversion. From a physical perspective, a ship's actual navigation state at sea is the result of the combined effects of various factors, including sea surface wind field, current field, and the ship's own dynamics. The sea surface current field affects the ship's velocity relative to water, which is reflected in the ship's actual trajectory and speed relative to land. Therefore, the ship's trajectory contains rich information about sea surface speed, and the ship dynamic information recorded by AIS data provides the possibility for extracting this information.
[0003] However, current large-scale sea surface velocity field inversion studies generally employ gridded processing of the sea area and utilize all AIS data within each grid to construct a function matrix for solution. But fixed grid partitioning has significant limitations. In actual marine environments, AIS data points are often non-uniformly distributed. When data points are densely distributed at grid edges, fixed grid partitioning forces them into different cells, violating the principle of flow field continuity. However, from a physical perspective, spatially adjacent points should belong to the same cluster cell because they are in similar flow field environments and have similar dynamic characteristics. Forced partitioning introduces heterogeneous data, interfering with the solution and causing the inverted sea surface velocity to deviate from the true value, reducing the reliability of the results. Secondly, although current research has verified the feasibility of using AIS data to construct a function matrix for inverting sea surface velocity, in-depth theoretical discussions are still lacking on how to systematically select high-quality AIS data to construct a numerically stable and physically consistent inversion model. Summary of the Invention
[0004] The purpose of this invention is to overcome the shortcomings of the prior art and provide a sea surface flow field inversion method based on AIS data. This method uses a direction-aware adaptive clustering algorithm to obtain high-quality AIS data and achieves adaptive aggregation of AIS data points under dual constraints of space and heading, thereby improving the accuracy and reliability of the inversion results.
[0005] The technical solution provided by this invention is: a sea surface current field inversion method based on AIS data, comprising the following steps:
[0006] Step 1: Acquire AIS data and clean the AIS data points;
[0007] Step 2: Use a direction-aware adaptive clustering algorithm to cluster the data from Step 1 to obtain clusters with diverse headings and spatial proximity.
[0008] Step 3: Use the clustering results obtained in Step 2 to perform sea surface flow field inversion;
[0009] The orientation-aware adaptive clustering algorithm specifically includes: sequentially traversing AIS data points, calculating the distance between each AIS data point and the center of all current clusters, finding clusters where the distance from the data point to the cluster center is less than a threshold, then determining whether the angular sector of the orientation circle occupied by the data point overlaps with the orientation circle of the cluster. If there is overlap, the AIS data point is deleted; otherwise, the AIS data point is added to the cluster, and the cluster statistics are updated, including the number of points. Cluster Center Cluster radius , point angle sector set If the cluster radius exceeds the preset value Then, the clusters are split; the angle sector of the direction circle occupied by the AIS data point is calculated by the following method: determine the corresponding angle threshold interval based on the bow direction of the AIS data point, calculate the interval covered by the reverse extension line of the boundary of the interval, and map it to the angle sector of the direction circle. In this context, each sector can accommodate at most one AIS data point; the direction circle of a cluster refers to the set of angular sectors occupied by all AIS data points in that cluster.
[0010] Preferably, the angular sector of the direction circle occupied by each AIS data point Defined as:
[0011] ;
[0012] in, For the bow direction of the AIS data point, The angle threshold of the direction circle. The angle range covered by the reverse extension line.
[0013] Preferably, the splitting of the cluster is specifically as follows: traversing all data points within the cluster, calculating the Haversine distance between any two data points, and selecting the two data points with the greatest distance, denoted as... and And use it as the initial center of the two subclusters 1 and 2. and ;
[0014] Traverse all data points within the cluster Calculate each data point to and distance and ;like Then Assigned to subcluster 1; if Then Assigned to subcluster 2; if According to The similarity between the heading sector and the heading sector of the initial center of the two subclusters is used to assign it to the subcluster with better heading diversity;
[0015] Calculate the statistical information of the two subclusters separately. and The sub-cluster center is the average latitude and longitude of all data points within the cluster, and the radius is the maximum Haversine distance from the data points within the cluster to the cluster center.
[0016] If the sub-cluster radius and If the sub-cluster radius is determined to be still beyond the threshold, the above splitting process is repeated for that sub-cluster until all sub-cluster radii meet the spatial constraints; if the sub-cluster radius meets the requirements, the splitting ends.
[0017] Compared with existing technologies, this invention has the following advantages: The direction-aware adaptive clustering algorithm proposed in this invention dynamically generates clusters based on spatial density, enabling AIS data points that meet the same function matrix solution conditions (i.e., spatially adjacent and in the same flow field environment) to autonomously aggregate, overcoming the rigid constraints of traditional fixed grid partitioning methods. Simultaneously, a "direction circle" mechanism is proposed to remove AIS data points with the same or opposite headings in real time during the clustering process, retaining effective samples with balanced heading distribution. This reduces matrix ill-conditionedness from the source, significantly improving the numerical stability of the solution process and the reliability of the inversion results. This method effectively solves the logical matching problem of traditional grid partitioning and enhances inversion accuracy through direction optimization, providing a more accurate and robust technical path for AIS ocean current inversion. Attached Figure Description
[0018] Figure 1 This is a flowchart of the sea surface flow field inversion method based on AIS data in an embodiment of the present invention;
[0019] Figure 2 This is a schematic diagram of the directional circle mechanism proposed in this invention;
[0020] Figure 3 This is a schematic diagram of the splitting mechanism proposed in this invention;
[0021] Figure 4 A force model for ship motion;
[0022] Figure 5 Ocean currents obtained by the method of this invention The fit between the components and the CMEMS data;
[0023] Figure 6 Ocean currents obtained by the method of the present invention The fit between the components and the CMEMS data. Detailed Implementation
[0024] To facilitate understanding of the present invention, the specific embodiments of the present invention will be described in further detail below with reference to the accompanying drawings and specific examples. The following examples or drawings are used to illustrate the present invention, but are not intended to limit the scope of the present invention.
[0025] The Automatic Identification System (AIS) is a navigation safety and communication system used for information exchange between ships and between ships and shore. It collects a wealth of data, including static attributes such as the Ship Mobility Service Identifier (MMSI), ship type, length, and draft, as well as dynamic navigation parameters with high spatiotemporal resolution, such as timestamps, latitude and longitude coordinates, turning rate, speed over ground (SOG), course over ground (COG), and head. This detailed dynamic information provides a solid data foundation for inverting sea surface currents.
[0026] When inverting ocean currents over a large area, it is necessary to select a sufficient number of "perfect ship attitude points" with uniform heading distribution within a suitable small-scale spatiotemporal range. This balances equation redundancy and matrix good state, thereby improving the accuracy and reliability of the inversion results while ensuring solution stability. To this end, this invention provides a sea surface flow field inversion method based on AIS data. This method proposes a direction-aware adaptive clustering algorithm. This clustering algorithm quantifies the heading distribution characteristics during the clustering process through a "direction circle" mechanism to ensure heading diversity. Relying on the extended clustering feature structure, it achieves adaptive aggregation of AIS data points under dual spatial and heading constraints, thereby accurately solving the sea surface velocity at each ship position.
[0027] The sea surface flow field inversion method based on AIS data provided by this invention has the following process: Figure 1 As shown, the specific steps include:
[0028] 1. Acquire AIS data and clean the AIS data points.
[0029] Second, a direction-aware adaptive clustering algorithm is used to cluster the data from step one to obtain clusters with diverse headings and spatial proximity.
[0030] The specific implementation process of this clustering algorithm is as follows:
[0031] 1. Definition of Clustering Features (CF)
[0032] Clustering features (CF) are the core carrier for achieving adaptive clustering of AIS data points. They obtain a set of sample clusters that are "spatially compact and have diverse headings" by comprehensively considering the spatial position and heading distribution characteristics of ships. Compared to traditional clustering algorithms, this invention introduces a heading distribution descriptor, defining the clustering features as a four-tuple structure, as shown below:
[0033] ;
[0034] in, The number of AIS data points within a cluster reflects the size of the cluster; The cluster center is the average latitude and longitude coordinates of all AIS data points within the cluster; The radius of the cluster is defined as the maximum Haversine distance from all points within the cluster to the cluster center. It is used to quantify the spatial dispersion of data points within the cluster and to provide a threshold for subsequent cluster splitting mechanisms. Record the set of sectors occupied by the "direction circle" corresponding to all AIS data points in the cluster. This directly serves the direction circle filtering mechanism. By verifying in real time whether the heading sector of a newly added point overlaps with the existing set, the diversity of heading distribution within the cluster is ensured, thus avoiding the matrix rank deficiency problem from the source.
[0035] 2. AIS data point filtering
[0036] During the clustering process, whether an AIS data point can be added to the current cluster requires strict verification based on both spatial proximity and directional diversity.
[0037] (1) Heading diversity screening
[0038] To effectively identify and avoid concentrated distributions of ship headings, this invention designs a novel mechanism based on heading angle interval constraints—the "direction circle"—to identify high-quality AIS data points within clusters that meet the heading diversity screening requirements. The "direction circle" mechanism can avoid matrix ill-conditioned problems caused by systematic convergence or symmetrical distribution of headings from the data source, thus providing a numerically stable data foundation for solving the equations in ocean current inversion.
[0039] In summary, the "direction circle" mechanism maps the heading of each AIS data point to a circular angular sector for representation, and strictly constrains each sector to accommodate at most one AIS data point, thereby ensuring the sparsity and diversity of heading distribution at the geometric level. The specific workflow of this mechanism in gradually aggregating AIS data points to construct clusters is as follows:
[0040] For the AIS data point to be inserted, first determine the corresponding angle threshold interval based on its heading, and then calculate the interval covered by the reverse extension line of the sector boundary, specifically as follows: Figure 2 As shown, the left side represents the ship heading status within a cluster during the clustering process within a certain spatiotemporal range, and the right side represents the direction circles occupied by all ships in all clusters. The solid lines represent the direction circle sectors occupied by the actual ship headings, and the dashed lines represent the direction circle sectors occupied by the reverse extension lines of the headings. Reasonable heading intervals are represented in blue. Red ships are abnormal insertion points during the clustering process. Abnormal insertions cause red overlap errors with the originally occupied direction circle sectors.
[0041] Considering the periodic variable of a ship's heading angle, ranging from 0° to 360°, the angle interval within the heading circle may cross either the 0° or 360° boundary. Therefore, segmentation based on the angle value is necessary. The sector occupied by each AIS data point... The following three categories can be used to define the classification:
[0042] ;
[0043] in, For the bow direction of the data point, The angle threshold of the direction circle. For the sectors occupied by the reverse extension line, This refers to the entire occupied sector of the direction circle corresponding to the AIS point.
[0044] Determine the "occupied sectors" of the data points to be added to AIS. Further examination is required afterward. Does it overlap with the sectors of the existing "direction circle" within the cluster? Let the set of sectors occupied by existing AIS points within the cluster be... , If there are already points within the cluster, then If the "occupied sector" of the data point to be inserted overlaps with existing sectors within the cluster, it indicates that the data point's heading is either too similar to or too different from existing data points within the cluster, and it needs to be removed; if The absence of overlap indicates that the heading distribution of this data point meets the diversity requirements and can provide stable sample information for ocean current inversion. Therefore, this data point is allowed to join the cluster, and its corresponding "occupied sector" is included in the coverage of the "direction circle".
[0045] (2) Spatial proximity screening
[0046] Because the Haversine distance calculation can eliminate the influence of the Earth's curvature and accurately reflect the actual spherical distance between two points, the cluster center is used as the benchmark during spatial proximity verification, and the Haversine formula is used to calculate the AIS data points to be screened. ) spherical distance from the center .like Less than the preset intra-cluster spatial proximity threshold If so, it can be preliminarily determined that the AIS data point is spatially compatible with the cluster. The calculation formula is as follows:
[0047] ;
[0048] in, , The latitude and radians of the two data points. , The longitude and radians of the two data points are given.
[0049] (3) If AIS data points ( If both of the above conditions are met, the element is added to the current cluster; if it only meets the heading diversity condition but is outside the spatial proximity range, it is still included and the cluster splitting mechanism is triggered to maintain spatial structure consistency; otherwise, it is removed.
[0050] 3. Dynamically update the clustering feature parameters of the clusters.
[0051] AIS data points ( To avoid efficiency losses caused by recalculating all cluster features after adding data points to a cluster, this invention designs an incremental iterative update strategy to fine-tune the statistical information (CF) in real time. The specific update formula is as follows:
[0052] ;
[0053] in, The original number of AIS points within the cluster, incrementing by 1. ; The cluster centers before the update; Let be the radius of the cluster, and take the maximum Haversine distance from all points within the cluster to the cluster center. The Haversine distance from the newly added point to the updated cluster center; Simultaneously included ( The corresponding occupied sector .
[0054] 4. Split Mechanism
[0055] If new AIS data points are added, the radius of the cluster will... Exceeding the preset intra-cluster spatial proximity threshold This means that if the spatial distribution within a cluster is too scattered, the cluster splitting mechanism will be triggered.
[0056] Specifically, first, all AIS data points within the cluster are traversed, the Haversine distance between any two points is calculated, and the two points with the greatest distance are selected and denoted as... and And use it as the initial center of the two subclusters 1 and 2. and .
[0057] Then traverse all points within the cluster. Calculate the distance from each point to and distance and .like Then Assigned to subcluster 1; if Then Assigned to subcluster 2; if According to The similarity between the heading sector and the heading sector of the initial center of the two subclusters is used to assign the sector to the subcluster with better heading diversity.
[0058] Calculate the statistical information (CF) of the two subclusters separately. and The sub-cluster center is the average latitude and longitude of all points in the cluster, and the radius is the maximum Haversine distance from the point in the cluster to the center, thus forming a new clustering feature.
[0059] If the sub-cluster radius and If the sub-cluster radius is determined to be still beyond the threshold, the above splitting process is repeated for the sub-cluster until the radii of all sub-clusters meet the spatial constraints; if the sub-cluster radius meets the requirements, the splitting ends and the newly generated sub-clusters participate in the subsequent ocean current inversion as independent clustering units.
[0060] The splitting mechanism ensures that each resulting cluster simultaneously satisfies the "space compactness" requirement. "and "diversified course" The two core requirements of "no overlap" provide a high-quality sample set for the subsequent construction of a stable set of ocean current inversion equations. The splitting process is as follows: Figure 3 As shown.
[0061] 3. Use the clustering results obtained in step 2 to perform sea surface flow field inversion.
[0062] By utilizing the ship dynamic information (such as ship heading and speed to land) recorded in the high-quality AIS data obtained by the above clustering algorithm, a corresponding function matrix is constructed, thereby realizing the inversion calculation of ocean currents at each ship location.
[0063] in accordance with Figure 4 The ship force model in the model, by projecting the vectors onto the horizontal and vertical axes related to the zonal and meridional velocity components, yields a system of equations containing two equations and three unknowns (i.e., the direction and magnitude of the sea surface force and the magnitude of the ship's velocity relative to the water surface), as shown in the following expressions:
[0064] .
[0065] For each AIS data point, in the above formula... The ground speed is SOG; For ground heading COG, The bow is the direction of the ship. When solving the two equations in the above formula using only a single AIS data point, a unique solution cannot be directly obtained because the equations contain three unknown variables (each AIS data point provides two equations, but contains three unknowns). Therefore, a single observation constitutes an underdetermined system, and a unique solution cannot be obtained.
[0066] To solve this system of equations, multiple data points need to be introduced to construct an overdetermined system. Consider the existence of such an overdetermined system in a region with a relatively small spatiotemporal range and where sea surface conditions can be considered uniform. There are 10 AIS data points. Each AIS data point can provide two equations, so the total number of equations is 100. The unknown quantity is The speed of water and two ocean current components and ,total There are several unknowns. At this point, an overdetermined system of equations can be constructed and solved using the least squares method. The overdetermined system of equations can be written in matrix form:
[0067] ;
[0068] in:
[0069] ;
[0070] in, The velocity of the ocean surface in the latitudinal direction. The speed towards the ocean surface;
[0071] coefficient matrix The structure is as follows:
[0072] .
[0073] Observation vector for:
[0074] .
[0075] The solution error of the above system of equations directly depends on the matrix. The condition number. Defined as:
[0076] ;
[0077] in, and They are respectively The maximum and minimum singular values; The smaller the value, the smaller the solution error; The larger the matrix, the more "ill-conditioned" the solution becomes, and the error may be amplified dramatically.
[0078] In the process of inverting ocean currents using AIS data, a matrix is designed. ill-posedness and ship course The distribution characteristics are closely related to the velocity distribution, directly determining the numerical stability and reliability of the velocity solution. When the heading distribution is highly concentrated or exhibits a symmetrical / anti-symmetrical pattern (e.g., multiple AIS data points have approximately the same heading), the velocity distribution becomes more concentrated. ) or the exact opposite (or This will lead to an approximately linear correlation between the column vectors of the matrix. Specifically, the sine and cosine function values corresponding to these ships satisfy... , , , Thus, the matrix The column vectors tend to be proportional. This phenomenon will lead to rank deficiency, making the minimum singular value of the matrix less than the minimum singular value. Approaching zero, condition number The error increases dramatically, approaching infinity. Under this ill-conditioned condition, the solution process is extremely sensitive to observation errors and numerical perturbations, leading to a significant amplification of the error in the inversion results, and even rendering them meaningless.
[0079] Conversely, for example, there are two ships with orthogonal headings (such as...) When ), the corresponding column vectors are respectively and The columns are linearly independent of each other, thus effectively enhancing the completeness of the matrix column space. This distribution avoids redundancy between column vectors, improving the minimum singular value and correspondingly reducing the condition number.
[0080] The AIS data obtained by the clustering method proposed in this invention fully considers the uniformity and diversity of the heading distribution, thereby suppressing matrix ill-conditionedness and improving the accuracy and reliability of the solution.
[0081] To evaluate the performance of the method proposed in this invention, a simulation verification experiment was conducted in the core region of the Agulhas Current, using CMEMS (Copernicus Ocean Environmental Monitoring Service) simulated ocean current data as a benchmark for accuracy evaluation. The results are as follows: Figure 5 , Figure 6 As shown, the ocean currents obtained by inversion using the method of the present invention , The goodness of fit (coefficient of determination R²) between the components and the CMEMS data all reached around 0.7.
Claims
1. A method for inverting sea surface current fields based on AIS data, characterized in that, Includes the following steps: Step 1: Acquire AIS data and clean the AIS data points; Step 2: Use a direction-aware adaptive clustering algorithm to cluster the data from Step 1 to obtain clusters with diverse headings and spatial proximity. Step 3: Use the clustering results obtained in Step 2 to perform sea surface flow field inversion; The orientation-aware adaptive clustering algorithm specifically includes: sequentially traversing AIS data points, calculating the distance between each AIS data point and the center of all current clusters, finding clusters where the distance from the data point to the cluster center is less than a threshold, then determining whether the angular sector of the orientation circle occupied by the data point overlaps with the orientation circle of the cluster. If there is overlap, the AIS data point is deleted; otherwise, the AIS data point is added to the cluster, and the cluster statistics are updated, including the number of points. Cluster Center Cluster radius , point angle sector set If the cluster radius exceeds the preset value Then, the clusters are split; the angular sector of the directional circle occupied by the AIS data point is calculated using the following method: based on the bow direction of the AIS data point... Determine the corresponding angle threshold interval, calculate the interval covered by the reverse extension of the boundary of this interval, and map it to the angle sector of the direction circle. In this context, each sector can hold at most one AIS data point; the direction circle of a cluster refers to the set of angular sectors occupied by all AIS data points in that cluster. The angle sector of the direction circle occupied by each AIS data point Defined as: ; in, For the bow direction of the AIS data point, The angle threshold of the direction circle. The angle range covered by the reverse extension line.
2. The sea surface current field inversion method based on AIS data according to claim 1, characterized in that, The splitting of the cluster is specifically as follows: traverse all data points within the cluster, calculate the Haversine distance between any two data points, and select the two data points with the greatest distance, denoted as... and And use it as the initial center of the two subclusters 1 and 2. and ; Then traverse all points within the cluster. Calculate the distance from each point to and distance and ;like Then Assigned to subcluster 1; if Then Assigned to subcluster 2; if According to The similarity between the heading sector and the heading sector of the initial center of the two subclusters is used to assign it to the subcluster with better heading diversity; Calculate the statistical information of the two subclusters separately. and The sub-cluster center is the average latitude and longitude of all data points within the cluster, and the radius is the maximum Haversine distance from the data points within the cluster to the cluster center. If the sub-cluster radius and If the sub-cluster radius is determined to be still beyond the threshold, the above splitting process is repeated for that sub-cluster until all sub-cluster radii meet the spatial constraints; if the sub-cluster radius meets the requirements, the splitting ends.
Citation Information
Patent Citations
A ship optimal route automatic generation method based on AIS big data
CN112906830A
Method, system, and device for full-waveform inversion deghosting of marine variable depth streamer data acquisition
US11709286B1