Skip to content

Commit 069a5c3

Browse files
committed
L31 emdashes
1 parent b03ba26 commit 069a5c3

File tree

2 files changed

+33
-33
lines changed

2 files changed

+33
-33
lines changed

lectures/L31-slides.tex

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
\begin{frame}
2121
\frametitle{Queueing Theory}
2222

23-
Literally the theory of queues -- what makes queues appear, how will they behave, and how do we make them go away?
23+
Literally the theory of queues---what makes queues appear, how will they behave, and how do we make them go away?
2424

2525

2626
Queueing theory has played a role in your life whether you know it or not.
@@ -48,12 +48,12 @@
4848
\frametitle{Questions Queueing Theory Helps Answer}
4949

5050
\begin{itemize}
51-
\item Given a choice between a single machine with speed $s$ or $n$ machines, each with speed $s/n$, which should we choose?
51+
\item Given a choice between a single machine with speed $s$, or $n$ machines, each with speed $s/n$, which should we choose?
5252
\item If the arrival rate and service rate double, how does the mean response time change?
5353
\item Should we try to balance load or is that a waste of time/effort?
5454
\item Can we give priority to certain operations without harming another category of job?
5555
\item How do job size variability and heavy-tailed workloads affect our choices of scheduling policy?
56-
\item If 12 servers is enough to handle 9 jobs per second, do we need 12~000 servers if we have an arrival rate if 9~000 jobs per second?
56+
\item If 12 servers is enough to handle 9 jobs per second, do we need 12~000 servers if we have an arrival rate of 9~000 jobs per second?
5757
\end{itemize}
5858

5959
\end{frame}
@@ -64,12 +64,12 @@
6464
\frametitle{Formal Terms and Bank Analogies}
6565

6666
\begin{itemize}
67-
\item Server - The banking centre fulfilling customer requests.
68-
\item Customer - Initiator of service requests.
69-
\item Wait time - The time a customer spends waiting in line.
70-
\item Service time - The time from when a teller starts to serve a customer up to the time when the next customer is called forward.
71-
\item Arrival rate - The rate at which customers arrive.
72-
\item Service rate - the rate at which customer requests are serviced.
67+
\item Server---the banking centre fulfilling customer requests.
68+
\item Customer---the initiator of service requests.
69+
\item Wait time---the time a customer spends waiting in line.
70+
\item Service time---the time from when a teller starts to serve a customer up to the time when the next customer is called forward.
71+
\item Arrival rate---the rate at which customers arrive.
72+
\item Service rate---the rate at which customer requests are serviced.
7373

7474
\end{itemize}
7575

@@ -81,11 +81,11 @@
8181
\frametitle{Formal Terms and Bank Analogies}
8282

8383
\begin{itemize}
84-
\item Utilization - The fraction of the teller's time used actually handling customer requests (not idling).
85-
\item Queue length - The total number of customers waiting, or currently with a teller, or both.
86-
\item Response time - The sum of wait and service time for a single visit.
87-
\item Residence time - The total response time if a customer visits several tellers (or the same one multiple times).
88-
\item Throughput - The rate at which customers get their requests serviced and dealt with.
84+
\item Utilization---the fraction of the teller's time used actually handling customer requests (not idling).
85+
\item Queue length---the total number of customers waiting, or currently with a teller, or both.
86+
\item Response time---the sum of wait and service time for a single visit.
87+
\item Residence time---the total response time if a customer visits several tellers (or the same one multiple times).
88+
\item Throughput---the rate at which customers get their requests serviced and dealt with.
8989
\end{itemize}
9090

9191
\end{frame}
@@ -153,7 +153,7 @@
153153

154154
Suppose the average service rate $\mu$ is 5 jobs per second.
155155

156-
The system is not overloaded -- 3 jobs per second arriving is less than 5 jobs per second being serviced.
156+
The system is not overloaded---3 jobs per second arriving is less than 5 jobs per second being serviced.
157157

158158
\end{frame}
159159

@@ -191,7 +191,7 @@
191191
\frametitle{Option 3}
192192

193193

194-
The answer is (3) - we don't need to double the CPU speed.
194+
The answer is (3)---we don't need to double the CPU speed.
195195

196196
We can see later in formal terms why this is the case, but think for a minute about what it is?
197197

@@ -304,7 +304,7 @@
304304
\begin{frame}
305305
\frametitle{Digression on Load Balancing}
306306

307-
Imagine your typical ``server farm'' - you have $n$ servers that are all responsible for handling incoming requests.
307+
Imagine your typical ``server farm''---you have $n$ servers that are all responsible for handling incoming requests.
308308

309309
Let's imagine all servers are the same (or close enough).
310310

@@ -321,7 +321,7 @@
321321
\begin{frame}
322322
\frametitle{Assignment Policies}
323323

324-
There are a few different task assignment policies - ways in which we can assign work to servers:
324+
There are a few different task assignment policies---ways in which we can assign work to servers:
325325

326326
\begin{itemize}
327327
\item Random
@@ -347,7 +347,7 @@
347347
You'll never know what you can do\\
348348
Until you get it up as high as you can go''
349349

350-
\hfill - Kenny Loggins
350+
\hfill -- Kenny Loggins
351351

352352

353353
\end{frame}
@@ -512,7 +512,7 @@
512512

513513
The closed system strategy: set it up so there is always work to do.
514514

515-
In closed systems, there's often consideration given to \textit{think time} -- this is what happens when the user is on the command line and dispatching work to do.
515+
In closed systems, there's often consideration given to \textit{think time}---this is what happens when the user is on the command line and dispatching work to do.
516516

517517
To keep the system totally busy in the stress test, we need think time to be zero---so additional work is always available.
518518

lectures/L31.tex

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -22,17 +22,17 @@ \section*{A Short Introduction to Queueing Theory}
2222
I tend to tell stories about banks that imply I hate them. Not really, they're just a place where there's likely to be a queue and I'm likely to be annoyed and thinking about how to optimize this situation. So let's define some terms formally, to make sure we're all on the same page when it comes to terminology and language. Some of these will seem obvious, but let's be complete (like the book~\cite{swps}):
2323

2424
\begin{itemize}
25-
\item Server - The banking centre fulfilling customer requests.
26-
\item Customer - Initiator of service requests.
27-
\item Wait time - The time a customer spends waiting in line.
28-
\item Service time - The time from when a teller starts to serve a customer up to the time when the next customer is called forward.
29-
\item Arrival rate - The rate at which customers arrive.
30-
\item Service rate - the rate at which customer requests are serviced.
31-
\item Utilization - The fraction of the teller's time used actually handling customer requests (not idling).
32-
\item Queue length - The total number of customers waiting, or currently with a teller, or both.
33-
\item Response time - The sum of wait and service time for a single visit.
34-
\item Residence time - The total response time if a customer visits several tellers (or the same one multiple times).
35-
\item Throughput - The rate at which customers get their requests serviced and dealt with.
25+
\item Server---The banking centre fulfilling customer requests.
26+
\item Customer---The initiator of service requests.
27+
\item Wait time---The time a customer spends waiting in line.
28+
\item Service time---The time from when a teller starts to serve a customer up to the time when the next customer is called forward.
29+
\item Arrival rate---The rate at which customers arrive.
30+
\item Service rate---The rate at which customer requests are serviced.
31+
\item Utilization---The fraction of the teller's time used actually handling customer requests (not idling).
32+
\item Queue length---The total number of customers waiting, or currently with a teller, or both.
33+
\item Response time---The sum of wait and service time for a single visit.
34+
\item Residence time---The total response time if a customer visits several tellers (or the same one multiple times).
35+
\item Throughput---The rate at which customers get their requests serviced and dealt with.
3636
\end{itemize}
3737

3838
The mathematical symbols for this are represented in the following table~\cite{swps}:
@@ -119,9 +119,9 @@ \subsection*{A Digression on Load Balancing}
119119

120120
\subsection*{Red Line Overload\footnote{You've seen ``Top Gun'', right? \url{https://www.youtube.com/watch?v=siwpn14IE7E}}}
121121

122-
Earlier I mentioned it would probably be bad to see 6 jobs arriving per second to a system that can handle 5 per second. This doesn't seem like rocket science, but it bears repeating. In our discussion we require that $\lambda \leq \mu$ and assume that $\lambda < \mu$. That is to say, we are not overloaded (as engineering students you may be amused by the idea that you might one day NOT be overloaded). Remember now that the values for $\lambda$ and $\mu$ are averages, so it could happen that temporarily we ``fall behind'' a bit, but then make up for it a little later on, or we temporarily get ahead before a bunch more work gets piled on. Think about the long term, though -- if we are not at least keeping up then this will eventually get out of hand. How badly? Well, in the limit, the queue length goes to infinity.
122+
Earlier I mentioned it would probably be bad to see 6 jobs arriving per second to a system that can handle 5 per second. This doesn't seem like rocket science, but it bears repeating. In our discussion we require that $\lambda \leq \mu$ and assume that $\lambda < \mu$. That is to say, we are not overloaded (as engineering students you may be amused by the idea that you might one day NOT be overloaded). Remember now that the values for $\lambda$ and $\mu$ are averages, so it could happen that temporarily we ``fall behind'' a bit, but then make up for it a little later on, or we temporarily get ahead before a bunch more work gets piled on. Think about the long term, though---if we are not at least keeping up then this will eventually get out of hand. How badly? Well, in the limit, the queue length goes to infinity.
123123

124-
The justification comes from~\cite{pmd}: Let's represent time with $t$, its usual symbol and define $N(t)$ as the number of jobs in the system at time $t$. $A(t)$ represents arrivals by time $t$ and $D(t)$ represents departures by time $t$. So:
124+
The justification comes from~\cite{pmd}: Let's represent time with $t$, its usual symbol, and define $N(t)$ as the number of jobs in the system at time $t$. $A(t)$ represents arrivals by time $t$ and $D(t)$ represents departures by time $t$. So:
125125

126126
\begin{center}
127127
$E[N(t)] = E[A(t)] - E[D(t)] \geq \lambda t - \mu t = t (\lambda - \mu) $

0 commit comments

Comments
 (0)