Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

1. A Gray code is a listing of all binary vectors (0, 1)\" so that adjacent vect

ID: 3194838 • Letter: 1

Question

1. A Gray code is a listing of all binary vectors (0, 1)" so that adjacent vectors in the list differ in exactly one position. For instance 00,01,11, 10 is a Gray code for n 2 (a) Show that, for even integers n, there is no Gray code which starts at 0 = 000..0 and ends at 1 = 111 . . . 1. (b) Find a Gray code for n = 3 which starts at 000 and ends at 111. 0OO.D Zg in the lexicographic 4 2, Describe, with proof, how to find the successor of x = xur2 list of all k-term weakly increasing sequences with symbols in (n). For instance, if n and k = 2, this list is: 11, 12, 13, 14, 22, 23, 24, 33, 34, 44. 3. Let X be a set and A S 2*, Prove that (X, A) is linear if and only if (():AEA is a family of pairwise disjoint sets.

Explanation / Answer

1.b

Gray code for n=3

000 , 001, 011, 010, 110, 100, 101, 111

The adjacent vector in the list should differ by exactly one position

1a The statement can be varified for the example given in que

For n=2

Gray code 00, 01, 11, 10

Similarly for n=4 if gray code would start with 0 it would not end with 1