## 2 Materials and Methods
### Non-Uniquely-Decodable Data Coding  
Let \(\mathcal{A}=a_{1}a_{2}\ldots a_{n}\) denotes an independently and identically distributed bit sequence, and \(d>1\) is a predetermined block length. Without loss of generality we assume \(n\) is divisible by \(d\). Otherwise, it is padded with random bits. \(\mathcal{A}\) can be represented as \(\mathcal{B}=b_{1}b_{2}\ldots b_{r}\), for \(r=\frac{n}{d}\) such that each \(d\)-bits long \(b_{i}\) in \(\mathcal{B}\) is from the alphabet \(\Sigma=\{0,1,2,\ldots 2^{d}-1\}\). We will first define the _minimum binary representation_ of an integer, and then use this definition to state our encoding scheme. **Definition 1**. : _The minimum binary representation (MBR) of an integer \(i\geq 2\) is its binary representation without the leftmost \(1\) bit. As an example, \(MBR(21)=0101\) by omitting the leftmost set bit in its binary representation as \(21=(10101)_{2}\)._  
**Definition 2**. : _Let \(\Sigma^{\prime}=\{\epsilon_{1},\epsilon_{2},\ldots\epsilon_{2^{d}}\}\) be a permutation of the given alphabet \(\Sigma=\{0,1,2,\ldots,2^{d}-1\}\), and \(W=\{w_{1},w_{2},\ldots,w_{2^{d}}\}\) is a code-word set such that_  
\[w_{i}= \begin{cases}MBR(2+\epsilon_{i})&\text{, if }\epsilon_{i}<2^{d}-2\\ \{MBR(2^{d}+\zeta):\forall\zeta\in\{0,1,\ldots,2^{d}-1\}\text{,where }\zeta=\{0,3\}\mod 4 \}&\text{, if }\epsilon_{i}=2^{d}-2\\ \{MBR(2^{d}+\zeta):\forall\zeta\in\{0,1,\ldots,2^{d}-1\}\text{,where }\zeta=\{1,2\}\mod 4 \}&\text{, if }\epsilon_{i}=2^{d}-1\end{cases} \]  
_The representation of the input \(\mathcal{A}=\mathcal{B}=b_{1}b_{2}\ldots b_{r}\) with the non-prefix-free code-word set \(W\) is shown by \(NPF(\mathcal{A})=c_{1}c_{2}\ldots c_{r}\) such that \(c_{i}=w_{1+b_{i}}\). When a code-word \(c_{i}\) has multiple options, a randomly selected one among the possibilities is used._  
The NPF coding of a sample sequence according to the Definitions 1 and 2 with the parameter \(d=3\) is shown in Figure 1. The code-words \(w_{1}\) and \(w_{5}\) are _sets_ as their corresponding \(\epsilon_{1}=6\) and \(\epsilon_{5}=7\) values are greater than or equal to \(6=2^{3}-2\). Thus, when \(c_{i}=w_{1}\) or \(c_{i}=w_{5}\), a randomly selected code-word respectively from sets \(w_{1}\) or \(w_{5}\), is inserted. **Proposition 1**. : _In a code-word set \(W\) that is generated for a block length \(d>1\) according to Definition 2, the lengths of the code-words in bits range from \(1\) to \(d\), where the number of \(\ell\)-bits long code-words for each \(\ell\in\{1,2,\ldots,d-1\}\) is \(2^{\ell}\), and for \(\ell=d\) there exist \(2\) sets of code-words each of which includes \(2^{d-1}\) elements._  
**Proof. ** According to Definition 2, the entities in \(W\) are minimum binary representations of numbers \(\{2,3,\ldots,2^{d+1}-1\}\). Since the MBR bit-lengths of those numbers range from \(1\) to \(d\), there are \(d\) distinct code-word lengths in \(W\). Each code-word length \(\ell\in\{1,2,\ldots,d-1\}\) defines \(2^{\ell}\) distinct code-words, and thus, total number of code-words defined by all possible \(\ell<d\) values becomes \(\sum_{i=1}^{d-1}2^{i}=2^{d}-2\). The remaining 2 code-words out of the \(|W|=2^{d}\) items require \(d\)-bits long bit sequences. For example, when \(d=3\), the \(W\) includes \(2(=2^{1})\) code-words of 1-bit long, \(4(=2^{2})\) code-words of length 2, and \(2(=2^{3}-6)\) code-word _sets_ of length 3-bits as shown in Figure 1.  
**Lemma 1**. : _The non-UD encoding \(NPF(\mathcal{A})\) of an i.i.d. bit sequence \(\mathcal{A}\) of length \(n=r\cdot d\) is expected to occupy \(r\cdot\left(d-2+\frac{d+1}{2^{d-1}}\right)\) = \(n\cdot\left(1-\frac{2}{d}+\frac{2(d+1)}{d\cdot 2^{d}}\right)\) bits space._  
Proof. : The total bit length of the NPF code-words is simply \(\sum_{\ell=1}^{d}C_{\ell}\cdot\ell\), where \(C_{\ell}\) denotes the number of occurrences of the \(b_{i}\) values represented by \(\ell\)-bits long code-words in \(\mathcal{B}\). Assuming the uniform distribution of \(\mathcal{B}\), each \(b_{i}\in\{0,1,2,\ldots,2^{d}-1\}\) appears \(\frac{r}{2^{d}}\) times.