The Gateway to Computer Science Excellence
First time here? Checkout the FAQ!
x
0 votes
48 views

L = {a^n: n ≥ 2, is a prime number}.

This is not a regular language.

What about L*?

Is it regular? Please explain.

asked in Theory of Computation by Junior (507 points) | 48 views

1 Answer

+1 vote

Let ∑ = {a} and L1 = ∑* 

Then we can say that L1 is regular.

Now take any arbitrary string x belongs to ∑*

then x = am for some integer m

Now, m must have a prime factor p

Hence m = p*k (for some integer k)

Hence, am = ap . ap . ap . ap .....(concatenating the string ap k times)

Now, ap belongs to L (given in the question )  which means (ap )k  belongs to L*

Hence am belongs to L*  which means x belongs to L*

So, for any arbitrary string x belongs to ∑* we get that x belongs to L*

Hence ∑* = L* 

Thus L* is a regular language.

answered by Loyal (5.7k points)
edited by


Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true

35,518 questions
42,792 answers
121,605 comments
42,162 users