CSE 355 Midterm 1

Réussis tes devoirs et examens dès maintenant avec Quizwiz!

To rip a state q r i p in the GNFA method, when there are following transitions: 1) transition from q to q r i p labeled A 2) transition from q r i p to q r i p labeled B 3) transition from q r i p to q ′ labeled C 4) transition from q to q ′ labeled D, we make a transition from q to q ′ labeled

( A ( B ) ∗ C ) ∪ D

Select an equivalent regular expression to ( A ∪ B ) ⋆

(a*b*)*

Suppose we have two DFAs that have 5 and 7 states respectively, and 2 and 3 accept states respectively. Using the product construction (assuming no minimization is done), how many final states will the union of these two DFAs have?

23

Suppose there is an NFA with n states. The equivalent DFA using the method taught in class will result in AT MOST:

2^n states

Select the false statement about the DFA to GNFA conversion algorithm.

DFAs must meet special requirements before the conversion can be done

( a b )^p c^)p + 1) is a good choice of a string to show that L 1 = { ( a b ) n c m | n ≥ m } is not regular.

False

A DFA can have multiple start states.

False

In order for a non-deterministic finite automaton (NFA) to accept an input, it must ONLY be in accept states when the string terminates.

False

Regular expressions can contain any operation closed under regular languages.

False

There is at least one DFA with its transition function that maps to an empty set.

False

We can still create DFAs/NFAs/Regular Expressions to recognize non-regular languages, we just can't do so algorithmically.

False

Given a GNFA with 5 states, which of the following are effected by the order in which the states are ripped out? I. The language of the GNFA II. The language of the resulting regular expression III. The form of the resulting regular expression

III only

Select the regular expressions which are necessarily equivalent to the regular expression

R ∪ ∅ R ∪ R R ∘ ϵ

Which of the following language does the DFA M described in the previous question recognize?

Set of all strings ending with 00

Select the false statement about the following NFA:

The alphabet must be {0, 1}

Suppose L is a regular language and let M = ( Q , Σ , δ , q s , F ) be a finite automaton that recognizes L. Which of the following statements justifies the existence of a finite pumping length p with respect to L?

The pigeon-hole principle demonstrates that | Q |is a candidate for p.

Adam has written down the start to his proof using the pumping lemma on the language D = { w w ∣ w ∈ { 0 , 1 } ∗ } . " Assume D is regular. Let p be the pumping length given by the pumping lemma Let s be the string 101101 The pumping lemma guarantees that s can be split into three pieces, s = xyz, satisfying the three conditions of the lemma. " What is wrong with this proof so far?

The string Adam has chosen is not of the right length for the pumping lemma.

Given an DFA M, M may be equivalent to multiple regular expressions.

True

L is a regular language if it could be described as a non-deterministic finite automaton (NFA).

True

The GNFA method is used to show that every regular language is described by a regular expression.

True

The alphabet of a DFA must have cardinality at least 1.

True

When splitting our string for the pumping lemma into xyz. It is possible that x or z might be empty.

True

Given a DFA ( Q , Σ , δ , q 0 , F ), what is the meaning of the statement δ ( q 0 , b ) = q 3?

When reading a b in state q 0 , the next state is q 3 .

Let L = { w x w ∣ w ∈ { 0 , 1 } ∗ , x ∈ { 0 } ∗ } Which of the following are valid strings to pick for the pumping lemma

s = 0^p s = 10^p10

Select all languages that are non-regular.

{ 0 n 1 n ∣ n ≥ 0 } { 0 n 1 n 2 m ∣ m , n ≥ 0 } { 0 n 1 n 2 n ∣ n ≥ 0 } { 0 n 1 m 2 m ∣ m , n ≥ 0 }

Select the language that can not be recognized by any DFA.

{xyy | x ∈ {0, 1}, y ∈ {0, 1}* }

Which of the following are true?

ε + = ε , ε ∗ = ε, ∅ ∗ = { ε }

Select the correct order of precedence (descending order) for regular operations.

1. Kleene Star 2. Concatenation 3. Union

Given a DFA M = ( { q 0 , q 1 , q 2 } , { 0 , 1 } , δ , q 0 , { q 2 } ) , where δ is described below, which of the following strings is not accepted by M? δ01q 0q 1q 0q 1q 2q 0q 2q 2q 0

111010110

How many entries are in the transition table for a DFA where | Q | = 4 , | Σ | = 5 , | F | = 3 .

20

With nondeterminism, a machine will accept if:

All of the input is read and at least one of the computation branches end on an accept state

L = { 0 n 1 m | n , m ≥ 0 } is non-regular.

False

Let L be a regular language. How many DFAs recognize language L?

Infinitely many

A DFA has to have at least two states, its start and an accept state.

False

By definition, the set of accept states F can NOT consist of all states Q.

False

For any string s in a language L, if s pumps for some decomposition, then L must be regular.

False

For every regular operation on the resulting regular expression, a GNFA will have an additional accept state.

False

If a finite automaton accepts no string, it recognizes only the empty string.

False

What is the maximum number of states a DFA can have?

None of the above.

A DFA may have zero accept states

True


Ensembles d'études connexes

PCAT - General Chemistry Problems [XI-XII]

View Set

Small Business Management Exam Review 1

View Set

Writing and graphing Equations in Two Variables

View Set

Past Perfect and Past Perfect Continuous

View Set

Cultural Anthropology (1), Cultural Anthropology Midterm (1), Chapter 2 - Cultural Anthropology (1), ALL Quizes Anthropology (1) large

View Set

Finance Exam 2 Connect questions

View Set

Ch 4 Respiratory disorders/pediatric success nclex ?s/ex2

View Set