View
228
Download
3
Tags:
Embed Size (px)
Citation preview
Modeling Worldviews
• Event Scheduling – Event Graphs
State Machines
• Activity Scanning – Event Graphs
and Petri Nets
• Process Interaction – Event Graphs
and Block Diagrams
Resident Entities
Variables describe the state.
Focus on cycles. (busy-idle-busy...)
Transient Entities
Variables describe state and location.
Focus on flow paths.
System Entities
Block LanguagesProcess “World View”• Focus on Transient Entity Flow – “JOB DRIVEN”.
• Preprogrammed blocks of code.• Block execution is triggered by a
Transient Entity entering a block. • Execution Controlled by Job Moves.• Common Languages
Arena (Siman), AutoMod, GPSS, SLAM (AweSim)
Block LanguagesCommon Languages
SLAM SIMAN GPSS (fundamental Blocks)
Generate - Transactions enter modelQueue - Transactions wait for facilitySeize - Transactions take resourceDepart - Transactions leave queueAdvance - Transactions are delayedRelease - Transactions release resourceTerminate - Transactions leave the model
Block LanguagesCommon Languages
SLAM SIMAN (fundamental blocks)GPSS
Create - Entities enter modelQueue - Entities wait for facilitySeize - Entities take resourceDepart - Transactions leave queueDelay - Entities are delayedRelease - Entities release resource (Entities may leave using “Dispose” )
Single Queue
QUEUE
SEIZE
DEPART
ADVANCE
RELEASE
GENERATE
TERMINATE
1
1
1
1
GPSSSIMANCREATE
DELAY
RELEASE
1
QUEUE
SEIZE1
1
Main Event Scheduling Algorithm for Process Interaction
Cancel Events
Initialize
Advance Clock to Time of Next Event
Execute Event
Remove Event From Listand move “tokens” until blocked or delayed
State
Event List
Change State
Schedule Events
Summary StatisticsStop YesNo
Loading Unloading
Processing
Time
Labor Modeling “Machine Interference”
tool1
Oper.
tool2
Loading
Processing
Unloading
QUEUE
SEIZE
GENERATE
TERMINATE
1
1
SEIZE2
DEPART
Load
RELEASE
1
1
Cycle
RELEASE2
SEIZE1
RELEASE1
Unload
Semiautomatic Machine
Worker is Resource 1Machine is Resource 2
Single Queue with FailuresSIMAN
CREATE
DELAY
RELEASE
1
QUEUE
SEIZE1
1
CREATE
DELAY
RELEASE
1
QUEUE
SEIZE1
1
(Job Processing) (Failure Processing)
TTR
TBF
Proc. time
IA time
HIGH PRIORITY
JOB
Siman Blocks View (File/Template/Attach/Blocks)
This is what the Arena Processes viewgenerates..
Eventually you will need to understand this to use Arena
In a real problem...
Bank Queue with Jockeying
MACHINEMACHINE MACHINE MACHINE
TRANSFER SEGMENT
TOOL BANK TOOLBANK
TOOLBANK
TOOLBANK
TRANSFERSEGMENT 1
TRANSFERSEGMENT 2
TRANSFERSEGMENT 3
TRANSFERSEGMENT 4
TRANSFERSEGMENT 5
DIESEL ENGINE MANUFACTURING LINE MODEL(SIMAN IV)
WALKING CRANE
ONLINE BUFFER
OFFLINE BUFFER
• ; *****************************• ; * Mechanical Failures *• ; ***************************• CREATE;• ASSIGN: J = 0;• DUPLICATE:NumSegs-1; !create entity for each segment• ASSIGN: J = J + 1: !increment counter• SegNum = J; !set segment number• MechLoop DELAY: ED(MTBF(SegNum)); !delay for mean time btwn failures• QUEUE, MechFail1_Q; !wait for machine• SEIZE: Mach(SegNum); !seize machine• ASSIGN: MStat(SegNum) = 6: !segment status to mech fail• State = 0;• BRANCH,2: IF,TR_Policy.EQ.2.OR.TR_Policy.EQ.3,PM:• ALWAYS,M_Rep;• M_Rep ASSIGN: DTime = ED(MTR(SegNum)); !assign mean time to repair• TALLY: MechFail_1 + SegNum - 1, DTime;• DELAY: DTime; !delay for mean time to repair• BRANCH,1: IF,TR_Policy.EQ.2.OR.TR_Policy.EQ.3,PM_GetR:• ELSE,MF_Done;• MF_Done ASSIGN: MStat(SegNum) = 2; !segment status to starved• RELEASE: Mach(SegNum): !release machine• NEXT(MechLoop);
Block LanguagesProcess World View:+Transient Entity Focus Helps Animation+Easy to Use for Simple Applications-Limited to Pre-programmed blocks-Difficult to Model Complex Logic-Difficult to Model Resource Failure or (say, on
amount of time worked.)-Hard to Learn Well-Simulation Slows (or stops) as the System
Becomes Congested ! ! !
Block Languages
Why the simulation slows (or stops) as the system becomes congested.A record of each active transient entity
must be maintained during a run.e.g.: Process Flow in a semi-conductor
fabrication facility. A resident entity model will run hundreds
of times faster.
Block Languages
Resident Entity models are required to have practical simulations of any system with many active transient entities.e.g.
• Communications Networks• Large Scale Manufacturing Systems
and• Continuous Flow Processes
Screen Capture of ARENA Output: Svc Time = 1.85
Ref: Kim Branch and Jay Gillespie
Maximum of 100 Entities Exceeded! (Svc Time = 18.5)
What is the effect on Bias of ignoring runs that did not terminate correctly?
Resource/Job Driven Simulations
0
50
100
150
200
250
300
350
400
450
0 0.5 1 1.5
traffic intensity
tim
e p
er1
00
K j
ob
s
transient entity
resident entity
RunTime Ratios
24.6 25.5 27.9 29.4
100
60
45
30
0
20
40
60
80
100
120
0.10 0.20 0.90 0.95 0.99 1.11 1.25 1.43
Traffic Intensity
Ru
n T
ime
Ra
tio
(A
ren
a/S
igm
a)
Speed comparisons with Automod ASAP
M/M/1 System
100.0
150.0
200.0
250.0
300.0
350.0
400.0
40% 50% 60% 70% 80% 90% 100% 110%
CP
U T
ime
(S
eco
nd
s/1
,000
,00
0 U
nit
s)
RD DESJD NetworkJD DESASAP
6.0
8.0
10.0
12.0
14.0
16.0
18.0
40% 50% 60% 70% 80% 90% 100% 110%
Traffic Intensity
Little Slowdown from using PUT/GET
Runtimes, no queue capacity
0
500
1000
1500
2000
2500
3000
3500
0 200 400 600 800 1000
# servers
Ru
nti
me
in s
eco
nd
s
Arena RD
Arena JD
SIGMA RD
SIGMA JD
Using Activity Scanning to Develop Process Models
“Color” tokens that represent Transient Entities - - track these tokens’ paths.Parse Activities into “SEIZE”, “DELAY” and “RELEASE” Blocks.
SEIZE
DELAY
RELEASE
Idle Resources
Queue
Process -> EG Mapping
Process World View:Automated SLAM to Event Graphs
(Woodward and Mackulak, ASU)
Resource deadlock detection
SIMAN to Event Graphs (Barton and Gonzalez, PSU)
Premature run termination
Notes: 1. Model "footprint" is "number of servers" not "size of queue" - insensitive to congestion – complexity grows with resources!2. Q statistics are O.K. but what about Delays? - ambiguity of the mystery blocks - Use Little's Law or transient entity (PUT/GET) method.
(S>0) (Q>0)
TA
GEN
1QUEUE
DEPART
TS
SEIZE
RELEASE
yes
TERM
yes
TERM
1
1
1
Conventional EG Model
SEIZE Release
{Q=Q+1} {R=R-1,Q=Q-1}
{R=R+1}
(R>0)
(Q>0)
QUEUE
Ta
Ts
NOTE: Can change Distns.dat while model is running!
//CREATE block 1 - interval.5*TRI{.5}
//DELAY block 1 - duration
2*TRI{.5}
//DELAY block 2 -duration
2+3*BET{.5;.5}
Run (S[0],S[1])
Enter
{ I=(Q[0]>10), Q[I]++ }
Start(I)
Finish(I)
I~(Q[I])
tS
tA
{Q[I]--, S[I]--}
{ S[I]++ }
I
~
(S[I])