• edited by
27,428 views
96 96 votes

Consider the following finite automata $P$ and $Q$ over the alphabet $\{a, b, c\}$. The start states are indicated by a double arrow and final states are indicated by a double circle. Let the languages recognized by them be denoted by $L(P)$ and $L(Q)$ respectively.

The automation which recognizes the language $L(P) \cap L(Q)$ is :

8 Answers

Best answer
105 105 votes

Design an automaton using $P$ and $Q$  having $p_0q_0$ as start state  

$\delta(p_0q_0,a) \rightarrow \delta(p_0,a) \cup \delta(q_0,a)$
$$\begin{array}{|l|l|l|l|}\hline \text{Q \ $\Sigma$}  &  \text{a} & \text{b} & \text{c} \\\hline  \text{$\rightarrow p_0q_0^*$}  &  \text{$p_1q_2$} & \text{$p_2q_1$} & \text{} \\\hline 
\text{$p_1q_2^*$}  &  \text{$p_3q_3$} & \text{} \\\hline \text{$p_2q_1^*$}  &  \text{$p_1q_2$} & \text{$p_3$ (No Need)} & \text{}\\\hline \text{$p_3q_3^*$}  &  \text{} & \text{$q_2$ (No Need)} & \text{$p_2q_1$} \\\hline \end{array}$$

In case of intersection final states are those where final states of P and final states of Q come together. 

"No need" in above table mean, when we reach to $p_3$ (or $q_2$) then we cannot reach to any final state because we cannot have states of $P$ and $Q$ together (intersection). Hence, this is not shown in diagram [may draw a dead state for it to make it a DFA (as noted at end) ]

Automaton results in:

That is option A .

Note : DFA must have transition for each symbol $Q \times \Sigma \rightarrow Q$ and hence our automaton is not a DFA as we do not have transitions to dead state.

• edited by
75 75 votes
See the languages being accepted by P and Q. In P before a 'c' there must be either 'b' or 'aa'. In Q, before 'c' there must be 'aa'. So, obviously, in their intersection before 'c' there must be 'aa' which is satisfied only by option A.
37 37 votes

One string "aa" is common to both.
Which is accepted by only A not by any other machine. (Ans)

3 3 votes
ans (A)...
2 2 votes

Another method for finding intersection is utilizing this property: L1 ∩ L2 = (L1' U L2')'

Now both the DFAs can be complemented (easy as only the set of final and non final states has to be changed), and then union can be applied (adding an initial state and then giving epsilon transitions from this state to both the previous initial states). However, this will give e-NFA which cannot be complemented directly. So we need to reduce it to a DFA and then complement it, to finally get L1 ∩ L2. This method may seem a little long but the only time consuming part is e-NFA to DFA conversion and if this part is simple for a given question then this method can also be used to find the intersection.

[Not giving an answer to this question because it has already been given. My aim was just to share this alternate method.]

1 1 vote
i checked "aac ", it worked, every  wrong option got  eliminated
("aac" is common in both )

hence A.😎
Answer:
Position:
Show:

Related questions

52 52 votes
8 answers 8 answers
13.3k
13.3k views
Ishrat Jahan asked Oct 30, 2014
13,308 views
Consider the regular expression $R = (a + b)^* (aa + bb) (a + b)^*$Which deterministic finite automaton accepts the language represented by the regular expression $R$?
59 59 votes
5 answers 5 answers
13.6k
13.6k views
Ishrat Jahan asked Oct 30, 2014
13,582 views
Consider the regular expression $R = (a + b)^* (aa + bb) (a + b)^*$Which of the following non-deterministic finite automata recognizes the language defined by the regular...
43 43 votes
10 answers 10 answers
11.7k
11.7k views
Ishrat Jahan asked Oct 30, 2014
11,714 views
Consider the following DFA in which $S_0$ is the start state and $S_1$, $S_3$ are the final states.What language does this $\textsf{DFA}$ recognize?All strings of $x$ and...
70 70 votes
8 answers 8 answers
23.3k
23.3k views
Ishrat Jahan asked Oct 30, 2014
23,297 views
Consider the regular expression $R = (a + b)^* \ (aa + bb) \ (a + b)^*$Which one of the regular expressions given below defines the same language as defined by the regula...