;; simlulator
(define run-petri-net
(lambda (cnt places transitions killstate)
(println cnt 'state: places)
(for-each (lambda (t) (t)) transitions)
(if (killstate places)
(println 'final 'state: places)
(schedule (+ (now) (* .5 *second*)) 'run-petri-net
(+ cnt 1)
places transitions
killstate))))