module YPetri::Simulation::TransitionRepresentation::Type_TS

Attributes

rate_closure[R]

Public Instance Methods

firing(Δt) click to toggle source

Firing of the transition (rate * Δtime).

# File lib/y_petri/simulation/transition_representation/TS.rb, line 29
def firing Δt
  rate * Δt
end
flux()
Alias for: rate
gradient_all()
Alias for:
init() click to toggle source

Initialization subroutine.

# File lib/y_petri/simulation/transition_representation/TS.rb, line 14
def init
  super
  @rate_closure = to_rate_closure
end
propensity()
Alias for: rate
rate() click to toggle source

Transition's rate, given the current system state.

# File lib/y_petri/simulation/transition_representation/TS.rb, line 21
def rate
  rate_closure.call
end
Also aliased as: flux, propensity
to_rate_closure() click to toggle source

Builds a flux closure.

# File lib/y_petri/simulation/transition_representation/TS.rb, line 42
def to_rate_closure
  build_closure
end
() click to toggle source

Gradient contribution of the transition to all places.

# File lib/y_petri/simulation/transition_representation/TS.rb, line 35
def 
  codomain >> stoichiometry.map { |coeff| rate * coeff }
end
Also aliased as: gradient_all