# Error-Correction Coding Using Polynomial Residue Number System
## 3 Theoretical Foundations of Building Redundant Codes of Polynomial Residue Number System
### PRNS Codes with One Control Base
 \tag{19}\]  
Therefore, the following inequality holds:  
\[\left[\frac{D_{iR}(z)}{P_{i}(z)}\right]-\left[\frac{D_{iV}(z)}{P_{i}(z)} \right]\
eq 0 \tag{20}\]  
If the weight of the orthogonal basis is \(m_{i}(z)\
eq 1\), then  
\[\left|R(z)-V(z)\right|_{p_{i}(z)}^{+}=\left|\frac{k(z)}{m_{i}(z)}\right|_{p_{ i}(z)} \tag{21}\]  
As \(m_{i}(z)\
eq 0\) and \(k(z)\
eq 0\), the right side of Equality (21) is a nonzero element \(\beta_{i}(z)\), which is a residue modulo \(p_{i}(z)\). Then, we obtain  
\[ \begin{array}{l}D_{iV}(z)=\left|d_{1}(z)B_{1}(z)+\ldots+V_{i}(z)B_{i}(z)+ \ldots+d_{n}(z)B_{n}(z)\right|_{W_{n}(z)}=\\ =\left|d_{1}(z)B_{1}(z)+\ldots+\left|R_{i}(z)-\beta_{i}(z)\right|_{p_{i}(z)}B _{i}(z)+\ldots+d_{n}(z)B_{n}(z)\right|_{W_{n}(z)}=\\ =\left|d_{1}(z)B_{1}(z)+\ldots+R_{i}(z)B_{i}(z)+\ldots+d_{n}(z)B_{n}(z)\right| _{W_{n}(z)}-\left|\beta_{i}(z)B_{i}\right|_{W_{n}(z)}=\\ =D_{iR}(z)-\left|\beta_{i}(z)B_{i}\right|_{W_{n}(z)}\end{array}  \tag{22}\]  
Therefore, the following inequality holds:  
\[\left[\frac{D_{iR}(z)}{P_{i}(z)}\right]-\left[\frac{D_{iV}(z)}{P_{i}(z)} \right]\
eq 0 \tag{23}\]  
The theorem is proved. \(\square\)  
**Theorem 2**. : _If an inequality_  
\[\left[\frac{D_{iR}(z)}{P_{i}(z)}\right]\
eq\left[\frac{D_{iV}(z)}{P_{i}(z)}\right] \tag{24}\]  
_exists for two code combinations \(D_{iR}(z)\) and \(D_{iV}(z)\) presented in the code of polynomial residue number system, then the following inequality holds:_  
\[R_{i}(z)\
eq V_{i}(z){\rm mod}p_{i}(z) \tag{25}\]  
**Proof of Theorem 2. ** The difference between two code combinations \(D_{iR}(z)=(d_{1}(z),\ldots,\)\(R_{i}(z),\ldots,\)\(R_{i}(z),\ldots,\)\(D_{iV}(z)=(d_{1}(z),\ldots,\)\(V_{i}(z),\ldots,d_{n}(z))\) is determined by the following expression:  
\[D_{iR}(z)-D_{iV}(z)=\left|R_{i}(z)-V_{i}(z)\right|_{p_{i}(z)}m_{i}(z)\frac{W_{n} (z)}{p_{i}(z)} \tag{26}\]  
Given Inequality (24), we can conclude that the first multiplier of Expression (26) is not zero. Then,  
\[R_{i}(z)\
eq V_{i}(z)\text{mod}p_{i}(z)\]  
The theorem is proved. \(\square\)  
Consider the application of the theorem in the example of a code of PRNS with various bases. **Example 2. **_The code of PRNS is set with the following bases: \(p_{1}(z)=z+1\), \(p_{2}(z)=z^{2}+z+1\), \(p_{3}(z)=z^{4}+z^{3}+2^{2}+z+1\), \(p_{4}(z)=z^{4}+z^{3}+1\), \(p_{5}(z)=z^{4}+z+1\). The operating range of the code is \(W_{5}(z)=\sum\limits_{i=1}^{5}P_{i}(z)=z^{15}+1\). The orthogonal bases for this modular code will have the following form:_  
\[B_{1}(z)=z^{14}+z^{13}+z^{12}+z^{11}+z^{10}+z^{9}+z^{8}+z^{7}+z^{6}+z^{5}+z^{4 }+z^{3}+z^{2}+z+1\]  
\[B_{2}(z)=z^{14}+z^{13}+z^{11}+z^{10}+z^{8}+z^{7}+z^{5}+z^{4}+z^{2}+z\]  
\[B_{3}(z)=z^{14}+z^{13}+z^{12}+z^{11}+z^{9}+z^{8}+z^{7}+z^{6}+z^{4}+z^{3}+z^{2 }+z\]  
\[B_{4}(z)=z^{14}+z^{13}+z^{12}+z^{11}+z^{9}+z^{7}+z^{6}+z^{3}\]  
\[B_{5}(z)=z^{12}+z^{9}+z^{8}+z^{6}+z^{4}+z^{3}+z^{2}+z\]  
_Consider the zero code combination \(D(z)=(0,\ 0,\ 0,\ 0,\ 0)=0\). Let \(i=2\); then, we obtain the following code combinations:_  
\[\left[\frac{D_{iR}(z)}{P_{i}(z)}\right]\
eq\left[\frac{D_{iV}(z)}{P_{i}(z)}\right] \tag{24}\]0  
\[\left[\frac{D_{iR}(z)}{P_{i}(z)}\right]\
eq\left[\frac{D_{iV}(z)}{P_{i}(z)}\right] \tag{24}\]1  
\[\left[\frac{D_{iR}(z)}{P_{i}(z)}\right]\
eq\left[\frac{D_{iV}(z)}{P_{i}(z)}\right] \tag{24}\]2  
\[\left[\frac{D_{iR}(z)}{P_{i}(z)}\right]\
eq\left[\frac{D_{iV}(z)}{P_{i}(z)}\right] \tag{24}\]3  
_Then, we have \(\left[\frac{D_{2,0}(z)}{P_{2}(z)}\right]=0,\ \ \ \left[\frac{D_{2,1}(z)}{P_{2}(z)}\right]=z,\ \ \ \left[\frac{D_{2,z}(z)}{P_{2}(z)}\right]=z+1,\ \ \ \left[\frac{D_{2,z+1}(z)}{P_{2}(z)}\right]=1.\)_  
_It can be concluded based on the analysis of the application of Theorems 1 and 2 for other bases of the code that if the degree of polynomials D(z) presented as code combinations of PRNS does not exceed deg \(P_{i}(z)\), then \(\left[\frac{D(z)}{P_{i}(z)}\right]=0\).