Techinical¶
There are two main technical concerns in implementing the functions defined previously.
An unbounded region is not directly representable.
Rounding errors need to be handled and/or avoided.
Unbounded region¶
Given polygon \(L\), let \(B\) be its bounding rectangle, defined by its two opposite points \((x_{0}, y_{0})\) and \((x_{1}, y_{1})\) where \(x_{0} < x_{1}\) and \(y_{0} < y_{1}\).
Additionally, given \(e\), in turn, we define \(\hat{B}\) as a rectangle defined by points \((x_{0} - 4 \rho_{e}, y_{0} - 4 \rho_{e})\) and \((x_{1} + 4 \rho_{e}, y_{1} + 4 \rho_{e})\).
If we change the definition of \(\mathcal{Q}(\mathcal{T})\) as
Then we can define \(\hat{Q}\) of \(\mathcal{T}\) as the one that includes the point \(u := (x_{0} - 2 \rho_{e}, y_{0} - 2 \rho_{e})\).
Note
The use of constants \(2\) and \(4\) is to simplify expressions while avoiding possible rounding errors and/or edge cases.
Rounding errors¶
As for set relations between regions \(A, B \subseteq \mathbb{R}^{2}\), it would be preferrable to have \(A \subseteq B^{\circ}\) instead of \(A \subseteq B\) whenever possible.
Hence, in determining \(R_{k}\)’s, we actually want as a condition
To avoid rounding errors, we further tweak the definitions as the following.
where \(\varepsilon\) is some fixed threshold.
Although not strictly necessary, for each \(i\) and \(j\), we also alter the definitions of \(R_{i}^{*}\)’s and \(Q_{j}^{*}\)’s to