Mapping polygons to the gridwith small Hausdorff and Frechet distance∗
Quirijn W. Bouts† Irina Kostitsyna† Marc van Kreveld‡ Wouter Meulemans§
Willem Sonke† Kevin Verbeek†
Abstract
We show how to represent a simple polygon P by a grid (pixel-based) polygon Q that issimple and whose Hausdorff or Frechet distance to P is small. For any simple polygon P , a gridpolygon exists with constant Hausdorff distance between their boundaries and their interiors.Moreover, we show that with a realistic input assumption we can also realize constant Frechetdistance between the boundaries. We present algorithms accompanying these constructions,heuristics to improve their output while keeping the distance bounds, and experiments to assessthe output.
1 Introduction
Transforming the representation of objects from the real plane onto a grid has been studied for decadesdue to its applications in computer graphics, computer vision, and finite-precision computationalgeometry [13]. Two interpretations of the grid are possible: (i) the grid graph, consisting of verticesat all points with integer coordinates, and horizontal and vertical edges between vertices at unitdistance; (ii) the pixel grid, where the only elements are pixels (unit squares). In the latter, one canchoose between 4-neighbor or 8-neighbor grid topology. In this paper we adopt the pixel grid viewwith 4-neighbor topology.
The issues involved when moving from the real plane to a grid begin with the definition of a linesegment on a grid, known as a digital straight segment [18]. For example, it is already difficult torepresent line segments such that the intersection between any pair is a connected set (or empty).In general, the challenge is to represent objects on a grid in such a way that certain propertiesof those objects in the real plane transfer to related properties on the grid; connectedness of theintersection of two line segments is an example of this.
While most of the research related to digital geometry has the graphics or vision perspective [18, 17],computational geometry has made a number of contributions as well. Besides finite-precisioncomputational geometry [11, 13] these include snap rounding [10, 12, 15], the integer hull [4, 14],and consistent digital rays with small Hausdorff distance [9].
Mapping polygons. We consider the problem of representing a simple polygon P as a similarpolygon in the grid (see Fig. 1). A grid cycle is a simple cycle of edges and vertices of the gridgraph. A grid polygon is a set of pixels whose boundary is a grid cycle. This problem is motivatedby schematization of country or building outlines and by nonograms.
The most well-known form of schematization in cartography are metro maps, where metro linesare shown in an abstract manner by polygonal lines whose edges typically have only four orientations.
∗Research on the topic of this paper was initiated at the 1st Workshop on Applied Geometric Algorithms (AGA2015) in Langbroek, The Netherlands, supported by the Netherlands Organisation for Scientific Research (NWO) underproject no. 639.023.208. NWO is supporting Q. W. Bouts, I. Kostitsyna, and W. Sonke under project no. 639.023.208,and K. Verbeek under project no. 639.021.541. W. Meulemans is supported by Marie Sk lodowska-Curie ActionMSCA-H2020-IF-2014 656741.†Dept. of Mathematics and Computer Science, TU Eindhoven, The Netherlands. { q.w.bouts | i.kostitsyna |
w.m.sonke | k.a.b.verbeek }@tue.nl‡Dept. of Information and Computing Sciences, Utrecht University, The Netherlands. [email protected]§giCentre, City University London, United Kingdom. [email protected]
1
arX
iv:1
606.
0666
0v1
[cs
.CG
] 2
1 Ju
n 20
16
Figure 1: From left to right: input; symmetric-difference optimal result is not a grid polygon; gridpolygon computed by our Frechet algorithm; grid polygon computed by our Hausdorff algorithm.
It is common to also depict region outlines with these orientations on such maps. It is possibleto go one step further in schematization by using only integer coordinates for the vertices, whichoften aligns vertices vertically or horizontally, and leads to a more abstracted view. Certain types ofcartograms like mosaic maps [7] are examples of maps following this visualization style. The versionbased on a square grid is often used to show electoral votes after elections. Another cartographicapplication of grid polygons lies in the schematization of building outlines [20].
Nonograms—also known as Japanese or picture logic puzzles—are popular in puzzle books,newspapers, and in digital form. The objective is to reconstruct a pixel drawing from a code thatis associated with every row and column. The algorithmic problem of solving these puzzles iswell-studied and known to be NP-complete [6]. To generate a nonogram from a vector drawing, a gridpolygon on a coarse grid should be made. We are interested in the generation of grid polygons fromshapes like animal outlines, which could be used to construct nonograms. To our knowledge, twopapers address this problem. Ortız-Garcıa et al. [22] study the problem of generating a nonogramfrom an image; both the black-and-white and color versions are studied. Their approach uses imageprocessing techniques and heuristics. Batenburg et al. [5] also start with an image, but concentrateon generating nonograms from an image with varying difficulty levels, according to some definitionof difficulty.
Considering the above, our work also relates to image downscaling (e.g. [19]), though this usuallystarts from a raster image instead of continuous geometric objects. Kopf et al. [19] apply theirtechnique to vector images, stating that the outline remains connected where possible. In contrastto our work, the quality is not measured as the geometric similarity and the conditions necessary toguarantee a connected outline remain unexplored.
Similarity. There are at least three common ways of defining the similarity of two simple polygons:the symmetric difference1, the Hausdorff distance [1], and the Frechet distance [2]. The first doesnot consider similarity of the polygon boundaries, whereas the third usually applies to boundariesonly. The Hausdorff distance between polygon interiors and between polygon boundaries both existand are different measures; this distance can be directed or undirected. Let X and Y be two closedsubsets of a metric space. The (directed) Hausdorff distance dH(X,Y ) from X to Y is defined asthe maximum distance from any point in X to its closest point in Y . The undirected version is themaximum of the two directed versions. To define the Frechet distance, let X and Y be two curvesin the plane. The Frechet distance dF (X,Y ) is the minimum leash length needed to let a man walkover X and a dog over Y , where neither may walk backwards (a formal definition can be foundin [2]).
Contributions. In Section 2 we show that any simple polygon P admits a grid polygon Q withdH(P,Q) ≤ 1
2
√2 and dH(Q,P ) ≤ 3
2
√2 on the unit grid. Furthermore, the constructed polygon
satisfies the same bounds between the boundaries ∂P and ∂Q. This is not equivalent, since the pointthat realizes the maximum smallest distance to the other polygon may lie in the interior (Fig. 2).Our proof is constructive, but the construction often does not give intuitive results (Fig. 2, P and
1The symmetric difference between two sets A and B is defined as the set (A \B)∪ (B \A). When using symmetricdifference as a quality measure, we actually mean the area of the symmetric difference.
2
P Q1 Q2
Figure 2: dH(P,Q1) is small but dH(∂P, ∂Q1) is not. dH(P,Q2) and dH(∂P, ∂Q2) are both smallbut the Frechet distance dF (∂P, ∂Q2) is not.
Q2). Therefore, we extend our construction with heuristics that reduce the symmetric differencewhilst keeping the Hausdorff distance within 3
2
√2. The Frechet distance dF [2] between two polygon
boundaries is often considered to be a better measure for similarity. Unlike the Hausdorff distance,however, not every polygon boundary ∂P can be represented by a grid cycle with constant Frechetdistance. In Section 3 we present a condition on the input polygon boundary related to fatness (infact, to κ-straightness [3]) and show that it allows a grid cycle representation with constant Frechetdistance. Finally, in Section 4 we evaluate how our algorithms perform on realistic input polygons.
2 Hausdorff distance
We consider the problem of constructing a grid polygon Q with small Hausdorff distance to P . InAppendix A we prove the theorem below. In this section we present an algorithm that achieves lowHausdorff distance between both the boundaries and the interiors of the input polygon P and theresulting grid polygon Q. We first show how to construct such a grid polygon. Then, in Section 2.2,we provide an efficient algorithm to compute Q. Finally, we describe heuristics that can be used toimprove the results in practice.
Theorem 1 Given a polygon P , it is NP-hard to decide whether there exists a grid polygon Qsuch that both dH(∂P, ∂Q) ≤ 1
2 and dH(∂Q, ∂P ) ≤ 12 .
2.1 Construction
We represent the grid polygon Q as a set of cells (or pixels). We say that two cells are adjacentif they share a segment. If two cells share only a point, then they are point-adjacent. If two cellsc1 ∈ Q and c2 ∈ Q are point-adjacent, and there is no cell c ∈ Q that is adjacent to both c1 andc2, then c1 and c2 share a point-contact. We construct Q as the union of four sets Q1, Q2, Q3,Q4 (not necessarily disjoint). To define these sets, we define the module M(c) of a cell c as the2× 2-region centered at the center of c (see Fig. 3). Furthermore, we assume the rows and columnsare numbered, so we can speak of even-even cells, odd-odd cells, odd-even cells, and even-odd cells.The four sets are defined as follows; see also Fig. 4.
Q1: All cells c for which M(c) ⊆ P .
Q2: All even-even cells c for which M(c) ∩ P 6= ∅.
Q3: For all cells c1, c2 ∈ Q1 ∪Q2 that share a point-contact, the two cells that are adjacent to bothc1 and c2 are in Q3.
Q4: A minimal set of cells that makes Q connected, and where each cell c ∈ Q4 is adjacent to twocells in Q2 and M(c) ∩ P 6= ∅.
Set Q1 ∪Q2 is sufficient to achieve the desired Hausdorff distance. We add Q3 to resolve point-contacts, and Q4 to make the set Q simply connected (a polygon without holes). The lemma belowis the crucial argument to argue that Q is a grid polygon.
3
M(c)
c
Figure 3: Module M(c)(dashed) of a cell c.
Q
P
Figure 4: Example of the Hausdorff algorithm; the input and outputare shown on the right. Colors: Q1, Q2, Q3, Q4.
Lemma 1 The set Q1 ∪Q2 is hole-free, even when including point-adjacencies.
H
C
Figure 5: A hole in Q. Colors:Q1 ∩B; Q2 ∩B.
Proof. For the sake of contradiction, let H be a maximalset of cells comprising a hole. Let set B contain all cells inQ1 ∪ Q2 that surround H and are adjacent to a cell in H.Since Q2 contains only even-even cells, every cell in Q2 ∩B is(point-)adjacent to two cells in Q1 ∩B (see Fig. 5). Hence, theouter boundary of the union of all modules of cells in Q1 ∩Bis a single closed curve C. Since C ⊂ P due to the definitionof Q1, the interior of C must also be in P . Since the moduleof every cell in H lies completely inside C, they are also in P ,so the cells in H must all be in Q1. This contradicts that His a hole. �
Lemma 2 The set Q is simply connected and does not contain point-contacts.
Proof. Consider a point-contact between two cells c1, c2 ∈ Q1 ∪Q2 and a cell c /∈ Q1 ∪Q2 that isadjacent to both c1 and c2 (c ∈ Q3). Since Q2 contains only even-even cells, we may assume thatc1 ∈ Q1. Recall that M(c1) ⊆ P by definition. We may further assume that c1 is an odd-odd cell,for otherwise a cell in Q2 would eliminate the point-contact. Hence, all cells point-adjacent to c1are in Q1 ∪Q2, and thus c has three adjacent cells in Q1 ∪Q2. This implies that adding c ∈ Q3
to Q1 ∪Q2 cannot introduce point-contacts or holes. Similarly, cells in Q4 connect two oppositelyadjacent cells in Q2, and thus cannot introduce point-contacts (or holes, by definition). Combiningthis with Lemma 1 implies that Q is hole-free and does not contain point-contacts.
It remains to show that Q is connected, that is, the set Q4 exists. Consider two cells c1, c2 ∈ Q.We show that c1 and c2 are connected in Q. We may further assume that c1, c2 ∈ Q2, as cells inQ1 ∪Q3 ∪Q4 must be adjacent or point-adjacent to a cell in Q2. Let p ∈M(c1)∩P , q ∈M(c2)∩Pand consider a path π between p and q inside P . Every even-even cell c with M(c) ∩ π 6= ∅ mustbe in Q2. Furthermore, the modules of even-even cells cover the plane. Every cell connecting aconsecutive pair of even-even cells intersecting π satisfies the conditions of Q4, and thus can beadded to make c1 and c2 connected in Q. �
Upper bounds. To prove our bounds, note that M(c) ∩ P 6= ∅ holds for every cell c ∈ Q. This isexplicit for cells in Q1, Q2, and Q4. For cells in Q3, note that these cells must be adjacent to a cellin Q1, and thus contain a point in P .
Lemma 3 dH(P,Q), dH(∂P, ∂Q) ≤ 12
√2.
4
Proof. Let p ∈ P and consider the even-even cell c such that p ∈M(c). Since c ∈ Q2, the distancedH(p,Q) ≤ dH(p, c) ≤ 1
2
√2. Now consider a point p ∈ ∂P . There is a 2 × 2-set of cells whose
modules contain p. This set contains an even-even cell c ∈ Q and an odd-odd cell c′ /∈ Q. The latteris true, because odd-odd cells in Q must be in Q1. Therefore, the point q shared by c and c′ mustbe in ∂Q. Thus, dH(p, ∂Q) ≤ dH(p, q) ≤ 1
2
√2. �
Lemma 4 dH(Q,P ), dH(∂Q, ∂P ) ≤ 32
√2.
Proof. Let q be a point in Q and let c ∈ Q be the cell that contains q. SinceM(c)∩P 6= ∅, we canchoose a point p ∈M(c) ∩ P . It directly follows that dH(q, P ) ≤ dH(q, p) ≤ 3
2
√2. Now consider a
point q ∈ ∂Q, and let c ∈ Q and c′ /∈ Q be two adjacent cells such that q ∈ ∂c ∩ ∂c′. We claim that(M(c) ∪M(c′)) ∩ ∂P 6= ∅. If c /∈ Q1, then M(c) * P . As furthermore M(c) ∩ P 6= ∅, we have thatM(c) ∩ ∂P 6= ∅. On the other hand, if c ∈ Q1, then M(c) ⊆ P , so M(c′) ∩ P 6= ∅. As furthermoreM(c′) * P (otherwise c′ ∈ Q1), we have thatM(c′)∩ ∂P 6= ∅. Let p ∈ (M(c)∪M(c′))∩ ∂P . ThendH(q, ∂P ) ≤ dH(q, p) ≤ 3
2
√2. �
Theorem 2 For every simple polygon P a simply connected grid polygon Q without point-contactsexists such that dH(P,Q), dH(∂P, ∂Q) ≤ 1
2
√2 and dH(Q,P ), dH(∂Q, ∂P ) ≤ 3
2
√2.
Lower bound. Fig. 6 illustrates a polygon P for which no grid polygon Q exists with low d(Q,P ).A naive construction results in a nonsimple polygon (left). To make it simple, we can either removea cell (center) or add a cell (right). Both methods result in dH(Q,P ) ≥ 3/2− ε. Alternatively, wecan fill the entire upper-right part of the grid polygon (not shown), resulting in a high dH(Q,P ).This leads to the following theorem.
Theorem 3 For any ε > 0, there exists a polygon P for which no grid polygon Q exists withd(Q,P ) < 3/2− ε.
In the L∞ metric, the lower bound of 3/2 − ε given in Fig. 6 also holds. A straightforwardmodification of the upper-bound proofs can be used to show that the Hausdorff distance is at most3/2 in the L∞ metric. In other words, our bounds are tight under the L∞ metric.
3/2
3/2
P
Q
Figure 6: A polygon that does not admit a grid polygon with Hausdorff distance smaller than 3/2.The brown line signifies an infinitesimally thin polygon.
2.2 Algorithm
To compute a grid polygon for a given polygon P with n edges, we need to determine the cellsin the sets Q1–Q4. This is easy once we know which cells intersect ∂P . One way to do this is totrace the edges of P in the grid. The time this takes is proportional to the number of crossingsbetween cells and ∂P . Let us denote the number of grid cells that intersect ∂P by b. Clearly, thereare simple polygons with Θ(nb) polygon boundary-to-cell crossings. We show how to achieve atime bound of O(n + B), where B is the number of cells in the output. The key idea is to firstcompute the Minkowski sum of ∂P with a square of side length 2 and use that to quickly find thecells intersecting ∂P .
5
P ′ P ′′P
Figure 7: A simple polygon P with its vertical decomposition, and the construction of P ′ and P ′′.
To compute this Minkowski sum we first compute the vertical decomposition of ∂P , see Fig. 7.For every of the O(n) quadrilaterals, determine the parts that are within vertical distance 1 fromthe bounding edges. The result P ′ is a simple polygon with holes with a total of O(n) edges,and ∂P ⊂ P ′. We compute the horizontal decomposition of every hole and the exterior of P ′
and determine all parts that are within horizontal distance 1 from the bounding edges. We addthis to P ′, giving P ′′. These steps take O(n) time if we use Chazelle’s triangulation algorithm [8].Essentially, the above steps constitute computing the Minkowski sum of ∂P with a square of sidelength 2, centered at the origin and axis-parallel.
Lemma 5 For any cell c, at most four edges of P ′′ intersect its boundary twice.
Proof. For any edge of P ′′, by construction, the whole part vertically above or below it overdistance at least 2 is inside P ′′, and the same is true for left or right. For any edge e that intersectsthe boundary of c twice, one side of that edge is fully in the interior of P ′′, and hence, cannotcontain other edges of P ′′. Hence, e can be charged uniquely to a corner of c. �
Corollary 1 The number of polygon boundary-to-cell crossings of P ′′ is O(n+ b), where b is thenumber of grid cells intersecting ∂P .
By tracing the boundary of P ′′, we can identify all cells that intersect it. Then we can determineall cells that intersect the boundary of P , because these are the cells that lie fully inside P ′′. Themodifications needed to find all cells whose module lies inside P are straightforward. In particular,we can find all cells whose module lies inside P , but have a neighbor for which this is not the casein O(n+ b) time. This allows us to find the O(B) cells selected in step Q1 in O(n+B) time. StepsQ2 and Q3 are now straightforward as well.
We now have a number of connected components of chosen grid cells. No component has holes,and if there are k components, we can connect them into one with only k − 1 extra grid cells. Wewalk around the perimeter of some component and mark all non-chosen cells adjacent to it. If a cellis marked twice, it is immediately removed from consideration. Cells that are marked once but areadjacent to two chosen cells will merge two different components. We choose one of them, then walkaround the perimeter of the new part and mark the adjacent cells. Again, cells that are markedtwice (possibly, both times from the new part, or once from the old and once from the new part) areremoved from consideration. Continuing this process unites all components without creating holes.
Theorem 4 For any simple polygon P with n edges, we can determine a set of B cells thattogether form a grid polygon Q in O(n + B) time, such that dH(P,Q), dH(∂P, ∂Q) ≤ 1
2
√2 and
dH(Q,P ), dH(∂Q, ∂P ) ≤ 32
√2.
2.3 Heuristic improvements
The grid polygon Q constructed in Section 2.1 does not follow the shape of P closely (see Fig. 4).Although the boundary of Q remains close to the boundary of P , it tends to zigzag around it dueto the way it is constructed. As a result, the symmetric difference between P and Q is relativelyhigh. We consider two modifications of our algorithm to reduce the symmetric difference between Pand Q while maintaining a small Hausdorff distance:
6
1. We construct Q4 with symmetric difference in mind.
2. We post-process the resulting polygon Q by adding, removing, or shifting cells.
Construction of Q4. Instead of picking cells arbitrarily when constructing Q4 we improve theconstruction with two goals in mind: (1) to directly reduce the symmetric difference between Pand Q, and (2) to enable the post-processing to be more effective. To that end, we construct Q4 byrepeatedly adding the cell c (not introducing holes) that has the largest overlap with P . These cellshence reduce the symmetric difference between P and Q the most.
Post-processing. After computing the grid polygon Q, we allow three operations to reduce thesymmetric difference: (1) adding a cell, (2) removing a cell, and (3) shifting a cell to a neighboringposition. These operations are applied iteratively until there is no operation that can reducethe symmetric difference. Every operation must maintain the following conditions: (1) Q issimply connected, and (2) the Hausdorff distance between P (∂P ) and Q (∂Q) is small. For thesecond condition we allow a slight relaxation with regard to the bounds of Lemma 3: dH(P,Q)and dH(∂P, ∂Q) can be at most 3
2
√2 (like dH(Q,P ) and dH(∂Q, ∂P )). This relaxation gives the
post-processing more room to reduce the symmetric difference.
3 Frechet distance
The Frechet distance dF between two curves is generally considered a better measure for similaritythan the Hausdorff distance. For an input polygon P , we consider computing a grid polygon Qsuch that dF (∂P, ∂Q) is bounded by a small constant. We study under what conditions on ∂P thisis possible and prove an upper and lower bound. However, if ∂P zigzags back and forth within asingle row of grid cells, any grid polygon must have a large Frechet distance: the grid is too coarseto follow ∂P closely. To account for this in our analysis, we introduce a realistic input model, asexplained below.
Narrow polygons. For a, b ∈ ∂P , we use |ab|∂P to denote the perimeter distance, i.e., the shortestdistance from a to b along ∂P . We define narrowness as follows.
Definition 1 A polygon P is (α, β)-narrow, if for any two points a, b ∈ ∂P with |ab| ≤ α,|ab|∂P ≤ β.
Given a value for α, we refer to the minimal β as the α-narrowness of a polygon. We assumeα < β, to avoid degenerately small polygons. We note that narrowness is a more forgiving modelthan straightness [3]. A polygon P is κ-straight if for any two points a, b ∈ ∂P , |ab|∂P ≤ κ · ‖a− b‖.A κ-straight polygon is (α, κα)-narrow for any α, but not the other way around. In particular,a finite polygon that intersects itself (or comes infinitesimally close to doing so) has a boundednarrowness, whereas its straightness becomes unbounded.
An upper bound. With our realistic input model in place, we can bound the Frechet distanceneeded for a grid polygon from above. In particular, we prove the following theorem.
Theorem 5 Given a (√
2, β)-narrow polygon P with β ≥√
2, there exists a grid polygon Q suchthat dF (∂P, ∂Q) ≤ (β +
√2)/2.
Proof. To prove the claimed upper bound, we construct Q via a grid cycle C that defines ∂Q.The construction is illustrated in Fig. 8. We define the square of a grid-graph vertex v to be the1× 1-square centered on v. Let C be the cyclic chain of vertices whose square is intersected by ∂P ,in the order in which ∂P visits them. We define a mapping µ between the vertices of C and ∂P . Inparticular, for each c ∈ C, let µ(c) be the “visit” of ∂P that led to c’s existence in C, that is, thepart of ∂P within the square of c. By construction, we have that ‖c− pc‖ ≤
√2/2 for all c ∈ C and
7
(a) (b) (c) (d)
Figure 8: Constructing Q for the upper bound on the Frechet distance. (a) Input polygon on thegrid and the squares it visits (shaded); initial state of C with revisited vertices slightly offset forlegibility. (b) Initial mapping µ (white triangles) between the vertices of C and ∂P . (c) Removal ofduplicate vertices in C, and its effect on µ. (d) Resulting cycle represents a grid polygon.
pc ∈ µ(c). The visits µ(c) and µ(c′) for two consecutive vertices, c and c′, in C intersect in a point(or, in degenerate cases, in a line segment) that lies on the common boundary of the squares of cand c′; let p denote such a point. For any point σ on the line segment between c and c′, we havethat ‖σ − p‖ ≤ max{‖c− p‖, ‖c′ − p‖} ≤
√2/2, as the Euclidean distance is convex (i.e., its unit
disk is a convex set). Hence, µ describes a continuous mapping on ∂P and acts as a witness fordF (∂P,C) ≤
√2/2.
However, C may contain duplicates and thus not describe a grid polygon Q. We argue here thatwe can remove the duplicates and maintain µ in such a way that it remains a witness to prove thatdF (∂P,C) ≤ (β +
√2)/2. Let c and c′ be two occurrences in C of the same vertex v. Let p ∈ µ(c)
and p′ ∈ µ(c′), both in the square of v. As they lie within the same square, ‖p− p′‖ ≤√
2 and hencewe know that |pp′|∂P ≤ β. Hence, at least one of the two subsequences of C strictly in between cand c′ maps via µ to a part of ∂P that has length at most β. We pick one such subsequence andremove it as well as c′ from C. We concatenate to µ(c) the mapped parts of ∂P from the removedvertices. As the length of the mapped parts is bounded by β, the maximal distance between anypoint on these mapped parts is β/2 +
√2/2. Hence, after removing all duplicates, we are left with a
cycle C, with µ as a witness to testify that dF (∂P,C) ≤ (β +√
2)/2.
If C contains at least three vertices, it describes a grid polygon and we are done. However, if Cconsists of at most two vertices, then it does not describe a grid polygon. We can extend C easilyinto a 4-cycle for which the bound still holds (Lemma 8, Appendix B). �
The proof of the theorem readily leads to a straightforward algorithm to compute such a gridpolygon. The construction poses no restrictions on the order in which to remove duplicates andthe decisions are based solely on the lengths of µ(v). Hence, the algorithm runs in linear time bywalking over P to find C and handling duplicates as they arise.
Lower bound. To show a lower bound, we construct a (√
2, β)-narrow polygon P for which thereis no grid polygon with Frechet distance smaller than 1
4
√β2 − 2 to P , for any β >
√2. First,
construct a polygonal line L = (p1, . . . , pn), where n = 2⌈14
√β2 − 2
⌉+ 1. Vertex pi is (0, i/2) if i is
odd and (12√β2 − 2, i/
√2) otherwise. Now, consider a regular k-gon with side length (n− 1)/
√2
and k ≥ 4 such that its interior angle is not smaller than ϕ = arccos (1− 4/β2). Assume the k-gonhas a vertical edge on the right-hand side. We replace this edge by L to construct our polygon P .Fig. 9 shows a polygon for k = 4 (β ≥ 2) and for k = 7 (β < 2).
The two lemmas below readily imply our lower bound on the Frechet distance. The proof of thefirst can be found in Appendix B.
Lemma 6 The polygon P described above is (√
2, β)-narrow.
Lemma 7 For constructed polygon P and any grid polygon Q, dF (∂P, ∂Q) ≥ 14
√β2 − 2.
8
√2
p1
p2
pn pn−1
12
√β2 − 2
ϕ
p1
pn
p2
Figure 9: Polygon P (left) for which any grid polygon will have high Frechet distance (center);polygon P for β < 2 (right).
Proof. We show this by contradiction: assume that a grid polygon Q exists with dF (∂P, ∂Q) = ε <14
√β2 − 2. For any vertex pi of P , there must be a point qi ∈ ∂Q (not necessarily a vertex) such
that ‖pi − qi‖ < ε. Moreover, these points q1, . . . , qn need to appear on ∂Q in order. Equivalently,if we draw disks with radius ε centered at p1, . . . , pn, curve ∂Q needs to visit these disks in order.
The disks centered at p1, p3, . . . , pn never intersect the disks centered at p2, p4, . . . , pn−1. Inparticular, the disks centered at p1, p3, . . . , pn are all to the left of the vertical line v : x = 1
4
√β2 − 2,
and all disks centered at p2, p4, . . . , pn−1 are all to the right of this line. Hence, between q1 and q2,∂Q must contain at least one horizontal line segment crossing line v to the right, and between q2and q3 there must be at least one horizontal segment crossing v to the left, and so on until we reachqn. Since Q is simple, this requires that the difference between the maximum and the minimumy-coordinate of the these horizontal segments on ∂Q is at least n− 1. The y-difference between p1and pn is only (n− 1)/
√2. This implies dF (∂P, ∂Q) ≥ n− 1− (n− 1)/
√2 > 1
4
√β2 − 2 and thus
contradicts our assumption. �
Theorem 6 For any β >√
2, there exists a (√
2, β)-narrow polygon P such that dF (∂P, ∂Q) ≥14
√β2 − 2 holds for any grid polygon Q.
4 Experiments
Figure 10: The input categories.
Here, we apply our algorithms to a set of polygons that canbe encountered in practice. We investigate the performanceof the Hausdorff algorithm and its heuristcs as well as theFrechet algorithm. Moreover, we consider the effects of gridresolution and the placement of the input.
Data set. We use a set of 34 polygons: 14 territorial outlines(countries, provinces, islands), 11 building footprints and9 animal silhouettes (see Fig. 10 for six examples; a full listis given in Appendix D.1). We scale all input polygons suchthat their bounding box has area r; we call r the resolution.Unless stated otherwise, we use r = 100. This scaling is usedto eliminate any bias introduced from comparing differentresolutions.
4.1 Symmetric difference
We start our investigation by measuring the symmetric difference between the input and outputpolygon. If the symmetric difference is small, this indicates that the output is similar to the input.We normalize the symmetric difference by dividing it by the area of the input polygon. The resultsof our algorithms depend on the position of the input polygon relative to the grid. Hence, for
9
Table 1: Normalized symmetric difference, as an increase percentage w.r.t. optimal, of thealgorithms. Note that “optimal” here means optimal for the symmetric difference when not insistingon a connected set of cells. For the Hausdorff algorithm, results for the various heuristic improvementsare shown. In the second row, None means that no postprocessing heuristic was used; A, R and Smean additions, removals and shifts, respectively. In the third row, 3 and 7 indicate whether Q4
was chosen arbitrarily (7) or using the symmetric difference heuristic (7).
Optimal Hausdorff Frechet
postproc. None A / R A / R / S
Q4 heur. 7 3 7 3 7 3
Maps 0.223 + 316 % + 238 % + 39 % + 3 % + 11 % + 3 % + 23 %Buildings 0.257 + 270 % + 197 % + 47 % + 9 % + 21 % + 8 % + 17 %Animals 0.333 + 246 % + 188 % + 60 % + 12 % + 29 % + 11 % + 8 %
every input polygon we computed the average normalized symmetric difference over 20 randomplacements.
Computing a (simply connected) grid polygon that minimizes symmetric difference is NP-hard [21].Hence, as a baseline for our comparison, we compute the set of cells with the best possible symmetricdifference by simply taking all cells that are covered by the input polygon for at least 50 %. This setof cells is optimal with respect to symmetric difference but may not be simply connected. It canhence be thought of as a lower bound.
Overview. In Table 1, we compare the Frechet algorithm and the various instantiations of theHausdorff algorithm in terms of the (normalized) symmetric difference. The second column lists theaverage symmetric difference of the symmetric-difference optimal solution, calculated as describedabove. The other columns are hence given as a percentage representing the increase with respect tothe optimal value. We aggregated the results per input type; the full results are in Appendix D.
The table tells us that, with the use of heuristics, the Hausdorff algorithm gets quite close to theoptimal symmetric difference, while still bounding the Hausdorff distance as well as guaranteeing agrid polygon. The Frechet algorithm is performing more poorly in comparison, though interestinglyperforms better on the animal contours.
Fig. 11 shows three solutions for one of the input polygons: symmetric-difference optimal, Frechetalgorithm and Hausdorff algorithm with heuristics. The symmetric-difference optimal solution lookslike the input, but consists of multiple disconnected polygons. The result of the Frechet algorithmis a single grid polygon, but the algorithm cuts off at narrow parts. The result of the Hausdorffalgorithm is also a single grid polygon, but does not have to cut off parts when input is narrow.
Below, we examine the effect of the different heuristics for the Hausdorff algorithm to explain itssuccess. Moreover, we show that the performance of the Frechet algorithm is highly dependent onthe grid resolution.
Figure 11: Example outputs for the symmetric-difference optimal algorithm (left), the Frechetalgorithm (center) and the Hausdorff algorithm (right). Note that the first does not yield a gridpolygon.
10
c
Figure 12: Without the heuristic for the Q4 construction (a), the algorithm gets stuck in the postprocessing phase (b). The smart Q4 construction gives a better starting point (c) resulting in thedesired shape (d).
no post-processing additions / removals shifts
Figure 13: Without allowing shifts, the post-processing phase cannot move the cells in the middleto coincide with the input polygon. With shifts, this is possible.
Hausdorff heuristics. Table 1 shows that using the heuristic for Q4 makes a tremendous difference,especially if a postprocessing heuristic is used as well. Fig. 12 illustrates this finding with four resultson the same input. In (a–b) Q4 is chosen arbitrarily and the resulting shape does not look like theinput—even after postprocessing. In particular, the postprocessing heuristic cannot progress further:the cell marked c cannot be added to Q since that would increase the symmetric difference. In (c–d)Q4 is chosen using the heuristic; it provides a better initial solution which allows the postprocessingto create a nice result.
In the postprocessing heuristic, allowing or disallowing shifts can influence the result. See forexample Fig. 13. Without shifts, the heuristic cannot move the connection between the two ends ofthe input polygon to the correct location as it would first need to increase the symmetric difference.With a series of diagonal shifts this can be achieved. Our experiments show that in practice allowingshifts indeed decreases the symmetric difference. However, the effect is only marginal if we use theheuristic for the Q4 construction. Hence, we conclude that shifts only significantly improve theresult if Q4 is chosen badly.
Resolution and placement. While developing our algorithm we noticed that not just the gridresolution but also the placement of the input polygon effected the symmetric difference. Hence weset up experiments to investigate these factors. First we tested how much the resolution influencesthe symmetric differences. In Table 2, the results are shown, averaged over all 34 inputs. Asexpected, for all algorithms, the normalized symmetric difference decreases when the resolutionincreases.
Table 2: Normalized symmetric difference for the various algorithms on five resolutions.
r = 100 r = 225 r = 400 r = 625 r = 900
Optimal 0.263 0.188 0.147 0.119 0.101Hausdorff 0.282 0.201 0.155 0.123 0.103
Frechet 0.306 0.227 0.184 0.148 0.122
11
To investigate how much the results of our algorithms depend on the placement of the inputpolygon, we compared the minimal, maximal and average symmetric difference over 20 runs of thealgorithms. The polygons were placed randomly for each run, but per polygon the same 20 positionswere used for all three algorithms. The results of this experiment are shown in Appendix D, Table 8.For every input polygon and algorithm, the minimum, average and maximum symmetric differenceof all 20 runs is shown. The difference between the minimum and the maximum symmetric differencefor each algorithm / polygon combination is rather large. We found that placement can have asignificant effect on the achieved symmetric difference. Hence, if the application permits us tochoose the placement, it is advisable to do so to obtain the best possible result. This leads to aninteresting open question of whether we can algorithmically optimize the placement, to avoid theneed to find a good placement with trial and error. In the upcoming analysis, we also consider theeffect of resolution and placement, with respect to the Frechet distance.
4.2 Frechet analysis
Theorem 5 predicts an upper bound on the Frechet distance based on√
2-narrowness. However,if the points defining the narrowness lie within different squares of grid vertices, this bound maybe naive. Moreover, it assumes a worst-case detour, going away in a thin triangle to maximize thedistance between the detour and a doubly-visited cell. Hence, the algorithm has the potential toperform better, depending on the actual geometry and its placement with respect to the grid. Here,we discuss our investigation of these effects; refer to Appendix D.2 for more details.
Procedure. We use the 34 polygons described in Appendix D.1. As we may expect the gridresolution to significantly affect results, we used 20 different resolutions. In particular, we useresolutions varying from 10 000 to 25, using (100/s)2 with scale s ∈ {1, . . . , 20}.
For each resolution-polygon combination (case), we measure its√
2-narrowness (using the algorithmdescribed in Appendix C) and derive the predicted upper bound. Then, we run the Frechet algorithm,using the 25 possible offsets in {0, 0.2, 0.4, 0.6, 0.8}2, and measure the precise Frechet distance betweeninput and output. We keep track of three summary statistics for each case: the minimum (best),average (“expected”) and maximum (worst) measured Frechet distance.
Effect of placement. We consider placement with respect to the grid (offset) to have a significanteffect on the result computed for a polygon, if the difference between the maximal and minimalFrechet distance over the 25 offsets is at least 2. Almost 30 % of cases exhibit such a significanteffect, with the animal contours being particularly affected (35 % significant). Again, this raises thequestion of whether we can algorithmically determine a good placement.
Upper bound quality. We define the performance as the measured Frechet distance as a percentageof the upper bound. We consider the algorithm’s performance significantly better than the upperbound, if it is less than 40 %. Using the best placement, over 95 % of cases perform significantly better.Averaging performance over placement, we still find such a majority (over 81 %). Interestingly, thisdrop is mostly due to the animal contours, of which only 63 % now perform significantly better.Thus, although we have a provable upper bound, we may typically expect our simple algorithm toperform significantly better than the upper bound. This holds even without any postprocessing tofurther optimize the result and when taking a random offset.
Effect of resolution. The influence of the resolution on the above results does not seem to exhibita clear pattern. Nonetheless, resolution likely plays an important role in these results, but not asstraightforward as either low or high resolution being more problematic. Instead, it is likely themost problematic resolutions are those at which the
√2-narrowness of the polygon jumps as a new
pair of edges comes within distance√
2 of each other. However, an in-depth investigation of this isbeyond the scope of this paper.
Heuristic improvement. In contrast to the Hausdorff algorithm, the Frechet algorithm needs noheuristic improvement on inputs that are not too narrow. However, badly placed narrow polygons
12
can be problematic: large parts of the polygon may be cut, greatly diminishing similarity. A solutionmay be to select an appropriate resolution (if our application permits us to). In our experiments thealgorithm tends to perform well at resolutions where the symmetric-difference optimal solution is asingle grid polygon. The advantage of our Frechet algorithm is that it guarantees a grid polygon onall outputs and bounds the Frechet distance.
Figure 14: Red cells cause acut-off and have high sym-metric difference.
Nonetheless, we may want to consider heuristic postprocessing toobtain a locally-optimal result. If we want to do this in terms ofthe symmetric difference, we may use similar techniques as for theHausdorff algorithm. However, this does not perform well: the narrowstrip that causes the Frechet algorithm to perform badly tends toeffect a high symmetric difference for the nearby grid cells (Fig. 14).As such, the result is already (close to) a local optimum in terms ofthe symmetric difference.
5 Conclusion
We presented two algorithms to map simple polygons to grid polygons that capture the shape ofthe polygon well. For measuring the distance between the input and the output, we considered theHausdorff and the Frechet distance. We achieved a constant bound on the Hausdorff distance; forthe Frechet distance we require a realistic input assumption to achieve a constant bound. We alsoevaluated our algorithms in practice. Although the Hausdorff algorithm does not produce greatresults directly, the algorithm achieves good results when combined with heuristic improvements.The Frechet algorithm, on the other hand, struggles with narrow polygons, and it is not clear howto improve the results using heuristics. Designing an algorithm for the Frechet distance that alsoworks well in practice remains an interesting open problem. Another interesting open problem isto algorithmically optimize the placement of the input polygon, for the best results of both theHausdorff and the Frechet algorithm.
13
References
[1] Helmut Alt, Bernd Behrends, and Johannes Blomer. Approximate matching of polygonalshapes. Annals of Mathematics & Artificial Intelligence, 13(3-4):251–265, 1995.
[2] Helmut Alt and Michael Godau. Computing the Frechet distance between two polygonal curves.International Journal of Computational Geometry & Applications, 5:75–91, 1995.
[3] Helmut Alt, Christian Knauer, and Carola Wenk. Comparison of distance measures for planarcurves. Algorithmica, 38(1):45–58, 2003.
[4] Ernst Althaus, Friedrich Eisenbrand, Stefan Funke, and Kurt Mehlhorn. Point containment inthe integer hull of a polyhedron. In Proceedings of the 15th Annual ACM-SIAM Symposium onDiscrete Algorithms (SODA), pages 929–933, 2004.
[5] K. Joost Batenburg, Sjoerd Henstra, Walter A. Kosters, and Willem Jan Palenstijn. Construct-ing simple nonograms of varying difficulty. Pure Mathematics and Applications (Pu. MA),20:1–15, 2009.
[6] Daniel Berend, Dolev Pomeranz, Ronen Rabani, and Ben Raziel. Nonograms: Combinatorialquestions and algorithms. Discrete Applied Mathematics, 169:30–42, 2014.
[7] Rafael G. Cano, Kevin Buchin, Thom Castermans, Astrid Pieterse, Willem Sonke, and BettinaSpeckmann. Mosaic drawings and cartograms. Computer Graphics Forum, 34(3):361–370, 2015.
[8] Bernard Chazelle. Triangulating a simple polygon in linear time. Discrete & ComputationalGeometry, 6:485–524, 1991.
[9] Jinhee Chun, Matias Korman, Martin Nollenburg, and Takeshi Tokuyama. Consistent digitalrays. Discrete & Computational Geometry, 42(3):359–378, 2009.
[10] Mark de Berg, Dan Halperin, and Mark H. Overmars. An intersection-sensitive algorithm forsnap rounding. Computational Geometry, 36(3):159–165, 2007.
[11] Olivier Devillers and Philippe Guigue. Inner and outer rounding of boolean operations onlattice polygonal regions. Computational Geometry, 33(1-2):3–17, 2006.
[12] Michael T. Goodrich, Leonidas J. Guibas, John Hershberger, and Paul J. Tanenbaum. Snaprounding line segments efficiently in two and three dimensions. In Proceedings of the 13thAnnual Symposium on Computational Geometry (SoCG), pages 284–293, 1997.
[13] Daniel H. Greene and F. Frances Yao. Finite-resolution computational geometry. In Proceedingsof the 27th Annual Symposium on Foundations of Computer Science (FOCS), pages 143–152,1986.
[14] Warwick Harvey. Computing two-dimensional integer hulls. SIAM Journal on Computing,28(6):2285–2299, 1999.
[15] John Hershberger. Stable snap rounding. Computational Geometry, 46(4):403–416, 2013.
[16] Alon Itai, Christos H. Papadimitriou, and Jayme Luiz Szwarcfiter. Hamilton paths in gridgraphs. SIAM Journal on Computing, 11(4):676–686, 1982.
[17] Reinhard Klette and Azriel Rosenfeld. Digital Geometry – geometric methods for digital pictureanalysis. Morgan Kaufmann, 2004.
14
[18] Reinhard Klette and Azriel Rosenfeld. Digital straightness – a review. Discrete AppliedMathematics, 139(1-3):197–230, 2004.
[19] Johannes Kopf, Ariel Shamir, and Pieter Peers. Content-adaptive image downscaling. ACMTransactions on Graphics, 32(6):Article No. 173, 2013.
[20] Wouter Meulemans. Similarity Measures and Algorithms for Cartographic Schematization.PhD thesis, Technische Universiteit Eindhoven, 2014.
[21] Wouter Meulemans. Discretized approaches to schematization. CoRR, 2016.
[22] Emilio G. Ortız-Garcıa, Sancho Salcedo-Sanz, Jose M. Leiva-Murillo, Angel M. Perez-Bellido,and Jose Antonio Portilla-Figueras. Automated generation and visualization of picture-logicpuzzles. Computers & Graphics, 31(5):750–760, 2007.
15
A Hausdorff distance
Theorem 1 [repeated] Given a polygon P , it is NP-hard to decide whether there exists a gridpolygon Q such that both dH(∂P, ∂Q) ≤ 1/2 and dH(∂Q, ∂P ) ≤ 1/2.
Proof. We reduce from the problem of finding a Hamiltonian cycle in a (“partial”) grid graph [16].Given such a grid graph G, we construct a polygon P such that a Hamiltonian cycle in G exists ifand only if there exists a grid polygon Q such that both dH(∂P, ∂Q) ≤ 1/2 and dH(∂Q, ∂P ) ≤ 1/2.
To construct P from G, we replace the edges of G with edge gadgets (see Fig. 15) and vertices ofG with vertex gadgets (see Fig. 16).
Edge gadget. The edge gadget consists of two “zigzag” polygonal chains following the grid that areplaced ε-close to each other for a small constant ε. The area between these chains will eventuallybecome the interior of polygon P . In the middle of the zigzag, we cut off two corners, as illustrated.As a result, a closest point on the zigzag chain to the middle of the red segment in Fig. 15 (top) is1/√
2 distance away, and thus the boundary of the grid polygon Q cannot pass through this segment.Moreover, the distance from any of the red points in the figure to the chain is larger than 1/2. Byconstruction there will be no other parts of P closer than 1/2 to any of the red points. Therefore,∂Q cannot pass through them. Furthermore, ∂Q must pass through all the green points, otherwisethe Hausdorff distance from ∂P to ∂Q would be too large. Therefore we can conclude that thereare only two ways of covering the edge with ∂Q shown in the Fig. 15 (middle and bottom).
Vertex gadget. The vertex gadget consists of four pieces of polygonal chains forming a cross-likepattern such that along every branch of the cross there are two polygonal chains that are placedε-close to each other. This is schematically illustrated in Fig. 16 (left); observe that to obtain the1/2 bound, we must be careful with this construction, moving the edges inward appropriately toensure that all connections are possible within the desired Hausdorff distance, this is shown inFig. 17. The area between these parts of chains will also eventually become the interior of polygonP . There are nine grid points in the vertex gadget that need to be traversed by the boundaryof the grid polygon Q to achieve a Hausdorff distance of 1/2. Consider an example of a degree-3vertex gadget connected to three edge gadgets in Fig. 18. Similarly to the edge gadget case we canargue that ∂Q must pass through all green points and cannot pass through any of the red pointsto achieve the Hausdorff distance of 1/2. Considering this case, and also the cases of 1-, 2-, and
Figure 15: Edge gadget (top): the red segmentcannot lie on ∂Q because the Hausdorff dis-tance from the middle point to the chain is1/√
2 > 1/2. There are two ways of coveringthe edge construction with a grid chain with theHausdorff distance 1/2 (middle and bottom).
Figure 16: Vertex gadget (left) can be connectedwith up to four edges. There are two ways ofcovering the vertex gadget with a polygonalchain within the Hausdorff distance 1/2 (middleand right). Dashed edges can be extended tocover a half of an adjacent edge.
16
Figure 17: The precise construction of thevertex gadget, to ensure a Hausdorff distanceof 1/2 with constant ε.
Figure 18: An example of a degree-3 vertexgadget connected to three edge gadgets. ∂Qmust pass through all green points and cannotcannot pass through red points.
4-degree vertices, we can observe the following: a chain of ∂Q must enter the vertex along one ofthe adjacent edges following the “zigzag” pattern from the Fig. 15 (middle), cover the nine gridpoints, and leave along another adjacent edge following the same “zigzag” pattern. If the vertexhas more adjacent edges, those edges can only be partially covered with the U-turn pattern fromthe Fig. 15 (bottom); the cut-off corners ensure that the U-turn cannot pass the middle of theedge-construction. A vertex gadget can be entered by ∂Q only once. The two ways for ∂Q to enterand exit the vertex gadget are shown in Fig. 16 (center and right).
Putting the gadgets together. Now, given a grid graph G, replace its vertices with vertex gadgets,and replace its edges with edge gadgets, and connect their corresponding pairs of polygonal chains.This construction leads to a polygon P ′ that may have holes. To make a simple polygon P out ofP ′, we cut some of the edges of G to break all the cycles (see Fig. 19 (top left)). We introduce smallcuts in the corresponding edge gadgets and reconnect the pairs of polygonal chains (see Fig. 19 (topright)). Thus, all the polygonal chains are connected in a cycle now forming a simple polygon P .The small cuts in the edge gadgets do not affect the way that it can be covered with ∂Q.
Suppose there is a Hamiltonian cycle in G (see Fig. 19 (bottom left)). It is straightforward toconstruct a grid polygon Q with the Hausdorff distance 1/2 from its boundary to ∂P and vice versa.The edge gadgets corresponding to the edges in G that belong to the Hamiltonian cycle are coveredby ∂Q following a “zigzag” pattern, and the edge gadgets corresponding to the edges in G that donot belong to the Hamiltonian cycle are covered by two pieces of ∂Q following a U-turn patterncoming from the two adjacent vertices (see Fig. 19 (bottom right)).
Now, suppose there is a grid polygon Q such that dH(∂P, ∂Q) ≤ 1/2 and dH(∂Q, ∂P ) ≤ 1/2. ∂Qcan only pass through the grid points marked with green dots in the Fig. 15 (top) and Fig. 16 (left),otherwise the Hausdorff distance to the input polygon is too large. Thus, every vertex gadget musthave two adjacent edge gadgets covered by ∂Q following the “zigzag” pattern. The edges of the gridgraph G corresponding to these edge gadgets form a Hamiltonian cycle, because the grid polygon Qis simple.
Therefore, a Hamiltonian cycle in G exists if and only if there exists a grid polygon Q such thatboth dH(∂P, ∂Q) ≤ 1/2 and dH(∂Q, ∂P ) ≤ 1/2. �
17
Figure 19: Given a grid graph G (top left), we construct a simple polygon P (top right), such thatif and only if there exists a Hamiltonian cycle in G (bottom left), there exists a grid polygon Qwith both dH(∂P, ∂Q) ≤ 1
2 and dH(∂Q, ∂P ) ≤ 12 (bottom right).
18
B Upper and lower bounds on the Frechet distance
Lemma 8 Let P be a (√
2, β)-narrow polygon. Let C be the cycle in the construction of Theorem 5for P after removing all duplicates. If C consists of at most two vertices, a 4-cycle C ′ exists withdF (∂P,C ′) ≤ (β +
√2)/2.
Proof. If C is one vertex v, we make it into a simple 4-cycle, picking the direction of extensionsuch that at least one point of ∂P lies in that direction from v as well. We can map the entireextension onto this point, which has distance at most
√2 ≤ (β +
√2)/2 by our assumption on β;
mapping v to the entire ∂P then proves the necessary bound.If C contains two vertices, u and v, we first observe that µ(v) starts and ends on the boundary
of the square of v, as this holds initially and is maintained during the removal of duplicates. Inparticular, that means that there is a point on the common boundary between the squares of u andv and µ(u) and µ(v) end there. As for the single-vertex case, we extend into a simple 4-cycle in thedirection of this point, and map the extension onto it (causing distance at most
√2). Together with
µ(u) and µ(v), this acts as a witness for the necessary bound on the Frechet-distance. �
Lemma 6 [repeated] The polygon P described above is (√
2, β)-narrow.
Proof. We must show that |ab|∂P ≤ β holds for any two points a, b ∈ ∂P with ‖a− b‖ ≤√
2. Notethat a and b either lie on the same boundary segment of ∂P , on two consecutive segments, or ontwo consecutive parallel segments of L (i.e., on pi−1pi and pipi+1 for some 1 < i < n): otherwisethe Euclidean distance between a and b would be larger than
√2. If the two points lie on the same
segment, then the distance between a and b along the polygon boundary |ab|∂P = ||a− b|| ≤√
2 < β.Now assume that a and b lie on two consecutive segments of the boundary of P . Denote the
common point of the two segments to which a and b belong as p. By construction, ∠apb ∈ [ϕ, π)where ϕ = arccos (1− 4
β2 ). As the Euclidean distance is convex, symmetry implies that the value
of ‖a− p‖+ ‖p− b‖ is maximized when ‖a− p‖ = ‖p− b‖ and ‖a− b‖ =√
2 (see also Lemma 10,Appendix C). Therefore, using the law of cosines, we can conclude that |ab|∂P = ‖a− p‖+ ‖p− b‖ ≤
2√1−cosϕ = β.
Finally, assume that a and b lie on two consecutive parallel segments pi−1pi and pipi+1 for some1 < i < n. W.l.o.g., let a lie on segment pi−1pi and let i be even. Then observe that the x-coordinateof b is not greater than the x-coordinate of a, otherwise the Euclidean distance between a and bwould be larger than
√2. Therefore, the distance between a and b along ∂P is not greater than the
length of two boundary edges forming a spike, i.e., |ab|∂P ≤ β. �
19
C Measuring narrowness
We bounded the Frechet distance needed for a grid polygon, depending on the√
2-narrowness ofthe input polygon. An important question to ask is then how narrow realistic inputs really are. Webriefly describe how to compute the α-narrowness of a polygon P in quadratic time. To this end,we must find the pair of points p, q on ∂P with ‖p− q‖ ≤ α such that |pq|∂P is maximized; we callsuch a pair an (α-narrow) witness. If we consider |pq|∂P for some fixed p, then we see that thisfunction has a single maximum with value |P |/2. In particular, this implies the observation below,and inspires the two subsequent lemmas. From these statements, the algorithm readily follows.
Observation 1 An α-narrow witness (p, q) of P satisfies ‖p− q‖ = α or |pq|∂P = |P |/2.
Lemma 9 Let e = (t, u) and e′ = (v, w) be two edges of P , and assume |uv|∂P is known. Wecan determine in constant time whether there is a p ∈ e and q ∈ e′ such that ‖p − q‖ ≤ α and|pq|∂P = |P |/2.
Proof. We express p ∈ e as a function of λp ∈ [0, 1]: p = t(1−λp)+uλp. Analogously, for λq ∈ [0, 1]we have q = v(1− λq) + wλq.
The condition |pq|∂P = |P |/2 can now be written as ‖p− u‖+ |uv|∂P + ‖v − q‖ = |P |/2, which,using the above expressions leads us to (1 − λp)‖t − u‖ + |uv|∂P + λq‖v − w‖ = |P |/2. We mayrewrite this to λq = (|P |/2− (1− λp)‖t− u‖ − |uv|∂P )/‖v − w‖ = (|P |/2− ‖t− u‖ − |uv|∂P )/‖v −w‖+ λp‖t− u‖/‖v − w‖. To make this expression simpler, we introduce R = ‖t− u‖/‖v − w‖ andC = (|P |/2− ‖t− u‖ − |uv|∂P )/‖v − w‖. Then, we find λq = C +Rλp.
As above, we can write ‖p− q‖ ≤ α to ‖t(1−λp) +uλp− (v(1−λq) +wλq)‖ ≤ α. Substituting theexpression for λq, we obtain ‖t(1− λp) + uλp − (v(1−C −Rλp) +w(C +Rλp))‖ = ‖(t− v + vC −wC) + (u+vR− t−wR)λp‖ ≤ α. Introducing c = t−v+vC−wC and r = u+vR− t−wR, we get‖c+ rλp‖ ≤ α. Writing out the Euclidean distance, this becomes (cx + rxλp)
2 + (cy + ryλp)2 ≤ α2
which is a quadratic equation: (r2x + r2y)λ2p + 2(cxrx + cyry)λp + (c2x + c2y − α2) ≤ 0.
Solving this quadratic equation, yields us an interval describing the points on the line spannedby e that satisfy the two conditions. If this interval does not overlap [0, 1], then there are nosolutions. Otherwise, let [λp,1, λp,2] denote the intersection of the computed interval with [0, 1]. Viaλq = C+Rλp, this projects an interval on the line spanned by e′ containing the points correspondingto the points described by [λp,1, λp,2]. There is now a solution satisfying both equations if thisprojected interval intersects [0, 1]. �
Lemma 10 Let P be a (α, β)-narrow polygon with β < |P |/2. P has an α-narrow witness (p, q)such that ‖p− q‖ = α and at least one of the following holds: (1) p is a vertex of P ; (2) p and q lieon nonparallel edges of P and are equidistant from the intersection of the lines spanned by theseedges.
Proof. Observation 1 implies that a witness satisfies ‖p− q‖ = α. Consider such a witness (p, q)that does not adhere to either (1) or (2). Without reducing |pq|∂P we transform the witness into onethat does (refer to Fig. 20). Let `p and `q denote the lines spanned by the edges containing p and qrespectively; let c denote their intersection. Both p and q have a direction along their respectivelines for which |pq|∂P increases if we keep the other fixed. Note that if the direction would change atany point, we would have a maximum value and thus a witness showing that P is (α, |P |/2)-narrow,contradicting the assumption.
If at least one direction points to c or if the lines are parallel, we simultaneously slide p and q (atthe same speed) into that direction without increasing ‖p− q‖ or decreasing |pq|∂P . At some point,a vertex of P must be found and thus we have a witness that adheres to (1).
If the lines are not parallel and both directions point away from c, we argue as follows. Considerthe inverse case (p′, q′), where we place p′ on `p such that ‖p′ − c‖ = ‖q − c‖ and q′ on `q such that
20
`p
`q
p
q
c
`p
`q
p
c
`p
`q
p
c
q′
p′p∗
q∗q
q
(a) (b) (c)
Figure 20: (a-b) Moving p and q towards c does not decrease |pq|∂P nor increase ‖p− q‖; we can doso until we hit a vertex. (c) Inverse case (p′, q′) has distance at most α; the midpoint (p∗, q∗) thusdefines an equidistant witness.
‖q′ − c‖ = ‖p− c‖. Since ‖p′ − p‖ = ‖q′ − q‖, ‖p′ − q′‖ ≤ α; note that p′ and q′ need not lie on theedges containing p and q. Convexity of the Euclidean distance implies that, as we move p to p′
and q to q′ simultaneously at the same speed the points remain within distance α and |pq|∂P doesnot change. In particular, halfway, we find a witness (p∗, q∗) that are equidistant to c. If either por q hits before reaching (p∗, q∗), we are done and found a witness adhering to (1). Otherwise, if‖p∗ − q∗‖ < α, we may move them again simultaneously away from c (thus increasing |p∗q∗|∂P ),until we either hit a vertex—adhering to (1)—or until the distance is exactly α—adhering to (2). �
21
D Experiments
In this appendix we present more details for our experiments.
D.1 Experimental inputs
We used a total of 34 simple polygons to fuel our experiments. They can be categorized as territorialoutlines, building footprints and animal contours. The former two target schematization purposesand the latter the construction of nonograms.
Territorial outlines. We used 14 territorial outlines (e.g. countries, provinces, islands), as illustratedin Fig. 21. We tried to vary the geographic extent and nature of the outlines. In particular,we have two continents (Africa and Antarctica), three provinces (Noord Brabant, Limburg andLanguedoc-Roussillon), and the largest contiguous part of 9 countries (Australia, Brazil, China,France, Greece, Italy, Switzerland, Great Britain, Vietnam). With this choice, the outlines containa mix of regions defined by shorelines, territorial borders or a combination of these. Moreover, thegeographic extent varies from small to large-scale regions.
Building footprints. Our data set contains 11 buildings (Fig. 22). It contains a mix of complexbuildings (Bld 1, terminal of Logan Airport in Boston (MA); Bld 5, high school in Chicago; Bld6, stadium in Chicago; Bld 11, university building at TU Eindhoven), castles (Bld 2–4) and lowcomplexity buildings (Bld 7–10).
Animal contours. Finally, our experiments also consider 9 animal contours (Fig. 23). In particular,we chose these inputs to achieve an expected variety of narrowness. For example, the spiderintuitively is more narrow than the turtle.
D.2 Frechet analysis
Procedure. We use the 34 polygon described in Appendix D.1. As we may expect the grid resolutionto significantly affect results, we used 20 different resolutions. In particular, we use resolutionsvarying from 10 000 to 25, using (100/s)2 with scale s ∈ {1, . . . , 20}.
For each resolution-polygon combination (case), we measure its√
2-narrowness (see Appendix Cfor the algorithm) and derive the predicted upper bound. Then, we run the Frechet algorithm, usingthe 25 possible offsets in {0, 0.2, 0.4, 0.6, 0.8}2, and measure the precise Frechet distance betweeninput and output. We keep track of three summary statistics for each case: the minimum (best),average (“expected”) and maximum (worst)measured Frechet distance.
Effect of placement. We define the placement effect as the difference between between the maximaland minimal Frechet distance. We consider the effect significant if it is at least 2. These differencesare listed in Table 3. Almost 30% of cases exhibit such a significant effect, with the animal contoursbeing particularly affected (35% significant). Eight cases even have a difference over 10, with themaximal difference slightly under 55.
If we look at the difference with the average Frechet distance, we find a much less pronouncedeffect (see Table 4). Only 6.5% of cases have a significant difference, most of these buildings (9.1%)and the least with territorial outlines (3.6%).
We conclude that a bad placement is quite likely to have a drastic effect on the algorithm’sperformance, but the potential gain when optimizing the placement instead of picking a randomone is limited.
Upper bound quality. Let us now turn to the relation between the predicted upper bound and theactual Frechet distance achieved by the algorithm. We define the performance as the measuredFrechet distance expressed as a percentage of the upper bound. We consider the algorithm’sperformance significantly better than the upper bound, if its performance is less than a veryconservative 40%.
22
Using the best placement (Table 5), over 95% of cases perform significantly better than the upperbound predicts. The worst case of the best placements is even only only 63 percent.
Averaging performance over placement (Table 6), we still find such a majority (over 81%) to havea significantly better performance. Interestingly, this drop is mostly due to the animal contours, ofwhich only 63% now perform significantly better. The average performance over all cases is around30 percent.
Only when we look at the worst performing offset for each case (Table 7), we see that a largenumber of cases start to fail to drop below the 40-percent significant threshold. The averageperformance of these cases is around 44 percent. We also note that we never achieve the actualupper bound. Though we can likely construct a polygon that may come close to the upper bound,this suggests that still this might not be realistic for the types of inputs considered here.
Thus, although we have a provable upper bound, we may typically expect our simple algorithmto perform significantly better than the upper bound. This holds even without any postprocessingto further optimize the result and when taking a random offset.
Effect of resolution. Resolution does not exhibit a clear pattern in the two analyses above. Forplacement, we may see that effects may occur not all (e.g. Australia), at high resolution (e.g.Switzerland), at noncontiguous resolution (e.g. Bld 5) or at most resolution (e.g. Bld 11). Similarpatterns can be seen for the performance with respect to the upper bound.
Nonetheless, resolution likely plays an important role in these results, but not as straightforwardas either low or high resolution being more problematic. Instead, it is likely the most problematicresolutions are those at which the
√2-narrowness of the polygon jumps as a new pair of edges comes
within distance√
2 of each other. However, an in-depth investigation of this is beyond the scope ofthis paper.
23
Africa Antarctica Australia
Brazil China France
Greece Italy Switzerland
Great Britain Vietnam Limburg (NL)
Noord Brabant (NL) Languedoc-Roussillon (FR)
Figure 21: The 14 territorial outlines used in our experiments.
24
Bld 1 Bld 2 Bld 3
Bld 4 Bld 5 Bld 6
Bld 7 Bld 8 Bld 9
Bld 10 Bld 11
Figure 22: The 11 building footprints used in our experiments.
25
bird butterfly cat
dog horse ostrich
shark spider turtle
Figure 23: The 9 animal contours used in our experiments.
26
Tab
le3:
Diff
eren
ceb
etw
een
max
imum
and
min
imum
Fre
chet
dis
tance
over
the
25ru
ns
for
all
case
s.Sig
nifi
cant
diff
eren
ces
(at
leas
t2)
are
mar
ked
ina
bold
font.
Sca
le1
23
45
67
89
1011
1213
1415
1617
1819
20
Afr
ica
0.68
0.85
0.6
20.
550.
460.
410.
510.
300.
230.
230.
250.
320.
290.
420.
300.
500.
560.
450.
610.
30A
nta
rcti
ca1.
211.
151.8
71.
872.2
83.4
12.8
52.4
52.1
42.0
01.
811.
621.
431.
271.
221.
221.
191.
051.
030.
90A
ust
rali
a1.
681.
120.9
90.
940.
990.
830.
931.
331.
101.
090.
890.
840.
880.
850.
940.
920.
940.
900.
860.
85B
razi
l0.
400.
550.9
50.
781.
340.
950.
890.
970.
750.
860.
800.
680.
611.
230.
541.
261.
021.
031.
060.
80C
hin
a0.
741.
041.0
81.
041.
361.
271.
100.
870.
930.
690.
502.0
62.1
62.1
41.
761.
921.
701.
561.
461.
36F
ran
ce1.
300.
770.7
70.
590.
560.
400.
410.
420.
780.
771.
000.
980.
810.
690.
610.
630.
650.
790.
620.
68G
reec
e1.
211.
412.2
01.
601.
611.
312.8
12.3
72.0
83.5
02.5
63.2
63.1
22.7
92.9
22.9
62.5
42.4
92.6
52.0
3It
aly
1.45
0.91
1.7
62.2
42.8
32.5
22.7
12.5
02.3
02.1
53.2
63.1
63.1
43.0
23.0
53.6
73.0
52.1
92.5
72.0
9S
wit
zerl
an
d3.0
24.4
72.7
12.2
31.
521.
611.
381.
771.
341.
211.
251.
161.
101.
110.
920.
720.
710.
740.
610.
48G
reat
Bri
tain
3.4
02.1
82.2
31.
721.
751.
771.
581.
341.
411.
601.
431.
681.
602.7
24.0
03.3
33.2
53.0
92.9
22.6
6V
ietn
am1.
661.
270.7
217.4
915.1
54.6
32.6
82.4
41.
491.
490.
810.
780.
950.
820.
780.
780.
850.
930.
880.
91L
imb
urg
1.70
2.2
41.
371.
803.4
24.9
55.7
75.0
64.5
64.5
34.2
12.9
23.5
83.2
92.9
72.7
32.6
42.4
63.1
82.7
0N
oord
Bra
bant
3.9
01.
991.
231.0
30.
890.
690.
781.
331.
201.
070.
920.
820.
960.
840.
690.
760.
620.
690.
570.
61L
ang.-
Rou
ss.
0.52
0.18
0.2
30.
650.
580.
890.
740.
680.
510.
540.
630.
580.
730.
810.
393.4
13.0
52.7
02.8
52.5
9
Bld
154.5
226.5
714.3
07.8
410.9
39.9
34.2
26.7
22.6
71.
701.
601.
441.
491.
281.
281.
321.
281.
281.
601.
77B
ld2
0.06
0.09
1.0
00.
800.
670.
820.
550.
500.
460.
390.
340.
510.
492.4
92.2
52.0
81.
901.
932.7
22.5
2B
ld3
0.53
0.63
0.5
90.
440.
450.
480.
410.
430.
920.
731.
231.
080.
930.
881.
020.
990.
831.
741.
581.
48B
ld4
0.05
0.05
0.0
60.
090.
070.
100.
120.
170.
220.
180.
220.
140.
140.
260.
170.
310.
200.
170.
120.
23B
ld5
0.32
0.35
2.9
21.
973.8
23.6
32.8
23.3
31.
883.0
21.
671.
411.
522.0
61.
871.
720.
951.
020.
981.
19B
ld6
0.62
1.75
3.1
41.
972.0
51.
671.
410.
970.
800.
670.
980.
730.
660.
760.
660.
780.
630.
620.
450.
52B
ld7
0.02
0.07
0.0
30.
050.
120.
090.
080.
120.
110.
190.
150.
190.
250.
220.
660.
980.
900.
840.
900.
80B
ld8
0.14
0.16
0.1
41.
042.3
22.0
31.
601.
701.
781.
251.
141.
231.
240.
881.
041.
023.8
23.5
43.3
73.3
8B
ld9
0.20
0.27
0.2
30.
230.
210.
220.
260.
241.
011.
050.
800.
810.
660.
660.
530.
620.
600.
460.
470.
48B
ld10
0.21
0.24
1.2
42.8
21.
941.
461.
110.
971.
341.
131.
071.
804.3
14.1
93.8
73.6
63.2
43.0
12.6
92.8
0B
ld11
0.10
18.3
112.5
87.5
15.9
55.1
14.5
44.7
43.9
84.0
63.5
43.3
83.4
42.3
52.3
62.5
52.6
72.0
22.3
12.2
0
bir
d1.
862.5
42.5
11.
131.
461.
471.
831.
370.
971.
211.
221.
040.
782.1
52.0
92.2
22.0
51.
781.
671.
40b
utt
erfl
y8.6
91.
582.5
92.2
31.
811.
471.
451.
030.
870.
830.
750.
750.
590.
650.
720.
822.3
12.1
50.
511.
69ca
t0.
180.
490.9
71.
213.3
93.2
02.7
32.5
51.
861.
621.
731.
481.
501.
581.
641.
211.
411.
431.
341.
30d
og
1.58
12.1
27.6
65.1
23.3
02.5
81.
541.
701.
271.
531.
441.
061.
371.
251.
191.
130.
881.
171.
091.
02h
ors
e0.
780.
815.9
63.9
32.5
51.
831.
811.
341.
231.
651.
261.
390.
720.
591.
091.
121.
261.
221.
170.
98os
tric
h0.
880.
650.7
16.9
45.2
12.7
92.2
21.
991.
201.
301.
271.
601.
771.
831.
371.
501.
461.
381.
201.
36sh
ark
1.27
1.42
0.6
71.
206.7
96.4
75.5
85.0
55.0
75.0
94.5
74.0
44.0
14.0
93.5
23.8
83.0
93.2
23.1
83.2
1sp
ider
2.8
32.4
45.5
93.3
14.4
12.0
62.0
83.7
22.6
82.3
82.0
52.0
32.4
01.
601.
272.1
01.
031.
531.
611.
56tu
rtle
0.39
0.42
2.0
61.
551.
150.
650.
681.
872.8
02.5
92.5
12.3
32.0
71.
551.
311.
511.
201.
291.
291.
00
27
Tab
le4:
Diff
eren
ceb
etw
een
aver
age
and
min
imum
Fre
chet
dis
tance
over
the
25ru
ns
for
all
case
s.Sig
nifi
cant
diff
eren
ces
(at
leas
t2)
are
mar
ked
ina
bol
dfo
nt.
Sca
le1
23
45
67
89
1011
1213
1415
1617
1819
20
Bld
14.8
320.3
312.4
26.5
57.4
98.0
03.0
75.6
51.
870.
950.
780.
730.
760.
590.
630.
720.
670.
660.
931.
05B
ld2
0.0
30.0
60.2
70.3
90.
360.
330.
230.
270.
190.
140.
160.
220.
180.
390.
340.
380.
310.
390.
690.
57B
ld3
0.0
90.1
00.0
90.1
20.
160.
170.
170.
160.
170.
220.
350.
310.
290.
260.
360.
370.
280.
290.
350.
29B
ld4
0.0
30.0
30.0
30.0
50.
040.
050.
050.
080.
060.
060.
070.
080.
050.
080.
090.
100.
080.
080.
060.
08B
ld5
0.0
70.0
81.3
71.2
81.
241.
602.0
41.
660.
611.
830.
850.
670.
571.
271.
231.
160.
520.
520.
480.
58B
ld6
0.1
20.5
31.4
71.3
41.
080.
890.
730.
500.
390.
360.
520.
360.
310.
350.
300.
370.
330.
370.
200.
27B
ld7
0.0
10.0
20.0
20.0
30.
050.
060.
040.
080.
080.
140.
090.
090.
130.
130.
140.
280.
240.
260.
360.
33B
ld8
0.0
50.0
50.0
60.0
70.
080.
080.
090.
090.
160.
230.
230.
250.
180.
250.
190.
230.
240.
170.
190.
18B
ld9
0.0
60.0
50.0
50.1
60.
981.
080.
900.
780.
870.
560.
650.
710.
580.
300.
270.
480.
710.
560.
630.
68B
ld10
0.0
60.0
60.1
71.3
11.
140.
830.
550.
480.
650.
530.
510.
690.
630.
910.
770.
860.
680.
620.
520.
84B
ld11
0.0
65.1
08.7
43.1
82.8
83.0
72.8
33.0
82.7
83.0
52.4
92.1
01.
931.
431.
401.
511.
901.
481.
371.
22
bir
d0.6
21.0
00.9
80.6
00.
640.
650.
990.
600.
430.
600.
620.
520.
340.
690.
680.
720.
630.
600.
610.
53b
utt
erfl
y1.8
91.0
91.3
61.2
81.
150.
910.
970.
600.
560.
460.
430.
410.
310.
340.
410.
430.
500.
480.
240.
47ca
t0.0
20.0
80.1
90.2
80.
731.
561.
361.
480.
870.
800.
830.
740.
890.
780.
830.
560.
630.
610.
720.
65d
og0.5
03.7
83.9
81.
891.
671.
490.
680.
850.
680.
940.
690.
500.
890.
670.
670.
610.
420.
550.
510.
48h
orse
0.2
30.2
31.7
62.5
31.
391.
061.
030.
540.
571.
040.
620.
620.
430.
270.
370.
440.
530.
470.
510.
50os
tric
h0.4
00.3
20.3
23.0
42.8
81.
421.
511.
440.
730.
860.
751.
081.
141.
130.
740.
870.
850.
690.
560.
52sh
ark
0.5
00.8
50.3
10.4
81.
052.0
72.2
92.2
72.7
22.5
82.6
21.
791.
752.0
41.
822.0
41.
691.
531.
881.
69sp
ider
1.3
01.4
53.0
61.
581.
840.
660.
721.
931.
400.
960.
620.
921.
300.
770.
730.
960.
520.
610.
680.
58tu
rtle
0.0
80.1
20.4
70.6
80.
400.
350.
310.
401.
051.
201.
451.
431.
150.
900.
650.
850.
700.
760.
810.
60
Afr
ica
0.4
40.4
10.2
30.1
90.
110.
110.
120.
090.
060.
070.
080.
080.
070.
130.
070.
100.
130.
110.
180.
09A
nta
rcti
ca0.4
10.4
40.7
10.8
20.
821.
100.
910.
880.
890.
930.
980.
870.
680.
550.
570.
550.
570.
470.
470.
39A
ust
rali
a0.5
20.5
30.3
60.3
50.
350.
300.
290.
340.
290.
320.
240.
250.
230.
280.
350.
300.
310.
340.
310.
29B
razi
l0.2
40.1
90.2
30.2
90.
350.
320.
360.
300.
280.
270.
230.
200.
250.
290.
260.
330.
220.
220.
270.
19C
hin
a0.3
50.3
60.4
70.4
40.
390.
390.
320.
280.
310.
180.
220.
240.
270.
430.
370.
420.
410.
460.
420.
35F
ran
ce0.4
70.3
50.3
10.2
10.
220.
170.
160.
130.
170.
190.
240.
300.
230.
240.
180.
200.
210.
200.
190.
26G
reec
e0.5
70.7
60.9
30.7
10.
720.
692.2
10.
730.
681.
380.
801.
021.
000.
870.
991.
131.
071.
271.
350.
93It
aly
0.8
50.4
30.5
30.7
41.
161.
221.
101.
041.
060.
971.
061.
251.
391.
561.
631.
881.
470.
891.
401.
07S
wit
zerl
an
d1.5
41.0
50.8
71.1
10.
710.
730.
610.
740.
520.
530.
530.
560.
550.
500.
450.
350.
390.
420.
340.
23G
reat
Bri
tain
1.2
41.3
31.0
50.7
70.
820.
590.
710.
620.
620.
840.
650.
590.
700.
550.
970.
680.
640.
930.
981.
05V
ietn
am
0.6
50.7
70.4
17.0
011.8
63.3
41.
771.
710.
900.
950.
380.
370.
450.
430.
400.
390.
430.
430.
480.
56L
imb
urg
0.7
00.8
80.6
00.5
90.
771.
731.
982.1
22.2
42.3
82.3
41.
442.1
82.0
51.
721.
631.
371.
401.
171.
18N
oor
dB
rab
ant
0.4
80.8
30.5
40.4
60.
350.
320.
330.
280.
280.
300.
260.
240.
310.
320.
250.
240.
210.
200.
190.
18L
ang.-
Rou
ss.
0.3
60.0
50.0
50.1
10.
210.
260.
300.
240.
210.
210.
210.
200.
160.
200.
130.
410.
720.
550.
921.
08
28
Tab
le5:
Th
em
inim
um
Fre
chet
dis
tan
ceov
erth
e25
run
sfo
rall
case
s,as
ap
erce
nta
ge
of
the
pre
dic
ted
up
per
bou
nd
.S
ign
ifica
ntl
yb
ette
rp
erfo
rman
ce(l
ess
than
40
per
cent)
are
mark
edin
ab
old
font.
Sca
le1
23
45
67
89
1011
1213
1415
1617
1819
20
Afr
ica
45.7
018.5
016.7
117.9
720.1
022.2
123.0
223.6
425.3
225.8
126.0
725.5
926.3
424.1
227.1
727.0
226.0
626.1
424.3
325.8
9A
nta
rcti
ca30.8
024.9
620.4
415.5
613.5
99.6
910.5
811.4
112.0
212.5
313.2
114.8
415.5
815.8
815.6
116.4
914.4
714.1
914.6
715.3
5A
ust
rali
a31.5
320.7
825.0
622.7
619.2
720.5
020.9
221.4
320.4
020.9
921.3
220.0
920.6
220.8
417.9
921.5
521.7
320.7
422.3
424.0
7B
razi
l29.6
127.7
120.0
817.7
119.0
719.1
616.8
118.4
213.5
213.2
313.6
514.5
514.2
314.0
013.8
114.2
315.9
415.9
415.6
217.6
4C
hin
a28.4
710.0
511.8
513.9
615.7
016.8
020.4
022.9
820.5
021.7
710.6
79.4
110.0
110.2
010.7
410.8
311.1
811.6
011.0
211.5
3F
ran
ce23.1
024.8
824.6
228.8
425.9
327.9
924.4
723.7
018.3
019.3
118.8
320.0
219.7
319.7
121.2
020.8
720.5
223.0
020.8
018.7
1G
reec
e22.1
619.8
619.4
719.2
615.4
812.9
75.3
612.1
011.6
77.2
210.6
611.5
510.6
012.0
710.3
49.2
610.2
59.3
28.0
411.6
4It
aly
32.1
125.2
214.0
010.4
813.9
010.7
212.2
313.4
26.7
86.7
56.7
07.0
48.1
97.5
47.8
27.9
513.5
821.7
714.7
920.9
4S
wit
zerl
an
d17.6
410.5
413.5
816.3
819.7
719.2
921.2
216.7
023.2
923.4
017.4
918.4
519.1
715.8
714.7
717.1
114.6
115.1
015.2
018.0
6G
reat
Bri
tain
26.9
522.0
920.5
619.6
317.0
75.0
44.6
44.9
15.6
84.3
24.8
35.8
95.3
06.9
14.8
86.9
56.8
97.0
27.1
57.7
9V
ietn
am
62.5
242
.62
26.4
62.5
53.1
137.1
543
.46
42.9
147
.52
46.0
050
.08
49.3
947
.77
47.3
547
.21
46.5
045
.93
44.8
943
.28
41.9
7L
imb
urg
10.8
116.6
418.3
412.7
310.6
04.9
06.1
510.7
29.1
56.6
76.2
713.1
97.4
66.6
78.5
59.9
27.7
78.5
28.8
512.4
2N
oor
dB
rab
ant
11.1
417.7
820.3
922.4
714.9
916.7
417.0
019.2
119.0
721.4
921.3
222.1
420.9
821.8
623.1
818.7
916.6
912.6
812.3
712.8
3L
ang.-
Rou
ss.
24.9
125.0
023.0
021.2
019.0
417.6
917.9
219.5
121.3
321.7
521.1
521.1
723.6
76.6
57.0
96.4
07.9
87.4
68.0
88.2
7
Bld
10.8
82.4
013.5
024.6
019.7
717.1
639.9
621.1
843
.37
48.9
448
.83
48.2
347
.21
48.3
446
.54
43.7
343
.57
43.0
736.6
934.0
9B
ld2
37.2
222.2
820.3
018.8
020.2
121.8
622.4
17.0
48.1
29.5
09.2
74.8
75.2
95.1
85.9
65.9
86.1
37.3
15.5
75.2
4B
ld3
29.9
031.0
533.5
226.1
728.1
327.7
014.9
716.8
318.6
515.6
115.8
917.5
916.3
618.3
811.7
610.3
612.5
713.8
913.2
014.3
4B
ld4
39.7
439.1
137.4
135.0
235.0
434.4
334.2
033.3
034.2
035.4
434.3
833.3
835.2
633.7
533.1
732.0
332.7
132.0
632.3
028.7
6B
ld5
31.9
910.1
04.1
25.7
313.5
36.3
98.8
311.4
225.3
38.6
724.3
719.0
918.1
08.0
28.4
58.7
723.4
021.1
320.9
619.6
9B
ld6
23.1
613.9
29.4
616.9
117.8
622.3
626.7
030.3
631.3
232.0
424.1
926.5
427.6
823.2
517.1
415.6
516.7
914.5
620.5
517.0
6B
ld7
39.5
338.2
438.0
836.9
135.5
334.7
935.5
433.2
333.3
216.2
117.5
317.6
616.8
216.7
418.6
614.9
419.0
321.4
119.7
819.4
0B
ld8
38.3
937.6
437.4
636.1
235.8
435.4
635.5
018.7
519.6
420.6
520.7
622.0
023.2
623.0
625.3
223.6
223.3
225.4
324.6
725.7
6B
ld9
32.6
632.6
518.7
57.7
29.1
77.8
69.5
914.6
610.9
018.1
08.0
47.2
27.0
611.0
411.1
38.2
88.3
97.9
08.8
67.8
7B
ld10
36.5
335.9
215.9
68.9
316.4
314.4
917.6
116.2
514.7
97.4
66.8
96.5
47.5
57.6
88.0
98.2
89.2
98.6
29.5
68.6
2B
ld11
5.6
91.3
71.3
914.4
314.2
012.7
912.3
58.1
99.1
27.0
28.3
07.3
95.4
711.9
09.6
66.9
66.9
19.5
88.3
47.1
9
bir
d24.4
916.7
525.2
236.1
835.5
629.5
728.2
735.7
220.9
818.4
818.1
416.2
818.4
916.8
816.9
517.1
717.0
819.7
620.1
618.5
4b
utt
erfl
y19.5
135.9
938.3
721.7
421.0
221.0
818.9
120.5
819.7
120.1
920.1
620.0
415.4
415.3
713.4
310.5
610.6
310.8
813.3
513.0
5ca
t38.8
227.0
724.7
218.9
69.4
09.7
519.4
715.9
425.6
127.2
824.8
326.2
421.0
320.4
620.3
125.2
721.0
621.6
317.4
819.0
9d
og16.2
53.1
15.8
010.2
518.3
623.9
235.6
031.6
333.5
427.4
229.5
233.4
524.5
928.2
226.1
428.3
932.4
613.3
613.2
013.6
3h
orse
26.1
83.1
84.6
215.8
527.7
531.7
630.3
337.4
830.3
422.6
627.4
027.3
228.2
731.8
531.7
425.4
523.1
922.0
221.1
321.7
5ost
rich
23.0
730.0
211.4
05.1
723.0
142
.87
41.3
438.8
043
.93
40.2
939.0
033.4
229.9
226.5
331.9
927.3
425.2
727.7
126.4
922.3
3sh
ark
13.8
416.3
76.4
05.9
27.0
75.5
56.2
08.9
67.3
47.2
16.8
113.2
412.9
110.3
612.8
18.8
714.3
914.1
39.8
19.5
2sp
ider
14.7
99.1
718.1
237.1
739.6
150
.32
38.0
728.6
427.4
318.4
420.1
517.9
715.4
115.0
614.2
210.5
413.7
412.6
111.2
911.3
3tu
rtle
35.8
726.2
513.7
824.9
123.1
121.2
614.1
215.1
412.6
113.1
813.4
814.3
416.5
125.3
129.3
222.5
926.0
922.5
619.7
827.0
0
29
Tab
le6:
The
aver
age
Fre
chet
dis
tance
over
the
25ru
ns
for
all
case
s,as
ap
erce
nta
geof
the
pre
dic
ted
upp
erb
ound.
Sig
nifi
cantl
yb
ette
rp
erfo
rman
ce(l
ess
than
40p
erce
nt)
are
mar
ked
ina
bold
font.
Sca
le1
23
45
67
89
1011
1213
1415
1617
1819
20
Afr
ica
53.7
726.5
522.0
823.1
223.4
325.8
927.6
427.2
827.7
928.7
029.5
029.1
829.3
630.1
130.2
931.6
732.1
031.2
532.6
130.0
0A
nta
rcti
ca41.5
236.4
537.5
833.8
729.1
724.9
524.8
026.0
528.3
230.7
433.7
034.1
331.4
629.2
430.2
230.9
628.3
825.9
926.6
925.5
6A
ust
rali
a45.2
131.7
134.5
133.1
628.8
529.6
430.2
932.4
329.8
731.4
429.3
428.3
528.5
130.8
430.1
132.3
333.1
733.6
434.1
435.3
1B
razi
l32.1
331.1
324.3
924.4
127.7
527.8
726.1
926.7
219.3
418.9
118.6
419.0
920.0
221.0
720.4
723.0
021.9
022.1
323.5
723.3
0C
hin
a40.9
214.8
819.7
922.8
224.4
026.8
229.3
731.2
430.2
327.6
214.3
112.9
814.2
417.2
117.1
018.4
618.8
120.5
519.0
718.5
1F
ran
ce38.3
837.8
435.5
736.6
934.9
335.1
431.0
228.6
623.2
225.0
926.2
929.5
927.4
027.8
727.5
728.1
528.4
530.7
427.5
328.0
5G
reec
e22.7
421.3
322.0
821.8
718.2
115.6
215.0
915.7
615.4
015.5
915.7
418.4
217.8
018.7
417.9
718.4
519.4
220.3
520.3
420.4
9It
aly
45.9
935.6
522.9
920.0
630.5
229.9
531.5
733.4
817.0
716.7
718.3
621.4
423.0
024.4
726.6
530.9
632.5
733.8
134.7
836.9
2S
wit
zerl
an
d40.2
122.7
827.3
838.1
535.0
535.5
735.4
733.4
135.6
836.4
931.4
233.7
034.6
630.1
325.2
525.1
123.5
425.0
623.6
023.8
8G
reat
Bri
tain
33.2
932.1
030.8
427.7
126.6
07.0
17.3
77.5
88.6
27.9
47.8
98.8
59.0
710.0
310.8
011.3
711.2
913.7
614.6
616.2
1V
ietn
am
71.9
360
.45
34.7
522.6
845
.54
51.4
252
.26
52.5
453
.23
52.6
552
.97
52.4
751
.79
51.4
651
.34
50.7
650
.91
50.1
149
.32
49.3
7L
imb
urg
21.3
737.7
334.2
521.0
719.0
214.9
118.9
626.0
626.8
226.6
726.7
925.1
926.7
725.8
325.6
326.9
522.7
324.5
622.9
727.4
1N
oor
dB
rab
ant
18.9
638.7
236.2
737.7
522.9
624.6
825.9
427.4
228.0
131.3
630.3
530.4
831.8
333.4
132.4
826.0
322.2
316.8
416.5
116.7
8L
ang.-
Rou
ss.
27.2
525.5
823.8
423.4
623.7
324.1
126.1
826.6
527.8
628.7
827.8
628.1
029.4
98.8
78.6
111.4
017.2
614.9
221.1
924.3
3
Bld
15.8
243.
2850
.34
50.0
748
.49
53.4
656
.00
54.4
255
.56
55.7
554
.92
54.3
254
.00
53.9
852
.86
51.4
251
.07
50.8
048
.05
47.4
9B
ld2
39.1
524.4
729.1
331.9
131.7
833.5
131.1
410.4
010.6
511.5
311.7
16.8
87.0
89.1
69.5
910.3
39.8
512.2
814.8
313.2
6B
ld3
33.9
635.7
438.1
331.2
234.7
335.4
519.3
421.3
023.7
921.8
126.5
327.1
925.7
327.1
920.0
319.0
419.5
521.2
822.2
522.2
6B
ld4
41.5
540
.88
38.9
237.6
237.4
837.1
637.2
237.6
337.9
138.6
838.4
338.2
138.1
338.5
838.5
338.0
437.2
336.3
935.6
932.7
7B
ld5
35.2
411.4
214.8
717.1
826.8
821.4
128.4
129.2
832.5
532.0
236.0
127.7
625.8
826.4
727.2
627.4
032.2
630.3
329.7
730.5
8B
ld6
27.0
224.6
829.3
238.9
338.7
241
.61
44.1
343
.33
41.9
542
.54
39.3
737.3
737.1
934.3
723.8
824.5
325.0
424.1
525.8
724.3
9B
ld7
40.0
139.6
239.1
938.8
138.6
037.9
538.0
437.7
237.6
520.5
120.4
920.5
621.0
821.1
923.6
824.9
827.7
231.2
433.4
632.4
0B
ld8
41.0
940
.70
40.7
240.
2640
.26
40.0
640
.63
21.6
724.6
028.3
028.4
730.9
229.8
132.4
732.5
632.5
232.8
632.2
932.4
433.2
0B
ld9
35.9
335.1
420.2
89.7
724.0
721.8
322.6
327.0
825.7
928.4
213.2
813.4
212.4
313.9
613.9
513.3
116.2
914.4
516.6
916.6
2B
ld10
39.5
539.0
920.1
527.0
734.9
926.0
026.0
724.3
426.6
211.7
411.3
513.0
213.8
417.1
816.4
418.1
117.6
016.5
416.6
020.4
4B
ld11
6.2
512.4
620.9
823.8
024.6
725.0
025.3
224.1
525.1
726.2
425.3
622.9
020.7
123.9
521.4
220.4
124.6
723.9
722.2
519.5
0
bir
d39.3
834.3
442.
9446
.62
47.2
740
.30
45.9
947
.38
26.2
026.3
426.7
223.8
623.7
128.0
428.4
529.8
928.6
631.2
132.1
628.4
5b
utt
erfl
y29.6
641.
8648
.55
29.0
929.0
528.4
827.9
126.7
826.0
725.8
925.8
525.7
818.8
819.4
018.5
715.1
516.2
216.5
116.3
119.0
5ca
t39.9
130.4
631.8
327.2
419.8
632.1
340
.72
41.0
841
.58
42.8
841
.92
42.4
641
.39
38.9
840
.78
39.5
937.5
238.1
937.6
137.6
5d
og
27.7
619.6
631.0
025.7
334.8
941
.07
44.4
143
.63
44.1
443
.24
41.7
942
.79
42.1
042
.08
40.5
842
.06
42.1
019.8
319.3
319.5
2h
orse
34.9
24.2
616.3
037.6
042
.27
44.6
542
.75
44.7
137.0
135.7
835.7
636.2
434.7
836.2
537.9
032.1
531.6
629.9
029.9
530.7
6ost
rich
35.4
140.
5216.4
629.0
446
.98
56.1
057
.09
55.2
552
.58
51.3
249
.38
49.3
347
.77
45.1
344
.75
42.9
441
.21
41.1
937.1
430.6
0sh
ark
22.1
032.9
17.9
98.8
914.3
221.7
325.2
329.3
033.1
132.9
534.6
133.4
731.9
033.6
334.4
033.8
536.3
335.0
736.7
134.9
1sp
ider
35.2
720.0
537.6
346.
8053
.24
56.0
643
.48
44.9
740
.53
24.5
024.4
424.7
725.7
920.3
319.5
416.8
317.3
217.0
216.3
815.7
8tu
rtle
40.1
430.8
823.3
541.
3233.9
531.6
920.6
523.9
731.4
436.3
943
.34
45.5
843
.01
46.9
945
.79
44.8
745
.31
44.1
043
.30
45.0
3
30
Tab
le7:
Th
em
axim
um
Fre
chet
dis
tan
ceov
erth
e25
run
sfo
rall
case
s,as
ap
erce
nta
ge
of
the
pre
dic
ted
up
per
bou
nd
.S
ign
ifica
ntl
yb
ette
rp
erfo
rman
ce(l
ess
than
40
per
cent)
are
mark
edin
ab
old
font.
Sca
le1
23
45
67
89
1011
1213
1415
1617
1819
20
Afr
ica
58.2
035.1
031.3
933.2
534.5
136.3
641
.84
35.5
534.6
935.4
136.9
239.6
839.3
342
.84
40.6
249
.95
52.0
946
.97
52.8
739.3
3A
nta
rcti
ca62.3
554
.79
65.2
957.
3156
.62
57.0
955
.25
52.4
451
.07
51.8
051
.22
50.9
548
.92
46.7
846
.55
48.5
043
.69
40.6
541
.19
39.1
2A
ust
rali
a75.8
243
.71
51.3
850.
9246
.66
45.4
351
.10
64.9
555
.90
56.4
450
.65
47.9
550
.53
50.9
850
.92
54.6
256
.17
54.3
955
.40
56.7
7B
razi
l33.7
337.6
038.1
135.6
052
.65
45.2
040
.14
45.5
029.0
031.4
330.8
329.7
928.5
844
.33
27.4
247
.43
43.5
945
.02
46.3
941.0
6C
hin
a54.5
224.0
030.1
134.7
046
.45
49.1
150
.88
48.8
649
.47
44.2
019.0
840
.01
43.4
545
.16
41.0
445
.50
43.0
041
.93
38.8
838.3
2F
ran
ce65.4
953
.33
51.6
851.
0048
.27
45.1
140
.91
39.4
841
.11
42.7
449
.35
50.8
946
.25
43.3
642
.81
43.6
044
.60
53.1
043
.08
42.9
2G
reec
e23.4
022.5
725.6
225.1
121.5
617.9
917.7
623.9
123.1
528.3
926.9
333.4
533.1
033.5
032.7
433.2
631.9
131.0
132.1
930.8
6It
aly
55.7
347
.42
43.6
939.4
754
.30
50.6
159
.87
61.7
229.1
029.0
042
.41
43.5
741
.72
40.2
642
.95
52.7
852
.97
51.5
551
.49
52.2
0S
wit
zerl
and
61.9
862
.44
56.7
159.
9552
.31
55.0
653
.12
56.7
355
.01
53.5
150
.13
50.2
250
.22
47.4
036.0
533.4
630.8
732.7
730.1
730.2
4G
reat
Bri
tain
44.3
038.5
842.
5137.7
737.4
110.9
310.7
310.6
712.4
011.2
311.5
614.3
413.9
222.4
429.2
428.5
029.1
729.3
929.4
529.1
0V
ietn
am
86.7
972
.02
41.1
952.
8857
.33
56.9
556
.75
56.6
856
.91
56.4
056
.29
55.8
556
.30
55.2
055
.22
55.0
155
.70
56.0
954
.42
54.0
6L
imb
urg
36.4
070.
4754
.38
38.1
548
.17
33.5
243
.40
47.4
345
.10
44.6
743
.18
37.4
739.1
937.4
038.0
338.4
536.5
636.7
747
.23
46.6
4N
oord
Bra
bant
74.5
668
.23
56.4
456.
8234.9
734.2
038.4
058
.53
56.8
156
.95
52.9
550
.70
54.5
252
.01
48.6
741
.71
33.1
426.9
324.5
526.1
7L
ang.
-Rou
ss.
28.2
627.1
626.8
134.2
132.1
340
.11
38.2
339.3
337.3
339.3
841
.66
40.8
849
.66
15.6
311.5
447
.76
47.0
843
.97
48.4
746.7
5
Bld
156.6
455
.83
55.9
155.
0961
.72
62.2
361
.97
60.6
760
.79
61.1
361
.30
60.2
660
.60
60.5
259
.40
57.7
657
.84
58.0
056
.27
56.6
3B
ld2
40.5
225.7
052.
9445
.57
41.9
350
.56
42.9
613.1
614.4
015.1
714.6
09.5
810.1
530.5
030.3
529.9
129.1
932.0
442
.14
40.7
7B
ld3
53.2
759
.90
62.5
944.
9147
.39
49.5
225.7
729.2
246
.73
36.5
252
.98
51.5
246
.59
47.9
235.0
333.8
032.9
158
.14
54.5
754.4
2B
ld4
42.7
342
.12
40.7
639.8
439.0
339.7
941
.19
43.2
046
.66
45.9
247
.43
41.7
743
.52
49.0
043
.38
50.3
544
.22
41.6
538.8
340.7
9B
ld5
47.6
915.7
927.0
623.3
354
.65
40.4
535.9
447
.21
47.5
247
.24
47.2
437.3
239.0
137.9
937.1
936.4
139.4
239.0
438.8
841.9
8B
ld6
43.6
249
.67
51.7
749.
4257
.43
58.6
160
.23
55.3
953
.36
51.3
052
.99
48.2
448
.23
47.6
232.1
934.2
132.4
930.5
532.6
031.4
4B
ld7
40.6
142
.32
40.0
439.9
142
.17
39.9
239.9
739.9
839.6
522.2
022.0
923.7
125.2
224.1
741
.92
50.3
852
.16
52.8
554
.29
50.6
8B
ld8
49.7
053
.18
50.6
249.
3447
.90
48.0
250
.43
26.0
751
.58
55.2
048
.11
50.7
447
.40
47.9
445
.71
47.9
347
.41
44.2
844
.37
46.1
9B
ld9
40.3
341
.40
23.1
221.2
044
.50
34.1
732.6
941
.70
41.3
740
.94
17.3
017.8
618.5
519.7
222.0
018.9
851
.00
49.4
650
.40
51.5
9B
ld10
47.5
348
.99
46.3
847.
8747
.88
34.6
634.7
832.5
639.1
916.6
116.2
423.4
650
.74
51.3
949
.98
50.3
648
.57
47.0
745
.69
47.9
6B
ld11
6.5
741.
2429.5
736.5
835.8
533.1
233.1
732.7
732.1
032.6
032.5
732.3
332.6
331.6
729.5
329.6
231.8
429.2
731.8
529.3
8
bir
d69.2
461
.32
70.6
655.
8862
.35
53.6
961
.01
62.4
532.8
534.2
334.9
831.5
130.5
751
.67
52.4
256
.54
54.9
953
.96
53.3
044.6
7b
utt
erfl
y66.1
544
.49
57.7
334.5
233.6
033.0
732.3
431.1
829.5
930.3
830.1
030.6
622.0
323.0
522.3
819.2
936.3
435.9
119.5
934.5
2ca
t48.7
046
.97
60.4
255.
1757
.77
55.7
762
.20
59.3
159
.54
58.7
760
.54
58.5
055
.08
57.8
560
.58
56.0
858
.24
60.3
254
.68
56.3
3d
og
52.7
556
.23
54.2
852.
0751
.00
53.5
755
.75
55.6
653
.21
53.0
555
.14
53.3
551
.66
54.0
951
.60
53.6
152
.97
27.1
526.2
526.2
2h
orse
55.3
16.9
144.
3149
.62
54.3
353
.96
52.1
355
.57
44.6
843
.41
44.3
447
.19
39.1
441
.32
50.1
542
.73
43.4
842
.38
41.3
539.3
4os
tric
h50.1
251
.54
22.7
459.
6566
.39
68.8
464
.42
61.4
758
.25
56.9
856
.49
56.9
357
.58
56.5
955
.65
54.3
152
.54
54.6
649
.24
43.9
5sh
ark
34.7
043.
869.8
613.2
654
.03
56.1
952
.55
54.2
355
.48
58.0
255
.36
58.9
756
.42
56.9
254
.58
56.3
954
.42
58.0
255
.42
57.7
0sp
ider
59.4
827.4
453.
7157
.38
72.3
068
.20
53.7
460
.11
52.5
433.4
734.2
733.0
634.5
125.9
823.4
824.2
820.8
323.7
323.4
223.3
4tu
rtle
55.9
542
.22
55.9
262.
1454
.61
40.8
328.5
756
.12
62.7
363
.13
65.2
165
.25
64.1
862
.78
62.3
862
.23
58.7
558
.99
57.1
356.9
1
31
Table 8: Influence of the input placement. For every algorithm and input the minimum, averageand maximum normalized symmetric difference are given.
Optimal Hausdorff Frechet
min avg max min avg max min avg max
Africa 0.139 0.159 0.18 0.139 0.159 0.18 0.142 0.165 0.191Antarctica 0.13 0.143 0.154 0.13 0.145 0.16 0.133 0.15 0.157
Australia 0.133 0.147 0.167 0.133 0.149 0.172 0.137 0.154 0.171Brazil 0.156 0.173 0.199 0.156 0.173 0.199 0.162 0.182 0.23China 0.157 0.174 0.209 0.157 0.174 0.209 0.163 0.184 0.214
France 0.135 0.149 0.162 0.135 0.149 0.162 0.14 0.157 0.173Greece 0.323 0.341 0.36 0.325 0.343 0.372 0.343 0.398 0.512
Italy 0.292 0.334 0.364 0.292 0.335 0.369 0.292 0.352 0.39Lang.-Rouss. 0.192 0.233 0.268 0.192 0.233 0.268 0.197 0.245 0.282
Noord Brabant 0.153 0.176 0.195 0.153 0.176 0.195 0.159 0.186 0.221Limburg 0.245 0.265 0.296 0.257 0.276 0.305 0.259 0.344 0.524
Great Britain 0.242 0.262 0.282 0.242 0.265 0.312 0.255 0.289 0.322Vietnam 0.364 0.392 0.416 0.412 0.456 0.494 0.665 0.847 0.995
Switzerland 0.168 0.181 0.194 0.168 0.181 0.194 0.171 0.193 0.21
Bld 1 0.511 0.56 0.594 0.68 0.757 0.825 0.833 0.863 0.896Bld 2 0.235 0.284 0.342 0.235 0.284 0.342 0.243 0.302 0.36Bld 3 0.135 0.159 0.189 0.135 0.159 0.189 0.138 0.166 0.199Bld 4 0.109 0.124 0.136 0.109 0.124 0.136 0.113 0.126 0.136Bld 5 0.183 0.234 0.264 0.197 0.247 0.274 0.19 0.271 0.472Bld 6 0.144 0.157 0.175 0.144 0.158 0.175 0.149 0.167 0.182Bld 7 0.114 0.158 0.188 0.114 0.162 0.217 0.119 0.16 0.195Bld 8 0.162 0.181 0.203 0.162 0.181 0.203 0.162 0.19 0.218Bld 9 0.187 0.279 0.392 0.187 0.28 0.392 0.206 0.295 0.407
Bld 10 0.293 0.308 0.322 0.293 0.311 0.337 0.313 0.333 0.382Bld 11 0.349 0.379 0.414 0.353 0.391 0.431 0.37 0.432 0.523
bird 0.28 0.304 0.323 0.28 0.307 0.342 0.284 0.324 0.349butterfly 0.21 0.225 0.234 0.21 0.228 0.246 0.21 0.24 0.281
cat 0.206 0.254 0.292 0.23 0.276 0.333 0.223 0.275 0.317dog 0.279 0.318 0.347 0.316 0.36 0.421 0.295 0.337 0.377
horse 0.286 0.343 0.401 0.314 0.384 0.504 0.291 0.363 0.42ostrich 0.308 0.346 0.392 0.363 0.419 0.48 0.363 0.398 0.437
shark 0.31 0.342 0.374 0.321 0.355 0.383 0.333 0.381 0.407spider 0.568 0.586 0.619 0.63 0.708 0.808 0.582 0.625 0.694turtle 0.261 0.279 0.303 0.267 0.282 0.303 0.271 0.303 0.351
32
Table 9: Normalized symmetric difference, as an increase percentage w.r.t. optimal, of the algorithms.For the Hausdorff algorithm, results for the various heuristic improvements are shown. In the secondrow, None means that no postprocessing heuristic was used; A, R and S mean additions, removalsand shifts, respectively. In the third row, 3 and 7 indicate whether Q4 was chosen arbitrarily (7) orusing the symmetric difference heuristic (7).
Optimal Hausdorff Frechet
postproc. None A / R A / R / S
Q4 heur. 7 3 7 3 7 3
Africa 0.159 + 358 % + 291 % + 5 % + 0 % + 0 % + 0 % + 4 %Antarctica 0.143 + 332 % + 267 % + 2 % + 2 % + 2 % + 2 % + 5 %
Australia 0.147 + 350 % + 288 % + 3 % + 1 % + 3 % + 1 % + 4 %Brazil 0.173 + 346 % + 274 % + 0 % + 0 % + 0 % + 0 % + 5 %China 0.174 + 372 % + 276 % + 32 % + 0 % + 4 % + 0 % + 5 %
France 0.149 + 365 % + 269 % + 41 % + 0 % + 0 % + 0 % + 5 %Greece 0.341 + 260 % + 188 % + 81 % + 1 % + 3 % + 1 % + 17 %
Italy 0.334 + 294 % + 215 % + 30 % + 0 % + 0 % + 0 % + 5 %Lang.-Rouss. 0.233 + 339 % + 248 % + 40 % + 0 % + 4 % + 0 % + 5 %
Noord Brabant 0.176 + 339 % + 254 % + 23 % + 0 % + 7 % + 0 % + 6 %Limburg 0.265 + 314 % + 225 % + 75 % + 4 % + 35 % + 4 % + 30 %
Great Britain 0.262 + 296 % + 215 % + 50 % + 1 % + 37 % + 1 % + 10 %Vietnam 0.392 + 268 % + 207 % + 38 % + 18 % + 22 % + 16 % + 116 %
Switzerland 0.181 + 338 % + 256 % + 59 % + 0 % + 20 % + 0 % + 7 %Maps 0.223 + 316 % + 238 % + 39 % + 3 % + 11 % + 3 % + 23 %
Bld 1 0.560 + 245 % + 201 % + 78 % + 42 % + 57 % + 35 % + 54 %Bld 2 0.284 + 288 % + 188 % + 48 % + 0 % + 0 % + 0 % + 7 %Bld 3 0.159 + 339 % + 248 % + 3 % + 0 % + 3 % + 0 % + 4 %Bld 4 0.124 + 357 % + 274 % + 9 % + 0 % + 0 % + 0 % + 1 %Bld 5 0.234 + 246 % + 167 % + 55 % + 3 % + 20 % + 5 % + 16 %Bld 6 0.157 + 300 % + 229 % + 29 % + 1 % + 1 % + 1 % + 7 %Bld 7 0.158 + 284 % + 203 % + 19 % + 3 % + 19 % + 3 % + 1 %Bld 8 0.181 + 344 % + 266 % + 22 % + 0 % + 5 % + 0 % + 5 %Bld 9 0.279 + 245 % + 161 % + 55 % + 0 % + 26 % + 0 % + 6 %
Bld 10 0.308 + 266 % + 178 % + 54 % + 1 % + 19 % + 1 % + 8 %Bld 11 0.379 + 216 % + 164 % + 47 % + 4 % + 10 % + 3 % + 14 %
Buildings 0.257 + 270 % + 197 % + 47 % + 9 % + 21 % + 8 % + 17 %
bird 0.304 + 273 % + 206 % + 51 % + 1 % + 2 % + 1 % + 7 %butterfly 0.225 + 322 % + 246 % + 53 % + 1 % + 12 % + 1 % + 7 %
cat 0.254 + 269 % + 208 % + 24 % + 8 % + 9 % + 9 % + 8 %dog 0.318 + 255 % + 193 % + 63 % + 13 % + 45 % + 13 % + 6 %
horse 0.343 + 229 % + 168 % + 94 % + 14 % + 63 % + 12 % + 6 %ostrich 0.346 + 244 % + 190 % + 76 % + 24 % + 52 % + 21 % + 15 %shark 0.342 + 268 % + 214 % + 26 % + 5 % + 4 % + 4 % + 12 %spider 0.586 + 173 % + 136 % + 71 % + 24 % + 40 % + 21 % + 7 %turtle 0.279 + 274 % + 199 % + 61 % + 1 % + 13 % + 1 % + 9 %
Animals 0.333 + 246 % + 188 % + 60 % + 12 % + 29 % + 11 % + 8 %
33
Top Related