In the last session, I introduced a concept of waiting time formula. One assumption, however, that we made in this formula is that we are dealing with the case where we have just one single resource doing all the work. We looked at the case where we had m = one. In this session, we will generalize this formula to the case where the resources staff that m = two multiple people. Most interesting problems, I would argue, have this flavor. If you think about a physician's office, it's often times not just one physician doing the work, but maybe three, four, or five. In a call center, you don't have just one operator picking up the phone, But you might have hundreds of seats with busy operators. So, the purpose of this session is to generalize the waiting time formula to this general m. This will be a little bit more technical, I have to alert you to this. But as a byproduct or as a reward for this extra work, we'll be able to derive a staffing plan. We'll be looking at a specific target wait time. And then, think about how many operators we'll have to put to work to actually be able to meet that level of responsiveness. Alright, I warned you. This is not going be pretty. Now, let's look at the process flow diagram before we turn our eyes to the math. In this process flow diagram, I realize now, that I have m parallel servers. Think of m for simply standing for multiple. I have multiple servers, but note further, I have a common queue. Som the assumption here is that the process flow diagram still consists out of this basic picture. I have a common queue for everyone, and whoever is available next is going to serve the next customer. Once again, I want to find the time it takes the customer to wait in the queue. It turns out that the expected time in the queue can be written in a very similar way as we saw it before. Here we go. We'd have to look again at the activity time or the processing time. This time divided by m times the utilization. And here, is the really ugly part. Look at the square root here. So, the utilization is raised to this exponent of the square root of 2m plues one minus one divided by one minus the utilization. The third factor is unchanged to the previous case. Now, as we apply this formula, keep in mind that the utilization all throughout remained the flow rate divided by the capacity. Remember further, that in all our discussion around variability, we assumed that the flow rate was constrained by demand. Again, if you have a demand that exceeds the capacity, waiting is not driven by variability, it's just driven by insufficient capacity. Now, if the flow rate is driven by demand, I simply have a customer arrive every a unit of time, where a was enter arrival time. And I can write my capacity, just like in every other module in this course, as the number of resources divided by the processing time. So, you can see here that I can simplify the utilization to P divided a times m. So, when you interpret this formula, be careful in the sense that the utilization is also a function of m. So, do not just look at this equation and say, oh, that makes sense. M is driving down the time in the queue, M is also sitting in the utilization over here and over here. I think you will be a lot more comfortable with this formula if we crunch through another example. So, let's consider the following situation. We have an online retailer that is staffing a help desk with three employees. These three employees are getting an email every two minutes on average. Standard deviation of these interval arrival times is two minutes. It takes four minutes to write a response email with a standard deviation of two minutes. What's the waiting time for the customers? Well, again, as before, I suggest we start writing down the formula. P divided by m times the utilization square root two m1. Plus one minus one divided by one minus u. Be careful with minus one, that's outside the square root here. The square root ends, but it's still in the exponent, Times CVa2 squared plus CVp2 squared divided by two. Alright. Now, let's look at the ingredients here to the question. We have a fairly obvious P equals to four minutes. We have three employees, So m equals three. The utilization, as I said before, we're going to compute the utilization as flow rate divided by the capacity which we said equates to p divided by a times m. So, P is four, a is two. The m comes every two minutes, times three employees, So that is 66%. And then, here's where things get ugly with the exponent. So, we have here the square root of m plus one, that's three plus one is four times two is eight, square root of eight, minus one, divided by 0.3333 times the CVa squared, that is one squared, Plus the CVp, that is the standard deviation of the service time, two minutes divided by the average, four minutes. That is 0.5 squared, divided by two. That's all there is to it. When I plug these into my calculator, I see an expected wait time in the queue of 1.19 minutes. Again, as before in the example we have to debate whether what matters here is the time in the queue or the time to response. If you care about the time to the response of the customer, you would have to add two minutes here of the actual service time. On this slide, I've summarized all the calculations you need to be able to do in the context of waiting times. The most important building blocks for the calculations is the utilization. Remember, the utilization is the flow rate divided by the capacity, which simplifies to P divided by a times m. Once we are done with the utilization, we can use the waiting time formula to get the time in the queue, Which is the time from entering the system to the time when you're going to start your service. If you care about the total time in the system, we simply have to add the expected processing time P. So that gets us from entering the physician's practice to leaving it. Notice that by Little's Law, I can also compute the inventory. Since I hold the flow rate constant, That's the rate of demand, I can simply apply Little's Law. I have the flow time, I have the flow rate, and I can compute Little's Law. This is summarized over here. The inventory in the queue is the flow rate through the queue times the time in the queue. Notice that the inventory that is currently in process, meaning the number of patients that currently see the doctor, can be computed as the utilization times the number of servers. Finally, I can compute the total inventory. We see inventory in the waiting room, plus the inventory with the servers. So far, we've assumed that the demand is really constant throughout the day. While it is variable from a perspective uncertainty, but it's at every minute and every hour, It's the same underlying distribution from which they enter arrival times, and the processing times are drawn. Now, in practice, oftentimes, you see situations when this assumption is not fulfilled. You see situations where you have spikes in demand at certain busy hours. In this example here, you see a call center where we have a spike of demand in the morning hours, and another spike in the early afternoon. It would be misleading to simply ignore this effect and just assume that the inter arrival times are drawn from the same distribution for every hour in the day. What you do in situations like this, This is very similar to what we did in the Subway analysis a little while ago, You slice the data into 30 minutes or hour long time intervals. And then, you behave as if the arrivals are constant within each of these intervals. I do believe that it's an imperfect approximation, but it's certainly better than ignoring it altogether. This is quite an important consideration when you are putting together a staffing plan. Let me illustrate this in Excel. In this Excel spreadsheet, I've summarized the calculations of our earlier example of the online retailing. Recall we had a situation where the processing time was on average four minutes, the inter-arrival time was two minutes, three employees, and so on. You notice here, the utilization is P divided by a times m. M, for the down here, you see the argued waiting time formula this time in excel. Now, typically, the question here, assumed that we have a given staffing level and given parameters. Instead of taking the staffing plan as given, you might ask the question a different way. You might ask, how many employees would it take to get the average waiting time to under a minute? You can then keep on adding employees to the point where this constraint is honored. So, this is quite an easy way to find a staffing plan. You can do this for one time slot in, in isolation, but also consider the situation where you have seasonal demand as illustrated on the earlier slide. Seasonal demand simply means that the inter-arrival times are actually changing over the course of the day. There's 60 minutes in an hour, so if I have 30 customers arrive in an hour, I have an inter-arrival time of two. When demand gets busier, I have a shorter inter arrival time. So, say for a sake of argument, I have some times in the day when there are not 30 customers arriving, but there are 50 customers arriving. The new inter-arrival time, in this case, would simply be 60 minutes in an hour divided by 50 customers in an hour, which means there's a customer coming in every 1.2 minutes. Notice that this blows up our waiting time formula. At that point, actually, Our implied utilization is bigger than one and our formula does not apply. I have to keep on adding employees to make the staffing feasible. If I add from three to four employees, I have an average waiting time of 2.5 minutes. If I have a goal, as articulated earlier on of having a response time under a 2-minute waiting time. Well, let's see if five minutes do the job, five employees do the job. And you notice that I can just increment my m to the point where the constraint is fulfilled. This gives us a staffing plan if I do this for every hour in the day. In this session, we extended the waiting time formula from the previous session to the case of a general m, a general number of resources, It was not pretty. I suggested if you want to, to impress a coworker, fellow student, or somebody in the family, just go memorize this formula and recite it at dinner. It would make for quite an impression. But it's a powerful formula, ugly or not. It is powerful because it can let you drive a staffing decision. We saw that often times, the demand changes over the course of the day or over the season an effect that we refer to as seasonality. We then followed an approach to this somewhat similar to what we did in the, the productivity analysis of the Subway case in Module Two. We said that we would level the demand, Fpr example, in 30 minutes time brackets, and we would then choose an appropriate staffing level for each of these time brackets. This allowed us to match supply with demand and thereby, balance the conflicting objectives from the services provider's perspectives. The desire of obtaining a high utilization, and from the customer's perspective of obtaining a short response time to their order.