Краткое практическое руководство по GPSS



             

Обозначения для транзактов - часть 2


Этот транзакт вносится в модель через цепь будущих событий с помощью процедуры, которая будет описана ниже. И наоборот, когда возникает необходимость удалить соответствующий транзакт, его убирают из модели и помещают обратно в вершину пассивного буфера. Перемещение транзактов между пассивным и активным буферами показано на рис.13.3. Номера блоков присваиваются в том порядке, в котором стоят карты блоков в колоде. Например, на рис.13.5 представлено повторение распечатки программы рис.13.4 с номерами блоков, присвоенными интерпретатором. Номера блоков стоят в левой колонке.

Рис.13.4. Пример моделирования 2A. Модель и распечатка программы:
а -заполненный бланк для перфорации модели;
б - распечатка программы для модели, представленной в части а.

На бланке показаны поля имени (LOCATION),операции (OPERATION) и операндов (помечено символами А,В, С,D,Е,F,G). На распечатке поле имени отмечено символами * LOC.

а)

LOCATION&nbspOPERATIONA,B,C,D,E,F ------------------------>
1234567891 01 11 21 31 41 51 61 71 81 92 02 12 22 32 42 52 62 72 82 93 03 13 23 33 43 53 63 73 83 94 04 14 24 34 44 54 6
&nbsp&nbsp&nbsp&nbsp&nbspSIMULATE&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp
*&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp
*&nbsp&nbsp&nbsp&nbspMODEL&nbspSEGMENT&nbsp1&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp
*&nbsp&nbsp&nbsp&nbspGENERATE&nbsp18,6&nbspПРИХОД&nbspКЛИЕНТОВ&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp
&nbsp&nbsp&nbsp&nbsp&nbspQUEUE&nbsp&nbsp&nbsp&nbspJOEQ&nbspПРИСОЕДИНЕНИЕ&nbspК&nbspОЧЕРЕДИ&nbsp&nbsp&nbsp&nbsp
&nbsp&nbsp&nbsp&nbsp&nbspSEIZE&nbsp&nbsp&nbsp&nbspJOE&nbsp&nbspПРИХОД&nbspВ&nbspКРЕСЛО&nbspПАРИКМАХЕРА
&nbsp&nbsp&nbsp&nbsp&nbspDEPART&nbsp&nbsp&nbspJOEQ&nbspУХОД&nbspИЗ&nbspОЧЕРЕДИ&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp
&nbsp&nbsp&nbsp&nbsp&nbspADVANCE&nbsp&nbsp16,4&nbspОБСЛУЖИВАНИЕ&nbspУ&nbspПАРИКМАХЕРА&nbsp
&nbsp&nbsp&nbsp&nbsp&nbspRELEASE&nbsp&nbspJOE&nbsp&nbspОСВОБОЖДЕНИЕ&nbspПАРИКМАХЕРА&nbsp&nbsp&nbsp
&nbsp&nbsp&nbsp&nbsp&nbspTERMINATE&nbsp&nbsp&nbsp&nbsp&nbspУХОД&nbspИЗ&nbspПАРИКМАХЕРСКОЙ&nbsp&nbsp&nbsp&nbsp&nbsp
*&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&n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bsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp
*&nbsp&nbsp&nbsp&nbspCONTROL&nbspCARDS&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp
*&nbsp&nbsp&nbsp&nbspSTART&nbsp1&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp
&nbsp&nbsp&nbsp&nbsp&nbspEND&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp

б)

BLOCK NUMBER *LOG OPERATION A,B,C,D,E,F,G COMMENTS SIMULATE * * MODEL SEGMENT 2 * 1 GENERATE 460 TIMER ARRIVES AT TIME 460 2 TERMINATE 1 SMUT OFF THE RUN * * MODEL SEGMENT 1 * 3 GENERATE 16,6 CUSTOMERS ARRIVE 4 QUEUE JOEQ ENTER THE LINE 5 SEIZE JOE CAPTURE THE BARBER 6 DEPART JOEQ LEAVE THE LINE 7 ADVANCE 16,4 USE THE BARBER 8 RELEASE JOE FREE THE BARBER 9 TERMINATE LEAVE THE SHOP * * CONTROL CARDS * START 1 START THE RUN END RETURN CONTROL TO OPERATING SYSTEM

Рис 13.5. Повторение рис. 13.4

BLOCK NUMBER *LOC OPERATION A,B,C,D,E,F,G COMMENTS SIMULATE * * MODEL SEGMENT 1 * 1 GENERATE 18,6 CUSTOMERS ARRIVE 2 QUEUE JOEQ ENTERTHE LINE 3 SEIZE JOE CAPTURE THE BARBER 4 DEPERT JOEQ LEAVE THE LINE 5 ADVANCE 16,4 USE THE BARBER 6 RELEASE JOE FREE THE BARBER 7 TERMINATE LEAVE THE SHOP * * MODEL SEGMENT 2 * 8 GENERATE 480 TIME ARRIVES AT TIME 480 9 TERMINATE 1 SHUT OFF THE RUN * * CONTROL CARDS * START 1 SRART THE RUN END RETURN CONTROL TO OPERATING SYSTEM



Содержание  Назад  Вперед