

- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
What is a Queue Automaton?
<p>A queue automaton is like a push-down automaton (PDA) except that the stack is replaced by a queue.</p><ul class="list"><li><p>A queue is a tape allowing symbols to be written only on the left-hand end and read only at the right-hand end.</p></li><li><p>Each write operation (we’ll call it a push) adds a symbol to the left-hand end of the queue and each read operation (we’ll call it a pull) reads and removes a symbol at the right-hand end.</p></li><li><p>As with a PDA, the input is placed on a separate read-only input tape, and the head on the input tape can move only from left to right.</p></li><li><p>The input tape contains a cell with a blank symbol following the input, so that the end of the input can be detected.</p></li><li><p>A queue automaton accepts its input by entering a special accept state at any time.</p></li></ul><h2>Formal Definition</h2><p>A deterministic queue automaton (DQA) is defined as a seven tuple</p><pre class="result notranslate">(Q, Σ, Γ, δ, q0 , ⊥, F)</pre><p>Where,</p><ul class="list"><li><p>Q is a set of states,</p></li><li><p>Σ is an input alphabet,</p></li><li><p>Γ is a finite set of queue symbols,</p></li><li><p>q0 is a starting state,</p></li><li><p>⊥ is an empty queue symbol ⊥6= Γ,</p></li><li><p>The transition function δ is defined by Q × Σ ∪ {λ} × (Γ × Γ) ∪ ({⊥} × {⊥}) → Q × Γ ∪ {λ} × {keep, remove}, where λ signifies empty symbol. It must never be used as an input symbol.</p></li><li><p>F is a set of accepting states (F ⊆ Q).</p></li></ul><h2>Example</h2><p>Construct queue automata for language {a<sup>n</sup>b<sup>n</sup> | n >= 0}.</p><p>For the given language the number of states present in the automata are 4,</p><p>Q={q0,q1,q2,q3},</p><p>Input alphabet ={a,b}</p><p>The queue automata is as follows −</p><p><img src="https://www.tutorialspoint.com/assets/questions/media/53248/Queue.jpg" class="fr-fic fr-dib" width="322" height="225"></p>
- Related Questions & Answers
- What is the Queue class in C#?
- What is Heap queue (or heapq) in Python?
- What is Queue in Python? Explain with examples
- Design a push down automaton for L = {wwR | w ∈ {a, b}+}?
- What is the Count property of Queue class in C#?
- C++ Program to Perform Finite State Automaton based Search
- Creating a Queue in Javascript
- Difference Between Linear Queue and Circular Queue
- Stack and Queue in Python using queue Module
- queue::front() and queue::back() in C++ STL
- queue::empty() and queue::size() in C++ STL
- queue::push() and queue::pop() in C++ STL
- Check if a queue can be sorted into another queue using a stack in Python
- Creating a Priority Queue using Javascript
- Queue in Java
Advertisements