1

Given two regular languages L1 and L2 over alphabet Σ, we define the operator RQ(L1, L2) = {w | there exists a word v in L2 such that wv is in L1}. The task is to determine the smallest language class among Regular, LL, CFG, and DCFG that certainly contains RQ(L1, L2).

So, I started with the most restricted of the languages I mentioned, which is Regular. But the problem is that I don't really have a formal or actual definition of RQ, or L1 and L2 for that matter. The only thing I know is that L1 & L2 are regular and then I know the definition of RQ. So, how can I use the pumping lemma or DFA without the expression for RQ to for example prove or disprove that it is a regular language?

What I need help with is grasping the problem, and maybe assistance in making the question less abstract if possible, because I just can't wrap my head around it right now.

Thanks beforehand!

Hendrik Jan
  • 30,578
  • 1
  • 51
  • 105
Oh No
  • 11

1 Answers1

1

The question is about closure properties of regular languages. In your question it is asked what is the family tho which the quotient $RQ(L_1, L_2) = \{ w \mid wv \in L_1 \text{ for some } v \in L_2\}$ belongs. The questions we linked to in the comments give the constructions needed for this specific case.

But let me explain the background of proving closure properties. Assume we have any operation $\star$ and want to know the class of $K\star L$ for any regular $K,L$. As you state we do not know how $K,L$ look like. All we know is that the languages are regular. This means we may assume we have finite state automata or regular expressions for $K,L$. To show that $K\star L$ is regular (or context-free) we have to explain how to recognize $K\star L$ (by automaton or expression). Most texts/courses on formal languages have examples of such a construction; notably, if $K,L$ are regular, then so is $K\cup L$. There are contructions to build an automaton for $K\cup L$, given automata for $K,L$.

If we want to show that $K\star L$ for regular $K,L$ does not belong to to a certain class then it suffices to take a single example where $K\star L$ is not regular while $K$ and $L$ are.

Hendrik Jan
  • 30,578
  • 1
  • 51
  • 105