The Crystal Programming Language Forum

Queuing systems and Discrete-Event Simulation

Hi folks! Lately, I’ve been playing with some Crystal code to run simulations for simple queuing systems.


The inspiration for this work is a set of notes from an Operations Research course by Prof. Beasley. If the topic interests you, I suggest you
  1. read the notes
  2. watch the videos
  3. checkout the code and simulate your own queuing system!

Related shards you might want to check out

  • statistics: a statistical library to perform descriptive statistics and generate random values based on popular probability distributions.
  • quartz: a library for defining models and constructing discrete event simulations based on the PDEVS (Parallel Discrete EVent System Specification) and some of its extensions (DSDE, multiPDEVS) - thanks @rumenzu.
10 Likes

I didn’t watch the entire video but thank you for making high quality and practical content. I also love that your programs output nice tables in the terminal.

Amazing content, Thank you for sharing! :smile: :+1:

Hi !

Thanks for the content and for starting a thread on M&S :slight_smile:

I thought it would be nice to reproduce the queuing example using quartz, a crystal simulation framework.

You can checkout the code that will give similar results.

The framework lacks documentation but I will try to improve this in the future.

1 Like

I put some effort in documenting quartz which will hopefully help people getting started.

Checkout the wiki if you are interested in learning how to use the tool.
I tried to write some parts like a tutorial which is inspired from how the underlying formalism can be teached.

It’s not 100% complete but getting close.

BTW this shard is around from quite some time now, although I just recently started to version it. It is quite stable, although it is an experimental tool mainly used to publish in scientific articles.

Enjoy! :slight_smile:

PS : feedbacks on how the docs can be improved are welcome!