mtsch / Ripserer.jl

Flexible and efficient persistent homology computation.
https://mtsch.github.io/Ripserer.jl/dev/
MIT License
66 stars 8 forks source link

Cubical PH on a torus #158

Open wardjm opened 2 years ago

wardjm commented 2 years ago

I'm not sure how hard this would be or if it is even a new idea. One of the things I'm interested in is doing persistent homology on a Cubical complex where we identify the top and bottom of the matrix and the right and left sides, essentially wrapping around like a torus. I haven't dug into the code to see what the right approach would be. Maybe making a TorusComplex object, and that somehow tells ripserer what to identify? Or should there just be a flag to ripserer when you submit a Cubical object? Thanks!

mtsch commented 2 years ago

Hey, sorry for ignoring this. I somehow missed the issue. I hope it's not too late.

That sounds like a neat idea, and think it should be straightforward to implement! Ripserer uses a CubeMap, which is basically an array that holds the birth values for all elements of the complex. That array would have to be extended in the direction you want to identify, and it would have to be taken into account when computing (co)boundaries. I would implement it as an additional argument to Cubical so we don't have to reimplement the whole thing.

I can give it a whirl when I find the time, or if you want to do it, I'm happy to help with that as well.

wardjm commented 2 years ago

Thanks! My group hasn't had time to explore this. We've been pursing some other stuff. We'd still very much appreciate it and use it if you can do it.