Next Article in Journal / Special Issue
Auditing Inferential Blind Spots: A Framework for Evaluating Forensic Coverage in Network Telemetry Architectures
Previous Article in Journal
FANET Routing Protocol for Prioritizing Data Transmission to the Ground Station
Previous Article in Special Issue
Design and Performance Evaluation of HEPS Data Center Network
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

DOTSSA: Directed Acyclic Graph-Based Online Trajectory Simplification with Stay Areas

Department of Information Science and Engineering, Faculty of Information Science and Engineering, Okayama University of Science, Okayama 700-0005, Japan
Submission received: 10 December 2025 / Revised: 16 January 2026 / Accepted: 20 January 2026 / Published: 29 January 2026
(This article belongs to the Special Issue Advanced Technologies in Network and Service Management, 2nd Edition)

Abstract

Devices equipped with the Global Positioning System (GPS) generate massive volumes of trajectory data on a daily basis, imposing substantial computational, network, and storage burdens. Online trajectory simplification reduces redundant points in a streaming manner while preserving essential spatial and temporal characteristics. A representative method in this line of research is Directed acyclic graph-based Online Trajectory Simplification (DOTS). However, DOTS does not preserve stay-related information and can incur high computational cost. To address these limitations, we propose Directed acyclic graph-based Online Trajectory Simplification with Stay Areas (DOTSSA), a fast online simplification method that integrates DOTS with an online stay area detection algorithm (SA). In DOTSSA, SA continuously monitors movement patterns to detect stay areas and segments the incoming trajectory accordingly, after which DOTS is applied to the extracted segments. This approach ensures the preservation of stay areas while reducing computational overhead through localized DAG construction. Experimental evaluations on a real-world dataset show that, compared with DOTS, DOTSSA can reduce compression time, while achieving comparable compression ratios and preserving key trajectory features.

1. Introduction

The widespread use of Global Positioning System (GPS)-equipped devices, including smartphones, drones, and vehicles, has led to the daily generation of massive volumes of trajectory data. In many real-world applications, such trajectories are continuously collected and retained for retrospective analytics, auditing, and model updating. However, storing and transmitting high-rate GPS streams at scale can become cost-prohibitive. If such data are collected every 10 s, a simple estimation indicates that approximately 100 MB of storage is required to store the trajectories of just over 400 objects for a single day [1]. According to statistics released by the U.S. Department of Transportation, motor vehicles in the United States traveled a total of 2.95 × 10 12 miles in 2011 for longer-distance trajectories [2]. Assuming a speed of 60 miles per hour and a GPS sampling rate of 1/60 Hz, this would generate approximately 53 TB of GPS trajectory data in that year [3].
These data are indispensable for applications such as advanced location-based services such as next location prediction [4,5], travel route recommendation [6,7], and mobility analysis [8,9]. However, their accumulation increases network transmission and storage costs, complicating efficient data processing. Real-world trajectories also contain numerous redundant points that do not contribute to changes in movement direction or speed, resulting in unnecessary computational overhead when stored or analyzed. Trajectory simplification (trajectory compression) addresses these issues by removing redundant points while preserving the spatial and temporal characteristics of the original trajectory, thereby reducing data size and improving processing efficiency.
The existing trajectory simplification algorithms can be categorized as either batch or online approaches. Batch approaches such as Douglas–Peucker (DP) [10], Top-Down Time Ratio (TDTR) [1], and Multiresolution Polygonal Approximation Algorithm (MRPA) [11] assume that a complete trajectory is available and simplify it while controlling the approximation error. Online approaches, including Opening Window (OW) [12], Opening Window Time Ratio (OWTR) [1], Dead Reckoning [13], Spatial QUalIty Simplification Heuristic (SQUISH) [14], Spatial QUalIty Simplification Heuristic-Extended( μ )(SQUISH-E( μ )) [15], and Directed acyclic graph-based Online Trajectory Simplification (DOTS) [16], simplify trajectories in a streaming manner as new points arrive. The batch approaches typically achieve higher-quality simplification because they utilize the entire trajectory, whereas online approaches support incremental processing suitable for real-time applications.
Although these algorithms effectively preserve the spatial and temporal characteristics of a trajectory, they often fail to retain stay-related information, such as stay areas where users remain for a specified duration. Given the importance of stay areas for understanding traffic congestion [17,18] and user behavior [19,20], it is essential that simplified trajectories preserve this information.
A stay point is detected when a user remains within a specific region for longer than a predefined duration. A stay area is a consecutive sequence of such stay points representing a region where the user has stayed. Figure 1 shows a sample trajectory, where the black points represent the location points, the dashed blue circle denotes the stay area, and the red points indicate the stay points. Within a stay area, GPS points are densely clustered and fluctuate irregularly within a limited spatial region due to the user remaining stationary. As a result, many of these points do not contribute meaningful information to trajectory representation.
To capture the temporal and spatial information of a stay area, retaining only the first and last stay points in each stay area is sufficient. All other stay points within the stay area were therefore regarded as redundant in the current study. Existing trajectory simplification algorithms struggle to achieve high compression rates while preserving stay areas. Although many methods allow parameter tuning to reach a target simplification rate, setting a low rate increases the chance that the start and end points of the stay areas remain but also preserves many redundant points, reducing efficiency. Conversely, setting a high simplification rate removes many points, thereby increasing the likelihood that important stay area points will be discarded.
To address these limitations, this study proposes Directed acyclic graph-based Online Trajectory Simplification with Stay Areas (DOTSSA), an extension of DOTS. DOTSSA integrates SA, an online adaptation of the stay area detection method proposed in [21], with DOTS. DOTS approximates a solution to the min- ε problem, which aims to identify a minimal subset of points that preserves the trajectory while minimizing the simplification error, and it is highly effective for online trajectory simplification [22]. However, DOTS suffers from two limitations: the directed acyclic graph (DAG) optimization is computationally expensive and the stay points are not preserved. DOTSSA applies DOTS to each sub-trajectory segmented by the stay areas extracted by the SA. Consequently, the compression time that DOTSSA achieves is reduced, and the compression rate is high, while ensuring that the stay area in the trajectory data is preserved.
The contributions of this research are summarized as follows.
  • We propose DOTSSA, a semantics-aware online trajectory simplification framework that integrates online stay area detection with DOTS and reliably preserves stay areas by applying DOTS to the sub-trajectories segmented at detected stay regions.
  • We conduct experiments on a large-scale real-world dataset, demonstrating that DOTSSA substantially reduces compression time compared with DOTS while achieving competitive compression ratios and error metrics against multiple baselines.
The remainder of this article proceeds as follows. Section 2 introduces the definitions and error-based quality metrics used in trajectory simplification. Section 3 presents the proposed DOTSSA method in detail, including the stay area detection algorithm and its integration with DOTS. Section 4 reports the experimental results and performance comparisons with existing methods. Finally, Section 5 concludes this paper and discusses directions for future work.

2. Definitions

2.1. Trajectory

In this study, a trajectory is defined as an ordered sequence of GPS points
T = { p 1 , p 2 , , p N }
where each point p i = ( x i , y i , t i ) consists of longitude x i , latitude y i , and timestamp t i .
For two points p s and p e ( 1 s < e N ) , the line segment p s p e ¯ denotes the anchor segment used to approximate the intermediate points, and the points within this interval are represented as { p k s < k < e } .
The simplified trajectory is denoted by
T = { p 1 , p 2 , , p M }
which is a subsequence of T consisting of points retained during simplification, where M is expected to be much smaller than N.

2.2. Error-Based Quality Metrics

This subsection outlines four widely used error metrics commonly employed to evaluate trajectory simplification. Additionally, DOTS utilizes two error metrics tailored to its unique method. These metrics quantify how well the simplified trajectory preserves the original movement behavior and assess errors from complementary perspectives, because a single metric is often insufficient to capture different types of information loss. Specifically, PED evaluates geometric deviation, SED measures spatio-temporal deviation, DAD quantifies directional changes, and SAD reflects variations in speed-related dynamics. Additionally, DOTS introduces two SED-based metrics, LISSED and ISSED, to support procedures for selecting compression points. The geometric definitions of these metrics are illustrated in Figure 2.

2.2.1. Perpendicular Distance Error (PED)

PED measures the shortest distance from a point p k to the anchor segment p s p e ¯ and is defined as follows:
PED ( p s , p k , p e ) = ( y e y s ) x k ( x e x s ) y k + x e y s y e x s ( y e y s ) 2 + ( x e x s ) 2

2.2.2. Synchronized Euclidean Distance (SED)

SED extends PED by incorporating temporal information, evaluating the Euclidean distance between a point and its synchronized point on the anchor segment. This metric evaluates the Euclidean distance between the actual point p k and its synchronized point, p k , which is defined on the anchor segment p s p e ¯ at corresponding time t k . SED is defined as follows:
SED ( p s , p k , p e ) = ( x k x k ) 2 + ( y k y k ) 2 x k = x s + t k t s t e t s ( x e x s ) y k = y s + t k t s t e t s ( y e y s )

2.2.3. Direction-Aware Distance (DAD)

DAD quantifies the directional deviation between the anchor segment p s p e ¯ and the segment p s p k ¯ based on their azimuth angles. Considering the periodicity of the angles, DAD is defined as follows:
DAD ( p s , p k , p e ) = min ( θ ( p s , p e ) θ ( p s , p k ) , 2 π θ ( p s , p e ) θ ( p s , p k ) ) θ ( p s , p e ) = atan 2 ( y e y s , x e x s ) θ ( p s , p k ) = atan 2 ( y k y s , x k x s )

2.2.4. Speed-Aware Distance (SAD)

SAD measures the deviation between the actual speed from p k to p k + 1 and the estimated speed between the synchronized points p k and p k + 1 on the anchor segment. SAD is defined as follows:
SAD ( p s , p k , p e ) = d ( p k , p k + 1 ) t k + 1 t k d ( p k , p k + 1 ) t k + 1 t k
where d ( · , · ) denotes the Euclidean distance between two points and p k and p k + 1 are defined in the same manner as in SED.

2.2.5. Integral Squared Synchronized Euclidean Distance (ISSED)

ISSED evaluates the overall approximation error of a simplified trajectory T by accumulating the squared SED values over all anchor segments induced by T . ISSED is defined as follows:
ISSED ( T ) = k = 1 M 1 LISSED ( k , k + 1 )
Here, the Local Integral Squared Synchronized Euclidean Distance (LISSED), denoted by LISSED ( s , e ) , is defined for the sub-trajectory between the anchor points p s and p e as the sum of the squared SED values over all points p k in that interval:
LISSED ( s , e ) = s < k < e SED ( p s , p k , p e ) 2 = ( c 1 2 + c 3 2 ) ( e s 1 ) + ( c 2 2 + c 4 2 ) ( S t 2 e 1 S t 2 s ) + 2 ( c 1 c 2 + c 3 c 4 ) ( S t e 1 S t s ) + ( S x 2 e 1 + S x 2 s ) + ( S y 2 e 1 + S y 2 s ) 2 c 1 ( S x e 1 + S x s ) + 2 c 3 ( S y e 1 + S y s ) 2 c 2 ( S x t e 1 + S x t s ) + 2 c 4 ( S y t e 1 + S y t k )
where
c 1 = x s t e x e t s t e t s , c 2 = x e x s t e t s , c 3 = y s t e y e t s t e t s , c 4 = y e y s t e t s S x i = j = 1 i x j , S y i = j = 1 i y j , S t i = j = 1 i t j , S x 2 i = j = 1 i x j 2 S y 2 i = j = 1 i y j 2 , S t 2 i = j = 1 i t j 2 , S x t i = j = 1 i t j x j , S y t i = j = 1 i t j y j

3. Proposed Method

This section presents DOTSSA, the proposed trajectory simplification method that integrates DOTS with the stay area detection procedure SA. An overview of DOTSSA is shown in Figure 3. We first describe SA and DOTS separately and then explain how DOTSSA combines them to perform efficient simplification while preserving stay areas.

3.1. SA

As illustrated in Figure 1, SA defines stay points as points satisfying distance and time thresholds within the dashed blue stay area and defines a stay area as the consecutive sequence of such stay points in the trajectory data that satisfies all of the following conditions:
a < i d ( p a , p i 1 ) T distance d ( p a , p i ) > T distance Δ t i 1 , a T time
d ( · , · ) is the Euclidean distance between two points. T distance is the distance threshold between two points. T time is the threshold of the difference in the timestamps between the two points. Δ t · , · is the time difference between two points.
In (10), the condition d ( p a , p i 1 ) T distance indicates that the trajectory remains within a spatial neighborhood centered at the candidate start point p a up to point p i 1 . The subsequent condition d ( p a , p i ) > T distance means that the newly arrived point p i lies outside this neighborhood; i.e., the object has just left the stay vicinity, and thus the stay interval ends at p i 1 . Finally, Δ t i 1 , a T time requires that the residence time within the neighborhood is at least T time , filtering out short stops (e.g., brief pauses) and ensuring that the detected interval corresponds to a meaningful stay.
Algorithm 1 shows SA satisfying the above condition, with SA being an online algorithm for extracting stay areas. In SA, whenever a new point p i arrives, the algorithm computes the distance d ( p a , p i ) between p i and the current monitoring start point, p a . If this distance remains below the distance threshold T distance , the user is likely to remain within the same local region and the monitoring process continues. Conversely, when d ( p a , p i ) exceeds the threshold, the previous point p i 1 is treated as a candidate end point of the stay interval, and the algorithm checks whether the duration of stay, computed as t i 1 t a , meets or exceeds the time threshold, T time . After processing the candidate interval, SA resets the monitoring start point to the current point p i and continues the same procedure for subsequent points.
Algorithm 1 SA ( d ( · , · ) denotes the Euclidean distance).
  • Require: Point stream { p i } , distance threshold T distance , time threshold T time
  • Ensure: Start point and end point of each stay area
      1:
    a 1
      2:
    for each newly arrived point p i  do
      3:
          if  d ( p a , p i ) T distance  then
      4:
              continue
      5:
          else
      6:
                if  t i 1 t a T time  then
      7:
                     output ( p a , p i 1 )
      8:
                 a i
      9:
    if  t i t a T time  then           ▹ Flush pending stay interval at stream end
    10:
          output ( p a , p i )

3.2. DOTS

DOTS is an online trajectory simplification method that incrementally determines an approximately optimal simplified trajectory by constructing a DAG. An overview of the DOTS is presented in Algorithm 2. In DOTS, each location point in the original trajectory is treated as a node, and a directed edge is added between two nodes only when the approximation error representing the segment with a straight line is below a predefined threshold, ε .
Algorithm 2 DOTS.
  • Require: Point stream { p i } , threshold ε , factor η , k = 1
  • Ensure: Simplified trajectory T
      1:
    Initialize V 1 = { p 1 } , k = 1 , α ( p 1 ) = 0 , d = 1
      2:
    while a new point p j arrives do
      3:
          for each p i V k  do
      4:
                if  p i T e r m k  then continue
      5:
                else if  LISSED ( p i , p j ) < ε  then
      6:
                      V k + 1 V k + 1 { p j }
      7:
                     add edge ( p i , p j )
      8:
                     break
      9:
                else if  LISSED ( p i , p j ) > η ε  then
    10:
                      T e r m k T e r m k { p i }
    11:
          if  T e r m k = V k  then
    12:
                Choose P a r e n t ( p j ) via Equation (15)
    13:
                Update α ( p j )
    14:
                 k k + 1
    15:
                 V k { p j }
    16:
                continue
    17:
          while  V d has exactly one alive node q do
    18:
                 T T q
    19:
                 d d + 1
    20:
    Backtrack remaining alive nodes and append the final path to T
A DAG is made up of two sets: the node set V and the edges set E. V contains all the points of T. For any pair of location points ( p i , p j ) with i < j , a directed edge ( p i p j ) is added if LISSED ( i , j ) , computed over the interval ( i , j ) , is smaller than ε .
E = ( p i p j ) | i < j , LISSED ( i , j ) < ε
As a result, a DAG is constructed from the trajectory, as illustrated in Figure 4.
For each node p j , the layer number is updated by
L ε ( p j ) = min i < j , LISSED ( i , j ) < ε L ε ( p i ) + 1
and the set of nodes belonging to the kth layer is defined as
V k = { p j L ε ( p j ) = k }
Through this layer construction, the DAG is incrementally extended as new points arrive.
The cumulative error of a node p j is computed using its parent node, P a r e n t ( p j ) , as follows:
α p j = α P a r e n t ( p j ) + LISSED ( P a r e n t ( p j ) , j ) .
The optimal parent of p j is then selected from the candidate nodes in the same layer by minimizing the cumulative error:
P a r e n t ( p j ) = arg min p i V k , LISSED ( i , j ) < ε α p i + LISSED ( i , j )
This process yields a locally optimal parent selection while maintaining the desired number of simplified points.
In the DAG, the nodes that remain reachable from subsequent layers are referred to as alive nodes. An alive node is defined as a point that retains the possibility of being included in the final simplified trajectory and whose parent–child relationships have not been pruned. When a layer contains a single alive node, that node is guaranteed to appear in the simplified trajectory. DOTS immediately outputs such a node as a confirmed simplified point, enabling online processing without waiting for the entire trajectory to be received. DOTS excludes nodes whose cumulative error exceeds η ε , thereby reducing any unnecessary edge generation and improving the efficiency of DAG construction. Using this mechanism, DOTS achieves practical computational performance while maintaining near-optimality guarantees.

3.3. DOTSSA

The overall procedure is presented in Algorithm 3. For each incoming point p i , the SA performs online stay area detection. When a stay area is detected, its starting point is used as a segmentation boundary to finalize the current buffered segment. DOTS is then applied to this segment to produce a locally simplified sub-trajectory; the resulting representative points are appended to the global simplified trajectory.
Algorithm 3 DOTSSA.
  • Require: Point stream { p i } , error threshold ε , stay thresholds ( T distance , T time )
  • Ensure: Simplified trajectory T
    1:
    T , B
    2:
    for each new point p i in the stream do
    3:
           B B { p i }
    4:
           ( p start , p end ) SA ( p i )
    5:
          if a stay area is detected then
    6:
                Extract S from B consisting of points from the head of B to p start
    7:
                 T T DOTS ( S )         ▹ DOTS ( S ) applies DOTS to all points contained in S
    8:
                Clear B
    9:
                 B { p end }
By repeating this process iteratively, DOTSSA achieves online trajectory simplification that preserves stay areas while incorporating the shape approximation provided by DOTS. DOTSSA effectively balances stay region preservation with geometric accuracy, enabling high-quality and computationally efficient trajectory simplification.

3.4. Time Complexity

This subsection provides an analysis of the time complexity of DOTSSA.
First, the SA performs a constant-time distance and dwell-time threshold check for each incoming point p i , and the cost of this check is O ( 1 ) . Therefore, if the number of input points is N, the computational complexity of SA is O ( N ) .
The computational complexity of DOTS is O N 2 L , where N denotes the number of points contained in the target segment and L represents the number of DAG layers. The worst-case complexity of DOTS is O ( N 2 ) , which occurs when ε is small and most points remain in the upper layers (e.g., most points remain in V 2 ), resulting in dense edge tests. On the other hand, the best-case complexity of DOTS is O ( N ) , which happens when ε is sufficiently large such that each layer contains only one node, making the processing nearly linear.
If DOTSSA detects S stay areas in the input trajectory, the overall computational complexity is expressed as follows:
O ( N ) + i = 1 S O N i 2 L i , where i = 1 S N i = N
Here, N i denotes the number of points contained in the i-th trajectory segment to which DOTS is applied and L i represents the number of layers in the corresponding DAG. Thus, the computational cost of DOTSSA is influenced by how the trajectory is segmented by stay area detection. As the number of detected stay areas S increases, the trajectory is divided into many smaller segments, effectively reducing each N i . In particular, in mobility trajectories where users tend to make frequent stops, such as at intersections, shops, and public transport stations, multiple stay areas are commonly observed. As a result, DOTSSA improves its efficiency significantly by processing each segment independently with a smaller computation size.
In the worst case, no stay area is detected and DOTS is executed only once over the entire trajectory. In other words, aside from the SA checks, DOTS is applied to the whole trajectory. In this case, S = 1 and N 1 = N , and therefore the computational complexity of DOTSSA becomes identical to that of DOTS:
O N 2 L
On the other hand, if the trajectory is split into many small segments due to frequent stay area detections, the size of each segment becomes close to a constant. In this scenario, the complexity of DOTSSA becomes linear:
O ( N ) + O N L = O ( N )
In summary, the computational complexity of DOTSSA depends on the number of stay areas contained in the trajectory, while its upper bound remains the same as that of DOTS. For real-world trajectories that often include multiple stay areas, DOTSSA frequently achieves near-linear time performance by dividing the trajectory into smaller sub-trajectories and performing efficient localized DAG construction.

4. Evaluation

Two experiments were conducted to evaluate the effectiveness of DOTSSA.
  • An evaluation under fixed error thresholds ε , focusing on a comparison with DOTS.
  • A comparison under controlled compression rates, in which the parameters of each method were tuned to achieve predefined rates and compared with multiple baseline methods.

4.1. Evaluation Conditions

All the experiments were conducted using the Microsoft GeoLife dataset [23,24,25], which covers various transportation modes, such as walking, driving, and trains. Trajectories were segmented whenever the interval between consecutive points exceeded 5 min; segments containing fewer than 100 points were removed from the dataset. After preprocessing, 39,162 trajectories remained. The average trajectory length was approximately 638 points and the median was 371 points; the average sampling interval was 3.1 s and the median was 2.0 s.
The stay area detection thresholds used in SA followed the batch-based method in [21]: the distance threshold T distance was set to 15 m and the time threshold T time to 30 s.
Simplification performance was evaluated using six metrics: PED error, SED error, SAD error, DAD error, compression rate, and compression time. The PED, SED, SAD, and DAD errors are computed as the average values of their respective error functions. The PED error is defined as follows:
PED Error = 1 | T | i = 1 | T | 1 R i j = 1 R i PED p c ( r i j ) , r i j , s c ( r i j )
where | T | is the number of trajectories, R i is the number of redundant points removed from the ith trajectory, and r i j is the jth redundant point. The functions, p c ( r i j ) and s c ( r i j ) , denote the first compressed points found by searching forward and backward from r i j , respectively. The other error metrics were defined analogously using their corresponding functions.
Because GPS points within stay areas (Figure 1) are often clustered densely and exhibit irregular fluctuations, including them in the error calculations can cause disproportionate distortion. To ensure a fair comparison, stay area intervals were excluded when computing the error metrics.

4.2. Comparison Result Under Fixed ε

DOTSSA and DOTS were compared while varying the error threshold ε within the range ε { 1.0 , 5.0 } × { 10 7 , 10 6 , 10 5 , 10 4 } .

4.2.1. Compression Time

As shown in Figure 5, DOTSSA consistently achieved a shorter compression time than DOTS across all settings, with the largest reduction (approximately 75%) observed at ε = 5 × 10 4 .
When ε is small (e.g., ε = 1.0 × 10 7 ), the compression time of DOTSSA is almost the same as that of DOTS. Under such strict error constraints, DOTS generates many layers, each containing only a few points, resulting in fewer LISSED computations within each layer. This keeps the computational cost low and reduces the compression time. Because DOTSSA also applies DOTS to the trajectory segments, its compression time remains similarly low, leading to comparable performance between the two methods.
In contrast, when ε becomes large (e.g., ε = 1.0 × 10 4 ), the compression time gap between DOTS and DOTSSA increases significantly. DOTS incorporates many points into a single layer, which increases the number of LISSED computations and thereby the overall compression time. On the other hand, DOTSSA segments the trajectory according to stay areas, reducing the number of points processed by each DOTS instance and enabling the construction of smaller DAGs. These results confirm that stay area-based segmentation and localized DAG construction allow DOTSSA to achieve higher computational efficiency than DOTS, particularly when the error tolerance is large.
In summary, DOTSSA achieves fast online trajectory simplification by effectively controlling the DAG size through stay area-based segmentation, allowing it to consistently outperform DOTS in computational efficiency across a wide range of error tolerance settings.

4.2.2. Compression Rate

In Figure 6, when ε is small, very few points can be removed under such a strict error bound, resulting in a low compression rate in DOTS, although the compression time remains small. Under such conditions, DOTSSA exhibits a slightly lower compression rate than DOTS. This is because DOTSSA always retains the points extracted by SA, as well as the start and end points of each segment. In addition, because DOTSSA applies DOTS separately to each segment, it tends to preserve more representative points overall. Consequently, DOTSSA may retain points that DOTS considers redundant, leading to a slightly lower compression rate.
In contrast, when ε becomes large, the compression rates of both DOTS and DOTSSA increase, since a larger ε allows more points to be omitted from the simplified trajectory. However, this also significantly increases the compression time of DOTS, as shown in Figure 6. By contrast, DOTSSA effectively suppresses this increase in execution time because stay area-based segmentation limits the number of points processed in each localized DAG construction.
Therefore, this outcome reflects a trade-off: while DOTSSA preserves stay area semantics at the expense of a slightly reduced compression rate, it nevertheless achieves faster execution than DOTS, demonstrating superior computational efficiency.

4.2.3. Error Metrics

As shown in Figure 7a–c, the difference between DOTS and DOTSSA in the spatial and temporal error metrics becomes more pronounced as ε increases, with DOTSSA exhibiting smaller errors. Although the compression rate decreases for larger ε values, as indicated in Figure 6, DOTSSA retains the boundary points of each stay area, which helps maintain slightly higher spatial fidelity than DOTS. Conversely, when ε is small, the compression rates of both methods are low, and thus the spatial and temporal characteristics of the trajectory are well preserved in both cases. These results reflect the trade-off between compression rate and the preservation of stay area information discussed earlier.
In contrast, DOTSSA yielded a larger DAD error (Figure 7d). Because stay areas contain many small directional fluctuations but SA preserves only their boundary points, the approximating segment can deviate from the true heading. As DAD is sensitive to directional changes, this omission may lead to an increased error.
Overall, DOTSSA substantially reduced computation time while maintaining competitive spatial and temporal accuracy relative to DOTS in most parameter settings. Although DOTSSA may yield slightly larger directional or speed-related deviations in certain cases, it consistently preserves stay area semantics and provides a practical balance between computational efficiency and trajectory fidelity under fixed ε .

4.3. Comparison Under Fixed Compression Rates

4.3.1. Compression Rate

This experiment compared DOTSSA with DOTS, OW, OWTR, and SQUISH-E( μ ) at fixed compression ratios of 0.1, 0.3, 0.5, 0.7, and 0.9. Because each method must be tuned to achieve the target rate, the parameter search was computationally expensive; thus, 1000 trajectories were randomly sampled for evaluation. DOTSSA and DOTS tuned the error threshold, ε ; OW tuned its PED threshold; and OWTR and SQUISH-E( μ ) tuned their SED thresholds.
DOTSSA outperformed DOTS in terms of compression time, particularly when the compression rate was high (Figure 8). Under such high-compression settings, the DAG construction cost in DOTS increases rapidly, whereas DOTSSA effectively suppresses the DAG size by segmenting the trajectory based on stay areas, leading to a significant performance advantage. This result indicates that the proposed method preserves the computational benefits of DOTS while greatly reducing the overhead associated with DAG expansion when strong compression is required.
OW and SQUISH-E( μ ) were consistently faster than DOTSSA across all compression rate settings. OW achieves its speed by recursively simplifying the trajectory using PED, which is computationally inexpensive. SQUISH-E( μ ) also offers fast processing because it simplifies trajectories using a queue-based heuristic and requires only local error checks, resulting in a low computational overhead. In contrast, OWTR is fast when the compression rate is low but becomes the slowest method when stronger compression is applied. This is likely due to OWTR recursively simplifying the trajectory while computing SED, which incurs a higher computational cost. However, none of these methods preserve stay area semantics, and they are not optimized for SED, which may lead to the loss of important semantic information in the trajectory.
Overall, the results in Figure 8 confirm that DOTSSA is a practical and efficient method that preserves stay area semantics while achieving superior compression speed compared with DOTS. The strong advantage under high-compression settings is particularly valuable for real-time applications and large-scale trajectory data processing.

4.3.2. Error Metrics

Figure 9a,b indicate that DOTSSA yields slightly smaller PED and SED errors than DOTS when the compression rate is below 0.7. For example, at a compression rate of 0.7, DOTSSA improves the PED and SED errors by approximately 13%. Moreover, DOTSSA achieves the smallest spatial errors among all the evaluated methods in this range. These results demonstrate that DOTSSA preserves stay area semantics while maintaining high spatial fidelity during trajectory simplification.
In contrast, at a compression rate of 0.9, DOTS produces lower PED and SED errors than DOTSSA, indicating that DOTS yields a more accurate approximation in this extreme compression regime. When the compression rate is 0.9, DOTSSA exhibits approximately 18% higher PED error and 21% higher SED error than DOTS. Because DOTS optimizes over the entire trajectory, including points within stay areas, it can freely select a very small set of representative points to minimize global error. DOTSSA, on the other hand, must always retain stay area boundary points and respect segment boundaries. Under a fixed high compression rate, these constraints force DOTSSA to discard more non-stay points and restrict its choice of anchor segments, resulting in larger overall approximation errors than DOTS. This observation shows that segmentation-based processing can make DOTSSA suboptimal when the compression rate is extremely high and only a few representative points are allowed.
Figure 9c shows that SQUISH-E( μ ) achieves the smallest SAD error among all methods because its SED-based local simplification strategy directly incorporates velocity information. In contrast, OW exhibits the largest SAD error because it relies solely on PED and fails to preserve temporal dynamics. DOTSSA, on the other hand, consistently produces smaller SAD errors than DOTS across a wide range of compression rates, particularly below 0.7. This demonstrates that its stay-area-aware segmentation enables more accurate reconstruction of temporal movement characteristics while still achieving efficient compression.
Similarly, Figure 9d demonstrates that DOTSSA yields the smallest DAD error when the compression rate is below 0.7. Because DAD is highly sensitive to directional changes along the trajectory, this result suggests that segment-wise DAG optimization in DOTSSA effectively limits unnecessary heading deviations, thereby improving directional consistency. However, none of the evaluated methods, including DOTSSA, are explicitly designed to preserve directional information. Therefore, the observed advantages should be regarded as secondary effects inherent to the method rather than guaranteed directional optimality. The development of direction-aware optimization techniques and mechanisms for explicitly preserving directional features remains for future work.
Table 1 summarizes the execution time and error metrics obtained by compressing trajectories with a given ε and selecting the results with compression rate of 0.9.
Compared with DOTS, DOTSSA consistently reduces the execution time across all ε settings. The reduction is particularly pronounced for ε = 1.0 × 10 6 and 1.0 × 10 5 : DOTS requires 0.015 s and 0.021 s, respectively, whereas DOTSSA completes in 0.008 s and 0.009 s, corresponding to an approximate 40–60% reduction. Furthermore, for ε = 1.0 × 10 4 , DOTSSA achieves 0.006 s compared with 0.023 s for DOTS, yielding a reduction of approximately 74%.
Regarding the error metrics, DOTSSA yields PED and SED values comparable to, or only marginally different from, those of DOTS, and SAD remains at a similar level overall. In particular, for ε = 1.0 × 10 7 , PED slightly decreases from 3.224 to 3.184 and SAD decreases from 2.875 to 2.835, indicating that DOTSSA maintains spatial and speed fidelity while reducing computation time. By contrast, DAD increases slightly for all ε values; however, the absolute increase is small (approximately 0.007–0.012 deg), suggesting that the degradation in directional accuracy is a limited trade-off relative to the achieved time reduction.
Overall, DOTSSA provides an effective trade-off between computational efficiency and simplification accuracy. It preserves stay area semantics while achieving faster processing and competitive errors compared with existing methods. These results demonstrate the practicality of DOTSSA as a method for real-time trajectory simplification in mobility analysis and location-based applications.

5. Conclusions

This paper presented DOTSSA, an online trajectory simplification method that integrates online stay area detection with the segment-wise application of DOTS. By partitioning input trajectories according to detected stay areas and then applying DOTS independently within each segment, DOTSSA preserves essential stay-related semantics while maintaining efficient computational performance. This design effectively ensures that meaningful behavioral information is retained without sacrificing the benefits of data reduction.
The experimental results show that DOTSSA substantially reduces compression time compared to DOTS, while maintaining lower spatial and temporal errors across a wide range of parameters. These findings demonstrate that DOTSSA provides a good balance between accuracy, compression efficiency, and semantic preservation. Therefore, DOTSSA is well-suited for real-time mobility analysis and large-scale location-based services that require fast processing and behavioral interpretability.
Future work will explore further optimization of the DAG construction process in DOTS to improve scalability for massive trajectory streams. In addition, we plan to extend DOTSSA by incorporating road network constraints and contextual knowledge to enhance spatial accuracy and semantic consistency, particularly in complex urban environments.
Moreover, with the recent proliferation of flight-capable devices such as drones, trajectories that include altitude information in addition to latitude and longitude are becoming increasingly common. Extending our approach to support the simplification of such 3D trajectories is therefore an important direction for future work. Adaptive parameter tuning and applying DOTSSA to emerging trajectory applications, such as intelligent transportation systems and autonomous navigation, represent additional promising directions for future research.

Funding

This research received no external funding.

Data Availability Statement

Conflicts of Interest

The author declares no conflicts of interest.

References

  1. Meratnia, N.; de By, R.A. Spatiotemporal Compression Techniques for Moving Point Objects. In Proceedings of the Advances in Database Technology, Heraklion, Greece, 14–18 March 2004; Springer: Berlin/Heidelberg, Germany, 2004; pp. 765–782. [Google Scholar]
  2. U.S. Department of Transportation. Highway Statistics Series. 2014. Available online: https://www.fhwa.dot.gov/policyinformation/statistics/2011/vm2.cfm (accessed on 19 January 2026).
  3. Han, Y.; Sun, W.; Zheng, B. COMPRESS: A Comprehensive Framework of Trajectory Compression in Road Networks. ACM Trans. Database Syst. 2017, 42, 11. [Google Scholar] [CrossRef]
  4. Hu, Z.; Huang, Z.; Yang, J.; Yang, T.; Jin, Y.; Xu, Y. TrajGEOS: Trajectory Graph Enhanced Orientation-based Sequential Network for Mobility Prediction. arXiv 2024, arXiv:2412.19092. [Google Scholar] [CrossRef]
  5. Deng, B.; Ji, L.; Chen, C.; Jing, X.; Ding, L.; Qu, B.; Wang, P.; Yang, D. STRelay: A Universal Spatio-Temporal Relaying Framework for Location Prediction with Future Spatiotemporal Contexts. arXiv 2025, arXiv:2508.16620. [Google Scholar]
  6. Wu, X.; Zhang, Z.; Wan, W. Travel route recommendation with a trajectory learning model. Complex Intell. Syst. 2024, 11, 12. [Google Scholar] [CrossRef]
  7. Jain, J.; Bagadia, V.; Manchanda, S.; Ranu, S. NeuroMLR: Robust & Reliable Route Recommendation on Road Networks. In Proceedings of the Advances in Neural Information Processing Systems, Virtual, 6–14 December 2021; Ranzato, M., Beygelzimer, A., Dauphin, Y., Liang, P., Vaughan, J.W., Eds.; Curran Associates, Inc.: Red Hook, NY, USA, 2021; Volume 34, pp. 22070–22082. [Google Scholar]
  8. Koh, Z.; Zhou, Y.; Lau, B.P.L.; Liu, R.; Chong, K.H.; Yuen, C. Clustering and Analysis of GPS Trajectory Data Using Distance-Based Features. IEEE Access 2022, 10, 125387–125399. [Google Scholar] [CrossRef]
  9. Guo, Y.; Yeung, C.Y.; Chan, G.C.H.; Chang, Q.; Tsang, H.W.H.; Yip, P.S.F. Mobility Based on GPS Trajectory Data and Interviews: A Pilot Study to Understand the Differences between Lower- and Higher-Income Older Adults in Hong Kong. Int. J. Environ. Res. Public Health 2022, 19, 5536. [Google Scholar] [CrossRef] [PubMed]
  10. Douglas, D.H.; Peucker, T.K. Algorithms for the reduction of the number of points required to represent a digitized line or its caricature. Cartogr. Int. J. Geogr. Inf. Geovisualization 1973, 10, 112–122. [Google Scholar] [CrossRef]
  11. Chen, M.; Xu, M.; Franti, P. A Fast O(N) Multiresolution Polygonal Approximation Algorithm for GPS Trajectory Simplification. IEEE Trans. Image Process. 2012, 21, 2770–2785. [Google Scholar] [CrossRef] [PubMed]
  12. Keogh, E.J.; Chu, S.; Hart, D.; Pazzani, M.J. An Online Algorithm for Segmenting Time Series. In Proceedings of the 2001 IEEE International Conference on Data Mining, San Jose, CA, USA, 29 November–2 December 2001; IEEE Computer Society: Washington, DC, USA, 2001; pp. 289–296. [Google Scholar]
  13. Trajcevski, G.; Cao, H.; Scheuermanny, P.; Wolfsonz, O.; Vaccaro, D. On-line data reduction and the quality of history in moving objects databases. In Proceedings of the 5th ACM International Workshop on Data Engineering for Wireless and Mobile Access, Chicago, IL, USA, 25 June 2006; Association for Computing Machinery: New York, NY, USA, 2006; pp. 19–26. [Google Scholar] [CrossRef]
  14. Muckell, J.; Hwang, J.H.; Patil, V.; Lawson, C.T.; Ping, F.; Ravi, S.S. SQUISH: An Online Approach for GPS Trajectory Compression. In Proceedings of the 2nd International Conference on Computing for Geospatial Research & Applications, Washington, DC, USA, 23–25 May 2011; Association for Computing Machinery: New York, NY, USA, 2011. [Google Scholar] [CrossRef]
  15. Muckell, J.; Olsen, P.W.; Hwang, J.H.; Lawson, C.T.; Ravi, S.S. Compression of trajectory data: A comprehensive evaluation and new approach. GeoInformatica 2014, 18, 435–460. [Google Scholar] [CrossRef]
  16. Cao, W.; Li, Y. DOTS: An online and near-optimal trajectory simplification algorithm. J. Syst. Softw. 2017, 126, 34–44. [Google Scholar] [CrossRef]
  17. Yu, Q.; Luo, Y.; Chen, C.; Zheng, X. Road Congestion Detection Based on Trajectory Stay-Place Clustering. ISPRS Int. J.-Geo-Inf. 2019, 8, 264. [Google Scholar] [CrossRef]
  18. Rouky, N.; Bousouf, A.; Benmoussa, O.; Fri, M. A spatiotemporal analysis of traffic congestion patterns using clustering algorithms: A case study of Casablanca. Decis. Anal. J. 2024, 10, 100404. [Google Scholar] [CrossRef]
  19. Liu, Y.; Kuai, C.; Liao, X.; Ma, H.; He, B.Y.; Ma, J. Semantic Trajectory Data Mining with LLM-Informed POI Classification. In Proceedings of the 2024 IEEE 27th International Conference on Intelligent Transportation Systems (ITSC), Edmonton, AB, Canada, 24–27 September 2024; pp. 207–213. [Google Scholar] [CrossRef]
  20. Ma, H.; Liao, X.; Liu, Y.; Jiang, Q.; Stanford, C.; Cao, S.; Ma, J. Learning universal human mobility patterns with a foundation model for cross-domain data fusion. Transp. Res. Part C Emerg. Technol. 2025, 180, 105311. [Google Scholar] [CrossRef]
  21. Iiyama, S.; Oda, T.; Hirota, M. SESA: Fast Trajectory Compression Method Using Sub-trajectories Segmented by Stay Areas. In Proceedings of the Advanced Data Mining and Applications, Brisbane, QLD, Australia, 28–30 November 2022; pp. 187–198. [Google Scholar]
  22. Zhang, D.; Ding, M.; Yang, D.; Liu, Y.; Fan, J.; Shen, H.T. Trajectory simplification: An experimental study and quality analysis. Proc. VLDB Endow. 2018, 11, 934–946. [Google Scholar] [CrossRef]
  23. Zheng, Y.; Li, Q.; Chen, Y.; Xie, X.; Ma, W.Y. Understanding mobility based on GPS data. In Proceedings of the 10th International Conference on Ubiquitous Computing, Seoul, Republic of Korea, 21–24 September 2008; Association for Computing Machinery: New York, NY, USA, 2008; pp. 312–321. [Google Scholar] [CrossRef]
  24. Zheng, Y.; Xie, X.; Ma, W. GeoLife: A Collaborative Social Networking Service among User, Location and Trajectory. IEEE Data Eng. Bull. 2010, 33, 32–39. [Google Scholar]
  25. Zheng, Y.; Zhang, L.; Xie, X.; Ma, W.Y. Mining interesting locations and travel sequences from GPS trajectories. In Proceedings of the 18th International Conference on World Wide Web, Madrid, Spain, 20–24 April 2009; Association for Computing Machinery: New York, NY, USA, 2009; pp. 791–800. [Google Scholar] [CrossRef]
Figure 1. Stay points and stay areas in trajectory data.
Figure 1. Stay points and stay areas in trajectory data.
Network 06 00008 g001
Figure 2. Error metrics for trajectory simplification: PED, SED, and DAD errors.
Figure 2. Error metrics for trajectory simplification: PED, SED, and DAD errors.
Network 06 00008 g002
Figure 3. Overview of DOTSSA.
Figure 3. Overview of DOTSSA.
Network 06 00008 g003
Figure 4. An example of trajectory simplification in DOTS and the corresponding DAG construction. The left side shows the input trajectory, with each circle representing a node. The dashed line represents the original time-ordered path, and the red polyline connecting the selected nodes ( 1 4 7 11 ) is the simplified trajectory. The right panel shows the DAG constructed from the left trajectory, where directed black edges are added according to Equation (11). The red directed path indicates the shortest path selected on the DAG, corresponding to the simplification result.
Figure 4. An example of trajectory simplification in DOTS and the corresponding DAG construction. The left side shows the input trajectory, with each circle representing a node. The dashed line represents the original time-ordered path, and the red polyline connecting the selected nodes ( 1 4 7 11 ) is the simplified trajectory. The right panel shows the DAG constructed from the left trajectory, where directed black edges are added according to Equation (11). The red directed path indicates the shortest path selected on the DAG, corresponding to the simplification result.
Network 06 00008 g004
Figure 5. Compression time for varying parameter ε .
Figure 5. Compression time for varying parameter ε .
Network 06 00008 g005
Figure 6. Compression rate for varying parameter ε .
Figure 6. Compression rate for varying parameter ε .
Network 06 00008 g006
Figure 7. Error metrics for varying parameter ε .
Figure 7. Error metrics for varying parameter ε .
Network 06 00008 g007
Figure 8. Compression time for compression rate.
Figure 8. Compression time for compression rate.
Network 06 00008 g008
Figure 9. Evaluation results for compression rate.
Figure 9. Evaluation results for compression rate.
Network 06 00008 g009
Table 1. Compression time and four error metrics at a fixed compression rate of 0.9 with a fixed parameter ε .
Table 1. Compression time and four error metrics at a fixed compression rate of 0.9 with a fixed parameter ε .
ε MethodTime [s]PED [m]SED [m]SAD [km/h]DAD [deg]
1.0 × 10 7 DOTS0.0103.2245.9632.8750.132
DOTSSA0.0073.1845.9862.8350.139
1.0 × 10 6 DOTS0.0156.86213.1184.2590.159
DOTSSA0.0086.79413.1644.1860.167
1.0 × 10 5 DOTS0.02114.39528.7805.9240.194
DOTSSA0.00914.25728.8565.7640.205
1.0 × 10 4 DOTS0.02331.97866.0457.6830.245
DOTSSA0.00630.54762.6787.2860.257
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Hirota, M. DOTSSA: Directed Acyclic Graph-Based Online Trajectory Simplification with Stay Areas. Network 2026, 6, 8. https://doi.org/10.3390/network6010008

AMA Style

Hirota M. DOTSSA: Directed Acyclic Graph-Based Online Trajectory Simplification with Stay Areas. Network. 2026; 6(1):8. https://doi.org/10.3390/network6010008

Chicago/Turabian Style

Hirota, Masaharu. 2026. "DOTSSA: Directed Acyclic Graph-Based Online Trajectory Simplification with Stay Areas" Network 6, no. 1: 8. https://doi.org/10.3390/network6010008

APA Style

Hirota, M. (2026). DOTSSA: Directed Acyclic Graph-Based Online Trajectory Simplification with Stay Areas. Network, 6(1), 8. https://doi.org/10.3390/network6010008

Article Metrics

Back to TopTop