- 2079 Bhadra · 1.5 marks
Convert (01010111)gray to binary
Short answer
MSB of binary equals MSB of Gray (0). Each next binary bit = previous binary bit XOR current Gray bit: 0⊕1=1, 1⊕0=1, 1⊕1=0, 0⊕0=0, 0⊕1=1, 1⊕1=0, 0⊕1=1. Result: (01100101)₂.
Convert (01010111)gray = (?)₂.
Rule (Gray to binary): the MSB of binary equals the MSB of Gray. Each next binary bit = previous binary bit XOR current Gray bit, .
| Gray bit | Operation | Binary bit |
|---|---|---|
| 0 | copy MSB | 0 |
| 1 | 1 | |
| 0 | 1 | |
| 1 | 0 | |
| 0 | 0 | |
| 1 | 1 | |
| 1 | 0 | |
| 1 | 1 |
Check: converting 01100101 back to Gray () gives 01010111 again.
Answer: (= ).
✓ Answer checked by Claude Opus 5.5 (high effort)
Related questions
- Gray vs binary code, convert (10110)₂ to Gray · Digital Logic, chapter 1
- Convert (110111)gray to binary · Digital Logic, chapter 1
- Gray code, (11101)Gray to binary, FFH AND CAH · Digital Logic, chapter 1
- Convert (101001001)₂ to Gray · Digital Logic, chapter 1
- BCD code and 3-bit binary-to-Gray converter · Digital Logic, chapter 1
- Gray code and 3-bit binary-to-Gray converter · Digital Logic, chapter 1