Data Collector Monitoring Functions

Data Collector Monitoring Functions

Each one of the Data collector monitors has the following monitoring functions: Initialization function is called once before a simulation starts. It returns an optional numerical value (see below for more information about optional values). If the function returns NONE then nothing will happen. If the function returns a value of the form SOME x where x is a number, then x will be used […]

Read Me Leave comment

Create a monitor

Create a monitor

The Monitoring tools:start are used to create monitors. Each tool cell in the Monitoring tool palette creates a different kind of monitor; see the Palette tools page if you are unsure about how to work with palettes. To create a monitor, select the desired kind of monitor, e.g. a write-in-file monitor, and apply the tool to the subnet to be monitored. Some monitors can only […]

Read Me Leave comment

Breakpoint monitoring functions

Breakpoint monitoring functions

Each one of the breakpoint monitors has two monitoring functions: a predicate function and an action function. The predicate function is called after simulation steps. When the predicate function returns true, the action function will set a flag in the simulator to indicate that a simulation breakpoint – that is, a simulation stop criterion – has been fulfilled. Accessibility of the monitoring functions for the […]

Read Me Leave comment

Monitor template code

Monitor template code

All monitors contain monitoring functions. Some of the monitoring functions are hidden from the user, while other monitoring functions are accessible for the user. If a monitoring function is accessible for a user, then the function can also be modified by the user. A user is never required to write a monitoring function from scratch, because it is always possible to generate template code for […]

Read Me Leave comment

Monitoring functions

Monitoring functions

Each monitor has a number of different functions that are used for different purposes. Some examples of functions for monitors are: predicate function for checking if the relevant condition is fulfilled observation function for extracting information from the net action function for doing something relevant with the extracted data initialization function for initializing a monitor before a simulation starts stop function for concluding a monitor […]

Read Me Leave comment

Breakpoint monitors

Breakpoint monitors

Breakpoint monitors are used to stop simulations when certain conditions are fulfilled. There are three breakpoint monitors: Place contents monitors, Transition enabled monitors, and Generic breakpoint monitors. Examples of breakpoint monitors can be found in the Queue System. Place contents monitors A place contents monitor checks the number of tokens on a place to determine if a simulation should be stopped. The simulation can be […]

Read Me Leave comment

Monitors

Monitors

What is a monitor? When simulating CP-nets, it is often useful to be able to examine the markings and occurring binding elements, to periodically extract information from the markings and binding elements, and then to use the information for different purposes, such as: Stopping a simulation when a particular place is empty Counting the number of times a transition occurs Updating a file when a […]

Read Me Leave comment