Papers
Topics
Authors
Recent
2000 character limit reached

B-Rep Distance Functions (BR-DF)

Updated 22 November 2025
  • B-Rep Distance Functions (BR-DF) are a framework that encodes and analyzes geometric models from boundary representations using distance-based volumetric constructs.
  • They provide explicit volumetric encoding of both geometry and topology, enabling robust algorithms for CAD, shape optimization, and level set methods.
  • BR-DF methods utilize precise gradient and Hessian formulations, facilitating efficient surface reconstruction and accurate detection of singularities in 2D and 3D models.

Boundary-Representation Distance Functions (BR-DF) constitute a unified framework for encoding, analyzing, and reconstructing geometric models from their boundary representations using distance-based volumetric and functional constructs. BR-DF plays a crucial role in CAD, shape optimization, level set methods, and generative modeling, providing both explicit geometric information and a basis for robust numerical algorithms (Zhang et al., 18 Nov 2025, Abgrall, 2022, Safdari, 2016).

1. Mathematical Preliminaries: Definitions and Core Properties

Let UR2U \subset \mathbb{R}^2 (or, in the volumetric setting, MR3M \subset \mathbb{R}^3) be a bounded domain with a boundary representation (B-Rep) specified via vertices, edges, and faces. The BR-DF framework generalizes the notion of distance-to-boundary using the gauge function γK\gamma_K of a compact, convex set KK with $0$ in its interior. For any xUx \in \overline{U}, the KK-distance to the boundary is defined as

dK(x)=minyUγK(xy)d_K(x) = \min_{y \in \partial U} \gamma_K(x - y)

where

γK(x)=inf{λ>0:xλK}\gamma_K(x) = \inf\{\lambda > 0 : x \in \lambda K\}

and γK\gamma_{K^\circ}, the polar gauge, is given by

γK(y)=inf{μ>0:yμK},K={y:x,y1 xK}\gamma_{K^\circ}(y) = \inf\{\mu > 0 : y \in \mu K^\circ\}, \quad K^\circ = \{y : \langle x, y \rangle \leq 1 \ \forall x \in K\}

For standard Euclidean distances, KK is the unit disk.

The volumetric extension, crucial for 3D geometry and CAD, utilizes the signed distance function (SDF)

φ(x)={minyMxy,xinterior(M) +minyMxy,xM\varphi(x) = \begin{cases} -\min_{y \in \partial M} \|x - y\|, & x \in \text{interior}(M) \ +\min_{y \in \partial M} \|x - y\|, & x \notin M \end{cases}

The set Σ={xΩφ(x)=0}\Sigma = \{x \in \Omega \mid \varphi(x) = 0\} forms a watertight surface encompassing the geometry (Zhang et al., 18 Nov 2025).

For each B-Rep face fif_i, a per-face unsigned distance function (UDF) is defined as

ui(x)=minyfixy,ui:ΩR0u_i(x) = \min_{y \in f_i} \|x - y\|, \quad u_i : \Omega \to \mathbb{R}_{\geq 0}

These fields capture both the geometry (SDF) and topology (via the collection of {ui}\{u_i\}) of a B-Rep model.

2. Regularity, Ridge Set, and Generalized Curvature

The regularity properties of dKd_K depend strongly on the boundary geometry and the choice of norm. At points xUx \in U with a unique closest boundary point yUy \in \partial U and under sufficient smoothness of U\partial U, the following hold:

  • Gradient:

dK(x)=νγK(ν),ν=inward normal at y\nabla d_K(x) = \frac{\nu}{\gamma_{K^\circ}(\nu)}, \quad \nu = \text{inward normal at } y

  • Hessian (for 1κK(y)dK(x)01 - \kappa_K(y) d_K(x) \neq 0):

D2dK(x)=ΔdK(x)(ζζ),ΔdK(x)=κ(y)ν3DγK(ν)2γK(ν)3(1κK(y)dK(x))D^2d_K(x) = \Delta d_K(x) (\zeta \otimes \zeta), \qquad \Delta d_K(x) = -\frac{\kappa(y) |\nu|^3 |D\gamma_{K^\circ}(\nu)|^2}{\gamma_{K^\circ}(\nu)^3 (1-\kappa_K(y) d_K(x))}

ζ\zeta is the unit vector orthogonal to (xy)(x-y).

Singularities arise where the closest boundary point is non-unique or the denominator vanishes, i.e., 1κK(y)dK(x)=01-\kappa_K(y)d_K(x)=0. The ridge set RKR_K (a generalization of the medial axis) consists of all points where dKd_K is not locally C1,1C^{1,1}:

RK=RK,0{xURK,0:1κK(y(x))dK(x)=0}R_K = R_{K,0} \cup \{x \in U \setminus R_{K,0} : 1 - \kappa_K(y(x)) d_K(x) = 0\}

with RK,0R_{K,0} being loci with multiple closest boundary points (Safdari, 2016). The KK-curvature κK\kappa_K generalizes traditional curvature to arbitrary gauges.

3. BR-DF Representation and Topology Encoding

In modern applications, especially CAD geometry, BR-DF encodes not only surface geometry but also face, edge, and vertex structure:

  • For a discrete 3D grid, one stores φ\varphi (SDF) and all uiu_i (per-face UDFs) (Zhang et al., 18 Nov 2025).
  • On the zero level set Σ\Sigma, face indices are recovered as i(x)=argminiui(x)i^*(x) = \arg\min_i u_i(x).
  • Face regions, edges, and vertices are encoded via local co-minimality:
    • Face patch: Fi={xΣ:ui(x)uj(x),j}F_i = \{x \in \Sigma : u_i(x) \leq u_j(x), \forall j\}
    • Edge: Eij={xΣ:ui(x)=uj(x)uk(x),k}E_{ij} = \{x \in \Sigma : u_i(x) = u_j(x) \leq u_k(x), \forall k\}
    • Vertex: Vijk={xΣ:ui(x)=uj(x)=uk(x)u(x),}V_{ijk} = \{x \in \Sigma : u_i(x) = u_j(x) = u_k(x) \leq u_\ell(x), \forall \ell\}

This volumetric encoding enables implicit representation of topological adjacency, obviating explicit graph structures.

4. Algorithms for Computation and Reconstruction

For 2D polygonal B-Rep boundaries under arbitrary asymmetric norms:

  • Each query xx computes de=γK(xye)d_e = \gamma_K(x - y_e) for every edge projection yey_e, and dv=γK(xv)d_v = \gamma_K(x - v) for vertices.
  • The minimum distance dmind_{\min} sets dK(x)d_K(x). If multiple minimizers exist, xx lies on the ridge.
  • The gradient and Hessian are evaluated at non-ridge points as above.
  • The algorithm identifies singularities via ridge conditions and provides pseudocode for efficient evaluation (Safdari, 2016).

For 3D BR-DF models:

  • The Marching Cubes and Triangles (MCT) algorithm extracts the surface mesh from sampled φ\varphi.
  • Each mesh vertex is assigned a face label via minimal uiu_i.
  • Edges and vertices are reconstructed by local intersection and co-minimality of UDFs, ensuring watertight, topologically consistent faceted B-Rep meshes.
  • This process is strictly local per triangle, but guarantees global watertightness and combinatorial correctness (Zhang et al., 18 Nov 2025).

5. Elliptic and Variational Methods for BR-DF Computation

Traditional fast-marching and sweeping schemes solve the Eikonal equation on structured domains. For general B-Rep (complex or unstructured), the elliptic approximation via the Hopf–Cole transform provides enhanced efficiency and robustness (Abgrall, 2022):

  • Given target Eikonal u21=0|\nabla u|^2 - 1 = 0 in Ω\Omega with Dirichlet BC on ΓD\Gamma_D,
  • Introduce viscosity ν\nu to obtain u21=νΔu|\nabla u|^2 - 1 = \nu \Delta u,
  • Via u(x)=νlogφ(x)u(x) = -\nu \log \varphi(x), the problem becomes linear: ν2Δφ=φ\nu^2 \Delta \varphi = \varphi with φ=1\varphi=1 on ΓD\Gamma_D.
  • Uzawa-type iterations update side boundaries using a discrete Godunov-type rule; convergence is ensured by a discrete maximum principle.
  • Error estimates: φφhLCh2/ν2\|\varphi - \varphi^h\|_{L^\infty} \leq C h^2/\nu^2, giving uuhLC(h/ν+ν)\|u-u_h\|_{L^\infty} \leq C(h/\nu+\nu) for mesh size hh.
  • Empirical complexity O(h1)\mathcal{O}(h^{-1}), significantly better than hyperbolic solvers on fine meshes (Abgrall, 2022).

The elliptic approach is particularly suitable for repeated BR-DF evaluations in turbulence modeling, image analysis, and design tasks requiring numerous distance queries.

6. Generative Modeling and Data-driven BR-DFs

The BR-DF representation underlies generative models for 3D B-Rep geometry:

  • A two-stage latent diffusion framework jointly predicts the SDF and UDFs: first, bounding-box diffusion to estimate the number and extent of faces; second, 3D VQ-VAE encodings and a 3D U-Net latent diffusion model reconstruct the volumetric distance fields.
  • Cross-attention in the U-Net enables conditioning the SDF (global shape) on facial UDFs and vice versa.
  • The joint latent model is trained to minimize predicted noise on both surface and face-branch latents.
  • Experimental outcomes show high coverage (COV≈73.7%), low Chamfer distance (≈6.6×10{-4}) validating topological and geometric faithfulness, with 100% success in producing watertight faceted B-Rep models (Zhang et al., 18 Nov 2025).

7. Applications and Implications

BR-DFs unify Euclidean, pp-norm, and arbitrary Finsler-type distance computations, generalize medial skeletons to non-Euclidean settings, and provide explicit volumetric encoding of B-Rep geometry and topology:

  • Offset surface computation in CAD
  • Fast front-propagation and level set schemes
  • Shape optimization, variational PDEs, and Monge–Kantorovich problems
  • Curvature-driven flows and image processing
  • Generative 3D model synthesis from latent spaces using distance-based fields

Robustness to geometric degeneracies, explicit gradient and Hessian formulas, and amenability to linear-algebraic acceleration render BR-DF a foundational tool in modern geometric computing (Safdari, 2016, Abgrall, 2022, Zhang et al., 18 Nov 2025).

Domain Key BR-DF Role Notable Reference
CAD Modeling Geometry/topology encoding (Zhang et al., 18 Nov 2025)
PDE/Numerics Distance for front evolution (Abgrall, 2022)
Medial Axis Ridge set analysis (Safdari, 2016)

The BR-DF methodology is extensible to higher-dimensional and more abstract settings, suggesting continued relevance in shape analysis and computational design.

Slide Deck Streamline Icon: https://streamlinehq.com

Whiteboard

Forward Email Streamline Icon: https://streamlinehq.com

Follow Topic

Get notified by email when new papers are published related to B-Rep Distance Functions (BR-DF).