in Theory of Computation retagged by
669 views
0 votes
0 votes
Let C be a context-free language and R be a regular language. Prove that
the language C $\cap$ R is context free.
in Theory of Computation retagged by
669 views

2 Answers

3 votes
3 votes
Best answer
A language is context-free only when it has only one condition in the formation of language.

For example $ L_1 = \{ a^n b^n | n>= 0 \} $

A regular language, will not have any conditions.

For example $ L_2 = {(a + b)}^* $

So Intersection, of condition and non condition will return that one condition,

Hence $ L_1 \cap L_2 = L_1 = \{ a^n b^n | n>= 0 \} $ Hence, Context free.
selected by
by

1 comment

L1 U L2 will it be DCFL or NCFL or not CFL ?? and how ??

Please explain
0
0
1 vote
1 vote
C: Context free language

R: Regular language

Every regular is context free but every context free is not regular

C(Context free)  INTERSECT  R(Regular)

C(Context free)  INTERSECT   R(Context free)                           Every Regular is context free

Output: CFL is not closed under Intersection

how can this be true  because CFl are not closed under intersection!!!!

plz make me correct if  i m wrong
reshown by

1 comment

CFL is not closed under intersection doesn't mean for Any  CFL's intersection can't be CFL

for some CFL's it can't be CFL but not for all

This is what i think
0
0