{'fraction_non_alphanumeric': 0.019784172661870502, 'fraction_numerical': 0.0, 'mean_word_length': 5.321969696969697, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Real Homology Cohomology and Harmonic Cochains, Least Squares, and Diagonal Dominance

We give new algorithms for computing basis cochains for real-valued homology, cohomology, and harmonic cochains on manifold simplicial complexes. We discuss only planar, surface, and solid meshes. Our algorithms are based on a least squares formulation. Previous methods for computing homology and cohomology have relied on persistence algorithm or Smith normal form, both of which have cubic complexity in worst case. Our algorithm is a Hodge decomposition using only the connectivity information of the mesh. This is a pair of least squares problems and thus can be solved using very reliable, efficient, classical iterative linear solvers which work in spite of nontrivial kernels, have guarantees on iteration counts, and work without forming the full linear system. Moreover, as we showed recently elsewhere, the corresponding normal equation matrices are diagonally dominant, allowing the use of recent developments in very fast solvers for such. For harmonic cochains, one previous approach has been to find eigenvectors corresponding to zero eigenvalue of the Laplace-deRham operator. In another approach, earlier methods have required the solution of all lower dimensional problems. We find harmonic cochains by solving a single weighted least squares problem. Our method does not use any inverse Hodge star matrices, since these can be dense if Whitney forms are used. We also show diagonal dominance in certain cases depending on geometric properties of the mesh. Finally, we prove a discrete version of the HodgedeRham theorem relating cohomology and harmonic cochains.