Peter Lorenz German smaller fonts Simulation und Animation

S&A Program and Model Examples

GPSS/H as a Programming Language
1. Introduction
2. Proof Animation
Bubbles Animation Trace File (ATF) Generation using GPSS/H Time/Create/Place/Move/Rotate
3.
3.1. Constants and Amper Variables
Arrays and indexed Ampervariables Value assigments and index expressionsINTEGER
LET
Faculty calculation Value assigment in cycles DO/ENDDO
Distance between two points Value assigments to REAL-Ampervariables REAL
LET
SQRT
3.2. Expressions
Substring-Function SSG-Demonstration CHAR*n/VCHAR*n/SSG
Length of a string
LEN-DemonstrationLEN
SSG
Symbols for numbers of instancesSYM-DemonstrationDO/ENDDO
FILEDEF
SYM
3.3. Commands
Controlling the compiler protocol LIST/UNLIST-DemonstrationLIST/UNLIST
LET
VCHAR*n
User controlled assignment of instance names to numbers EQU-DemonstrationEQU
Cycles and Branches DO- and IF-Demonstration DO/ENDDO
IF/ELSE/ENDIF
3.4. In- and Output
Value Tables for functions Formatting a result table PUTPIC
DO/ENDDO
Edit fields and values Too short and too long edit fieldsPUTPIC
FILEDEF-Demonstration ATF-file-creation PUTPIC
PUTSTRING
I/O-list demonstration Cycles in a I/O-list PUTPIC
3.5. Standard Attributes
Value Table of mathematical functions SNA for mathematical functions SIN(&X)/COS(&X)
TAN(&X)/EXP(&X)
LOG(&X)/SQRT(&X)
Date and time in a German format String processing CURTIME
CURDATE
SYM and ENTNUMSymbolic names and numbers of objectsEQU
SYM/ ENTNUM
3.6. Functions
Value tables for functions of different types Functions of types C and D FUNCTION
Customer groups Discrete probability distribution FUNCTION
PICTURE
Function without arguments Numeric list functions DO/ENDDO
PICTURE
FUNCTION
Standard Attributes as function values Discrete attributed function FUNCTION
PUTSTRING
Expressions as function values Attributed list functions FUNCTION
PICTURE
FN
Dynamic name-number-assignment Object functions or functions of type S FUNCTION
INITIAL
3.7. Variables
Integer arithmetical expressions Integer Variables VARIABLE
Real arithmetical expressions Real-Variables or FVARIABLE FVARIABLE
3.8. Random numbers
Two random number streams with neighbouring start indices Start indices and value sequences RMULT
Antithetic Random number streams RMULT with negative operand RMULT
Integer and standard random number streams Random number streams from RN1 and FRN1 RN/ FRN
Exponentially and normally distributed random numbers Transformation by SNA RVEXPO
RVNORM
100 random numbers with a discrete empiric distribution Function with the argument FRN1 FUNCTION
Randomizing the Starting Value Using the current time RMULT, CURTIME
3.9. Graphical Representation of Data
Histograms for uniform and normal distribution Userdefined graphical outputREPORT/GRAPH
ORIGIN/X/Y
ENDGRAPH
Histograms for uniform and normal distributionOutput in EXCEL-compliant table format PUTPIC
Historgrams for uniform and normal distributionOutput of a LightLib specification for result presentation on the WebPUTPIC
4. GPSS/H-Queueing Models
4.1. Transactions and Facilities
Joe's BarbershopSingle-channel queueing systemGENERATE/TERMINATE
SEIZE/RELEASE
ADVANCE
Standard output of Transactions Operands of STARTSTART
Joe and Jim Parallel queueing channelsGENERATE/TERMINATE
SEIZE/RELEASE
ADVANCE
Single Server with Animation AnimationstracefileBPUTPIC
4.2. Blocks, Control statements and Compiler directives
Blocks and Control Statements Execution orderRESET/CLEAR
START
Single-Server with TRACE TRACE-protocolTRACE/UNTRACE
4.3. Queues and Storages
Barbershop with two Queues Waiting time statisticQUEUE/DEPART
Salon with two barbers Storages STORAGE
ENTER/LEAVE
Salon with lunch break and closing hour Availibility of StoragesSUNAVAIL/SAVAIL
4.4. Logical Switches and Branches
Pedestrian traffic lights Logical SwitchesLOGIC/ GATE
Tanker blocks petrol station Waiting for a logical stateGATE
Impatient customersBreak- and closing time control
Conditional branches
GATE
SAVAIL/SUNAVAIL
Closing Hour Waiting for an arithmetical conditionTEST
BVARIABLE
Coal Transfer Port Separation of Storage loading and unloadingENTER/LEAVE
TEST
Two arrival streams Unconditional branch for TransactionsTRANSFER
Branches with specified probability TRANSFER with probabilityTRANSFER .p
Orders in a workplace Selecting one of two destinationsTRANSFER BOTH
4.5. Attributes of Transactions
Numerical Standard attributes of TransactionsNumber, Transit Time, Priority, ParametersXID1/M1/PR/PHj
Providing Transactions with parametersXacts with different parameter setsGENERATE/nPF,...
Value assignments for parametersASSIGN-Block for Parameter valuesASSIGN
Hotel barberCustomers with priorityGENERATE
BarbershopTransit time measurementMARK/M1/MP
SupermarketAttributes of TransactionsASSIGN
TABLE/TABULATE
4.6. Searching, Counting and Classifying
Frequency table for random numbers Use of TablesTABLE/TABULATE
Barbershop with time recordingFrequency table for transit timesTABLE/TABULATE
5. Internal Control Concepts of GPSS/H
5.1. GPSS/H Macros and Subroutines
Traffic crossroadsMacro definition and callMACRO/STARTMACRO/ENDMACRO
ATF generationRecursive Macro definitionMACRO/STARTMACRO/ENDMACRO
ATF Macro collectionMacro definition and callMACRO/STARTMACRO/ENDMACRO
Two JobstreamsSBR-branches and MacrosTRANSFER SBR, STARTMACRO, ...
5.2. Internal Control of GPSS/H
GENERATE-Blocking #1Scanphase Case A1 
GENERATE-Blocking #2Scanphase Case A2 
GENERATE-Blocking #3Scanphase Case B1 
5.3. Preemption and Assembly Sets
Priority WaitingPriority in the CECQUEUE, SEIZE
Emergency Room 1Simple PREEMPTPREEMPT, RETURN
Emergency Room 2Extended PREEMPTPREEMPT, RETURN
Night watchman with telephoneProcess control with PREEMPTPREEMPT, RETURN
Single-Server with User-ChainWaiting in User-Chain PREEMPTLINK, UNLINK
Sorting random numbersSorting with LINK/ UNLINKLINK, UNLINK
Women supportSelecting with UNLINKLINK, UNLINK
Car purchaseSelecting with UNLINKLINK, UNLINK
5.4. User-Chains and Groups
Numbered copiesNumbering with SPLITSPLIT
BaggageCollecting baggage ASSEMBLESPLIT, ASSEMBLE
Trains waiting for each otherSynchronizing with MATCHJOIN, MATCH
7 from 49Drawing lots without repeats with EXAMINE JOIN, EXAMINE
Magdeburg Taxisnotify of destination with ALTERJOIN, ALTER
RestaurantRestaurant operation with Groups JOIN, REMOVE, ALTER, SCAN
Taxis in Manhattan Working with Groups, User-Chains and Animation Macros
5.5. Model Experiments and Output Analysis

Download

SAHome previous next up Germansmaller fonts Top Line
Last Modified Fri 03-04-05 12:32 GMT Valid CSS!
English Translation:S. Osterburg

Comments please to:pelosim@yahoo.com