ContinuousTimeMarkov.CompetingPoissonMethod
CompetingPoisson(rates; events)

The first arrival from competing Poisson point processes with the given rates.

rand returns a NamedTuple{(:duration,:event)}, where duration is the duration until the first event and event is drawn from events.

Varios properties are supported, see propertynames.

Note

The distribution of duration is Exponential(1/sum(rates)), so this process can also be thought of as competing exponentials.

ContinuousTimeMarkov.TransitionRateMatrixMethod
TransitionRateMatrix(Q)

Create a transition rate matrix from the argument. This makes a copy, checks that off-diagonal elements are nonnegative, and sets the diagonal so that rows sum to 0, striving to preserve sparsity and structure.

ContinuousTimeMarkov.normalize_diagonal!Method
normalize_diagonal!(A)

Set the diagonal of the argument (which is modified) so that rows sum to 0.

Internal, not part of the API. Works with generalized indexing.