Scalar Function Topology Divergence (SFTD)
- SFTD is defined as a framework that quantifies local topological differences between scalar functions using persistent homology and explicit spatial localization.
- It provides a robust metric to compare feature mismatches across mathematical, computer vision, and quantum field theory contexts, enhancing traditional global measures.
- Efficient computational methods, including cubical complexes and doubled domain constructions, enable precise extraction of divergence values and topological features.
Scalar Function Topology Divergence (SFTD) is a conceptually distinct framework arising in both topological data analysis (TDA) and quantum field theory (QFT), denoting divergences or dissimilarities in the topology of scalar functions defined on a common domain. In mathematics and computer vision, SFTD refers to a family of metrics that quantify both the scale and location-specific differences between the topological features (via persistent homology) of two scalar functions. In quantum field theory, SFTD captures the new divergences in the spectral expansion of the heat kernel associated with nontrivial geometric or topological structures, such as cones or screw dislocations. Each context provides a precise mathematical definition, computational procedure, and theoretical foundation for SFTD, linking it to diverse applications in mathematical physics, computer vision, and topological analysis (Mota, 2023, Trofimov et al., 2024).
1. Mathematical Definition and Formulations
In TDA and computer vision, SFTD is defined for two scalar functions on a common domain (graph or -dimensional grid). For , sublevel sets are and . Topological features across the filtration (connected components, holes, voids) are tracked using persistent homology, generating th-dimensional persistence barcodes .
SFTD compares not only the number and persistence of features but their explicit spatial localization. It is defined via the construction of a doubled domain and a th "cross-barcode"
and the divergence
0
with typical 1 or 2. Summing over 3 gives the global SFTD up to specified homological dimension.
In high-energy physics, SFTD denotes additional divergence terms in the short-4 expansion of the heat kernel 5 for a Laplacian-like operator 6 on a 7-dimensional manifold 8 with nontrivial topology,
9
where new coefficients 0 arise uniquely from the topological structure, necessitating additional counterterms in regularization schemes (Mota, 2023).
2. Practical Computation and Algorithmic Details
The calculation of SFTD in TDA involves:
- Discretization of 1 and 2 on the chosen domain (3-grid or graph 4).
- Construction of a doubled domain: For graphs, create pairs of vertices 5 with 6 and 7 with 8, plus a root with 9; for grids, build an 0-dimensional cubical complex with values 1, 2, 3.
- Impose a lower-star filtration: 4.
- Compute 5-persistence barcodes of the doubled complex using libraries (giotto-ph, GUDHI) to obtain cross-barcodes.
- Summation of the lengths of cross-barcode intervals yields SFTD.
Complexity depends on the number of vertices 6: persistent homology on 7 vertices scales as 8 for general methods, but cubical complexes offer significant computational advantages on regular lattices. For 9, cubical implementations can handle grids up to 0 with current software (Trofimov et al., 2024).
Pseudocode for the matrix assembly and barcode computation is outlined as Algorithm 1 in (Trofimov et al., 2024).
3. Theoretical Properties
SFTD possesses several key mathematical properties:
- Uniqueness: If 1 for all 2, then 3 and 4 have identical persistence barcodes in every dimension and those features are located at the same domain points.
- Stability: The bottleneck distance between cross-barcodes of 5 and 6 does not exceed the maximum pointwise difference in the scalar functions; i.e.,
7
- Long Exact Sequence: There exists a long exact sequence linking the persistent homology of the filtrations induced by 8, 9, and their minimum, ensuring that cross-barcode intervals precisely encode mismatches in homological features.
In QFT, the SFTD coefficients correspond to new UV-divergent terms (0) in the heat kernel expansion. For conical or screw-dislocation topological defects, these coefficients are nontrivial but can vanish for specific boundary conditions, as parameterized by quasiperiodicity or defect strength (Mota, 2023).
4. Illustrative Examples and Empirical Behavior
Several illustrative instances demonstrate the specificity of SFTD:
- 2D "three-minima" comparison: Distinct local minima in same sublevel-set topology yield identical ordinary barcodes but nonzero 1; SFTD identifies mismatched minima locations explicitly.
- 2D checkerboard lattices: Same number of 2 cycles (loops) placed differently; SFTD quantifies and highlights spatial mismatches in defect placement.
- 3D concentric spheres with bridges: When two spheres are joined by tubes in different spatial positions, standard 3 barcodes (voids) match, but SFTD reflects the localization difference.
- Graph Laplacian eigenvectors: SFTD quantifies topological similarity/dissimilarity of eigenvectors in small-world networks.
These examples illustrate that SFTD penalizes local topological mismatches, in contrast to global metrics (e.g., Wasserstein distances on barcodes) that may match features regardless of their location in the domain (Trofimov et al., 2024).
5. Applications in Computer Vision and Physics
5.1 Computer Vision
SFTD serves as a loss function and error localization tool in several computer vision contexts:
- 3D Shape Reconstruction: When used as an additional loss in SHAPR models for reconstructing 3D cell shapes from 2D slices, SFTD outperforms both voxel-wise (Dice + MSE) and conventional topological (Wasserstein) losses, yielding lower error in metrics such as IoU, volume, surface, roughness, and Wasserstein metrics of topological barcodes; see comparative results in Table 1 of (Trofimov et al., 2024).
- 3D Segmentation: On datasets such as BraTS21, SFTD successfully localizes segmentation errors, identifying topological mismatches that are undetected by ordinary barcodes or voxel-wise metrics. This enables both automatic and human-in-the-loop correction of critical clinical structures.
5.2 Quantum Field Theory
In QFT in nontrivial 4-dimensional spacetimes (conical, screw-dislocation, or combined dispiration geometries), SFTD identifies extra divergence terms in the spectral expansion of the heat kernel, distinct from Euclidean UV divergences. The coefficients, physically realized as additional counterterms, depend on geometric/topological parameters (e.g., opening angle 5, screw strength 6, quasiperiodic parameter 7). For specific parameter values, SFTD-induced divergences vanish, restoring ordinary UV behavior. The SFTD structure determines the necessary regularization and renormalization of vacuum energy and thermal corrections (Mota, 2023).
6. Comparative Analysis and Theoretical Significance
A central distinction of SFTD is its sensitivity to both the scale and localization of topological features, unlike classical TDA metrics based solely on the distribution of persistence intervals. This allows SFTD to separate scalar fields with identical Betti number profiles but different spatial feature arrangements.
In end-to-end learning, SFTD is differentiable with gradients backpropagated through selected birth/death pairs. This yields practical utility as a regularizer or direct loss for deep network optimization, especially in geometric or topological learning tasks. Empirical evidence consistently supports the superiority of SFTD over Betti-matching Wasserstein losses for geometric fidelity, localization, and robustness to misaligned features in 2D and 3D domains.
In quantum field theory, SFTD formalizes the systematic appearance of new divergence structures induced purely by nontrivial topological geometry, providing a principled organization for counterterms and normalization conditions essential to physical predictions.
7. Parameterization, Limitations, and Extensions
The main tunable parameters for SFTD are the power 8 in the divergence (9 commonly used), the homological dimension 0 up to which divergences are summed, and, in learning scenarios, the loss weight 1, usually selected by cross-validation. Computational costs are tractable for graphs up to 2 nodes and 3 grids using efficient cubical persistent homology libraries (Trofimov et al., 2024).
A plausible implication is that while SFTD offers marked improvements for localizing and quantifying topological mismatches, scalability to extremely large, irregular complexes may require further algorithmic development. In QFT, extension to more exotic topologies or higher-spin fields would generalize the program, potentially revealing further classes of nontrivial divergences and their physical implications.
References:
- (Mota, 2023) Vacuum energy, temperature corrections and heat kernel coefficients in 4-dimensional spacetimes with nontrivial topology
- (Trofimov et al., 2024) Scalar Function Topology Divergence: Comparing Topology of 3D Objects