Warning: foreach() argument must be of type array|object, bool given in /var/www/html/web/app/themes/studypress-core-theme/template-parts/header/mobile-offcanvas.php on line 20

Let Σ={0,1}.

a. Let A={0ku0kk1anduΣ*}Show that Ais regular.

b. Let B={0k1u0k|k1anduΣ*}Show thatB is not regular.

Short Answer

Expert verified

a) A is regular is proved.

b) Bis not regular is proved.

Step by step solution

01

Regular language.

A language is regular if it can be expressed in terms of regular expression. A regular expression can also be described as a sequence of pattern that defines a string. Regular expressions are used to match character combinations in strings.

02

Language is regular.

a).

For the string which containsΣ={0,1} where string can be made for the given language in the question and string is formed.

And for the given grammar the language is possible and also its string can be formed and also deterministic finite machine is possible.

The string formed is given as,

In regular expression,

0(0+1)*0

Here, this isbecause(0+1)* can generate all the string required,

(0+1)*=0(0+1)*0=00(0+1)*00=0n(0+1)*0n

Hence, This is proved that A={0ku0kk1anduΣ*}is regular. And this is a regular language and deterministic finite machine is possible.

03

Language is not regular.

b).

For the string which containsΣ={0,1} where language is regular if it can be expressed in terms of regular expression.A regular expression can also be described as a sequence of pattern that defines a string. Regular expressions are used to match character combinations in strings.

For the given language,B={0k1u0k|k1anduΣ*}.

B={0k1u0k|k1anduΣ*}.

The deterministic finite automata is not possible.

Hence,B={0k1u0k|k1anduΣ*}. is not regular. This is not a regular language and no deterministic finite machine is possible.

Unlock Step-by-Step Solutions & Ace Your Exams!

  • Full Textbook Solutions

    Get detailed explanations and key concepts

  • Unlimited Al creation

    Al flashcards, explanations, exams and more...

  • Ads-free access

    To over 500 millions flashcards

  • Money-back guarantee

    We refund you if you fail your exam.

Over 30 million students worldwide already upgrade their learning with Vaia!

One App. One Place for Learning.

All the tools & learning materials you need for study success - in one app.

Get started for free

Most popular questions from this chapter

Question: Prove that the following languages are not regular. You may use the pumping lemma and the closure of the class of regular languages under union, intersection, and complement.

a.{0n1m0n|m,n0}b.{0m1n|mn}c.{w|w{0,1}*isnotapalindrome}d.{wtw|w,t{0,1}+

Let N be an NFA with k states that recognizes some language A.

a. Show that if Ais nonempty, Acontains some string of length at most k.

b. Show, by giving an example, that part (a) is not necessarily true if you replace both A’s byA .

c. Show that If Ais nonempty, Acontains some string of length at most 2k.

d. Show that the bound given in part (c) is nearly tight; that is, for each k, demonstrate an NFA recognizing a languagerole="math" localid="1660752484682" Ak' where role="math" localid="1660752479553" Ak'is nonempty and where Ak'’s shortest member strings are of length exponential in k. Come as close to the bound in (c) as you can.

For languages AandB, let the shuffle of AandBbe the language

{ω|ω=a1b1...akbk,where  a1...akA  and  b1...bkB,each  ai,bi}.

Show that the class of regular languages is closed under shuffle.

Let Cn={x|xis a binary number that is a multiple of n}. Show that for each n1, the language Cnis regular

Recall that string x is a prefix of string y if a string z exists where xz=y, and that x is a proper prefix of y if in addition x6=y. In each of the following parts, we define an operation on a language A. Show that the class of regular languages is closed under that operation.

a)NOPREFIXA={wA|noproperprefixofwisamemberofA}.b)NOEXTENDA={wA|wisnottheproperprefixofanystringinA}.

See all solutions

Recommended explanations on Computer Science Textbooks

View all explanations

What do you think about this solution?

We value your feedback to improve our textbook solutions.

Study anywhere. Anytime. Across all devices.

Sign-up for free