• No results found

Flexsim Basic Course

N/A
N/A
Protected

Academic year: 2021

Share "Flexsim Basic Course"

Copied!
123
0
0

Loading.... (view fulltext now)

Full text

(1)
(2)

Course Outline

• Chapter 1. Simulation basics

• Chapter 2. Flexsim basics

• Chapter 3. Flexsim terminology

• Chapter 4. Flexsim modeling steps

• Chapter 5. Flexsim object library

• Chapter 6. Commands and constructs

• Chapter 7. Concepts and models

(3)

Chapter 1

(4)

What is Simulation?

Simulation is the imitation of a system,

based on knowledge or assumptions

about the

behavior of the parts

of that

system,

with the purpose of obtaining insight in

the

behavior of the whole

system.

(5)

Problems solved with simulation

Service problems –

the need to process

customers and their requests at the highest

level of satisfaction for the lowest possible

cost.

Manufacturing problems –

the need to

make the right product at the right time for

the lowest possible cost.

Logistic problems –

the need to get the

right product to the right place at the right

time for the lowest possible cost.

(6)

Simulation uses

• improve equipment utilization

• reduce waiting time and queue sizes • allocate resources efficiently

• eliminate stock-out problems

• minimize negative effects of breakdowns

• minimize negative effects of rejects and waste • study alternative investment ideas

• determine part throughput times • study cost reduction plans

• establish optimum batch sizes and part sequencing • resolve material handling issues

• study effect of setup times and tool changeovers

• optimize prioritization and dispatching logic for goods and services • train operators in overall system behavior and job related performance • demonstrate new tool design and capabilities

(7)

Discrete Event Simulation

• Used to model systems which change

state at discrete points in time as a result

of specific events

• State variables:

– machine status (idle, busy, down, etc.)

– queue content

– operator availability, etc.

• System events:

– order arrival

– product movement

(8)

Chapter 2

(9)

Flexsim Basics

• A Flexsim model is basically a system of

queues, processes, and transportation.

• Processing is simply a forced delay.

• Transportation is the movement of an

entity from one resource to another.

• Queues develop naturally in a model

when upstream arrival rates exceed the

downstream processing rates.

(10)

Flexsim Basics

• Modeling objects typically include:

– fixed resources (i.e. queue, machines)

– shared resources (i.e. operators)

– mobile resources (i.e. forklifts, elevators).

• Entities flow through the model from one fixed

resource to another. We call these entities

“flowitems” in Flexsim.

• Flowitems hold information (i.e. labels and

itemtypes) that can be set and queried in the

model to define process times and make

(11)

Flexsim Basics

• Sometimes an operator must be available

before the processing time for a flowitem can

start, and sometimes the processing time

starts immediately upon entry into the fixed

resource.

• Sometimes the flowitems are carried to the

next fixed resource via a mobile resource,

and sometimes they are simply moved

(12)

Flexsim Basics

• Most modeling information is defined on

the fixed resources in a model. Such as:

– how long to process the flowitem

– where to send the flowitem next

– call a shared resource (operator) for

processing the flowitem

– call a mobile resource to transport the

flowitem to the next fixed resource

(13)

Chapter 3

(14)

Flexsim Terminology

• model

– a collection of object instances representing

an actual system -with just enough detail to answer

the questions you are concerned with.

• object

– a model building block with inherited

behavior, and user-definable attributes, variables,

and visual properties.

• library

– a list of class objects to be used in building a

model. Instances are created in the model when an

object is dragged from the library icon grid into one of

the view windows (orthographic, perspective)

(15)

Flexsim Terminology

• flowitem

– the entities that flow through a model such

as products, customers, paperwork, phone calls, etc.

are called flowitems.

• FixedResource class

– objects which receive and

send flowitems

– Processor – Queue – Conveyor

• TaskExecuter class

– shared resources and mobile

resources that perform assigned tasks

– Operator – Transport

(16)

Flexsim Terminology

• task

– a single instruction or action to be

performed by a TaskExecuter object.

• tasksequence

– a group of tasks to be

performed in a set order. A tasksequence is

sent to either a Dispatcher or TaskExecuter

object. A Dispatcher will queue a

tasksequence as necessary and send it to a

TaskExecuter as they become available.

(17)

Flexsim Terminology

• itemtype

– all flowitems have an attribute

called itemtype. It’s a numeric identifier used

to distinguish one “type” of flowitem from

another in processing and routing decisions in

a model.

• labels

– information may also be stored on

flowitems (and other modeling objects) in the

form of labels. You may define as many

labels on a flowitem or object as you would

like. Labels have a name and data. The data

may be numeric, string, list, or table

(18)

Flexsim Terminology

• ports

– objects have output, input and center

ports. Output-to-input port connections define

possible flowitem routes. Center port

connections are for referencing purposes,

and are typically used to define which

taskexecuter will be called for processing or

transportation. Port connections are made

and broken by holding a letter down on the

keyboard while click-and-dragging from one

object to another.

(19)

Flexsim Terminology

• triggers

– when key events occur on an object, a

trigger is fired. The user may specify a variety of

things they want to have happen when a trigger

fires. There are triggers for when a flowitem

enters or exits an object. There are triggers for

when a process time finishes or a repair time is

complete. Each type of object has a unique set

of triggers.

• message

– information sent from one object to

another. When the message is received, a

trigger is fired. A message is sent with a

command. Messages may be sent immediately

(sendmessage), or after a specified period of

(20)

Flexsim Terminology

• variables

– Objects have system variables

such as process time, maximum capacity,

speed, etc. that can be defined uniquely for

each instance. The Parameters window for an

object is typically used to edit variables.

• attributes

– Objects have physical attributes

such as size, location, rotation, 3D shape,

color, etc. that may be defined uniquely for

each instance. The Properties window for an

object is typically used to edit attributes.

• toolbox

– a collection of tools that are global in

(21)

Chapter 4

(22)

Basic Steps of Modeling in Flexsim

1 - Create a layout using library objects

2 - Make port connections

3 - Edit look and behavior of objects

4 - Compile and run the simulation

5 - View the results

(23)

Model 1

• Purpose

– Introduction to the 5 basic steps of model building using a single queue, single server system (post office)

• Description

– people arrive at a post office every 60 seconds on average. The statistical probability distribution which best simulates the inter-arrival pattern is an exponential distribution with a

location value of 0 and a scale value of 60.

– the service time at the one and only service window in the post office is lognormal(31,3.1,0.5) seconds.

– if the queue for the service window exceeds 20 people, new arrivals are routed out of the model as “unhappy customers”.

• Questions

– What’s the maximum and average time people wait in line? – How many unhappy customers?

(24)
(25)

Step 1. Create a layout

• Drag objects from the Library (icon grid) and drop them into the Orthographic Model View window using your mouse.

(26)

To scale or not to scale?

• Flowitems are passed from one object to the next in

zero time regardless of where objects are located.

• Convey time depends on the conveyor’s length and

speed.

• Transport time between objects depends on the

distance between the objects and speed, accel, decel.

• Grid size can be modified in the Settings menu.

• Length units are “user-definable” – consistency is the

key!

• The VisualTool object can be used to display a CAD

drawing as the floor plan for the model.

• After scaling the imported image/shape, the modeling

objects can be placed on the layout and sized to match.

(27)

Mouse operations

• View Window:

– Translate: left click-drag

– Tilt and Rotate: right click-drag

– Zoom: left&right click-drag (or scroll wheel)

• Object:

– Translate in X and Y: left click-drag on object

– Translate in Z: right&left click-drag on object

– X,Y,Z rotation: right click-drag on object

– Resize X and Y: left click-drag on yellow dot

– Resize Z: right&left click-drag on yellow dot (or use

scroll wheel when object is highlighted)

(28)

Highlighting and Selecting Objects

• Only one object can be highlighted (yellow box) in a given view window. • Multiple objects can be selected (red box) across views using

shift-click-drag and/or ctrl-click-shift-click-drag.

• Group editing can be performed on selected objects using the “Edit Selected Objects” menu on the Model View windows.

(29)

Step 2. Make port connections

• While pressing the “A” key, click-and-drag port connections

between the objects.

• These output to input port connections are needed between the

objects in your model that send and receive flowitems.

(30)

The purposes of port connections

• Output to input port connections are typically used for

passing flowitems.

• Center port to center port connections are typically

used for calling operators and transporters.

• Center port connections are a handy way to reference

other objects when writing code (

i.e. outobject(current,1)

references the object connected to output port 1

)

• Output to input port connections provide automatic

“handshaking” that is used in passing flowitems

– Flowitems are either pushed or pulled when port

connections are open at both ends.

– Opening ports may trigger events on the connecting

objects (useful in developing object behavior).

(31)

Keys used for port connections

A

Q

W

S

Disconnect Connect

(32)

Port connections

• Objects can have an unlimited number of ports.

• A port connection is needed for each possible

routing choice in the model.

• The actual port that a flowitem passes through

depends on the selected rule for the object that

is either doing the pushing or the pulling.

(33)

Viewing port connections

• Display of port

connections can be

turned off by using

the “Settings” option

in the Model View.

• The size of the ports

can also be adjusted

with the “Settings”

option (although not

recommended)

(34)

Full Port Display

• Input ports on left

• Output ports on right

• Center ports on

bottom

• Ports are numbered

top to bottom

• “V” click to display

input and outputs

• “C” click to display

(35)

Step 3. Edit the objects

• Parameters Window

– Double click (or right click then choose Parameters)

– Used to edit object specific stuff

• Properties Window

– Right click then choose Properties

– Used to edit and view general info on all objects

• Model Tree View

– All objects in the model listed in a hierarchal tree.

– Contains the underlying data structure for an object

– ALL info is contained in the tree (all other gui’s are

(36)

Parameters Window

• Each object class has its

own Parameters Window

• Parameters affect the time

that flowitems stay in an

object and how they are

routed from object to object.

• Apply

will accept changes

• OK

will accept changes and

close the window

• Cancel

will close the window

without accepting changes

• Properties

button opens the

Properties Window

(37)

Parameter tabs

• Parameters are grouped into tab pages by category

• Every fixed resource object will have a “Flow”, and a

“Triggers” tab (although some objects will have more

triggers than others)

(38)

Understanding the Pick List Combo Box

• The pick list

• The code template (friendly editing)

(39)

Code Template

• Brown text may be

replaced with any

valid Flexscript.

• These templates

can be customized

through the Code

Edit window (to be

taught later).

(40)

Properties Window

• Every object has the

same set of properties

tabs

• Visual Tab

– Look and size

• General Tab

– Port connections – Display switches

• Labels

– User defined attributes

• Statistics

– Throughput, states,

queuing, and stay times – Graphs, charts, readouts

(41)

Step 4. Compile and

Run the simulation

• Compile the model (create

an executable runtime)

• Reset, Run

• Control run speed with the

slide control (has no effect

on the simulation results)

• Experimenter is used to

define run length, number of

iterations, and number of

(42)

Step 5. View the results

• Create a Standard

Report or State Report

using the “Stats” menu

• Other reporting features

to be discussed later:

– VisualTool

• Dynamic text

– Recorder

• Time plots, histograms, pie charts, historical and statistical tabular data

– Triggers writing to

GlobalTables

(43)

Standard Report

• Display a tabular report (csv file in Excel) for all objects in model (or just those objects selected red).

• Choose from a list of standard system variables to include in report. • Or type in your own variables to add to the report

(44)
(45)

Flexsim State Report

• Percentage of total

simulation time an

object was in each

of its states.

• CSV format (default

viewer is Excel).

• State profile is listed

for each object

currently

selected

in

the model.

(46)

Model 2

• Purpose

– learn how to duplicate objects

– see affects of adding a second service window

– introduction to the “Send to port” field

• Description

– add another service window to the post office

• Questions

– answer the questions asked in model 1

– if the windows differ by the type of service they can

provide and 40% of the people need to use window

1 and 60% need to use window 2, how does the

(47)

Chapter 5

(48)
(49)

Flexsim Standard Objects

• Flexsim has 25

objects in the entire

library

• Your ability to model

will be determined

by how well you

understand these

basic 25 objects and

their 3 superclasses

(50)

FixedResource superclass

• FixedResource objects are the backbone of a

simulation model. They define the flow of the

model. Since flow is defined by the connecting of

output to input ports, FixedResources are

always connected together using the “A” key.

• FixedResources can:

– push or pull flowitems

– process flowitems (forced delay)

– queue up flowitems (accumulate up to maxcontent)

– call for an operator to be utilized

(51)

Dispatcher superclass

• The Dispatcher receives tasksequences and either queues them up, OR dispatches the tasksequences immediately to downstream

Dispatchers and/or TaskExecuters.

• A tasksequence is a list of tasks that must be executed in a defined order one after the other.

• Common tasks are actions such as travel, load, unload, utilize, sendmessage, delay and break.

• One tasksequence may preempt another tasksequence part way through the current one’s list of tasks. The preemption can either temporarily interrupt the current tasksequence or permanently destroy the current tasksequence and all sequences in queue.

• Tasksequences are created and dispatched automatically when the “Use Transport” or “Use Operator” boxes are checked on a

(52)

TaskExecuter superclass

• TaskExecuters are subclasses of the Dispatcher

and therefore know how to receive, queue up,

and dispatch tasksequences.

• In addition, TaskExecuters have the ability to

execute the tasksequences that they receive.

• The Operator, Transporter, Elevator, Robot,

Crane, and ASRSvehicle are all subclasses of

the TaskExecuter and therefore have similar

functionality.

(53)

Model 3

• Purpose

Simple model which uses several objects in the library

• Description:

A part enters a Separator every 20 seconds where it is split into 3 separate parts. The first part moves via an “s”-shaped conveyor to a Combiner where a total of 8 parts are packed on a pallet (supplied by another Source). The loaded pallet is then conveyed to a Sink.

The second part is conveyed to a Queue where it is then carried by an Operator to a MultiProcessor object where 3 separate processing steps are performed. The first step can complete on it’s own in 3

seconds. The second step requires an operator (same operator that delivered the part) and takes 4 seconds, and the third process can complete on its own in 5 seconds. A Transporter then picks it up and takes it to a Rack where it is stored.

The third part travels via FlowNodes to a Queue where 10 are accumulated before being released, one at a time, to a Processor

(54)
(55)

Model 3 Follow-up Work

Once you have finished the model, do the following:

• Create a Network path for the transport to follow when travelling between the MultiProcessor and the Rack.

• Use a 3D status pie chart to show the state profile for the operator. • Use 3D text to display the content of the Rack.

• View the model in the perspective view and experiment with different background colors.

• Learn how to apply new 3D shapes to the objects in your model. • Move the objects associated with each of the three flows into a separate VisualTool to create an hierarchal model.

(56)

Connecting Dispatchers and

TaskExecuters

(57)

NetworkNode

• A NetworkNode is used to define the path a

TaskExecutor will follow when executing its travel tasks.

• A path is made up of a group of NetworkNodes

connected together by using the “A” key.

• At least one NetworkNode needs to be connected to

each load and unload station (FixedResource) using the

“A” key.

• A Task Executor is assigned to a path by connecting it

to any NetworkNode in the path using the “A” key.

(58)

Connecting NetworkNodes

• Click-and-drag a

connection while

pressing the “A” key

• When connected

you will see a green

path between the

nodes denoting

(59)

Connecting Paths to the Model

• Click-and-drag a

connection while

pressing the “A” key

between the

NetworkNode and

the object where the

load takes place.

• A blue line will show

the connection. The

line does not

(60)

Connecting a TaskExecutor

to a Path

• Click-and-drag a

connection between

the TaskExecutor and

a NetworkNode while

pressing the “A” key.

• A red line will indicate

that the connection has

been made. The line

does not connect to

any port.

(61)

Single Direction Paths

• A path can be restricted to

travel in a single direction

by pressing the “Q” key

and clicking-and-dragging

in the direction you want

to disallow travel.

• A red line (right side rule)

will show the restricted

direction.

(62)

Non-Passing Paths

• A non-passing path

can be defined by

using the “A” key

and

click-and-dragging between

two nodes that are

already connected.

• Non-passing path

segments turn a

yellow color.

No traveling

(63)

Path Spline Points

• Every path has a spline

point in the center of the

path by default.

• Spline points allow

paths to be curved.

• Add spline points by

pressing “X” and

clicking on an existing

spline point.

• Delete spline points by

selecting them and

(64)

Hide Splines, Paths and

NetworkNodes

• The display options

for a path system

can be toggled by

holding the “X” key

down and then

clicking on any

NetworkNode in the

path system.

(65)

Chapter 6

Basic Modeling Functions and

Logic Statements

(66)

Available Help

– Hints

– Commands

– Sample Models (Help menu)

– Existing picklist options

(67)

General rules

• language is case sensitive (A does not equal a)

• no specific format is required (free use of spaces, tabs and line

returns is encouraged for “readable” code)

• numbers are double precision unless otherwise specified.

• text strings are entered between quotes.

“mytext”

• parenthesis follow a function call and commas separate the

arguments of the function.

moveobject(object1,object2);

• a function or command will always end with a semi-colon

• parenthesis can also be used freely to make associations in

your math and logic statements.

• curly braces (ie { }) are used to define a block of statements.

• to comment out the rest of a line use

//

• don’t use spaces or special characters in name definitions (

_

is

ok).

(68)

Math Operators

• x+y

• x-y

• x*y

• x/y

• sqrt(x)

• pow(x,y)

• round(x)

• frac(x)

• fmod(x,y)

x plus y

x minus y

x times y

x divided by y

square root of x

x to the power of y (x

y

)

x rounded to the nearest integer

returns the decimal portion of x

returns the remainder of x/y

(69)

Comparing

• x > y

• x < y

• x >= y

• x <= y

• x == y

• x != y

• comparetext(string1,string2)

x greater than y

x less than y

x greater than or equal to y

x less than or equal to y

x equal to y

x not equal to y

(70)

Relating

• &&

• ||

• !

• min(x,y)

• max(x,y)

logical AND

logical OR

logical NOT

returns minimum of x and y

returns maximum of x and y

(71)

Updating

• x = y

• x += y

• x -= y

• x *= y

• x /= y

• x ++

• x --

set x to y

set x to x plus y

set x to x minus y

set x to x times y

set x to x divided by y

add 1 to x

subtract 1 from x

(72)

Variable Types

• int

• double

• string

• fsnode*

integer

double precision

text string

(73)

Declaring and Setting Variables

• int index = 1;

• double weight = 175.8;

• string category = “groceries”;

(74)

What is a Node?

• Basic data structure of Flexsim is a hierarchal tree

– main (model and project related objects and data)

– view (gui related objects and picklists)

• The node is the basic building block of a tree

• Nodes hold all the information behind the scenes

for objects, gui’s and data.

(75)

Node Structure

• Nodes have a name

• Nodes can have a data item

– number

– string

– object

• If nodes have object data, use > to view a

separate node list containing the object info

(data members and member functions)

(76)

Node Symbols

Standard Folder

Object

Object data

Function (C++)

Function (FlexScript)

(77)
(78)

Basic Object Referencing

• current

• item

• rank(

node,ranknum

)

• inobject(

object,portnum

)

• outobject(

object,portnum

)

• centerobject(

object,portnum

)

• model()

the current object

the involved flowitem

rank(current,3)

inobject(current,1)

outobject(current,1)

centerobject(current,1)

model()

(79)

Basic Object Attributes

• getname(

object

)

• setname(

object, “name”

)

• getitemtype(

object

)

• setitemtype(

object, num

)

• setcolor(

object, red, green, blue

)

(80)

Object Spatial Attributes

• xloc(

object

)

yloc(

object

)

zloc(

object

)

• setloc(

object, xnum, ynum, znum

)

• xsize(

object

)

ysize(

object

)

zsize(

object

)

• setsize(

object, xnum, ynum, znum

)

• xrot(

object

)

yrot(

object

)

zrot(

object

)

• setrot(

object, xdeg, ydeg, zdeg

)

(81)

Basic Object Statistics

• content(

object

)

• getinput(

object

)

• getoutput(

object

)

• int inventory = content(current);

(82)

Object Labels

• syntax

– getlabelnum(

object, “labelname”

)

– setlabelnum(

object, “labelname” , value

)

– getlabelstr(

object, “labelname”

)

– setlabelstr(

object, “labelname” , string

)

– label(

object, “labelname”

)

examples

getlabelnum( item, “serialnumber” )

setlabelnum( item, “serialnumber”, 5 )

getlabelstr( current, “category” )

(83)

Global Tables

• gettablenum(

“tablename”, rownum, colnum

)

• settablenum(

“tablename”, rownum, colnum, value

)

• gettablestr(

“tablename”, rownum, colnum

)

(84)

Logical ‘if’ Statement

if (test expression)

{

code block

}

else

{

code block

}

if (content(item) == 2)

{

colorred(item);

}

else

{

colorblack(item);

}

(85)

Logical ‘while’ Statement

while (test expression)

{

code block

}

while (content(current) > 0)

{

destroyobject(last(current));

}

(86)

for (start expression;

test expression;

count expression)

{

code block

}

for (int index = 1;

index <= content(current);

index++)

{

colorblue(rank(current,index));

}

(87)

switch ( switchvariable )

{

case casenum:

{

code block

break;

}

default:

{

code block

break;

int type = getitemtype(item); switch (type) { case 1: { coloryellow(item); break; } case 5: { colorred(item); break; } default: { colorgreen(item); break;

(88)

Code Exercise 1

• Purpose

– Gain experience in writing C++ code in the Code Edit

windows.

– Introduction to PROSESTART and PARAMSTART

statements and how they define the Template

windows.

– Introduction to the bernoulli command.

• Description

– See layout slide for model description.

– Using the “Send To Port” field of the Conveyor, send

30% of the flowitems to port 1 and 70% to port 2.

(89)
(90)

Code Exercise 2

• Purpose

– Learn how to both set and read the itemtype of a flowitem using C++

• Description

– See layout slide for model description.

– Set the itemtype of flowitems as they exit the Source.

– 60% of the flowitems are itemtype 7, the rest are itemtype 3. – Using an “if” statement in the “Send To Port” field of the

Conveyor, send flowitems with itemtype 7 to port 1, and those with itemtype 3 to port 2.

• Questions

– Can you change the color of the Flowitems based on their itemtype using code?

(91)

Code Exercise 3

• Purpose

– Learn how to both set and read the labels on a flowitem using C++

• Description

– See layout slide for model description.

– Create a numeric label named “routing” on the Textured Colored Box in the FlowItem Bin (see toolbar).

– Set the “routing” label of flowitems as they exit the Source with a random number between 1 and 4 (use duniform() command). – Use a switch() statement in the “Send To Port” field of the

Conveyor to send flowitems according to the following

• Label values 1 and 3 go to port 2

• Label values 2 and 4 go to port 1

• Questions

(92)

Code Exercise 4

• Purpose

– Learn how to write your own “for” loop.

• Description

– A Combiner packs 8 boxes on a pallet.

– Use an infinite supply of pallets from one Source and an infinite supply of boxes from another Source.

– The Combiner sends to a Conveyor which then sends to another Conveyor.

– Using the OnExit trigger of the first Conveyor, write a for loop which changes the color of all the boxes on the pallet.

• Questions

– Can you change the 3D shapes of the boxes on the pallet with the setobjectshapeindex() command?

(93)
(94)

Chapter 7

(95)

Modeling Concepts

• FlowItem Bin

• Arrivals (interarrival time, schedule,

sequence, initial stock)

• Labels and itemtypes

• GlobalTables

(96)

Modeling Concepts

• Push versus pull

• MTBF/MTTR

• Time Tables

• Experimenter and Optimizer

• Manual tasksequence creation

• 3D shapes and animation

(97)

Modeling Concepts

• Data import and export

• Data capturing and reporting

• Fly through presentations

• Debugging tips

• Global object pointers

• Flow control (close and open ports)

• Messaging (delayed messages)

(98)

Model 4

• Purpose

– Learn how to use pull logic in defining routings based on a flowitem’s itemtype.

• Description

– Electronic components need to be tested after manufacture. – There are two types of components that arrive in a queue at

random with the mix being 40% of one and 60% the other. – The inter-arrival time of components is exponential(0,30,1) – There are two testers for component 1 and three testers for

component 2. Components will go to the first available tester. – Service times are all between 120 and 150 seconds uniformly

distributed.

• Questions

(99)
(100)

Model 5

• Purpose

– Learn how to assign and use labels on flowitems for routing and processing purposes. Learn how to use an empirical distribution to assign itemtypes.

• Description

– Parts arrive in a queue every 30 seconds exponentially distributed. There are four part types distributed as follows: 20%, 30%, 40%, 10%.

– The four part types are each processed on one of four dedicated

machines. The processing times at each machine is uniform(100,120) seconds for first time parts, and uniform(120,130) seconds for rework parts.

– After the parts are machined, they are put in a queue and wait to be tested. The test time is a constant 10 seconds. Parts that pass, leave the model, failed parts are routed back to the first queue to be

reworked. 10% of the parts fail.

– Parts being reworked are given priority in the queue.

(101)
(102)

Model 6

• Purpose

– Learn how to us an Operator to both carry and process flowitems

• Description

– Parts arrive at a queue every 20 seconds exponentially

distributed and need to be carried by the operator to one of 3 machines.

– The operator needs to setup the part which takes 10 seconds. – The part can then run for 20 seconds on its own.

– When the part finishes, it will leave the system. – One operator will run all three machines.

• Questions

(103)
(104)

Model 7

• Purpose

– Learn how to use the “Break To” Requirement field on TaskExecuters.

• Description

– A Source continuously sends Flowitems randomly to 3 Queues. – Flowitems are assigned an itemtype 1,2,3 uniformly distributed. – All three Queues can hold all three itemtypes.

– A Transporter carries Flowitems to three Queues that each hold 1 itemtype.

– These Queues then go to Processors and a Sink. – The Transporter can carry up to 5 items at a time.

– The Transporter should only carry items that have the same itemtype at any time.

• Questions

(105)
(106)

Model 8

• Purpose

– More practice working with Operators, priorities and preempting

• Description

– A single work cell has 5 machines.

– Each part must be processed at each of the 5 machines – There are 3 operators who work in the cell as a team.

– The operators need to carry each part to the next machine as well as set up the machine for that part.

– Setup times are 5 seconds and process times are 15. – New parts arrive in the system every 25 seconds.

• Questions

– What’s the throughput rate per hour?

– Experiment with priorities and preempting to try and improve the throughput rate.

(107)
(108)

Model 9

• Purpose

– Small example of using a Global Table to define product routings.

– Learn how to use a label to keep track of what step its on.

• Description

– 3 different products (uniform) enter a 5 station work cell. – Product 1 needs to be processed at station 1,3, and 2. – Product 2 needs to be processed at station 1, 2, and 4. – Product 3 need to be processed at station 2,4,3, and 5.

– Use a global table to make sure the products are sent to the right station in the proper sequence.

– Use a single Queue who’s output ports are connected to each of the 5 stations and to a Sink. Each of the five stations have their output port also connected to the input ports of the Queue.

• Questions

(109)
(110)

Model 10

• Purpose

– Learn how to manipulate the Components List table on a Combiner object to do custom packing on the fly

– Learn how to import and use a Source arrival schedule

• Description

– A small distributor has 10 product types that he ships to the same 5 customers.

– Each customer has a different order profile.

– The distributer has a large supply of each of the 10 products so all he has to do is wait for an order to come through the door.

– Products are placed on a pallet and then conveyed out. – Use the next two tables to build the model.

• Questions

(111)
(112)

Model 10 Order Table

2 1 4 2 1 prod 9 0 3 3 3 2 prod 8 3 2 2 0 0 prod 7 0 2 0 4 2 prod 6 1 0 3 3 3 prod 5 2 3 1 2 1 prod 4 2 1 0 1 0 prod 3 1 2 1 0 2 prod 2 4 1 3 2 1 prod 1 Customer 5 Customer 4 Customer 3 Customer 2 Customer 1

(113)

Model 10 Daily Arrival Schedule

10 5 E 14400 Customer 5 10 4 D 10800 Customer 4 10 3 C 7200 Customer 3 10 2 B 3600 Customer 2 10 1 A 0 Customer 1 Quantity ItemType ItemName ArrivalTime

(114)

Model 11

• Purpose

– Gain experience in building an abstract model – Learn to write some C++ in a trigger field

• Description

– Items arrive at a warehouse each day to be stored. – Orders arrive at a warehouse each day to be pulled.

– The average number of items and orders received each day is 10, but both are exponentially distributed.

– There are only 5 types of items (and therefore orders) received. The type of received items and orders is uniformly distributed 1 through 5 on a daily basis. – Whenever an order arrives it must search for a matching item and remove it. – Whenever an item arrives it must search for a matching order and remove it. – 1 model time unit = 1 day.

• Questions

– How big must the warehouse be, so there is always room to store the items received each day?

– Plot the number of unsatisfied orders each day for an entire year. – What’s the average number of days an order waits to be satisfied?

(115)
(116)

TaskExecuter Control

• requestoperators(

taskexecuter, station, involvedobj, nrofops,

priority, preempting

)

• freeoperators(

taskexecuter, involvedobj

)

• createemptytasksequence(

taskexecuter, priority,

preempting

)

• inserttask(

tasksequence, tasktype, involved1, involved2,

parameter1, parameter2, parameter3

)

(117)

Sample code for tasksequences

fsnode *forklift = centerobject(current,1);

fsnode *origin = centerobject(current,2);

fsnode *destination = centerobject(current,3);

fsnode *item = first(origin);

fsnode *ts = createemptytasksequence(trans,0,0);

inserttask(ts, TASKTYPE_TRAVEL, origin, NULL);

inserttask(ts, TASKTYPE_FRLOAD, item, pickup);

inserttask(ts, TASKTYPE_TRAVEL, destination, NULL);

inserttask(ts, TASKTYPE_FRUNLOAD, item, destination);

(118)

Task Types

TASKTYPE_LOAD: flowitem, pickup

TASKTYPE_FRLOAD: flowitem, pickup, outputport

TASKTYPE_UNLOAD: flowitem, dropoff

TASKTYPE_FRUNLOAD: flowitem, dropoff, inputport

TASKTYPE_UTILIZE: involved, station, state

TASKTYPE_STOPREQUESTFINISH: stoppedobject, NULL

TASKTYPE_TRAVEL: destination, NULL

TASKTYPE_TRAVELTOLOC: NULL, NULL, xloc,yloc,zloc, endspeed

TASKTYPE_TRAVELRELATIVE: NULL, NULL, xloc,yloc,zloc, endspeed

TASKTYPE_BREAK: NULL, NULL

TASKTYPE_DELAY: NULL, NULL, delaytime, state

TASKTYPE_SENDMESSAGE: receiver, NULL, param1,param2,param3

TASKTYPE_MOVEOBJECT: flowitem, container, port

TASKTYPE_DESTROYOBJECT: object, NULL

(119)

Model 12

• Purpose

– Learn how to manually build your own tasksequences

• Description

– The model consists of a Source, three Processors in series, and a Sink.

– An operator must pick up a part from the source, carry it to the first processor, be utilized for the process time, carry the part to the next processor, etc. until finally dropping it off at the sink. – Use Global Object Pointers instead of center port connections.

• Questions

(120)
(121)

Basic Object Control

• closeinput(

object

), openinput(

object

)

• stopinput(

object

), resumeinput(

object

)

• closeoutput(

object

), openoutput(

object

)

• stopoutput(

object

), resumeoutput(

object

)

• sendmessage(

toobject, fromobject, parameter1,

parameter2, parameter3

)

• senddelayedmessage(

toobject, delaytime,

fromobject, parameter1, parameter2, parameter3

)

(122)

Model 13

• Purpose

– Learn how to control product flow and send delayed messages.

• Description

– Assume an infinite supply of A and B components.

– The two components must be glued together with epoxy which takes lognormal(0,2.6,0.8) seconds.

– The assembled parts must wait in a staging area for at least 15 seconds for the epoxy to cure before they can enter the paint booth.

– It takes lognormal(0,2.5,0.5) seconds to paint each part separately.

– After each part is painted and exits the paint booth, the booth must be purged for 3 seconds before another part can enter.

• Questions

(123)

References

Related documents

No Post-Scriptum às Migalhas Filosófi cas, de 1846, há uma tese profundamente instigante sobre essa relação de Kierkegaard com a herança clássica e a herança cristã e, por

Other Routers VC Allocator Input Port VC state crossbar switch Routing Module Switch Allocator Input Port VC state Output Port Output Port crossbar switch

Full Scale Should be set to the value on the possible output on the analog hardware port Source input that will create the highest Port Defines the hardware port where the

The figure below shows the circuit diagram used to interface 16-bit output port.. Two latches are used to connect 16 LEDs with

The purpose of this study was to validate the identification and determine the genome sizes and ploidy of a diverse collection of Deutzia species and hybrids using cytology and

Ckp vzkhq`xkp iäp a`kgðio`kp y ha Ckp vzkhq`xkp iäp a`kgðio`kp y ha idykz `kgpqik apxdjdg ag ac idykz `kgpqik apxdjdg ag ac panqghk vopk' Vdzd kjxagazckp ac panqghk vopk'

flocculation or conditioning and the filtration rate is much higher: the rate may vary from 6000 to 15,000 litres per hour per m 2 of filter area. This makes this type of filter