# Traffic generation using poissrnd()

5 visualizzazioni (ultimi 30 giorni)
Jaya il 9 Ago 2021
Commentato: Jaya il 18 Ago 2021
I generate 24 numbers using possrnd as below
lambda=50
r = poissrnd(lambda,1,24)
% One output is 47 58 45 52 57 44 53 54 43 48 57 44 69 58 35 66 60 44 47 47 45 48 51 43
Can I use this output as a Possion distributed traffic over 24 hours? I am confused on how to generate a Possion arrival traffic as I see other stuff like creating exponentially distributed RVs and then inter-arrival times, etc. Please advise me
##### 0 CommentiMostra -2 commenti meno recentiNascondi -2 commenti meno recenti

Accedi per commentare.

### Risposta accettata

Prachi Kulkarni il 12 Ago 2021
Hi,
For arrival traffic over a single set of 24 hours with mean "lambda", you can use-
r = poissrnd(lambda);
For arrival traffic for 24 separate hours, each with mean "lambda", you can use-
r = poissrnd(lambda,1,24);
For more details regarding the "poissrnd" function or the Poisson distribution in general, please refer to the following documentation
##### 3 CommentiMostra 1 commento meno recenteNascondi 1 commento meno recente
Prachi Kulkarni il 18 Ago 2021
Hi,
Both the code snippets you provided represent the same scenario. They are modeling the arrival traffic in each hour separately. This is shown below-
r = poissrnd(lambdaHour,1,24); % The mean traffic in each hour is lambdaHour
To model arrival traffic for a full day i.e. 24 hours, you will need to generate a single Poisson random variable. The mean of this random variable should be 24 times the mean for a single hour i.e. 24*lambdaHour. This is shown below-
r = poissrnd(24*lambdaHour);
Jaya il 18 Ago 2021
Thanks a lot!

Accedi per commentare.

### Categorie

Scopri di più su Poisson Distribution in Help Center e File Exchange

### Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by