Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement a standard library for modeling processes #6

Open
abeham opened this issue Sep 24, 2018 · 2 comments
Open

Implement a standard library for modeling processes #6

abeham opened this issue Sep 24, 2018 · 2 comments

Comments

@abeham
Copy link
Member

abeham commented Sep 24, 2018

Many processes can be standardized and a library of atomic processes can be created. In process models one creates a set of agents or entities and models their flow through a network of processes. The network features several streams. Each stream starts at "Create" and ends at "Finalize". Multiple streams may synchronized, they may be created also a result of one stream through "Clone" or merged to one stream using "Merge".

  1. Create - creates new entities (0:1)
  2. Finalize - finalizes the entities (1:0)
  3. Queue - puts entities into a queue (1:1)
  4. Delay - delays entities for some time (1:1)
  5. Attach - request resources and attach them (1:1)
  6. Detach - free resource requests and detach them (1:1)
  7. Collect - combine multiple entities into one collection entity (1:1)
  8. Dispense - dispenses the collection entity (1:1)
  9. Clone - creates one or multiple copies of an entity (1:n)
  10. Merge - creates a new entity based on a number (n:1)
  11. Distribute - select the next process based on some strategies (round-robin, custom) (1:1)
  12. Sync - uses n streams of entities and synchronizes them (n:n)

Collect and dispense are 1:1 because entity collection would also be a sub-type of entity. The resources in Sim# are not subclasses of one common class. Some abstraction must be created that hides the used resource type.

The processes should feature event handlers such as OnEnter, OnExit to allow collecting statistics or perform other manipulation to the entity instance.

@sean-reed
Copy link
Contributor

There is a DES library for the R language, called simmer, based around this very concept. They call the streams that entities flow through 'trajectories' and there is a nice paper about it that you be interested in reading.

@abeham
Copy link
Member Author

abeham commented May 19, 2022

@sean-reed, thanks that looks interesting.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants