Converting an NFA to DFA

1.6k Views Asked by At

I am atttempting to convert an NFA into an equivalent DFA. I did it, but i am not sure if it is correct. If anyone can please take a look at let me know if it is correct or if there is something wrong with it, I'd really appreciate it. Thank you.

(Note:I just realized i have 2 {q1,q2})

UPDATED VERSION: enter image description here

Here it is:enter image description here

2

There are 2 best solutions below

2
On BEST ANSWER

Note that if you look at the transition from $q_1$ with the symbol $0$, then it can go to $q_1$ as well by using the empty transition after passing through $q_0$ first. The DFA you've written down doesn't accept "00", which is accepted by the NFA above.

You also need, as mentioned in the other answer, to make the start state $\{q_0, q_1\}$, since that empty transition means that that the empty string is accepted, since it is accepted by the NFA.

0
On

If lambda is the empty string then that isn't correct. Remember the start state is the epsilon closure of the start state - in other words the start state should be the union of q0 and q1

*note I havent done NFA to DFA in awhile so correct me if im wrong.