The power of the queue

  • Ming Li
  • Luc Longpré
  • Paul M. B. Vitányi
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 223)


Queues, stacks (pushdown stores), and tapes are storage models which have direct applications in compiler design and the general design of algorithms. Whereas stacks (pushdown store or last-in-first-out storage) have been thoroughly investigated and are well understood, this is much less the case for queues (first-in-first-out storage). In this paper we present a comprehensive study comparing queues to stacks and tapes. We address off-line machines with a one-way input. In particular, 1 queue and 1 tape (or stack) are not comparable:

(1) Simulating 1 stack (and hence 1 tape) by 1 queue requires Ω(n4/3/logn) time in both the deterministic and the nondeterministic cases.

(2) Simulating 1 queue by 1 tape requires Ω(n2) time in the deterministic case, and Ω(n4/3/logn) in the nondeterministic case;

We further compare the relative power between different numbers of queues:

(3) Nondeterministically simulating 2 queues (or 2 tapes) by 1 queue requires Ω(n2/(log2n loglogn)) time and deterministically simulating 2 queues (or 2 tapes) by 1 queue requires Ω(n2) time. The second bound is tight. The first is almost tight.

(4) We also obtain the simulation results for queues: 2 nondeterministic queues (or 3 pushdown stores) can simulate k queues in linear time. One queue can simulate k queues in quadratic time.


Turing Machine Input Tape Length Prefix Input Head Work Tape 
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.


Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.


  1. [Aa]
    Aanderaa, S.O., "On k-tape versus (k-1)-tape real-time computation," in Complexity of Computation, ed. R.M. Karp, SIAM-AMS Proceedings, vol. 7, pp. 75–96, American Math. Society, Providence, R.I., 1974.Google Scholar
  2. [BGW]
    Book, R., S. Greibach, and B. Wegbreit, "Time-and tape-bound Turing acceptors and AFL's," J. Computer and System Sciences, vol. 4, pp. 606–621, 1970.Google Scholar
  3. [Ch]
    Chaitin, G.J., "Algorithmic Information Theory," IBM J. Res. Dev., vol. 21, pp. 350–359, 1977.Google Scholar
  4. [DGPR]
    Duris, P., Z. Galil, W. Paul, and R. Reischuk, "Two nonlinear lower bounds for on-line computations," Information and Control, vol. 60, pp. 1–11, 1984.Google Scholar
  5. [GKS]
    Galil, Z., R. Kannan, E. Szemeredi, “On nontrivial separators for k-page graphs and simulations by non-deterministic one-tape Turing machines,” in Proceedings 18th Annual ACM Symposium on Theory of Computing, 1986.Google Scholar
  6. [HS1]
    Hartmanis, J. and R.E. Stearns, "On the computational complexity of algorithms," Trans. Amer. Math. Soc., vol. 117, pp. 285–306, 1969.Google Scholar
  7. [HS2]
    Hennie, F.C. and R.E. Stearns, "Two tape simulation of multitape Turing machines," J. Ass. Comp. Mach., vol. 4, pp. 533–546, 1966.Google Scholar
  8. [HU]
    Hopcroft, J.E. and J.D. Ullman, Formal Languages and their Relations to Automata, Addison-Wesley, 1969.Google Scholar
  9. [Kl]
    Klawe, M., "Limitations on explicit construction of expanding graphs," SIAM J. Comp., vol. 13, no. 4, pp. 156–166, 1984.Google Scholar
  10. [Ko]
    Kolmogorov, A.N., "Three approaches to the quantitative definition of information," Problems in Information Transmission, vol. 1, no. 1, pp. 1–7, 1965.Google Scholar
  11. [Li1]
    Li, M., "Simulating two pushdowns by one tape in O(n**1.5 (log n)**0.5) time," 26th Annual IEEE Symposium on the Foundations of Computer Science, 1985.Google Scholar
  12. [Li2]
    Li, M., "Lower Bounds in Computational Complexity," Ph.D. Thesis, Report TR-85-663, Computer Science Department, Cornell University, march 1985.Google Scholar
  13. [Li3]
    Li, M., "Lower bounds by Kolmogorov-complexity", 12th ICALP, Lecture Notes in Computer Science, 194, pp. 383–393, 1985.Google Scholar
  14. [LV]
    Li, M. and P.M.B. Vitanyi, "Tape versus queue and stacks: The lower bounds," Submitted for publication.Google Scholar
  15. [LS]
    Leong, B.L. and J.I. Seiferas, "New real-time simulations of mul-tihead tape units," J. Ass. Comp. Mach., vol. 28, pp. 166–180, 1981.Google Scholar
  16. [Ma]
    Maass, W., "Combinatorial lower bound arguments for deterministic and nondeterministic Turing machines," Trans. Amer. Math. Soc., 292,2, pp. 675–693, 1985. (Preliminary Version “Quadratic lower bounds for deterministic and nondeterminstic one-tape Turing machines,” pp 401–408 in Proceedings 16th ACM Symposium on Theory of Computing, 1984.)Google Scholar
  17. [PSS]
    Paul, W.J., J.I. Seiferas, and J. Simon, "An information theoretic approach to time bounds for on-line computation," J. Computer and System Sciences, vol. 23, pp. 108–126, 1981.Google Scholar
  18. [Pa]
    Paul, W.J., "On-line simulation of k+1 tapes by k tapes requires nonlinear time," Information and Control, pp. 1–8, 1982.Google Scholar
  19. [So]
    Solomonov, R., Information and Control, vol. 7, pp. 1–22, 1964.CrossRefGoogle Scholar
  20. [Vi1]
    Vitányi, P.M.B., "One queue or two pushdown stores take square time on a one-head tape unit," Computer Science Technical Report CS-R8406, CWI, Amsterdam, March 1984.Google Scholar
  21. [Vi2]
    Vitányi, P.M.B., "An N**1.618 lower bound on the time to simulate one queue or two pushdown stores by one tape," Information Processing Letters, vol. 21, pp. 147–152, 1985.Google Scholar
  22. [Vi3]
    Vitányi, P.M.B., "On two-tape real-time computation and queues," J. Computer and System Sciences, vol. 29, pp. 303–311, 1984.Google Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 1986

Authors and Affiliations

  • Ming Li
    • 1
  • Luc Longpré
    • 2
  • Paul M. B. Vitányi
    • 3
    • 4
  1. 1.Department of Computer and Information ScienceThe Ohio State UniversityColumbus
  2. 2.Department of Computer ScienceUniversity of WashingtonSeattle
  3. 3.M.I.T. Laboratory for Computer ScienceCambridge
  4. 4.Centrum voor Wiskunde en InformaticaAmsterdamThe Netherlands

Personalised recommendations