Discussing the article: "Persistent Homology in MQL5: The Reduction Algorithm and the Persistence Diagram"

 

Check out the new article: Persistent Homology in MQL5: The Reduction Algorithm and the Persistence Diagram.

We complete persistent homology for MQL5 by reducing the Vietoris–Rips boundary matrix to a persistence diagram. The article implements Z/2 column reduction (CTDAReduction), a diagram container with analytics (CTDADiagram), and a facade that runs the six-stage pipeline in one call (CTDA). Outputs are cross-checked against Ripser to numerical agreement, enabling reliable diagram-based metrics.

In the previous article we built two classes. The Vietoris-Rips filtration enumerated every vertex, edge, and triangle, sorted by the scale at which it enters the complex. The boundary matrix recorded, for each simplex, the lower-dimensional simplices that form its border. We ended with a sorted list of simplices and a sparse matrix over Z/2.

That matrix holds the answer, but not in readable form. The loops and connected components are encoded in its column relationships, not stated outright. Extracting them is the job of one algorithm: the standard column reduction. It is the computational heart of persistent homology, and it is what this article implements.

The output is a persistence diagram. Each entry is a birth-death pair: a topological feature, its homology dimension, the scale at which it appeared, and the scale at which it vanished. Long-lived pairs are real structure. Short-lived pairs are noise. This is the payoff the first two articles were building toward.

This article introduces three classes. CTDAReduction runs the reduction. CTDADiagram stores the resulting pairs and answers questions about them. CTDA is a facade that runs the whole six-step pipeline in one call. By the end, you can pass a price window to a single Compute call. It returns a persistence diagram whose birth and death values match an independent reference to six decimal places. The article closes with that verification: a bit-for-bit comparison against Ripser.


Author: Hammad Dilber