Composite Data Structures

The package relies on a number of basic composite data structures that encompass more complicated objects. For the internal representation of sparse matrices we refer to Internal Sparse Matrix Representation.

ConleyDynamicsModule
module ConleyDynamics

Collection of tools for computational Conley theory.

source

Lefschetz Complex Type

ConleyDynamics.AbstractComplexType
AbstractComplex

Abstract base type for Lefschetz complexes.

Both LefschetzComplex and EuclideanComplex are subtypes of AbstractComplex. All topology, homology, and dynamics functions accept any AbstractComplex.

source
ConleyDynamics.LefschetzComplexType
LefschetzComplex
LefschetzComplex(labels, dimensions, boundary; validate=true)

Collect the Lefschetz complex information in a struct.

The struct is created via the following fields:

  • labels::Vector{String}: Vector of labels associated with cell indices
  • dimensions::Vector{Int}: Vector cell dimensions
  • boundary::SparseMatrix: Boundary matrix, columns give the cell boundaries

It is expected that the dimensions are given in increasing order, and that the square of the boundary matrix is zero. Otherwise, exceptions are raised. In addition, the following fields are created during initialization:

  • ncells::Int: Number of cells
  • dim::Int: Dimension of the complex
  • indices::Dict{String,Int}: Dictionary for finding cell index from label

The coefficient field is specified by the boundary matrix.

The optional keyword argument validate controls whether the constructor verifies that the boundary matrix squares to zero. By default this check is enabled. Internal library functions that are guaranteed to produce a valid complex by construction (simplicial, cubical, restriction, permutation, basis-change, etc.) pass validate=false explicitly to suppress the check, since for large complexes the matrix multiplication is expensive. Users constructing a LefschetzComplex manually can also call validate_lefschetz_complex to check an existing complex at any point.

source
ConleyDynamics.EuclideanComplexType
EuclideanComplex
EuclideanComplex(labels, dimensions, boundary, coords; validate=true)

A Lefschetz complex with embedded Euclidean coordinates for every cell.

The struct shares the fields of LefschetzComplex:

  • labels::Vector{String}: Vector of labels associated with cell indices
  • dimensions::Vector{Int}: Vector of cell dimensions
  • boundary::SparseMatrix: Boundary matrix, columns give the cell boundaries
  • ncells::Int: Number of cells
  • dim::Int: Dimension of the complex (must satisfy dim ≤ 3)
  • indices::Dict{String,Int}: Dictionary for finding cell index from label

In addition it carries:

  • coords::Vector{Vector{Vector{Float64}}}: Per-cell vertex coordinates. coords[k] is the list of vertex coordinate vectors needed to draw cell k:
    • Vertex: [[x,y]] (length 1)
    • Edge: [[x1,y1],[x2,y2]] (length 2)
    • Triangle: [[x1,y1],[x2,y2],[x3,y3]] (length 3)
    • Cubical 2-cell: [[x1,y1],[x2,y2],[x3,y3],[x4,y4]] (length 4)

An EuclideanComplex can be created from an existing LefschetzComplex using lefschetz_to_euclidean, and converted back using euclidean_to_lefschetz.

source
Base.showMethod
Base.show(io::IO, ::MIME"text/plain", lc::LefschetzComplex)

Display Lefschetz complex information when hitting return in REPL.

source
Base.showMethod
Base.show(io::IO, ::MIME"text/plain", ec::EuclideanComplex)

Display EuclideanComplex information when hitting return in REPL.

source

Cell Subset Types

ConleyDynamics.CellType
Cell = Union{Int,String}

A cell of a Lefschetz complex.

This data type is used to represent a cell of a Lefschetz complex. The cell can be specified either via its index, or its label.

source
ConleyDynamics.CellsType
Cells = Union{Vector{Int},Vector{String}}

A list of cells of a Lefschetz complex.

This data type is used to represent subsets of a Lefschetz complex. It is used for individual isolated invariant sets, locally closed subsets, and multivectors.

source
ConleyDynamics.CellSubsetsType
CellSubsets = Union{Vector{Vector{Int}},Vector{Vector{String}}}

A collection of cell lists.

This data type is used to represent a collection of subsets of a Lefschetz complex. It is used for Morse decompositions and for multivector fields.

source

Conley-Morse Graph Type

ConleyDynamics.ConleyMorseCMType
ConleyMorseCM{T}

Collect the connection matrix information in a struct.

The struct has the following fields:

  • matrix::SparseMatrix{T}: Connection matrix
  • columns::Vector{Int}: Corresponding columns in the boundary matrix
  • poset::Vector{Int}: Poset indices for the connection matrix columns
  • labels::Vector{String}: Labels for the connection matrix columns
  • morse::Vector{Vector{String}}: Vector of Morse sets in original complex
  • conley::Vector{Vector{Int}}: Vector of Conley indices for the Morse sets
  • complex::LefschetzComplex: The Conley complex as a Lefschetz complex
source
Base.showMethod
Base.show(io::IO, ::MIME"text/plain", cm::ConleyMorseCM)

Display connection matrix information when hitting return in REPL.

source