Modeling Machine Failure
This example shows how to model random failures and scheduled maintenance of a machine during regular operation. In the model, the machine can transition between three different states.
In the regular operation state, the machine acquires a worker and processes raw materials to produce finished products. In the planned maintenance state, the machine gets into a service mode, and after a fixed service time it returns to regular operation. The machine can also sporadically breakdown and enter a random failure state. The breakdown repair time is also random and the machine returns to regular operation after the repair is complete. During the planned maintenance and the random failure states the machine acquires a serviceman.
After fixing a sporadic machine failure, the following options are available to continue operation.
The operation resumes with the existing semi-processed material in the machine.
The operation resumes by discarding the semi-processed material as a waste and by taking the next raw material for processing.
Structure of the Model
The model contains the following major components.
Raw Material Source: Generates raw materials periodically to be sent to the storage.
Material Storage: Represents the storage space of the raw materials.
Maintenance Scheduler: Generates an entity to trigger a scheduled machine maintenance.
Machine: Models a machine which can receive entities from Maintenance Scheduler and transitions between regular operation, planned maintenance and random failure states.
Store: Represents the departure of all finished goods.
Worker pool: Represents the available worker resource for regular operation.
Serviceman Pool: Represents the available service man resource for scheduled maintenance and failure repair.
AnimateControl: Models the switch to turn the animation on or off.
Structure of the Machine Block
The Machine block contains two Discrete-Event chart blocks, namely 'breakdownGenerator' and 'operatingStates' along with the Resource Acquirer and the Resource Releaser blocks.
Breakdown Generator: Sends a message, 'breakdown', to indicate the breakdown of the machine and accepts a message, 'repairDone', that indicates the completion of the repair. Random 'breakdown' messages are generated from a gaussian distribution.
Operating States: Encapsulates three possible Machine block states which are 'breakdownAction', 'operationAction' and 'maintenanceAction'. On entering any of these states, the first action is to acquire the required resource and proceed with further actions.
Breakdown: When entering the 'breakdownAction' state, the machine requests a serviceman who performs the repair action. After the repair is complete, the machine releases any acquired resources, and prepares to exit the 'breakdownAction' state. The random time spent for a repair is generated from a gaussian distribution. If the machine breakdown interrupts any ongoing process, after the repair, the machine either terminates it to start a new process or resumes the interrupted process. If a scheduled maintenance overlaps with a breakdown repair time, additional time is taken to complete the maintenance.
Maintenance: When entering the 'maintenanceAction' state, the machine requests a serviceman who performs the service action. After the service is complete, the machine releases any acquired resources and exits the 'maintenanceAction' state. If a breakdown repair time overlaps with a service time, additional time is taken to repair the machine. In the event of a scheduled maintenance, the machine waits to complete any pending operations and only after their completion it enters the 'maintenanceAction' state.
Machine Operation: When entering the 'operationAction' state, the machine requests a worker before proceeding with its operation. Then the machine fetches raw materials and switches to the processing state. After the processing is complete in a fixed duration, the machine releases the finished product and switches back to an idle state during which it waits for raw material. If the operation state is interrupted by a breakdown event, you can specify the action of the machine to resume or to terminate the operation after the repair.
Processing Time: Time required to process the raw material to a finished product.
Maintenance Time: Time required to service the machine during periodic maintenance.
Mean time between failures (MTTF) : Average time between two consecutive breakdowns. Breakdowns are random events that are generated from a gaussian distribution.
Standard deviation in failure: Standard deviation of the gaussian distribution representing breakdowns.
Mean time to repair (MTTR): Average time to repair a machine in a breakdown state. Random repair time is generated from a gaussian distribution.
Standard deviation in repair: Standard deviation of the gaussian distribution representing the repair time.
Resume operation post repair: Checkbox to resume any pending operations in the machine after a breakdown. Otherwise, the materials are discarded and a new operation starts.
Enabling the toggle switch labelled 'AutomationControl' allows you to visualize the machine operations listed below.
Raw materials are transferred to the storage, sent to the machine's processing queue, and processed by the machine into a finished product.
Machine acquires a worker from the worker pool to operate. The worker is sent back to the pool during breakdown or maintenance.
Machine acquires a serviceman from the pool in the event of a breakdown or a maintenance. When the service or repair is complete, the serviceman is sent back to the pool.
The material is sent to the waste bin to be discarded.
The animation displays the quantity of the materials that are unloaded, in storage, wasted and processed.
The animation also displays the quantity of available workers and serviceman.