18.10.2014 Views

SIMSCRIPT II.5 Programming Language

SIMSCRIPT II.5 Programming Language

SIMSCRIPT II.5 Programming Language

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Discrete Simulation Concepts<br />

1 process JOB<br />

2 define TASK, REQUIRED as integer variables<br />

3<br />

4 until ROUTING.SET is empty<br />

5 do<br />

6 remove the first TASK from the ROUTING.SET<br />

7 request 1 units of PRODUCTION.CENTER(TASK.DOER(TASK))<br />

8 work TASK.DURATION.. HOURS<br />

9 relinquish 1 units of PRODCUTION.CENTER(TASK.DOER(TASK))<br />

10 destroy the TASK<br />

11 loop<br />

12<br />

13 let CYCLE.TIME = TIME.V - ARRIVAL.TIME<br />

14<br />

15 end<br />

This process models the complete life cycle of a job through the shop.<br />

UNTIL<br />

REMOVE<br />

REQUEST<br />

WORK<br />

RELINQUISH<br />

DESTROY<br />

LOOP<br />

Processing of this JOB is to continue until its ROUTING.SET is empty.<br />

The first TASK in the set is removed for processing.<br />

A MACHINE of type indicated by TASK.DOER is requested.<br />

Execution of the requesting JOB process is suspended, if necessary, until a<br />

MACHINE becomes available. While a particular JOB process is suspended,<br />

other processes, including other instances of JOB process, will run using other<br />

machines.<br />

As no priorities are specified, a first-in-first-out discipline is provided whenever<br />

more than one suspended process is waiting for the same type of resource.<br />

Work on this JOB continues only when its MACHINE becomes available.<br />

The JOB delays itself for a set time to model actual processing by a MACHINE.<br />

The MACHINE is made available for other jobs.<br />

Since this operation is complete, the TASK entity is destroyed.<br />

Mark end of UNTIL loop.<br />

Numeric results are gathered “on the fly” by accumulate and tally statements contained in<br />

the Preamble. The final computation, is the total time, including delays, that it took to process<br />

this job.<br />

243

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!