## 6 Modification of the Reference Points Method Based on the MRC  
As the number of moduli and their dimensionality increase, the method of reference points requires a significant amount of memory.  
First, we introduce a method based on the proposed methods of reference points and modified MRC. Let us take RNS \(\left\{p_{1},\ldots,p_{n-1},p_{n}\right\}\), where \(p_{n}=2^{k}\), i.e., degree 2. Then using the Algorithm 3 we find \(X_{h}\) by the moduli \(\left\{p_{1},\ldots,p_{n-1}\right\}\), and using the method of reference point we compute \(\left|x_{n}-X_{h}\right|_{p_{n}}\). Since \(p_{n}=2^{k}\), this expression can be reduced to taking \(k\) lower bits of the sum \(x_{n}+\bar{X}_{h}+1\), where \(\bar{X}_{h}\) is the bitwise inversion.  
Then, based on this value, a precomputed value equal to \(\left|\left|x_{n}+\bar{X}_{h}+1\right|_{2^{k}}\cdot\left|P_{h}^{-1}\right|_{2 ^{k}}\right|_{2^{k}}\). \(P_{h}\) is selected from the LUT table of size \(2^{k}\), where \(P_{h}=\prod_{i=1}^{n-1}p_{i}\). The final value is obtained by adding \(\left|x_{n}+\bar{X}_{h}+1\right|_{2^{k}}\). In this case, the reverse converter can have a structure, for example, as shown in Figure 3.  
Figure 3: Reverse converter based on reference point and modified MRC.  
Figure 2: Reverse converter based on reference point.  
Consider an example for RNS {3,5,7,8} and the number \(X=115=\) (1,0,3,3). To calculate the Algorithm 3, find the parameters of the RNS {3,5,7}:  
\[P_{h}=3\cdot 5\cdot 7=105,\] \[P_{1}=5\cdot 7=35,\] \[P_{2}=3\cdot 7=21,\] \[P_{3}=3\cdot 5=15,\]  
Let us calculate \(\hat{w}_{j}=\prod_{i=1}^{j-1}p_{i}\):  
\[\hat{w}_{1}=1,\hat{w}_{2}=3,\hat{w}_{3}=3\cdot 5=15.\]  
Let us calculate the representation of \(B_{i}\) in the MRC:  
\[B_{1}\xrightarrow{\text{MRC}}\hat{B}_{1}=\left[b_{1,1},b_{1,2}, \hat{b}_{1,3}\right]=\left[1,3,4\right]\] \[B_{2}\xrightarrow{\text{MRC}}\hat{B}_{2}=\left[\hat{b}_{2,1},b_ {2,2},\hat{b}_{2,3}\right]=\left[0,2,1\right]\] \[B_{3}\xrightarrow{\text{MRC}}\hat{B}_{3}=\left[\hat{b}_{3,1},b_ {3,2},\hat{b}_{3,3}\right]=\left[0,0,1\right].\]  
To calculate \(X_{h}=\) (1,0,3) we then compute \(U_{i}=\sum_{j=1}^{i}x_{j}\cdot\hat{b}_{j,i}\):  
\[U_{1}=x_{1}\cdot\hat{b}_{1,1}=1\cdot 1=1,\] \[U_{2}=x_{1}\cdot\hat{b}_{1,2}+x_{2}\cdot\hat{b}_{2,2}=1\cdot 3+0 \cdot 2=3,\] \[U_{3}=x_{1}\cdot\hat{b}_{1,3}+x_{2}\cdot\hat{b}_{2,3}+x_{3}\cdot \hat{b}_{3,3}=1\cdot 4+0\cdot 1+3\cdot 1=7.\]  
Let us calculate \(\hat{x}_{i}=\left|\sigma_{i-1}+U_{i}\right|_{p_{i}}\) and \(\sigma_{i}=\left\lfloor\frac{\sigma_{i-1}+U_{i}}{p_{i}}\right\rfloor\):  
\[\hat{x}_{1}=\left|U_{1}\right|_{p_{1}}=\left|1\right|_{3}=1, \sigma_{1}=\left\lfloor\frac{U_{1}}{p_{1}}\right\rfloor=\left\lfloor\frac {1}{3}\right\rfloor=0,\] \[\hat{x}_{2}=\left|\sigma_{1}+U_{2}\right|_{p_{2}}=\left|0+3 \right|_{5}=3, \sigma_{2}=\left\lfloor\frac{\sigma_{1}+U_{2}}{p_{2}}\right\rfloor= \left\lfloor\frac{3}{5}\right\rfloor=0,\] \[\hat{x}_{3}=\left|\sigma_{2}+U_{3}\right|_{p_{3}}=\left|0+7 \right|_{7}=0.\]  
From this we obtain:  
\[X_{h}=\sum_{i=1}^{n}\hat{x}_{i}\cdot\hat{w}_{i}=1\cdot 1+3\cdot 3+0\cdot 15=10.\]  
According to the method of reference vectors we find the difference  
\[X_{4}=\left|x_{4}-X_{h}\right|_{p_{4}}=\left|3-10\right|_{8}=1.\]  
In the case of a hardware implementation, to obtain \(X_{4}\), one must add \(x_{4}\) to one and \(k=3\) to the lowest bits of the inverted value of \(X_{h}\), i.e.,  
\[X_{4}=\left|11+\overline{1010}+1\right|_{8}=\left|11+101+1\right|_{8}=\left| 1001\right|_{8}=1.\]Since \(X_{4}=1\), based on the Table 1 we obtain a value of 105 and then the initial value \(X=105+X_{h}=115\).  
Changing the ratio of the number of moduli over which the reconstruction in the modified MRC and the method of reference points, as well as the number of steps in the method of reference points allows you to flexibly adjust the system according to the constraints on the used area and computation time.