1. Consider the operation of a machine with the data path of figure 2-2. Suppose that loading the ALU input registers takes 5 nsec, running the ALU takes 10 nsec, and storing the result back in the register scratchpad takes 5 nsec. What is the maximum num
DEFINITIONS N is an equivalence relation on set A if o a ~ a for all a A o if a ~ b, then b ~ a for all a,b A o if a ~ b and b ~ c, then a~c for all a,b,c A The Completeness Axiom If A is a subset of R, and A is bounded above, then sup (A) exists An infin
II. Let A be a countable set, B a subset of A and B is not finite. Prove that B is countable. A is countable. There exists a bijective function f : N A. there exists a function g : A N If you restrict the domain of g to B, then you get a new function h :
Name: _Solutions _ _ _ _
C SC/MATH 473
Sample Exam
b a b E a q b
3. RegExp NFA. Use the standard algorithm to convert (01)*(0+1)* to an NFA. (Show intermediate work to allow for partial credit.)
p
a O b
a
Midterm 1 TIME = 75 min Instructions: Write your n
Name: _ _ _S olutio ns _ _ _ _ _
C SC/MATH 473 Midterm 1 TIME = 75 min Instructions: Write your name in the space provided. Do ALL of the Short Answer problems (1-5), and do TWO of the Long Problems. Write all answers on this exam paper. When finished, pl
Johny Nguyen November 9th, 2010 CS 473 Homework 4 Downey
Problem 1
Show that L = cfw_anbmcndm | m, n 1 is not CFL. Proof: Suppose L is context free. Let p be the pumping length of L that is guaranteed
Johny Nguyen November 9th , 2010 CS 473 Homework 4 Downey
P roblem 1
Show that L = cfw_an bm cn dm | m, n 1 is not CFL. Proof: Suppose L is context free. Let p be the pumping length of L that is guaranteed to exist by the pumping lemma. Let s = apbpcpdp,
Johny Nguyen October 26th, 2010 CS 473 Homework 3 Downey
Problem 1
Use the Pumping Lemma for Regular languages to show that is not regular.
Assume L is regular. Let p be the pumping length given by the pumping lem
Johny Nguyen October 26th, 2010 CS 473 Homework 3 Downey
Problem 1
Use the Pumping Lemma for Regular languages to show that is not regular.
Assume L is regular. Let p be the pumping length given by the pumping lemma. Let s be the string apbapba2p. The pum
Johny Nguyen October 5 , 2010 CS 473 Homework 2 Downey
th
Problem 1 1. baa L(a*b*a*b*)? Yes. Say the first a* yields the empty string. The first b* yields one b, then we will have b. Let the second a* yie
Johny Nguyen October 5th, 2010 CS 473 Homework 2 Downey
Problem 1
1.
baa L(a*b*a*b*)?
Yes. Say the first a* yields the empty string. The first b* yields one b, then we will have b. Let the second a* yield aa, and the last b* yield the empty string. We wil
Johny Nguyen September 16th, 2009 CS 473 Homework 1 Downey
PROBLEM 1
Draw directed graphs representing relations of the following types: (a) Reflexive, transitive and antisymmetric. Antisymmetry of R means that (a,b) if (a,b) R and
Johny Nguyen September 16th, 2009 CS 473 Homework 1 Downey
PROBLEM 1
Draw directed graphs representing relations of the following types: (a) Reflexive, transitive and antisymmetric. Antisymmetry of R means that (a,b) if (a,b) R and a b, then (b,a)R.
(b) R
Let D R. D is said to be convex if a,b D, the line segment connecting and is contained in D.
Let D R. D is said to be connected if , D, : [0,1] D such that (0) = , (1) =
Let D . , x0 D. f is continuous at x0 if cfw_an x0, an D,
cfw_f(xn) f(x0).
Let D . ,
Let D R. D is said to be convex if a,b D, the line segment connecting is contained in D. Let D R. D is said to be connected if , = , (1) = Le t D . cfw_f(xn) f(x0).
a nd
D, : [0,1] D such that (0)
, x0 D. f is continuous at x0 if cfw_an x0, an D,
Le t D
1. Explain each of the following terms in your own words: a. Translator b. Interpreter c. Virtual machine 2. What is the difference between interpretation and translation? 3. Is it conceivable for a compiler to generate output for the microarchitecture le