Pn.o_BnD {queueing}R Documentation

Returns the probabilities of a generic Birth and Death process model

Description

Pn returns the probabilities that a generic Birth and Death process model has n customers.

Usage

  ## S3 method for class 'o_BnD'
Pn(x, ...)

Arguments

x

a object of class o_BnD

...

aditional arguments

Details

Pn returns the probabilities that a generic Birth and Death process model has n customers.

References

[Sixto2004] Sixto Rios Insua, Alfonso Mateos Caballero, M Concepcion Bielza Lozoya, Antonio Jimenez Martin (2004).
Investigacion Operativa. Modelos deterministicos y estocasticos.
Editorial Centro de Estudios Ramon Areces.

See Also

QueueingModel.i_BnD.

Examples

## Generating a generic Birth and Death model with the same lambda and mu vectors as M/M/1 model
## create input parameters
lambda <- rep(1/4, 200)
mu <- rep(1/3, 200)

i_BnD <- NewInput.BnD(lambda=lambda, mu=mu)

## Build the model
o_BnD <- QueueingModel(i_BnD)

## Returns the probabilities
Pn(o_BnD)

## Simulating M/M/1
lambda <- rep(1/4, 200)
mu <- rep(1/3, 200)

pn_bnd_mm1 <- Pn(QueueingModel(NewInput.BnD(lambda=lambda, mu=mu)))
pn_mm1 <- Pn(QueueingModel(NewInput.MM1(lambda=1/4, mu=1/3, n=200)))

## Simulating M/M/2
lambda <- rep(5, 200)
mu <- c(1*10, rep(2*10, 199))

pn_mmc <- Pn(QueueingModel(NewInput.MMC(lambda=5, mu=10, c=2, n=200, method=0)))
pn_bnd_mmc <- Pn(QueueingModel(NewInput.BnD(lambda=lambda, mu=mu)))


## Simulating M/M/1/K/K
lambda <- c(2*0.25, 0.25)
mu <- rep(4, 2)
pn_mm1kk <- Pn(QueueingModel(NewInput.MM1KK(lambda=0.25, mu=4, k=2, method=3)))
pn_bnd <- Pn(QueueingModel(NewInput.BnD(lambda=lambda, mu=mu)))


[Package queueing version 0.2.12 Index]