Instructor Led Training

Download Report

Transcript Instructor Led Training

Instructor Led Training - Instruction Plan
THIS COURSE MATERIAL IS NOT INTENDED TO BE SELF TEACH SUFFICIENT.
The course is organized into four sections.
I. Kickoff

Introductions, Agenda, and Expectation setting.
II. Product information


Presentation material for discussion of the training in context of the DELMIA solutions.
This material is repurposed from Smart Training or Developer presentations to offer the instructor an
opportunity to discuss the training and the software as it applies to the audience interests.
III. Course Material



The course is organized into modules that follow a process flow similar to the manner in which a new
user would interact with the software to accomplish a project.
Each Module has an Overview with objectives, a reference of the workbenches and
toolbars used in the Module and series of Process Steps that are organized to
accomplish the goal of the module. In presenting the overview of the module,
the instructor has the opportunity to discuss the use, benefits, and best
practices of the software.
Each Process Step begins with an “About” screen that permits the instructor to
speak to an overview of that part of the process. This introductory area is
intended to offer the instructor and participant an opportunity to discuss “why”
the software is being used in this manner and other industry relevant topics.
After the “About” discussion occurs, there are procedures detailing the key
functionalities that are necessary to accomplish this element of the Process
Step. The key functionalities are presented in a generic manner but may contain
an example for clarification. Because the accomplishment of a Process Step is
the focal point of the instruction, not every aspect of a functionality is detailed
here. It is intended for the instructor to speak to and/or demonstrate these
functionalities.
At relevant points within the module, exercises will be offered to the participant for practice of the key
functionalities.
At the end of the course, an Independent Project has been included for additional, less directed, practice.
This data set is identified in the training data given to the Instructor as “Independent Practice Data”.
IV. Wrap Up

Course summary, Support and PSO information and evaluations.
1
Instructor Led Training - Instruction Plan
Project Data is included with the Instructor Information.
Student Material folder contains the powerpoint presentation material for each module
Project Data folder contains folders with the data for the exercises







Catalog – contains a pre-built catalog that will serve as back up if the participant has difficulty creating
their own.
Part – contains the parts, tools, and equipment that may not be contained in the software libraries.
Product – contains product data for the exercises
Process – contains the files of each completed exercise that will serve as back up if the participant has
difficulty creating their own.
Resource – contains resources call upon by the exercises if not obtained from a catalog or library.
Reports – contains reports called for by the exercises
Independent Project Data – contains the data set for the independent project
Hardware and Software Specifications
This educational material was developed for the configuration AP2 at R15 sp1. It can be
used for PPR AP2, AG2 and AX2 but does not address those specific differences.
Module 7 Tool Validation calls upon the MHMC-SB Human Modeling Complete license.
It is recommended that this training be conducted on:









Pentium IV, min. 2400 MHz, Min. 512 MBytes Memory ( 1024 Mbytes to install Client, Server and the ORACLE server on the
same machine )
Windows 2000, Windows XP (SP2 only with various security settings disabled; please have a look into the DCOM manual)
5 Gbyte diskspace for E5 server application and Oracle database, optionally more disk space for 3D graphic files or others (.cgr,
.jt, ...)
Graphical interface (1024x768, OpenGL, min. 32Mb onboard memory)
Microsoft IE6 (ERGOCheck)
LAN Interface (completely configured)
TCP/IP
The PC has to have an IP address, either a static one or via DHCP)
JRE 1.3.1.08 installed ( Windows XP: The environment variable JAVA_HOME has to be set on the server if you want to
accomplish communication between E5 server and V5 clients. )
2
Education Services
Instructor Presentation
Advanced QUEST
Version 5 Release 16
3
START !
Introductions
Sign the Roster (Make sure we can spell your name correctly)
Expectations
4
PPR QUEST
Objectives of the course
You will be able to:
Program in SCL & BCL
Conduct Experimentation & Optimization for a simulated model
Create AVI, MPEG & tiff videos for a simulation & also capture images & create postscripts.
Create Sub Models & Groups.
Create Fluids, Trains and Tools & Fixtures
Targeted audience
Simulation Engineers
Mechanical and Industrial Engineers
Prerequisites
You should have QUEST and DELMIA Process Engineer of the same release
installed on your computer.
2 days
5
Agenda
Day 1
Approximate time
 Kick Off
1 hr
Introductions
Expectations
 Product Information
1 hr
QUEST
 Course Presentation
Module 1 Advanced SCL, BCL and Popups




3 hr
Programming in SCL
Creating SCL & BCL macros
SCL Debugging
Creating Popups
Module 2 Experimentation and Optimization
3 hr
 Defining Control Variables
 Conducting Optimization
 Conducting Experimentation
6
Agenda
Day 2
Approximate time
Module 3 QUEST Graphical Outputs
2 hr
 Creating Videos
 Creating Images and Hardcopies
Module 4 Hierarchical Modeling
3 hr
 Creating Sub Models
 Creating Groups
Module 5 Trains, Fluids and Tools & Fixtures
3 hr
 Creating Fluid Model
 Modeling Trains
 Modeling Tools & Fixtures
7
Agenda
Day 3
Approximate time
Module 6 Final Assembly Model & Pull Modeling
4 hr
 Modeling Final Assembly Model
 Modeling Pull System
Module 7 Wrap Up
1hr
Q&A
Evaluations
8
Advanced QUEST
&
Product Information
9
QUEST
Product
Information
The QUEST product family is DELMIA’s Factory Flow Simulation
solution. QUEST provides a collaborative environment for industrial
engineers, manufacturing engineers, and management to develop
and prove out best manufacturing flow practices throughout the
production design process. QUEST is an object-based, discrete
event simulation environment, where engineers evaluate the
dynamic behavior of their manufacturing process and flow designs.
Whether the facility design is new or existing, the effects of change
can be collected and analyzed in a cost-effective manner.
The DELMIA – QUEST Advanced provides a flexible, object-based,
discrete event simulation environment combined with powerful
visualization and robust import/export capabilities that make it the
engineering and management solution for process flow simulation
and analysis.
Some of the Features and Functionalities available in QUEST Advanced
(in addition to base QUEST) are:
• The OptQUEST functionality provides quick optimization functions.
• XML and HTML outputs of simulation results for customization.
• Includes Unigraphics and DXF Translators, CATIA Direct and VRML 2.0.
10
Expe
r
t
Master
Specialist
Advanced QUEST Specialist
Course Material
11
Introduction to Advanced QUEST- Specialist Course
This specialist course in Advanced QUEST describes the behaviour of the model
relying on defined events being governed by different states. This is created by
managing elements that run standard logic files simultaneously. The reader should
have a basic knowledge in QUEST.
This course will permit the learner to have an applied, consistent experience while
learning the advanced feature of the software. However, in the interests of maintaining
the project focus, not every feature and function available in QUEST will be used or
addressed. It is suggested that the user access the online documentation that comes
with the software installation to further explore additional functionality.
The exercises at the end of each section will provide you with a better understanding
of the concepts needed to build a project QUEST.
12
Advanced QUEST Course Process Flow
1
Advanced
QUEST
Programming
2
Programming in SCL & BCL
Creating SCL & BCL macros
SCL Debugging
Creating Popups
Trains, Fluids and
Tools & Fixtures
5
Creating Fluid Model
Modeling Trains
Modeling Tools & Fixtures
6
4
Hierarchical
Model
Building Sub Models
Creating Groups
Experimentation
& Optimization
Defining Control Variables
Conducting Optimization
Conducting Experimentation
3
QUEST Graphical
Outputs
Creating Videos
Capturing Images and Hardcopies
Final Assembly
Model & Pull Model
Modeling Final Assembly Model
Modeling Pull System
13
1
Advanced
QUEST
Programming
2
Optimization &
Experimentation
3
5
6
Trains, Fluids and
Tools & Fixtures
4
QUEST
Graphical
Outputs
Hierarchical
Model
Final Assembly
Model & Pull Model
Module 1
Advanced QUEST
Programming
14
1
Introduction
Overview
This is an advanced module on Simulation Control Language (SCL) and
Batch Control Language (BCL) and provides details on popups. It is
assumed that you are now familiar with the basics of the QUEST user
interface, concept of elements, class, and parts, and have a basic
knowledge of SCL.
This module contains explanation for many of the concepts presented
in the following module of the Advanced QUEST course material.
Objectives
Topics in this module are:
Programming in SCL &BCL
Creating SCL & BCL macros
SCL Debugging
Creating Popups
3 hours
15
Menus and Action Buttons used in this Module
16
1
Advanced QUEST Programming
Programming
in SCL & BCL
About Procedures
About Routines
About Statements
About Data Constructs
Creating SCL File
Implementing BCL Commands
Creating SCL &
BCL Macros
Creating SCL Macros
Creating BCL Macros
SCL
Debugging
Creating Popups
Creating Popups
Defining Options to Popups
Linking Popups to Element Class
Debugging SCL File
Setting Break Point to Line
Setting Break Point to Variable
Setting Break Point Attributes
Modifying Break Point
3 hours
17
A
Programming
in SCL & BCL
About Procedures
About Routines
About Statements
About Data Constructs
Creating SCL File
Implementing BCL Commands
18
1
Advanced QUEST Programming
Programming
in SCL &BCL
About Programming in SCL & BCL
Simulation Control Language (SCL) is a procedural proprietary language used to construct logics
to govern the actions and behavior of individual model entities in QUEST simulation. The logics
in QUEST are implemented using SCL. When you select a particular logic through the button
interface, you are effectively linking to some default SCL program that will be called during the
simulation run.
The Batch Control Language (BCL) is a command language
that is used to control QUEST. For example, BCL commands
can be used to read a model, modify parameters, run a
simulation, interrogate the simulation results, and even
provide visual control. BCL commands can be thought of as
a text-command version of selecting menu buttons in the
Graphical User Interface (GUI). Additionally, BCL commands
can provide data to QUEST.
More about using SCL and BCL syntax can be found in the
QUEST on-line documentation.
19
1
Advanced QUEST Programming
Programming
in SCL &BCL
Procedures
SCL Programs have two structures: procedures and routines.
A procedure is the most common program used in SCL. The logics associated with elements
are actually SCL procedures.
The syntax of basic procedure is shown below:
Procedure proc_first_possible()
VAR
—— Local variable declaration section
UserVar:Integer
BEGIN
—— SCL Statements
UserVar = 1
do_process (ANY)
END
The procedure starts with the procedure title declaration including the name of the procedure.
The main body of a procedure or routine must be bounded by BEGIN and END statements.
20
1
Advanced QUEST Programming
Programming
in SCL &BCL
Routines
A routine has the same basic structure as a procedure except that it has the ability
to return a value to the program that called it. Routines are added to provide
programming structure to SCL.
In the following example, the routine returns a value of data type integer. It is possible
to pass a parameter, either by value or reference, to a procedure or routine.
Routine get_Number_Elements(Element_Name : STRING) :
INTEGER
VAR
MyEClass :Element_class
NumInClass :Integer
BEGIN
MyEClass = get_element_class(Element_Name)
NumInClass = MyEClass->num_element
return NumInClass
END
21
1
Advanced QUEST Programming
Programming
in SCL &BCL
Statements
Statements make up the main body of an SCL program, either a procedure or a routine. The task to be
accomplished by a program is specified by the statements in the statement block. A statement is a
line of SCL code that does something, i.e., it results in some kind of an action.
Data Constructs
An SCL program will generally require some data. In QUEST, data is represented in a number of
constructs. Data constructs are created and used in two parts: first the construct is declared,
thus revealing its name and defining its type, and from there it has values assigned to it and is
used in the logic. QUEST data constructs include the following:
•System attribute or field
•User attribute
•Local variables
•Global variables
•Static variables
22
1
Advanced QUEST Programming
Programming
in SCL &BCL
Data Constructs
Brief description about the attributes and variables:
System Attribute or Field
- This is a data item declared by QUEST and stored as an attribute of
some entity.
User Attribute
- This is a data item you declare as an attribute attached to an element
or a part in the system
Local Variables
- These are variables created for the period of the execution of a
procedure or routine.
Global Variables
- This is created by a program, and once created it is available to any
other program for access or modification within the same QUEST
session.
Static Variables
- These are similar to local variables in that values are held unique to a
specific program.
23
1
Advanced QUEST Programming
Programming
in SCL &BCL
Creating SCL File - Procedure
The steps included in creating a SCL file is as follows:
Create program in text editor
Always name your file
appropriately, linked to the
model & save the SCl file in
the appropriate library.
Locate Program into Library
directory
Compile SCL logic file
When assigning a logic to an
element you will be asked to
pick the file name from the
library. You will then get a list
of the procedures within that
file to chose. The larger the
file the more time to compile
and list the procedures.
SCL files are all
text format with
extension .SCL
Quest has it’s own
compilation system,
and logic tracking
functions.
Assign to Application
execution point
Test the logic
Never assume that the
logic is working. Use
statements in your code
to track events that you
want to occur.
Each of these steps are described in the following slides.
24
Advanced QUEST Programming
1
Programming
in SCL &BCL
Creating SCL File - Procedure
1
Open a text editor with line numbers and include the
required SCL program.
Note:
One file can have any number of procedures
& routines. Never over write a standard logic
file or use a similar procedure name.
2
Save the file to the “Logics directory inside ../QUESTlib or
in your own quest library with a .scl extension file name.
3
Select Run / Simulate / SCL Program / Edit Program / Compile.
You will see Select Library dialog box.
4
Select the required path in the dialog box, and click OK.
25
Advanced QUEST Programming
1
Programming
in SCL &BCL
Creating SCL File - Procedure
You will see the selected ../QUESTlib dialog box.
5
Select the desired program in the dialog box, and click OK.
The message window displays whether
the compilation was successful or not.
6
Select Model / Element Class / Desired Element.
You will see the selected element dialog box (in this case source).
7
Click Logics in the dialog box.
You will see Logics dialog box.
8
Click Process Logic in the dialog box.
26
Advanced QUEST Programming
1
Programming
in SCL &BCL
Creating SCL File - Procedure
You will see Process Logic dialog box.
9
Select the desired logic and click OK on all opened dialog boxes.
10
To test the SCL program written, run the simulation.
A message box will now appear with the process information.
27
1
Advanced QUEST Programming
Programming
in SCL &BCL
Implementing BCL Commands - Procedure
There are five methods of entering BCL commands:
• BCL context button
• BCL user button
• Loading QUEST with a file of BCL commands
• Loading QUEST with a socket that supplies BCL commands
• Via SCL
Method 1 : BCL Context Button
In this method, BCL command are typed in one at a time and can be used to change or make
inquires about an existing model. To enter a BCL command select File / BCL. The BCL
statement dialog box appears. Enter any BCL statement and click OK to implement it.
See on-line documentation for more the list of BCL commands.
28
1
Advanced QUEST Programming
Programming
in SCL &BCL
Implementing BCL Commands - Procedure
Method 2 : Running BCL Macro from a BCL Macro Button
In this method, a BCL action button is created from within QUEST and used to run a series of
BCL commands, which are listed in an ASCII file. More detailed explanation on this will be
given in the following topic.
Method 3 : Loading QUEST with a file of BCL Commands
QUEST may be started up with a command option (-b) that directs it to receive commands from a
specified source. This method is excellent for experimenting with design and for creating a
choreographed walkthrough of a model as it runs.
There are three methods of applying this option:
• A text file of BCL commands may be specified as providing the initial instructions to
QUEST which includes building or reading model and modifying and running the model.
Syntax: quest –b < path name to text file >
29
1
Advanced QUEST Programming
Programming
in SCL &BCL
Implementing BCL Commands - Procedure
• Quest may be started in a special state where it waits for BCL commands to be typed
into a specified window. As you type each command, QUEST will receive the command
and execute it immediately. Results will be echoed back to the terminal or window.
This method works for UNIX systems only.
Syntax: quest –b
• A stream may be directed to QUEST. The <path> specified should be a valid path to
a file that contains valid BCL commands. Each line of the file will be executed successively.
Syntax: cat <path> | quest -b
Method 4 : Loading QUEST with a Socket that supplies BCL Commands
QUEST may be started up with a command option (-b) that directs it to communicate with another
program. This method is useful for optimization that use the results of one model to change the
model in an intelligent fashion.
Syntax: quest –s <TCP/IP socket address>
This allows any external program residing on any machine in a TCP/IP network to load QUEST and
communicate with it through a socket by sending BCL commands and receiving return codes.
There is a C program support library in the giftware/bin directory distributed with the system
under the quest directory.
30
1
Advanced QUEST Programming
Programming
in SCL &BCL
Implementing BCL Commands - Procedure
Method 5 : Running a BCL Command from within SCL
This allows for changes to be made to a model while it is running. This method is useful
for modeling such things as multiple speed conveyors whose speed changes based on
their load. To implement this method, you must use the BCL( ) routine in the SCL logics.
bcl_return = BCL(“RUN 1000”)
bcl_return = BCL(“READ MODEL ‘GIFTS\assembly.mdl’”)
When a BCL command is executed, the system provides reply in two parts: an integer value
(returned BCL integer) and a text string (returned BCL message). Return information is
passed back in a stream with the following syntax:
<integer return code>: <string message>
In all cases, the built-in BCL variables call bcl_msg and bcl_status are set to the returned
BCL message string and the returned BCL integer. These variables should be treated as
read-only. No values can be assigned to these system variables.
31
Programming in SCL & BCL – Exercise
32
1
Exercise – Programming in SCL & BCL
20 min.
Scope:
In this exercise you will write an SCL program containing three SCL statements and three SCL
routines that will sample the machine cycle time from the user interface and cause the machines to fail for
60 seconds after every 10 cycles.
Conditions: D5 must be open.
In this exercise you will:
Create SCL File
Assign SCL to Element
Implement BCL Command
33
Do it Yourself (1/5)
SCREEN SHOT
Starting point
Ending point
Load: ../QUESTlib/MODELS/GIFTS/shop.mdl
34
Do it Yourself (2/5)
Create SCL File
1.
Create a SCL file mylogic.scl in any text editor and save it in ..\QTUTORlib\LOGICS.
2.
Enter the following commands in the file:
USER_ATTRIB
fail_count : Real
VAR
proc_id : Process
procedure myproc()
begin
require part ANY
proc_id = get_process('Process_1')
work sample_cycle_time(proc_id)
celem->fail_count = celem->fail_count + 1
if (celem->fail_count == 10)then
fail 0,60
celem->fail_count = 0
endif pass()
end
35
Do it Yourself (3/5)
Assign SCL File to Element
1.
Select Model / Build / Element / Machine.
2.
Select Wrokcell_1 in the Select a Machine Class dialog box, and click OK.
3.
Click on Logics in the Machine dialog box. Logics dialog box appears,
click on Process Logic.
4.
Select User Func in the Process Logics dialog box.
5.
Select mylogic.scl in the ../QUESTlib/Logics dialog box, and click OK.
6.
After successful compilation, you are prompted to choose the routine
myproc in the Select a SCL function dialog box, and click OK.
7.
Click OK on all open dialog boxes.
36
Do it Yourself (4/5)
Implement BCL Command
You will implement the BCL command using BCL context button & BCL command via SCL.
1.
Select File / BCL.
2.
Enter run 1000 for BCL Statement in the
BCL Statement dialog box, and click OK.
The model is simulated for the specified time & halts.
BCL in SCL method
1.
Create a SCL file bcl_in_scl.scl following the steps given in the previous topic.
2.
Enter the following commands in the file which contains BCL commands in a SCL file. To
run this program, attach this file to the SCL Macro that you will create in the next topic.
Procedure CreateExtrudedConv ( )
Var
BclRet
BclStr
: Integer
: String
37
Do it Yourself (5/5)
Implement BCL Command
Begin
BclRet = BCL("CREATE PCLASS 'Part1'")
BclRet = BCL ("CREATE SOURCE CLASS 'Source1' ")
BclRet = BCL ("SET 'Source1' IAT TO 20 ")
BclRet = Bcl ( "Create EXTRUDED_CONVEYOR Class 'ExtrConv'" )
BclRet = BCL("SET 'ExtrConv' TYPE TO NONACCUMULATING")
BclRet = BCL("CREATE LINEAR SEGMENT FOR 'ExtrConv' FROM COORD -6000, -6000,0 TO 6000, -6000, 0" )
BclRet = BCL("CREATE ARC SEGMENT FOR 'ExtrConv' WITH RADIUS 1000 ANGLE 90 IN LEFT DIRECTION AT 6000, 6000, 0" )
BclRet = BCL("CONNECT ELEMENT 'ExtrConv_1' TO ELEMENT 'ExtrConv_2‘ PHYSICALLY" )
BclRet = BCL("CREATE LINEAR SEGMENT FOR 'ExtrConv' FROM COORD 7000, -5000, 0 TO 7000, 7000, 0" )
BclRet = BCL("CONNECT ELEMENT 'ExtrConv_2' TO ELEMENT 'ExtrConv_3' PHYSICALLY" )
BclRet = BCL("CREATE CONV_DEC_PT CLASS 'ExtrConvDecPt1'")
BclRet = BCL("CREATE CONV_DEC_PT OF 'ExtrConvDecPt1' ON CONVEYOR 'ExtrConv_1' AT OFFSET 500")
BclRet = BCL("CREATE CONV_DEC_PT CLASS 'ExtrConvDecPt2'")
BclRet = BCL("SET 'ExtrConvDecPt2' PROCESS LOGIC TO 'dec_fixed_unload'")
BclRet = BCL("CREATE CONV_DEC_PT OF 'ExtrConvDecPt2' ON CONVEYOR 'ExtrConv_3' AT OFFSET 11500")
BclRet = BCL ("CREATE SINK CLASS 'Sink1' ")
BclRet = BCL("CONNECT ELEMENT 'Source1_1' TO ELEMENT 'ExtrConvDecPt1_1'")
BclRet = BCL("CONNECT ELEMENT 'ExtrConvDecPt2_1' TO ELEMENT 'Sink1_1'")
BclRet = BCL("Fill")
End
38
B
Creating
Macros
Creating Macros
Saving Macros
39
1
Advanced QUEST Programming
Creating
Macros
About Creating Macros
SCL programs are most commonly invoked by linking them to the logic of an element class. An
alternative mechanism for running an SCL program is to run as an SCL macro. An SCL macro is a
procedure that is invoked at the click of a user created SCL macro button.
BCL macro’s allow the user to perform multiple interface driven functions quickly and efficiently.
These statements are used throughout every program to link program designed parameters to
element specification.
More about creating macros can be found in the QUEST
on-line documentation.
40
Advanced QUEST Programming
1
Creating
Macros
Creating Macros
1
Select User1 / Page_no / Define.
You will see User Button Type dialog box.
2
Select SCL MACRO in the dialog box, and click OK.
The message window prompts “Place and Size new Button or
Select an existing button”
3
Click on the selection area and drag holding LMB until
the desired size is obtained as shown:
You will see Select Library dialog box.
4
Select the library path where the SCL file created
is saved in the dialog box, and click OK.
41
Advanced QUEST Programming
1
Creating
Macros
Creating Macros
You will see the selected path dialog box.
5
Select a SCL macro text file in the dialog box.
42
Advanced QUEST Programming
1
Creating
Macros
Creating Macros
You will see Macro Button Attributes dialog box.
6
Set the desired fields in the dialog box, and click OK.
When you are finished, a SCL macro action button is created.
Clicking the button at any stage will run the macro.
7
Follow steps 1 to 6 in creating BCL macro, selecting BCL Macro
in the User Button Type dialog box in step 2.
43
1
Advanced QUEST Programming
Creating
Macros
Saving Macros
If the button is to be reused in any future session of QUEST, it must be saved.
1
Select User1 / Page_no / Page_no / Save.
?Sure? Appears on the Save button as shown:
2
Click ?Sure? to confirm the action.
The message window displays “Button Configuration Saved”.
44
Creating Macros – Exercise
45
1
Exercise – Creating Macros
20 min.
Scope:
In this exercise you will create two macros and will apply to the shop model.
Conditions: D5 must be open.
In this exercise you will:
Create SCL & BCL File
Create and Run Macro
46
Do it Yourself (1/4)
SCREEN SHOT
Starting point
Ending point
Load: ../QUESTlib/MODELS/GIFTS/shop.mdl
47
Do it Yourself (2/4)
Create SCL and BCL File
1.
Create a SCL file scl_macro.scl in any text editor and save it in ..\QTUTORlib\SCLMACRO.
2.
Enter the following commands in the file:
procedure my_scl_macro()
var
ret_val :
integer
begin
write("now it works”.cr)
ret_val = bcl(“CONTINUE SIMULATION ")
end
3.
Create a BCL file bcl_macro.scl in any text editor and save it in ..\QTUTORlib\BCLMACRO.
4.
Enter the following commands in the file:
Run 1000
48
Do it Yourself (3/4)
Create and Run Macros
1.
Select User1 / Page1 / Define.
2.
Select SCL MACRO in the User Button Type dialog box, and click OK.
3.
Click on the selection area and drag holding LMB until the desired size
is obtained. Once the mouse is released Select Library dialog box appears.
4.
Select the library ../SCLMACROS/ where you have saved the SCL file.
5.
Select scl_macro.scl in the dialog box, and click OK.
6.
Set Button Type to Confirm, enter SCL for Text, SCL for Hi Text
and ?Sure? for Confirm Text in the dialog box and click OK.
49
Do it Yourself (4/4)
Create and Run Macros
7.
Follow steps 1 to 6 to create a BCL Macro. Select BCL Macro in the User Button Type
dialog box in step 2 & choose bcl_macro.bcl file in the ../BCLMACRO/ dialog box. Enter
BCL in the Macro Button Attribute dialog box.
8.
Run the BCL macro first. Halt the simulation and then run the SCL macro.
A SCL program Output dialog box appears with the message “now works” as specified
in SCL macro file, which means the macro file has been executed successfully.
The message window displays “SCL Macro complete”.
50
C
SCL
Debugging
Debugging SCL File
Setting Break Point to Line
Setting Break Point to Variable
Setting Break Point Attributes
Modifying Break Point
51
1
Advanced QUEST Programming
SCL
Debugging
About Debugging
After you model a system, you may require to debug it to make it run as desired. The Run page
provides you with many tools that help in debugging and verifying the model.
The buttons under the SCL Debugger title bar allow you to set and display a specified file
in the SCL debugger window, or you can advance the program by a specified number of lines.
This section discusses how to debug models using the functionalities available in the Run pages.
Complete information about debugging can be found in
the on-line documentation.
52
Advanced QUEST Programming
1
SCL
Debugging
Debugging SCL File - Procedure
1
Select Run / Trace / SCL Debugger / File.
You will see Select Library dialog box.
This button allows to set
and display a specified file
in the SCL debugger
window.
2
This button can be used
only after the simulation is
halted by an SCL break
point that is set to the file,
otherwise an error occurs.
Select a library in the dialog box, and click OK.
You will see ../QUESTlib/Library_name/ dialog box.
3
Select a SCL file to debug in the dialog box.
53
1
Advanced QUEST Programming
SCL
Debugging
Debugging SCL File - Procedure
If the selected file is a valid file in the simulation and has been complied in full debug mode,
you will see a SCL Program Window dialog box.
4
Make the required changes in the file in the
dialog box, and click Close.
The message window displays
“ File modified and saved”.
If not the message window displays “ File selected
../QUESTlib/library_name/file_name in not loaded.”
54
1
Advanced QUEST Programming
SCL
Debugging
Debugging SCL File - Procedure
1
Select Run / Trace / SCL Debugger / Step.
A dialog box is displayed to select from the following options:
• One: This advances the program to the next line. If the current line in
the sub-program call, the program will advance to the first line
of the sub-program.
• Over: This advances the program to the next line. If the current line in
the sub-program call, the program will advance to the line after
the sub-program call in the current sub-program.
• Sub: This advances the program to the line after the one that invoked the
current sub-program in the sub-program’s caller.
55
Advanced QUEST Programming
1
SCL
Debugging
Setting Break Point to Line - Procedure
The buttons under SCL Break Point allow you to set break points at the highlighted
line in the SCL Debugger Window or set the break point for a variable.
1
Select Run / Trace / SCL Break Point / Line.
You will see SCL Debugger Window dialog box.
2
Select a line to set a break point in the dialog box, and click Close.
The message window displays “Break when line <line_number>”.
56
1
Advanced QUEST Programming
SCL
Debugging
Setting Break Point to Variable - Procedure
1
Select Run / Trace / SCL Break Point / Variable.
You will see Enter variable reference : dialog box.
2
Enter variable reference in the dialog box, which may be a simple variable,
structure or array element of global, static or local scope, and click OK.
You will see Relational Operator dialog box.
3
Select a relational operator in the dialog box, and click OK.
You will see Enter constant expression : dialog box.
57
Advanced QUEST Programming
1
SCL
Debugging
Setting Break Point to Variable - Procedure
4
Enter a constant expression in the dialog box, and click OK.
The message window displays “Break when variable
<variable_name> <rel_operator> <const_exp>”.
Setting Break Point to Attributes - Procedure
To set break point to attributes of an element and part, you must have already added
user attributes to the desired elements and parts.
1
Select Run / Trace / SCL Break Point / Attrib.
You will see Entity Type dialog box.
2
3
Select the desired entity in the dialog box, and click OK.
You will see Select a entity_name dialog box.
Select the desired option in the dialog box, and click OK.
58
Advanced QUEST Programming
1
SCL
Debugging
Setting Break Point to Attribute - Procedure
You will see Relational Operator dialog box.
4
Select a relational operator in the dialog box and click OK.
You will see Enter constant expression : dialog box.
5
Enter a constant expression in the dialog box, and click OK.
The message window displays “Break when entity type <entity_name>
attribute <attribute_name> <rel_operator> <const_exp>”.
59
Advanced QUEST Programming
1
SCL
Debugging
Modifying Break Point - Procedure
1
Select Run / Trace / SCL Break Point / Modify.
You will see SCL Break Points dialog box listing all the declared break points.
2
Set the desired declared break point to a option listed
in the pull down menu in the dialog box and click OK.
The status of all break points is updated to the option chosen.
60
D
Creating
Popups
Creating Popups
Defining Options to Popups
Linking Popups to Element Class
61
1
Advanced QUEST Programming
Creating
Popups
About Creating Popups
An SCL popup is a file containing a lost of procedures (or routines) that can be associated with an
element class in QUEST. When you associate a logic to an element class using the user interface
you use a standard popup with the standard procedures assigned for that logic. A popup, with its’
associated procedures can be stored as part of the current model, or in a HOOK$LIB directory as
an independent entity.
More about popups can be found in the QUEST on-line
documentation.
62
Creating
Popups
Advanced QUEST Programming
1
Creating Popups - Procedure
The first step in using popup is to define a popup itself. Once defined, procedures
or routines are associated with the popup and linked to it. These procedures &
routines associated with a popup are known as options. To define a popup:
1
Select Advanced / Popup / Popup / Cre.
You will see Create Popup dialog box.
This button allows to delete an
SCL popup selection. You will be
prompted to indicate a SCL popup
to be deleted, and after
confirmation the popup is removed
from the model.
2
Enter the popup name, select the desired type in the
dialog box, and click OK.
The message window displays “Popup <Popup_name> created”
To save this popup to an independent file immediately:
3
Select File / Save Entity.
63
Advanced QUEST Programming
1
Creating
Popups
Creating Popups - Procedure
You will see Select Entity Type dialog box.
4
5
Select Popup in the dialog box, and click OK.
You will see Select a Popup dialog box.
6
Select the popup name created in the
dialog box, and click OK.
64
1
Advanced QUEST Programming
Creating
Popups
Creating Popups - Procedure
You will see the Save dialog box.
7
Enter the file name & set the library list in the dialog box, and click Save.
8
Select popup dialog box appears again, click Cancel.
To modify crated popups, select Advanced/Popup/Popup/Mod. Select the desired popup in the dialog
box. The requested popup dialog box appears to which the required modification can be done.
65
1
Creating
Popups
Advanced QUEST Programming
Defining Options to Popups - Procedure
To add an option to the SCL popup, you must have already created the required SCL file.
1
Select Advanced / Popup / Options / Add.
You will see Select a Popup dialog box.
2
This button allows
you to remove an
option from an SCL
popup.
Select the required popup from the dialog box, and click OK.
You will see ../LOGICS/ library dialog box.
3
Select the created SCL file in the dialog box, and click OK.
The SCL function in the file is complied.
To verify that the processes are available to the popup, select Advanced / Popup / Options / Show.
Select the desired popup in the dialog box. The message window displays all the options in the popup.
66
Advanced QUEST Programming
1
Creating
Popups
Linking Popups to Element Class - Procedure
1
Select Advanced / Popup / Attach Popup / Add.
You will see Select an Entity Type dialog box.
This button allows
you to show all SCL
popup for an entity
type.
2
Select Element Class in the dialog box, and click OK.
3
Select the desired element in the QUEST model
positioned on the grid.
This button allows
you to remove an
SCL popup from an
entity type.
This button allows you to
modify the option at anytime,
including the middle of a
simulation run.
67
1
Advanced QUEST Programming
Creating
Popups
Linking Popups to Element Class - Procedure
You will see Select a Popup dialog box.
4
Select the required popup in the dialog box, and click OK.
You will see ../LOGICS/ library dialog box.
5
Select the required SCL file in the dialog box, and click OK.
The SCL function in the file is not complied as it is already complied & is in the memory.
The process is complete. The selected element now has access to the attached popup
and will use the options wherever the popup is used in its SCL code.
68
Creating Popups – Exercise
69
1
Exercise – Creating Popups
30 min.
Scope:
In this exercise you will create a new popup attached to the buffer named Buffer1_1
in the shop model. The popup will permit easy control of alternative logic during the
execution of the buffer process logic.
Conditions: D5 must be open.
In this exercise you will:
Define Popup
Define SCL code to access Popup
Add Options to the Popup
Attach popup to the element
Run Model with Popup
70
Do it Yourself (1/11)
SCREEN SHOT
Starting point
Ending point
Load: ../QUESTlib/MODEL/GIFTS/shop.mdl
71
Do it Yourself (2/11)
Define Popup
1.
Select Advanced / Popup / Popup / Cre.
2.
Enter TUTO_HOOK for Popup Name and set Save In to Independent
File in the Create Popup dialog box, and click OK.
The message window displays “Popup <TUTOR_HOOK> created.
3.
Select File / Save Entity to save the popup to the disk as part of the model.
4.
Select Popup in the Select Entity Type dialog box, and click OK.
5.
Select TUTOR_HOOK in the Select a Popup dialog box, and click OK.
72
Do it Yourself (3/11)
Define Popup
6.
7.
Enter HOOK_FILE for File name & set Library list to ../HOOKS/
in the Save As dialog box, and click Save.
Select a Popup dialog box appears again, click Cancel.
The message window displays “Popup <TUTOR_HOOK> saved”.
73
Do it Yourself (4/11)
Define SCL Code to Access Popup
A buffer process logic will be created which will allow the use of a popup.
This popup will be used to choose from two different, simple messaging
procedures for the buffer process logic.
1.
Select File / Copy File.
2.
Select the SCL file pr_buff.scl.src located in ../QUESTlib/SYSDEF/LOGICS/.
3.
Save As dialog box appears. Rename the SCL file as buff_pr.scl and set
library list to ../QUESTlib/ LOGICS in the dialog box , and click Save.
The message window confirms that the file pr_buff.scl.src has been
copied to the file buf_pr.scl in the library ../QUESTlib\LOGICS.
74
Do it Yourself (5/11)
Define SCL Code to Access Popup
4.
Select File / Edit File to edit the SCL file to match the following code.
5.
Select buff_pr.scl in the ../QUESTlib/LOGICS/ dialog box.
6.
Overwrite with the following code in the File Edit Window, and click WRITE.
7.
Click Save in the Save As dialog box. You will be prompted with the message “The file
buff_pr.scl already exist”. Click Yes in the dialog box, then click Close in the File Edit Window.
75
Do it Yourself (6/11)
Define SCL Code to Access Popup
This step creates the alternative SCL procedures for this popup. In this example they
are all in one file. However, they can also be placed in different files.
8.
Follow steps 1 to 7 in creating the file buff_hooks.scl. Select buf_hooks.scl located
in..QUESTlib/LOGICS & save the file as buff_hooks.scl in the preferable location.
9.
Edit the file and enter the following code in the File Edit Window.
10. Save the file buff_hook.scl.
Note:
The SCL syntax Read_kbd (prompt_str, lvalue [ , lvalue,... ] ) requires two
parameters. The first parameter is a string specified within quotes & the
other is a value. The command returns the string specified.
76
Do it Yourself (7/11)
Add Options to Popup
1.
Select Advanced / Popup / Options / Add.
2.
Select TUTOR_HOOK in the Select a Popup dialog box, and click OK.
3.
Select buf_hook.scl in the ../QUESTlib/LOGICS dialog box, and click OK.
The message window displays “File ../QUESTlib/LOGICS/buf_hook.scl complied successfully”.
4.
Select wr_res function in the Select a SCL function dialog box, and click OK.
5.
Choose the buf_hook.scl again and choose wr_wgt in the Select a SCL function dialog box.
Choose the same file again and click Cancel in the SCL function dialog box.
6.
To verify that the processes are available to the popup, select Advanced / Popup / Options / Show.
7.
Select TUTOR_HOOK from the Select a Popup dialog box and click on OK. The message window
displays “SCL procedures, wr_res and wr_wgt, are the options in the popup TUTOR_HOOK”.
77
Do it Yourself (8/11)
Add Options to Popup
8.
At this point, the information on the popup TUTOR_HOOK is complete.
Save the popup information again to the file HOOK_FILE.mdl in
../QUESTlib/HOOKS/, as explained before by selecting File/Save Entity.
9.
Open the file HOOK_FILE.mdl in notepad from it’s location. It should have the following contents:
DEF_SCLHOOK 'TUTOR_HOOK' 0
HOOK_PROCEDURE wr_res()
HOOK_PROCEDURE wr_wgt()
END_DEFINE 'TUTOR_HOOK'
Attach Popup to Element Class
1.
To attach the revised process logic to the process of Buffer1
select Model / Build / Element Class / Buffer.
2.
Select Buffer1 in the Select a Buffer Class dialog box, and click OK.
3.
Click Logics in the Buffer dialog box.
78
Do it Yourself (9/11)
Attach Popup to Element Class
4.
Select Process Logics in the Logic dialog box, and select
User Func in the Process Logic dialog box, click OK.
5.
Select the file buff_pr.scl in the ../QUESTlib/LOGICS/ dialog box,
and click OK. The file is complied
6.
Select buf_sort in the Select a SCL function dialog box, and click OK.
7.
Click OK on all open dialog boxes.
8.
The final step is to attach the popup to the buffer.
Select Advanced/Popup/Attach Popup/Add.
9.
Select Element Class in the Select an Entity Type
dialog box, and click OK.
10. Click on Buffer1 positioned on the grid or in the
Element Class dialog that appears.
79
Do it Yourself (10/11)
Attach Popup to Element Class
11. Select TUTOR_HOOK popup in the Select a Popup dialog box, and click OK.
12. Select wr_res option in the TUTOR_HOOK dialog box, and click OK.
13. Select a Popup dialog box appears again, click Cancel.
No compilation takes place as this procedure is already compiled and in memory.
The process is complete. The buffer named Buffer1 now has access to the popup named
TUTOR_HOOK and is currently going to use wr_res wherever the popup is used in its SCL
code; i.e., in its revised process logic code
Note:
In the above process there were three options in the TUTOR_HOOK dialog box, even
though only two procedures are currently attached to TUTOR_HOOK. The option "User
Func" allows the attachment of any procedure by selection of any SCL file and any
procedure within it. This shortcut is useful when switching back and forth between
options seems unlikely. For example, the procedure could be set for this popup for this
buffer without adding the procedure to TUTOR_HOOK. This selection would involve
compilation of the selected SCL file.
80
Do it Yourself (11/11)
Run Model with Popup
1.
Run the model for 1000 sec and observe that every time a part arrives in Buffer1, a
dialog box Using TUTOR_HOOK with procedure wr_res: appears. This prompt will
require a mouse click on OK button or the enter key to continue the model run.
Change the procedure/ routine to observe the difference in the two options. To do this:
2.
Select Advance / Popup / Attach Popup / Set Options.
3.
Select TUTOR_HOOK in the Select a popup dialog box, and click OK.
4.
Select the procedure/routine wr_wgt in the
TUTOR_HOOK dialog box, and click OK.
5.
Run the model & not the difference. The dialog box will now read:
“Using TUTOR_HOOK with procedure wr_wgt:”.
81
1
Advanced QUEST Programming – Module summary
Summary
This module explained the advanced functionality and application of BCL
and SCL programming. The characteristics of popups and the functions
that are used to create them where also discussed here.
Coming Up
Optimization and Experimentation
Defining Control Variables
Conducting Experimentation
Conducting Optimization
3 hour
82
1
Advanced
QUEST
Programming
2
Optimization and
Experimentation
3
5
6
Trains, Fluids and
Tools & Fixtures
4
QUEST
Graphical
Outputs
Hierarchical
Model
Final Assembly
Model & Pull Model
Module 2
Optimization and
Experimentation
83
2
Optimization and Experimentation
Overview
This module provides the purpose of simulation & the necessity of
conducting experiments on the simulation model by conducting
various runs.
Objectives
Topics in this module are:
Defining Control Variables
Conducting Experimentation
Conducting Optimization
3 hours
84
Menus and Action Buttons used in this Module
85
2
Optimization and Experimentation
Defining
Control
Variables
Creating Control Variables
SCL Support for Control Variables
Conducting
Experimentation
Setting and Running Multi-Run Experiments
Saving & Running Experimentation Data
Conducting
Optimization
Setting Optimization
Running & Saving Optimization
3 hours
86
A
Defining
Control
Variables
Creating Control Variables
SCL Support for Control Variables
87
2
Optimization and Experimentation
Defining
Control
Variables
About Defining Control Variables
The purpose of a simulation is to understand the behavior of the system being simulated
and to evaluate alternatives to determine the best alternative. Therefore after a simulation
model is built, it is necessary to conduct experiments on the simulation model by conducting
various runs while varying certain model parameters, i.e. parameters of entities within the model.
The model parameters that are varied are those parameters of
the system that can be controlled. These are the control
variables, also called decision variables such as the conveyor
operating speed & processing time on machine. The output
that is to be optimized (maximized or minimized) is defined by
an objective function such as the number of parts to be
maximized.
A Control Variable is a generic entity in QUEST, which is
associated to an attribute of an entity in the model. The model
entity can be an Element Class, Element, Shift Break, Failure,
etc. Depending on the entity, the set of attributes, which can
be associated to the Control Variable, varies.
More about optimization & experimentation can be found in the
QUEST on-line documentation.
88
Optimization and Experimentation
2
Defining
Control
Variables
Creating Control Variables
A control variable can be created or an existing
control variable can be modified by using the :
1
Select Run / Simulate / Control Variables / Cr/Mod.
You will see the Control Variable dialog box.
On selecting this
button the list of
entities of the selected
entity type, existing in
the model are given.
Selecting this button allows
you to specify the range and
step size of for the Control
Variable. This is enabled
only when the Attribute is
selected.
2
On selecting this button a
dialog box appears, prompting
u select an existing control
variable to be deleted. This
doesn’t have affect on the
attribute associated with the
control variable.
On selecting this button the
list of attributes that are
allowed for the selected
entity are given. This button
is enabled only after the
entity has been selected.
Enter the control variable name and select the required
entity type in the dialog box, and click Entity.
89
2
Optimization & Experimentation
Defining
Control
Variable
Creating Control Variables
You will see the selected entity type dialog box.
3
Select the required option in the dialog box, and click OK.
4
Select Attribute in the Control Variable dialog box.
You will see the Select Attribute dialog box.
5
Select the desired option in the dialog box, and click OK.
6
The Range dialog box appears. Enter the required values in the dialog box, and click OK.
7
Click OK in the Control Variables dialog box.
The message window displays “Control Variable <variable_name> created”
90
2
Optimization and Experimentation
Defining
Control
Variables
SCL Support for Control Variable
Control Variable is an entity in QUEST. So like other QUEST entities,
Control variables can be accessed and used in SCL.
• The SCL data type for control variables: 'control_variable' or ‘ctrl_var'.
• Like other entities in QUEST, the handle to a control variable can be obtained by using the routine:
Get_Control_Var ( String: cvar_name ) : Ctrl_Var
Cvar_name: The name of the Control Variable
• There is a system-defined variable, which gives the handle to the first control variable in the model:
‘first_control_var' or 'first_cvar‘.
• Given a handle to a control variable, the handle to the next control variable can be obtained by using
the next attribute of type Ctlr_Var: Ctrl_Var1->next.
• The current values for control variables associated to numeric attributes can be obtained by the
attribute ‘value’, of type Real: Ctrl_Var1->value.
• Given the handle the name of the control variable can be obtained by using the attribute ‘name’ of the
type string: Ctrl_Var1->name.
91
Defining Control Variables – Exercise
92
2
Exercise – Defining Control Variables
15 min.
Scope:
In this exercise you will create control variable for the QUEST model
shop.mdl located in ../QUSETlib/MODELS/GIFTS
Conditions: D5 must be open.
In this exercise you will:
Create Control Variable
93
Do it Yourself (1/3)
SCREEN SHOT
Starting point
Ending point
Load: ../QUESTlib/MODEL/GIFTS/shop.mdl
94
Do it Yourself (2/3)
Create Control Variable
1.
Select Run / Simulate / Control Variable / Cre/Mod.
2.
Enter Average_Process_Time for Name, set Entity Type to Process
in the Control Variable dialog box, and click Entity.
3.
Select process_1 in the Select Process dialog box, and click OK.
4.
Click Attribute in the Control Variable dialog box.
5.
Select Cycle Time in the Select Attribute dialog box, and click OK.
6.
Range dialog box appears. Enter the following values in each field
as shown below in the dialog box, and click OK.
7.
Click OK in the Control Variable dialog box.
The message window displays “Control Variable
<Average_Process_Time created”.
95
Do it Yourself (3/3)
Create Control Variable
8.
Follow steps 1 in creating Conv1_Speed control variable. Set Entity Type to Element Class.
9.
Click on Entity & choose Converyor_1 in the dialog box, and click OK
10.
Click on Attribute & choose Speed in the dialog box, and click OK.
11.
Range dialog box appears. Enter the values given in the dialog box below:
12. Follow steps 8 to 11 in creating Conv2_Speed, Conv3_Speed & Conv4_Speed control variables.
In step 9 select Conveyor_2,3, & 4 respectively in the Entity dialog box.
This completes the process of creating all the required control variables for the shop model.
96
B
Conducting
Experimentation
Setting and Running Multi-Run Experiments
Saving & Retrieving Experimentation Data
97
2
Optimization and Experimentation
Conducting
Experimentation
About Conducting Experimentation
The Experimentation feature in QUEST allows the user to set up a batch of experiments
with one or more model parameters changed for each experiment. This helps the user to
efficiently make multiple runs with different settings. After the batch of experiments is
complete, the simulation outputs, i.e. the statistics, for each of the experiments, may be
analyzed.
The model parameters that are to be changed must be associated to a Control Variable.
The multi-run Experimentation cannot be setup if no Control Variables are defined in the model.
More about optimization & experimentation can be found in the
QUEST on-line documentation.
98
Optimization and Experimentation
2
Conducting
Experimentation
Setting & Running Multi-run Experiments
1
Select Run / Simulate / Experiments/Optimize / Experimentation.
You will see the Experimentation Setup dialog box.
This indicates that number of simulation runs for
each experiment. When running multiple
replications, the values of the Control Variables are
not changed, but each replication starts with a
different Random Number Seed so the outputs for
each replication will be different.
This allows you to set the
multi-run setup. The number
of rows is equal to number
of experiments set & has a
column for each control
variable created for the
model.
2
Clicking on this
button starts the
simulation run for
the experiments.
Enter the number of experiments you would like to perform and the
number of replications in the dialog box, and click Experiment Setup.
99
Optimization and Experimentation
2
Conducting
Experimentation
Setting & Running Multi-run Experiments
You will see the Experiment Setup dialog box.
3
Set the experiment values for each of the control variables in the dialog box, and click OK.
4
When you are finished setting the multi-run experiments,
click Start Experiment in the Experimentation Setup dialog box.
The simulation run for the set experiments begins with Animation
Mode off and the Restore Random Seeds mode set to No.
When the simulation of the model is completed, the message window prompts
“ Experimentation Runs Completed. Experimentation log file: C:\temp”.
Experimentation log file consists of statistics of all the simulation runs that
can be analyzed and studied & is stored in the temp folder.
100
Optimization and Experimentation
2
Conducting
Experimentation
Saving & Retrieving Experiments Data
The Optimization and Experimentation data is saved while saving the Model.
The Experimentation and the Optimization data can be saved separately in the
DATA$lib. If no file is selected for the Optimization and/or Experimentation data,
by default, the data is saved to the Model file. However, if the data has been loaded
from a file it will be saved back to the respective file. To save the data independently:
1
Select File / Save Entity.
You will see Select Entity Type dialog box.
2
Select Experimentation Data in the dialog box, and click OK.
101
Optimization and Experimentation
2
Conducting
Experimentation
Saving & Retrieving Experiments Data
You will see Save As dialog box.
3
Enter the file name & set the library where you would
like to save the data in the dialog box, and click Save.
The message window displays “Experimentation data saved”.
102
Conducting Experimentation – Exercise
103
2
Exercise – Conducting Experimentation
20 min.
Scope:
In this exercise you will conduct experiments for the shop model with the control variables
created in the previous topic.
Conditions: D5 must be open.
In this exercise you will:
Set Multi-Run Experiments
104
Do it Yourself (1/2)
SCREEN SHOT
Starting point
Ending point
Load: ../QUESTlib/MODEL/GIFTS/shop.mdl
105
Do it Yourself (2/2)
Set Multi-Run Experiments
1.
Select Run /Simulate / Experiments/Optimize / Experimentation.
2.
Enter 3 for Number of Experiments & 1 for Number Of Replications
in the Experimentation Setup, and click Experimentation Setup.
3.
Set values to each control variable in the Experiment Setup
dialog box as shown below, and click OK.
4.
Click on Start Experimentation in the Experimentation Setup dialog box.
When simulation run for the specified experiments begins. When the
simulation is completed, the message window reads “ Experimentation
log file: C:/temp”.
5.
Click OK in the Experimentation Setup dialog box. Open the log file from
its location & analyze the statistics. The following statistics should be
displayed in the log file:
106
C
Conducting
Optimization
Setting Optimization
Running & Saving Optimization
107
2
Optimization and Experimentation
Conducting
Optimization
About Conducting Optimization
The experimentation feature allows testing a batch of alternatives. However, if it is desired
to get the best alternative, even for a moderately complex model, it would require a large
number of experiments to be run. Often, it is not clear how to adjust the Control Variables
from one experiment to the next, because the relation between the model attributes and
the objective to be optimized may be complex. Additionally, the interaction between two
or more attributes being varied may be complex. Therefore searching for the optimal
solution manually, may be tedious and, in problems with thousands or millions of
potential alternatives, it is impractical. The ultimate goal of this process is to find
the solution that optimizes (maximizes or minimizes) the value of the objective function.
Optimization is the process of determining the best
alternative, i.e. the optimal combination of parameters
settings, which gives the best possible output.
More about optimization & experimentation can be found in the
QUEST on-line documentation.
108
Optimization and Experimentation
2
Conducting
Optimization
Setting Optimization
1
Select Run / Simulate / Experiments/Optimize / Optimization.
You will see the Optimization Setup dialog box.
This indicates that number of
simulation runs that to made
for the iteration.
This is similar to the number of runs but
instead of terminating the optimization
after a certain number of iterations, the
optimization will terminate after the
specified time has elapsed.
This is yet another criteria to stop the
optimization. The options are Yes & No. If this
is set to ‘Yes’, the optimization will stop when
the optimizer determines that the solution is
unlikely to improve any further.
This allows you to define
the function to be either
minimized or maximized.
2
Enter the number of iterations, the stop time & other required
details in the dialog box, and click Objective Function.
109
Optimization and Experimentation
2
Conducting
Optimization
Setting Optimization
You will see the Experimentation Setup dialog box.
This has 2 options, either Maximize or
Minimize. It determines whether the
goal of optimization is to maximize or
minimize the Objective Function.
The function can be any SCL Expression or a
pre-compiled SCL routine that evaluates to a
Real value. The value of the objective
function is evaluated after every simulation
run and is fed back to Quest.
3
Set optimization type to maximize or minimize & enter
the objective function in the dialog box, and click OK.
4
Click Constraints in the Optimization Setup dialog box.
You will see the Set Constraints dialog box.
5
Click on Add/Modify in the dialog box.
110
Optimization and Experimentation
2
Conducting
Optimization
Setting Optimization
You will see the Constraints Info dialog box.
The expression can be
any SCL Expression, a
pre-compiled SCL
routine that evaluates
to a Real value or an
expression that is
linear combination of
the defined Control
Variables.
This is the value, a real
number that is a limiting
value of the constraint’s
expression.
There are two modes of
specifying constraints, either
as an ‘SCL expression’ or
‘Mathematical’.
The constraint relationship can be either >=
(greater than or equal) <= (less than or
equal) or = (equal) to the RHS value
specified by the user. It defines the
relationship that must be satisfied by any
feasible solution between the Expression
and the RHS Value.
6
Enter the name & other required details in the dialog box, and click OK.
7
Click OK in the Set Constraints dialog box.
111
Optimization and Experimentation
2
Conducting
Optimization
Running & Saving Optimization
1
After setting up the optimization, click on Run Optimization
in the ‘Optimization Setup’ dialog box.
If the information is incomplete or incorrect, the optimization
will not run, but appropriate error messages will be displayed.
The optimization process starts with Quest assigning a set of values to the control variables
for that particular iteration and then runs the simulation with Animation off and the Restore
Random Seeds mode set to No. The output of the simulation is used to evaluate the Objective
Function and SCL Expression constraints, if any and results are returned back into the Quest.
Then Quest analyzes these results and returns the settings for the next iteration. This process
continues till the stopping criteria are fulfilled.
During the optimization process, an optimization chart is plotted, with Objective Function value
(on Y-axis) against the iteration number (on X-axis). The user can monitor the change in the
Objective function value as the optimization process proceeds. The Objective function values
for only feasible iterations are plotted, i.e. the infeasible solutions are not plotted.
2
The process of saving Optimization data is similar to saving Experimentation data
explained before. The only difference is choose Optimization data in the Select
Entity Type dialog box.
112
Conducting Optimization – Exercise
113
2
Exercise – Conducting Optimization
20 min.
Scope:
In this exercise you will conduct optimization for the shop model to the control variables
created.
Conditions: D5 must be open.
In this exercise you will:
Set & Run Optimization
114
Do it Yourself (1/4)
SCREEN SHOT
Starting point
Ending point
Load: ../QUESTlib/MODEL/GIFTS/shop.mdl
115
Do it Yourself (2/4)
Set & Run Optimization
1.
Select Run / Simulate / Experiments/ Optimize / Optimization.
2.
Enter 100 for Number of Iterations, 600 for Stop Time & set Yes to
Auto Stop in the Optimization Setup, and click Objective Function.
3.
Set Maximize to Optimization Type & enter Total_Profit() in the
Objective Function dialog box as shown below, and click OK.
4.
Click on Constraints in the Optimization Setup dialog box.
5.
Click on Add/Modify in the Set Constraints dialog box.
6.
Enter Cost Constraint or name & define other values in the respective
fields in the dialog box as shown below, and click OK.
Note:
The constraint Cost_Constraint specify that the
total cost should not exceed 500o, defined in
shop.scl. Also make sure you have complied
shop.mdl previously.
116
Do it Yourself (3/4)
Set & Run Optimization
7.
Follow step 5 in creating constraint Conv_Speed_Constraint1.
8.
Enter the values in each fields in the dialog box as shown below:
9.
Follow steps 7 & 8 in creating constraints Conv_Speed_Constraint2,
and Conv_Speed_Constraint3. In the Expression field enter
Conv1_Speed – Conv2_Speed and Conv1_Speed – Conv2_Speed
respectively in their dialog box.
10. Click OK in the Set Constraints dialog box.
11. When you are finished in setting the optimization, click
Run Optimization in the Optimization Setup dialog box.
Note:
These constraints specify that the speed of all the four conveyors should be the same.
117
Do it Yourself (4/4)
Set & Run Optimization
12. During the optimization process, the following optimization
chart is plotted with values for only feasible iterations.:
13. Once the process in completed, open the Optimization log file from it’s location in ../temp.
118
2
Optimization and Experimentation – Module summary
Summary
This module explained the purpose of conducting experiments on the
simulated model & conducting various runs by varying the control. Also,
the process of creating control variables, conducting experimentation &
optimization were covered here.
Coming Up
QUEST Graphical Output
Creating Videos
Creating Images and Hardcopies
2 hour
119
1
Advanced
QUEST
Programming
2
Optimization and
Experimentation
3
5
6
Trains, Fluids and
Tools & Fixtures
4
QUEST
Graphical
Outputs
Hierarchical
Model
Final Assembly
Model & Pull Model
Module 3
QUEST Graphical
Outputs
120
3
QUEST Graphical Output
Overview
This module provides the information on QUEST graphical outputs i.e
creating videos, hardcopies, capturing image & saving the model in
other formats.
Objectives
Topics in this module are:
Creating Videos
Creating Images and Hardcopies
2 hours
121
Menus and Action Buttons used in this Module
122
3
QUEST Graphical Outputs
Creating
Videos
Setting Video Variable
Creating Config File & Video folder
Recording and Saving Video
Creating
images &
hardcopies
Capturing Images
Creating Postscripts
Plotting Current Views
Printing and Saving 2D Charts
2 hours
123
A
Creating
Videos
Setting Video Variable
Creating Config File & Video folder
Recording and Saving Video
124
3
QUEST Graphical Outputs
Creating
Videos
About Creating Videos
Videos and movies can be created in QUEST without the use of any external software on a
windows platform, either with NT4.0 or Win 95/98. A video consists of a number of images called
frames that are sequentially combined into a file as AVI, MPEG or tiff files.
The resultant files can be played on a Standard Win NT installation with the help of Media Player
or even NETSCAPE 4.0 & can be embedded in Power Point Presentation. Ability to create these
files are not options in QUEST but comes with the base software.
More about Creating Videos can be found in the QUEST on-line
documentation.
125
QUEST Graphical Outputs
3
Creating
Videos
Setting Video Variable
The following procedure is to create an AVI file. AVI stands for Audio Video
Interleave. VIDEO can be set to AVI in the “.qenvfig” file. This “.qenvfig” file is
used to initialize QUEST “environment variables” e.g. button colors, menu style
etc. For more details on environment variables see the Configuration Manual from
the QUEST online documents. To do this:
1
Select File / Edit Config.
You will see Select Config Type dialog box.
2
Select .qenvfig in the dialog box, and click OK.
126
QUEST Graphical Outputs
3
Creating
Videos
Setting Video Variable
You will see Config Edit Window.
3
If the text editor contains text, locate the VIDEO variable and
change it’s value from NONE to AVI / MPEG / tiff, depending
in which format you want to record the video.
If it is empty, click Close in the Edit Window &
select File / Save Config, then repeat step 2 & 3.
4
When u have finished setting the VIDEO variable,
click WRITE in the Config Edit Window.
127
QUEST Graphical Outputs
3
Creating
Videos
Setting Video Variable
You will see Save As dialog box.
5
Click Save in the dialog box without changing the location where the file is stored.
6
AVI setup is complete, exit and restart QUEST for the environment changes to take effect.
128
QUEST Graphical Outputs
3
Creating
Videos
Creating Config File and video folder
1
Create a config file and edit it by selecting File / Edit Config
You will see Select Config Type dialog box.
2
Select CONFIG$LIB in the dialog box, and click OK.
You will see ../CONFIGS/ dialog box.
3
Select the config file created in the dialog box, and click OK.
129
Creating
Videos
QUEST Graphical Outputs
3
Creating Config File and Video folder
4
Enter the text :
“VIDEO=AVI
COPY$lib=..\hardcopy” in the config file created as shown:
Note:
The path set to COPY$lib variable is
where you will or have created the
folder hardcopy.
5
Click on WRITE in the dialog box. Save As dialog box appears.
Click Save Without changing the location where the file will be saved.
6
When you have finished, click Close in the text editor.
130
QUEST Graphical Outputs
3
Creating
Videos
Creating Config File and AVI folder
Note, the config variable COPY$lib points to a hardcopy folder. The hardcopy
folder must be created manually. To do this:
7
Go to the location specified in the config edit window, in this example D:/DELMIA/DR15GA/Quest/
folder, and create hardcopy folder under it, then create a folder avi inside the hardcopy folder.
Note:
8
hardcopy and avi folder name must be lowercase. A normal
QUEST installation will have the hardcopy/avi folders by default.
Append the config file created by selecting File / Append Config.
Select the created config file in the Select config Type dialog box.
The message window displays “ Config file appended”.
9
Select config Type dialog box appears again, click Cancel.
131
3
QUEST Graphical Outputs
Creating
Videos
Recording and Saving Video
1
To begin recording AVI, read the model and run the simulation.
2
As soon as the simulation starts to run click on Run / Simulation / Simulate / Full screen.
You will see Record Frames in the dialog box.
3
Choose Yes in the dialog box, and click OK.
You will see AVI Video Options dialog box in the dialog box.
4
Enter values for the required fields
in the dialog box, and click OK.
132
3
QUEST Graphical Outputs
Creating
Videos
Recording and Saving Video
You will see Video Compression dialog box.
5
Select the appropriate Codec Or “Compression Algorithm” if desired. You may leave
this setting at ‘Full Frames (Uncompressed)’ in the dialog box, and click OK .
The AVI creation for the simulated model starts. Ensure the “Simulation Time” window
displaying the clock and the “Video Compression” window are away from the capture area.
Also ensure that message windows don’t popup while AVI recording is in progress.
133
3
Creating
Videos
QUEST Graphical Outputs
Recording and Saving Video
This is the screen capture area. All windows in
this area will be captured
Move these windows away
From the screen capture area
You can stop AVI recording using the Spacebar or Esc Keys on the keyboard.
When the recording is finished, the message window displays
“Simulation Complete” and the QUEST window is restored.
The AVI is stored in the path set to COPY$lib variable in the appended config file,
in this example it is stored in D:/DELMIA/DR15GA/Quest/hardcopy/avi folder.
You can play the video in Standard Win NT installation with the help of Media Player
or even NETSCAPE 4.0
134
Creating Videos – Exercise
135
3
Exercise – Creating Videos
20 min.
Scope:
In this exercise you will create an AVI for the QUEST model
shop.mdl located in ../QUSETlib/MODELS/GIFTS
Conditions: D5 must be open.
In this exercise you will:
Set VIDEO Variable
Create Config File & AVI folder
Record & Save Video
136
Do it Yourself (1/5)
SCREEN SHOT
Starting point
Ending point
Load: QUEST
137
Do it Yourself (2/5)
Set Video Variable
You need to first set the VIDEO variable in the environmental variable config file .qenvfig.
1.
Select File / Edit Config.
2.
Choose .qenvfig in the Select Config Type dialog box, and click OK.
3.
Go to line VIDEO=NONE, and change the variable value to
VIDEO=AVI in the Config Edit Window, and click WRITE.
4.
Click Save in the save As dialog box without changing the
path. Click Yes in the dialog box to confirm the operation.
5.
Click Close in the Config Edit Window.
6.
Restart QUEST for the environment changes to take effect.
138
Do it Yourself (3/5)
Create Config File & AVI folder
The next step is to create a config file, if you have not created one & also creating
hardcopy/avi folder within the config folder. You will not use the default avi folder
within Quest folder.
1.
Create a config file Video, selecting File / Make Lib.
2.
Select File / Edit Config File to edit the Video config file.
3.
Select CONFIG$LIB in the Select Config Type dialog box, and click OK.
Choose Video in the CONFIG$LIB/ dialog box, and click OK.
4.
Enter the line:
“VIDEO=AVI
COPY$lib=..\video\hardcopy” in the Config Edit Window, and click WRITE.
5.
Click Save in the Save As dialog box without changing
the default path. Click Yes to confirm the operation.
6.
Click Close in the Config Edit Window.
7.
Select File / Append Config file to append Video.cfg.
8.
Locate the folder Video created in your system &
create folder hardcopy/avi, all in lowercase.
139
Do it Yourself (4/5)
Record & Save Video
The last step is to record a video of a simulated shop model. To do this:
1.
Read the model Shop.mdl into QUEST.
2.
Select Run / Simulation / Simulate / Run to simulate the model for 1000sec.
3.
Immediately click Full screen on the same page i.e Run / Simulation / Simulate /
4.
Click Yes in the Record Frames in the dialog box, and click OK.
5.
Enter Shop.avi for File name and enter values to other fields
as shown in the AVI Video Options dialog box, and click OK.
6.
Select Full Frames (Uncompressed) in the dialog box, and click OK.
140
Do it Yourself (2/5)
Record & Save Video
An AVI video for simulated shop model is started. The AVI creation is completed after the model
is simulated for 1000 sec. You can stop the recording by clicking the spacebar or ESC key.
The shop.avi video is located under ../video/hardcopy/avi folder. Double clicking
on the file opens up the file in media player where you view the video.
141
B
Creating
Images &
Hardcopies
Capturing Images
Creating Postscripts
Plotting Current Views
Printing and Saving 2D Charts
142
3
QUEST Graphical Outputs
Creating
Images &
Hardcopies
About Creating Images and Hardcopies
Static images of simulated model in QUEST can be captured without the use of any external
software on a windows platform. You can also have hardcopies of the simulated model in form
of postscript.
More about capturing static images & creating hardcopies can
be found in the QUEST on-line documentation.
143
Creating
Images &
Hardcopies
QUEST Graphical Outputs
3
Capturing Images
You can capture static images of the QUEST model & save them as TIFF or JPEG
image files. To do this, you must have already created a config file.
1
Have a folder called hardcopy created in the location where you want to store
the image, in this example the folder is stored in D:/DELMIA/DR15GA/quest/.
2
Create a sub folder called tiff or jpeg, depending in which format you want to
save the image, within the hardcopy folder.
3
Return to QUEST and select File / Edit Config File. Choose the required
config file in the dialog box that appears. Add the following line in the
Config Edit Window to map COPY$lib to hardcopy: COPY$lib=/DELMIA/DR15GA/output/hardcopy.
4
Click WRITE in the window to save the
modification, and then click Close.
5
Append this config file.
144
QUEST Graphical Outputs
3
Creating
Images &
Hardcopies
Capturing Images
6
Read the required model and select File / SCEEN COPY.
You will see Screen Copy dialog box.
7
Select TIFF or JPEG in the dialog box, and click OK.
You will see Image Selection dialog box.
8
Select the desired option in the dialog box, and click OK.
145
QUEST Graphical Outputs
3
Creating
Images &
Hardcopies
Capturing Images
You will see Save As dialog box.
9
Enter the file name in the dialog box and without changing the path click Save.
The message window displays “ TIFF/JPEG file completed”.
You can view the captured image from the location ../hardcopy/tiff or hardcopy/jpeg,
depending on which option you selected in the Screen Copy dialog box.
146
QUEST Graphical Outputs
3
Creating
Images &
Hardcopies
Creating Postscripts
The post script file is the format used for printing. In order to create a postscript file:
1
Have a folder called hardcopy created in the location where you want to store
the image, in this example the folder is stored in D:/DELMIA/DR15GA/quest/.
2
Create a sub folder called eps within the hardcopy folder.
3
Copy the folder "tools" from the default hardcopy folder available in quest
directory to the hardcopy folder created by you.
4
Read the required model and select File / SCREEN COPY.
You will see Screen Copy dialog box.
5
Select Postscript in the dialog box, and click OK.
147
3
Creating
Images &
Hardcopies
QUEST Graphical Outputs
Creating Postscripts
You will see Image Selection dialog box.
6
Select the desired option in the dialog box, and click OK.
You will see Save As dialog box.
7
Enter the file name in the dialog box and
without changing the path click Save.
The message window displays “ EPS file completed”.
You can view the postscript from the location ../hardcopy/eps.
148
QUEST Graphical Outputs
3
Creating
Images &
Hardcopies
Plotting Current Views
The current view of the model can be directed to a HP plotter, if the machine
is connected to a plotter. Else we can also create a hpgl format file which
can be used for plotting the view. To do this:
1
Have a folder called PLOT created in the location where you want to store
the current view, in this example the folder is stored in D:/DELMIA/DR15GA/output/.
2
Return to QUEST and select File / Edit Config File. Choose the required
config file in the dialog box that appears. Add the following line in the
Config Edit Window to have the mapping to the PLOTS folder:
PLOT$lib =/DELMIA/DR15GA/output/PLOT.
3
Read the required model and select File / Screen Copy.
4
Select Pen plotter in the Screen Copy dialog box, and click OK.
You will see Pen Plot Setup dialog box.
5
Set the required values to each fields
in the dialog box, and click OK.
The message window displays “ Plot created”.
You can view the current view from the location ../PLOTS.
149
QUEST Graphical Outputs
3
Creating
Images &
Hardcopies
Printing and Saving 2D Charts
In order to Print the 2D output charts available in the 2D world, you must have
already read or created the required model into QUEST and created the desired
chart for it, then follow the below steps to print & save the 2D chart.
1
Holding the Ctrl key, with LMB click on the required chart in the 2D window.
The chart is highlighted.
2
Select File / Print Chart.
3
The print dialog box appears. Make the required settings
for the printer in the dialog box, and click OK.
4
To save the chart, highlight the chart again & press
Ctrl C button. This gets saved onto the clip board.
5
The same can be placed into a word document by
pasting from the clip board using Ctrl v or paste.
150
3
QUEST Graphical Output – Module summary
Summary
This module described the functions used to create videos of the simulation
& saved as AVI, MPEG & tiff files. Functions to capture static images of the
model & creating hardcopies such as postscript were also discussed.
Coming Up
Hierarchical Modeling
Building Sub Models
Creating Groups
3 hour
151
1
Advanced
QUEST
Programming
2
Optimization and
Experimentation
3
5
6
Trains, Fluids and
Tools & Fixtures
4
QUEST
Graphical
Outputs
Hierarchical
Model
Final Assembly
Model & Pull Model
Module 4
Hierarchical Modeling
152
4
Hierarchical Modeling
Overview
This module describes the functions that are used to create Sub
Models and Groups. Each function is described and the details
of its parameters discussed.
Objectives
Topics in this module are:
Creating Sub Model
Creating Groups
3 hours
153
Menus and Action Buttons used in this Module
154
4
Hierarchical Modeling
Building Sub
Models
Building Sub Models
Connecting Sub Models
Setting Sub Model Logic to Source & Sink
Saving and Retrieving Sub Model
Creating Groups
Types of QUEST Defined Groups
Creating User-defined Group Type
Creating Group
Adding Elements to Groups
Reading Model & Saving Group
Assigning Group to Element
3 hours
155
A
Building Sub
Models
Building Sub Models
Connecting Sub Models
Setting Sub Model Logic
Saving and Retrieving Sub Model
156
4
Hierarchical Modeling
Building Sub
Model
About Building Sub Models
In general, large or moderately large systems consist of multiple distinct interdependent
sub-systems. It is useful to break the system into sub-systems when planning or studying
the behavior of such systems. From the simulation point of view, each of these sub-systems
can be an independent model, with Sources and Sinks representing the upstream and
downstream sub-systems. When the integrated system has to be considered as a whole, the
constituent sub-systems have to be brought to together into a single model.
In Quest, the Sub Model feature offers an easy and convenient
way to model such integrated systems. Using this feature the
models of the sub-systems, read as Sub Models, can be used
to build-up the larger system. The Sub Models, which are built
independently, can be assembled together to form the larger
model.
More about Hierarchical Modeling can be found in the QUEST
on-line documentation.
157
4
Hierarchical Modeling
Building Sub
Model
Building Sub Model
To build a sub model, you need to read the required existing
model already built in QUEST. To do this:
1
Select Advanced / Grp / Sub Model / Read.
You will see the MODELS$LIB directory dialog box.
2
Select the desired folder & the required existing model in the dialog box.
You will be prompted to select a location on grid floor.
3
Select the required location on the grid floor to position the model.
Note:
Existing Floor dimensions used may not be proportionate to the dimensions
of the Sub Model being read. Therefore on locating the Sub Model, it may not
be visible. The Floor settings may have to be modified suitably.
158
4
Hierarchical Modeling
Building Sub
Model
Building Sub Model
4
Note:
Once the selected model has been positioned on the grid,
read other required sub models by following the steps 1 to 3.
The selected model is read as a Sub Model, and is assigned a unique name.
By default it is the filename of the Sub Model, without the ‘. mdl’ extension.
If a Sub Model with the same name already exists then a default name
‘Sub_Model_1’ is given to the Sub Model. The integer index at the end of
the name is incremented to get a new name.
To modify the Sub Model:
1
Select Advanced / Grp / Sub Model / Modify.
You will see the Select Sub Model dialog box.
2
Select the required sub model in the dialog box, and click OK.
159
Hierarchical Modeling
4
Building Sub
Model
Building Sub Model
You will see the selected Sub Model dialog box.
3
Do the required modification in the dialog box, and click OK.
An existing Sub Model maybe relocated using the Advanced / Grp / Sub Model / Trn
button after it is selected using Advanced / Grp / Sub Model / Sel button. The selected
Sub Model is highlighted. If a Sub Model selection is not done, the most recently
accessed Sub Model is selected. The selected Sub Model may be rotated using the
Advanced / Grp / Sub Model / Rot button.
160
4
Hierarchical Modeling
Building Sub
Model
Building Sub Model
The Sub Model inherits the following features from the model from which it is read:
• Elements, their classes and connections between Elements and Element Classes.
• Relative Location & Orientation of Elements
• Color & Display of all Elements
• Entities like Failures, Shifts, Schedules and their association with their respective
Elements/Element Classes
• Other entities like User Interrupts, User Stats, Custom Reports, Charts, Actions
• Controllers' associations to Elements
• Model Description
Entities, except for Part Classes, that has the same name as some other existing entity will be
assigned a new, unique, name. If a Part Class with the same name already exists, a new Part Class
is not created. The attributes of the Part Class that are not same as the existing Part Class, are
over-written.
New entities can be added to the integrated model, like any normal model. These newly added
entities would belong to the integrated model and not be part of any Sub Model.
161
Hierarchical Modeling
4
Building Sub
Model
Connecting Sub Models
The Sub Models need to be connected to simulated the entire model. Connection is
made from a Sink of the upstream Sub Model to a Source of the downstream Sub
Model. To connect the Sub Models:
1
Select Advanced / Grp / Sub Model / Connection.
You will see Select Sub Model dialog box.
2
Choose the desired option in the dialog box, and click OK.
You will see Select a Sink dialog box.
3
Highlight the sink in the dialog box, and click OK.
162
Hierarchical Modeling
4
Building Sub
Model
Connecting Sub Models
4
Select Sub Model dialog box appears again. Choose the other required
model you want to connect to the already selected sub model.
You will see the Select a Source dialog box.
5
Choose the source in the dialog box, and click OK.
If you have more than two sub models read, then the procedure from
steps 2 to 5 will continue till you have connected all the sub models.
Existing connections between Sub Models can be deleted using the Advanced / Grp / Sub
Model / Disconnect button. In order to remove a Sub Model connection, the Sub Model and the
input/output connection has to be selected.
The existing connections for a selected Sub Model or for all Sub Models can be viewed using
the Advanced / Grp / Sub Model / Show Connections button.
163
Hierarchical Modeling
4
Building Sub
Model
Setting Sub Model Logic to Source & Sink
If the logic option for the Sources and Sinks of the Sub Model are default
option, they are automatically set to the Sub Model Logic options. If they are
not set, then you need to do it manually, to do this:
1
Select Model / Build / Element Class / Source
2
Click on Logics in the Source dialog box.
3
Click on Process Logic in the Logics dialog box.
You will see the Source Process Logic dialog box.
4
Choose Sub Model Source Logic in the dialog box, and click OK.
164
4
Hierarchical Modeling
Building Sub
Model
Setting Sub Model Logic to Source & Sink
5
Click OK in all open dialog box.
Repeat the same procedure to set sub model logic to the remaining
source & sink in the retrieved Sub Models manually.
Note:
A Sink with Sub Model Sink Logic will not destroy parts, but will transfer the parts to
the downstream Source. The Source with Sub Model Source Logic will not create any
Parts but will only pass the parts it receives from the upstream Sinks. Hence, the IAT,
Lotsize, Part Fractions set at the Source are ignored.
165
4
Building Sub
Model
Hierarchical Modeling
Saving and Retrieving Sub Model
The integrated model can be saved in a model file & retrieved in the same
way as that of a normal model i.e.:
1
Select File / Save.
You will see the Save As dialog box.
2
Note:
Enter the file name & set the required
library list where the model needs to be
saved in the dialog box, and click Save.
Any changes done within a Sub Model, i.e. to any Sub Model entities
are not saved to the model file. The single exception to the above rule
is Sub Model connection, Part Routing Info at a Sinks. Actually this is
information is related to the Sub Model, only for the sake of convenience,
its UI is at the Sink Element level.
166
4
Hierarchical Modeling
Building Sub
Model
Saving and Retrieving Sub Model
The main model maintains links to the Sub Models. Therefore any change in
a Sub Model is reflected in the main Model. This is not a live link; therefore
the changes will show only when the main model is loaded again.
To retrieve the model from the model file:
1
Select File / Read Model.
2
Choose the required sub model in the MODEL directory dialog box that appears.
The model along with the constituent Sub Models and their connection between
respective Sinks and Sources are retrieved. Any other additional entities and
connections added to the model are also read.
Note:
If any Sub Model is moved from its original location or is renamed, it is not be
read. This does not affect reading of rest of the Model. The Sub Models are read
with their latest changes. If any Sink or Source with Sub Model connection has
been deleted or renamed, the corresponding connection is not made.
167
Building Sub Models – Exercise
168
4
Exercise – Building Sub Models
20 min.
Scope:
In this exercise you will integrate sub models shop, sort, 3pnf & paint located
within GIFT folder in the MODEL directory.
Conditions: D5 must be open.
In this exercise you will:
Build Sub Model
Connect Sub Models
Set Sub Model Logic to Source & Sink
Run and Save Sub Model
169
Do it Yourself (1/6)
SCREEN SHOT
Starting point
Ending point
Load: QUEST
170
Do it Yourself (2/6)
Build Sub Model
1.
Select Preference / Grid.
2.
Enter 10 for Number & 15 for Spacing in the Grid dialog box, and click OK.
3.
Select Advanced / Grp / Sub Model / Read.
4.
Click on shop.mdl in the ../MODEL/GIFTS dialog box.
5.
Select a location on the grid to position the shop model as shown:
6.
Repeat steps 3 to 5 in reading sub models 3pnf, sort & paint
from the ../MODEL/GIFTS dialog box & position each sub model
referring to the ending point image in the previous slide .
171
Do it Yourself (3/6)
Connect Sub Model
1.
Select Advanced / Grp / Sub Model / Connection.
2.
Choose shop in the Select Sub Model dialog box, and click OK.
3.
Click on Sink_1 in the Select a Sink dialog box, and click OK.
4.
Select Sub Model appears again. Choose sort in the dialog box, and click OK.
5.
Choose Source1_1 in the Select a Source dialog box, and click OK.
You have connected shop(Sink_1) to sort(Source1_1).
6.
Select Sub Model dialog box appears again. Following steps 2 to 5, connect the
following sub models :
sort(Sink1_1) to paint(Source2_1) &
Sort(Sink1_1) to Sub_Model(Source3_1)
7.
When u have finished with the connection, click Cancel in the Select Sub Model
dialog box that appears.
172
Do it Yourself (4/6)
Connect Sub Model
8.
Select Advanced / Grp / Sub Model / Show Connections.
9.
Choose All Connections in the Select Connection Type dialog box, and click OK.
10.
The connection between the sub model is displayed, as shown:
173
Do it Yourself (5/6)
Set Sub Model Logic to Source & Sink
1.
Select Model / Build / Element Class / Source.
2.
Select Source1 in the Select a Source Class dialog box, and click OK.
3.
Click on Logics button in the Source dialog box.
4.
Click on Process Logic in the Logics dialog box.
5.
Select Sub Model Source Logic in the Source Process Logic
dialog box, and click OK.
6.
7.
Click OK in all open dialog boxes.
Follow the steps 1 to 6 to set Sub Model logic for Source2, Source3, Sink1 and Sink_1.
In the Sink dialog box, choose Sub Model Sink logic in the Sink Process Logic dialog box.
174
Do it Yourself (6/6)
Run & Save Sub Model
The Sub Model are simulated in the same way as that of a normal model.
1.
Select Run / Simulate / Simulation / Run.
2.
Enter 2000 for Run Time in the Run dialog box, and click OK.
Observe the part flow from shop model to sort model & then to Paint & 3 pnf model. The model is
simulated for 2000 sec before it halts & the message window reads “ Simulation completed”.
If you wish to save the Sub Model created, select File / Save Model. Enter the file name & select
the the desired location in the library list field in the Save As dialog box, and click Save.
175
B
Creating
Groups
Types of QUEST defined Groups
Creating User-defined Group Type
Creating Group
Adding Elements to Groups
Reading Model & Saving Group
Assigning Group to Element
176
4
Creating
Groups
Hierarchical Modeling
About Creating Group
Groups are collections of model elements that can be used to translate or rotate multiple
elements at a time. Groups can also be used as a destination for an AGV. There are eight
types of default groups that are defined in QUEST and are listed below. An element
group is the only group that the system provides containing elements. All the remaining
groups provided by the system only contains decision points. Route groups and part groups
are applicable to AGVs as well as to labor.
The types are:
• Any Element (element group)
• AGV Claim (claim group)
• Route Percent ( route group)
• Route Priority (route group)
• Route Cyclic (route group)
• Park Cyclic (park group)
• Park Percent (park group)
More about Groups can be found in the QUEST on-line
documentation.
177
4
Hierarchical Modeling
Creating
Groups
Types of QUEST Defined Groups
A description of each system-defined group type is provided below.
 Elements Group: An element group can contain elements and any type of decision point. It can be
used to translate or rotate a group of elements collectively and used as a way to group elements that
will be accessed from SCL using the GET_GROUP() routine.
 AGV Claim (Claim Group): This group type contains AGV decision points. A claim group is used to
set a capacity for a group of AGV decision points. A claim is a reservation made by an AGV to designate
that the AGV will be traveling to this AGV decision point in the future. A claim group is often used to
control traffic congestion at intersections.
 Route Percent (Route Group): A route percent group is used to assign percentages to each of its AGV
decision points, which are used in AGV decision point selection for routing.
 Route Priority (Route Group): A route priority group is used to create a prioritized group of AGV
decision points, which are used in AGV decision point selection for routing.
 Route Cyclic (Route Group): A route cyclic group is used to create a fixed sequence of routings to a
group of AGV decision points. This fixed sequence will repeat endlessly, hence it is described as being
cyclical.
 Park Cyclic (Park Group): A park cyclic group is used in a similar manner as a route cyclic group. That
is, it creates a fixed sequence of routings to the AGV decision points to which AGVs will move and park.
 Park Percent (Park Group): Park Percent takes samples from the included AGV decision points, based
on percentages assigned to each, in order to determine the AGV decision point to which the AGV will
move and park.
178
Creating
Groups
Hierarchical Modeling
4
Creating User-defined Group Type
Apart from the default groups that are defined in QUEST, there
is a method by which new group types can be created.
1
Select Advanced / Grp / Group Type / Cre.
You will see the Create Group Type dialog box.
This refers to the
number of these groups
that can be applied to
any element. There are
two choices: Single &
Multiple.
2
This defines the type of entities that
will be included in this group type.
There are two choices:
Any Element: Used to translate &
rotate elements.
AGV Decision Point: Used in
custom AGV or controller logic
anywhere a group of decision points
are needed for making decisions.
Enter the group type name, set the entity type &
the association in the dialog box, and click OK.
The message window reads “ Group Type <Group_name> Created”.
179
Creating
Groups
Hierarchical Modeling
4
Creating Group
To create new groups, you should have already read the required model into QUEST.
1
Select Advanced / Grp / Group / Cre.
You will see the Create Group dialog box.
There are several type of groups
that are provided with QUEST.
These types along with any userdefined group types make up the
list of possible types when a group
is created.
2
Enter the group name & select the type of group you
would want to create in the dialog box, and click OK.
180
Hierarchical Modeling
4
Creating
Groups
Creating Group
You will see the Select Element dialog box reading elements or decision point based
on the group type selected in the Create Group dialog box.
3
Select the required element/decision point in the dialog box, and click OK. To select
more than one option, hold Ctrl key & click the required elements/decision points.
The message window reads “Element <element_name> added.”
To modify the characteristics of the user-defined group, select Advanced / Grp / Group / Mod.
Select the desired group in the dialog. The selected group dialog box appears, make the
required changes confirm the changes by clicking OK button.
To delete a group created, select Advanced / Grp / Group / Del. You are prompted to indicate
the group to be deleted in the dialog.
181
Hierarchical Modeling
4
Creating
Groups
Adding Elements to Group
The other method to add elements/decision point to the group already created:
1
Select Advanced / Grp / Group / Add.
If you have more than one group created, you will see Select Group dialog box.
2
Select the required group in the dialog box, and click OK.
182
Hierarchical Modeling
4
Creating
Groups
Adding Elements to Group
You will see Select Element dialog box. If you have created just
one group, you will see this dialog box when you click on Add button.
3
Select the required elements/decision point in the dialog box, and click OK.
The message window reads “Element <element_name> added.”
To view & confirm if all the required elements/decision points are added to the right groups,
select Advanced / Grp / Group / Show. Select the desired group in the dialog. The message
window reads the list of elements added to the selected group.
To remove elements from the selected group, select Advanced / Grp / Group / Remove.
You are prompted to indicate the required group in the dialog. Click on the required elements
to be removed from the selected group.
183
Hierarchical Modeling
4
Creating
Groups
Reading Model and Saving Group
The two buttons Read and Save allows you to retrieve a model & save a
selected group as sub model. To retrieve a model:
1
Select Advanced / Grp / Group / Read.
You will see the ../MODEL directory dialog box.
2
Select the required model in the dialog box.
The selected model is retrieved & positioned on the grid floor.
184
Hierarchical Modeling
4
Creating
Groups
Reading Model and Saving Group
You can save a group provided the selected group type is Sub Model.
To save a group:
1
Select Advanced / Grp / Group / Save.
If you have more than one group of Sub Model type,
you will see Select Group dialog box.
2
Select the required group in the dialog box, and click OK.
185
Hierarchical Modeling
4
Creating
Groups
Reading Model and Saving Group
You will see Select Group Entities to Save dialog box. If you have just one group of
Sub Model type, you will see this dialog box when you have clicked Save button.
3
Click on the desired button in the dialog box.
You will see the Select Element dialog box reading contents
based on the selected option in the previous step.
4
The elements added to the selected group are highlighted.
Select or deselect elements in the dialog box, and click OK.
186
Hierarchical Modeling
4
Creating
Groups
Reading Model and Saving Group
5
Click OK in the Select Group Entities to Save dialog.
You will see the Save As dialog box.
6
Enter the file name set the library list to the
desired option in the dialog box, and click Save.
The sub-model group is saved as .mdl file in the MODEL directory.
When this sub-model group is retrieved, clicking the Read button, only the selected
elements saved in this group are retrieved.
187
Hierarchical Modeling
4
Creating
Groups
Assigning Group to Element
To assign groups to a specific element, you must have already created a group of
a specific type. There are two methods of assigning group to a specific element.
Both the methods are explained below
Method 1: Using Assign Command under Advanced / Grp / Apply Group.
1
Select Advanced / Grp / Apply Group Type / Assign.
You will see the Group Entity Type dialog box.
2
Choose the required option in the dialog box, and click OK.
3
You will see the Select Element dialog box. Select the
element in the dialog box to be added to the group.
188
Hierarchical Modeling
4
Creating
Groups
Assigning Group to Element
You will see the Group Entity Type dialog box.
4
Select the type of group you want to create in the dialog box, and click OK.
The message window reads “ Group <Group_name> added to Element <element_name>”
5
Select Group Type dialog appears again. Again select a group type, if you want to add
the selected element to another group. If not click Cancel in the dialog box.
Note:
If you select a group type for which a group is not created,
then message window reads “No group of this type is created”.
189
Hierarchical Modeling
4
Creating
Groups
Assigning Group to Element
Method 2: Using Part Destination Command (applicable only for Decision Points).
1
Select Model / MHS / DEC Point / Part Destination.
You will see the Select Elements dialog box reading all decision points in the model.
2
Select the required elements and confirm the selection
by clicking on OK button in the dialog box
You will see the Select Part Destination Options dialog box.
3
Click on Add button under Route Group Based Destination in the dialog box.
190
Hierarchical Modeling
4
Creating
Groups
Assigning Group to Element
You will see Select a AGV Route Group dialog box, if you have created more than one group.
4
Select the desired group in the dialog box, and click OK.
5
Select a AGV Route Group dialog box appears again. Select any other group
if the selected element is to be added to other groups. If not, click Cancel.
The message window reads “Groups <groups_name> is added to the Element <element_name>.”
6
Click OK in the Select Part Destination Option dialog.
191
Creating Groups – Exercise
192
4
Exercise – Creating Groups
20 min.
Scope:
In this exercise you will create groups for the model created by BCL macro reading the
file Build_Cyclic_Model.bcl, which creates a model similar to cyclic model located in
../MODEL/GIFTS .
Conditions: D5 must be open.
The Build_Cyclic_Model.bcl file given to you along with this training material
should be placed in ../QUESTlib/BCLMACROS in your system.
In this exercise you will:
Read Model
Create Group
Assign Group
193
Do it Yourself (1/3)
SCREEN SHOT
Starting point
Ending point
Load: QUEST
194
Do it Yourself (2/3)
Read Model
1.
Create BCL Macro, naming the macro Cyclic Model & attach BCL macro file
Build_Cyclic_Model.bcl to the macro.
2.
Play the macro. The model shown in the ending point is created on the grid floor.
Create Group
1.
Select Advanced / Grp / Group / Cre.
2.
Enter AgvRtCycGrp for Name and set Type to AGV Route Cyclic
in the Create Group dialog box, and click OK.
3.
Select elements dec31_1, dec32_1, and dec3_1
in the Select Element dialog box, and click OK.
The message window reads “ Elements dec31_1, dec32_1, dec3_1 added to Group <AgvRtCycGrp>.”
195
Do it Yourself (3/3)
Assign Group
1.
Select Build / MHS / Dec Point / Part Destination.
2.
Select element dec2_1in the Select an AGV/Labor
Dec Point dialog box, and click OK.
3.
Click on Add under Route Group Based Destination
in the Select Part Destination Options dialog box.
The message window reads “ Group
<AgvRtCycGrp> added in Element dec2.”
Run the model. Observe that the parts will be routed to Machine2_1, Machine3_1 and
Machine4_1 alternately (cyclically). The fixed routing has been overridden by the use
of cyclic routing.
196
4
Hierarchical Modeling – Module summary
Summary
This module described the functions that are used to create, connect and run
Sub Models. Functions used to create Groups, method to create user-defined
group type and saving groups as sub models where also described.
Coming Up
Tools & Fixtures, Fluids and Trains
Modeling Tools & Fixtures
Modeling Fluids
Modeling Trains
3 hour
197
1
Advanced
QUEST
Programming
2
Optimization and
Experimentation
3
5
6
Trains, Fluids and
Tools & Fixtures
4
QUEST
Graphical
Outputs
Hierarchical
Model
Final Assembly
Model & Pull Model
Module 5
Trains, Fluids and
Tools & Fixtures
198
5
Trains, Fluids and Tools & Fixtures
Overview
This module discusses the concepts of tools & fixtures, fluids and
trains in QUEST. Each of the new tools & fixtures, fluid and trains
entities are described and the details of its parameter discussed. An
explanation of how theses parameters may be used to model physical
system is provided.
It is assumed that user is now familiar with the basic of the QUEST
interface and with the concept of elements, classes, parts, and logics.
Objectives
Topics in this module are:
Modeling Trains
Creating Fluids
Modeling Tools & Fixtures
3 hours
199
Menus and Action Buttons used in this Module
200
5
Trains, Fluids and Tools & Fixtures
Modeling
Trains
Defining Train Leader
Defining Train Followers
Assigning Followers to Leader
Setting Train Logics to AGV Class and Controller
Stopping Behavior of Trains
SCL for Trains
Engaging and Disengaging Followers
SCL for Engage and Disengage Followers
Creating Fluid
Model
Modeling
Tools &
Fixtures
Creating Fluid Class
Creating Fluid Element Class
Defining & Associating Fluid Cycle Process
Creating Fluid History
Connecting Fluid Element
Setting Optimization
Running & Saving Optimization
3 hours
201
A
Modeling
Trains
Defining Train Leader
Defining Train Followers
Assigning Followers to Leader
Setting Train Logics to AGV Class and Controller
Stopping Behavior of Trains
SCL for Trains
Engaging and Disengaging Followers
SCL for Engage and Disengage Followers
202
5
Trains, Fluids and Tools & Fixtures
Modeling
Trains
About Modeling Trains
A Train is a group of vehicles moving together in a single continuous chain. The significant
characteristics of a train are:
• While the train moves, one of these vehicles, i.e. the engine, tractor or, in general, the leader,
drives all the other vehicles i.e. the wagons, or, in general, the followers, in the train.
• Each of the vehicles in a train maintains the same distance relative to all the other vehicles
in the train at all times.
Trains can be modeled as AGVs, by assigning one or more
followers to an AGV, which is the leader. When a set of
followers is assigned to an AGV, all these AGVs, i.e. followers
follow the motion of the leader.
The followers do not communicate with the controller directly,
but only through the leader. Therefore, appropriate AGV and
Controller logics have to be assigned to the Train AGVs and
its controller to enable this communication.
More about trains can be found in the QUEST on-line
documentation.
203
Trains, Fluids and Tools & Fixtures
5
Modeling
Trains
Defining Train Leader
You must have already created the AGV segment & other required element class for
the required model. Any AGV Class, to which the followers are assigned, is a leader
with Follower attribute set to “No”.
1
Select Model / MHS / MHS Element / AGV.
You will see AGV dialog box.
2
Enter the class name, stopping space, speed and define
required attributes in the dialog box, and click OK.
The message window prompts “Select a Segment location
to place AGV”
3
Select a location on the required AGV segment near the
source to position the AGV.
204
Trains, Fluids and Tools & Fixtures
5
Modeling
Trains
Defining Train Followers
Once you have created the leader, the next step is to create followers for that leader.
Follower is an Element class with the Follower attribute set to Yes.
1
Select Model / MHS / MHS Element / AGV.
You will see the AGV dialog box.
2
Set Follower to Yes, Follower Capacity Mode to “From Class”,
or From Leader” and define other desired attribute in the
dialog box, and click OK.
This attributes settings for a follower
are acquired from it’s leader to which
it is assigned. Hence these attributes
are disabled.
This attribute defines train's
capacity at the leader, which
determines if the capacity of each
follower is to be inherited from the
Leader’s Class or from the
Follower’s class. It has two options:
• From Class [default] and
• From Leader
205
Trains, Fluids and Tools & Fixtures
5
Modeling
Trains
Defining Train Followers
3
Position the AGVs on the AGV segment created on the grid floor behind the leader.
Note:
When an AGV Element Class with Follower attribute set to YES:
• An AGV follower is not associated to an AGV controller; it is linked only to
the leader in the train. The leader in turn communicates the AGV Controller
and vice versa.
• It is not possible to change the Class of an AGV that belongs to a
Follower AGV Class to that of a non-Follower AGV Class and vice-versa.
• The AGVs belonging to a class of followers cannot have followers,
i.e. they cannot be leaders.
• Neither Shift Schedules nor Failures can be assigned to the Class
through Model / Aux / Shifts / Assoc and Model / Aux / Failures / Assoc
respectively and also disabled in the Follower dialog. Prior shifts & failures
assigned to element are removed after confirmation.
206
5
Trains, Fluids and Tools & Fixtures
Modeling
Trains
Assigning Followers to Leader
There are some restrictions in creating valid trains:
1.
2.
The basic definition of train is that the AGVs in the train should form
a continuous and a single chain.
•
Continuous means that there should not be any other AGV that
does not belong to the train in between any two AGVs of a train.
•
Single means that the chain of AGVs should have no branches. It is valid to have
two consecutive AGVs in the train on different segments that are directly or
indirectly connected. But at the same time there cannot be another AGV in the train
that is on another path segment that is connected through some other input.
A Train leader has to be at the head of the train.
The model does not run if any of the two conditions are violated, though they
can be violated during their creation i.e.; assigning followers to a leader.
207
Trains, Fluids and Tools & Fixtures
5
Modeling
Trains
Assigning Followers to Leader
Creating a valid train is completed by assigning followers to an AGV i.e. leader.
To assign followers to a leader:
1
Select Model / Build / Element / Modify (or Model / MHS / Element / Modify) .
You will see Select Element dialog box.
2
Select an AGV Element that does not belong to a follower AGV Class and is
not already been assigned as a follower to some other leader, and click OK.
You will see the Modify Element dialog box.
3
Click on Followers button in the dialog box.
208
Trains, Fluids and Tools & Fixtures
5
Modeling
Trains
Assigning Followers to Leader
You will see Select Element dialog box.
4
Select the required AGV’s of the follower class to be assigned
to the selected leader in the dialog box, and click OK.
To select more than one AGV’s in the dialog, hold the Ctrl key and select the required AGV’s.
The message window reads “<AGV_name> AGV process Logic set to <Train AGV Logic>”.
This completes the process of creating trains in QUEST.
Note:
When a train is created, there is no physical link between the consecutive
AGVs in the train, i.e. no “link” is visible in the model, but these AGVs are
internally linked. However, the Properties of the any of the followers in the
train shows its leader and that of the leader shows all its followers.
209
5
Trains, Fluids and Tools & Fixtures
Modeling
Trains
Setting Train Logics to AGV Class and Controller
A Train system, Leader, Follower and Controllers, require specific logic settings. If the
default settings of the AGV and Controller are not changed, the train related logics are
automatically set.
These settings are:
• Follower Process Logic — Train AGV Logic, is set when the AGV Class follower
attribute is set.
• Leader Process Logic — Train AGV Logic, is set when Followers are attached to the
Leader.
• Controller Process Logic — Train AGV Ctlr Logic,
• Controller AGV Selection — Train Closest AGV,
• Controller AGV Destination — Train AGV Closest Part Destination.
The Controller’s logics are set when any of the AGVs associated to the controller is made
a leader by assigning followers to it.
These settings can be crossed checked under Logics in the respective dialog box.
210
5
Trains, Fluids and Tools & Fixtures
Modeling
Trains
Stopping Behavior of Trains
When a train stops at a Decision Point, there are two options:
• Leader stops at the Decision Point
• Follower required to load/unload stops at the Decision Point.
The Train Stop Mode setting at the Decision Point defines this behavior.
This mode has two options:
Follower At Dec. In this mode the specific follower that needs to
Load/Unload at the Dec Point stops at the Dec Point. After all the
commands for this Follower at this Dec Point are complete, the
other commands are considered.
Leader At Dec. In this mode the Train Leader stops at the Dec Point
and then all the Load and Unload commands for all the AGVs in the
Train at the Dec Point are executed. The followers will do the
load/unload considering the Dec as Logical Dec.
211
5
Trains, Fluids and Tools & Fixtures
Modeling
Trains
SCL for Trains
Certain Element level SCL Inquiry fields are available to access the followers of a train,
given its Leader and to get the Leader of any Follower in a train:
• Followers[ ]: Returns the handle of the follower for the specified index of the leader.
It returns the leader itself if the index is 0.
• Num_Followers: Returns the number of followers assigned to the train’s Leader
• Leader: Returns the handle to the leader of any follower AGV in a Train. It returns NULL
for Train Leaders and other AGVs that are not part of a Train
Besides there are certain AGV related SCL routines, which given the leader, also
consider the followers associated to it.
• IS_AGV_CMD_PENDING(): This routine accepts an AGV and a Decision Point handle as
arguments. It checks if there are any pending commands for the specified AGV and its
followers, if any, at the specified Decision Point.
• IS_AGV_CMD_WAITING(): This routine accepts an AGV handle as an argument. It checks
if there are any waiting commands for the specified leader and it’s followers.
• AGV_OK_TO_DEPART(): This routine accepts an AGV and a Decision Point handle as
arguments. It checks if the train can depart the Decision Point based on the Parts loaded
on the train and the minimum part requirements specified at the Decision Point.
Since the leader issues commands to the Followers, there is a SCL routine that can be
used by the follower to communicate to its leader.
212
Trains, Fluids and Tools & Fixtures
5
Modeling
Trains
Engaging and Disengaging Followers
During the course of a simulation run, followers may need to be disengaged or new
followers may need to be engaged to the leader. This procedure to engage & disengage
the followers at required AGV decision point is explained in following steps:
1
Select Model / Build / Element / Modify (or Model / MHS / Element / Modify) .
You will see Select Element dialog box.
2
Choose the required decision point in the dialog box, and click OK.
213
Trains, Fluids and Tools & Fixtures
5
Modeling
Trains
Engaging and Disengaging Followers
You will see Modify Element dialog box.
3
Click on Train Engage Info in the dialog box.
214
Modeling
Trains
Trains, Fluids and Tools & Fixtures
5
Engaging and Disengaging Followers
You will see Train Engage Info dialog box.
This is enabled when Engage
Mode is set to Engage Followers
& has two options:
None [default] –The followers are
engaged at their current location
irrespective of the Engage Space.
Move Followers – The followers
are moved forward or in reverse
direction to maintain the Engage
Space
Selecting this button will enable the
selection of any other existing AGV
Dec Point for engaging followers
when the “Follower Selection” popup
option is either, “AGVs Logically At
Dec” or “AGVs At Reference Dec” in
the selected AGV decision point
dialog under Logics.
4
The Engage Mode has three
options:
None [Default] – This is neither
both.
Disengage Followers – All the
followers of a Train are
disengaged at this Dec Point.
Engage Followers – Engages
selected followers to a train
leader stopping at a particular
Dec Point.
Set the Engage mode to Engage followers / Disengage Followers
in the dialog box, and click OK.
215
Trains, Fluids and Tools & Fixtures
5
Modeling
Trains
Engaging and Disengaging Followers
4
Click OK in all open dialog box and click Cancel in the Select Element dialog box.
Note:
1) An AGV Dec Point’s Train Engage Mode can either be to Engage or Disengage
Followers, but a Leader cannot engage and disengage followers from the same point.
2) When the mode 'Move Followers' is used the engage takes time required
to move(s). All the followers move to the desired location simultaneously.
3)Followers moving to engage are not linked to a Controller. The Leader
issues them move commands.
The followers to be engaged are selected by the “Follower Selection” Popup
at the AGV Dec Point. To do this:
1
Select Model / MHS / Decision Point / AGV.
2
Select the desired decision point in the Select AGV Decision Point Class dialog box.
3
Click on Logics button in the AGV_Dec_Pt dialog box.
216
Trains, Fluids and Tools & Fixtures
5
Modeling
Trains
Engaging and Disengaging Followers
You will see Logics dialog box.
4
Click on Follower Selection dialog box in the dialog box.
You will see Follower Selection dialog box.
This option selects all the
AGVs existing logically at
the Reference Dec.
This option will select all
the AGVs behind the leader
to Reference Dec.
5
Choose the required option in the dialog box, and click OK.
6
Click OK in all open dialog box.
217
5
Trains, Fluids and Tools & Fixtures
Modeling
Trains
SCL for Engage and Disengage Followers
In order to engage or disengage followers during a run, the two SCL routines,
Engage_Followers & Disengage_Followers, can be used. These routines can be
called from AGV, AGV Controller or AGV Dec Point Logics. The SCL syntax for
engage follower & disengage follower is mentioned below.
Engage Follower:
The SCL routine, Engage_Followers(), engages the specified Followers to the Leader
so as to form a Train. If the Leader already has Followers, the Followers specified in
the routine are added to the existing list of Followers.
Syntax: Engage_Followers (the_leader, follower1[, follower2]... )
or
Engage_Followers (the_leader, follower_list)
Note: 1) The first argument is the Train Leader. Remaining are followers.
The followers can be specified as a comma, separated list or as an SCL List.
2) The followers should belong to a follower AGV Class, while Leader
should be an AGV of non-Follower Class. The specified followers
should not belong to another train.
218
5
Trains, Fluids and Tools & Fixtures
Modeling
Trains
SCL for Engaging and Disengaging Followers
Disengage Follower:
The routine, Disengage_Followers(), disengages the specified number of followers
from the AGV Train Leader, beginning from the end of the train.
Syntax: Disengage_Followers (the_leader[, num_followers | ALL])
Note: 1) The first argument is the train leader.
2) The second argument, optional, is the number of followers to be disengaged.
If not specified, it means ALL. The second argument if specified should not
be greater than the existing number of followers.
3) After disengaging, the Followers remain in their current positions and are free
to move independently or can be re-engaged or engaged to another leader.
219
Modeling Trains – Exercise
220
5
Exercise – Modeling Trains
15 min.
Scope: In this exercise you will create a basic train model.
Conditions: D5 must be open.
In this exercise you will:
Define Train Leader
Define Train Follower
Assign Follower to Leader
Engage & Disengage Followers
221
Do it Yourself (1/7)
SCREEN SHOT
Starting point
Ending point
Load: QUEST
222
Do it Yourself (2/7)
Define Train Leader
1.
Read the cyclic model from ../MODELS/GIFTS directory.
Delete only the AGV class & controller created in this model.
2.
Select Model / MHS / Controller / AGV.
3.
Enter Controller_1 for Class Name in the AGV_Controller1
dialog box, and click OK.
4.
Position the Controller on the grid floor referring to the image
shown in the previous step.
5.
Select Model / MHS / MHS Element / AGV.
6.
Enter the values in the required fields in the AGV dialog box as
shown, and click OK.
7.
Position the AGV1 at decision point dec1 on the grid floor.
223
Do it Yourself (3/7)
Define Train Follower
1.
Select Model / MHS / MHS Element / AGV.
2.
Select New in the Select AGV Class dialog box.
3.
Set Follower to Yes in the AGV dialog box, and click Part Capacity.
4.
Enter 0 for Value in the Capacity dialog box, and click OK.
1.
Click OK in the AGV dialog box.
2.
Position AGV2 behind the AGV1 as shown in the ending
point image at the beginning of the exercise.
Note:
Part Capacity attribute defines the combination from the class part capacity table
that is applicable to the AGV and the capacity of the AGV defined by that combination.
A value zero entered signifies that the AGV cannot carry any parts, & any
224
Do it Yourself (4/7)
Assign Follower to Leader
1.
Select Model / MHS / Element / Modify.
2.
Select AGV1_1 in the Select Element dialog box, and click OK.
3.
Click on Follower button in the Modify Element dialog box.
4.
Select AGV2_1 in the Select Element dialog box, and click OK.
The message window reads the following:
5.
Click OK in the Modify Element & click Cancel in the Select Element dialog box.
6.
Simulate the model for 1000sec. Observe the movement of the follower moving along
with the leader. Also the follower will not carry any part. For the follower to carry part,
change the value of Part capacity to 1 & simulate the model to observe the change.
225
Do it Yourself (5/7)
Engage and Disengage Follower
A simple case where a Leader leaves followers at one point and then engages them
at some other point is modeled through the user interface for the AGV Dec Point in
following steps:
1.
Select Model / MHS / Element / Modify.
2.
Select decision point dec2 in the Select an Element dialog box.
3.
Click on Train Engage Info button in the Modify Element dialog.
4.
Set Engage Mode to Disengage Followers in the
Train Engage Info dialog box, and click OK.
226
Do it Yourself (6/7)
Engage and Disengage Follower
6.
Click OK in the Modify Element and choose dec4 in the
Select Element dialog box, and click OK.
7.
Click Train Engage Info in the Modify Element dialog box.
8.
Set Engage Mode to Engage Followers and Engage Move Mode
to Move Followers in the Train Engage Info dialog box, and click Reference
Info.
9.
Select dec2 in the Select an AGV Decision Point dialog box, and click OK.
10. Click OK in the Modify Element dialog box, and click Cancel in the Select Element dialog box.
227
Do it Yourself (7/7)
Engage and Disengage Follower
11. Select Model / MHS / Dec Point / AGV
12. Select dec3 in the Select an AGV Dec Point dialog box.
13. Click on Logics in the AGV_Dec_Pt dialog box.
14. Click Followers Selection in the Logics dialog box.
15. Choose AGVs Logically At Dec in the Followers Selection
dialog box, and click OK.
16. Click OK in all open dialog boxes.
17. Simulate the model again for 1000sec. Observe the movement of the follower & leader.
The follower gets disengaged from the leader on arriving at dec2 & engages itself to the
leader at dec3.
228
B
Modeling
Fluids
Creating Fluid Class
Creating Fluid Element Class
Defining & Associating Fluid Cycle Process
Connecting Fluid Elements
Creating Fluid History
229
5
Trains, Fluids and Tools & Fixtures
Modeling
Fluids
About Modeling Fluids
A fluid may be a liquid, vapor, or gas. Fluid flow is inherently continuous in nature. This is
modeled in QUEST similar to the discrete parts (material) movement through the system of
connected resources. In discrete part simulation, the part is created, destroyed & moved by
MHS. and processed at machine. The similar basic unit in fluid flow modeling is the fluid that
is collective unit and has no individual identity.
The continuous flow of fluid is modeled by identifying the
discrete flow rate changes that happen at different resources.
Flow rate change can be observed when fluids are created,
destroyed, produced and transferred. Flow rate happening as
a result of various activities are the main inputs for the fluid
flow modeling.
More about Fluids can be found in the QUEST on-line
documentation.
230
Trains, Fluids and Tools & Fixtures
5
Modeling
Fluids
Creating Fluid Class
The first step in modeling fluids is to create a fluid class.
1
Select Model / Fluids / Fluids Class / Create/Modify.
You will see Fluid Class dialog box.
This is maximum flow
rate by which this fluid
class can flow
between resources.
2
Enter the name, the max flow rate & define the required
attributes in the dialog box, and click OK.
The message window prompts “Fluid <Fluid_Name> created.”
231
5
Trains, Fluids and Tools & Fixtures
Modeling
Fluids
Creating Fluid Element Class
During the process of creating the elements described in this chapter, many common
functions are used, one being element geometry, which is described below.
Element Geometry: This function allows users to set the display parameters
of the element such as geometry, color, stack axis, etc.
Selecting the Display button will present the Display dialog box shown below:
This defines the current
fluid point for the
element. All changes
made in the Fluid point
Info button apply to
current fluid point.
This is the value
displayed for dynamic
fluid annotation. This
field is used only when
the animation method
is set to “Annotation” or
“Both”.
The location of the fluids inside a
fluid element is based on the fluid
point of that element. This attribute
defines the number of fluid points on
the element.
This field allows users to set the method
for visually representing the fluids in the
current element. It has four options:
• None: No fluid animation will be seen.
• Fluid Point: Animates the fluid at the
fluid points in the element without any
annotation.
• Annotation: Provides a dynamic text
visualization of the current contents of the
fluids in the element.
• Both: Uses both fluid point and
annotation for fluid animation.
232
5
Modeling
Fluids
Trains, Fluids and Tools & Fixtures
Creating Fluid Element Class
The buttons under Model / Fluid / Fluid Element Class title bar allow the
creation of fluid elements and defines the different services that those
elements provide to the fluid flowing through them.
The fluid resources that can be created are:
Fluid Source:
This resource is used to create fluids with specified volumes at specified inter-arrival times. This
similar to the regular source, but producing only fluid class. Selecting the Fluid Source button will
present the Fluid Source dialog box as shown:
This sets the maximum
quantity of fluid that the
This field sets the mode of fluid creation in
fluid source can produce
the source to one of the two options:
during a single run of the
- Flow Rate: Fluid is produced at the rate
model after which it
specified as the lotsize, for the duration
ceases fluid creation.
specified as the IAT.
- Quantity: The value specified as the lotsize
is the quantity of fluid that is created
instantaneously at the sampled IAT.
This is the maximum
time that every fluid
created in the source
must stay in the source
before it can be avaiable
for routing.
233
5
Trains, Fluids and Tools & Fixtures
Modeling
Fluids
Creating Fluid Element Class
Tank:
Tanks are used to represents the locations where fluids are stored.
They are analogous to the buffers that are used with parts.
Selecting the Tank button will present the Tank dialog box.
Processor:
Processors are capable
of performing more than
one process, although
not simultaneously. This
sets the total number of
process associated with
the processor class.
Processors are the special elements that can handle both discrete
parts and fluids. They are used represent the elements in a system
that are responsible for processing or carrying out work on fluids.
Selecting the Processor button will present the Processor dialog box.
234
5
Trains, Fluids and Tools & Fixtures
Modeling
Fluids
Creating Fluid Element Class
Fluid Sink:
The primary purpose of a fluid sink is to destroy fluids, therefore, it has inputs but no outputs.
Once the fluids has completed its processing in the model, it is removed from the model through
the fluid. Selecting the Fluid Sink button will present the Fluid Sink dialog box.
Pipe:
This defines the
time the fluid
takes for it to flow
through the pipe.
The fluid pipe is an element that may be used to transport fluids
between elements. Pipes for fluids are analogous to Conveyors
for normal parts. Selecting Pipe button will present Pipe dialog
box as shown:
235
5
Trains, Fluids and Tools & Fixtures
Modeling
Fluids
Creating Fluid Element Class
The procedure to create fluid elements in the world (grid floor) is as follows:
1
Select Model / Fluids / Fluid Element Class / Select the required element.
You will see the selected fluid element dialog box.
2
Define the required attributes in the dialog box.
Click Ok to confirm the information entered in the dialog box.
You will prompted to locate the element on the grid floor.
3
Click at the required location in the grid floor (World) to position the element.
236
Trains, Fluids and Tools & Fixtures
5
Modeling
Fluids
Defining & Associating Fluid Cycle Process
The fluid cycle process defines the various process requirements, the time
required to do the process, and the products produced as a result of the process.
The requirements could be parts, fluids, AGVs, or labor.
In a generic fluid process, while the fluid is flowing in (as part of the requirement)
some processing can happen (applying cycle time) and also new fluids can be
produced.
The main three phases involved are the:
• Acceptance Phase
• Cycle Phase
• Production Phase
The procedure to define the fluid cycle process and associate them
to processor are mentioned below.
1
Select Model / Fluids / Fluid Cycle Process / Cre/Mod.
You will see Select Fluid Cycle Process dialog box.
2
Select New in the dialog box, and click OK.
237
Trains, Fluids and Tools & Fixtures
5
Modeling
Fluids
Defining & Associating Fluid Cycle Process
You will see Select Fluid Cycle Process dialog box.
This allows you to set
the general parameters
governing that start &
end conditions of the
cycle phase
3
This sets the fluid
products of the
cycle process.
Enter the name, define cycle time and other required attributes in the dialog box, and click OK.
The message window reads “ Fluid Cycle Process <Fluid_Process_name> created.”
238
Trains, Fluids and Tools & Fixtures
5
Modeling
Fluids
Defining & Associating Fluid Cycle Process
To associate the fluid cycle process to processor:
4
Select Model / Fluids / Fluid Cycle Process / Assoc.
If the model consists of more than one processors,
you will see Select Element with Process Class dialog box.
5
Choose the required element in the dialog box, and click OK.
You will see Process assignment dialog box. Also, if there is only
one processor you will see this dialog on clicking the Assoc button.
6
Choose the desired process to be associated with the
selected processor in the dialog box, and click OK.
This completes the process of creating & associating the fluid cycle process to processors.
239
Trains, Fluids and Tools & Fixtures
5
Modeling
Fluids
Connecting Fluids Elements
The next step is to make the fluid connections that describe the fluid flow between
resources. In addition to connections, the fluid flow rate between resources can also
be specified at each connection. Each connection can be considered as an opening
with a slot or a valve. To do this:
1
Select Model / Fluids / Connections / Connect.
You will see Select an Output Fluid Element dialog box.
2
Choose the required element in the dialog box, and click OK.
You will see Fluid Connection Info dialog box.
This is the maximum
possible flow rate
through this
connection when the
slot (value) is
opened fully.
This is the initial slot opening value at
the connection. This is specified in
terms of percentage. 100% is fully open
& zero is fully closed.
240
Trains, Fluids and Tools & Fixtures
5
Modeling
Fluids
Connecting Fluids Elements
3
Enter the values in the required field in the dialog box, and click OK.
You will see Select an Input Fluid Element dialog box.
4
Choose the required element in the dialog box, and click OK.
The two element are connected. Repeat the procedure to connect the remaining elements
in the model. To view all the connection select Model / Fluid / Connection / Show.
241
Modeling
Fluids
Trains, Fluids and Tools & Fixtures
5
Creating Fluid History
Fluid history may be collected for fluid elements to keep track of changes in the
fluids during the element's operations during a simulation run. Fluid history may be
collected for a given element over a specific duration, and may either be viewed
dynamically during the simulation run or after the simulation run is completed. 2D
charts are used to create the fluid history charts. To Create fluid history:
1
Select Model / Fluids / Fluid History / Cre/Mod.
2
Select the required element for which history is required
to be created in the Select a Fluid Element dialog box.
You will see Fluid History dialog box.
This specifies the
data to be plotted as
the fluid history.
This permits the selection
of a different fluid element
to be associated with the
fluid history.
This creates a time series
2D chart of the history data
that was collected during
the simulation run
If it is set to Yes, a time
series chart is created and
updated dynamically
during the simulation run.
These two field specifies
the simulation clock to
start & stop collecting the
fluid history.
This permits the selection of fluid
class whose attributes is to be
collected as history data during the
simulation run. fluid history.
242
Trains, Fluids and Tools & Fixtures
5
Modeling
Fluids
Creating Fluid History
3
Define the desired attributes in the dialog box as per the
required details to be displayed on the chart, and click OK.
4
Once you have simulated the model, select Model / Fluids / Fluid History / Cre/Mod.
5
Select the fluid history just created & in the fluid History dialog box, click the Chart button.
You will see Fluid History Chart dialog box.
6
Click in the dialog box to place the chart & it’s
legend.
The chart is created in the window as shown.
Note:
Currently, fluid history may be created for a single run of the model only and
are not applicable across multiple runs. Also, the fluid history created for a
simulation run cannot be saved with the model.
243
Modeling Fluids – Exercise
244
5
Exercise – Modeling Trains
15 min.
Scope:
In this exercise you will create a basic fluid model with fluids created at fluid source, processed
at processor & been destroyed at fluid sink.
Conditions: D5 must be open.
In this exercise you will:
Setup
Create Fluid
Create Fluid Source
Create Tank
Create Processor
Create Fluid Sink
Create Pipe
Create Extruded Pipe
Connect Fluid Elements
Save and Run Fluid Model
245
Do it Yourself (1/13)
SCREEN SHOT
Starting point
Ending point
Load: QUEST
246
Do it Yourself (2/13)
Set Up
1.
Select Pref / Preference / Environment / Units.
2.
Set Volume to Liter, Volume Flow Rate to Liter/Second and define the
remaining fields as shown in the Set Units dialog box, and click OK.
3.
In the same page click on Grid.
4.
Set Display to Floor Only in the Grid dialog box, and click OK.
Create Fluid Class
1.
Select Model / Fluid / Fluid Class / Create/Modify.
2.
Click OK to confirm the default values in the Fluid Class dialog box.
The message window reads “Fluid Class <Fluid1> created.”
247
Do it Yourself (3/13)
Create Fluid Source
1.
Select Model / Fluid / Fluid Element / Fluid Source.
2.
Enter 600 for Max Fluid Quantity, 20 for Fluid Min Residence Time
in the Fluid_Source dialog box, and click Lotsize.
3.
Choose Constant in the Distribution dialog box, and click OK.
4.
Enter 1.5 for Value in the Constant
dialog box, and click OK.
5.
Click on Display & set Animation Method attribute to Both in the Display dialog box.
6.
Click OK in the Fluid_Source dialog box.
The message window reads “Fluid Source <Fluid_source1> created.”
7.
Position Fluid_Source1 on the grid at a location referring to the Ending Point
image at the beginning of the exercise.
248
Do it Yourself (4/13)
Create Tank
1.
Select Model / Fluid / Fluid Element / Tank.
2.
Set Part Capacity Type to Volume in the Tank dialog box,
and click Fluid Capacity.
3.
Enter 100 for Fluid Capacity in the Fluid Capacity dialog box, and click OK.
4.
Click on Display in the Tank dialog box and set Animation
Method attribute to Both in the Display dialog box.
5.
Click OK in the Tank dialog box.
The message window reads “Tank <Tank1> created.
Select a location on Grid floor.”
6.
Position Tank1 at a location on the grid referring to the image at the
beginning of the exercise.
Note:
Animation Method attribute in the Display dialog box for each of the
element is set to “Both”, so that you can view the volume of fluids in
each element during the simulation run.
249
Do it Yourself (5/13)
Create Processor
1.
Select Model / Fluid / Fluid Element / Processor.
2.
Set Part Capacity Type to Volume in the Processor dialog box,
and click Fluid Capacity.
3.
Enter 50 for Fluid Capacity in the Fluid Capacity dialog box,
and click OK.
4.
Click on Cycle Process in the Processor dialog box.
5.
Select New Process in the Select Process dialog box, and click OK.
250
Do it Yourself (6/13)
Create Processor
6.
Click on Fluids under Requirement in the
Cycle Process Definition dialog box.
7.
Set Remaining to Level Reached in Qty & Quantity to 40
in the Fluids Acceptance End dialog box, and click OK.
8.
Click Cycle Time in the Cycle Process Definition dialog box.
9.
Choose Constant in the Distribution dialog box, and click OK.
10. Enter 10 for value in the Constant dialog box, and click OK.
11. Click OK in the Cycle Process Definition dialog box.
The message window reads “Fluid Process <Fluid_Process_1> created.”
251
Do it Yourself (7/13)
Create Processor
12. Click on Display and set Animation Method attribute to Both
in the Display dialog box, and click OK.
13. Click OK in the Processor dialog box.
The message window reads “Processor <Processor1> created.
Select a location on Grid floor.”
14. Position processor1 at a location on the grid referring to the
image at the beginning of the exercise.
Create Fluid Sink
1.
Select Model / Fluid / Fluid Element / Fluid Sink.
2.
Enter 30 for Fluid Min residence Time in the
Fluid_Sink dialog box, and click Display.
3.
Set animation Method to Both in the Display dialog box.
4.
Position Fluid_Sink1 at a location on the grid floor referring
to the image at the beginning of the exercise.
252
Do it Yourself (8/13)
Create Pipe
1.
Select Model / Fluid / Fluid Element / Pipe.
2.
Set Part Capacity Type to Volume in the Pipe dialog box,
and click Fluid Capacity.
3.
Enter 0.01 for Fluid Capacity in the Fluid Capacity
dialog box, and click OK.
4.
Click OK in the Pipe dialog box & position the pipe on the
grid at a location between the source & tank in the model
as shown at the beginning of the exercise.
5.
Make sure the ends of the pipe is fixed to the inlet of the source & tank as
shown below by translating the element & pipe accordingly along X-axis
(LMB) Y-axis (MMB), Z-axis (RMB) using the option Model / Fluid / Trn.
6.
Follow steps 1 to 5 in creating a another pipe Pipe2. Position this pipe between the
processor and the sink as shown in the image at the beginning of the exercise.
253
Do it Yourself (9/13)
Create Extruded Pipe
1.
Select Model / Fluid / Pipe System/ Extruded Pipe.
2.
Set Part Capacity Type to Volume in the Extr_Pipe dialog box,
and click Fluid Capacity. Enter 0.01 for Fluid Capacity in the Fluid
Capacity dialog box. Click OK in the Extr_Pipe dialog box.
3.
Select Model / Fluid / Pipe System/ Setup.
4.
Set Arc Mode to Angle-Radius in the Layout Setup dialog box,
and click OK.
5.
Select Model / Fluid / Pipe System/ Line.
6.
Indicate the first point at the Tank outlet and select Rel.
7.
Enter 5 for X in the Rel Coords dialog box, and click OK.
The extruded pipe Extr_Pipe1 is positioned on the grid floor.
8.
Attach one end of the extruded pipe to the outlet of Tank1 using
the options Model / Fluid / Trn.
254
Do it Yourself (10/13)
Create Extruded Pipe
9.
Select Model / Fluid / Pipe System/ Arc.
10. With RMB click the end of Extr_Pipe1_1 positioned on the grid floor.
11. Arc Parameter dialog appears. Enter the values in each field as shown:
12. Translate the processor using the Trn button to fix its inlet to the
end of Extr_Pipe1_2 as shown:
255
Do it Yourself (11/13)
Connect Elements
1.
Select Model / Fluid / Connections / Connect.
2.
Select Fluid_Source1_1 in the Select a Fluid
Output Element dialog box, and click OK.
3.
Fluid Connection Info dialog box appears. Enter 0.7
for Full Slot Rate in the dialog box, and click OK.
4.
Select Pipe1_1 in the Select a Fluid
Input Element dialog box, and click OK.
The connection between Fluid_Spource1_1 and
Tank1_1 is established as shown:
256
Do it Yourself (12/13)
Connect Elements
5.
Follow steps 1 to 4 in establishing the connection between the following element
and enter the specified full slot rate value in the dialog box given below:
Pipe1_1 to Tank1_1 (Full Slot Rate: 1)
Tank1_1 to Extr_Pipe1_1 (Full Slot Rate: 1.2)
Extr_Pipe1_2 to Processor1_1 (Full Slot Rate: 1)
Processor1_1 to Pipe2_1 (Full Slot Rate: 1.2)
Pipe2_1 to Fluid_Sink1_1 (Full Slot Rate: 1)
6.
Select Model / Fluid / Connection / Show to view the connection between each element.
7.
Choose All Connection in the Select Connection type dialog box, and click OK.
All the connection between the elements in the
model is displayed as shown:
257
Do it Yourself (13/13)
Save and Run Fluid Model
1.
The procedure to save the fluid model is same to saving a
normal QUEST model using File / Save Model.
2.
Enter Fluid_Model for File name in the Save As dialog box.
3.
Simulate the model for 500 sec, selecting Run / Simulation / Simulate / Run.
During the simulation you will see a dynamic text visualization of the current contents
of the fluids each element.
The fluid Fluid1_1 is created in Fluid_Source1_1 & 100L of fluid flows to Tank1_1. When the tank has
100L of fluid, 50L of fluid from the Tank flows to Processor1_1. When the Processor1_1 is filled with
50L of fluid, the processed fluid is transferred to Fluid_SinK1_1, which resides in the sink for 30 sec
before being destroyed. During this 30sec, fluid flows from source to tank till the tank has 100 L and
50L from tank to processor. This process continues for the specified run time. You can observe these
values in the dynamic text that is displayed for each element during the simulation.
258
C
Modeling Tools
& Fixtures
Modeling Tools & Fixtures
Defining Sub-Resource Controller
Creating Tool
Associating Sub-resource Controller to Resource
Locking/Unlocking with Parts
259
5
Trains, Fluids and Tools & Fixtures
Modeling Tools
& Fixtures
About Modeling Tools & Fixtures
Tools & fixtures can be modeled using the concept of sub-resources. Tolls are auxiliary
resources that are used in machines as part of processing. Tools can be either shared
between machines or attached to one machine. Sub-resource can represent tools and can
also be shared (transferred) between resources. When a set of tool is shared between
resources, a sub-resource controller is used to coordinate the communication between
involved resources. The behavior and logic of the sub-resource controller is a simplified
version of a labor controller.
More about Tools & Fixtures can be found in the QUEST
on-line documentation.
260
5
Trains, Fluids and Tools & Fixtures
Modeling Tools
& Fixtures
Modeling Tools & Fixtures
The following table summarizes the common behavior of tools and the
corresponding available sub resource related modeling feature.
Tool/Fixture Behavior
Modeling Representation/Feature
Tools/Fixtures
Sub-resources
Different types of tools
Different sub-resource classes
Tools needed for processing
Sub-resource requirement in cycle processes
Tools movement between re-sources
Sub-resource "transfer" between resources
Tool room to hold set of tools
Sub-resources created/located in some
resource
Coordination/sharing of tools between
resources
Sub-resource controller to control subresources and assigned to resources
Tool failures
Sub-resource failures
Tool life
Sub-resource failures (also ability to destroy
sub-resources)
Tool buffer/changer in machines
Sub-resources created and assigned locally to
machines
Parts attached/detached to fixtures
Lock/unlock a part with a sub-resource
Tools/fixtures part of setup and unload
Sub-resource requirement in setup and unload
processes
Tools moved by labor/mobile
Workaround using lock/unlock with dummy
parts or through custom SCL
261
Trains, Fluids and Tools & Fixtures
5
Modeling Tools
& Fixtures
Defining Sub-resource Controller
The sub-resource controller is the new element type introduced to enable a subresource to be shared between multiple resources. Sub-resource controller creation,
association, behavior, and logics are similar to that of a labor controller element.
1
Select Model / Aux / Element Class / SR Controller.
You will see Fluid Class dialog box.
2
Enter the name of the controller in the dialog box, and click OK.
3
Position the controller at the required location on the grid floor.
The message window reads “Element Class <SR_Controller> created.”
262
Trains, Fluids and Tools & Fixtures
5
Modeling Tools
& Fixtures
Creating Tool
The Sub-resource controller supervise the movement of the tool i.e. sub-resource.
It keeps track of the requests for sub-resources, for the various processes, and by
various elements. It dispatches the sub-resources as required and when available.
The sub-resource created through their class cane be associated to sub-resource
controller. To do this:
1
Select Model / Aux / Element Class / Sub-Resource.
You will see Sub_Resource dialog box.
2
Set Controller to sub-resource controller created & define
the required attributes in the dialog box, and click OK.
3
Position the sub-resource on the required resource
located on the grid floor.
The message window reads “ Sub-resource <Sub_Resource>
created.”
263
Trains, Fluids and Tools & Fixtures
5
Modeling Tools
& Fixtures
Associating Sub-resource Controller to Resources
Similarly, other resources can also be associated to a sub-resource controller through
their class creation (similar to specifying the labor controller). the requests from the
resources are directed to the associated sub-resource controller.
1
Select Model / Aux / Element Class / Modify.
2
Select the required element in the Select Element dialog box that appears.
3
You will see the selected element dialog box.
Click on SR Controller button in the dialog box.
You will see SR Controller dialog box.
4
Choose SR_Controller in the dialog box, and click OK.
SR_Controller is associated with the selected element class.
264
Trains, Fluids and Tools & Fixtures
5
Modeling Tools
& Fixtures
Locking/Unlocking with Parts
The lock/unlock feature has been included to attach a sub resource with a part for
fixtures modeling. When locked, the sub-resource is physically attached to the part.
When the part is transferred between resources, the locked sub-resource also goes
with that and when the part is unloaded or transferred, the sub-resource will go to the
sub-resource list of the new element. Similarly unlock will separate the part from the
sub-resource. This feature is set through the cycle process product option along with
pass and specify.
1
Select Model / Process / Process / Cycle.
2
Click on Product in the Cycle Process Definition dialog box.
You will see the Product dialog box.
3
Choose lock/unlock for the required part in the method
pull-down menu and assign the required sub-resource to be
attached to the part in the Lock sub Res field in the dialog box,
and click OK.
265
Modeling Fluids – Exercise
266
5
Exercise – Modeling Trains
15 min.
Scope: In this exercise you will create Tools & Fixture Model.
Conditions: D5 must be open.
In this exercise you will:
Create Element Class
Create Sub-Resource and Controller
Run Model
267
Do it Yourself (1/6)
Machine1
Machine3
Machine4
Machine5
SCREEN SHOT
Machine2
Starting point
Machine4
Ending point
Load: QUEST
268
Do it Yourself (2/6)
Create Element Class
1.
Select Model / Build / Part Class / Create/Modify.
2.
Use the default settings in the Part Class dialog box and click on OK.
3.
Repeat steps 1 & 2 to create Part2 and choose a different color.
4.
Select Model / Build / Element Class / Source.
5.
Use the default name in the Source dialog box and click Part Initial Stock.
Enter 1 for Part1 in the Class Initial Stock dialog box, and click OK.
6.
Repeat steps 4 & 5 to create Source2 and enter 1 for Part2 in the
Class Initial Stock dialog box.
7.
Position the source on the grid referring to the image
in the above slide.
8.
Select Model / Build / Element Class / Conveyor.
9.
Use the default name in the Conveyor dialog box and set the speed to
0.01ft/sec in the Conveyor Info dialog box.
10. Position the conveyor on the grid referring to the image
in the above slide.
269
Do it Yourself (3/6)
Create Element Class
11. Select Model / Build / Element Class / Machine.
12. Use the default name and enter 2 for No. of Process
in the Machine dialog box, and click OK.
13. Position the machine on the grid referring to the image
at the beginning of the exercise.
14. Repeat steps 1 to 3 for the remaining machines Machine2,3,4,5,6
and position them one the grid referring to the image at the
beginning of the exercise. Set No. of Process to 2 only for Machine2.
15. Create the following cycle process with the given cycle time,
selecting Model / Process / Process / Cycle.
Cycle Process
Cycle Time
Part
Product
Mac_Process_1
90
Set Part1 to 1 for Quantity
Set Part1 to Lock for Method & choose
Sub_Resource1_1 for Loc Sub Res
Mac_Process_2
90
Set Part 2 to 1 for Quantity
Set Part2 to Lock for Method & choose
Sub_Resource2_1 for Loc Sub Res
16. Select Assoc button on the same page & select Machine1 in the Select Element dialog box, click OK.
270
Do it Yourself (4/6)
17. Create Element Class
17. Set Cycle_1 & Cycle_2 to Mac_Process_1 in the Process assignment,
and click OK.
18. Follow steps 2 & 3 in associating Mac_Process_2 to Machine2.
19. Repeat steps 5 & 6 in creating the following process & associate them to
Machine3,4,5 & 6 respectively.
Cycle Process
Cycle Time
Process Precedence
Mac_Process_3
104
Select Mac_Process_1
Mac_Process_4
105
Select Mac_Process_2
Mac_Process_5
1
Select Mac_Process_3 & Mac_Process_4
20. Connect the elements as shown, selecting
Model / Build / Connection / Element.
271
Do it Yourself (5/6)
Create Sub-Resource and Controller
1.
Select Model / Aux / Element Class / SR Controller.
2.
Use the default name in the SR_Controller dialog box, and click OK.
3.
Position the controller on the grid referring to the image at the
beginning of the exercise.
4.
Select Model / Aux / Element Class / Sub-Resource.
5.
Use the default name, set Controller to SR_Sontroller1_1 and enter
9 ft/sec for Speed in the Sub_Resource dialog box, and click OK.
6.
Position the sub-resource on Machine6 by clicking on the machine.
7.
Follow steps 4 to 6 for creating Sub_Resource2.
8.
Assign SR Controller1_1 for all machines & conveyor, selecting
SR Controller button in the respective dialog box.
272
Do it Yourself (6/6)
(2/13)
Run the Model
1.
Select Run / Simulation / Simulate / Run.
2.
Enter 1000sec for Report Time in the Run dialog box, and click OK.
The model is simulated for 1000sec before it halts. The message window
reads “ Simulation Completed”.
During the simulation Sub-resource 1 & 2 on Machine6 is removed from it’s parent element’s
labor point and attached to the part on Machine1 & 2 respectively. The tool moves along with
part when transferred between resources. You can observe the tool & part moving together
over the Conveyor1_1. This is because you have locked the parts to the respective tool.
When the part is unloaded at Machine5 & tool returns back to their respective machine.
273
5
Trains, Fluids and Tools & Fixtures – Module summary
Summary
This module explained the concepts of tools & fixtures, fluids and trains
in QUEST. Each of the functions for creating tools & fixtures, fluid and
trains entities were described and the details of its parameter discussed.
An explanation of how theses parameters could be used to model
physical system was also provided.
Coming Up
Final Assembly & Pull Model
Modeling final Assembly Model
Modeling Pull System
4 hour
274
1
Advanced
QUEST
Programming
2
Optimization and
Experimentation
3
5
6
Trains, Fluids and
Tools & Fixtures
4
QUEST
Graphical
Outputs
Hierarchical
Model
Final Assembly
Model & Pull Model
Module 6
Final Assembly &
Pull Model
275
6
Final Assembly & Pull Model
Overview
This module describes assembling of parts or sub-assemblies with the
main part at one or more stations in a final assembly. Also, the
underlying structure of pull systems and the elements class attributes
that need to be set for pull systems are discussed.
Objectives
Topics in this module are:
Modeling Final Assembly
Modeling Pull Systems
4 hours
276
Menus and Action Buttons used in this Module
277
6
Final Assembly & Pull Model
Modeling Final
Assembly Model
Defining Assembly Station
Defining Assembly Operators
Defining Part Bins
Creating Main Part
Defining Assembly Process
Modeling Pull
System
Structure of Pull System
Pull Connection
Element Attributes for Pull System
4 hours
278
A
Modeling Final
Assembly Model
Defining Assembly Station
Defining Assembly Operators
Defining Part Bins
Creating Main Part
Defining Assembly Process
279
6
Final Assembly & Pull Model
Modeling Final
Assembly Model
About Modeling Final Assembly Model
In a final assembly, at each station, the processes earmarked for that station are performed.
The processes may require other resources like Labor, Robots, Tools, Fixtures and other
material handling equipments. Processes also require other auxiliary parts that are usually
placed in buffers or bins near the station. Multiple processes may be required to be executed
at a station.
Final assembly operations can be categorized into two
distinct types:
Line assembly — In Line assembly the parts are assembled
while the main part moves on a conveyor. Example of a line
assembly is the final assembly of automobiles.
Dock assembly — In Dock assembly the main part remains at
a station and the required parts are assembled at this station
only. This is normally used in building ships, airplanes and
heavy machinery.
This module devoted almost entirely to line assembly
systems. However, many of these features can be used to
model a dock assembly station.
More about optimization & experimentation can be found in the
QUEST on-line documentation.
280
Final Assembly & Pull Model
6
Modeling Final
Assembly Model
Defining Assembly Station
An assembly station is defined on the conveyor by associating a machine to the
conveyor decision point and this machine is called dedicated machine. To create an
assembly station:
1
Select Model / MHS / Element / Modify.
2
Select the required decision point in the Select Element dialog box, and click OK.
You will see Modify Element dialog box.
This field has two options:
Create: a machine class with one element is
created and located near the decision point.
None: When the conveyor decision is not
associated to a station this option is selected.
The 'Station' machine class and the element, if
existing, are deleted.
281
Final Assembly & Pull Model
6
Modeling Final
Assembly Model
Defining Assembly Station
3
Set Dedicated Machine to Create in the dialog box, and click OK.
This creates an assembly station on the conveyor at the selected conveyor decision point.
Note:
1) When you set the Dedicated Machine at the conveyor decision element to
'Create', the process logic is set to 'Station Process Logic' if the existing
option is 'Delay‘ (the default option). This logic option can be used only for
those decision points that are the start points of a station.
2) No connection is required from the conveyor decision point to the machine.
3) The default machine class name is 'Station_<decision point name>'.
4) If the default geometry is used for both conveyor and machine, the machine
is located such that the worktable sits in line with the conveyor and just after
the decision point. The machine is also attached to the decision point and is
translated with the decision point, but also can be translated/ rotated
independently.
282
Final Assembly & Pull Model
6
Modeling Final
Assembly Model
Defining Assembly Operators
Assembly operators are “Dedicated Labors” associated to the Station. Dedicated Labors
are also referred to as task-based labors. They have the following characteristics:
• No labor controller.
• Process Logic set to ‘Task Based Labor Logic‘.
• Load / Unload Logics set to ‘Move Part‘.
• Attached ‘Labor Parking‘ popup.
To assign these labor elements as dedicated labors to a machine i.e. station:
1
Select Model / MHS / Element / Modify.
2
Select the desired station in the Select Element
dialog box, and click OK.
You will see the Modify Element dialog box.
3
Click on Dedicated Labors in the dialog box.
You will see the Select Element dialog box.
283
Final Assembly & Pull Model
6
Modeling Final
Assembly Model
Defining Assembly Operators
4
Choose the desired labor to be associates with the selected station in the dialog, and click OK.
You will see the Dedicated Labor Setting dialog box.
This information is used
in labor selection
and will determine which
labor gets selected for a
given process.
5
Enter the labor points in the dialog box i.e. where exactly you want each of the dedicated
labors to work on the machine, and click OK.
Note:
The default is ‘ANY‘, which means that the labor can work in any of the
labor points on the machine. Multiple labor points can be entered as
comma separated indices, for example, Labor1_1: 5, 7.
When dedicated labor is set, the message window reads the following logics set
automatically for each selected labor element:
- Process Logic Option is set to ‘Task Based Labor Logic’.
- Load / Unload Logics are set to ‘Move Part’.
- Labor Parking Popup is added and option set to ‘Park Fixed’.
284
Final Assembly & Pull Model
6
Modeling Final
Assembly Model
Defining Assembly Operators
Note:
Controller option is set to ‘No Controller’ for dedicated labors and
commands are issued to these labors by the machine, i.e. the station
(Process Logic) by user interrupt to perform the tasks required to perform
the processes at the machine. Commands are issued to the labor based
on the availability of the parts on the upstream elements. All the parts
must be available at the upstream buffer for labor commands to be issued.
6
Labor Parking Information for the dedicated labor elements can be set at the machine
using the Labor Parking button in the Modify Element dialog box for the machine.
7
Click on Add under Fixed Packing Info in the Select
Labor Parking Options dialog box.
8
Choose the required Labor in the Select a Labor Class
dialog box, and click OK.
9
Select the element in the Select Element dialog box on which Labor is parked after the
process on the machine is done. Click OK in the Select Labor Parking Options dialog box.
285
Final Assembly & Pull Model
6
Modeling Final
Assembly Model
Defining Part Bins
Part bins are modeled as ‘Dedicated Buffers’, connected to the Assembly stations.
Dedicated buffers do not route any parts. The parts are picked up from these buffers
when required. To do this:
1
Select Model / Build / Element Class / Buffer.
2
Click on Logics in the Buffer dialog box.
You will see Logics dialog box.
3
Click on Route Logic in the dialog box.
286
6
Final Assembly & Pull Model
Modeling Final
Assembly Model
Defining Part Bins
You will see Route Logic dialog box.
Note:
4
Choose None in the dialog box, and click OK.
5
Click OK in all open dialog boxes.
The Route Logic for these buffers are set to ‘None‘ for parts to be
picked up from these buffers when required. All Upstream
Connections to the assembly station must be from Dedicated Buffers.
287
Final Assembly & Pull Model
6
Modeling Final
Assembly Model
Creating Main Part
The Main Part is the part whose arrival at a station triggers the start of processes
at that station. Following are some of the attributes of a main part:
• The main part must be a pallet i.e.; it must have an associated Sub Resource.
• The main part must have stack and labor points defined for parts and labor positioning.
To create a main part you need to first create a sub-resource. To do this:
1
Select Model / Aux / Element Class / Sub-Resource.
2
Click on Display in the Sub-Resource dialog box.
You will see Display dialog box.
3
Enter the required no. of stack points & labor point for the
main part in the dialog box, and click Stacking Table i.e.
highlighted when the no. of stack points is more than one.
288
Final Assembly & Pull Model
6
Modeling Final
Assembly Model
Creating Main Part
You will see Stack Info dialog box.
4
Set a stack point & labor point for each part in the dialog box to locate correctly the
auxiliary part on the main part during assembly process and also to position the labor
near the assembly area, and click OK.
5
Click OK in all open dialog boxes.
289
Final Assembly & Pull Model
6
Modeling Final
Assembly Model
Creating Main Part
The main part is a pallet, which is created by:
6
Select Model / Build / Part Class / Create/Modify.
You will see Part Class dialog box.
7
Set Associate Sub-Resource Class to the created
Sub-Resource in the dialog box, and click OK.
This completes the process of creating the main part i.e. pallet.
290
Final Assembly & Pull Model
6
Modeling Final
Assembly Model
Defining Assembly Process
Assembly processes are cycle processes. There are certain settings that are required
in order to select the desired dedicated labors and to have these labors at the correct
location in the station. The attributes to be specified for the cycle process are:
1
Select Model / Process / Process / Cycle.
2
Click on Parts under Requirement in the Cycle Process
Definition dialog box. You will see Part Requirement dialog box.
3
Set the following attributes in the dialog box, and click OK.
• ‘Dedicated Labor’ used to bring in the parts for the process from an upstream element
• ‘Input’ connection from where the parts required for assembly will be sourced and
• ‘Stack Point’ to position of the auxiliary part on the main part.
Note:
The stack point information in the assembly process has higher priority. If it is
not specified here, then the stack point specified at the main part is considered.
This is because, the same auxiliary part can be used for multiple processes. In
each of these processes, it can be assembled at a different point on the main part.
291
Final Assembly & Pull Model
6
Modeling Final
Assembly Model
Defining Assembly Process
4
Click on Labor under Requirement in the Cycle Process Definition dialog box.
You will see Labor Requirements dialog box.
5
Set the location index in the dialog box that assigns the labor point to the process, and
click OK. Based on this attribute and the labor point assigned to the dedicated labor at
the machine i.e. station, labor required for the process is selected.
6
Click on Product in the Cycle Process Definition dialog box.
You will see Product dialog box.
7
Set method against each of the auxiliary parts required for the process to 'Pack‘ and
Container Part Class to main part on which the part is packed in the dialog box, and click OK.
This completes the process of setting the required attributes to select the
desired dedicated labor for the process.
292
Modeling Final Assembly Model – Exercise
293
6
Exercise – Modeling Final Assembly Model
15 min.
Scope:
In this exercise you will create a part of the automobile model which is an example for line
assembly model. The part u will be modeling is fixing seats to the carbody.
Conditions: D5 must be open.
In this exercise you will:
Create Auxiliary Parts
Create Element Class
Create Assembly Station
Create Part Bins
Create Assembly Operators
Define Main Part
Define Assembly Process
Run Model
294
Do it Yourself (1/11)
SeatSource1
SeatBuffer1_3
SeatBuffer1_1
SeatBuffer1_2
CarbodySource1
SeatBuffer1_4
SCREEN SHOT
Starting point
Ending point
Load: QUEST
295
Do it Yourself (2/11)
Set up
1.
Select Pref / Environment / Units.
2.
Set each fields in the dialog box as shown, and click OK.
Create Auxiliary Part
1.
Select Model / Build / Part Class / Create/Modify.
2.
Enter Seat for Name in the Part Class dialog box,
and click Display.
3.
Click on 3D File in the Part Class Display dialog box. Select Select
from library in the Geometry Selection dialog box, and click OK.
4.
Select car_seat in the ../PARTS/GIFTS/WIDGET/ dialog box.
5.
Click OK on all open dialog boxes.
6.
Repeat step 1 to create other part & enter Carbody for class name.
296
Do it Yourself (3/11)
Create Source, Conveyor & Conveyor decision point
1.
Select Model / Build / Element Class / Source.
2.
Enter SeatSource1 for Class Name and 2.5 for Start Offset in the
Source dialog box, and click Part initial Stock.
3.
Enter 4 for Seat in the Class Initial Stock dialog box, and click OK.
4.
Click IAT in the Source dialog box. Select Constant in the Distribution
dialog box & enter 6 min for value in the Constant dialog box.
5.
Enter 1 for Seat in the Part Fraction dialog box, clicking on Part Fraction.
Enter 5 min for Lotsize, selecting Constant in the Distribution dialog box.
6.
Repeat steps 1 & 2 to create source CarbodySource1. Enter 1 for Carbody
in the Part Fraction dialog and enter 8.333min for IAT value, selecting
Constant in the Distribution dialog box.
7.
Position the two source on the grid referring to the image at the beginning of the exercise.
297
Do it Yourself (4/11)
Create Source, Conveyor & Conveyor decision point
1.
Select Model / Layout / Create System / Conv.
2.
Enter AssyConveyor1 for class name in the Extr_Conveyor
dialog box, and click Conveyor Info.
3.
Enter 500 for Moving Space and stopping space and 720
for Speed in the Conveyor Info dialog box, and click OK.
4.
Set Conveyor Style to Roller in the Display dialog box, selecting
Display in the Extr_Conveyor dialog box.
5.
Select Model / Layout / Create System / Line.
6.
Indicate the first point by clicking on the grid near Carbodysource1.
Click on Rel and enter 10 for X in the Rel Coord dialog box.
7.
This will create AssyConveyor1_1. With the Line button activated,
repeat step 3, which will create AssyConveyor1_2 on the grid floor.
298
Do it Yourself (5/11)
Create Assembly Station
1.
Select Model / Layout / Dec Point / Conv.
2.
Use the default setting in the Cnv_Dec_Pt dialog box, and click OK.
3.
Position the conveyor decision point on the conveyor created
by clicking on Assyconveyor1_1.
4.
Select Model / MHS / Element / Modify.
5.
Select Cnv_Dec_Pt1 in the select Element dialog box, and click OK.
6.
Set Dedicated Machine to Create in the Modify Element dialog box, and click OK.
Station Station_Cnv_Dec_Pt1 is created & located
at the decision point on the conveyor on the grid floor.
Once the station is created, the Process Logic for the
decision point is set to Standard Process Logic. This
can be crossed checked in the decision point dialog.
299
Do it Yourself (6/11)
Create Part Bins
1.
Select Model / Build / Element Class / Buffer.
2.
Enter SeatBuffer for class name, and 4 for No. of Elements
in the Buffer dialog box, and click Logics.
3.
Click on Route Logic in the Logics dialog box and choose
None in the Route logic dialog box, and click OK.
4.
Position the four buffers on the grid floor referring to the
image at the beginning of the exercise.
300
Do it Yourself (7/11)
Create Assembly Operator
1.
Select Model / MHS / MHS Element / Labor.
2.
Use the default setting in the Labor dialog box, and click OK.
3.
Click on Seat_Buffer1_2 located on the grid floor to position Labor1.
4.
Repeat steps 1 & 2 to create a second Labor & position the Labor2
on SeatBuffer1_1 located on the grid floor.
5.
Click on Modify under Element on the same MHS page.
6.
Select Station_Cnv_Dec_Pt1 in the Select Element dialog box.
7.
Click on Dedicated Labor in the Modify Element dialog box.
8.
Select both Labor1 & Labor2 in the Select Element dialog box, and click OK.
9.
Enter labor points 5, 7 for Labor1 and 6, 8 for Labor2
in the Dedicated Labor Setting dialog box, and click OK.
The Process Logic, Load/Unload Logic and Labor Parking popup are set automatically
for the Labor. This can be crossed checked in the Labor dialog box under Logics.
301
Do it Yourself (8/11)
Define Main Part
To define a part as a pallet i.e. main part, you need to first created a sub-resource.
1.
Select Model / Aux / Element Class / Sub-Resource.
2.
Enter car_bodySR for Class Name in the Sub_Resource
dialog box, and click Display.
3.
Enter 14 for No. of Stack Points and 8 for No. of Labor Points
in the Display dialog box, and click Stacking Table.
4.
Complete the Stack info dialog box as shown, and click OK.
5.
Click OK in all open dialog boxes.
To define part CarBody as the main part i.e. pallet:
6.
Select Model / Build / Part Class / Create/Modify.
7.
Choose CarBody in the Select Part Class
dialog box, and click OK.
8.
Set Associate Su-Resource Class to car_bodySR
in the Part Class dialog box, and click OK.
302
Do it Yourself (9/11)
Define Assembly Process
1.
Select Model / Process / Process / Cycle.
2.
Choose NEW in the Select Cycle Process, and click OK.
3.
Enter SeatAssyFL for class name in the Cycle Process
Definition dialog box, and click Parts.
4.
Define each fields in the Part Requirement dialog box
as shown, and click OK.
5.
Click Labor in the Cycle Process Definition dialog box and enter the
details as shown in the Labor Requirement dialog box, and click OK.
303
Do it Yourself (10/11)
Define Assembly Process
6.
7.
Click Product in the Cycle Process Definition dialog box and enter the
details as shown in the Product dialog box, and click OK.
Repeat steps 1 to 3 & 6 for creating the remaining assembly process,
SeatAssyFR, SeatAssyRL and SeatAssyRR. Enter the following entries
in the Part & Labor Requirement dialog box for each assembly process:
Process
Part Requiremnt dialog
Labor Requirement dialog
SeatAssyFR
For Seat set 1 for Quantity, Input, 6 for
Stack Point & set Labor to Labor2
Set Requirements to 1 and Location Index
to 6 for Labor2.
SeatAssyRL
For Seat set 1 for Quantity, 4 for Input,
9 for Stack Point & set Labor to Labor1
Set Requirements to 1 and Location Index
to 7 for Labor1.
SeatAssyRR
For Seat set 1 for Quantity, 3 for Input,
8 for Stack Point & set Labor to Labor2
Set Requirements to1 and Location Index
to 8 for Labor2.
304
Do it Yourself (11/11)
Define Assembly Process
8.
Set No. of Process to 4 in the Machine i.e. station dialog, selecting
Model / Build / Element Class / Machine. Click Cycle Process in the
Machine dialog box and set each cycle as shown:
Run Model
1.
Select Model / Simulation / Simulate / Run.
2.
Enter 400 min for Report Time in the Run dialog box, and click OK.
The automobile model is simulated for 400 min before it halts.
During the simulation when a main part i.e. CarBody hits the decision point and process is
triggered, Labor1 & Labor2 will get commands from the station to move auxiliary parts i.e.
Seat to the Carbody. The two labors draws a via path from the buffer to the position where the
main part would be, taking into account both the speed of the main part on the conveyor, speed
of the labor and also orientation of the conveyor. So the labor will reach the main part exactly at
the end of the move. An assumption made here is that conveyor will not stop in between. Also
linear movement of the main part on the conveyor is considered. At the end of the process, the
Seat is packed to the CarBody at the specified stack point in the Part Requirement dialog box.
After the part is packed, the bounding box of the main part is updated to account for proper stop
space and moving space on the conveyor.
305
B
Modeling Pull
System
Structure of Pull System
Pull Connection
Element Attributes for Pull System
306
6
Final Assembly & Pull Model
Modeling Pull
system
About Modeling Pull System
In most manufacturing systems, parts are created continuously and a finished goods inventory
is created. Parts are constantly added to the system to produce products. Such systems are
referred to as "push" systems in QUEST. However, system where products are produced
only when required are referred to as "pull" systems in QUEST. An example of “pull system is
JIT (Just In Time) manufacturing systems.
The pull mechanism allows parts to be created on demand
arising at the sink and is sent in the form of a request for a
particular part to the upstream element, which tries to satisfy
it. If the element has the requested part, it is routed out. If it
does not possess the requested part, it propagates the
request further upstream. The request could thus get
propagated all the way up to the source, which then satisfies
the request by creating a part of the specified class. It then
routes it to the element that requested it. Thus, requests
travel in the direction opposite to that of parts in the system.
More about Pull Modeling can be found in the QUEST on-line
documentation.
307
6
Final Assembly & Pull Model
Modeling Pull
system
Structure of Pull Systems
To keep track of requests, each element has two internally maintained lists that hold
information about the requests. The "Order List" is a list of requests that have gone
(ordered) upstream from the element, but are not yet fulfilled. The "Request List"
is a list of requests that have been received by the element, but are not yet fulfilled.
To create and process the requests a wide range of SCL routines are available of which
the most important are:
• wait_for_request — Waits for a part request from downstream elements.
• attach_request — Removes the specified request from the request list of
the current element and sets it on the part.
• set_request_pending – Adds the request to the request list of the element.
• dispatch request — Creates a request for the specified part class and dispatches it through the
specified input number, element, or element class and is added to the sending element's Order List.
• require part ordered — Defines a part class or a specific part that is required
at an element only if there is a pending order for that part.
• match_order — Finds the request from the element's order list that matches the
request on the specified part. Returns the request handle if one is found in the order list.
• order_fulfilled — Removes the specified order from the element's order list, when
a part arrives at an element in response to an order.
308
6
Modeling Pull
system
Final Assembly & Pull Model
Pull Connection
For the propagation of the requests upstream, the connection mechanism provides pull
connections. A pull connection is a channel for requests traveling upstream in a system,
just like the push connection transferring request downstream. Pull connections are
made in the reverse order of push connections. However, pull connections are not
mandatory. In the absence of a pull connection, the push connection is used to send
requests in the reverse direction. Pull connections are useful in sending requests to
elements when a direct push connection does not exist to this element.
The same buttons used for creating and deleting connections in the push mode are used
for pull connections also. The Push, Pull toggle button under Model / Build / Connections
is used to set the mode to push or pull. The other connections buttons work based on
the current mode.
Click this button to
toggle between Push &
Pull connection.
309
6
Final Assembly & Pull Model
Modeling Pull
system
Elements Attributes for Pull Systems
To enable an element to function as a pull element there are several attributes of that
element that may need to be assigned. This section describes these functions.
Input Type:
This option is used to specify the method by which parts are to enter the element. This can be toggled
to either "Push" or "Pull". When Pull is selected, the element will only receive parts on its inputs after
it sends out a request for the part. When Push is selected, the element inputs are passive and receive
parts on the inputs whenever they are pushed on by its upstream elements.
Output Type:
This is used to specify the method by which parts are to enter the element. Using this attribute, the
output type of the element can be toggled to either "Push" or "Pull". If Pull is selected, then parts will
not be routed out of the element until a request is received from a downstream element. An output
type of push means that the element routes parts from its outputs as soon as the downstream
elements are able to receive them.
Note:
Only two types of element classes, sinks and buffers, may generate requests.
Hence, you cannot set the Input Type of an element to "Pull" and the "Output Type
to "Push" for any element in QUEST except buffers (sinks do not have an output
type since parts are not allowed to flow out of the sink and source do not have
input type attributes).
310
6
Final Assembly & Pull Model
Modeling Pull
system
Elements Attributes for Pull Systems
Part Creation Mode:
Part Creation Mode is an attribute of a source that can be set to either "Active" or "Passive".
Active mode is analogous to any push input element, producing parts in accordance with its
Inter-arrival Time (IAT). Passive sources produce parts only when a request is made to them
to do so. Hence passive sources do not have parameters like IAT, lot size, and initial stock.
If the creation mode is set to Passive then the source process logic is changed to "Default
Passive Source Process" or can be set to user-defined logic.
Note:
If you set the Part Creation Mode to "Active" and also set the Output Type to
"Pull", then the source will produce parts according to its part fractions, lot size,
and IAT but these parts will leave the source only when a request arrives from a
connected element.
Threshold:
This is an attribute of the buffer and is activated only if the input type is set to "Pull". Using this,
you can define upper and the lower thresholds for the various parts coming into a buffer. As soon
as the number of a particular part becomes lesser than the lower threshold, a request for its
refurbishment is placed to the element upstream.
311
6
Final Assembly & Pull Model
Modeling Pull
system
Elements Attributes for Pull Systems
IRT, Request Lotsize and Request Part Fractions:
These are the attributes of the sink and is activated when the input type of the sink is set to "Pull".
Selecting IRT and Request Lotsize displays the Distributions dialog box, which allows two
distinct types:
Deterministic — Uses the "Constant" or "File Based" options.
Stochastic (random) — Uses a probability distribution from the list.
In addition, you can write an SCL routine that produces the lot size using the "User Func" option.
This creates requests
for a part at the
specified intervals.
This sets the proportions of
each part class that a sink will
request when in pull mode,
which chooses the new part's
class at random based on
probabilities determined from
the specified "request part
fractions", and independent of
the proportions of any initial
stock in the source.
This sets the number
of parts requested
simultaneously.
312
6
Final Assembly & Pull Model
Modeling Pull
system
Elements Attributes for Pull Systems
Pull Process Logic:
If the input type is set to "Pull", the process logic is set automatically to "Default Pull Machine
Process" or you can set to “User Func to use your own logic.
The default pull process logic algorithm goes through the following steps to process parts:
• Checks for any pending processes. If none exist, logic is suspended (until restarted in the
request logic).
• If pending processes do exist for the current element and there are in-parts in the machine,
these parts are checked to see if any of them match the pending orders. If true, then the
order is fulfilled and the part is removed from the pending order list of the element.
• The process is removed from the pending process list.
• Process is carried out.
313
6
Final Assembly & Pull Model
Modeling Pull
system
Elements Attributes for Pull Systems
Pull Route Logic:
If the output type is set to Pull, the route logic is automatically set to "Default Pull Route" or you can
set to “User Func” to use your own logic.
The default pull route logic algorithm goes through the following steps to process requests:
• Checks if part is routed. If true, the next out-part is checked.
• If an unload process exists, and the part being checked is not yet unloaded,
the next part in the list is checked.
• Checks if the part has a request attached to it:
- If no request is attached to it, then matches request by checking the pending request list.
If no matching request is found, the next part is checked.
- If request exists, it is attached to the part (thereby removing it from the request list)
• Checks labor requirement for the part. If labor is needed, then it is requested and obtained.
• Checks if the requesting element is connected to the current element.
- If connected, the part is routed to the requesting element.
- If request came from an element that is not connected to the current element,
then the part gets routed to the element at the output connection.
• Unloads all parts with request.
- If unload was successful, the logic moves on to the next part and the whole process is repeated.
- If unload was unsuccessful, then the route logic is suspended until restarted in the request logic.
314
Modeling Pull System – Exercise
315
6
Exercise – Modeling Pull System
15 min.
Scope:
In this exercise, the main objective is to show the functionality of the pull feature in QUEST.
To emphasize on the functionality of the pull, read in the assembly model from the GIFTS
directory and modify it to create a pull model.
Conditions: D5 must be open.
In this exercise you will:
Modify Sink
Modify Conveyor
Modify Machine
Modify Buffer
Modify Source
Pull Connection
Run Model
316
Do it Yourself (1/6)
SCREEN SHOT
Starting point
Ending point
Load: ../QUESTLib/MODEL/GIFTS/assembly.mdl
317
Do it Yourself (2/6)
Modify Sink
1.
Select Model / Build / Element Class / Modify / Sink.
2.
Choose Sink1_1 in the Select Element Class dialog box, and click OK.
3.
Set Input Type to Pull in the Sink dialog box. IRT, Request Lotsize
and Request Part Fractions are enabled.
4.
Click on IRT in the dialog box. Choose Constant in the
Distribution dialog and set its value to 60.
5.
Click on Request Part Fractions in the dialog box.
Complete the Request Class dialog box as shown below
and click on OK.
6.
Click OK in the Sink dialog box.
318
Do it Yourself (3/6)
Modify Conveyors
1.
Select Model / Build / Element Class / Modify.
2.
Click on Conveyor when prompted to select an element to modify. Choose
conveyor1_1 in the Select Element Class dialog box, and click OK.
3.
Set Input Type and Output Type to Pull in the Conveyor dialog box,
and click OK.
4.
Repeat step 3 for the other two conveyors in the model
i.e conveyor1_2 and conveyor1_3.
Modify Machines
1.
Select Model / Build / Element Class / Modify.
2.
Choose workcell1_1 in the Select Element Class dialog box,
and click OK.
3.
Set Input Type and Output Type to Pull in the Machine dialog box,
and click Request Routing.
319
Do it Yourself (4/6)
Modify Machines
4.
Click on Restriction in the Request Routing Info dialog box to
route plate & rack parts to a specific input.
5.
Route plate on Inpit-2 and Route rack on Input-1 as shown
in the Request Restriction Info dialog box, and click OK.
6.
Click OK on all open dialog boxes.
Modify Buffers
1.
Select Model / Build / Element Class / Modify.
2.
Choose buffer_7 in the Select Element Class dialog box,
and click OK.
3.
Set Input Type and Output Type to Pull in the Buffer dialog box,
and click Threshold.
320
Do it Yourself (5/6)
Modify Buffer
4.
Set Lower Threshold to 1 and the Upper threshold to 5 for plate
in the Class Thresholds dialog box, and click OK.
5.
Repeat steps 1 to 4 and modify buffer_8 to change the Input Type
and Output Type to Pull. For buffer_8, set the Lower Threshold to
1, the Upper Threshold to 5 for rack, and all others as 0 in the
Class Threshold dialog box.
6.
To see the effect of the lower and upper thresholds working for the two buffers, buffer_7 and
buffer_8, only delete the two buffers next to the source i.e. buffer_5 and buffer_6.
Modify Source
1.
Select Model / Build / Element Class / Modify.
2.
Choose source1_1 in the Select Element Class dialog box,
and click OK.
3.
Set Part Creation Mode to Passive in the Source dialog box.
The Output Type is set Pull & disabled. Click OK.
4.
Repeat step 3, modify source_2, and change the Part Creation Mode
to Passive. This will set the Output Type to Pull and disabled.
321
Do it Yourself (6/6)
Pull Connection
Since, the two buffers next to the sources have been deleted, the element connections
between the corresponding elements will be made again. In this model, all the
connections are push connections. The way the pull system works in QUEST
is to make use of push connections in the absence of the pull connections.
1.
Select Model / Build / Connections / Element.
2.
Select source1_1 in the Select an Output Element dialog box, and click OK.
3.
Select conveyor1_1 in the Select an Input Element dialog box, and click OK.
4.
The connection between the two is established. Repeat step 2 & 3 to connect
source2_1 to conveyor2_1.
Run Model
1.
Select Run / simulation / Simulate / Run.
2.
Enter 2000sec for Report Time in the Run dialog box, and click OK.
The model is simulated for the given time and terminate.
322
6
Final Assembly and Pull Model – Module summary
Summary
This module discussed each function of elements and stations for modeling
line assembly model. Also, described the underlying structure of pull system &
the element attributes that need to be set for pull system.
Coming Up
Wrap Up
Evaluations
1 hour
323
Wrap Up
The DELMIA – QUEST Advanced provides a flexible, object-based, discrete event
simulation environment combined with powerful visualization and robust import/export
capabilities that make it the engineering and management solution for process flow
simulation and analysis.
QUEST Advanced allows experimentation with facility layout, resource allocation
kaizen practices and alternate scheduling scenarios. It also facilitates effective
presentation of results to customers, managers and those in other engineering
disciplines. It provides a single model that can be integrated with existing design tools
for use from conceptualization to implementation including documentation, analysis
and communication of results.
QUEST Advanced provides and intelligent automated approach to analyses not
available in QUEST. This analysis automation increases user productivity.
Coming Up
Evaluations
324
AFTER TRAINING SUPPORT
AND SERVICES
www.delmiasupport.com
325
Professional Services
Professional services are available to
customers to provide on-site, “Over the
Shoulder” assistance with implementing
DELMIA solutions.
Contact your local DELMIA office for more
information
In the USA
248.267.9696
326
Please fill out and return the evaluations
327
Thank you
328