# Artificial Neural Network Assisted Error Correction for MLC NAND Flash Memory
## 2 Channel Model
### Relative LLR  
For soft decision belief-propagation (BP) decoding, a soft quantization scheme has been proposed. As an example, Figure 2 shows a 15-level uniform sensing quantization [12].  
The overlap region is obtained by the entropy of the cell's threshold voltage [12,14]. When the threshold voltage falls into the range \((R_{n-1},\ R_{n}]\), where \(R_{n}\) is the \(n\)-th reference voltage, \(R_{0}=-\infty\) and \(R_{16}=+\infty\), the LLR values of the least significant bit (LSB) and the most significant bit (MSB) in the \(i\)-th cell can be calculated by (12) and (13), respectively:  
\[LLR_{lsb}(R_{n-1},\ R_{n})=\log\frac{\int_{R_{n-1}}^{R_{n}}p(V_{th}|11)+p(V_{th }|01)\,\mathrm{d}\,x}{\int_{R_{n-1}}^{R_{n}}p(V_{th}|00)+p(V_{th}|10)\,\mathrm{d }\,x}, \tag{12}\]  
\[LLR_{msb}(R_{n-1},\ R_{n})=\log\frac{\int_{R_{n-1}}^{R_{n}}p(V_{th}|11)+p(V_{th }|10)\,\mathrm{d}\,x}{\int_{R_{n-1}}^{R_{n}}p(V_{th}|01)+p(V_{th}|00)\,\mathrm{d }\,x}. \tag{13}\]  
However, it may be hard to accurately calculate the LLR values due to the retention noise. Even though retention noise is modeled as Gaussian distribution, the mean and the standard deviation are random, since \(\triangle\,V_{t}\) is random as described in (6) and (7). Furthermore, it is difficult to obtain accurate retention time in a practical system. To deal with those problems, we can estimate LLR, based on the relative reference voltage positions, given as  
\[LLR^{\prime}_{lsb}(R_{n-1}-V_{rv}+V^{\prime}_{rv},\ R_{n}-V_{rv}+V^{\prime}_{rv})\] \[=\log\frac{\int_{R_{n-1}-V_{rv}+V^{\prime}_{rv}}^{R_{n}-V_{rv}+V^ {\prime}_{rv}}p^{\prime}(V_{th}|11)+p^{\prime}(V_{th}|01)\,\mathrm{d}\,x}{\int _{R_{n-1}-V_{rv}+V^{\prime}_{rv}}^{R_{n}-V_{rv}+V^{\prime}_{rv}}p^{\prime}(V_ {th}|00)+p^{\prime}(V_{th}|10)\,\mathrm{d}\,x}, \tag{14}\]  
\[LLR^{\prime}_{msb}(R_{n-1}-V_{rv}+V^{\prime}_{rv},\ R_{n}-V_{rv}+V^{\prime}_{ rv})\] \[=\log\frac{\int_{R_{n-1}-V_{rv}+V^{\prime}_{rv}}^{R_{n}-V_{rv}+V^ {\prime}_{rv}}p^{\prime}(V_{th}|11)+p^{\prime}(V_{th}|10)\,\mathrm{d}\,x}{\int _{R_{n-1}-V_{rv}+V^{\prime}_{rv}}^{R_{n}-V_{rv}+V^{\prime}_{rv}}p^{\prime}(V_ {th}|01)+p^{\prime}(V_{th}|00)\,\mathrm{d}\,x}, \tag{15}\]  
where \(p^{\prime}\) means that we estimate \(\triangle\,V_{t}\) in Equations (6) and (7) as \(\triangle\,V_{t}\approx\mu_{k}-\mu_{e}\), \(V_{rv}\) and \(V^{\prime}_{rv}\), are the reference voltages of the actual threshold distribution and the theoretical threshold distribution, respectively, as shown in Figure 3, where \(V_{rv}\) is obtained by voltage optimization [1] and \(V^{\prime}_{rv}\) is obtained by theoretical calculations, such as minimizing entropy of the cell's threshold voltage [12,14]. In (14) and (15), we first calculate the LLR of the theoretical threshold distribution using a quantization scheme. Then, the corresponding LLR of the actual threshold distribution is mapped according to the relative position of the optimal reference voltage.  
We depict the relative LLR versus data retention time in Figure 4. The relative LLR values remain relatively steady, which allows the neural network to not require retention time as an input parameter. In addition, LLR calculation is offline in a flash memory controller [15]. It may be difficult for a controller to estimate the characteristics of the memory channel because online estimation leads to a significant increase in the power consumption and read latency of the flash controller. Therefore, the proposed relative LLR can estimate the actual LLR over a time range, which can also help reduce the number of LLR tables stored in the controller.