Skip to main content
deleted 4 characters in body
Source Link
Yuval Filmus
  • 279.1k
  • 27
  • 316
  • 512

Take this automaton for instance, it's an NFA and it accepts the string $0110$. To be more pedantic, it accepts strings that end in $10$.

Example automaton, source: https://cs.stackexchange.com/questions/61159/what-is-the-difference-between-following-two-finite-automata/61208

To see that we just need to check wetherwhether it reaches an accept state.

\begin{align*} q_0 & \rightarrow 1\\ q_0 & \rightarrow 0\\ \color{red}{q_1} &\rightarrow \color{red}{1}\\ q_2 &\rightarrow 0\\ \end{align*}

Now in the red line there was another possibility, that is when reading the second $1$ I could stay in $q_0$ and then stay in $q_0$ when reading the last $0$. Automata have no memory, so there's no way to 'save' a state and check later if my string ends with $10$, it's like this NFA it's making a guess wetherwhether the string ends with $10$ before branching to an acceptable state. Edit: The nondeterminism here is making lots of choices and always making the right ones.

It's easier to construct an NFA than it is to construct an DFA, the good thing is that both are equivalent.

Take this automaton for instance, it's an NFA and it accepts the string $0110$. To be more pedantic, it accepts strings that end in $10$.

Example automaton, source: https://cs.stackexchange.com/questions/61159/what-is-the-difference-between-following-two-finite-automata/61208

To see that we just need to check wether it reaches an accept state.

\begin{align*} q_0 & \rightarrow 1\\ q_0 & \rightarrow 0\\ \color{red}{q_1} &\rightarrow \color{red}{1}\\ q_2 &\rightarrow 0\\ \end{align*}

Now in the red line there was another possibility, that is when reading the second $1$ I could stay in $q_0$ and then stay in $q_0$ when reading the last $0$. Automata have no memory, so there's no way to 'save' a state and check later if my string ends with $10$, it's like this NFA it's making a guess wether the string ends with $10$ before branching to an acceptable state. Edit: The nondeterminism here is making lots of choices and always making the right ones.

It's easier to construct an NFA than it is to construct an DFA, the good thing is that both are equivalent.

Take this automaton for instance, it's an NFA and it accepts the string $0110$. To be more pedantic, it accepts strings that end in $10$.

Example automaton, source: https://cs.stackexchange.com/questions/61159/what-is-the-difference-between-following-two-finite-automata/61208

To see that we just need to check whether it reaches an accept state.

\begin{align*} q_0 & \rightarrow 1\\ q_0 & \rightarrow 0\\ \color{red}{q_1} &\rightarrow \color{red}{1}\\ q_2 &\rightarrow 0\\ \end{align*}

Now in the red line there was another possibility, that is when reading the second $1$ I could stay in $q_0$ and then stay in $q_0$ when reading the last $0$. Automata have no memory, so there's no way to 'save' a state and check later if my string ends with $10$, it's like this NFA it's making a guess whether the string ends with $10$ before branching to an acceptable state. The nondeterminism here is making lots of choices and always making the right ones.

It's easier to construct an NFA than it is to construct an DFA, the good thing is that both are equivalent.

added 90 characters in body
Source Link
Schonfinkel
  • 1.5k
  • 4
  • 13
  • 25

Take this automaton for instance, it's an NFA and it accepts the string $0110$. To be more pedantic, it accepts strings that end in $10$.

Example automaton, source: https://cs.stackexchange.com/questions/61159/what-is-the-difference-between-following-two-finite-automata/61208

To see that we just need to check wether it reaches an accept state.

\begin{align*} q_0 & \rightarrow 1\\ q_0 & \rightarrow 0\\ \color{red}{q_1} &\rightarrow \color{red}{1}\\ q_2 &\rightarrow 0\\ \end{align*}

Now in the red line there was another possibility, that is when reading the second $1$ I could stay in $q_0$ and then stay in $q_0$ when reading the last $0$. Automata have no memory, so there's no way to 'save' a state and check later if my string ends with $10$, it's like this NFA it's making a guess wether the string ends with $10$ before branching to an acceptable state. Edit: The nondeterminism here is making lots of choices and always making the right ones.

It's easier to construct an NFA than it is to construct an DFA, the good thing is that both are equivalent.

Take this automaton for instance, it's an NFA and it accepts the string $0110$. To be more pedantic, it accepts strings that end in $10$.

Example automaton, source: https://cs.stackexchange.com/questions/61159/what-is-the-difference-between-following-two-finite-automata/61208

To see that we just need to check wether it reaches an accept state.

\begin{align*} q_0 & \rightarrow 1\\ q_0 & \rightarrow 0\\ \color{red}{q_1} &\rightarrow \color{red}{1}\\ q_2 &\rightarrow 0\\ \end{align*}

Now in the red line there was another possibility, that is when reading the second $1$ I could stay in $q_0$ and then stay in $q_0$ when reading the last $0$. Automata have no memory, so there's no way to 'save' a state and check later if my string ends with $10$, it's like this NFA it's making a guess wether the string ends with $10$ before branching to an acceptable state.

It's easier to construct an NFA than it is to construct an DFA, the good thing is that both are equivalent.

Take this automaton for instance, it's an NFA and it accepts the string $0110$. To be more pedantic, it accepts strings that end in $10$.

Example automaton, source: https://cs.stackexchange.com/questions/61159/what-is-the-difference-between-following-two-finite-automata/61208

To see that we just need to check wether it reaches an accept state.

\begin{align*} q_0 & \rightarrow 1\\ q_0 & \rightarrow 0\\ \color{red}{q_1} &\rightarrow \color{red}{1}\\ q_2 &\rightarrow 0\\ \end{align*}

Now in the red line there was another possibility, that is when reading the second $1$ I could stay in $q_0$ and then stay in $q_0$ when reading the last $0$. Automata have no memory, so there's no way to 'save' a state and check later if my string ends with $10$, it's like this NFA it's making a guess wether the string ends with $10$ before branching to an acceptable state. Edit: The nondeterminism here is making lots of choices and always making the right ones.

It's easier to construct an NFA than it is to construct an DFA, the good thing is that both are equivalent.

Source Link
Schonfinkel
  • 1.5k
  • 4
  • 13
  • 25

Take this automaton for instance, it's an NFA and it accepts the string $0110$. To be more pedantic, it accepts strings that end in $10$.

Example automaton, source: https://cs.stackexchange.com/questions/61159/what-is-the-difference-between-following-two-finite-automata/61208

To see that we just need to check wether it reaches an accept state.

\begin{align*} q_0 & \rightarrow 1\\ q_0 & \rightarrow 0\\ \color{red}{q_1} &\rightarrow \color{red}{1}\\ q_2 &\rightarrow 0\\ \end{align*}

Now in the red line there was another possibility, that is when reading the second $1$ I could stay in $q_0$ and then stay in $q_0$ when reading the last $0$. Automata have no memory, so there's no way to 'save' a state and check later if my string ends with $10$, it's like this NFA it's making a guess wether the string ends with $10$ before branching to an acceptable state.

It's easier to construct an NFA than it is to construct an DFA, the good thing is that both are equivalent.