Octal To Gray Code
How This Converter Works
Converts an unsigned octal integer to reflected binary Gray code; spaces and underscores are ignored and redundant leading zero bits are omitted.
Formula or rule
Map each octal digit to a three-bit group; concatenate, strip leading zeroes (or use 0), then XOR adjacent binary bits.
Example
- Input
- 55
- Calculation
- 5→101 and 5→101, giving 101101₂; its reflected Gray encoding is 111011.
- Result
- 111011