Sha256: 9a9df2f823b40146b0b7bf595f4686d4b7130dd8714bcb18b797739ee84b6ec4
Contents?: true
Size: 492 Bytes
Versions: 16
Compression:
Stored size: 492 Bytes
Contents
#! /usr/bin/ruby # encoding: utf-8 require 'y_petri' require 'sy' require 'mathn' include YPetri A = Place m!: 10 B = Place m!: 10 AB = Place m!: 0 AB_association = Transition s: { A: -1, B: -1, AB: 1 }, rate: 0.1 AB_dissociation = Transition s: { AB: -1, A: 1, B: 1 }, rate: 0.1 A2B = Transition s: { A: -1, B: 1 }, rate: 0.05 B2A = Transition s: { A: 1, B: -1 }, rate: 0.07 set_step 1 set_target_time 50 set_sampling 1 set_simulation_method :gillespie run! print_recording plot_state
Version data entries
16 entries across 16 versions & 1 rubygems