Questions tagged [automata]

Automata Theory, including abstract machines, grammars, parsing, grammatical inference, transducers, and finite-state techniques

Automata (plural of automaton) are abstract models of machines. These machines take an input such as a string of characters and give some output, often an "accept" or "decline" value.

These machines are closely related to . Many languages can be categorized based on the type of automata that can accept them. For instance,

  • regular languages can be recognized by some deterministic finite automata.
  • context-free languages can be recognized by some pushdown automata.
  • recursively enumerable languages can be recognized by some Turing machine.

There are many different types of automata, each with slightly different definitions. A few examples are

  • Deterministic Finite Automata (DFA)
  • Nondeterministic Finite Automata (NFA)
  • Pushdown Automata
  • Infinite Automata
  • Alternating Automata

For instance, a deterministic finite automata $A$ has five parts:

  • a finite set of states $Q$
  • a finite set of input symbols called the alphabet $\Sigma$
  • a transition function $\delta: (Q\times \Sigma)\rightarrow Q$
  • an initial state $q_0 \in Q$
  • a set of accept states $F\subseteq Q$

The automaton $A$ takes in a string $\sigma$ of characters of $\Sigma$. The automaton starts at state $q_0$ and then for each letter of $\sigma$ it moves to another state according to the transition function $\delta$. Once the automaton has used every letter of $\sigma$, if its final state is in $F$, then we say that $A$ accepts $\sigma$.

For questions also about

1841 questions
3
votes
0 answers

Lattice worms with nontrivial deaths

In Paterson's worms, a triangular lattice is used. A worm can move in 6 directions. As each node is hit, the worm follows an internal rule for which edge it will eat next based on the edges already eaten. If it reaches the starting node with all…
Ed Pegg
  • 20,955
3
votes
1 answer

Decide whether DFA accepts all Strings

Wikipedia : Because DFAs can be reduced to a canonical form (minimal DFAs), there are also efficient algorithms to determine: whether a DFA accepts any strings. whether a DFA accepts all strings. whether two DFAs recognize the same…
CodeLover
  • 185
3
votes
2 answers

Why is a 3-PDA no more powerful than a 2-PDA?

A k-PDA is a pushdown automata with k stacks. My textbook on Computation Theory has an exercise that asks to prove that 3-PDA is no more powerful than a 2-PDA. Now consider the language that I made up while trying to think of a counter-example: $ L…
3
votes
0 answers

Define NFA for the following languages

Question: Define NFA for the following languages : $L_1=\{\sigma w \sigma\big| \sigma\in\{a,b,c\},w\in\{a,b,c\}^*\}$ $L_n=\{w\in\{0,1\}^* \big| the \ n^{th} \ from \ last \ char\ is\ 1\}$ $Solution.A.$ we define NFA for $L_1$. Let $$A=(…
Chopin
  • 872
3
votes
1 answer

Build a NFA that accepts $L_k=\{w\#w\quad |\quad w\in\{a,b\}^*,|w|=k\}$, where $\Sigma=\{a,b,\#\}$

i've been trying this for hours... Let $$k\geqslant 1, \quad \Sigma=\{a,b,\#\}$$ $$L_k=\{w\#w\quad |\quad w\in\{a,b\}^*,|w|=k\}$$ Let's say that $A$ is a NFA that accepts $L_k$. First of all, What's the minimum number of states in $A$…
ryden
  • 583
3
votes
2 answers

Proving prefix/suffix exists for finite automata

My task is to show that if a language $L \subseteq \{a, b\}^*$ is recognised by a finite automaton then there exists a finite automaton that recognise all the prefixes and suffixes of the word in $L$. $$\text{Pref}(L) = \big\{x \in \{a,b\}^* \big|…
3
votes
2 answers

Can _any_ NFA be converted to a DFA?

I was wondering if for every NFA there exists an equivalent DFA? I think the answer is yes. How would one prove it? Since I'm just starting up learning about Automata I'm not confused about this and especially the proof of such a statement.
Swair
  • 597
  • 5
  • 14
3
votes
0 answers

Finding a language the accepts a given push-down automaton

Ok, so given the following automaton: I need to find the language that accepts it (no need for formal prove, a short intuitive explanation is good enough). I think the answer here is {$a^{11+6k}, k≥0$}. I can explain why the shortest word that can…
John
  • 341
3
votes
1 answer

What are annihilators?

I was recently listening to Automata lecture, there it was told told that an empty set is an Annihilator for concatenation just like $0$ is for multiplication. What do we mean by this statement?
CodeYogi
  • 259
2
votes
1 answer

Constructing a NFA from a right linear grammar, is this correct?

Given the right linear grammar G S -> abA | bbB | a A -> bB | aA | b B -> baB | aaaA | [Epsilon/Terminates] Is the NFA in the image below the proper construction of an NFA M(G) from the grammar?
KDecker
  • 861
  • 2
  • 11
  • 23
2
votes
1 answer

How to check whether a language is regular or not?

Say I have a given expression like $L_1\{a^n\mid n\ge0\}$ $L_2\{b^n\mid n\ge 0\}$ Then what is the procedure of checking weather L1.L2 is regular or not?
Pritam
  • 21
2
votes
1 answer

Stack automata with nonequality

I encontered the following problem that I'm unable to solve. The goal is to construct a stack automata, that accepts language $$ L = \left\{u\mathrm{\underline{c}}v \mid u,v \in \{\mathrm{\underline{a}},\mathrm{\underline{b}}\}^* \text{ and } u…
2
votes
2 answers

An algorithm that minimises the number of states for a conversion from a DFA to an NFA

I am looking for an algorithm that can convert from a DFA to an NFA, while at the same time producing the minimum number of states for the NFA. My gut tells me this can be done with around $n$ states, where the DFA has $O(2^n)$ states. That is, I…
Andries
  • 21
2
votes
2 answers

Pushdown Automata

I having trouble constructing NPDAs for these two languages: $L_1 = \{a^nb^m \mid 2n \le m \le 3n\}$ $L_2 = \{a^nb^mc^k \mid n = m \: or \: m \ne k\}$ Would these be the proper states for the first one? $q_0$ – reading $a$’s (initial state) …
2
votes
2 answers

Combining two DFAs into an NFA to recognize concatenation

Suppose we have two separate DFAs that each recognize their own language. What is the most efficient way to combine these two DFAs into one NFA that recognizes the concatenation of both languages?
1
2
3
17 18