代做CS1800 Discrete Structures Fall 2024 HW3: Sets, Algebra & Circuits代写Java编程
- 首页 >> C/C++编程CS1800 Discrete Structures
Fall 2024
HW3: Sets, Algebra & Circuits
Problem 1 [12 pts]: Beatles Set Representation
Consider the bit string representation of sets A and B:
A = {paul, george}
B = {ringo, george}
U john paul ringo george
A 0 1 0 1
B 0 0 1 1
A ∪ B
A ∩ B
AC
For each of sets below:
● complete the empty row to the table which gives the bit string representation of the set
● tell which logical operator (AND, NOT, XOR, OR) of the bit string representations of A, B yield the same bit string representation of the set
i A ∪ B
ii A ∩ B
iii AC
Problem 2 [16 pts (2 each)]: Set Operations (Listing)
Consider the subsets A = {2, 4, 6, 8} and B = {1, 3, 5} of the universal set U = {1, 2, 3, 4, 5, 6, 7, 8, 9}. Express each of the following sets as an explicit list (e.g. {3, 5, 6}).
i {x − 1 ∈ U | x ∈ A}
ii {x ∈ B | x is even}
iii {x ∈ A | x + 3 ∈ U}
iv A ∩ B
v A ∪ B
vi B − A
vii (A ∩ BC)C
viii A△B
Problem 3 [18 pts (3 each)]: Set Operations (Shading)
Shade the indicated regions of the following Venn diagrams.
Problem 4 [18 pts (6 each)]: Set Algebra
Simplify each of the following expressions by applying (and labelling) one law at time from logic-set-identities.pdf. Do not use the set difference operator in your simplifications. Note that the set U in the second
item is the universal set, which includes all elements.
i A ∩ A
ii (AC ∩ BC)C ∩ U
iii (A ∪ A) ∩ (B ∪ AC)
Problem 5 [18 pts (6 each)]: Set Builder Notation
i Express the set:
S = {n ∈ Z|n ∈ N and (−5 ≤ n) and (n < 7)}
by explicitly listing each item in a set (e.g. {1, 2, 3}). We assume that 0 ∈ N above.
ii Express the set B of all integers whose fourth-power (i.e., x4 ) is either 16 or 81 using set builder notation.
iii Express the set B immediately above by listing.
Problem 6 [18 pts (5, 8, 5)]: Digital circuit
i Using the circuit diagram above, express Y in terms of A,B, C and the logical operators ∧ , ∨ , ¬ .
ii Using the logic identities (i.e. “Laws of Logic”), simplify your statement of Y above. Label each step with the name of the logic identity you’ve used. (A simplified statement uses as few logical operators as possible)
iii Draw the logic circuit corresponding to your simplified statement above. (Notice: this is equiv- alent to the circuit above and yet it uses fewer circuit elements, requiring less resources to produce!)