MIE360-无代写
时间:2023-10-22
MIE 360: Systems Modelling and Simulation (Fall 2023)
Homework 5
• Due by Friday October 27, 10:00 a.m. sharp. For every day the assignment is late, 10%
will be deducted from your mark.
• Submit your solutions online on Quercus as a single pdf file. Include at the top of
the first page your name and student number. You are strongly encouraged to
typeset your solutions.
• You may do the homework individually or in pairs. If doing it as a pair, write both
names and student numbers at the top of the first page. Only one of you should submit
the solutions. You will receive the same mark.
• Please show your work and clearly mark your answers. We will separately deduct up to
20% of the potential grade for this assignment if your work is messy or disorganized.
• For questions requiring coding, you must include both the Python / R source
code (including comments to make it easy to follow) and the output.
• You may use the QueueingTools.xls spreadsheet unless stated otherwise in
the question. However, make sure to clearly specify the queueing model you
are using as well as its parameters.
1. (40 pts) The table below provides samples of the number of defects in 20 production
batches. You suspect that the number of defects follows a Geometric distribution with
PMF P (X = k) = (1− p)kp for k = 0, 1, 2, 3, . . . .
Batch 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 Sum
Defects 2 4 15 0 4 0 3 1 0 7 13 3 2 0 0 7 1 5 2 1 70
(a) What is the MLE estimate of the probability of success p based on the observed
samples? HINT: You can use the MLE estimator for the parameter of the Geometric
distribution derived in the lecture without proof.
(b) You have decided to conduct a χ2 Goodness of Fit test to asses your hypothesis using
the following four bins: [0,1), [1,3), [3,5), [5,∞). Calculate the value of the χ2 statistic.
Is there enough statistical evidence to reject the null hypothesis at the significance level
of α = 0.05?
(c) Explain in one sentence how the conclusion in part (b) is affected by the small
sample size.
(d) Repeat the same test in R and compare the result with you obtained in parts (b)
and (c). Does your test statistic match with the output of the software? Why?
2. (60 pts) Consider a queueing-network model of a Hospital shown below. Suppose new
patients arrive at the reception at a rate of 24/hr and emergency patients enter the ER
at a rate of 6/hr. The reception desk for non-emergency patients is managed by three
associates. Admission at the reception (not counting any queueing time) takes 4 minutes
on average, regardless of whether the non-emergency patient is first-time or returning.
The clinic is served by dC doctors with an average visit time of 15 minutes. About one
in every four patients visiting the clinic are asked to return for a follow-up appointment
that is, on average, 3 weeks (504 hours) later in time. Two in every ten visitors to the
clinic is referred to the internal ward (IW). Others are treated and discharged. Patients
arriving to the ER require about 1 hour of time with a doctor. The ER is staffed by
dE doctors. Half of the patients in the ER are discharged after treatment, with the
remainder referred to the IW. The average stay in the IW is about 55 hours and there
are n IW beds available. After a stay at the IW, 30% of patients are discharged, whereas
the rest are asked to return for a follow-up appointment as a non-emergency patient that
is, on average, 3 weeks (504 hours) later in time.
Reception Clinic
IW
ER
Home
discharged patients emergency arrivals
new arrivals
reappointments returning patients
(a) What is the minimum number of beds and doctors to ensure that the hospital can
keep up with its patient load, i.e., the queueing network is stable?
(b) Suppose the hospital chooses to run with dE = 7 doctors in the ER, dC = 12 doctors
in the clinic, and n = 650 beds in the IW. Approximate the average time spent
in the clinic (including treatment but not including reception) and the average
number of busy clinic doctors assuming that all external inter-arrival times are
exponentially distributed, all routings are independent, and all service times in the
hospital are exponentially distributed.
(c) Suppose the hospital chooses to run with dE = 7 doctors in the ER, dC = 12
doctors in the clinic, and n = 650 beds in the IW. Compute the probability that
the hospital will simultaneously have no patients in the ER and no patients in the
clinic. Assume that all external inter-arrival times to each unit of the hospital are
exponentially distributed, all routings are independent, and all service times in the
hospital are exponentially distributed.
2