+
+
+ /** Get the value of the birth index w.r.t. to a simplicial order o
+ * and a simplicial function f. Requires that o and f are defined
+ * on the same simplicial complex. */
+ template<class VT>
+ VT get_birth_value(const simplex_order &o, const simplicial_function<MAXDIM, IT, VT> &f) const {
+ assert(&f.get_complex() == &o.get_complex());
+ return f.get_value(o.order_to_complex(birth));
+ }
+
+ /** Get the value of the death index w.r.t. to a simplicial order o
+ * and a simplicial function f. Requires that o and f are defined
+ * on the same simplicial complex. */
+ template<class VT>
+ VT get_death_value(const simplex_order &o, const simplicial_function<MAXDIM, IT, VT> &f) const {
+ assert(&f.get_complex() == &o.get_complex());
+ return f.get_value(o.order_to_complex(death));
+ }
+
+ /** Get the persistence of this point w.r.t. to a simplicial order
+ * o and a simplicial function f. Requires that o and f are defined
+ * on the same simplicial complex. */
+ template<class VT>
+ VT get_persistence(const simplex_order &o, const simplicial_function<MAXDIM, IT, VT> &f) const {
+ assert(&f.get_complex() == &o.get_complex());
+ return get_death_value<VT>(o, f) - get_birth_value<VT>(o, f);
+ }