DATA604_Discussion_Week_5

Dilip Ganesan

chooseCRANmirror(graphics=FALSE, ind=1)

install.packages("queueing")
## 
## The downloaded binary packages are in
##  /var/folders/4h/klcns9_17c30jkl6d7htgbhw0000gn/T//RtmpzGl3Ga/downloaded_packages
library(queueing)

M/M/1 Problem

  1. M/M/1 queue with arrival rate lambda = 120 parts per hour and service rate mu = 50 parts per hour and value of c = 3.
lambda=120/60
sigma=50/60
c=3

rho= lambda/(c * sigma)

mm3 = NewInput.MMC(lambda,sigma,c=3,n=0,method = 0)
mm3queue = QueueingModel(mm3)

Lq = Lq(mm3queue)
Wq = Wq(mm3queue)

W = Wq + 1/sigma
L = Lq + lambda/sigma

df5= data.frame(Wq , Lq, W, rho, L)
df5
##         Wq       Lq        W rho        L
## 1 1.294382 2.588764 2.494382 0.8 4.988764