UNIVERSITI SAINS MALAYSIA Second Semester Examination
Academic Session 2007 12008
April 2008
MSG 253 - Queueing Systems and Simulation fSrlsfem Giliran dan Simulasil
Duration :3 hours [Masa :
3jamJ
Please check that this examination paper consists of FIFTEEN pages of printed material before you begin the examination.
[Sila pastikan bahawa keftas peperiksaan ini mengandungi LIMA BEI-AS muka surat yang bercetak sebelum anda memulakan peperiksaan ini.l
Instructions: Answer all three [3] questions.
Aranan:. Jawab semua tiqa [3] saalan.l
l' (a) A queueing
Processthat
is basedon
thebirth and death
process has thefollowing birth and death
rates:Ar=T-a, .4 for
n = 0,'1,, 2, 9,....w+ t)
Itr= F, fot n='!.,2,3,....
(i) Draw
arate-diagram
torepresent
thequeueing system.
(ii) Showthat p,= P' ,-c
nl
,where p=l
.(iii) Next, show that Ir= p -
7 +e-p
.lt
[50
marks]
(b) the
Pulau PinangDaity Bugle
operates apopular sport wire service, which allows people to call the
specialnumber requesting ,.o.e, of national and local sports events'
Thenewspaper
has assigned oneclerk to answer
thequestions of
thosewho
?U i"' On
average, callsarrive
at therate of
45per hour and
are assumedto follow the Poisson distribution. It
takes(on
average) 1minute to handle
eachcall and the service time is assumed
to beexponential. If
theclerk
isbusy when
acall arrives, the caller
isplaced
onhlfd until
theclerk
is free.(i) What proportion of
thetime
does theclerk actually spend handling
these calls?liil How many callers,
on average, arewaiting for the clerk?
(iii) How many callers, on
average, arebeing served or waiting for
service?(iv) what
isthe
averagetime, in minutg
eachcaller waits for the clerk?
(v) what is the
averagetime in minutq that
eachcaller
spendswaiting and having his or her question answered?
(vi) What is
theprobability that exactly four callers
arewaiting or being
served?(vii) What is
theprobability that more than six callers
arewaiting or being
served?(viii) If
acaller
hasto wait, what
isthe
averagetime spent waiting?
(ix) What is the
averagenumber of
callerswaiting auring thoseleriods that
awaiting line
exists?3 [MSc 2531
L. (a)
Suatu prosesgiliran
yang berasaskdn kepada proseslahir
danmati
mempunyai kadar kelahiran dankmtatian
sepertiberkut:
^1
7_=-7---- " l"+l) ,
bagt n = 0,L,2,
3, ..../Jn=
It ,
bagi n =L,2,
3, '.'.G)
Lukiskan gambar rajah kadar yang mmsakili sistemgiliran tnsebuL
Gi) TuniukkanbahautaP"= nnl
7e-p ,Affigmana p=!.
(iiil
Kemudian,tunjukkan
bahawa 14= p -
1 +s-e
.[50 markah]
ft)
Syarikat suratWtabarPulau Pinang Daily Bugle
mmyediakanpnkhidmatan
talian-sukan bagi membolehkan orang ramai menelefon danbntanyakEutusan
acara sukan kebangsaan dmt antarabangsa. Seorangkuani
ditugaskanuntuk
menjawab lemuf, panggilan. Pada puratanyn, panggilan diterima dmgan kadar purata 45 sejam mengikut agihan Poisson. Masa puratauntuk
melayan setiap panggilan ialalt 1-minit
mengikut agihan eksponen.likakrani
sedang sibuk setflasa ketibann sesuatu panggilan,
panggilan itu
akan dileta]*.an dalam keadann menunggu sehinggalah ksani itu
b er smang.(i) Apokdt
peratusan masadaipaila
masa bekerjanya yang diganakan aleh keraniuntuk
menjawab panggilan?(ii)
Berapakahbilanganpnnanggil
secaru puratn yang ffienunggu kerani?(iii)
Berapakahbilanganpemanggil secarapuratayang sedang dilayan atau seilangmenunggukqani?
(ia)
Buapakah tnasa purata, dalamminit,
setiappmranggil
menunggu kerani?(v)
Bnapakah masa purata, dalamminit,
setiap pemanggil menunggu dan dilayan oleh kerani?(ot)
Apakah kebarangknlian balrmua empat orang pemanggil sedangmmunggu
atau sedang dilayan?(aiil
Apakahkebarangkalianbahawalebih daripadn otam orangpetttanggil sedang menunggu atau sedang dilayan?(viii)
Jika seseorangpnnanggil itu trpaksa
rnerrunggu, burpakah masa purata menunggunya?Gx)
Berapakah bilangan purata pemanggil yang menunggu sauaktubaisan
menungguterbmtuk?
Suppose
that
ascalls arrive
atthe switchboard, only five lines
areavailable for incoming calls to the sport wire clerk. One
of theseis actually connected to the clerk and the other four, if
necessary, areused for
callsput
onhold. If all five lines
arein
use,
any incoming call will
receive abusy signal and will
be,in effect, tumed away.
Assrime that such callers will then tum to
arival newspaper with their
request.(x) What proportion of time
does thederk actually spend answering questions?
(xi) l4lhat proportion of
calls areturned away by
thebusy signat?
(xii) what is the
averagenumber of phone lines tied up by the sport wire?
(xiii) How long on
averagedo the callers spend waiting for the clerk?
(xiv) How long
doesit
takefrom
thetime
acaller
isput
onhold until the question
has beenanswered?
(xv) A follow-up study
hasbem done that show that
Lpercent of customers who
usethe sport wire
serviceeventually
becomesubscribers to
thenewspaper.
An annual subscription to
thepaper
isestimated
tocontribute RM10 to profit. The
costof
leasingadditional phone lines
isknown to
be RM400per year. How many additional phone lines, if any, should
thenewspaper
leasefor the sport wire? (Aszume that the sport wire service is opened
12hours
aday,365 days
ayear)
[50
marks]
2. (a) A power plant operating
24hours per day
hasfour idmtical turbine generators,
eactr capableof producing
3megawatts of power.
Thedemand
atany time is
5megawatts,
sothat when all four turbines
arein working conditiorg
one iskept on "warm- standby'',
oneon "cold-standby'', and the other two
arein full operation. If
oneturbine is down, then two
areoperating and
oneis
onwarm-standby. If two
aredown, both working turbines
areoperating. If only
oneturbine
isworking, then the comPany must purdtase
3megawatts
ofpower from another source. If all furbines
aredown, the company must purchase
6megawatts.
If
aturbine is in the operating mode, its
meantime to failure is
3weeks. If
aturbine is in warm-standby, its mean time to failure
is 9 weeks.The company
hastwo
technicians that
canrepair failed turbines, but it only
takes onetechnician to effect
arepair. On averagg
arepair
can bedone in half
aweek. If
aturbine is in cold-standby, it cannot fail. (We asfltme that all switchovers from warm-standby to working or from cold-standby to wann-standby ateinstantaneous.) Assuming that all times
areexponentially distributed, determine
the expectedmegawatt hours that must
bepurdrased
eachyear.
[rt0
marks]
(b) Two alternative designs
arebeing considered for
theservice facility of
afinite queueing system. Altemative A
has asingle server and alternative
B hastwo
servers.The
costof the service facility
hastwo components:
afixed
costof
RM50,000per
year,whidr
isindependent of
thenumber of
servers,and
avariable
costof
RM3O000per
server
Peryear/ whidr
isproportional to
thenumber of servers. Simulation analysis
hasdetermined the following
steady-stateprobability distributions for
thenumber of
customers in the system.
lMsG 2531
2.
(a)Kntah'nn hanya lima talinn disedialun untuk menerima panggitnn. Salah satu itaripada talian itn disamhtnglan kspada lerani mattal,nla yang setebihnya digunalan untuk panggilan menungglt. lika lcesmrua talian sedang digunal,nn, sebarang panggilan yang tiba
alan
mmerima isyarat sihuk. Anggapknn baharpa pananggil yang mennima isyarat sfuak a!.,nnbqarusan dcngan talian yang diseiliakan oleh
syaikat
suratk&ahar yang tain.k)
APnknlrpnafiisan nasa dafipadamasabelcerjanyayang digunakan olehkeraniuntuk menjauah panggilan?(xi)
Bnapaluhluilm
panggilan yang ditolak disebablun isyarat sfuuk?kii)
Bnapalahbilangan purata talianyang itigunakan?(xiii) Bnrpa
lnnakah pada puratanyn seseorung pemanggilitu
menunggtt teerani?(xio)
Bnrpalnnaknhmasayang diambilbermula dfiipada masa sesuatu panggitaniht menung
sehinggalah soalannyo terjauab ?(xo)
satu kajian telah dibuat ilan didapati balwwa 7 paatus danpaitapmnnggit
yang mmggtnakan talian sulan akan akhinryameLanggan surattclubarsymilut itn.
setirp langganan tahunan alan mmyumbong sebnnyak RM10 kepadn keuntungan.
Kos patyaoaan talian Elefon tantbalun ialah KM400 seta|run. Bnapatcnh tnlian tclefon tambalan, sekiranya
p*lu,
yangpahtt
disa oa unhtk talian sukan?(Anggaplun bahawa talinn sukan dibulu 72 iam sehai, 3GS
hai
setahun)[50 markah]
sebuah
kihng tnuga
yang bnoperusi 24jan setui matputryai
unpat tnrbinjan*urea,
setiap satuny a berapay a menghasilkan 3 me gawat tenaga. P ermintaan tenaga p adaUk-bila
masa adalah sebarryak 6 megawat, dmgan
itu
apabih lresernua turbin bnaila dalnm lccadamt ba*, satu di antarunya aknnberaila dalamlccailaan "warm-standbyodtn
satu lngi datan kcadaan "cold-standby",ffian*aloyang
fuialagi al.,anbnoperasi patuh. fh,n safuturbin
rosak, dua akan
bropnasi
dan satu dalam lceadaan "warm-standby'.litu ihnrcsale
dua turbin yang ebk akanbnoprasi.
likamtu
hnbin sahaja yang elolg syar{lut Walcsa membeli 3 megawat teruga ilaripadasumbt
luar. l*,alcesanua turbin rosak,syaikat
t*Valcsa menbeli 6 megawat tenaga.lilu
sesuatu turbinitu
beraila dalam mod bnopnasi, masa puratn xhingga ia rosakitlnh
Bminggt.
lila
turbin iWam lcmdaon "warm-stanilby", masa purata sehingga ia rosak ialah 9mingy.
Syarilutitu
mmryutryai duajurutebtik
untuk membaiki turbin dan merelu betcerja bnasingan. Pada puratanya verja pembaikan memakan masa setengalr minggu.Jilu turbin
dnlan l,eadaon " cold-standby' , ia tidak alctn rcsak. ( Kita anda*nn bahrata smtuaperhiuran dmipaik
"warm-stanilby'kekeadaanberoperasi atan dartpafo "coW-stanilby" lce "rparm- stanilby" berlaht Eecara serta-mnta) Dengan anggapan balwna semua masa ailalalr bertaburan eksponm, tcntulun jangkaan jmn megawatt yanglarus
dibeli setiap tahan.[40markah]
Dua
altnrutif
sednngdiprtimbanglun
sebagai relubentukkemudalan perlkidmatnnbagi suatu sistengiliran
tnhingga.Altenatif A
manpunyai seorang pelayan ilan alternatif B mmryurryaihta
pelayan. Kos kemudahnn pnl&idmatanitu tsdiri
daripdda dua konponen:knstetapsebanyakRMS0,000setahunyangtidnkbergantungkepadabilanganpelayandan
kos bolehberubah R/iv/f,,l,ON
pu
pelayan setahun. Daripada analisis simulasi yang dijalankan, agihankebaranglulianbilangnnpehnggan di dalam sistett smtasatceailann man@ ailalah.srynti
bqihtt
:Design A Design
B4 0.05
n072 Po 0.38 0.30
0.21n P"
34
0.15
0.10I.r additioo the simulation
hasdetermined that
10o/oof the customers balk with design A whereas
5%balk with design
B. Thearrival rate (including balks) is
1500customers per year.
Management estimates that
acustomer who balks
coststhe company
RM100in lost profits. The
costof customers waiting in
the systemis RM20 per hour (per customer).
Determine whictr design alternative minimizes the total expected
cost.Assume that there
are 2000work hours in
a vear.[30
marks]
A
stateagency that handles compensation for
thosewho
areunemployed is considering two options for processing applications. Option
L:Four derks
processapplications in parallel from
asingle
queue. Eachderk fills out the required form in
the presence
of the applicant
basedon information that is verbally related to the derk. Processing time is exponentially distributed with
amean of
45minutes. Option
2: Each
applicant first fills out
theform without
thehelp of the clerk.
Thetime required to accomplish this
isexponentially distributed, with
a meEmof
55minutes.
When the applicant finishes
theforr;
heor
shejoins
asingle queue to await
areview by
oneof the four clerks.
Thetime required to review
aform is exponentially
distributed with
amean of
5minutes.
Given that the arival of applicants
is a Poisson processwith
amean rate of
4.8per hour, compare the two options with
respect tothe expected number of applicants in the system and the expected time in the
system.[30
marks]
Ships
arrive at
aharbor
at therate
of.I,trh.hours. There
aresix berths to
accommodate them. They
also needthe
serviceof
a cranefor unloading and there
arefive
cranes.After unloading
10%of
theships stay to refuel before leaving; the others
leaveirnnediately. Ships do not
need the cranesfor refueling. It
takes 7r/zt
3hours to unload and
1 + 14hours to refuel
aship. Write
a GPSSPCprogram to simulate the dearance of
100ships from
theharbor.
Thequeueing pattems for berths and
cranes are to beobserved.
[50
marks]
Referring to problem
3(a),perforrr
ahand simulation for the
clearanceof
10ships from
theharbor- Aszume that there
areonly
threeberths and two
cranes.The inter- arrival time of ships is either
L, 2or
3hours,
eachwith equal
chances ofhappening.
The
urrloading time
iseither 2,3,4 or
5hours with probabilities of
0.1, 0.3, 0.4and
0.2,respectively. The refueling time
iseither
1,1v2 ,or
2%hours,
eachwith equal
drances ofhappening. The ;ulswers to
thefollowing questions
areto
beprovided:
a.72 012 0.25
0.383 0.05
(c)
3
(a)(b)
7 lMsG 2531
n01.2
P" 0.38 0.30
0.21n01.234
P" 0.72 0.25 0.38 0.L5
0.70RelubentukA ReknbentukB
34
0.05
0.05 sebagai tambalwn,awlisis
simulasi itu juga telahmmathtlun
bahaua 10% daripada pelanggan alcnn belah dalam relcabentukA,
manaknla 5% atcan betah datam relubentuk B .IGdar lcetih aan ( tcnnasuk belnh) ialah 1s00 pel"an ggan s etalrun.
Pihak pmgurusnn menganggarkan bahowa setirp petanggan yang betatt alun mengakibatl,an kerugian sebanyak RML00 ilalam bmfitklcchilangan keuntungan. Kos bertuitan dcngan masa menunggu pelanggan ialah KM20 sejam (per pelanggan). Tenh*an alternatif
nan*ah
yang alan mmtinimumkan jumlahlasjangtaan.
Anilail-,nn baltawataitrpat
2000 jam masa belenia setahun.[30 tnarknhl sebuah pnbadanan ?,rrajaan negni yang mengmdalilun urusan nbsidi kcpada maeka yang mmganggur xdang menimbangkan
&n
opsyenunfiik
m.ewtproses permolutun.oprym
7:Ernpat
kaani
alan manproses permohonan secara selariilaipaila
satu barisan menunggu.setiap
krani
alun mengbi borang untuk pemolnn bnasaskan kepaitn maklumat yangdfu
s*'an
secara lisnn kcpananya
Masa pemproxsan adalahmmgjhtt
agihnn eksponm ilengan min 45miniL opsym
2: setirypanolan
mengisisendiibarangyang
disediakan.Mnsa yang
diperhiun
ialah mengifutagilutt
eksponen dengan min 65 minit. Apabiln borang stap iliisi, Wmolpn akanmnnsuki
satu bmisan menunggu untuk mmunggugilirnt
perryanal'an borang oleh salah seorang daripada anpat lcerani yang ada. Masa penyanatun borang ialah menglhrt agihan eksponm ilengan min 5
minit.
lilal<etibaanpettnlun adnlahmengkutproses Poisson
ilmgankadarmin
4.8 sejam,b anding'lun dua
opsyn itu
ber asaskankqadt
bilangan j angh,aan pmtolnn di dalam sistetn ilan jangkaan masaili ilalnn
sistem.[30nailah]
Kapal tiba di pelabuhan dengan ksdsr 1
t
Tzjan.
Etum ryIantar disediakan unhtk ke gunaan krpal. Kapal juga fitmet'lukanben
untuk pmtunggalnn danttdrpat
lima krendi
perlahulun
itu.
Selepas siap petnunggaltnn, 7"0"/o dmipadn kapal al<antrus
bntahuhuntuk
mmgisiminy&;
yang l"ainnya aluntrus
bereilar. Sarusa pmgisianminy*, krm tiilak
iliperlulan. MasamanunggahialnhTYzt3 jwn ilannasamengisiminyakialahl. tVz jnn
bagt setiap lopal. Tulis satu aturcara GPSSPC untukmclahtkan simulasi pmtprosesan L00 buah kspal
ili
pelnbulwn. Corak baisan menunggu untuk lecgunaan pelantar dan loen hmuslah diperhatikan.[50narkah]
Dmgan
mrujuk
kepailn masalah 3(a), Iakulsn simulasi dmgan tffigan porrprosesan 1.0 bualr hapal di pelabuhan. Andailun bahnna tefiapatlnnya
tiga pelnntar ilan dua kren. Masaiti
antara ketihaan kfrpnl ialah sama ada 1-, 2, atau 3 jam, dengan
xtiry
sahnryn mempunyai peluang yang sarna untukberlaht. Masa manunggalt ialaltsmu
ada 2, 3, 4 atau 5 jam dengan kebarangkalian masing-masingnya iolah 0.7, 0.3, 0.4 dnn 0.2. Masa untukmaqisi
minyak pula ialnh '1, lTz atau 2Yz jam, dcngan setiap satunya smna mungkin aknn berloku.
lmoapan ke?ada soaJan-soalan
bfrikut
mestilah diberikan:(c)
3
(a)(b)
(i) (ii) (iii)
What is the
averagetime that
aship spent
at theharbor?
What proportion of time
are the cranesidle?
What
isthe
averagetime that
aship spend waiting for
aberth to
beavailable?
(Use the
enclosed 2-digit random number table with the first column for ints-aniaal time,
secondcolumn for
unloading time, thethird column for
determining whether to refael ornot
andthe fourth column for
refueling time.)[50
marks]
IMSG 2531
0
Berrpakah masa purata sesebuahkrpal
berada di pelabuhan?Gi)
Berapakah peratusan masabersenang kren?Gii)
Bnapakah masa purata sesebuah kapalmmunggu untuk
menggunakan pelantar?(Gunakan
sifr
nombor rawak2-digit
yang disertakan denganlajur
pertatnauntuk masa antara ketibaan, laiur
keduauntuk
masa manunggah,lajur
ketigauntukmenentukan
sama adaperlu mengisi minyak ataupun tidak dan lajur keempat untuk
masamengisiminyak)
[50 rnarksh]
APPENDIX I / I^/IMPIRAN 1 Formulas for Queueing Theory:
1. IUI/A,I/I:
P=1lP
P, = (l - p) p' for
n= 0,I,2,...
L=L p- ).
r_L-
^',-q p(p- t) W:_____ p-^
I,
WoPlw tf=
"-"'
Pl.r, t)= pe-'t-
2.
Iutr\ul/s:p=L sP
=- p(p- 1 x)
, -l@r p)' -l + g (,trp)"-l '
"-L "! (A r k a
1l7'tp)', iro(r(s , =J
nt''n
l+#^ ' irn(s
, -(lttt)' P o
-q s\t- p)''o
,,=j , YI=wr+tl p
L= Lo+ 1./ p
Pl*o
t.
t r] = ,-.1,
L
"]=[t-"
,l,n
,,=l?-(')(ii.f-('.)h(il'l'
^(,)(X)^ , iro(,,ss
^('")(!de) , , if n> irs <n<M M
L = P.[x .(y) (I)' .f-.(y)*;iil
]
Lq = L-, * r, ; (, - 4(y)(1)^
,=ffi,w.=fu
Po=l- P
, L'o'+ p2
"o=@
l,= p*L,
, l+k
)r2t',=n;ff;)
w q =l*k ,1 zk p(p- ),)
=W =Wc+Il p L=1,W
11 lMsG 2531
APPENDIX?I I.AMPIRAN 2 3. Ir[/]tl/s: finite population of
sizeM.
Pr=
4. luI/G/I:
L"l
Wo=i , W=*o*
U
5. M lErlt:
APPENDIX3 I I.,/IMPIRAN 3 6. MI,I/I/k:
For p+l L-
For p-l
7.
IUI/]ut/s/k:Lq = L-(1-Pr) = r-o(t- {,)
l- pr*' W=Ll2' , A'=a(t-tr1
W, =W -Il p=
Lc IA'
(o<n<s) (p +t) (p=l)
Pn
n[*1n*r)pr *kpr*'f (t- or")(r- p)
t=L 2
' *rl
slr )
Po (s<n<k)
r
-( , )'-".''l-'
.w#g_l ".(
SPJ l'
lc r \r r-l | /
".+(t-'+r)l ror l#
1=
Po=
=1)
",
("_r\(ps), L= Lo+s-Prl9-
n=o nl
, =i , I. t,= A(l_ p*) W' =W -L p
Wr=+
8. tu{/luI/s/s:
r=ffi, ror (o<n<") q = !tp)'
ttt
where (, = L\.
l(sp)' tit \ sP )
,=0
1=L1t-r,) , w=*where ),'=2(t-p,)
13 IMSG 2531
APPENDIX4 | L/IMPIRAN 4
(A/u\n eltu
p _\ , t fotn=0rlrZr...
'n nl
L= ).1 p
W=! p
9. M lM /a:
APPENDIXS I I}IMPIRAN 5
10. luI/luI/I:state-dependentservice
ln Q<n<t) o'= Io @> k)
,,=lS* e.oi'f' (p,= u h,p= )"t p <r)
Lt-A t-P )
ll.
L = p^l p,lr+(* -r) pi
_- tpi'f
*epi"lr -(t -\ ef]
"
L (r- p,)" (r- p)' I
Lq = L-(t -Pr)
w =L 1 w-=L .tt )"
w=wq.+
f( ^\"
" _Jlfl ^ (o<n<rr)
"-l ld'P' 4^p, (,>k)
WluI/I: finite population of
sizeM.
" -[$ Mt (l'1-'
":lk6[t,ll
P= M! ('\'
-n ('-4ll-') 4 rorn=r'2'"''M
t= u -fiIr-r,l
t, =, -^io (l-4)
w =fr , W, =+ where t' = l,(u - t)
15
APPENDIX6 / LAMPIRAN 6
TWO-DIGIT RANDOM IYUMBER TABLE
-ooooooo-
lMsG 2531
03
7l
33 53
4l t6
88 13 15 64 98 43 69 06 34 46 28 35 90 62
26 44 75
7l
15 18 50 10 72 10 66 05 82 40 86 05 73 53 90 32
48 81 06 27 43
7S00 08 73 99 53 06 02 10 83 92 s9 49
r8
97 92 46
4l
13
9l
11
56
1569 02 86
196l
24
4l
s6 56 39 27
1638 44 87 37 46 26 70 29 27 18 34 91 98 68 33 82 43 98 75 33
96 47 72 45 81 80
t9
33 75 26
7l
78 50 42 83 04 88
l4
08 66
41 07 63 89 57 93 90 75 72 78 09 03 74 39 85 67
6l
16 75 02
04 20 88 61 39 97 00 70 95 69 88 6s 84 97 92 05 17 76 17 34
35 58 59 30 34 29 93 43 99 19 s6 08 60 25 32 18 07 69 55 62
84 04 54 26 86 33 95 05 56
t2
08
t6 4l 5t
29
69
48
10
68
26