jsf

jsf.ArrayMultiplyAB(ArrayA, ArrayB)
jsf.ArrayPlusAB(ArrayA, ArrayB)
jsf.ArraySubtractAB(ArrayA, ArrayB)
jsf.ComputeFiringTimes(firedReactions, integralOfFiringTimes, randTimes, Props, dt, nRates, integralStep)
jsf.ComputeIntegralOfFiringTimes(Dtau, Props, rates, Xprev, Xcurr, AbsT)
jsf.ComputedXdt(Props: List[float], nu: List[List[float]], frozenReaction: List[bool], nCompartments: int) List[float]

Compute the derivative of the state vector at time t for the continuous compartments by summing the contributions from each reaction.

Args:

Props: A list of the propensities of each reaction. nu: The stoichiometry matrix. frozenReaction: A list of booleans indicating which reactions

are frozen.

nCompartments: The number of compartments in the system.

jsf.ImplementFiredReaction(tauArray, integralOfFiringTimes, randTimes, Props, rates, integralStep, TimePassed, AbsT, X, iters, nu, dXdt, OriginalDoDisc, frozenReaction)
jsf.IsDiscrete(X, SwitchingThreshold, DoDisc, EnforceDo, frozenReaction, compartInNu, nCompartments, nRates)
jsf.JumpSwitchFlowSimulator(x0: SystemState, rates: Callable[[SystemState, Time], List[float]], stoich: Dict[str, Any], t_max: Time, options: Dict[str, Any]) Trajectory

Simulate a jump-switch-flow process using the operator splitting method.

Args:

x0: The initial state of the system. rates: A function that takes the current state and time and

returns the rates of each reaction.

stoich: A dictionary containing the stoichiometry of the

system.

t_max: The final time of the simulation. options: A dictionary containing the simulation options.

Returns:

A list containing the time series of the state of the system.

jsf.MatrixDOTArray(Matrix, Array)
jsf.MatrixPlusAB(MatrixA, MatrixB)
jsf.MatrixSubtractAB(MatrixA, MatrixB)
jsf.UpdateCompartmentRegime(dt, Xprev, Dtau, dXdt, Props, nu, SwitchingThreshold, DoDisc, EnforceDo, frozenReaction, compartInNu, nCompartments, nRates)
jsf.jsf(x0: SystemState, rates, stoich, t_max, **kwargs) Trajectory

Generates a sample from the JSF process.

Args:

x0: The initial state of the system. rates: A function that takes the current state and time and

returns the rates of each reaction.

stoich: A dictionary containing the stoichiometry of the

system.

t_max: The final time of the simulation. **kwargs: A dictionary containing the simulation options.

Returns:

A list containing the time series of the state of the system.

Raises:

RuntimeError: If the requested method is not implemented.

jsf.num_non_zero(array: List[float] | List[int] | List[Time]) int