4  Data, Structure, and Logic

In this lab you will complete the remainder of the fourth phase of the HCCM framework, with your group. Again the goal is to give experience using the HCCM framework, and understand how to formulate the detailed components of a conceptual model. To get the lab signed off your group will need to complete the:

4.1 Define the Data

Firstly, you need to give detailed definitions of the data modules. You may not have collected data during car making, but complete the following table that describes the kind of data you would need to collect to simulate car making. Also add a comment on how the entry for CutTapeDuration would change if no person-by-person data was available, but an Exponential distribution that estimated the time it takes for a person to cut tape was available.

Table 4.1: List of Data Modules
Name Source Model Type Input Output
NumPencils System info Constant Deterministic - The number of pencils available
NumScissors System info Constant Deterministic - The number of scissors available
NumTape System info Constant Deterministic - The number of rolls of tape available
System info Constant Deterministic -
TraceCarDur Experimental data Lookup Deterministic Person Time to trace car
CutNetDur Experimental data Lookup Deterministic Person Time to cut the net out
CutTapeDur Experimental data Lookup Deterministic Person Time to cut a piece of tape

4.2 Define the Structure

The first part of the structure to define is the entities. Table 4.2 lists the entities again, but adds attributes that the entities will need to capture the performance of the system, e.g., waiting time until the cube was cut. It is assumed that all entities have the three attributes: ID, CurrentActivity, and CurrentStart. These are omitted in the table to prevent repetition.

Table 4.2: List of Entities
Entity Attributes
Paper WaitForTrace[0.0]
WaitForCutShape[0.0]
WaitForFold[0.0]
WaitForTapeCube[0.0]
Pencil WaitForTrace[0.0]
Scissors WaitForTask[0.0]
Tape WaitForCut[0.0]
TapePieces WaitForTape[0.0]
ArrivalTime[0.0]
LeavingTime[0.0]
Person WaitForTask[0.0]

The next part of the structure is the transitions, which describe how entities move between activities and events. Table 4.3 lists the transitions for making paper cars. These transitions are prefixed by entity of the behavioural pathway they come from. Complete the transitions for the Scissors pathway.

Table 4.3: List of Transitions
Participant Name From Event To Event
Paper P.1 Paper Created Paper Wait for Trace.Start
P.2 Paper Wait for Trace.End Trace Car.Start
P.3 Trace Car.End Paper Wait for Cut Net.Start
P.4 Paper Wait for Cut Net.End Cut Car Net.Start
P.5 Cut Car Net.End Paper Wait for Fold.Start
P.6 Paper Wait for Fold.End Fold Car.Start
P.7 Fold Car.End Paper Wait for Tape.Start
P.8 Paper Wait for Tape.End Tape Car.Start
P.9 Tape Car.End Car Finished
Pencil N.1 Pencil/Template Created Pencil Wait for Trace.Start
N.2 Pencil Wait for Trace.End Trace Car.Start
N.3 Trace Car.End Pencil Wait for Trace.Start
Scissors S.1 Scissors Created
S.2
S.3
S.4
S.5
Tape T.1 Tape Created Tape Wait for Cut.Start
T.2 Tape Wait for Cut.End Cut Tape.Start
T.3 Cut Tape.End Tape Wait for Cut.Start
Tape Piece TP.1 Tape Pieces Created Tape Pieces Wait for Tape.Start
TP.2 Tape Pieces Wait for Tape.End Tape Car.Start
TP.3 Tape Car.End Tape Pieces Leave
Person H.1 Person Created Person Wait for Task.Start
H.2 Person Wait for Task.End Trace Car.Start
H.3 Trace Car.End Person Wait for Task.Start
H.4 Person Wait for Task.End Cut Car Net.Start
H.5 Cut Car Net.End Person Wait for Task.Start
H.6 Person Wait for Task.End Fold Car.Start
H.7 Fold Car.End Person Wait for Task.Start
H.8 Person Wait for Task.End Cut Tape.Start
H.9 Cut Tape.End Person Wait for Task.Start
H.10 Person Wait for Task.End Tape Car.Start
H.11 Tape Car.End Person Wait for Task.Start

Table 4.4 lists the activities from the behavioural pathway diagrams along with the state changes for the start and end event of each activity. Complete the activities for:

  • Paper Wait for Tape Car
  • Tape Car
  • Person Wait for Task (Hint look at Scissors Wait for Task)
Table 4.4: Activities
Activity Participants Event Type State Change
Paper Wait for Trace Paper (P) Start Scheduled
(Default, omitted hereafter) P.CurrentActivity = "this activity"
(Default, omitted hereafter) P.CurrentStart = TIME
TRIGGER OnStartPaperWaitForTrace WITH C
End Controlled
P.WaitForTrace = TIME - P.CurrentStart
# TRANSITION P.2 in logic
Trace Car Paper (P), Person (H), Pencil (N) Start Controlled
SCHEDULE END at TIME + TraceCube(H)
End Scheduled
START Paper Wait for Cut Net WITH P # TRANSITION P.3
START Person Wait for Task WITH H # TRANSITION H.3
START Pencil Wait for Trace WITH N # TRANSITION N.3
Paper Wait for Cut Net Start
TRIGGER OnStartPaperWaitForCutNet WITH P
End
P.WaitForCutNet = TIME - P.CurrentStart
# TRANSITION P.4 in logic
Cut Car Net Paper (P), Person (H), Scissors (S) Start Controlled
SCHEDULE END at TIME + CutNet(H)
End Scheduled
START Paper Wait for Fold WITH P # TRANSITION P.5
START Person Wait for Task WITH H # TRANSITION H.5
START Scissors Wait for Task WITH S # TRANSITION S.3
Paper Wait for Fold Paper (P) Start Scheduled
TRIGGER OnStartPaperWaitForFold WITH P
End Controlled
P.WaitForFold = TIME - P.CurrentStart
# TRANSITION P.6 in logic
Fold Car Paper (P), Person (H) Start Controlled
SCHEDULE END at TIME + FoldCar(H)
End Scheduled
START Paper Wait for Tape Car WITH P # TRANSITION P.7
START Person Wait for Task WITH H # TRANSITION H.7
Paper Wait for Tape Car Start
 
End
 
 
Tape Car Start
 
End
 
 
 
Pencil Wait for Trace Pencil (N) Start Scheduled
TRIGGER OnStartPencilWaitForTrace WITH N
End Controlled
N.WaitForTrace = N.WaitForTrace + TIME - N.CurrentStart
# TRANSITION N.2 in logic
Scissors Wait for Task Scissors (S) Start Scheduled
TRIGGER OnStartScissorsWaitForTask WITH S
End Controlled
S.WaitForTask = S.WaitForTask + TIME - S.CurrentStart
# TRANSITION S.2 or S.4 in logic
Cut Tape Tape (T), Person (H), Scissors (S) Start Controlled
SCHEDULE END at TIME + CutTape(H)
End Scheduled
START Person Wait for Task WITH H # TRANSITION H.9
START Scissors Wait for Task WITH S # TRANSITION S.5
START Tape Wait for Cut WITH T # TRANSITION T.3
CREATE Tape Pieces TP
START Tape Pieces Created WITH TP
Tape Wait for Cut Tape (T) Start Scheduled
TRIGGER OnStartTapeWaitForCut WITH T
End Controlled
T.WaitForCut = T.WaitForCut + TIME - T.CurrentStart
# TRANSITION T.2 in logic
Tape Pieces Wait for Tape Tape Pieces (TP) Start Scheduled
TRIGGER OnStartTapePiecesWaitForTape WITH TP
End Controlled
TP.WaitForTape = TP.WaitForTape + TIME - TP.CurrentStart
# TRANSITION TP.2 in logic
Person Wait for Task Start
 
End
 
 

Table 4.5 lists the events to start and finish the simulation along with the events from the behavioural pathway diagrams along with the state changes for each event. Complete the events for:

  • Tape Pieces Created
  • Person Created
Table 4.5: Events
Event Participants Type State Change
Simulation Start None Scheduled
FOR NumPaper DO
  CREATE Paper P
  START Paper Created WITH P
END FOR
FOR NumPencils DO
  CREATE Pencil N
  START Pencil/Template Created WITH N
END FOR
FOR NumScissors DO
  CREATE Scissors S
  START Scissors Created WITH S
END FOR
FOR NumTape DO
  CREATE Tape T
  START Tape Created WITH T
END FOR
FOR NumPeople DO
  CREATE Person H
  START Person Created WITH H
END FOR
Paper Created Paper (P) Scheduled
START Paper Wait for Trace WITH P # TRANSITION P.1
Car Finished Paper (P) Scheduled
Calculate statistics for P
REMOVE Paper P
Pencil/ Template Created Pencil (N) Scheduled
START Pencil Wait for Trace WITH N # TRANSITION N.1
Scissors Created Scissors (S) Scheduled
START Scissors Wait for Task WITH S # TRANSITION S.1
Tape Created Tape (T) Scheduled
START Tape Wait for Cut WITH T # TRANSITION T.1
Tape Pieces Created
  
Tape Pieces Leave Tape Pieces (TP) Scheduled
Calculate statistics for TP
REMOVE Tape Pieces TP
Person Created
 
Simulation Finish None Scheduled
Calculate statistics as required for Pencils, Scissors, Tape, Person entities

4.3 Define the Logic

The last part of the structure to define is the logic. You need to define the logic for each of the triggers (the red squares in the behavioural paths, and TRIGGER statements in the state changes). Tables 4.6, to 4.14 show the logic for some of the triggers. Complete the logic for: - OnStartTapeWaitForCut - OnStartCubeWaitForFold - the last condition of OnStartPersonWaitForTask

Table 4.6: OnStartPencilWaitForTrace
Triggered by: Pencil N
IF (any Paper P with P.CurrentActivity = Paper Wait for Trace) AND
   (any Person H with H.CurrentActivity = Person Wait for Task) THEN
  SELECT valid Paper P
  SELECT valid Person H
  START Trace Car WITH P, H, N
END IF
Table 4.7: OnStartScissorsWaitForTask
Triggered by: Scissors S
IF (any Paper P with P.CurrentActivity = Paper Wait for Cut Net) AND
   (any Person H with H.CurrentActivity = Person Wait for Task) THEN
  SELECT valid Paper P
  SELECT valid Person H
  START Cut Net WITH P, H, S
ELSE IF (any Tape T with T.CurrentActivity = Tape Wait for Cut) AND
        (any Person H with H.CurrentActivity = Person Wait for Task) THEN
  SELECT valid Tape T
  SELECT valid Person H
  START Cut Tape WITH T, H, S
END IF
Table 4.8: OnStartTapeWaitForCut
Triggered by: Tape T
 
 
 
 
 
 
Table 4.9: OnStartTapePiecesWaitForTape
Triggered by: Tape Pieces TP
IF (any Paper P with P.CurrentActivity = Paper Wait for Tape) AND
   (any Person H with H.CurrentActivity = Person Wait for Task) THEN
  SELECT valid Paper P
  SELECT valid Person H
  START Tape Car WITH P, H, TP
END IF
Table 4.10: OnStartPaperWaitForTrace
Triggered by: Paper P
IF (any Pencil N with N.CurrentActivity = Pencil Wait for Trace) AND
   (any Person H with H.CurrentActivity = Person Wait for Task) THEN
  SELECT valid Pencil N
  SELECT valid Person H
  START Trace Car WITH P, H, N
END IF
Table 4.11: OnStartPaperWaitForCut
Triggered by: Paper P
IF (any Scissors S with S.CurrentActivity = Scissors Wait for Task) AND
   (any Person H with H.CurrentActivity = Person Wait for Task) THEN
  SELECT valid Paper P
  SELECT valid Person H
  START Cut Car WITH P, H, S
END IF
Table 4.12: OnStartPaperWaitForFold
Triggered by: Paper P
 
 
 
 
Table 4.13: OnStartPaperWaitForTape
Triggered by: Paper P
IF (any Tape Pieces TP with TP.CurrentActivity = Tape Pieces Wait for Tape) AND
   (any Person H with H.CurrentActivity = Person Wait for Task) THEN
  SELECT valid Tape Pieces TP
  SELECT valid Person H
  START Tape Car WITH P, H, TP
END IF
Table 4.14: OnStartPersonWaitForTask
Triggered by: Person H
# Prioritise taping, then folding, then cutting, then tracing
IF (any Paper P with P.CurrentActivity = Paper Wait for Tape Car) AND
   (any Tape Pieces with TP.CurrentActivity = Tape Pieces Wait for Tape) THEN
  SELECT valid Paper P
  SELECT valid Tape Pieces TP
  START Tape Car WITH P, H, TP
ELSE IF (any Paper P with P.CurrentActivity = Paper Wait for Tape Car) AND
        (any Tape T with T.CurrentActivity = Tape Wait for Cut) AND
        (any Scissors S with S.CurrentActivity = Scissors Wait for Task) THEN
  # There is a car waiting to be taped, but no tape pieces
  SELECT valid Tape T
  SELECT valid Scissors S
  START Cut Tape WITH T, H, S
ELSE IF (any Paper P with P.CurrentActivity = Paper Wait for Fold)
  SELECT valid Paper P
  START Fold Car WITH P, H
ELSE IF (any Paper P with P.CurrentActivity = Paper Wait for Cut Net) AND
        (any Scissors with S.CurrentActivity = Scissors Wait for Task) THEN
  SELECT valid Paper P
  SELECT valid Scissors S
  START Cut Car Net WITH P, H, S
 
 
 
 
 
END IF

4.4 Assumptions and Simplifications

What assumptions did you make when defining your model? What simplifications did you make? These details are important when communicating your model to others. List them in the box below. Remember, assumptions are beliefs about the system that we take to be true, and inform part of the model. Assumptions enable us to resolve uncertainties about the actual system. We use assumptions complete parts of the model that we do not have the information about. Simplifications are intentional changes to the model that make it different from the system being modelled. Simplifications are usually used to replace a complex part (or parts) with a simpler one, that is either more easily: defined in the conceptual model; implemented in the simulation; or communicated.

 

 

 

 

 

 

 

 

You have now completed the conceptual model of the cube making activity and you could use this model as the staring point for implementing a simulation model in JaamSim using the HCCM library. Show your work to a lab tutor to get it signed off.