The Gateway to Computer Science Excellence

First time here? Checkout the FAQ!

x

0 votes

L={a^n b^n :n>=1} and R = (a+b)^*

L union R is going to be regular or not regular

plzz give reason L is not regular if N leads to infinity then how it can be regular ..........

L union R is going to be regular or not regular

plzz give reason L is not regular if N leads to infinity then how it can be regular ..........

+2 votes

Best answer

$L$ = {$ab,aabb,aaabbb,aaaabbbb....... $} $\Rightarrow DCFL$

$R$ = {$\epsilon, a ,b , aa,bb,ab,ba,aaa,bbb ,aabb,aaaabbbb,,,,,,,,$} $\Rightarrow Regular$

$L\cup R$ = {$\epsilon, a ,b , aa,bb,ab,ba,aaa,bbb ,aabb,aaaabbbb,,,,,,,,$} = $R$ $\Rightarrow Regular$

The thing is $R$ is a set of all strings over {$a,b$}. So $union$ of $R$ and $L$ is $R$ only. So it's regular.

$DCFL \cup Regular$ = $DCFL$ and Regular languages are subset of DCFL .

$R$ = {$\epsilon, a ,b , aa,bb,ab,ba,aaa,bbb ,aabb,aaaabbbb,,,,,,,,$} $\Rightarrow Regular$

$L\cup R$ = {$\epsilon, a ,b , aa,bb,ab,ba,aaa,bbb ,aabb,aaaabbbb,,,,,,,,$} = $R$ $\Rightarrow Regular$

The thing is $R$ is a set of all strings over {$a,b$}. So $union$ of $R$ and $L$ is $R$ only. So it's regular.

$DCFL \cup Regular$ = $DCFL$ and Regular languages are subset of DCFL .

- All categories
- General Aptitude 1.4k
- Engineering Mathematics 5.9k
- Digital Logic 2.3k
- Programming & DS 4.3k
- Algorithms 3.7k
- Theory of Computation 4.6k
- Compiler Design 1.7k
- Databases 3.4k
- CO & Architecture 2.9k
- Computer Networks 3.4k
- Non GATE 1.2k
- Others 1.3k
- Admissions 506
- Exam Queries 482
- Tier 1 Placement Questions 22
- Job Queries 64
- Projects 15

40,903 questions

47,560 answers

146,299 comments

62,306 users