1. Introduction
Multi-scale spatial representation has a wide range of applications, such as zooming in/out, and is among the most common operators in geographic information and online mapping systems [
1,
2,
3,
4]. Rendering spatial data at different scales also improves our understanding and analysis of spatial data, thereby meeting the continuous visual needs of modern map users. As essential geomorphic elements, contour lines are among the most often used data for describing the geographic information of the Earth’s surface [
5,
6,
7]. A simplification of these contour lines provides different levels of detail for linear features, which is an effective operator for maintaining essential shapes in multi-scale terrain maps [
1,
8,
9]. Although contour simplification methods have been investigated for a long time, studies on the continuous multi-scale representation of contour lines still face considerable limitations.
Various contour simplification methods have been proposed over the past few decades. These methods can mainly be divided into (1) reduction in point set [
10,
11,
12,
13,
14,
15], (2) bending simplification [
8,
16,
17,
18,
19,
20], and (3) scale-driven simplification [
9,
21,
22,
23,
24].
The first strategy, point set reduction, is a straightforward approach for achieving simplified polylines. The classical Douglas–Peucker (DP) algorithm [
10] introduced a pre-defined threshold for selecting a set of significant vertices recursively for simplification. However, the simplified contours seem stiff and may contain self-intersection and topological conflicts when dealing with dense contours for multi-scale simplification. To improve the DP algorithm, Saalfeld et al. [
12] utilized dynamic convex hull algorithms, neighborhood screening, and efficient measures of topological consistency between features to avoid potential topological conflicts. Wu et al. [
14] employed convex hull computations by partitioning a polyline into a set of separable star-shaped sub-polylines and applying the DP algorithm for each sub-polyline to avoid self-intersection along the recursive refinements. Pallero et al. [
15] proposed an enhanced simplification algorithm based on the DP algorithm to obtain robust results regardless of the morphology of the initial line. However, when simplifying dense contours, the above methods generate results with discontinuous deformation. Meanwhile, the essential shape features of simplified contours may shift or contain topological errors.
For the second strategy, bending simplification, Wang and Muller [
18] proposed the Wang–Muller (WM) simplification algorithm to maintain the structure of simplified bends based on size, shape, and context. Zhu et al. [
20] leveraged the furthest visibility principle to divide the bend area of the contour line and to maintain the main characteristics of simplified contours at the target scale without self-intersection. Ai et al. [
8] presented a simplified algorithm based on Delaunay triangulation and Perkal’s ε-circle rolling algorithm to preserve the essential bend of a polyline and maintain the area amid large-scale changes during the simplification process. However, these bend reduction methods for simplifying polylines focus on simplifying the local bend than the global structure continuity.
The third strategy, scale-driven simplification, has become popular in recent years. Li and Openshaw [
21] proposed a “natural principle” that can be employed to the overall shape simplification of linear features to address the stiff simplified results of the DP algorithm. Bertolotto and Egenhofer [
22] proposed a model that can be used to represent multi-scale maps and guarantee the consistency of generalized data in the simplification process. Nöllenburg et al. [
25] focused on polyline morphing at different scales and presented a dynamic programming algorithm with the corresponding linear features. Deng et al. [
23] proposed an improved morphing method for two linear features at different scales based on their entire structural information. Li et al. [
9] used simulated-annealing-based morphing (SABM) to implement continuous linear features generalization. Du et al. [
24] proposed a progressive simplification method based on multi-bend groups that can delete bend units as little as possible. This method has advantages in area preservation during the multi-scale representation. Liu et al. [
1] proposed a Fourier-based method using head/tail breaks that simplifies polylines via a Fourier approximation according to the global shape. These scale-driven simplification methods have advantages over the two aforementioned strategies (i.e., point set reduction and bending simplification). However, they lack domain-specific constraints in the scale-driven simplification process, thereby producing simplified results that do not completely follow the essential global structure of the initial line at continuous scales.
In sum, the three aforementioned simplification strategies still show limitations in continuous multi-scale representation. On the one hand, simplifications occur only through a few fixed scales. This problem makes it impossible to show data from one scale to another smoothly and ignores the actual morphological transformations of the contour line of desired scales between fixed scales. On the other hand, the local structures are overemphasized, and the global structures of linear characteristics are ignored during the simplification of continuous multiple scales, which may lead to a sudden change in the shape of the contour line (‘jumps’) during transformation. Given these limitations, this study proposes a novel contour simplification method to retain the global structure of linear characteristics and to implement a multi-scale deformation of contours continuously. This method is labeled the continuous changing surface model (CCSM) based on the notion of the level set method.
The core idea of the level set method [
26,
27] is that the motion of lower-dimensional (e.g., 2D) curves can be derived from a higher dimensional (e.g., 3D) surface. Accordingly, our simplification model derives 2D simplified contours from a meticulously constructed 3D surface labeled the continuous changing surface (CCS). According to the contour features, a CCS is established between two contours and is then intersected with a set of horizontal planes with continuous height values. The generated intersection lines are considered simplified contours with continuous scales. We also compare our proposed method with two traditional significant polyline simplification methods on a real contour dataset in China to validate the effectiveness of CCSM. Results show that the shape changes of contours simplified by CCSM are natural and continuous between scales and that the CCSM maintains the global shape features much better than the other two classical significant simplification algorithms.
The major original contributions of this study are twofold. First, we propose the CCSM simplification method guided by the level set framework to derive simplified contours with continuous multi-scale transformation, thereby reducing the loss of deformed details during the continuous multi-scale simplification process. Second, we propose a new contour deformation analysis method, namely, a shape similarity-scale trend line based on the improved Fréchet distance, which provides a tool for evaluating the performance of multi-scale polyline simplification methods.
The rest of this paper is organized as follows.
Section 2 elaborates on the proposed method.
Section 3 describes the experiment using the contour dataset and reports the results.
Section 4 discusses two key factors affecting the quality of CCSM, the arbitrary scale simplification, and the retention of topographical features.
Section 5 concludes the paper.
2. Methodology
The CCSM methodological framework was proposed for global continuous multi-scale contour simplification. The main idea of this framework is to derive 2D contours from a 3D surface by using the level set method. The 3D surface was constructed by the non-uniform rational B-spline (NURBS), a common mathematical form for representing standard analytical shapes and free-form curves/surfaces [
28,
29]. The built 3D surface, namely, the continuous changing surface (CCS), was used to guide the entire simplification process. The framework consists of the following main steps as shown in
Figure 1:
(1) Extracting characteristics. The extraction of contour characteristics aims to preserve the global morphology features of simplified contour lines. These characteristics include characteristic points, characteristic sub-polylines, and characteristic links. To define CCSM constraints, the most significant morphology feature points in the shape were extracted from the initial contour to form a target contour by using the DP algorithm. The initial and target contours were converted into NURBS curves, and the two contour lines were assigned two height values. Accordingly, the NURBS curves were segmented into characteristic sub-polylines based on the characteristic points. Characteristic links were then constructed by linking the characteristic points of these two curves in order.
(2) Building the CCS. The extracted characteristics were used to weave a wireframe (WF) that constrains the construction of the CCS. Faced with this constraint, the CCS was built by using the NURBS function.
(3) Generating global continuous multi-scale simplified contours. First, the CCS was converted into a triangle mesh (CCS-mesh), which was then intersected with a set of horizontal planes with continuous height values. The generated intersection lines served as global continuous multi-scale simplified contours.
2.1. Extracting Characteristics
Linear features are considered basic elements in maps and suitable features that need to be retained during multi-scale transformation [
23]. Therefore, when constructing the CCS, the optimum extraction of morphology characteristics and the constraint of characteristics are critical to obtain the final global continuous multi-scale simplified results. The characteristics of CCS include characteristic points, characteristic sub-polylines, and characteristic links.
(1) Characteristic points. The boundary of the CCS needs to be constructed with the initial contour and the target contour . represents the initial contour with a large scale, whereas represents the target contour with a small scale. These two contours served as boundaries for building the CCS.
(2) Characteristic sub-polylines.
and
were resampled via equidistant sampling to ensure that they have the same number of points. To maintain the morphology shape of the contour line, the number of resampling points should exceed the number of characteristic points extracted from the initial contour. All resampling points were considered characteristic points. Then, two NURBS curves (
and
) were defined using the characteristic points from
and
, respectively. It is worth noting that
are highly similar in shape and size, as are
. Meanwhile, the B-spline curve was built based on the control points
, which are the characteristic points of
or
, where
represents the number of characteristic points of
or
. Generally, the NURBS curve (
) is defined over the knot
vector as Equation (1).
where
is the B-spline base function of order
(where
is set to 3), which is represented as Equation (2).
Accordingly, the characteristic sub-polylines of and were obtained based on these characteristic points.
(3) Characteristic links. The direct lines in a sequence linked the characteristic points. These links represent the correspondence relationship between the characteristic points of and , and are thereby labeled characteristic links.
In sum, as shown in
Figure 2, the characteristic points, characteristic sub-polylines, and characteristic links were used as feature constraints that are inherited from the initial and target contours to constrain the global continuous multi-scale simplification process. To build the CCS in the 3D space,
and
were assigned the bottom and top height values of CCS.
and
correspond to the height values of
and
, respectively. Accordingly, the characteristic points, characteristic sub-polylines, and characteristic links on
and
also inherit the height values
and
.
2.2. Building The CCS
2.2.1. Level Set Method
Osher and Sethian proposed the level set method [
26], whose main idea is to raise some computations in lower dimensions to a higher one and consider the N-dimensional description as a level of N+1 dimensions, which is an effective implicit representation of curves and surfaces [
26,
27]. In other words, the motion of lower-dimensional (e.g., 2D) curves can be derived from a higher-dimensional (e.g., 3D) surface, thereby allowing the derivation of 2D simplified contours from the 3D surface. The implicit function is essential in guiding the motion of curves on the surface. Based on the notion of the level set method, the NURBS function was selected in this study as an implicit function to generate CCS.
2.2.2. Building the CCS Based on Characteristics
To constrain the shape change of the contour during the simplification process, the CCS was built based on characteristics. The CCS building process was divided into three steps.
Step 1. Setting characteristics in the 3D space. As described in
Section 2.1, all the characteristic points, characteristic sub-polylines, and characteristic links on
and
inherit the height values from
and
.
Step 2. Building a wireframe (WF) from 3D characteristics. As shown in
Figure 3, four points were sampled on each characteristic link with equal intervals to construct a third-order NURBS surface uniformly. These points were merged into the constraints of characteristics, which act together during the construction of the WF.
Step 3. Constructing the CCS based on the WF. By using the NURBS function, the CCS was constructed in consideration of the WF constraints as shown in Equation (3).
where
indicates the operator of acquiring the NURBS surface by the constraints of
, which is defined as Equation (4).
where
represent the points on
,
represents the number of characteristic points of
, which is the same as that of
,
represents the number of points on characteristic links and
is set to 4,
represents the corresponding weight of
, and
and
are the normalized B-spline base functions of orders
and
, respectively (both
and
are set to 3,
) and are defined over knot vectors
and
. Based on these knot vectors, the following matrix
was obtained. As shown in Equation (5).
As shown in
Figure 4, a NURBS surface is constructed, which is referred to as the CCS in this study. The CCS plays a vital role in guiding the global continuous contour simplification process.
2.3. Generating Global Continuous Multi-Scale Simplified Contours
2.3.1. Generation of Simplified Contours
Contour lines are essential parts of a terrain model. In terrain modeling, multiple levels of contours can be modeled on the 3D surface, and each contour depicts a terraced representation of the 3D surface at an elevation level. To obtain simplified contours, the CCS was intersected with a set of horizontal planes with successive height values to generate intersection lines. These intersection lines were taken as global continuous multi-scale simplified contours with varying simplification degrees of the initial contour.
To calculate the intersection lines between CCS and a set of horizontal planes, the CCS was tessellated into a polygonal mesh (e.g., triangle or quadrangle), that is, the
, values of NURBS were mapped to the corresponding grid points of the polygonal mesh. The triangle mesh was used to generate a polygonal mesh due to its advantages in the rapid generation and its intersection with planes. As shown in
Figure 5, the triangle mesh comprises a set of triangular faces covering CCS and was therefore labeled CCS-mesh. This mesh may become irregular due to the uneven distribution of unconstrained sample grid points. To ensure the stability and convergence of the numerical solution, a suitable mesh generation technique should be applied to construct the appropriate surface mesh and to maintain a well-defined mesh that fits well in the CCS throughout the intersection process.
Based on the CCS-mesh, we built a set of equidistant horizontal planes to intersect the CCS-mesh and the intersection lines that are regarded as simplified intermediate results. As defined in Equation (6) below, the result of every horizontal plane intersecting the CCS-mesh is an intersection line
. The height
corresponds to each horizontal plane and is between the elevations of
and
. An intersection contour cluster was obtained by iterating the intersection between CCS-mesh and every horizontal plane. These intersecting lines were considered simplified contour lines. The scale corresponding to these simplified contour lines continuously varied between the scales of the initial and target contours.
Figure 6 presents an example of the simplified intermediate results generated by the CCS-mesh intersecting with a set of horizontal planes.
Figure 6a represents a set of equidistant horizontal planes with continuous elevation;
Figure 6b shows the intersection between the CCS-mesh and planes;
Figure 6c illustrates the global continuous multiscale transformation of intersection lines. Each intersection line between the CCS-mesh and a horizontal plane captured the morphology characteristics of contours at a certain height level. Therefore, this cluster of simplified contours preserves the morphology characteristics corresponding to the continuously changing scales between the initial and target contours. The location or number of horizontal planes can be determined based on the desired scale simplified results or the number of simplified contours demanded by users.
2.3.2. Estimation of the Scales for the Simplified Contours
As a general rule, in cartographic generalization, the shape similarity of a contour should correspond to its scale value. The contour lines with complex shapes have a large scale, whereas those lines with simple shapes have a small scale. When the topographic map was simplified from large to small scale, the shape of contour lines on the topographic map also changed from complex to simple [
30]. According to Li [
31], similarity is a measure that has been widely used to analyze the shape relationship of topographical objects. In this subsection, the shape similarity between the simplified and initial contours was used as an intermediary to estimate the scale of an arbitrary simplified contour.
The shape similarity between two curves is often defined based on a specific distance measure [
32]. One common metric of curve similarity is the Fréchet distance, which takes the flow of two curves into account and the pairs of points whose distance contributes to the Fréchet distance sweeping continuously along the respective curves [
33]. However, the uneven distribution of the points of a polyline may affect the accuracy of the distance of this polyline [
34]. To deal with such an uneven distribution, we proposed an improved Fréchet distance method based on equidistant resampling points to precisely reflect the shape similarity between two contour lines [
35].
First,
represents the simplified contour corresponding to the horizontal plane with a height value of
. The points on the simplified contour
were resampled via equidistant sampling, and the number of resampling points was similar to that in
. The initial contour line is
, where
is a metric space and
is a positive integer. The sequence
of the characteristic points of the characteristic sub-polylines of
was denoted by
.
was defined similar to
. Let
and
be the corresponding sequences. A coupling
between
and
represents a sequence
of distinct pairs from
, where
and
denote the number of characteristic sub-polylines on the two contour lines. Therefore, the coupling should follow the order of points in
and
. The number of points here refers to the number of characteristic points. The length
of coupling
represents the length of the longest link in
as shown in Equation (7).
Given two contour lines
and
, their improved Fréchet distance is defined as Equation (8). This distance index can provide a basis for accurately capturing the similarity of the two contour lines.
Then, the similarity between
and
is defined as Equation (9) based on the improved Fréchet distance.
where
represents the improved Fréchet distance between contours
and
, and
represents the length of
. Note that
and
.
To reveal the correspondence between shape similarity and scale, we used an exponential regression function to fit the ideal relationship between the similarity of contours and scale [
36,
37]. Ideally, as the scales changed continuously from large to small, the shapes of the contour lines were transformed from complex to simple, and the similarity value gradually changed from large to small. As shown in
Figure 7, the relationship between the contour scales and similarity values was fitted with an exponential regression function. The horizontal axis represents the scale, whereas the vertical axis represents the similarity value between the initial large-scale contour lines and the other small scales. As shown in
Figure 7, the trend of the relationship between the similarity values and scale is continuous and monotonic in the ideal case.
The transitions of gradual simplification from to were emulated by the intersections of the CCS-mesh and the horizontal plane. To generate a simplified contour cluster from to , each horizontal plane was assigned the height value in the equal interval sequence. Given that the relationship between the scale and similarity of different scale contours can be fitted with an exponential regression function and that the trend is continuously monotonic, according to Equation (9) and based on the similarities derived by values, an interpolation function was formulated to characterize the transition. is a scaling parameter with values ranging from to that can be used to bridge the continuous scales between and by mapping . By referring to the scales of and , can be linearly converted into common actual scales. When is , the scale is the initial scale of , but when is , the scale is the target scale of . In turn, the contour cluster can be ordered by . According to the interpolation function , the arbitrary scale of the simplified contours can be determined by the value and its corresponding value. In sum, each simplified contour has a determined scale and similarity with . Therefore, the proposed method can achieve arbitrary scale simplification.
5. Conclusions
This study proposed the CCSM method for contour simplification based on the NURBS surface between the initial and target contours with a feature constraint. A set of horizontal planes with equidistant height values was intersected with CCSM to obtain global continuous multi-scale simplified contours.
The CCSM method proposed in this paper can support continuous multi-scale contour simplification while maintaining the essential global structure. Compared with the classical DP and WM algorithms, CCSM can provide simplified contours with better continuity and consistency. This study also proposed a shape similarity–scale trend line based on the contour deformation analysis method that can be used to evaluate the performance of multi-scale polyline simplification methods.
Two problems still need to be studied in depth in future work. First, CCSM consumes much time in surface construction, thereby suggesting that this method needs to be optimized further. Second, a more general form of the relationship between the contour scale and the height value of the horizontal plane for an arbitrary type contour should be explored.