# How to model arrival times in discrete event simulation where arrivals vary with time of day and day of week

I'm looking for suggestions on how to model inter-arrival times in a discrete event simulation where the arrival rate is highly dependent on the day of week and the hour of day.

For example: A laboratory processes samples that arrive by Fedex or other carrier at specific times of day (e.g. most samples arrive between 10 AM and noon). Similarly, there is a strong cyclical pattern by day of week: very few samples arrive on Sunday, relatively few on Monday, Thursday is the busiest day of week, etc.

Question Part 1: Where the typical approach is to sample from a poisson distribution, what seems to be needed is a function where the next inter-arrival time is a function of day and time of the last arrival, as well as the usual scale and distribution of arrivals.

It's not useful to run the simulation for timeframes shorter than several weeks, because the process takes several weeks to complete. It is also important not to just average the arrivals over the course of the day because, for example, batches are formed at specific times of day, certain instruments are run at specific times of day, and so on.

Question Part 2: I have historical data with arrival timestamps. Is there an approach to mining such data such that it would provide an inter-arrival time for any given day and time?

Thanks very much for any help. Suggestions for restructuring and/or rewording the question are welcome. Pointers to papers where this issue is discussed/resolved would be much appreciated.

• Do you want to analyze the data or simulate the data? Commented Dec 10, 2018 at 16:24
• @user158565 simulate it (and analyze the results) Commented Dec 10, 2018 at 18:08
• Then you need the unique model first, include the values of the parameter, and write it mathematically. Then following the model to generate the data. Commented Dec 10, 2018 at 20:00