Skip to main content

Questions tagged [gray-code]

For questions about Gray codes, also known as reflected binary codes. It is a binary numeral system where two successive values differ in only one bit (binary digit).

Filter by
Sorted by
Tagged with
1 vote
2 answers
258 views

How to prove these rules produce a Gray code

There is a neat N-ary puzzle that has a solution that follows a 5-ary Gray code. https://www.schwandtner.info/publications/Kugellager.pdf It's not the typical reflected Gray code but still seems to go ...
user1301930's user avatar
0 votes
0 answers
15 views

Rearrange integers of a given length to avoid nearby typos

Inspired by a post about car park identifiers, I started wondering if we could avoid two adjacent car parks having identifiers which could easily be mistaken for each other: What are the best ...
David McKee's user avatar
1 vote
1 answer
57 views

If $\mathcal{C}$ is binary code self-orthogonal. I want to proof that $\textbf{1}=11\cdots 1 \in \mathcal{C}^{\perp}$ [closed]

$\textbf{Definition}$: A code $\mathcal{C}$ is self-orthogonal if $\mathcal{C}\subseteq \mathcal{C}^{\perp}$. I need proof that if $\mathcal{C}$ is binary code self-orthogonal. I want to proof that $\...
Andrés Reyes's user avatar
1 vote
1 answer
36 views

How to achieve upper bound on the minimum distance of a BCH code?

Let $[2^{m}-1, k ,d]_2$ be a BCH code, and let $g(x)\in GF[2](x)$ be its generating polynomial. Let $\alpha^{i_1}, \alpha^{i_2}, \alpha^{i_3},...,\alpha^{i_t}$ are the different roots of $g(x)$ (not ...
Robin Kurtz's user avatar
1 vote
1 answer
188 views

How to find equidistant hamming sequences?

Given N as the number of bits, how to find N sequences of (2^N/N) numbers each such that: given an arbitrary number n, there is always one number in each sequence that has hamming distance 1 from n. ...
fra93's user avatar
  • 11
1 vote
1 answer
55 views

What kind of symmetric codes have a very large minimum distance?

I am in search of symmetric error-correcting codes that have a very large minimum distance. A codebook $\mathcal{C}$ is called symmetric if $\bf{1}\in\mathcal{C}$. Now, if $[n,k,d]_2$ is a symmetric ...
Robin Kurtz's user avatar
3 votes
2 answers
70 views

How to simplify $\log_2$ more easily? Need guidance

So I need to calculate the entropy for a code. We are not allowed to use a calculator and I wonder how I can make my life easier. Given the following expression: $$ -\frac{6}{24}\log_2\left(\frac{6}{...
JohnGam's user avatar
  • 331
1 vote
0 answers
63 views

how to generalize gray coding

I have a set of $2^n$ points in $d$-dimensional real space. This is my "constellation" $C \subset {\mathbb R}^d$. Let $B$ be the set of binary unordered tuples of length $n$. I want find a $...
unknown's user avatar
  • 1,010
0 votes
0 answers
18 views

Complete Error correction code with length n on q letters.

$C$ is an complete e-Code for error correction with length $n$ on a set of $q$ letters. I want to compute the length of $C$ set.
AMZ's user avatar
  • 312
0 votes
1 answer
342 views

What is the size of the largest subset with a pairwise hamming distance of 3

Consider all binary strings of length $n$. Is there any known bounds on the size of the maximum subset such that the pairwise hamming distance between any two elements is at least 3.
newstein's user avatar
4 votes
1 answer
831 views

Subsets - Ranking / Unranking

I am looking at the following codes: It is lexicographic order related to ranking and unranking. Here is also an example: There is also the Gray code: with the repective examples: I haven't really ...
Mary Star's user avatar
  • 14k
4 votes
0 answers
395 views

Generalizing the Binary Reflected Gray Code

Let $Q_n$ denote the $n$-dimensional hypercube. It has a vertex for each binary string $x = x_n x_{n-1} \ldots x_1 \in \{0, 1\}^n$, and there is an edge between two vertices $v_x$ and $v_y$ if their ...
Nizbel99's user avatar
  • 917
2 votes
0 answers
260 views

Recursive on Gray Code

I have been curious since working on gray code that how can I write recursive function to calculate the integer that appear in position m of n-bit (as show in the link that I provide) like 3-bit Gray ...
Sebastian's user avatar
1 vote
0 answers
124 views

Does Gray Code converted to decimal give us a fractal?

I have noticed that Gray code converted to decimal and plotted into a chart (for instance, 2 is binary 10, but in Gray code it's 11, 11 in binary is 3 so I plotted 2 to 3, and so on) give a fractal-...
FlatAssembler's user avatar
1 vote
1 answer
259 views

Proving that for every n there exists one step codes from 0 to 2^(n)-1 (Gray Code)

Prove that for every n ∈ N with n ≥ 1 exists a one step binary code Cn for the number interval [0..2 n −1] with code words of length n. I have the hint of complete induction. So my start would be ...
Rapiz's user avatar
  • 115
3 votes
1 answer
54 views

Efficient generation of Gray code differences?

We know that the integers $1\le k\le 2^n-1$ (which for the purposes of this post may be identified with their binary expansions) can be mapped to their Gray code equivalents with $k \oplus (k >> ...
Alasdair's user avatar
  • 830
2 votes
1 answer
129 views

Polynomial-time algorithm to generate the "opposite" of a binary Gray code?

I'm seeking to implement a function $\phi(n,k,i)$ of integers $n,k,i$ where $$1 \leq k < n\\1 \leq i \leq N\\N = {n \choose k}$$ that returns all possible $n$-element binary vectors containing $k$ $...
COTO's user avatar
  • 472
0 votes
1 answer
573 views

Gray codes over strings of length n?

For any natural number n, an ordering of all binary strings of length n is a Gray code if it starts with 0^n, and any successive strings in the ordering differ in exactly one bit (the first and last ...
Geeklovenerds's user avatar
-1 votes
1 answer
37 views

Justify a Linear code

Consider the code $C=\{0000, 0010, 0020, abcd, 2110, 2100, 1220, 2120, 1210\}\subset F^{4}_3$ To determine $abcd\in F^{4}_3$ for $C$ to be linear is to say that $abcd$ is a linear combination of a ...
EL Comandante's user avatar
0 votes
1 answer
698 views

Determine the immediate successors of the following 9-tuple in the reflected Gray Code of order 9.

Problem: Determine the immediate successors of the following 9-tuple in the reflected Gray Code of order 9. $$111111111.$$ My Attempt: I am using the following algorithm to solve this problem: Begin ...
Student's user avatar
  • 9,218
19 votes
1 answer
380 views

Generalization of Gray codes

A friend of mine asked me if it was possible - physical difficulties aside - to generate all 32 combinations of raised/lowered fingers by changing status of a fixed number of fingers at every step. ...
mau's user avatar
  • 9,804