International Journal of Geo-Information

Article Identifying Complex Junctions in a Network

Jianting Yang 1 , Kongyang Zhao 1, Muzi Li 2, Zhu Xu 1,3,* and Zhilin Li 1,3

1 Faculty of Geosciences and Environment Engineering, Southwest Jiaotong University, Chengdu 611756, China; [email protected] (J.Y.); [email protected] (K.Z.); [email protected] (Z.L.) 2 Faculty of Geography and Resource Sciences, Sichuan Normal University, Chengdu 610066, China; [email protected] 3 National Collaborative Innovation Center for Rail Transport Safety, Southwest Jiaotong University, Chengdu 611756, China * Correspondence: [email protected]

Abstract: Automated generalization of road network data is of great concern to the map general- ization community because of the importance of road data and the difficulty involved. Complex junctions are where meet and join in a complicated way and identifying them is a key issue in road network generalization. In addition to their structural complexity, complex junctions don’t have regular geometric boundary and their representation in spatial data is scale-dependent. All these together make them hard to identify. Existing methods use geometric and topological statistics to characterize and identify them, and are thus error-prone, scale-dependent and lack generality. More significantly, they cannot ensure the integrity of complex junctions. This study overcomes the obstacles by clarifying the topological boundary of a complex junction, which provides the basis for straightforward identification of them. Test results show the proposed method can find and isolate complex junctions in a road network with their integrity and is able to handle different road representations. The integral identification achieved can help to guarantee connectivity among roads when simplifying complex junctions, and greatly facilitate the geometric and semantic simplification of them.

Keywords: generalization; scale; topological relationship; road network; pattern recognition  

Citation: Yang, J.; Zhao, K.; Li, M.; Xu, Z.; Li, Z. Identifying Complex 1. Introduction Junctions in a Road Network. ISPRS Int. J. Geo-Inf. 2021, 10, 4. https:// Map generalization is a special variant of spatial modelling, which involves deriving dx.doi.org/10.3390/ijgi10010004 a less detailed spatial representation from a detailed one and was traditionally performed manually by cartographers [1]. In digital environment, generalization of spatial data is the Received: 13 October 2020 basis of constructing multiscale representations in spatial databases and is highly desired Accepted: 21 December 2020 to be automated [2,3]. Published: 24 December 2020 Generalization demands highly intelligent processing of spatial data and is very diffi- cult to automate in general [1,4]. Great effort has been made to its automation in the past Publisher’s Note: MDPI stays neu- half century [5]. In the last three decades, significant progress has been made on transform- tral with regard to jurisdictional claims ing data representation [6,7], enriching data semantics [5,8], and developing intelligent in published maps and institutional algorithms [9–11]. Some of the achievements have been applied in data production [12,13]. affiliations. Generalization of road network data has been among the greatest concern of general- ization researchers and practitioners due to the importance of road data and the difficulty involved [6,14,15]. Lots of research have been carried out on road selection [16–18], analysis of

Copyright: © 2020 by the authors. Li- patterns in road networks [19–21], and techniques for enriching road data semantics [22–24]. censee MDPI, Basel, Switzerland. This This study is particularly concerned with the identification of complex junctions in article is an open access article distributed a road network. Complex junctions are where roads meet and join in a complicated way, under the terms and conditions of the and properly simplify them is a key issue in road network generalization [25–27]. Unlike Creative Commons Attribution (CC BY) simple planar junctions, such as crossings and T-junctions where major roads directly license (https://creativecommons.org/ intersect by themselves, complex junctions can be planar ones with slip roads for smooth licenses/by/4.0/). turning and can be grade-separated interchanges with ramps for bridging gaps in height.

ISPRS Int. J. Geo-Inf. 2021, 10, 4. https://dx.doi.org/10.3390/ijgi10010004 https://www.mdpi.com/journal/ijgi ISPRS Int. J. Geo-Inf. 2021, 10, 4 2 of 17

What is more, they can be very complex in structure and twisted in shape. To simplify the representation of such junctions without breaking the connectivity among the relevant roads, it is necessary to first identify them precisely in the network of roads [25,26]. Identifying complex junctions in a road network has been shown to be quite chal- lenging by previous studies due to the difficulties in definitely characterizing them and ascertaining their boundary in the network [21,27]. Mackaness and Mackechnie [25] char- acterized complex junctions as where nodes of road are dense and proposed a density analysis approach to detecting them. By carefully tuning the density threshold, complex junctions as a collection of densely clustered nodes could be identified, although blocks might be wrongly included as well. Savino et al. [23,26] noticed node den- sity did not work in some cases. They used statistics of redundant circles (or loops in topological terms) to characterize different forms of complex junctions and tried to detect them by searching for such circles in a road network. Touya [19] applied the method of Grosso [28] to detect interchanges. Their method is similar to that of Mackaness and Mackechnie [25]. But, instead of ordinary intersection nodes, they used fork and y-nodes which were considered more characteristic of highway interchanges. Similarly, Zhou and Li [27] took a complex junction as a collection of simple junctions, including T-, fork and crossing junctions etc. Like Savino et al. [23,26], they attempted to characterize and detect different forms of complex junctions with their compositional statistics of the simple junctions. As can be seen, existing methods are all based on statistical analysis of geometric and topological properties of complex junctions. They therefore suffer from the problem of threshold setting. Real world complex junctions vary greatly in node density, enclosed shape and size, and structural form. Thresholds of them inevitably vary from area to area and city to city due to spatial heterogeneity. What is more, there was no definition of the boundary of a complex junction included in those methods. Therefore, they cannot identify complex junctions with their integrity, as the boundary would change with the thresholds used. Further, junction representation is scale-dependent. A change from single-line representation of roads to dual-line one can make a complex junction very different in geometry and topology. Currently, no known methods deal with such scale- dependence explicitly. We took a structural pattern approach to identifying complex junctions. According to the domain knowledge of junction design [29,30], complex junctions are those having secondary roads, such as slip roads and ramps, to help primary roads join smoothly. In that sense, a complex junction can be structurally defined in topological terms no matter how complicated it is. That definition opens a gate to a straightforward way to identify complex junctions. The rest of this paper is organized as follows. From the perspective of road and junction design, Section2 formalizes a structural pattern of complex junctions, which characterizes them in a scale-independent way and defines the exact topological boundary of them. A simple algorithm based on that pattern is then proposed for identifying complex junctions in Section3. In Section4, experimental test of applying the method to a challenging case of real-world road network and a comparison between this method and a conventional one are presented. The influences of errors in input data on the identification are discussed in Section5. In Section6, scale-dependence during identifying complex junctions and relation between primary-secondary roads and road network generalization are discussed. Finally, conclusions are drawn in Section7.

2. Topological Boundary of a Complex Junction As analyzed above, more essential characteristics of complex junctions need to be revealed to provide more effective basis for identifying them. We turn to the domain knowledge of road and junction design and formulate a topological definition of the complex junction. ISPRS Int. J. Geo-Inf. 2020, 9, x FOR PEER REVIEW 3 of 23

and ramps, to help primary roads join smoothly. In that sense, a com- plex junction can be structurally defined in topological terms no matter how complicated it is. That definition opens a gate to a straightforward way to identify complex junctions. The rest of this paper is organized as follows. From the perspective of road and junction design, Section 2 formalizes a structural pattern of complex junctions, which characterizes them in a scale-independent way and defines the exact topological boundary of them. A simple al- gorithm based on that pattern is then proposed for identifying complex junctions in Section 3. In Section 4, experimental test of applying the method to a challenging case of real-world road network and a com- parison between this method and a conventional one are presented. The influences of errors in input data on the identification are discussed in Section 5. In Section 6, scale-dependence during identifying complex junctions and relation between primary-secondary roads and road net- work generalization are discussed. Finally, conclusions are drawn in Section 7.

2. Topological Boundary of a Complex Junction As analyzed above, more essential characteristics of complex junc- tions need to be revealed to provide more effective basis for identifying them. We turn to the domain knowledge of road and junction design and formulate a topological definition of the complex junction. ISPRS Int. J. Geo-Inf. 2021, 10, 4 According to the principles of road and junction design [29–32], 3 of 17 two types of roads can be differentiated in a road network system, the primary ones and the secondary ones. Primary roads (or major roads in the commonAccording sense) to the serve principles to link places of road distributed and junction over design geographic [29–32 ], two types of roads space.can In be contrast, differentiated secondary in a road roads network such as system, slip roads the and primary ramps ones serve and the secondary ones. to linkPrimary primary roads roads (or major and help roads them in the join common more smoothly sense) serve than to linkin the places distributed over directgeographic intersection space. way In to contrast, increase secondary throughput roads at suchtheir asjoints. slip roadsIn other and ramps serve to link words,primary secondary roads androads help are them dependent join more on smoothlyprimary roads. than inThese the directtwo intersection way to kindsincrease of roads throughput are illustrated at their in Figure joints. 1 Inwith other a schematic words, secondary road network roads are dependent on T. Roadsprimary in roads.T are labeled These twofor easy kinds reference. of roads Those are illustrated in light or in dark Figure grey,1 with a schematic road i.e.,network a–j, are T.primary Roads inones, T are and labeled those for in easy black, reference. i.e., k–p, Those are secondary in light or dark grey, i.e., a–j, are ones.primary With ones,the roads and thoseso classified, in black, the i.e., composition k–p, are secondary of a complex ones. With junc- the roads so classified, tionthe becomes composition conceptually of a complex clear. Two junction dashed becomes circles conceptuallyare drawn around clear. Two dashed circles theare two drawn complex around junctions the two in Figure complex 1 to junctions make their in Figure composition1 to make more their composition more explicit.explicit. It should It should be beclear clear that that a complex a complex junction junction consists consists of ofa agroup group of secondary roads of secondarytogether with roads the together relevant with primary the relevant roads that primary make theroads former that make connected to the rest roads. the former connected to the rest roads.

Figure 1. A schematic road network T for illustrating primary roads, secondary roads, and complex junctions.

The above conception of complex junctions needs to be formalized to be rigorous and made computable. To do so, we transform the ordinary segment-based representation of a road network to a stroke-based representation, and further on to a dual topological representation (or dual network for brevity). The concept of road stroke was proposed by Thomson and Richardson [33], which refers to a concatenation of road segments according to the principle of good continuity. Intuitively, instead of road segment it is road stroke that naturally corresponds to the concept of road in everyday use. The road stroke has been widely accepted and used in road network analysis since its proposed [18,19,32]. In fact, the labels in Figure1 are those of road strokes instead of road segments. Therefore, the road network T in Figure1 used the stroke-based representation. The dual network of a stroke-based road network is widely used in topological analysis of road networks [34–36]. In the dual network, a road is turned into a node and there is an edge between two nodes if the two roads they represent intersect. To illustrate, the dual network of road network T shown in Figure1 is presented in Figure2. As can be seen, each road in Figure1 is now a node in Figure2. In addition, there is an edge between two roads (i.e., nodes) if they intersect. In Figure1, the intersection relationship among roads is indicated by the line colors. Generally, if two lines intersect, the two roads they represent intersect. Exceptions are the cases in which a light grey line intersects with a dark grey line. In other words, road a does not intersect either road f or g, and neither does b. Therefore, the dual network of T is like that shown in Figure2, where there are not edges between a and f, a and g, b and f, and b and g. ISPRS Int. J. Geo-Inf. 2020, 9, x FOR PEER REVIEW 4 of 23

Figure 1. A schematic road network T for illustrating primary roads, second- ary roads, and complex junctions.

The above conception of complex junctions needs to be formalized to be rigorous and made computable. To do so, we transform the ordi- nary segment-based representation of a road network to a stroke-based representation, and further on to a dual topological representation (or dual network for brevity). The concept of road stroke was proposed by Thomson and Richardson [33], which refers to a concatenation of road segments according to the principle of good continuity. Intuitively, in- stead of road segment it is road stroke that naturally corresponds to the concept of road in everyday use. The road stroke has been widely ac- cepted and used in road network analysis since its proposed [18,19,32]. In fact, the labels in Figure 1 are those of road strokes instead of road segments. Therefore, the road network T in Figure 1 used the stroke- based representation. The dual network of a stroke-based road network is widely used in topological analysis of road networks [34–36]. In the dual network, a road is turned into a node and there is an edge between two nodes if the two roads they represent intersect. To illustrate, the dual network of road network T shown in Figure 1 is presented in Figure 2. As can be seen, each road in Figure 1 is now a node in Figure 2. In addition, there is an edge between two roads (i.e., nodes) if they intersect. In Figure 1, the intersection relationship among roads is indicated by the line colors. Generally, if two lines intersect, the two roads they represent intersect. Exceptions are the cases in which a light grey line intersects with a dark grey line. In other words, road a does not intersect either road f or g, ISPRS Int. J. Geo-Inf. 2021, 10, 4 and neither does b. Therefore, the dual network of T is like that shown 4 of 17 in Figure 2, where there are not edges between a and f, a and g, b and f, and b and g.

Figure 2. The dual network of the schematic road network T and the topological boundary of complex Figure 2. The dual network of the schematic road network T and the topologi- junctions depicted in Figure1. cal boundary of complex junctions depicted in Figure 1. In the dual network of the stroke-based representation of a road network, a complex junctionIn the candual be network defined asof athe group stroke-based of nodes ofrepresentation secondary road of isolateda road from the rest of the network,road network a complex by the junction relevant can nodes be defined of primary as a group road, whichof nodes the of former sec- serves to connect or ondarydepend road on. isolated That is clearfrom inthe Figure rest of2, the where road nodes network of secondary by the relevant road are purposely greyed nodesto indicate of primary they road, are ‘bounded’ which the byformer the relevant serves to primary connect roads. or depend Two dashed ellipses are ISPRS Int. J. Geo-Inf. 2020, 9, x FOR PEER REVIEW 5 of 23 on.drawn That is to clear make in explicit Figure the2, where topological nodes boundaries of secondary of theroad two are complex pur- junctions, which poselyotherwise greyed might to indicate not be apparent.they are ‘bounded’ As can be seen,by the nodes relevant of secondary primary road, say (k, l, m, n), cannot be reached from the secondary roads without passing through roads.are blockedTwo dashed from ellipses the rest ofare the drawn network to make by the explicit relevant the nodestopological of primary road, i.e., (a, b, the primary roads they serve, and the latter constitute the topological boundariesf, g). In other of the words, two complex the rest ofjunctions, the road which network otherwise cannot bemight reached not from the secondary boundary of a complex junction. Reversely, the interior secondary be roadsapparent. without As can passing be seen, through nodes the of primary secondary roads road, they say serve, (k, l, and m, n), the latter constitute the roads of a complex junction cannot be reached from the roads external aretopological blocked from boundary the rest of of a the complex network junction. by the Reversely, relevant nodes the interior of pri- secondary roads of a to the junction without passing through its boundary primary roads. marycomplex road, junctioni.e., (a, b, cannot f, g). In be othe reachedr words, from the the rest roads of externalthe road to network the junction without passing through its boundaryThe primary topological roads. boundary of a complex junction provides an ap- The topologicalproach boundaryto generalize of a the complex complex junction junction provides by properly an approach discarding to generalize its the complex junctioninterior bysecondary properly roads. discarding Figure its 3 interiorshows an secondary example roads. to illustrate Figure 3this shows an example togeneralization illustrate this generalizationprocess by simplifying process by the simplifying complex thejunctions complex in junctions the in the schematicschematic road network road network T in Figure T in 1Figure. The complex1. The complex junctions junctions are generalized are gen- by discarding the nodes of secondary road, i.e., (k, l, m, n, o, p), but preserving the connectivity between the boundary primary roads served by the discarding ones.

(a) (b)

(c)

Figure 3. (a–Figurec) The process 3. (a–c) of The generalization process of generalization of complex junc of complextion by junctiondiscarding by the discarding interior the secondary interior secondary roads. roads.

It is worth emphasizingIt is worth emphasizing that the above that definition the above is adefinition purely topological is a purely onetopo- and is thus inherentlylogical scale-independent. one and is thus That inherently means itscale-independent. works no matter how That complicated means it or works no matter how complicated or simple the complex junction is. That also means it works no matter a road is represented by a single line, dual lines or even multiple lines. The case of dual-line representa- tion is illustrated in Figure 2. For the pairing lines a and b of a in Figure 1, we can logically take them as a composite node A in the dual network as shown in Figure 2. Similarly, f and g make another composite node F. In addition, as the definition includes an ex- act topological boundary of a complex junction, it can thus be applied to identify complex junctions with their integrity, as explained below.

3. Algorithm of Identifying Complex Junctions The process of finding and isolating a complex junction in the dual network starts with a seed node of secondary road (sd) and then con- tinues by expanding the found part till the boundary is reached. More specifically, the algorithm proceeds as follows: (1) Global initialization: concatenate road segments into strokes. Derive the primary-or-secondary type of roads and pair counterparts. By transform to the dual network, take the set of nodes of secondary road (SG). Prepare an empty set (J) to collect complex junctions to be found. If SG is empty, return J and quit. Otherwise, mark all nodes in ISPRS Int. J. Geo-Inf. 2021, 10, 4 5 of 17

ISPRS Int. J. Geo-Inf. 2020, 9, x FOR PEER REVIEW 6 of 23 simple the complex junction is. That also means it works no matter a road is represented by a single line, dualSG as lines unprocessed. or even multiple The global lines. initialization The case of dual-lineof the schematic representation road net- is illustrated in Figurework2. For T shown the pairing in Figure lines a 4. and SG b corresponds of a dual carriageway to the set in of Figure secondary1, we can logically takeroads, them asi.e., a composite(k, l, m, n, o, node p). A in the dual network as shown in Figure2. Similarly, f and g make another composite node F. In addition, as the definition includes an exact topological boundary of a complex junction, it can thus be applied to identify complex junctions with their integrity, as explained below.

3. Algorithm of Identifying Complex Junctions The process of finding and isolating a complex junction in the dual network starts with a seed node of secondary road (sd) and then continues by expanding the found part till the boundary is reached. More specifically, the algorithm proceeds as follows: (1) Global initialization: concatenate road segments into strokes. Derive the primary- or-secondaryPrimary road segments type of roadsJunctions and or ends pair counterparts. By transform to the dual network, ISPRS Int. J. Geo-Inf. 2020,takeSecondary 9, x FOR the PEER setroad of REVIEWsegments nodes of secondary road (SG). Prepare an empty set (J) to collect 6 of 23 complex junctions to be found. If SG is empty, return J and quit. Otherwise, mark all nodes in SG as unprocessed. The(a) global initialization of the schematic road network(b) T shown in Figure4. SG correspondsFigure 4. (a, tob) theThe setglobal of secondaryinitialization roads, of thei.e., schematic (k, l, m, road n, o,network p). T.

(2) Seeding: pick an unprocessed secondary road sd from SG. If it is an appropriate one (i.e., it connects two different roads instead of the counterparts of one road), proceed to the next step. Otherwise, mark it as processed in SG. Try others till an appropriate one is picked. Or oth- erwise, return J and quit, as there are no more unprocessed nodes in SG. (3) Local initialization: prepare two empty sets, one for primary roads (P) and the other for secondary ones (S), to collect a complex junc- tion’s boundary nodes and interior nodes respectively. Put sd into S. By Primary road segments Junctionspicking or ends node k as sd as shown in Figure 5a, S contains a secondary road Secondary road segments in its collection as (k) after the local initialization. (4) S expanding: for each unexpanded appropriate node (x) in S, (a) (b) fetch all of its neighboring nodes from the dual network and put each Figure 4. (a,b) The globalof them initialization into either ofof thethe P schematicschematicor S according roadroad networknetwork to its road T.T. type, and then mark x as expanded. If new nodes are added to S, recursively expand the new (2) Seeding:(2) Seeding:onespick antill unprocessed somepick an primary unprocessed secondary roads aresecondary road reached. sd from road In SG.thesd from Ifprocess itis SG. an ofIf appropriate itrecursive one (i.e., itis connects an appropriateexpanding, two different one mark (i.e., roads thoseit conne instead in ctsS as oftwo expanded the different counterparts but roads leave of instead one those road), of in the P proceed as unex- to the next step.counterparts Otherwise,panded. of one markFigure road), it as5b proceed processedshows an to example inthe SG. next Try ofstep. others the Otherwise, process till an of appropriate markS expanding it one by is picked. Oras otherwise,processedexpanding returnin SG. node JTry and others k quit, in the astill theredualan appropriate network. are no more The one unprocessed nodes is picked. involved Or nodes oth- in inthe SG. pro- (3) Localerwise, initialization: returncess of J S and expandingprepare quit, as two arethere indicated empty are no sets, moreby one their unprocessed for color primary as shown nodes roads in (P)in Figure and the 2, other forSG. secondary and ones the (S),black to edges collect correspond a complex junction’sto links between boundary the nodesprocessing and interiornodes, nodes respectively. Put sd into S. By picking node k as sd as shown in Figure5a, S contains (3) Localso are initialization:those below in prepare Figures two 6–8. empty By S expending sets, one for of nodeprimary k, P collect a secondary road in its collection as (k) after the local initialization. roads (P)the and node the othera, and for f. secondary ones (S), to collect a complex junc- tion’s boundary nodes and interior nodes respectively. Put sd into S. By picking node k as sd as shown in Figure 5a, S contains a secondary road in its collection as (k) after the local initialization. (4) S expanding: for each unexpanded appropriate node (x) in S, fetch all of its neighboring nodes from the dual network and put each of them into either P or S according to its road type, and then mark x as expanded. If new nodes are added to S, recursively expand the new ones till some primary roads are reached. In the process of recursive expanding,(a) mark those in S as expanded but leave (thoseb) in P as unex- panded. Figure 5b shows an example of the process of S expanding by FigureFigure 5. The 5. seed The node seed ofnode secondary of secondary road k road (a) and k (a its) and S expanding its S expanding (b). (b). expanding node k in the dual network. The nodes involved in the pro- cess of S expanding(5) Multi-line are indicated processing: by their for eachcolor node as shown x in P inthat Figure is a counterpart 2, and the blackof a dual-line edges correspond or multi-line to links road between r, put r’s the other processing counterparts nodes, into P if so are thosethey below are not in in Figures yet, and 6–8. leave By Sthem expending as unexpanded. of node k, Figure P collect 6 shows an the node a, and f.

(a) (b) Figure 5. The seed node of secondary road k (a) and its S expanding (b).

(5) Multi-line processing: for each node x in P that is a counterpart of a dual-line or multi-line road r, put r’s other counterparts into P if they are not in yet, and leave them as unexpanded. Figure 6 shows an ISPRS Int. J. Geo-Inf. 2020, 9, x FOR PEER REVIEW 7 of 23

example of multi-line processing by collecting the counterparts, g and b, of node f and a in the dual network. By the multi-line processing, P contains the nodes of complex junction’s boundary as (a, b, f, g).

ISPRS Int. J. Geo-Inf. 2021, 10, 4 6 of 17

(4) S expanding: for each unexpanded appropriate node (x) in S, fetch all of its neighboring nodes(a) from the dual network and put each( ofb) them into either P or S according to itsFigure road type, 6. (a,b and) The then multi-line mark processing x as expanded. of node If of new primary nodes road are f and added a. to S, recursively expand the new ones till some primary roads are reached. In the process of recursive expanding, mark those(6in ) P S expanding: as expanded prepare but leave three those sets infor P temporary as unexpanded. use: first Figure for the5b ISPRS Int. J. Geo-Inf. 2020, 9, x FOR PEER REVIEW 7 of 23 shows an exampleunexpanded of the process appropriate of S expanding nodes by of expanding secondary node road k in neighboring the dual network. with The nodes involvedexamplethe inprocessing the of process multi-line one of (T), S expandingprocessing second for arebycollecting collecting indicated primary the by theircounterparts, roads color involved as showng and in in Figure2, and the black edges correspond to links between the processing nodes, so are b,the of process node f ofand expanding a in the dual (TP) network.and third By for the collecting multi-line secondary processing, roads P those below in Figures6–8. By S expending of node k, P collect the node a, and f. containsduring expanding the nodes (TS). of complex For each juncti unexpandedon’s boundary node xas in (a, P, b, clear f, g). T, fetch all of x’s neighboring unexpanded appropriate secondary roads, and put them into T. For each unexpanded node (y) in T, clear TS and TP, recursively expand y till some primary roads are reached, and put the roads obtained in the process of expanding (including y) into TS or TP respectively. If any node in TP is one in P other than x, put all those in TS and TP into S and P respectively if they are not there yet, and mark those added into S as expanded and leave those added into P as unex- panded. If x is connected to any node in S, mark it as expanded. Other- (a) wise, remove x from P. The P expanding(b) of node f, g, a, b in the dual network is shown in Figure 7. By P expanding, S contains its interior FigureFigure 6. (a,b 6.) The(a,b multi-line) The multi-line processing processing of node of ofno primaryde of primary road f road and a.f and a. nodes as (k, l, m, n). (6 ) P expanding: prepare three sets for temporary use: first for the unexpanded appropriate nodes of secondary road neighboring with the processing one (T), second for collecting primary roads involved in the process of expanding (TP) and third for collecting secondary roads during expanding (TS). For each unexpanded node x in P, clear T, fetch all of x’s neighboring unexpanded appropriate secondary roads, and put them into T. For each unexpanded node (y) in T, clear TS and TP, recursively expand y till some primary roads are reached, and put the (a) (b) roads obtained in the process of expanding (including y) into TS or TP respectively. If any node in TP is one in P other than x, put all those in TS and TP into S and P respectively if they are not there yet, and mark those added into S as expanded and leave those added into P as unex- panded. If x is connected to any node in S, mark it as expanded. Other- wise, remove x from P. The P expanding of node f, g, a, b in the dual network is shown in Figure 7. By P expanding, S contains its interior ISPRS Int. J. Geo-Inf. 2020, 9, x FOR PEER REVIEW nodes as (k, l, m, n). 8 of 23 (c) (d)

put jFigure into FigureJ, 7. andThe 7.clear P The expanding sd.P expanding Figure of node 8 showsof ofnode primary an of primaryexample road froad (ofa), a gf complex ((ba), g a (cb),), bajunc- ((dc),). b (d). tion with its node collections. (7) Local recursion: repeat step 5–6 till all nodes in both P and S are expanded; (8) Collecting results: now a complex junction j has just been iden- tified, for which P contains its boundary primary roads and S contains its interior secondary roads. Mark the nodes in S as processed in SG, (a) (b)

FigureFigure 8. A 8.complexA complex junction junction in the in dual the dualnetwork network for illustrating for illustrating its collec- its collections of nodes. P contains tionsthe of nodes nodes. P of contains the complex the nodes junction’s of the boundarycomplex junction’s as (a, b, f, boundary g), and S as contains (a, the interior nodes of b, f, g),secondary and S contains road as the (k, interior l, m, n). nodes of secondary road as (k, l, m, n).

(9) Global(5) Multi-line recursion: processing: repeat stepfor 2–8 each to node find xmore in P thatcomplex is a counterpart junc- of a dual-line or tionsmulti-line in the road road network. r, put r’s other counterparts into P if they are not in yet, and leave them (c) (d) asRegarding unexpanded. the algorithm, Figure6 shows some explanation an example may of multi-line be helpful. processing It is by collecting the worth notingFigure that 7. Thestep P 4 expanding expands outward of node of from primary the roadseed fnode (a), g of(b ),a com-a (c), b (d). plex junction, while step 6 first expands inward from its boundary nodes of primary road, and(7) thenLocal outward recursion: to repeatother boundarystep 5–6 till nodes. all nodes in both P and S Additionally, note theare simple expanded; proces sing in step 5 makes the algorithm applicable to the dual-line(8) and Collecting multi-line results: representations now a complex of roads junction in j has just been iden- addition to the single-linetified, one. for What which is Pmore, contains the result its boundary obtained primary in step roads and S contains 8 is stroke-based and canits interiorbe easily secondary transformed roads. to a Marksegment-based the nodes rep- in S as processed in SG, resentation which specifies the boundary and interior of a complex junction in terms of road segment and segment node. As can be seen, the overall process is basically a traversal of the dual network and is therefore highly efficient. A demonstration of the algorithm will be given in the next section.

4. Experimental Tests and Result Analysis A challenging road network of real world was used to test the pro- posed method. The test dataset covers a 6 km by 4 km area of city San Diego, California, US, which is shown in Figure 3. As can be seen, the roads were represented as segments in the dataset as indicated by their ends, the light grey dots on the map. The dataset used the dual-line representation for dual carriageways. It contained nineteen complex junctions, which were labeled from one to nineteen for easy reference. The rough extents of the complex junctions are circled with the black dotted ellipses on the map. As shown, the complex junctions vary greatly in size and complexity and are embedded in thousands of roads. The dataset is therefore considered challenging and suitable for testing if the proposed method can integrally identify complex junc- tions embedded in the surroundings, and also if it can deal with both the single-line and dual-line representations of roads. The data was preprocessed with ESRI ArcGIS Desktop 10.2.2. Stroke assembling, counterpart pairing, and the derivation of the pri- mary-or-secondary type of roads were based on road attributes, mainly road names and height grades, which is an attribute indicate whether two intersected road segments of 2-D plane in database connect with each other. Thanks to the quality of road attribute data, all of the soft- ware-based preprocessing turned out to be of high accuracy in terms of percentage of correct inferences, but there were errors. Manual check and error correction were performed after each main step of software- based preprocessing to ensure clean input to the next step.

ISPRS Int. J. Geo-Inf. 2021, 10, 4 7 of 17

counterparts, g and b, of node f and a in the dual network. By the multi-line processing, P contains the nodes of complex junction’s boundary as (a, b, f, g). (6) P expanding: prepare three sets for temporary use: first for the unexpanded appropriate nodes of secondary road neighboring with the processing one (T), second for collecting primary roads involved in the process of expanding (TP) and third for collecting secondary roads during expanding (TS). For each unexpanded node x in P, clear T, fetch all of x’s neighboring unexpanded appropriate secondary roads, and put them into T. For each unexpanded node (y) in T, clear TS and TP, recursively expand y till some primary roads are reached, and put the roads obtained in the process of expanding (including y) into TS or TP respectively. If any node in TP is one in P other than x, put all those in TS and TP into S and P respectively if they are not there yet, and mark those added into S as expanded and leave those added into P as unexpanded. If x is connected to any node in S, mark it as expanded. Otherwise, remove x from P. The P expanding of node f, g, a, b in the dual network is shown in Figure7. By P expanding, S contains its interior nodes as (k, l, m, n). (7) Local recursion: repeat step 5–6 till all nodes in both P and S are expanded; (8) Collecting results: now a complex junction j has just been identified, for which P contains its boundary primary roads and S contains its interior secondary roads. Mark the nodes in S as processed in SG, put j into J, and clear sd. Figure8 shows an example of a complex junction with its node collections. (9) Global recursion: repeat step 2–8 to find more complex junctions in the road network. Regarding the algorithm, some explanation may be helpful. It is worth noting that step 4 expands outward from the seed node of a complex junction, while step 6 first expands inward from its boundary nodes of primary road, and then outward to other boundary nodes. Additionally, note the simple processing in step 5 makes the algorithm applicable to the dual-line and multi-line representations of roads in addition to the single-line one. What is more, the result obtained in step 8 is stroke-based and can be easily transformed to a segment-based representation which specifies the boundary and interior of a complex junction in terms of road segment and segment node. As can be seen, the overall process is basically a traversal of the dual network and is therefore highly efficient. A demonstration of the algorithm will be given in the next section.

4. Experimental Tests and Result Analysis A challenging road network of real world was used to test the proposed method. The test dataset covers a 6 km by 4 km area of city San Diego, California, US, which is shown in Figure3. As can be seen, the roads were represented as segments in the dataset as indicated by their ends, the light grey dots on the map. The dataset used the dual-line representation for dual carriageways. It contained nineteen complex junctions, which were labeled from one to nineteen for easy reference. The rough extents of the complex junctions are circled with the black dotted ellipses on the map. As shown, the complex junctions vary greatly in size and complexity and are embedded in thousands of roads. The dataset is therefore considered challenging and suitable for testing if the proposed method can integrally identify complex junctions embedded in the surroundings, and also if it can deal with both the single-line and dual-line representations of roads. The data was preprocessed with ESRI ArcGIS Desktop 10.2.2. Stroke assembling, counterpart pairing, and the derivation of the primary-or-secondary type of roads were based on road attributes, mainly road names and height grades, which is an attribute indicate whether two intersected road segments of 2-D plane in database connect with each other. Thanks to the quality of road attribute data, all of the software-based preprocessing turned out to be of high accuracy in terms of percentage of correct inferences, but there were errors. Manual check and error correction were performed after each main step of software-based preprocessing to ensure clean input to the next step. The results of each main preprocessing step are all shown on the map in Figure9. About 1000 strokes were obtained from near 3000 segments in the test data. Each of the strokes was uniquely colored on the map to be distinguishable from the surroundings, ISPRS Int. J. Geo-Inf. 2021, 10, 4 8 of 17

although adjacent strokes might be in close colors due to the use of a random coloring scheme. The paired dual lines were indicated by their light grey background on the map. ISPRS Int. J. Geo-Inf. 2020, 9, x FOR PEER REVIEW The secondary roads were indicated by their yellow background on the map. 10 of 23

Figure 9. The test dataset and its preprocessing results after manual correction. The end points of the road segments in the raw data are represented by the light grey dots. The nineteen complex junctions to be identified are labeled from one to nineteen. The rough extents of the complex junctions are circled with the black dotted ellipses. The strokes assembled are uniquely colored using a random coloring scheme. The paired dual lines are indicated by their light grey background. The secondary roads are indicated by their yellow background.

Finally, the dual network of the stroke-based representation of the dataset was gener- ated and used for identification. We take complex junction No. 9 as shown in Figure 10 as an instance to demonstrate the transformation and identification processes. Although No. 9’s internal structure is not very complicated, its surrounding setting is more complicated than most of the others in the test area. It is next to No. 3 and No. 10, and connects five strokes of primary roads, i.e., (a, b, c, d, e), among which a and b are dual and the other three are single-line. To simply the demonstration, we have complex junction No.9 and its surroundings clipped to concentrate on. The resulting road network N is shown in Figure 10, where the roads of concern are labeled for reference. Its dual network is shown in Figure 11. As can be interpreted from Figure 10, roads a–n are primary and o–v are secondary. In addition, a and b are dual. So, o–v were greyed, and a and b were grouped by a dotted ellipse in Figure 11. The dashed ellipse doesn’t represent information known up to now and is drawn to help visualize the composition of complex junction No.9, which is to be identified. ISPRS Int. J. Geo-Inf. 2020, 9, x FOR PEER REVIEW 11 of 23

Figure 9. The test dataset and its preprocessing results after manual correction. The end points of the road segments in the raw data are represented by the light grey dots. The nineteen complex junctions to be identified are labeled from one to nineteen. The rough extents of the complex junctions are cir- cled with the black dotted ellipses. The strokes assembled are uniquely colored using a random col- oring scheme. The paired dual lines are indicated by their light grey background. The secondary roads are indicated by their yellow background.

Finally, the dual network of the stroke-based representation of the dataset was generated and used for identification. We take complex junction No. 9 as shown in Figure 10 as an instance to demonstrate the ISPRS Int. J. Geo-Inf. 2020, 9, x FOR PEER REVIEW 11 of 23 transformation and identification processes. Although No. 9’s internal Figure 9. The test datasetstructure and its preprocessing is not very complicated,results after manual its surrounding correction. The setting end pointsis more of com-the road segments in the rawplicated data are thanrepresented most of by the the otherslight grey in dots.the test The area. nineteen It is complex next to junctionsNo. 3 and to be identified are labeledNo. from 10, oneand to connects nineteen . fiveThe roughstrokes extents of primary of the complex roads, i.e.,junctions (a, b, are c, cir-d, e), cled with the black dottedamong ellipses. which The strokesa and b as aresembled dual andare uniquely the other colored three usingare single-line. a random col- oring scheme. The paired dual lines are indicated by their light grey background. The secondary roads are indicated by their yellow background.

Finally, the dual network of the stroke-based representation of the dataset was generated and used for identification. We take complex junction No. 9 as shown in Figure 10 as an instance to demonstrate the transformation and identification processes. Although No. 9’s internal structure is not very complicated, its surrounding setting is more ISPRS Int. J. Geo-Inf. 2021, 10, 4 com- 9 of 17

Figure 10. Road network N around complex junction No.9 clipped from the test data.

To simply the demonstration, we have complex junction No.9 and its surroundings clipped to concentrate on. The resulting road network N is shown in Figure 10, where the roads of concern are labeled for reference. Its dual network is shown in Figure 11. As can be interpreted from Figure 10, roads a–n are primary and o–v are secondary. In addi- tion, a and b are dual. So, o–v were greyed, and a and b were grouped by a dotted ellipse in Figure 11. The dashed ellipse doesn’t represent information known up to now and is drawn to help visualize the com- position Figure of 10.complexRoad network junction N No.9, around which complex is to junction be identified. No.9 clipped from the test data.

To simply the demonstration, we have complex junction No.9 and its surroundings clipped to concentrate on. The resulting road network N is shown in Figure 10, where the roads of concern are labeled for reference. Its dual network is shown in Figure 11. As can be interpreted from Figure 10, roads a–n are primary and o–v are secondary. In addi-tion, a and b are dual. So, o–v were greyed, and a and b were grouped by a dotted ellipse in Figure 11. The dashed ellipse doesn’t represent information known up to now and is drawn to help visualize the com-position of complex junction No.9, which is to be identified.

Figure 11. Dual network DN of road network N. Figure 11. Dual network DN of road network N. With the dual network D , complex junction No.9 can be identified by the algorithm N proposed. Table1 lists the steps of the identification process, in which the states of each step are given. The result of identification in the test network is shown on the map in Figure 12. For an identified complex junction, its secondary roads are in the same bright color while the participant primary roads are in black as one primary road can participate in more than one complex junctions. The rest roads that are not part of the complex junctions are in light grey. From the test result, some properties of the algorithm can be observed. Firstly, the algorithm identified all the nineteen complex junctions with their respective integrity. FigureIn other 11. Dual words, network no complexDN of road junctions network N. to be identified were missed; no non-complex- junction parts of the road network were mistakenly included in the identification result; no component roads of any junction were missed; and no non-component roads were mistakenly included in any junction. The integral identification results come from the deterministic nature of the algorithm, which is based on the definite topological boundary of the complex junction. With that said, it is not to claim the algorithm is error-tolerant, but rather it is integrity-maintaining when the input is clean. The influence of errors in input data will be discussed in Section5. Secondly, the algorithm turned out to be adaptable as anticipated. It worked for the simply structured complex junctions like No. 12–19, and the complicatedly structured ones like No. 1–11. It worked for the small ones like No. 12–19, the medium ones like No. 1, 2, 4, 5, 8, 9, 10, and 11, and the large ones like No. 3, 6 and 7. It worked for the single-line ones like No. 12–19, the dual-line ones like No. 1, 3 and 7, and the mixture ones like No. 2, 4, 5, 6, 8, 9, 10 and 11. ISPRS Int. J. Geo-Inf. 2021, 10, 4 10 of 17

Table 1. The steps and states of the algorithm in identifying complex junction No.9 in DN (the changed states are in bold in each step).

S P sd T TS TP SG J Global initialization ////// (o, p, q, r, s, t, u, v) () Notes: (1) s, t, u, and v are not eligible for seeding in DN as each of them connects to one road only; (2) without loss of generality, suppose s, t, u, and v are tried first and then p is picked as the seed. Seeding // p / / / (o, p, q, r, s’, t’, u’, v’) () Local initialization (p) () p / / / (o, p, q, r, s’, t’, u’, v’) () S expanding, p (p’)(a, c, d) p / / / (o, p, q, r, s’, t’, u’, v’) () Multi-line processing (p’) (a, b, c, d) p / / / (o, p, q, r, s’, t’, u’, v’) () P expanding, a (o, p’) (a’, b, c, d) p (o) () () (o, p, q, r, s’, t’, u’, v’) () expanding, o (o’, p’) (a’, b, c, d) p (o) (o)(a, c, d) (o, p, q, r, s’, t’, u’, v’) () P expanding, b (o’, p’, q, r) (a’, b’, c, d) p (q, r) () () (o, p, q, r, s’, t’, u’, v’) () expanding, q (o’, p’, q’, r) (a’, b’, c, d, e) p (q, r) (q)(b, c, e) (o, p, q, r, s’, t’, u’, v’) () expanding, r (o’, p’, q’, r’) (a’, b’, c, d, e) p (q, r) (r)(b, c, e) (o, p, q, r, s’, t’, u’, v’) () P expanding, c (o’, p’, q’, r’) (a’, b’, c’, d, e) p () () () (o, p, q, r, s’, t’, u’, v’) () P expanding, d (o’, p’, q’, r’) (a’, b’, c’, d’, e) p () () () (o, p, q, r, s’, t’, u’, v’) () Local recursion: proceed to Multi-line processing as there may be new nodes in P. Multi-line processing (o’, p’, q’, r’) (a’, b’, c’, d’, e) p / / / (o, p, q, r, s’, t’, u’, v’) () P expanding, e (o’, p’, q’, r’) (a’, b’, c’, d’, e’) p () () () (o, p, q, r, s’, t’, u’, v’) () Local recursion: proceed to the next step as all node in S and P are expanded. Collecting results (o’, p’, q’, r’) (a’, b’, c’, d’, e’) / / / / (o’, p’, q’, r’, s’, t’, u’, v’) (No. 9) Global recursion: proceed to Seeding Seeding: return J and quit. As all nodes in SG are processed. ISPRS Int. J. Geo-Inf. 2021, 10, 4 11 of 17

ISPRS Int. J. Geo-Inf. 2020, 9, x FOR PEER REVIEW 14 of 23

Figure 12. The result of applying the proposed method to the test dataset. For an identified complex junction, its secondary roads are in the same bright color while the participant primary roads are in black as one primary road can participate in more than one complex junctions. The rest roads that are not part of the complex junctions are in light grey.

Thirdly, the algorithm was not affected by geometric complexity of junctions as it is based on the topological relationship among roads. For No. 4 and 11, which are not connected but look very much like one complex junction instead of two, the algorithm did not combine them. For No. 5 and 6, of which the geometric extents are almost overlapping, the algorithm did not mix them up. For No. 6, it correctly gathered the four secondary roads that are quite apart but integrally connect the four primary roads (or six primary road strokes), among which two are dual and the other two are single-line. A comparison between this method and the conventional one, which defines complex junctions as dense regions of vertices, proposed by Mackaness and Mackechnie in 1999 is conducted in this study. Figure 13 shows the result of complex junction recognitions generated from a hierarchical clustering method [27], which was applied to detect dense regions of vertices in this comparison. By testing the thresholds involved in the clustering approach rigorously, we finally set the Distance, which means the maximum distance between points in a cluster, at 130 m, and the least number of points in a cluster at 4. It can be seen most of the clusters are outside the targets through comparison with the complex junctions highlighted in Figure 12. In addition to the error detected regions, the complex junctions were identified with several defects. The missed complex junctions like No. 8 and 13, the overfitting ones like No. 4, 12 and 14–19, the other ones with various degree of inexactness, including missing intersections, overfitting or both, like No. 1, 2, 3, 5, 6, 7, 9, 10 and 11. More detail were discussed in the previous studies [25–27]. ISPRS Int. J. Geo-Inf. 2021, 10, 4 12 of 17 ISPRS Int. J. Geo-Inf. 2020, 9, x FOR PEER REVIEW 16 of 23

Figure 13. Complex junction detections using the approach proposed by Mackaness and Mackechnie (1999). The nineteen labels of the complex junctions to be identified are in two grey levels. Dark grey for various degree of inexactness, and light grey for overfitting. For those completely missing identified complex junctions, red dashed ellipses are used to circle the extents of concern.

5. Influence of Errors in Input Data As can be seen from the above experiment, preprocessing is needed to semantically enrich the raw data and transform the representation of data before the identification, which includes stroke assembling, counterpart pairing, road classification and dual network generation. As we know, this is not special but rather common in map generalization, as spatial data in their ordinary form are generally not suitable to be generalized directly, and data enrichment and representation transformation are regularly required [2]. While the proposed algorithm is integrity-maintaining, dirty input can influence and even spoil the identification. To have some idea of how significant the influence is, we made a trial by letting the identification process run upon the uncorrected preprocessing result. The uncorrected preprocessing result and the corresponding identification result are shown in Figures 14 and 15 respectively. In Figure 15, the nineteen labels of the complex junctions to be identified are in three grey levels. White stands for exact identification, light grey for various degree of inexactness, and dark grey for misses. As can be seen, ten were identified exactly, and eight inexactly, and one is missed. In addition, four artefact ones were mistakenly identified, which were highlighted and labeled with red numbers on the map. By comparing Figure 14 with Figures9 and 15 with Figure 12, it is not difficult to figure out that all of the inexact identification was due to imperfect stroke assembling. Additionally, all of the missed and artefact complex junctions were due to misclassification of roads, although some of the classification errors were related to the mistakes in stroke assembling. There were also dual-line pairing errors, but they did not manifest themselves in the result of this trial of identification. ISPRS Int. J. Geo-Inf. 2021, 10, 4 13 of 17

ISPRS Int. J. Geo-Inf. 2020, 9, x FOR PEER REVIEW 18 of 23

Figure 14. The test dataset and its preprocessing result without manual correction. The map used the same symbolization as that of Figure9 except for the random stroke colors. The end points of the road segments of the raw data are represented by the light grey dots. The nineteen complex junctions to be identified are labeled from one to nineteen. The rough extents of the complex junctions are circled with the dashed ellipses. The strokes assembled are uniquely colored using a random coloring scheme. The paired dual lines are indicated by their light grey background. The secondary roads were indicated by their yellow background. ISPRS Int. J. Geo-Inf. 2020, 9, x FOR PEER REVIEW 20 of 23

Figure 15. The identification result obtained from the input with errors. The nineteen labels of the complex junctions to be identified are in three grey levels. White stands for exact identification, light grey for various degree of inexactness, and dark grey for misses. For those inexactly identified or missed, red dashed ellipses are used to circle the extents of concern. The four artefact complex junctions that were mistakenly identified are highlighted and labeled with the red numbers. ISPRS Int. J. Geo-Inf. 2021, 10, 4 14 of 17

The influence exposed above should be not surprising. To make it worse, there are no known error-free algorithms for the three widely used preprocessing operations of data enrichment, i.e., stroke assembling, counterpart pairing and road classification. That means the result of purely software-based preprocessing would normally contain errors, which if not corrected would significantly influence the identification. Manual check and correction after each operation is therefore a necessity. In addition, the above trial indicates that it is ISPRS Int. J. Geo-Inf. 2020, 9, x FOR PEERstill REVIEW so even though each step produces output of high accuracy, as the errors will propagate 21 of 23 and accumulate through the preprocessing flow. That also means user-friendly efficient Figure 15. The identification result obtained from the input with errors. The nineteen labels of the complex junctions to be identified are in three grey levels.tools White for interactive stands for exact check identification, and correction ligh aret grey invaluable for various in degree production of inexactness, environment, and and dark grey for misses. For thosereliable inexactly estimation identified ofor themissed, uncertainty red dashed of processingellipses are used results to circle is highly the extents desired of toconcern. be provided The four artefact complex junctionsby any that inexact were mistakenly algorithm id inentified addition are to highlighted the result and itself. labeled with the red numbers. 6. Discussion 6. Discussion InIn this this article, article, we we consider consider the the scale-dependence scale-dependence of ofidentifying identifying complex complex junctions junctions as as two aspects: the first is spatial heterogeneity among complex junctions, and the second is two aspects: the first is spatial heterogeneity among complex junctions, and the second is different representations of a complex junction at its relative scales (multiple representa- different representations of a complex junction at its relative scales (multiple representa- tions). For dealing with the scale-dependence, this article proposed a novel approach to tions). For dealing with the scale-dependence, this article proposed a novel approach to identify complex junctions based on their topological boundaries. No matter how compli- identify complex junctions based on their topological boundaries. No matter how compli- cated or simple a complex junction is, it contains its boundary primary roads and interior cated or simple a complex junction is, it contains its boundary primary roads and interior secondary ones. Therefore, the topological boundary of a complex junction is inherently secondary ones. Therefore, the topological boundary of a complex junction is inherently scale-independent that can be free from the influence of spatial heterogeneity and multiple scale-independent that can be free from the influence of spatial heterogeneity and multi- representations. ple representations. From the comparison, it can be found that the topological boundary of a complex From the comparison, it can be found that the topological boundary of a complex junction is a practical characteristic to integrally identify complex junctions from avoiding junction is a practical characteristic to integrally identify complex junctions from avoiding overfitting problems. Therefore, it seems that representing complex junction as the primary- overfittingsecondary problems. road structure Therefore, is cleaner it seems and that clearer representing than point-based complex (or junction intersection-based) as the pri- mary-secondarycluster in a road road network. structure This is approachcleaner an cand clearer also betha appropriatelyn point-based integrated (or intersection- into the based)process cluster of road in a networkroad network. generalization This approa basedch can on also stroke be representation.appropriately integrated By simplifying into thecomplex process junctionsof road network without generalization breaking connectivity based on among stroke relativerepresentation. roads, the By generalization simplifying complexof road junctions network without can be purely breaking dealt connectivity with primary among ones. relative Figure roads, 16 shows the generalization an example to ofexplain road network this process can be by purely transforming dealt with dual-line primary representation ones. Figure to single-line16 shows an one example for the roadto explainnetwork this in process Figure3 byc. Thetransf pairingorming lines dual-line a and b representation of a dual carriageway to single-line are combined one for withthe roadthe primary network road in Figure c. Similarly, 3c. The f and pa giring compose lines another a and road b of F. Therefore, a dual carriageway classifying roads are combinedinto the primary and secondary categories can be considered as a preprocessing operations of data enrichment for road network generalization.

FigureFigure 16. 16. A Aresult result of ofthe the road road network network generalization generalization by by combin combininging the the pairing pairing primary primary roads. roads.

TherebyThereby the the criteria criteria to todifferentiate differentiate betw betweeneen primary primary roads roads and and secondary secondary ones ones is a is a necessity. In this article, strokes are assembled and classified based on road attributes. necessity. In this article, strokes are assembled and classified based on road attributes. In In the domain knowledge of junction design [29–31], the principle of secondary road the domain knowledge of junction design [29–31], the principle of secondary road (auxil- (auxiliary , slip roads or ramps) design is rigorously considered, such as number of iary lanes, slip roads or ramps) design is rigorously considered, such as number of lanes, lanes, speed restriction and driving direction. Primary roads and secondary roads are with speed restriction and driving direction. Primary roads and secondary roads are with sig- significantly difference on their design principles for such as road capacity, safety, location nificantly difference on their design principles for such as road capacity, safety, location and space [29]. Therefore, the standard of design may be applied as criteria to and space [29]. Therefore, the standard of interchange design may be applied as criteria classify roads of primary-or-secondary type in the future. to classify roads of primary-or-secondary type in the future.

7. Conclusions This paper presented a neat solution to the problem of identifying complex junctions. In addition to preserving the integrity of complex junctions, the proposed method is free from the troublesome threshold-setting, able to deal with different representations of roads, and efficient. All these together make it favorable for practical use. With the bound- ary and interior clearly identified, complex junctions in a road network can be properly ISPRS Int. J. Geo-Inf. 2021, 10, 4 15 of 17

7. Conclusions This paper presented a neat solution to the problem of identifying complex junctions. In addition to preserving the integrity of complex junctions, the proposed method is free from the troublesome threshold-setting, able to deal with different representations of roads, and efficient. All these together make it favorable for practical use. With the boundary and interior clearly identified, complex junctions in a road network can be properly simplified without breaking the connectivity among roads, thereby maintaining the topological validity of the simplified road network. What is more, such topological clarity can greatly facilitate the geometric and semantic simplification of complex junctions [23,25,26]. This study consolidates the effectiveness of the intelligent approach to spatial data generalization that is characterized by an appropriate combination of data enrichment, representation transformation and pattern recognition [8,19]. Although this study is mainly concerned with the composite pattern of complex junction, it is based on the components that are progressively richer in semantics and more complex in structure, which in turn are roads strokes, classified roads and the bundled counterparts of a road. Therefore, we think all of the three operations of data enrichment (i.e., stroke assembling, road classification and counterparts pairing) are crucial and desired to be better addressed so as to improve the accuracy of algorithms, make reliable uncertainty estimation for effectively locating potential errors in results, and provide interactive tools for efficiently checking results and correcting errors. In that regard too, the two new conceptions adopted in this study can be of use wider than defining the composition of a complex junction. Firstly, we believe the categorization of roads into two basic types, the primary and the secondary, is not only appropriate but also useful in other processing and analysis of road networks. As is shown in this study, the topological boundary of complex junctions instantly becomes clear once roads are classified this way. In fact, we found it also very useful for better pairing the dual lines of a dual carriageway and analyzing other patterns in road networks in our related studies ongoing. Secondly, the concept of topological boundary may also apply to other structural patterns in road networks besides complex junctions. For instance, street blocks may be better delineated topologically than geometrically. We will examine such possibility in our future studies.

Author Contributions: Zhu Xu and Zhilin Li designed this research. Jianting Yang implemented the methodology and performed the experimental validation. Kongyang Zhao and Muzi Li performed the data preprocessing and conducted some of the experiments. All authors have contributed to this article with discussion and writing. All authors have read and agreed to the published version of the manuscript. Funding: This research was funded by National Natural Science Foundation of China (No. 40971209 and 41971330) and the Key Laboratory of Digital Mapping and Land Information Application of National Administration of Surveying, Mapping and Geoinformation (No. DM2016SC07). Acknowledgments: This work was supported by the New Century Talent Supporting Project of education ministry. Conflicts of Interest: The authors declare no conflict of interest.

References 1. Brassel, K.E.; Weibel, R. A review and conceptual framework of automated map generalization. Int. J. Geogr. Inf. Syst. 1988, 2, 229–244. [CrossRef] 2. Weibel, R. Map generalization in the context of digital systems. Cartogr. Geogr. Inf. Syst. 1995, 22, 259–263. [CrossRef] 3. Jones, C.B.; Mark Ware, J. Map generalization in the web age. Int. J. Geogr. Inf. Sci. 2005, 19, 859–870. [CrossRef] 4. Buttenfield, B.P.; McMaster, R.B. Map Generalization: Making Rules for Knowledge Representation; Longman Scientific and Technical: Harlow, UK, 1991; ISBN 978-047-021-803-7. 5. Li, Z. Digital map generalization at the age of enlightenment: A review of the first forty years. Cartogr. J. 2007, 44, 80–93. [CrossRef] ISPRS Int. J. Geo-Inf. 2021, 10, 4 16 of 17

6. Mackaness, W.A.; Beard, K.M. Use of graph theory to support map generalization. Cartogr. Geogr. Inf. Syst. 1993, 20, 210–221. [CrossRef] 7. Jones, C.B.; Bundy, G.L.; Ware, M.J. Map generalization with a triangulated data structure. Cartogr. Geogr. Inf. Syst. 1995, 22, 317–331. [CrossRef] 8. Neun, M.; Weibel, R.; Burghardt, D. Data enrichment for adaptive generalisation. In Proceedings of the 8th ICA Workshop on Generalisation and Multiple representation, Leicester, UK, 20–21 August 2004. 9. Barrault, M.; Regnauld, N.; Duchène, C.; Haire, K.; Baeijs, C.; Demazeau, Y.; Hardy, P.; Mackaness, W.; Ruas, A.; Weibel, R. Integrating multi-agent, object-oriented and algorithmic techniques for improved automated map generalization. In Proceedings of the 20th International Cartographic Conference, Beijing, China, 6–10 August 2001; pp. 2110–2116. 10. Lee, J.; Jang, H.; Yang, J.; Yu, K. Machine learning classification of buildings for map generalization. Isprs Int. J. Geo-Inf. 2017, 6, 309. [CrossRef] 11. Feng, Y.; Thiemann, F.; Sester, M. Learning cartographic building generalization with deep convolutional neural networks. Isprs Int. J. Geo Inf. 2019, 8, 258. [CrossRef] 12. Stoter, J.; Post, M.; van Altena, V.; Nijhuis, R.; Bruns, B. Fully automated generalization of a 1: 50k map from 1: 10k data. Cartogr. Geogr. Inf. Sci. 2014, 41, 1–13. [CrossRef] 13. Šuba, R. Design and development of a system for vario-scale maps. Archit. Built Environ. 2017, 13–14. [CrossRef] 14. Edwardes, A.J.; Mackaness, W.A. Intelligent generalisation of urban road networks. In Proceedings of the GIS Research UK 2000 Conference, York, UK, 5–7 April 2000; pp. 81–85. 15. Touya, G.; Lokhat, I.; Duchêne, C. CartAGen: An Open Source Research Platform for Map Generalization. In Proceedings of the 29th International Cartographic Association (ICC 2019), Tokyo, Japan, 15–20 July 2019. [CrossRef] 16. Jiang, B.; Claramunt, C. A structural approach to the model generalization of an urban street network. GeoInformatica 2004, 8, 157–171. [CrossRef] 17. Benz, S.A.; Weibel, R. Road network selection for medium scales using an extended stroke-mesh combination algorithm. Cartogr. Geogr. Inf. Sci. 2014, 41, 323–339. [CrossRef] 18. Yu, W.; Zhang, Y.; Ai, T.; Guan, Q.; Chen, Z.; Li, H. Road network generalization considering traffic flow patterns. Int. J. Geogr. Inf. Sci. 2020, 34, 119–149. [CrossRef] 19. Touya, G. A road network selection process based on data enrichment and structure detection. Trans. Gis 2010, 14, 595–614. [CrossRef] 20. Yang, B.; Luan, X.; Li, Q. An adaptive method for identifying the spatial patterns in road networks. Comput. Environ. Urban. Syst. 2010, 34, 40–48. [CrossRef] 21. Shao, L.; Mittelstädt, S.; Goldblatt, R.; Omer, I.; Bak, P.; Schreck, T. Analysis and Comparison of Feature-Based Patterns in Urban Street Networks. In Proceedings of the 11th International Joint Conference on Computer Vision, Imaging and Computer Graphic, Rome, Italy, 27–29 February 2016; pp. 287–309. [CrossRef] 22. Balboa, J.L.G.; López, F.J.A. Generalization-oriented road line classification by means of an artificial neural network. GeoInformatica 2008, 12, 289–312. [CrossRef] 23. Savino, S.; Rumor, M.; Zanon, M.; Lissandron, I. Data enrichment for road generalization through analysis of morphology in the CARGEN project. In Proceedings of the 13th ICA Workshop on Generalisation and Multiple Representation, Zürich, Switzerland, 12–13 September 2010. 24. Wenzel, S.; Bulatov, D. Simultaneous Chain-Forming and Generalization of Road Networks. Photogramm. Eng. Remote Sens. 2019, 85, 19–28. [CrossRef] 25. Mackaness, W.A.; Mackechnie, G.A. Automating the detection and simplification of junctions in road networks. GeoInformatica 1999, 3, 185–200. [CrossRef] 26. Savino, S.; Rumor, M.; Lissandron, I. Generalization in Large Scale Geodatabases; CRC Press/Balkema: London, UK, 2009; ISBN 978-042-920-671-9. 27. Zhou, Q.; Li, Z. Experimental analysis of various intersections for interchange detection. Trans. GIS 2015, 19, 19–41. [CrossRef] 28. Grosso, E. Etude des carrefours d’un réseau routier–Première approche: Modélisation et implémentation d’outils de détection des carrefours (plate-forme Oxygène). Master’s Thesis, University of Paris 1 Pantheon-Sorbonne, Paris, France, February 2004. 29. Lamm, R.; Psarianos, B.; Choueiri, E.M.; Mailaender, T. Interchange Planning and Design-An International Perspective. Transp. Res. Rec. 1993, 1385, 69–83. 30. Lunenfeld, H. Human factors associated with interchange design features. Transp. Res. Rec. 1993, 1385, 84–89. 31. Chlewicki, G. New interchange and intersection designs: The synchronized split-phasing intersection and the diverging . In Proceedings of the 2nd Urban Street Symposium, Anaheim, CA, USA, 28–30 July 2003. 32. Thomson, R.C. The ’stroke’ Concept in Geographic Network Generalization and Analysis. In Progress in Spatial Data Handling; Riedl, A., Kainz, W., Elmes, G.A., Eds.; Springer: Berlin/Heidelberg, Germany, 2006; pp. 681–697. [CrossRef] 33. Thomson, R.C.; Richardson, D.E. The ‘good continuation’principle of perceptual organization applied to the generalization of road networks. In Proceedings of the 19th International Cartographic Conference, Ottawa, ON, Canada, 14–21 August 1999. 34. Lämmer, S.; Gehlsen, B.; Helbing, D. Scaling laws in the spatial structure of urban road networks. Phys. A Stat. Mech. Its Appl. 2006, 363, 89–95. [CrossRef] ISPRS Int. J. Geo-Inf. 2021, 10, 4 17 of 17

35. Newman, M.E.J. Networks: An Introduction; Oxford University Press: New York, NY, USA, 2010; pp. 35, 121–124, ISBN 978-019- 920-665-0. 36. Corcoran, P.; Mooney, P. Characterising the metric and topological evolution of OpenStreetMap network representations. Eur. Phys. J. Spec. Top. 2013, 215, 109–122. [CrossRef]