This practical is based on the related lecture: Lecture 2: Non-Determinism

Exercise 1

Given the NFA $N_1$ below in its graphical format, provide its formal definition $N_1=(Q,\Sigma,\delta,q_0,F)$:

NFA $N_1$

NFA $N_1$

Exercise 2

Provide the graphical format for the NFA $N_2=(\{q_0,q_1,q_2\},\{\mathtt{a},\mathtt{b}\},\delta,q_0,\{q_2\})$ where $\delta$ is

$$ \begin{array}{c|ccc} & \mathtt{a} & \mathtt{b} & \epsilon \\ \hline q_0 & \{q_0\} & \emptyset & \{q_1\} \\ q_1 & \{q_1\} & \{q_0,q_1\} & \emptyset \\ q_2 & \{q_0,q_1,q_2\} & \{q_0,q_1\} & \emptyset \end{array} $$

Exercise 3

Given the NFA $N_3$ below in its graphical format:

NFA $N_3$

NFA $N_3$

Exercise 4

For each regular expression $R_i$ below, provide an NFA $N_i$ such that $L(R_i)=L(N_i)$, that is, the NFA recognises the same language expressed by the RE.

<aside> 💡

Hints