Reference
Simplicial Complexes
Construction
Hodge.SimplicialComplex — TypeSimplicialComplexRepresent an abstract simplicial complex where all vertices are labeled by integers.
Internally, use the SimplexTrees.SimplexTree data structure.
Base.insert! — Methodinsert!(sc::SimplicialComplex, σ)Insert the simplex σ and all its faces on the SimplicialComplex sc.
The simplex does not need to be ordered.
Hodge.skeleton — Functionskeleton(sc, k)Return the k-skeleton of a SimplicialComplex. That is, a SimplicialComplex with the same simplices as sc up to dimension k.
Accessing
Hodge.dimension — Functiondimension(sc)Return the dimension of the largest simplex on a SimplicialComplex.
Hodge.hassimplex — Functionhassimplex(sc, σ)Test whether the SimplicialComplex sc contains the simplex σ.
Hodge.vertices — Functionvertices(sc)Return an array containg the vertices of the SimplicialComplex sc.
See also simplices. Notice that this function returns an array of integers while simplices(sc, 0) returns an array of singleton arrays containing the vertices.
Hodge.numvertices — Functionnumvertices(sc)Return how many vertices (1-simplices) the SimplicialComplex sc has.
Hodge.simplices — Functionsimplices(sc[, k])Return all simplices of the SimplicialComplex sc whose dimension equals k.
If the parameter k is not given, return all simplices of sc including the empty face.
Hodge.numsimplices — Functionnumsimplices(sc[, k])Return the number of k-dimensional simplices of sc.
If the parameter k is not given, return the total number of simplices including the empty face.
This function is a more efficient implementation of length ∘ simplices.
Topological Operators
Hodge.euler_characteristic — Functioneuler_characteristic(K)Return the Euler characteristic of a SimplicialComplex.
Hodge.betti — Functionbetti(K)Return the Betti numbers of a SimplicialComplex.
Cochains
Construction
Hodge.Cochain — TypeCochain{R, n}Represent the n-th group $C^n(K; R)$ of cochains over the ring R whose basespace is the simplicial complex $K$.
For constructing Cochains, see also the methods zero_cochain and indicator_cochain.
The elements of this type may be seem as functions from the n-simplices of K to R or as skew-symmetric n-tensors over the vertices of K. This second perspective follows the ideas from the paper:
- Jiang, X., Lim, L., Yao, Y. et al. Statistical ranking and combinatorial Hodge theory. Math. Program. 127, 203–244 (2011). https://doi.org/10.1007/s10107-010-0419-x
Hodge.zero_cochain — Functionzero_cochain(R, K, n)Construct an identically zero n-cochain over R and whose base space is K.
Hodge.indicator_cochain — Functionindicator_cochain(R, K, σ)Return the indicator function f of the n-simplex σ as a Cochain. That is, a cochain such that f(σ) = 1 and f(τ) = 0 for all other n-simplices of K.
Notice that, nevertheless, f is still skew-symmetric over permutations of σs indices.
If Κ does not contain σ, the returned cochain is identically zero.
Operators
Hodge.basespace — Functionbasespace(ω::Cochain)Return the simplicial complex that ω is associated with.
Hodge.basering — Functionbasering(ω::Cochain)Return the Ring that ω is defined over.
Hodge.degree — Functiondegree(ω::Cochain)Return the degree of a Cochain.
Hodge.norm — Functionnorm(ω[, p])Calculate the p-norm of the Cochain ω.
By default, p=2.
Return a floating point, no matter the base ring of ω.
Hodge.norm2 — Functionnorm2(ω)Calculate the square of the usual inner product norm of a Cochain ω.
Hodge.inner — Functioninner(ω, ξ)Usual inner product between Cochains.
For complex Cochains, the conjugation is taken on the first entry.
This inner product sees a n-cochain as a free vector space over the (non-oriented) n-simplices of their base space. Formally,
\[\sum_{\sigma \in \mathrm{simplices}(K,n)} \overline{f(σ)} g(σ).\]
Hodge.cup — Functioncup(ω, ξ)The cup product $\omega \smile \xi$ of two Cochains.
Hodge.coboundary — Functioncoboundary(ω)The coboundary or discrete exterior derivative of a Cochain.
The coboundary of $ω$ applied to a simplex $σ$ equals the alternating sum of $ω$ applied to the faces of $σ$.
Hodge.coboundary_adj — Functioncoboundary_adj(ω)The adjoint of the coboundary with respect to usual inner product.
Hodge.laplacian — Functionlaplacian(ω)The (higher-order) laplacian of ω, defined as
\[ \delta = d d^* + d^* d\]
where $d$ and $d^*$ are, respectively, the coboundary and coboundary_adj operators.
Hodge.hodge — Functionhodge(ω)Hodge decomposition of a Cochain using inner as the inner product.
Return a tuple (α,β,γ) such that
ω == coboundary(α) + coboundary_adj(β) + γ
laplacian(γ) == 0