Find $L_1$ and $L_2$ (formal languages)

54 Views Asked by At

We have two languages $L_1, L_2 \subseteq \{{a, b}\}^{*}$.

According to the following formulas find $L_1$ and $L_2$:

$L_1 = \{\lambda\} \cup \{a\}.L_1 \cup \{b\}.L_2 $

$L_2 = \{\lambda\} \cup \{b\}.L_2 $

I am trying to solve this question. extra explaination would be great. Thank you in advance for your help.

Edit 1: Here's what I think so far:

About the $L_2$, I can say that $L_2$ contains the empty string and every word in $L_2$ starts with the letter {b}.

About the $L_1$, I can say that $L_1$ also contains the empty string, every word in $L_1$ starts with the letter {a} followed by whatever we had in $L_1$ or letter {b} followed by whatever we had in $L_2$.

Is the following corrct?

$L_1 = \{a, b\}^*$

$L_2 = \{b\}.\{a, b\}^*$

1

There are 1 best solutions below

0
On BEST ANSWER

Let $1$ be the empty word and let $+$ denote union. Your system of equation becomes \begin{align} L_1 &= 1 + aL_1 + bL_2 \\ L_2 &= 1 + bL_2 \end{align} All you need to know is Arden's rule, which states that if $K$ and $L$ are languages such that $1 \notin K$, then $K^*L$ is the unique solution to the equation $X = KX + L$.

Applying Arden's rule to the second equation, one gets $L_2 = b^*1 = b^*$. Carrying this over to the first equation, one obtains $L_1 = 1 + aL_1 + bb^* = aL_1 + b^*$, whence $L_1 = a^*b^*$ by Arden's rule.