# 排队模型

排队模型是对这样一类系统的数学表示：顾客到达，在服务器忙碌时排队等候，接受服务后离开；它用于预测拥堵情况以及利用率、队列长度、等待时间等性能指标。该方法起源于电话话务工程，如今已成为运筹学、计算机系统性能分析和网络设计中的标准工具。<sup>[1](https://www.informs.org/Explore/History-of-O.R.-Excellence/O.R.-Methodologies/Queueing-Models)</sup>

| 关键事实 | 详情 |
|---|---|
| 模型所表示的内容 | 输出包括稳态队列长度分布和等待时间分布，以表格形式给出 M/M/c、M/D/c 和 D/M/c 系统的结果<sup>[2](https://apps.dtic.mil/sti/pdfs/ADA089540.pdf)</sup> |
| 肯德尔记号 | A/S/c：到达过程、服务过程、服务器数量；M = 指数分布（无记忆），D = 确定性，G = 一般分布<sup>[3](https://www.cse.fau.edu/~bob/publications/Queueing%20Notation%20-%20Cooper%20%28EORMS%29.pdf)</sup> |
| 稳定性条件 | 单服务器队列仅在业务强度 ρ = λ/µ < 1 时稳定；否则队列长度将无界增长<sup>[4](https://iadan.win.tue.nl/blockq/h3.pdf)</sup> |
| 利特尔定律 | \( L = \lambda \cdot W \)：系统中平均顾客数等于到达率乘以在系统中平均停留时间<sup>[3](https://www.cse.fau.edu/~bob/publications/Queueing%20Notation%20-%20Cooper%20%28EORMS%29.pdf)</sup> |
| M/M/1 稳态 | 系统中平均顾客数 \( E(Q) = \rho/(1 - \rho) \)<sup>[5](https://encyclopediaofmath.org/wiki/Queueing_theory_%28Statprob%29)</sup> |
| 网络 | 杰克逊网络和 BCMP 网络具有乘积形式稳态分布，可实现对吞吐量和响应时间的精确算法<sup>[6](https://www.dsi.unive.it/~balsamo/pub/pfwhite99.pdf)</sup> |
| 主要应用 | 电话工程、呼叫中心、分时计算机系统、急诊科和机加工车间<sup>[7](https://dl.acm.org/doi/epdf/10.1145/356733.356735)</sup><sup> • </sup><sup>[1](https://www.informs.org/Explore/History-of-O.R.-Excellence/O.R.-Methodologies/Queueing-Models)</sup> |

## 工作原理

排队模型用肯德尔简记法 A/S/c 指定三个要素：到达过程 A、服务过程 S 和服务器数量 c，除非采用更长的记号另行说明，否则假定缓冲区无限且采用先到先服务调度。<sup>[6](https://www.dsi.unive.it/~balsamo/pub/pfwhite99.pdf)</sup><sup> • </sup><sup>[8](https://iadan.win.tue.nl/que/h2.pdf)</sup> 字母 M 代表无记忆（指数）分布，D 代表确定性分布，G 代表一般分布；第四个字母可以指定系统容量（包括正在接受服务的顾客），如 M/M/1/N，表示系统中最多可有 N 个顾客，最多 N − 1 个可以等待。<sup>[8](https://iadan.win.tue.nl/que/h2.pdf)</sup> 在 M/M/1 中，第一个 M 表示泊松（马尔可夫）到达，第二个 M 表示指数服务，1 表示单服务器。<sup>[9](https://people.maths.bris.ac.uk/~maajg/teaching/iqn/queues.pdf)</sup>

核心输出是顾客数量的稳态分布，由此可得出利用率、平均队列长度、等待时间，以及在有限容量系统中的阻塞概率。<sup>[2](https://apps.dtic.mil/sti/pdfs/ADA089540.pdf)</sup> 稳定性是前提条件：对于 G/G/1 队列，条件为 \( \lambda \cdot E(B) < 1 \)；对于 c 个服务器，条件为 \( \lambda \cdot E(B) < c \)，每服务器利用率为 \( \rho = \lambda \cdot E(B)/c \)；当 ρ < 1 时，它等于服务器工作时间的比例。<sup>[8](https://iadan.win.tue.nl/que/h2.pdf)</sup> 两个结构性结果支撑着整个框架：利特尔定律 \( L = \lambda \cdot W \)，将系统中平均顾客数、到达率和平均停留时间联系起来；<sup>[3](https://www.cse.fau.edu/~bob/publications/Queueing%20Notation%20-%20Cooper%20%28EORMS%29.pdf)</sup> 以及 PASTA 性质，即泊松到达看到的是时间平均，因此发现系统处于某一状态的顾客比例等于系统处于该状态的时间比例。<sup>[8](https://iadan.win.tue.nl/que/h2.pdf)</sup>

## 具体做法

为真实系统建立模型按步骤进行。首先，选择与系统匹配的到达过程和服务过程，例如用泊松到达配合指数服务进行 M/M/1 式分析。其次，当到达过程和服务过程为马尔可夫过程时，将队列表述为关于在场顾客数量的生灭马尔可夫链，其到达率和服务率依赖于状态；此类基本模型涵盖 m 个并行同质服务器，而非马尔可夫队列则需要补充状态或其他方法。<sup>[10](https://web.mit.edu/urban_or_book/www/book/chapter4/4.5.html)</sup> 第三，写出平衡方程，即令每个状态 n 的概率流出等于流入；这些方程可以直接从状态转移图观察写出。<sup>[10](https://web.mit.edu/urban_or_book/www/book/chapter4/4.5.html)</sup> 对于 M/M/1，方程为 \( 0 = -\lambda p_{0} + \mu p_{1} \) 和 \( 0 = \lambda p_{k-1} - (\lambda + \mu) p_{k} + \mu p_{k+1} \)，其解为几何分布 \( p_{k} = (1 - \rho) \rho^{k} \)。<sup>[4](https://iadan.win.tue.nl/blockq/h3.pdf)</sup> 最后，从稳态分布中提取性能指标，利用利特尔定律及相关关系将队列长度转换为等待时间和吞吐量。<sup>[8](https://iadan.win.tue.nl/que/h2.pdf)</sup>

## 起源

[排队论](https://www.edgepedia.org/zh/queueing-theory)始于电话话务。在哥本哈根电话公司开展的研究证明，概率论可以为电话通话提供数学模型，并确立了以下结论：交换机入站呼叫服从[泊松分布](https://www.edgepedia.org/zh/poisson-distribution)，线路与呼叫组成的系统会达到统计平衡。<sup>[5](https://encyclopediaofmath.org/wiki/Queueing_theory_%28Statprob%29)</sup><sup> • </sup><sup>[1](https://www.informs.org/Explore/History-of-O.R.-Excellence/O.R.-Methodologies/Queueing-Models)</sup><sup> • </sup><sup>[11](https://onlinelibrary.wiley.com/doi/10.1111/j.1467-9574.2008.00395.x)</sup><sup> • </sup><sup>[1](https://www.informs.org/Explore/History-of-O.R.-Excellence/O.R.-Methodologies/Queueing-Models)</sup>

现代形式体系出现较晚。受1948—1949年柏林空运的启发，大卫·乔治·肯德尔（David George Kendall）发表了 A/B/C 简记法、嵌入[马尔可夫链](https://www.edgepedia.org/zh/markov-chain)方法，并首次使用了“排队系统”一词；他1953年发表于《数学统计年鉴》的论文是该记号以及对非泊松到达或非指数服务队列进行嵌入链分析的经典参考文献。<sup>[1](https://www.informs.org/Explore/History-of-O.R.-Excellence/O.R.-Methodologies/Queueing-Models)</sup><sup> • </sup><sup>[12](https://doi.org/10.1214/aoms/1177728975)</sup> 利特尔定律 \( N = \lambda \cdot T \) 对稳定的服务系统成立。<sup>[1](https://www.informs.org/Explore/History-of-O.R.-Excellence/O.R.-Methodologies/Queueing-Models)</sup> 詹姆斯·R·杰克逊（James R. Jackson）在研究机加工车间作业调度时，基于保罗·伯克（Paul Burke）1956年的定理发展了排队网络。<sup>[1](https://www.informs.org/Explore/History-of-O.R.-Excellence/O.R.-Methodologies/Queueing-Models)</sup>

## 变体

**单站点模型**主要在到达和服务假设以及公式复杂度上有所不同。对于 M/M/1，\( P_{0} \) = 1 − r，\( L_{\mathrm{q}} \) = r²/(1 − r)，其中 r = λ/µ 为输入负载。<sup>[13](https://rossetti.github.io/RossettiArenaBook/app-qt-sec-formulas.html)</sup> 对于 M/G/1，波拉切克—欣钦公式给出队列中的平均等待时间 \( W_{q} = \lambda \cdot E[X^{2}]/(2(1 - \rho)) \)，由平均剩余服务时间和利特尔定理导出，因此系统中平均时间为 E[X] + Wq；M/M/1 队列等待时间 Wq = ρ/(µ(1 − ρ)) 恰好是 M/D/1 值 Wq = ρ/(2µ(1 − ρ)) 的两倍，且由于 E[X²] 无上界，利用率低于 1 的 M/G/1 队列仍可能具有无限平均等待时间。<sup>[14](https://richardclegg.org/previous/networks2/Lecture9_06.pdf)</sup> 埃尔朗损失系统 M/G/c/c 的 \( P_{0} = [\sum_{n=0}^{c} r^{n}/n!]^{-1} \)，队列长度为零，因为溢出顾客被阻塞。<sup>[13](https://rossetti.github.io/RossettiArenaBook/app-qt-sec-formulas.html)</sup>

**排队网络**对顾客在站点之间移动的系统进行建模。杰克逊网络由 J 个节点组成，每个节点有一个或多个服务器，处理时间独立同分布且服从指数分布，服务率可以同时取决于节点和本地队列长度。<sup>[15](https://doi.org/10.1287/mnsc.10.1.131)</sup><sup> • </sup><sup>[16](https://link.springer.com/chapter/10.1007/978-1-4757-5301-1_2)</sup> 杰克逊1957年的论文《等待线网络》分析了一个作业可在任意位置进入或离开的多设备系统，其1963年的论文《类作业车间排队系统》获得了一大类网络的队列长度平衡联合分布，其中到达率取决于在场顾客数，服务率取决于本地队列长度。<sup>[17](https://doi.org/10.1287/opre.5.4.518)</sup><sup> • </sup><sup>[15](https://doi.org/10.1287/mnsc.10.1.131)</sup> 这些是乘积形式解：稳态分布分解为各节点项的乘积，因此每个队列可以独立分析，利用率、吞吐量和响应时间可通过高效算法得出。<sup>[18](https://dl.acm.org/doi/10.5555/1768017.1768019)</sup> 该定理将乘积形式推广到具有多顾客类别和多种服务规则（先到先服务、[处理器共享](https://www.edgepedia.org/zh/processor-sharing)、无排队、后到先服务）的开放、封闭和混合网络；在先到先服务中心，所有类别的服务分布必须相同且为指数分布。<sup>[6](https://www.dsi.unive.it/~balsamo/pub/pfwhite99.pdf)</sup><sup> • </sup><sup>[19](https://www.inf.puc-rio.br/~inf2511/inf2511_files/menu/material/suplementar/papers/historic/p248-baskett.pdf)</sup> F. P. 凯利（F. P. Kelly）1975年的论文获得了具有不同类型顾客的排队网络的平衡分布，并在某些情况下证明队列的状态与网络其余部分独立。<sup>[20](https://doi.org/10.2307/3212869)</sup> 关于相位型服务队列的早期处理见于 R. R. P. 杰克逊（R. R. P. Jackson）1954年的论文。<sup>[21](https://doi.org/10.1057/jors.1954.23)</sup> 在计算方面，布曾（Buzen）1973年的卷积算法评估具有指数服务器的封闭网络，<sup>[22](https://doi.org/10.1145/362342.362345)</sup> 而平均值分析这一递归算法可评估乘积形式的 BCMP 网络。<sup>[6](https://www.dsi.unive.it/~balsamo/pub/pfwhite99.pdf)</sup> PASTA 性质本身由罗纳德·W·沃尔夫（Ronald W. Wolff）在1982年的论文《泊松到达看到时间平均》中确立。<sup>[23](https://doi.org/10.1287/opre.30.2.223)</sup>

## 应用

电话工程仍是经典场景：埃尔朗 B 公式和 C 公式至今仍在使用，服务器随负载伸缩构成了平方根人员配置的基础，后者在呼叫中心得到广泛应用。<sup>[11](https://onlinelibrary.wiley.com/doi/10.1111/j.1467-9574.2008.00395.x)</sup> 在计算领域，网络模型的首次成功应用出现在1965年，谢尔（Scherr）使用机器维修员模型分析了麻省理工学院的分时系统 CTSS，穆尔（Moore）后来证明排队网络模型可以预测密歇根终端系统上的响应时间，误差在10%以内。<sup>[7](https://dl.acm.org/doi/epdf/10.1145/356733.356735)</sup> 排队论也被应用于医院急诊科。<sup>[24](https://onlinelibrary.wiley.com/doi/10.1111/itor.12400)</sup> 近期工作将该方法推广到机器学习系统：学习增强调度利用机器学习生成的服务时间预测来改进 M/G/1 队列中的 FIFO 和 SRPT 策略，<sup>[25](https://arxiv.org/pdf/2503.07545v1.pdf)</sup> 其基础是早期用监督机器学习方法求解 GI/GI/1 队列的工作，<sup>[26](https://doi.org/10.1287/ijoc.2022.0263)</sup> 大语言模型推理服务也产生了具有状态依赖服务率的排队模型，而 Sarathi-Serve 等系统则处理大语言模型推理的吞吐量—延迟权衡。<sup>[27](https://doi.org/10.48550/arxiv.2403.02310)</sup>

## 局限与替代方案

经典公式建立在马尔可夫假设之上，而真实流量常常违反这些假设。M/M/1 队列假定泊松到达、指数服务和单一 FIFO 队列且缓冲区无限，这使得延迟计算简单但不现实；实测互联网流量具有自相关性，更符合威布尔和对数正态等重尾分布。<sup>[28](https://ar5iv.labs.arxiv.org/html/2603.28394)</sup> 放宽假设会产生 G/G/1 型模型，这些模型更难求解且可能没有精确解，需要近似求解器。<sup>[28](https://ar5iv.labs.arxiv.org/html/2603.28394)</sup> 即使在 M/G/1 内部，重尾服务也可能在利用率低于 1 时导致平均等待时间无限。<sup>[14](https://richardclegg.org/previous/networks2/Lecture9_06.pdf)</sup>

稳态分析是第二个约束。许多系统具有时变参数，例如呼叫中心的呼叫量和坐席数；此时利特尔定律等稳态关系必须重新表述，这一分析脉络可追溯到柯尔莫哥洛夫（Kolmogorov）1931年的工作。<sup>[29](https://www.sciencedirect.com/science/article/abs/pii/S0305048315002170)</sup> 排队模型还给出聚合预测（如平均分组延迟），而非逐分组的洞察，并且将硬件抽象为服务器。<sup>[28](https://ar5iv.labs.arxiv.org/html/2603.28394)</sup> 与替代方案相比：解析排队方法产生精确结果，但随着模型规模和复杂度增长或问题为非马尔可夫时很快变得不适用；当系统为非马尔可夫且不具有再生结构时，仿真往往是唯一可能的方法，而流体模型将数据视为连续流，能够基于常微分、随机和偏微分方程进行描述。<sup>[30](https://eudl.eu/pdf/10.4108/valuetools.2007.1807)</sup><sup> • </sup><sup>[28](https://ar5iv.labs.arxiv.org/html/2603.28394)</sup> 在实践中选择是顺序性的：假设成立时用精确公式，近似成立时用近似方法，两者都不适用时用仿真。

## References

1. [Queueing Models (INFORMS History of O.R.)](https://www.informs.org/Explore/History-of-O.R.-Excellence/O.R.-Methodologies/Queueing-Models)
2. [Tables of Queue Size and Waiting Time Distributions for M/M/c, M/D/c, and D/M/c Queueing Systems](https://apps.dtic.mil/sti/pdfs/ADA089540.pdf)
3. [Queueing Notation (Cooper, Wiley Encyclopedia of Operations Research and Management Science)](https://www.cse.fau.edu/~bob/publications/Queueing%20Notation%20-%20Cooper%20%28EORMS%29.pdf)
4. [The M/M/1 system (chapter 3, Eindhoven lecture notes)](https://iadan.win.tue.nl/blockq/h3.pdf)
5. [Queueing theory (Statprob) (encyclopediaofmath.org)](https://encyclopediaofmath.org/wiki/Queueing_theory_%28Statprob%29)
6. [Queueing networks (survey, Balsamo)](https://www.dsi.unive.it/~balsamo/pub/pfwhite99.pdf)
7. [The Operational Analysis of Queueing Network Models (Denning & Buzen, ACM Computing Surveys 1978)](https://dl.acm.org/doi/epdf/10.1145/356733.356735)
8. [Queueing models and some fundamental relations (Eindhoven lecture notes)](https://iadan.win.tue.nl/que/h2.pdf)
9. [Simple queueing models (University of Bristol lecture notes)](https://people.maths.bris.ac.uk/~maajg/teaching/iqn/queues.pdf)
10. [Fundamental Queueing Model (MIT, Urban Operations Research ch. 4.5)](https://web.mit.edu/urban_or_book/www/book/chapter4/4.5.html)
11. [Back to the roots of the M/D/s queue and the works of Erlang, Crommelin and Pollaczek (Statistica Neerlandica)](https://onlinelibrary.wiley.com/doi/10.1111/j.1467-9574.2008.00395.x)
12. [David G. Kendall (1953). Stochastic Processes Occurring in the Theory of Queues and their Analysis by the Method of the Imbedded Markov Chain. The Annals of Mathematical Statistics.](https://doi.org/10.1214/aoms/1177728975)
13. [C.4 Summary of Queueing Formulas (Simulation Modeling and Arena companion)](https://rossetti.github.io/RossettiArenaBook/app-qt-sec-formulas.html)
14. [Lecture 9, The M/G/1 System (Richard Clegg, QMUL)](https://richardclegg.org/previous/networks2/Lecture9_06.pdf)
15. [James R. Jackson (1963). Jobshop-Like Queueing Systems. Management Science.](https://doi.org/10.1287/mnsc.10.1.131)
16. [Jackson Networks (Chen & Yao, Fundamentals of Queueing Networks, 2001)](https://link.springer.com/chapter/10.1007/978-1-4757-5301-1_2)
17. [James R. Jackson (1957). Networks of Waiting Lines. Operations Research.](https://doi.org/10.1287/opre.5.4.518)
18. [Queueing networks (Balsamo tutorial, SFM proceedings)](https://dl.acm.org/doi/10.5555/1768017.1768019)
19. [Open, Closed, and Mixed Networks of Queues with Different Classes of Customers (BCMP)](https://www.inf.puc-rio.br/~inf2511/inf2511_files/menu/material/suplementar/papers/historic/p248-baskett.pdf)
20. [F. P. Kelly (1975). Networks of queues with customers of different types. Journal of Applied Probability.](https://doi.org/10.2307/3212869)
21. [R. R. P. Jackson (1954). Queueing Systems with Phase Type Service. Journal of the Operational Research Society.](https://doi.org/10.1057/jors.1954.23)
22. [Jeffrey P. Buzen (1973). Computational algorithms for closed queueing networks with exponential servers. Communications of the ACM.](https://doi.org/10.1145/362342.362345)
23. [Ronald W. Wolff (1982). Poisson Arrivals See Time Averages. Operations Research.](https://doi.org/10.1287/opre.30.2.223)
24. [Applying queueing theory to emergency department operations: survey and comparison with simulation (ITOR)](https://onlinelibrary.wiley.com/doi/10.1111/itor.12400)
25. [Queueing, Predictions, and LLMs: Challenges and Open Problems](https://arxiv.org/pdf/2503.07545v1.pdf)
26. [Opher Baron and colleagues (2023). Supervised ML for Solving the GI/GI/1 Queue. INFORMS journal on computing.](https://doi.org/10.1287/ijoc.2022.0263)
27. [Agrawal, Amey and colleagues (2024). Taming Throughput-Latency Tradeoff in LLM Inference with Sarathi-Serve. arXiv (Cornell University).](https://doi.org/10.48550/arxiv.2403.02310)
28. [From Simulation to Deep Learning: Survey on Network Performance Modeling Approaches](https://ar5iv.labs.arxiv.org/html/2603.28394)
29. [Performance analysis of time-dependent queueing systems: Survey and classification (Queueing Systems)](https://www.sciencedirect.com/science/article/abs/pii/S0305048315002170)
30. [Simulation versus Analytic-Numeric Methods: Illustrative Examples (VALUETOOLS 2007)](https://eudl.eu/pdf/10.4108/valuetools.2007.1807)

---
*Initially written Sep 29, 2026 · Reviewed: Sep 30, 2026 · Edited: Sep 30, 2026 · Last review: Sep 30, 2026*

Topic: 技术与人造世界 › 计算技术与数字系统 › 人工智能与数据 › Algorithms and computational methods

Copyright 2026 Edgepedia

License: Edgepedia Community License 1.0, https://www.edgepedia.org/edgepedia/license

Source: https://www.edgepedia.org/zh/queueing-model

English original: https://www.edgepedia.org/queueing-model
