# An Improved Low-Density Parity-Check Decoder and Its Field-Programmable Fate Array Implementation
## 2 LDPC Code Structure and Decoding Algorithm
### LDPC Decoding Algorithm
Its main improvement involves selecting the  
Figure 1: Tanner graph corresponding to Matrix H.  
minimum values from the variable nodes to replace the hyperbolic tangent operations in the check nodes. Thus, Formula (5) is modified to Formula (8):  
\[L(c_{ji})=\prod_{\vec{r}\in M(j)\smallsetminus i}\text{sgn}(L^{(l-1)}(v_{\vec{r}j}) )\times\text{min}_{\vec{r}\in M(j)\smallsetminus i}(|L^{(l-1)}(v_{\vec{r}j})|) \tag{8}\]  
The following is a brief description of the decoding steps for the NMS algorithm:  
Compared to earlier decoding algorithms, the Min-Sum decoding algorithm significantly reduces computational complexity, but it also considerably impacts performance. Consequently, the Normalized Min-Sum (NMS) decoding algorithm was introduced, which incorporates a normalization correction factor into Formula (8). This modification transforms Formula (8) into Formula (10), effectively mitigating the performance degradation incurred by simplifying the LLRBP algorithm to the MS algorithm. Initialization: Set the maximum number of iterations as \(l_{\text{max}}\) and the current iteration count as \(l=0\). Initialize the channel information as the variable node information. \[L^{(0)}(v_{ij})=L(Q_{i})=x \tag{9}\]  
C--Check Node Update: Update the variable node information to the check node information row-wise according to the Formula (10). \[L^{(l)}(c_{ji})=\prod_{\vec{r}\in M(j)\smallsetminus i}\text{sgn}(L^{(l-1)}(v_{ \vec{r}j}))\times\text{min}_{\vec{r}\in M(j)\smallsetminus i}(|L^{(l-1)}(v_{ \vec{r}j})|)\times\alpha \tag{10}\]  
Var--Variable Node Update: Update the check node information to the variable node information column-wise according to Formula (11). \[L^{(l)}(v_{ij})=L(Q_{i})+\sum_{\vec{r}\in N(i)/j}L^{(l)}(c_{\vec{r}i}) \tag{11}\]  
Pos--Posterior Probability Calculation and Decision: Calculate the posterior probability for each variable node and make a decision. \[L(Q_{i})=\log(\frac{\Pr(x_{i}=1\mid y_{i})}{\Pr(x_{i}=-1\mid y_{i})})=\log( \frac{1+e^{2y_{i}/\sigma^{2}}}{1+e^{-2y_{i}/\sigma^{2}}})=2y_{i}/\sigma^{2} \tag{4}\]0  
Dec--Decoding Check:  
If condition \(L^{(l)}(q_{i})>0\) is met, choose option \(\hat{x}_{i}=0\). Otherwise, choose option \(\hat{x}_{i}=1\). Check whether \([\hat{x}_{1},\hat{x}_{2},\hat{x}_{3},\cdots,\hat{x}_{n}]*\mathbf{H}^{\text{T} }=0\) is satisfied. If so, decoding is successful and the decoded output is provided. Otherwise, perform action \(l=l+1\) and return to step 1 until the maximum iteration count \(l_{\text{max}}\) is reached, then finish decoding. The meanings of the symbols used in the formulas are shown in the Table 1 below: \begin{table}
\begin{tabular}{c c} \hline \hline
**Name** & **Symbol Meanings** \\ \hline \(L(Q_{i})\) & Sequence of information waiting to be decoded \\ \(v_{i}\) & Variable nodes \\ \(c_{i}\) & Check nodes \\ \(L^{(l)}(c_{ij})\) & Edge information passed from variable node \(v_{i}\) to check node \(c_{j}\) at the \(l\)-th iteration \\ \(L^{(l)}(v_{ij})\) & Edge information passed from check node \(c_{j}\) to variable node \(v_{i}\) at the \(l\)-th iteration \\ \(M(j)\) & Set of all variable nodes connected to check node j \\ \(N(i)\) & Set of all check nodes connected to variable node i \\ \(M(j)\backslash i\) & Set of all variable nodes connected to check node j, excluding variable node i \\ \(N(i)\backslash j\) & Set of all check nodes connected to variable node i, excluding check node j \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Symbol meanings.