Questions tagged [dfa]
12 questions
8
votes
1 answer
Does a DFA accept an empty string if $q_0$ is the accept state?
Suppose $q_0$ is the start state, does this mean that if it's the accept state, then the machine must accept the empty string since it cannot have a transition with the empty string?
maregor
- 209
- 1
- 2
- 6
5
votes
1 answer
space complexity of DFA intersection problem
the DFA-intersection computation problem, given two DFAs specified on the input, compute the intersection DFA, or the decision problem to determine its emptiness, turns out to have wider/ deeper significance in computational complexity theory.[1][2]…
vzn
- 11,162
- 1
- 28
- 52
4
votes
2 answers
DFA to regular expression how to deal with 'sink state'
Didn't find a clear statement on this so I just want to make sure I'm right. If I have DFA with edges leading to a 'sink state' (non-accepting state we don't get out of) the edges leading to the sink state and the edge from the sink to itself won't…
Gil-Mor
- 141
- 1
- 3
2
votes
2 answers
Determining states in a DFA
In computational theory for deterministic finite automata, there is a 5-tuple representation containing $Q$, $\Sigma$, $\Delta$, $Q_0$ and $F$. I am wondering how one understands thinking about the number of states to construct such a…
Ryan
- 21
- 2
2
votes
1 answer
Bit-parallelism and NFA simulation
In several papers I have read that Bit-parallel pattern matching is an NFA-simulation.
My questions are:
1- Is it true in general? Or, is there any restrictions?
2- As any regular expression can be converted to NFA, how Bit-parallelism is able to…
MH Samadani
- 123
- 3
1
vote
1 answer
regular expression to accept all strings other than one containing ads or adlib
My intention is to select only those packages whose name do not contain adlib or ads. But if i add *adlib* and *ads* it selects all packages containing the substring adlib and ads. So i need a regular expression to select all packages that do…
Jose Kj
- 113
- 3
1
vote
1 answer
Proving $A$ avoiding $B$ regular if $A$ and $B$ are regular
Suppose we define an operation such that
$$A \text{ avoiding } B = \{w \in A \mid w\text{ has no substring in }B\}\,.$$
How can I prove that, if $A$ and $B$ are regular then $A\text{ avoiding }B$ is regular too?
I know I should either construct a…
Dr.Pro
- 23
- 1
- 6
1
vote
1 answer
How to draw a DFA for given language?
Give a finite state diagram for a DFA that accepts any word in the language $L = \{w \mid w \in \{a, b\}^* \text{ and }w \text{ alternates } a\text{'s and }b\text{’s and has an even number of }b\text{’s}\}$.
My attempt: I am having problem on how to…
max
- 123
- 3
1
vote
2 answers
Palindrome of fixed length
We know that general palindromes cannot be decided by a DFA.
Howeve if you restrict to case of even length palindromes, does a DFA need exactly $2^{2k}$ states where $2k$ is length of palindrome the language needs to accept?
I get this as lower…
Turbo
- 2,947
- 14
- 27
0
votes
0 answers
Proving right quotient of two languages
I know that if a language $L_1$ and a language $L_2$ are regular, then
$L1/L2$ is regular.
When we construct a DFA $M'=(Q, \Sigma, \delta, q_0, F)$, for each state $i$
we can make $i$ the start state (we'll represent is using $L'i$) and if $L'i…
user3295674
- 383
- 4
- 14
0
votes
1 answer
How would a DFA be designed to accept a language defined as the string comprised of every other character in each string in another language?
For example, you have a DFA that accepts the language comprised of strings aabbbaa and aaabbbbaaa, and you want to create a new DFA that accepts a language comprised of strings abba and aabba (strings made up of every other character in the strings…
Adam
- 9
- 2
-1
votes
1 answer
L equivalence classes
Let L be the language consisting of all strings in (a+b)* that have an even number of letters and do not have aaba as a substring.
Into how many L-equivalence classes is (a+b)* divided?
John doe
- 1