Deconstructing Approximate Offsets

Eric Berberich, Dan Halperin, Michael Kerber, Roza Pogalnikova

Abstract

In computational geometry, offsetting—adding "thickness" to a shape—is a fundamental operation used in GIS, path planning, and manufacturing. This paper addresses the inverse problem: offset-deconstruction. Given a complex polygonal shape $Q$, we seek a simpler "skeleton" polygon $P$ that, when thickened by a radius $r$, approximates $Q$ within a specified tolerance. We present the first efficient algorithms for this problem, including an $O(n \log n)$ exact decision algorithm and a robust rational-approximation variant. Our approach enables significant simplification of complex geometric data, reducing vertex counts by orders of magnitude while preserving shape fidelity.

Introduction

Adding thickness to a shape, formally known as an offset or the Minkowski sum of a shape and a disk, is a standard tool in modern engineering. However, the reverse process—finding the simple generator of a thickened shape—is significantly more difficult. This "offset-deconstruction" is crucial for recovering intended designs from noisy data or simplifying complex geometries for efficient manufacturing.

Figure 1: Examples of the offset-deconstruction problem. The goal is to find a simple red polygon P whose offset (grey region) approximates the target shape Q.

The challenge lies in the "lossy" nature of offsetting. Small details, such as tiny dents or holes, can be blurred away during the thickening process. To address this, we look for a "simple-looking" original polygon $P$ that stays within a Hausdorff distance tolerance $\epsilon$ of the target shape $Q$.

The DECIDE Algorithm

The core contribution of this work is a surprisingly elegant 4-step decision algorithm, termed DECIDE, which determines if a valid generator $P$ exists for a given $Q, r,$ and $\epsilon$:

  1. Offset the input $Q$ by the tolerance $\epsilon$.
  2. Inset (erode) the resulting shape by the radius $r$ to identify a candidate region $\Pi$.
  3. Offset this candidate region $\Pi$ by $r + \epsilon$ to produce a reconstructed shape $Q'$.
  4. Check for containment: if the original shape $Q$ is contained within $Q'$, a solution exists.
Figure 6: The final containment check of the DECIDE algorithm, ensuring the original shape Q is covered by the reconstructed offset Q'.

Overcoming Geometric Complexity

A major technical hurdle in this process is the appearance of "indented" circular arcs in intermediate shapes, which are computationally expensive to track and manipulate. We provide a key geometric insight in Theorem 5: indented arcs can effectively be ignored. We prove that a simple polygonal line can produce the same offset as a curved indented region, provided the offset radius is sufficiently large. This allows the algorithm to maintain a manageable $O(n \log n)$ time complexity.

Furthermore, to handle the algebraic numbers (square roots) inherent in circular arcs, we developed a rational approximation version. By approximating disks with $k$-gons and using rational arithmetic, we ensure the algorithm is both certified and robust against precision errors.

Results and Practical Impact

We evaluated our implementation, built on the CGAL library, using various geometric benchmarks. A notable example is the map of Kazakhstan, a complex polygon with 1,881 vertices. Our algorithm reduced this to just 335 vertices while maintaining high approximation quality, processing the entire map in approximately 3.8 seconds on a standard 3 GHz processor.

For convex shapes, the problem is even more efficient. We provide a greedy algorithm that finds a solution with at most one more vertex than the theoretical minimum in $O(n)$ time.

Conclusion and Future Work

This work provides a foundational framework for reversing geometric offsets. While we have solved the decision problem efficiently, finding the absolute minimal number of vertices for non-convex shapes remains a challenging open problem. Future research could extend these concepts to 3D surfaces—essential for 3D printing and mesh simplification—or explore alternative distance metrics like the Fréchet distance to better capture the "flow" of shapes in applications like handwriting recognition.

Summary updated

BibTeX
@article{berberich2012deconstructing,
  author = {Eric Berberich and Dan Halperin and Michael Kerber and Roza Pogalnikova},
  title = {{Deconstructing Approximate Offsets}},
  journal = {Discret. Comput. Geom.},
  year = {2012},
  doi = {10.1007/s00454-012-9441-5},
}
Figure