An Efﬁcient Method to Construct Parity-Check Matrices for Recursively Encoding Spatially Coupled LDPC Codes †

: Spatially coupled low-density parity-check (LDPC) codes have attracted considerable attention due to their promising performance. Recursive encoding of the codes with low delay and low complexity has been proposed in the literature but with constraints or restrictions. In this manuscript we propose an efﬁcient method to construct parity-check matrices for recursively encoding spatially coupled LDPC codes with arbitrarily chosen node degrees. A general principle is proposed, which provides feasible and practical guidance for the construction of parity-check matrices. According to the speciﬁc structure of the matrix, each parity bit at a coupling position is jointly determined by the information bits at the current position and the encoded bits at former positions. Performance analysis in terms of design rate and density evolution has been presented. It can be observed that, in addition to the feature of recursive encoding, selected code structures constructed by the newly proposed method may lead to better belief-propagation thresholds than the conventional structures. Finite-length simulation results are provided as well, which verify the theoretical analysis.

To realize the promising performance in practice, the implementation of spatially coupled LDPC codes is worth investigation.The best known implementation of spatially coupled LDPC codes is the one introduced in [6].Based on the particular structure of the parity-check matrix, a recursive Entropy 2016, 18, 305 2 of 14 encoder using a shift-register was proposed.The encoder requires only a small number of memory units and the computational cost per bit is proportional to the check node degree.This is a clear advantage compared with the encoding of LDPC block code regarding storage requirements and computational costs.Combined with the pipeline decoding or the sliding-window decoding [6,23], spatially coupled LDPC codes provide a low-delay and low-complexity realization of channel coding with capacity-approaching performance.
The structure in [6] is suitable for recursive encoding; however, several constraints need to be satisfied when constructing the parity-check matrix.Alternatively, Sridharan et al. [8] proposed a simpler way to generate the parity-check matrix using randomly permuted identity matrices on condition that the check node degree d c and the variable node degree d v are not relatively prime.If we further require that the ratio of d c and d v is an integer, then the structure in [8] enables recursive encoding.These constraints and requirements limit the practical application of the codes.To extend the construction to the codes with arbitrary rates, we propose in this paper an efficient method to construct the parity-check matrices with permuted identity matrices regardless of the choice of d c and d v .By rearranging the edge connections, each parity bit at a coupling position is jointly determined by the information bits at the current position and the encoded bits at former positions [24].A generalized principle is proposed, which provides feasible and practical guidance for constructing the recursive structures.The requirement of memory units and the computational complexity retain similar to the recursive encoder in [6].Performance analysis in terms of design rate and density evolution is provided.It can be observed that, with properly designed pattern, the modified code structure may converge faster in the belief-propagation (BP) decoding than the existing structure [8].Consequently, the corresponding spatially coupled LDPC ensemble is able to provide better BP thresholds and smaller gaps to the Shannon limits.Bit erasure rate (BER) performance with finite code lengths is provided as well, which verifies the analysis of the BP thresholds.
In this manuscript we restrict ourselves only to the convolutional-like LDPC codes with nearly regular structures.More advanced spatially coupled protograph codes [25] have been proposed with better decoding thresholds, minimum distances and finite-length trade-offs [26], such as spatially coupled repeat-accumulate (RA) codes [27], spatially coupled accumulate-jagged-accumulate (ARJA) codes [28] and spatially coupled MacKay-Neal (MN) codes [29].The easy encoding of these codes is definitely worth investigations, and we will look into it in the future work.
The remainder of the paper is organized as follows.An overview of spatially coupled LDPC codes and the recursive encoding proposed in [6,8] are given in Section 2. In Section 3, we propose a principle on constructing the parity-check matrices of spatially coupled LDPC codes and illustrate the recursive encoding using a shift-register.Performance analysis based on design rate and density evolution is provided in Section 4. Section 5 presents the finite-length performance evaluation in the binary erasure channel (BEC).Section 6 concludes the paper.

Overview of Spatially Coupled LDPC Codes
Spatially coupled LDPC codes are constructed by coupling together a series of disjoint LDPC block codes into a single coupled chain.As shown in Figure 1, the left unit is the protograph of a LDPC code, and the structure on the right represents the protograph of the corresponding spatially coupled LDPC code.The spatially coupled LDPC ensemble is obtained by duplication and edge rearrangement from the LDPC ensemble.
A (d v , d c ) spatially coupled LDPC code with coupling chain L can also be defined using the parity-check matrix H T [0,L−1] as follows: Entropy 2016, 18, 305 3 of 14 where each submatrix M T l (l + m) is a c × (c − b) binary matrix.The parameter c corresponds to the number of variable nodes at each position, and (c − b) is the corresponding number of check nodes.In the notation, l, 0 ≤ l < L, denotes the position in the chain, and m, 0 ≤ m ≤ m s , indicates the position of edge connections.The parameter m s is called the syndrome former memory, and (m s + 1)c is regarded as the constraint length of the code.codes and the recursive encoding proposed in [6,8] are given in Section 2. In Section 3, we propose a principle on constructing the parity-check matrices of spatially coupled LDPC codes and illustrate the recursive encoding using a shift-register.Performance analysis based on design rate and density evolution is provided in Section 4. Section 5 presents the finite-length performance evaluation in the binary erasure channel (BEC).Section 6 concludes the paper.

Overview of Spatially Coupled LDPC Codes
Spatially coupled LDPC codes are constructed by coupling together a series of disjoint LDPC block codes into a single coupled chain.As shown in Figure 1, the left unit is the protograph of a LDPC code, and the structure on the right represents the protograph of the corresponding spatially coupled LDPC code.The spatially coupled LDPC ensemble is obtained by duplication and edge rearrangement from the LDPC ensemble.Once the node degrees (d v , d c ) have been given, the parity-check matrix H T [0,L−1] needs to satisfy the following constraints: 1.The number of ones in each row is d v .
2. The number of ones in each column is d c , except the beginning and the terminating ends of the chain.3. M T l (l + m) = 0, for m < 0 and m > m s ,∀l. 4.There exists l such that M T l (l + m s ) = 0. 5. M T l (l) = 0 has full rank ∀l .
To implement the systematic and recursive encoding according to [6], M T l (l + m) must additionally satisfy: Note that, in this paper we assume that the encoder is systematic, i.e., the information bits is part of the codeword.We define the recursive encoding as that each parity bit to be encoded can be obtained through the module-2 addition of the known information bits and parity bits.Once a parity bit is determined, it will be utilized in the forthcoming calculation of other unknown parity bits.
It usually takes some efforts to simultaneously satisfy all the above constraints.Instead, if using the structure illustrated in [8], a syndrome matrix meeting all the requirements can be constructed simply.
We now describe the structure proposed in [8].According to [8], the submatrix M T l (l + m) is constructed as where P i,j (l + m) is an M × M random permutation matrix in the i-th row and the j-th column of The recursive encoding of spatially coupled LDPC code for the case that d c /d v is an integer is discussed in the following.The protograph of the (3, 6, L) spatially coupled LDPC ensemble has been provided in Figure 1, where the gray circles correspond to information bits and the white circles associate with parity bits.As shown in the protograph, the parity bits v l,1 in each position l are determined according to the information bits v l,0 and the related bits v l ,0 , v l ,1 , 0 ≤ l < l, from the previous positions.In this way, a recursive encoder is implemented.
However, it is disappointing that for the case d c /d v is not an integer, we cannot perform recursive encoding as above.Let us consider the case d v = 4 and d c = 6.The protograph of the LDPC block code, which acts as the smallest coupling unit, is given on the left of Figure 2. The protograph of a (d v , d c , L) = (4, 6, L) spatially coupled LDPC ensemble constructed according to [8] is provided in Figure 2a.The notations are the same as in Figure 1.The protograph consists of d c = 3 variable nodes and d v = 2 check nodes at each position.The variable node degree equals d v , and the check node degree is d c .At each position l in Figure 2a, v l,0 denotes the information bits while v l,1 and v l,2 represent the parity bits, for 0 ≤ l < L. It can be seen that the parity bits v l,1 (and v l,2 ) can not be calculated only depending on v l,0 and the encoded bits at former positions, as the two variable nodes associated with v l,1 and v l,2 connect to the same check node.Therefore, recursive encoding cannot be applied for this case.Fortunately, the problem may have a solution using a modified protograph structure as illustrated in Figure 2b.Similarly, v l,0 represents the information bits, and v l,1 , v l,2 are the parity bits, at each position l.The edge connection on the variable node associated with v l,2 is rearranged.It avoids connecting to both the check nodes at the current position but connects to a check node one position away.By doing this, each check node connects with only one unknown variable nodes and d c − 1 known variable nodes.The parity bit v l,1 can be calculated depending on v l,0 and the encoded bits at former positions.Afterwards, v l,2 can be obtained in turn through v l,0 , v l,1 and the encoded bits at former positions.After the modification, all the parity bits at the current position can be calculated depending on the information bits and the previously encoded parity bits.The recursive encoding is realized through a structure modification.
The recursive encoding significantly reduces the delay and the complexity compared to the encoding of LDPC block codes, and it promotes the application of spatially coupled LDPC codes in practice.Therefore, it is important to find an efficient and effective method to implement the recursive encoding for arbitrarily chosen node degrees.In the next section, we propose a simple but generalized principle for constructing the parity-check matrix and implement the recursive encoding for the proposed structures.

Recursive Encoding of Spatially Coupled LDPC Codes with Arbitrary Node Degrees
In the following we first propose a general method which guides the construction of the parity-check matrix for recursive encoding.Afterwards, the details of the encoding procedure is provided.

General Principle on Constructing Parity-Check Matrices
Instead of using the d c × d v structure as the smallest coupling unit, we redefine a structure consisting of d c × d v permuted identity matrices as: . . . where i,j (l) is an M × M random permutation matrix in the i-th row and the j-th column of B T l , and n (0 ≤ n < d v ) represents that P (n) i,j (l) is the n-th non-zero permutation matrix in the i-th row.By varying the offsets between adjacent rows, different types of coupling units are obtained.We define a pattern a = (a 0 , to represent the coupling unit H T l after row offsetting as: i,j+2 (l) The element a i = 1 means that the beginning of the non-zero matrices in the i-th row shifts by one column compared to that in the (i − 1)-th row, while a i = 0 indicates that the non-zero matrices in the i-th row are aligned with those in the (i − 1)-th row, for 0 < l < d c .Note that a 0 = 1 means that the beginning of the first row in H T l shifts by one column compared to the last row of H T l−1 .Figure 3 illustrates how to obtain H T l from B T l according to pattern a, and then how to assemble H T [0,L−1] accordingly.
In the following we propose a theorem which selects all the parity-check matrix structures suitable for recursive encoding.
Theorem 1.For a coupling unit represented by a = (a 0 , the spatially coupled LDPC ensemble {d v , d c , L} constructed by coupling the unit of pattern a allows recursive encoding.We then prove why recursive encoding can be applied with this structure.We have assumed that the coupling unit has d c variable nodes and d v check nodes.We use C(l, k) to denote the k-th check node in the l-th coupling unit in the chain, 0 ≤ k < d v .In each coupling unit, the number of variable nodes associated with the parity bits equals d v , and the number of variable nodes corresponding to information bits is d c − d v .For convenience, we name the variable nodes associated with the parity bits as parity nodes, and we denote the k-th parity node in the l-th coupling unit as P(l, k).The nodes related to the information bits are denoted as I(l, j), 0 ≤ j < d c − d v .
To guarantee recursive encoding, we set the following conditions on the edge connections from the check node C(l, k): (i) there is one and only one edge connecting the check node C(l, k) and the parity node P(l, k); (ii) the remaining (d c − 1) edges are only allowed to connect with the nodes in the set {P(l , k ) : A protograph which illustrates the above connections for d v = 4 and d c = 6 is given in Figure 4. Without the loss of generality, we assume the information bits are associated with the first two variable nodes in each coupling unit. ...

C(l,0) C(l,1) C(l,2) C(l,3)
I(l,0) I(l,1) P(l,0) P(l,1) P(l,2) P(l,3) ... In the following we describe the above conditions in form of parity-check matrix.Each coupling unit is described by a d c × d v structure of permutation matrices.Without disarranging the edge connections, we change the order of rows so that the first d v rows relate to parity nodes P(l, k), 0 ≤ k < d v .The indexes of the columns represent the check nodes C(l, k).According to the condition (i), the permutation matrix at the k-th row and the k-th column for 0 ≤ k < d v is non-zero.Meanwhile, based on the condition (ii), the permutation matrix at the k-th row and the k -th column, k > k , 0 ≤ k, k < d v , must be a zero-matrix.We have defined that the element a i = 1 means that the beginning of the non-zero permutation matrices in the i-th shifts by one column compared to that in the (i − 1)-th row.According to the conditions, there is obviously a number of d v 1s in the pattern a.
As a 0 = 1, the above theorem selects a number of ( d c −1 d v −1 ) structures which allow recursive encoding.However, some different structures may actually lead to the same edge connections in the chain.In order to screen out the structures which have truly different edge connections, we take into account the following restriction.The submatrices indexed by a a and a b are considered to result in different edge connections in the coupling chain only if they satisfy: where (a a ) N indicates a sequence obtained by circular shifting the elements in a a for N times, Once the pattern a is obtained, the positions for the information bits are determined.If a i = 0, 0 < i < d v , the (i − 1)-th variable node is designated for one information bit.The structures selected by ( 3) and (4) for recursive encoding spatially coupled LDPC ensembles with d v = 4 and d c = 6 are a a = (1, 0, 0, 1, 1, 1), a b = (1, 0, 0, 1, 1, 1), and a c = (1, 0, 1, 1, 1, 0).The corresponding matrix structures are illustrated in Figure 5.The various structures lead to different performance which will be discussed later.The spatially coupled LDPC codes need to be initialized and terminated properly for finite L. In order to ensure that the spatially coupled LDPC codes with the modified structures exhibit good performance, we try to maintain the degree of variable nodes for all the positions on the coupling chain but reduce the degree of check nodes at the boundary positions.
Take Figure 2b as an example.If we keep all the variable node degree to be d v , there appears an additional check node at the end of the chain compared to Figure 2a.This check node will slightly reduce the design rate of the ensemble.On the other hand, if we remove this check node, the design rate will be the same as that of Figure 2a.For this case, the last variable node has a reduced degree d v − 1.In this manuscript, we always choose to keep the variable node degree d v on all the positions.
The same as in [6], the state of the register is non-zero after encoding.A solution to this problem has been proposed in [6], but it has to solve a system of linear equation which is complex.To solve the problem more efficiently, we adopt the efficient termination proposed in [9].

Implementation of Recursive Encoding
In this section, we introduce the implementation of recursive encoding based on the modified structure of spatially coupled LDPC codes as above.
To illustrate the recursive encoding, we first define the following notations.The subsequence of information bits at position l is defined as is the parity-bit vector for 0 ≤ l < L. We have the entire code sequence as v We divide ( 5) into several sub-equations, and the l-th sub-equation is written as v l H T l = p l = [s l , q l ], 0 ≤ l < L. The vector p l = [s l , q l ] is the partial syndrome from the l-th sub-equation, where From the structure of H T l , for 1 ≤ l < L, we have ) is an identity matrix, then the parity bits can be calculated simply with the encoded bits obtained earlier.For 0 ≤ l < L, the i-th (0 ≤ i < d c ) encoded bit v l,i is determined depending on the information bits, the encoded parity bits and the partial syndrome as where u l,g and c l,k correspond to the coming information bits and the parity bits to be encoded, respectively.The indexes g, k and j are determined by the realization of H T l .For l = 0, s 0 = 0, the encoder is initialized by and the encoded bits are Entropy 2016, 18, 305 9 of 14 According to ( 6) and ( 7), we can implement the recursive encoder of spatially coupled LDPC codes using shift-registers as in [6].The encoder needs a number of (d v − 1)M storage units, and the encoding complexity per bit is proportional to d c .

Theoretical Analysis
In this section, the design rate of the terminated spatially coupled LDPC ensemble with the modified structure is calculated.In addition, analysis based on density evolution is provided.For a fair comparison with [8], in the following we assume an idealized termination where the state of the shift-register comes back to zero.For the ease of presentation, we refer to the structure in [8] as the original structure in the rest of the paper.

Design Rate
To get the design rate of a (d v , d c , L) spatially coupled LDPC ensemble, we calculate the total number of information bits and parity bits separately.Since there are M nodes for each position, the total number of variable nodes equals d c LM, and the total number of check nodes is (d v L + d v − 1)M.Hence, the design rate of the spatially coupled LDPC code is As we pointed out earlier, this rate is slightly lower than that of the original ensemble when gcd , the modified ensemble is equivalent to the original structure, and the design rate is the same for both.For a large L, the rate reduction is negligible.When L tends to infinity, the design rate converges to 1 − d v /d c .

Density Evolution
In the following we derive the density evolution of the proposed code structures.For comparison, we plot the remaining erasure probabilities after iterations for both the original spatially coupled structure and the newly proposed structures.
There are d c variable nodes and d v check nodes at each position.Due to the variety of edge connections, we track the message passing on each individual node instead of each position.We use T (k, n) to denote the set of indices ( f , g) of the check nodes connected with variable node (k, n) and J ( f , g) to represent the set of indices (k, n) of the variable nodes related to check node ( f , g).The check node ( f , g) is the g-th check node at position f , and variable node (k, n) is the n-th variable node at position k.
In the t-th iteration of the decoding, we use x n,g k, f (t) to denote the probability that the message from variable node (k, n) to check node ( f , g) is an erasure, while the probability that the message from check node ( f , g) to variable node (k, n) corresponds to an erasure is represented by y g,n f ,k (t).As the variable node (k, n) connects with the check nodes indexed by T (k, n), x n,g k, f (t) can be updated as Similarly, for check node ( f , g), we get Entropy 2016, 18, 305 10 of 14 In Figure 6, the density evolution for (d v , d c , L) = (4, 6, 50) spatially coupled LDPC ensemble with iteration numbers n = {1, 101, 201, 301, ..., 901} is given for the binary erasure channel with erasure probability ε = 0.646.Figure 6a refers to the original spatially coupled LDPC ensemble in [8], while Figure 6b-d correspond to the spatially coupled LDPC ensembles modified for recursive encoding.The horizontal axis is the index of the variable nodes in the protograph, where every adjacent d c variable nodes belong to the same position.The vertical axis presents the remaining erasure probability.The curves of density evolution reflect the irregularity of check node degree at the boundary positions.In the initialization, the degree of the left four check nodes is respectively {3, 3, 6, 6}, {2, 3, 5, 6}, {3, 4, 5, 6}, and {2, 3, 4, 6} for (a) to (d).In general, lower check node degree leads to better decoding performance, which is verified in Figure 6.We can see that (b) and (d) show an advantage over (a) and (c) on the left boundary of the protograph.Similar superiority is observed for (b) and (c) on the right boundary due to their smaller check node degree.
For the original spatially coupled LDPC ensemble, all the variable nodes at the same position has the same coupling behavior.Therefore, (a) exhibits a stair for every d c variable nodes.In the protograph of the modified structures, even for the same position, the edge connection may be different from one variable node to another.Consequently, the curves of remaining erasure probability in (b), (c), and (d) are smoother than that in (a).Meanwhile, the manner of edge connection clearly affects the convergence behavior in iterative decoding.For the erasure probability we chose, the codes are in the water-fall region.We can see from the distance between neighboring curves, (b) converges the fastest among all the ensembles, and (c) performs the worst.
The BP decoding performance of spatially coupled LDPC ensembles is jointly determined by the boundary effect and the manner of edge connections.Combining the above observations, we expect that the ensemble associated with Figure 6b outperforms the others regarding the decoding threshold.The BP thresholds will be given in the next section.
On top of BP threshold, the performance of a spatially coupled LDPC code can be analyzed through the distance property of the ensemble.For example, the minimum distance growth rate of a spatially coupled LDPC ensemble can be studied via ensemble weight enumerator [30], and the smallest stopping/trapping set size growth can be studied via stopping/trapping set enumerator [31].This manuscript mainly discuss the implementation aspects of the recursive encoding after modifying the structure, and a comprehensive performance analysis based on the distance property will be addressed in the future work.

Simulation Results and Discussions
In this section, we evaluate the performance of the proposed structures in the binary erasure channel numerically.We compare the BP thresholds of the spatially coupled LDPC codes after the modifications with the BP thresholds of the corresponding original structures in [8].In addition, the bit erasure rates for different structures are provided.
We first provide the comparison of BP thresholds among different realizations of the modification.We choose the parameters d v = 4, d c = 6 and L = 50 and carry out the density evolution for all the structures shown in Figure 5.The BP thresholds of the modified spatially coupled LDPC ensembles and the original implementation in [8] over the BEC are shown in Table 1, which are represented by ε BP .Besides, ε Sh denotes the Shannon limit corresponding to different design rate.As predicted in Section 4.2, the ensemble with the pattern (101101) performs the best among all the structures.The gap between the Shannon limit and the BP threshold is smaller than that of the original structure.The structure modification does not necessarily result in better BP threshold.However, a properly designed pattern can enable both easy encoding and better threshold.Based on the observations in Table 1, we realize the modifications with properly selected patterns for different d v and d c and provide the BP thresholds in Table 2.The selected patterns are listed in the table, and the coupling length is L = 50.The gaps between the BP thresholds and the Shannon limits for the modified spatially coupled LDPC ensembles and for the original ensembles in [8] are represented by Gap and Gap, respectively.Comparing Gap with Gap, we can find that all the gaps are narrowed after proper modifications.For the modified structures, all the gaps are very small and can be further narrowed if we increase the parameters.Properly modified spatially coupled LDPC ensembles are able to provide capacity-approaching performance over the BEC.A similar conclusion can be extended to the general binary memoryless symmetric channel.Bit erasure rates for the modified spatially coupled LDPC codes and the original code over BECs are provided in Figure 7. Here, we set M = 500 and L = 50, and we use the selected patterns as in Table 2.We also include the corresponding BP thresholds as the dashed lines and the Shannon limits as the dotted lines.Comparing the BER curves, we can find that the spatially coupled LDPC codes with properly modified structures clearly outperforms the original spatially coupled LDPC code in [8].Note that, in addition to the good decoding performance, the proposed structure allows recursive encoding which facilitates the application of spatially coupled LDPC codes in practice.Bit erasure rates of spatially coupled LDPC codes over binary erasure channels.In the legend, "MSCLDPC" represents the modified code while "SCLDPC" stands for the original code.

Conclusions
In this manuscript, structure modification for the spatially coupled LDPC code has been proposed, which enables the recursive encoding using a shift-register for arbitrary node degrees.The proposed principle provides feasible and practical guidance for the code construction and significantly reduces the computational complexity and memory requirement for the encoding.Performance analysis in terms of design rate and density evolution has been provided.The belief-prorogation decoding threshold is improved if proper edge rearrangement is applied in the modified spatially coupled LDPC ensemble.Finite-length simulation results are provided, which verify the theoretical analysis.

Figure 1 .
Figure 1.Protograph of a (3, 6, L) spatially coupled LDPC ensemble.The rectangles represent check nodes while the circles denote variable nodes.The gray circles correspond to information bits while the white circles associate with parity bits.

Figure 1 .
Figure 1.Protograph of a (3, 6, L) spatially coupled low-density parity-check (LDPC) ensemble.The rectangles represent check nodes while the circles denote variable nodes.The gray circles correspond to information bits while the white circles associate with parity bits.

6 .
The last c − b rows of M T l (l) is a (c − b) × (c − b) identity matrix.
the greatest common divisor of d v and d c , then there exist positive integers d v = d v /m b , d c = d c /m b , and gcd(d v , d c ) = 1.In this case, we have c = d c M, b = (d c − d v )M, and the syndrome former memory m s = m b − 1.The satisfaction of constraints 1-5 is obvious.When d c /d v is an integer, M T l (l + m) turns out to be a d c × 1 matrix.The constraint 6 is easy to access by setting P d c −1,0 (l + m) as an identity matrix.

Figure 3 .
Figure 3.The construction of the parity-check matrix for the (4, 6, L) spatially coupled LDPC ensemble.

Figure 4 .
Figure 4.The connections for(4,6) spatially coupled LDPC codes assuming the information bits are associated with the first two variable nodes.

Figure 7 .
Figure 7.Bit erasure rates of spatially coupled LDPC codes over binary erasure channels.In the legend, "MSCLDPC" represents the modified code while "SCLDPC" stands for the original code.

Table 2 .
BP thresholds of modified spatially coupled LDPC ensembles with different node degrees.