Base algorithm

class autolyap.algorithms.Algorithm(
n: int,
m: int,
m_bar_is: List[int],
I_func: List[int],
I_op: List[int],
)[source]

Bases: ABC

Abstract base class (ABC) for algorithms expressed in the state-space representation used by AutoLyap.

See 3. Algorithm representation for notation and representation conventions.

Note

  • For a given method, the state-space representation is not unique.

  • Concrete subclasses must implement get_ABCD(); all other methods are implemented by this base class.

__init__(
n: int,
m: int,
m_bar_is: List[int],
I_func: List[int],
I_op: List[int],
) None[source]

Initialize an Algorithm with the structural parameters of the representation.

Parameters

  • n (int): the state dimension, i.e., \(\bx^{k} \in \calH^{n}\).

  • m (int): the number of components \(m\) in the inclusion problem.

  • m_bar_is (List[int]): the list \((\bar{m}_i)_{i=1}^{m}\) of evaluation counts per component, with \(\bar{m}_i \in \mathbb{N}\) for each \(i\).

  • I_func (List[int]): the index set \(\IndexFunc\) for functional components.

  • I_op (List[int]): the index set \(\IndexOp\) for operator components.

Raises

  • ValueError: if \(n < 1\), \(m < 1\), \(m \neq \text{len}(m\_bar\_is)\), if any \(\bar{m}_i \le 0\), \(\IndexFunc\) and \(\IndexOp\) are not disjoint, do not cover \(\llbracket 1, m\rrbracket\), or are not strictly increasing sequences.

abstractmethod get_ABCD(
k: int,
) Tuple[ndarray, ndarray, ndarray, ndarray][source]

See 3. Algorithm representation for notation and representation conventions.

Return the system matrices \((A_k, B_k, C_k, D_k)\) at iteration \(k\).

Parameters

  • k (int): iteration index \(k\).

Returns

  • (Tuple[numpy.ndarray, numpy.ndarray, numpy.ndarray, numpy.ndarray]): A tuple \((A_k, B_k, C_k, D_k)\) of numpy arrays with

    \[A_k \in \mathbb{R}^{n \times n}, \quad B_k \in \mathbb{R}^{n \times \bar{m}}, \quad C_k \in \mathbb{R}^{\bar{m} \times n}, \quad D_k \in \mathbb{R}^{\bar{m} \times \bar{m}}.\]