#include <sources/headers/Chain.h>
template<typename Coeff>
Chain struct
list of clinks (Clink), representing a single indecomposable summand of a looptype complex. If the morphism of the last Clink is nonzero, the chain corresponds to a compact curve; otherwise it corresponds to a noncompact one.
Constructors, destructors, conversion operators
 Chain(const std::string str)
 convert output of Chain::
to_string() back into chain  Chain(std::vector<Clink<Coeff>> clinks)
 standard constructor
Public functions
 void concentrate_local_system()
 move all nontrivial coefficients into the first Clink (if the corresponding curve is compact) or make all equal to 1 (if the corresponding curve is noncompact)
 void fix_shorts()
 convert chain representation of short figure8s into standard form
 auto is_compact() const > bool
 true if chain is compact, ie if the last clink has an arrow.
 auto operator<(const Chain<Coeff>& chain2) const > bool
 standard comparison operator
 auto size() const > size_t
 length (=#objects) of chain
 void sort()
 sort generators such that the first one has minimal quantum grading, and the first morphism is type S (if possible)

auto to_Khr_curve() const > Khr_
curve  attempt to recognize a chain as a component from the clasification of components of

auto to_string(const max_
gr_ & max_gr = {}, const bool& is_4ended = true) const > std::stringstr  string representative of chain; the options are the same as Clink::
to_string
Public variables
Function documentation
template<typename Coeff>
void Chain<Coeff>:: fix_shorts()
convert chain representation of short figure8s into standard form
Convert ●——(D^n+S^2n)—>●
into ●——(D^n)—>●<~(S^2n)~~
.
template<typename Coeff>
std::string Chain<Coeff>:: to_string(const max_gr_str & max_gr = {},
const bool& is_4ended = true) const
string representative of chain; the options are the same as Clink::
converts a single chain to a string
detailed test documentation