Lesson 3-Discrete Event Simulation
Lesson 3-Discrete Event Simulation
Random numbers are a necessary basic Notice that the title of this section has the
ingredient in the simulation of almost all discrete word “pseudo” in it. “Pseudo” means false, so false
systems. Most computer languages have a random numbers are being generated! In this
subroutine, object, or function that will generate a instance, “pseudo” is used to imply that the very act of
random number. generating random numbers by a known method
removes the potential for true randomness. If the
Random numbers are used to generate event method is known, the set of random numbers can be
times and other random variables in simulation repeated. Then an argument can be made that the
languages. In this chapter, the generation of random numbers are not truly random. The goal of any
numbers and their subsequent testing for generation scheme, however is to produce a
randomness is described. sequence of numbers between 0 and 1 that simulates
3.2 PROPERTIES OF RANDOM NUMBER or imitates, the ideal properties of uniform distribution
and independence as closely as possible.
A sequence of random number R1, R2 ….,
To be sure, in the generation of pseudo-
must have two important statistical properties:
random numbers, certain problems or errors can
uniformity and independence.
occur. These errors, or departures from ideal
Each random number Ri must be an randomness, all related to the properties stated
independent sample drawn from a continuous previously.
uniform distribution between zero and 1.
Some example of such departures include the should be possible to easily specify different
following: starting points, widely separated, within the
sequence.
1. The generated numbers might not be
5. Most important, the generated random numbers
uniformly distributed.
should closely approximate the ideal statistical
2. The generated numbers might be discrete-
properties of uniformity and independence.
valued instead of continuous-valued.
3. The mean of generated numbers might be too Inventing techniques that seem to generate
high or too low. random numbers is easy; inventing techniques that
4. The variance of the generated numbers might really produce sequences that appear to be
be too high or too low. independent, uniformly distributed random numbers
5. There might be dependence as measured, for is incredibly difficult. There is now a vast literature and
instance, by autocorrelation. rich theory on the topic, and many hours of testing
have been devoted to establishing the properties of
Departures from uniformity and
various generators.
independence for a particular generation scheme
often can be detected by tests. If departures are Even when a technique is known to be
detected, the generation scheme should be dropped theoretically sound, it is seldom easy to implement it
in favor of an acceptable generator. in a way that will be fast and portable. The goal of this
chapter is to make the reader aware of the central
Usually random numbers are generated by a
issues in random-number generation, to enhance
digital computer as part of the simulation. There are
understanding, and to show some of the techniques
numerous methods that can be used to generate the
that are used by those working in this area.
values. Before we describe some of these methods,
there are several important considerations that we Example of a generated Pseudo-Random Number
should mention:
A basic test that should always be performed In this section, a method for discovering
to validate a new generator is the test of uniformity. whether such a relationship exists is described. The
Two different methods of testing are the Kolmogorov- relationship would not have to be all high numbers. It
Smirmov and the chi-square test. Both test measures is possible to have all low numbers in the locations
the degree of agreement between the distribution of a being examined, or the numbers could alternate from
sample of generated random numbers and the very low to very high.
theoretical uniform distribution. Both tests are based 3.4 MECHANICS OF DISCRETE SIMULATION
on the null hypothesis of no significant difference
between the sample distribution and the theoretical As an example, let’s think about a logistics chain
distribution. involving a truck:
1. it arrives at a warehouse;
2. it enters a loading gate;
3. it unloads its supplies;
4. and then it leaves the warehouse. In the
example above, you will see that each step is a
separate — i.e., discrete — event. In order to
simulate this process, you will typically use a
discrete event simulation model.
MANUFACTURING AND MATERIAL HANDLING 7. Production schedules
SIMULATIONS
a) Made-to-stock
Manufacturing and Material Handling Simulations b) Made-to-order
Customer order
As do all modeling projects, manufacturing Line items and quantities
and material handling simulation projects need to
8. Production control
address the issue of scope and level of detail.
Consider scope as analogous to breadth and level of a. Assignment of jobs to work areas
detail as analogous to depth. b. Task selection at workcenters
c. Routing decisions
The proper scope and level of details should
be determined by the objective of the study and the 9. Supplies
questions being asked.
a) Ordering
On the other hand, level of detail could be b) Receipt and storage
restrained by the availability of input data and the c) Delivery to workcenters
knowledge of how system components work.
10. Storage
MODELS OF MANUFACTURING SYSTEM
a. Supplies
Models of manufacturing systems might have b. Spare parts
to take into account a number of characteristics of c. Work-in-process (WIP)
such systems, including some of the following: d. Finished goods
The purpose of simulation is insight, not Unscheduled random downtimes can have a
numbers. major effect on the performance of manufacturing
systems. Many authors have discussed the proper
Those who purchase and use simulation
modeling of downtime data.
software and services want to gain insight and
understanding into how a new or modified system will There are a number of alternatives for modeling
work. random unscheduled downtime, some better than the
others:
Will it meet throughput expectations? What
happens to response time at peak periods? 1. Ignore it
2. Do not model it explicitly, but increase
Is the system resilient to short-term surges?
processing times in appropriate proportion
What is the recovery time when short-term surges
3. Use constant values for the time to failure and
causes congestion and queueing?
time to repair
Simulation are expected to provide numeric 4. Use statistical distribution for time to failure
measures of performance, such as throughput under and time to repair
a given set of conditions, but the major benefit of
Alternative one (1) is not the suggested general
simulation comes from the insight and understanding
approach. This is certainly an irresponsible modeling
gained regarding system operations.
technique if downtimes have an impact on the results,
The major goals of manufacturing-simulation as they do in almost all situations. One situation in
model are to identify problem areas and quantify which ignoring downtimes could be appropriate, with
system performance. Common measures of system full knowledge of the customer, is to leave out the
performance include the following: catastrophic downtimes that occur rarely and leave a
production plant or line for a long period of time.
• Throughput under average and peak loads;
• System Cycle time (how long it takes to In other words, the model would incorporate
produce one part); normal downtimes but ignore those catastrophic
• Utilization of resources, labor and machines; downtimes, such as general power failures, snow
• Bottlenecks choke points; storms, cyclones and hurricanes, that occur rarely,
• Queueing at work locations; but stop all production when they occur.
• Queueing and delays caused by material- The second possibility, to factor into the model
handling devices and systems; the effect of downtimes by adjusting processing times
• WIP storage needs; applied to each job or part, might be an acceptable
• Staffing requirement; approximation under limited circumstances. If each
• Effectiveness of scheduling systems; job or part is subjected to a large number of small
• Effectiveness of control systems; delays associated with downtime of equipment or
tools, then the total of such delays may be added to
Issues in manufacturing and material-handling
the pure processing time to arrive at an adjusted
simulations
processing time.
There are a number of modeling issues If total delay time and pure processing time
especially important for the achievement of accurate are random in nature, then an appropriate statistical
and valid simulation models of manufacturing and distribution should be used for the total adjusted
material-handling systems. Two of these issues are processing time. If the pure processing time is
the proper modeling of downtimes and whether, for constant while the total delay time in one cycle is
some inputs, to use actual system data or a statistical random and variable, it is almost never accurate to
model of those inputs. adjust the processing time by a constant factor.
The third possibility, using constant durations
for time to failure and time to repair, might be
appropriate when, for example the downtime is
actually due to preventive maintenance that is on a
fixed schedule.
Time to failure
1. By wall-clock time;
2. By machine or equipment busy time;
3. By number of cycle times;
4. By number of items produced.
Breakdown/Failure