edu.stanford.math.plex
public class Persistence extends java.lang.Object
Persistence
class class implements the algorithm of
Zomorodian and Carlsson for computing the persistent homology groups
with coefficients in a finite field. The details of this are too complex
to explain here. See A. Zomorodian and G. Carlsson, "Computing
persistent homology," Discrete and Computational Geometry, 33
(2), pp. 247-274.
The algorithm needs to be extended to return useful basis elements for the homology, and do cohomology calculations. And a really big, open question is how to do the same sort of calculation when using some representation (possibly simplicial sets) that will scale better at the persistence parameter increases.
Constructor and Description |
---|
Persistence() |
Modifier and Type | Method and Description |
---|---|
static int |
baseModulus()
What is modulus of the coefficient field?
|
PersistenceInterval.Float[] |
computeIntervals(SimplexStream stream)
Calculate the persistent homology.
|
PersistenceInterval.Float[] |
computeIntervals(SimplexStream stream,
boolean preserveStream,
int prime)
Calculate the persistent homology with a specified Zp.
|
PersistenceInterval[] |
computeRawIntervals(SimplexStream stream,
boolean preserveStream,
int prime)
Calculate the raw persistent intervals for a stream, using a specified Zp.
|
int |
cycleSpaceDimension()
Return the dimension of the cycle space.
|
static void |
setBaseModulus(int modulus)
Set or reset the coefficient field.
|
public static int baseModulus()
public static void setBaseModulus(int modulus)
modulus
- Must be a prime in [2,255].java.lang.IllegalArgumentException
public int cycleSpaceDimension()
This function is for performance tuning and pandering to aimless curiosity.
public PersistenceInterval.Float[] computeIntervals(SimplexStream stream)
stream
- generates simplices in persistence/dimension order.public PersistenceInterval.Float[] computeIntervals(SimplexStream stream, boolean preserveStream, int prime)
stream
- generates simplices in persistence/dimension order.preserveStream
- If true, don't deplete the stream.prime
- Set the base field to be Z/prime.public PersistenceInterval[] computeRawIntervals(SimplexStream stream, boolean preserveStream, int prime)
stream
- generates simplices in persistence/dimension order.preserveStream
- If true, don't deplete the stream.prime
- Set the base field to be Z/prime.