Properties

class pydtmc.MarkovChain[source]
absorbing_states: List[List[str]][source]

A property representing the absorbing states of the Markov chain.

accessibility_matrix: ndarray[source]

A property representing the accessibility matrix of the Markov chain.

adjacency_matrix: ndarray[source]

A property representing the adjacency matrix of the Markov chain.

communicating_classes: List[List[str]][source]

A property representing the communicating classes of the Markov chain.

communication_matrix: ndarray[source]

A property representing the communication matrix of the Markov chain.

cyclic_classes: List[List[str]][source]

A property representing the cyclic classes of the Markov chain.

cyclic_states: List[List[str]][source]

A property representing the cyclic states of the Markov chain.

density: float[source]

A property representing the density of the transition matrix of the Markov chain.

determinant: float[source]

A property representing the determinant of the transition matrix of the Markov chain.

entropy_rate: float | None[source]
A property representing the entropy rate of the Markov chain.
If the Markov chain has multiple stationary distributions, then None is returned.
entropy_rate_normalized: float | None[source]
A property representing the entropy rate, normalized between 0 and 1, of the Markov chain.
If the Markov chain has multiple stationary distributions, then None is returned.
fundamental_matrix: ndarray | None[source]
A property representing the fundamental matrix of the Markov chain.
If the Markov chain is not absorbing or has no transient states, then None is returned.
implied_timescales: ndarray | None[source]
A property representing the implied timescales of the Markov chain.
If the Markov chain is not ergodic, then None is returned.
incidence_matrix: ndarray[source]

A property representing the incidence matrix of the Markov chain.

is_absorbing: bool[source]

A property indicating whether the Markov chain is absorbing.

is_aperiodic: bool[source]

A property indicating whether the Markov chain is aperiodic.

is_canonical: bool[source]

A property indicating whether the Markov chain has a canonical form.

is_doubly_stochastic: bool[source]

A property indicating whether the Markov chain is doubly stochastic.

is_ergodic: bool[source]

A property indicating whether the Markov chain is ergodic.

is_irreducible: bool[source]

A property indicating whether the Markov chain is irreducible.

is_regular: bool[source]

A property indicating whether the Markov chain is regular.

is_reversible: bool[source]

A property indicating whether the Markov chain is reversible.

is_stochastically_monotone: bool[source]

A property indicating whether the Markov chain is stochastically monotone.

is_symmetric: bool[source]

A property indicating whether the Markov chain is symmetric.

kemeny_constant: float | None[source]
A property representing the Kemeny’s constant of the fundamental matrix of the Markov chain.
If the Markov chain is not absorbing or has no transient states, then None is returned.
lumping_partitions: List[List[List[int]] | List[List[str]]][source]

A property representing all the partitions of the Markov chain that satisfy the ordinary lumpability criterion.

mixing_rate: float | None[source]
A property representing the mixing rate of the Markov chain.
If the Markov chain is not ergodic or the SLEM (second largest eigenvalue modulus) cannot be computed, then None is returned.
n: int

A property representing the size of the Markov chain state space.

p: ndarray

A property representing the transition matrix of the Markov chain.

period: int[source]

A property representing the period of the Markov chain.

periods: List[int][source]

A property representing the period of each communicating class defined by the Markov chain.

pi: List[ndarray][source]
A property representing the stationary distributions of the Markov chain.
Aliases: stationary_distributions, steady_states
rank: int[source]

A property representing the rank of the transition matrix of the Markov chain.

recurrent_classes: List[List[str]][source]

A property representing the recurrent classes defined by the Markov chain.

recurrent_states: List[List[str]][source]

A property representing the recurrent states of the Markov chain.

relaxation_rate: float | None[source]
A property representing the relaxation rate of the Markov chain.
If the Markov chain is not ergodic or the SLEM (second largest eigenvalue modulus) cannot be computed, then None is returned.
size: int

A property representing the size of the Markov chain.

spectral_gap: float | None[source]
A property representing the spectral gap of the Markov chain.
If the Markov chain is not ergodic or the SLEM (second largest eigenvalue modulus) cannot be computed, then None is returned.
states: List[str]

A property representing the states of the Markov chain.

topological_entropy: float[source]

A property representing the topological entropy of the Markov chain.

transient_classes: List[List[str]][source]

A property representing the transient classes defined by the Markov chain.

transient_states: List[List[str]][source]

A property representing the transient states of the Markov chain.