We study the problem of fitting a two-joint orthogonal polygonal chain to a set S of n points in the plane, where the objective function is to minimize the maximum orthogonal distance from S to the chain. We show that this problem can be solved in Θ(n) time if the orientation of the chain is fixed, and in Θ(nlogn) time when the orientation is not a priori known. Moreover, our algorithm can be used to maintain the rectilinear convex hull of S while rotating the coordinate system in O(nlogn) time and O(n) space, improving on a recent result (Bae et al., 2009 ). We also consider some variations of the problem in three-dimensions where a polygonal chain is interpreted as a configuration of orthogonal planes. In this case we obtain O(n), O(nlogn), and O(n2) time algorithms depending on which plane orientations are fixed. © 2010 Elsevier B.V. All rights reserved.
Díaz-Báñez, J. M., López, M. A., Mora, M., Seara, C., & Ventura, I. (2011). Fitting a two-joint orthogonal chain to a point set. Computational Geometry: Theory and Applications, 44(3), 135–147. https://doi.org/10.1016/j.comgeo.2010.07.005