A decoding method, apparatus, device and medium of an error correction code

By deriving the target relation and determining the conjugate position pairs using Vieta's theorem, and combining the index and polynomial comparison table of Galois fields, the problem of high computational cost in BCH code decoding is solved using the XOR operation, thus improving decoding efficiency.

CN116015315BActive Publication Date: 2025-11-25BEIJING TONGFANG MICROELECTRONICS
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211738080.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-12-30
Publication Date
2025-11-25
Estimated Expiration
2042-12-30

AI Technical Summary

Technical Problem

The decoding process of existing BCH codes is computationally intensive and highly complex, especially when solving the roots of the Galois field quadratic equation, which requires traversing all possible values, resulting in excessive computation.

Method used

The target relation is derived using Vieta's formulas, the conjugate position pairs corresponding to the error positions are determined based on the Galois domain equation, the error positions are determined by the comparison table of exponents and polynomials, and the XOR operation is used to reduce the amount of computation.

Benefits of technology

This reduces the computational complexity of the decoding process, decreases the number of traversals of the Galois field equations, and improves decoding efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116015315B_ABST
    Figure CN116015315B_ABST
Patent Text Reader

Abstract

The application discloses a decoding method and device of an error correction code, an apparatus, and a medium, comprising: acquiring a Galois field equation corresponding to the error correction code, and determining a target relationship corresponding to an error position after decoding. Based on the target relationship, a plurality of conjugate position pairs are determined, and for any conjugate position pair, based on an index and a polynomial control table, a first polynomial corresponding to the index coefficient of a first position in the conjugate position pair and a second polynomial corresponding to the index coefficient of a second position are determined. The coefficients of the first polynomial and the second polynomial are XORed to obtain an XOR result. When the XOR result matches the target coefficient of the Galois field equation, the first position and the second position are determined as the error position. Based on the application of the Galois field equation and the Wedderburn theorem, the error position can be determined based on the index and the polynomial control table, without traversing all possible values to substitute into the Galois field equation, so as to reduce the calculation amount in the decoding process and reduce the complexity.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and in particular to a decoding method, apparatus, device and medium for error correction codes. Background Technology

[0002] BCH codes are linear block codes in a finite field (Galois field) that can correct multiple random errors and are commonly used for error correction coding in communication and storage. BCH codes divide a sequence of information to be transmitted into message groups of fixed bits, and then independently transform each message group into a group of binary numbers, thus obtaining the block code. The process of transforming message groups into codewords is called encoding, and the reverse process is called decoding.

[0003] For example, in flash storage scenarios, BCH error-correcting codes with an error-correcting capability of 2 are primarily used to achieve error correction. This means that decoding the error-correcting code provides information about the two error locations in the flash storage. The core step in decoding is calculating the roots of the quadratic equation in the Galois field corresponding to the BCH code. The current method involves iterating through all possible values ​​in the Galois field and substituting each value into the quadratic equation to determine if the result is zero. This results in a large computational load for finding the roots, making the decoding process quite complex. Summary of the Invention

[0004] In view of this, this application provides a decoding method, apparatus, device and medium for error-correcting codes to reduce the amount of computation and complexity in the decoding process.

[0005] Firstly, this application provides a decoding method for error-correcting codes, the method comprising:

[0006] Obtain the Galois domain equation corresponding to the error correction code, wherein the total length of the error correction code is a preset number of bits;

[0007] Based on the Galois domain equation, the target relational expression corresponding to the error position after decoding the error correction code is determined. The target relational expression is derived based on Vieta's theorem.

[0008] Multiple conjugate position pairs are determined based on the target relation;

[0009] For any of the multiple conjugate position pairs, based on the exponent-polynomial lookup table of the Galois field, determine the first polynomial corresponding to the exponent coefficient of the first position and the second polynomial corresponding to the exponent coefficient of the second position in the conjugate position pair.

[0010] XOR the coefficients of the first polynomial and the coefficients of the second polynomial to obtain the XOR result;

[0011] When the XOR result matches the target coefficient of the Galois domain equation, the first position and the second position are determined to be erroneous positions.

[0012] In one possible implementation, the step of XORing the coefficients of the first polynomial and the coefficients of the second polynomial to obtain the XOR result includes:

[0013] Identify multiple matching pairs in the first and second polynomials where the exponents of the powers are the same;

[0014] For any of the multiple matching pairs, XOR the two coefficients of the matching pair to obtain the XOR result of the multiple matching pairs.

[0015] In one possible implementation, the process of matching the XOR result with the target coefficients of the Galois domain equation includes:

[0016] Obtain the target coefficients of the Galois domain equation, wherein the target coefficients are the coefficients of the first-order terms in the Galois domain equation;

[0017] Based on the index-polynomial comparison table, determine the target polynomial corresponding to the target coefficient;

[0018] The XOR result is matched with the coefficients of the target polynomial.

[0019] In one possible implementation, the derivation process for determining the target relation based on Vieta's formulas includes:

[0020] The first exponent corresponding to the first coefficient of the Galois domain equation is determined based on the generator of the Galois domain equation, where the first coefficient is the coefficient of the highest power term.

[0021] Based on the generator, determine the second exponent corresponding to the first root of the Galois domain equation and the third exponent corresponding to the second root of the Galois domain equation.

[0022] The product relationship between the second exponent and the third exponent is determined based on Vieta's formulas, and the product relationship includes the first exponent;

[0023] The target relation is determined based on the product relation, wherein the first root and the first error position are inversely related, and the second root and the second error position are inversely related.

[0024] In one possible implementation, determining the target relation based on the product relation includes:

[0025] Take the logarithm of both sides of the product expression to determine the summation expression;

[0026] Based on the reciprocal relationship between the first root and the first error position, the reciprocal relationship between the second root and the second error position, and the summation formula, the target formula is determined.

[0027] In one possible implementation, determining multiple conjugate position pairs based on the target relation includes:

[0028] Determine the midpoint position based on the target relation;

[0029] Based on the midpoint position and the value space of the Galois domain equation, the first side position space and the second side position space corresponding to the midpoint position are determined. The first side position space and the second side position space are non-overlapping value spaces, and the first side position space, the second side position space and the midpoint position constitute the value space of the Galois domain equation.

[0030] The first position is determined in the first side position space, and the second position is determined in the second side position space. The first position and the second position are determined to be a conjugate position pair. The distance between the first position and the midpoint position is equal to the distance between the second position and the midpoint position.

[0031] In one possible implementation, the Galois domain equation is a quadratic equation in one variable.

[0032] Secondly, this application provides a decoding apparatus for error-correcting codes, the apparatus comprising:

[0033] The first acquisition unit is used to acquire the Galois domain equation corresponding to the error correction code, wherein the total length of the error correction code is a preset number of bits.

[0034] The first determining unit is used to determine the target relational expression corresponding to the error position after decoding the error correction code based on the Galois domain equation. The target relational expression is derived based on Vieta's theorem.

[0035] The second determining unit is used to determine multiple conjugate position pairs based on the target relation;

[0036] The third determining unit is used to determine, for any one of the multiple conjugate position pairs, the first polynomial corresponding to the exponent coefficient of the first position and the second polynomial corresponding to the exponent coefficient of the second position in the conjugate position pair based on the exponent-polynomial lookup table of the Galois domain.

[0037] The second acquisition unit is used to perform an XOR operation on the coefficients of the first polynomial and the coefficients of the second polynomial to obtain the XOR result.

[0038] The fourth determining unit is used to determine the first position and the second position as erroneous positions when the XOR result matches the target coefficient of the Galois domain equation.

[0039] Thirdly, this application provides a decoding device for error-correcting codes, the device comprising: a memory and a processor;

[0040] The memory is used to store the relevant program code;

[0041] The processor is used to call the program code to execute the decoding method of the error correction code described in any of the implementations of the first aspect above.

[0042] Fourthly, this application provides a computer-readable storage medium for storing a computer program for executing the decoding method of the error-correcting code described in any implementation of the first aspect.

[0043] Therefore, this application has the following beneficial effects:

[0044] In the above implementation of this application, when decoding the error-correcting code, the Galois domain equation corresponding to the error-correcting code can be obtained, wherein the total length of the error-correcting code is a preset number of bits. Based on the Galois domain equation, a target relational expression corresponding to the error position determined after decoding the error-correcting code is determined, wherein this target relational expression can be derived based on Vieta's formulas. Then, based on the target relational expression, multiple conjugate position pairs are determined. For any conjugate position pair among the multiple conjugate position pairs, based on the Galois domain exponent-polynomial lookup table, the first polynomial corresponding to the exponent coefficient of the first position and the second polynomial corresponding to the exponent coefficient of the second position in the conjugate position pair are determined. The coefficients of the first polynomial and the coefficients of the second polynomial are XORed to obtain the XOR result. When the XOR result matches the target coefficient of the Galois domain equation, the first and second positions in the conjugate position pair can be determined as error positions. The decoding method of the error-correcting code provided in this application, based on the application of the Galois field equation and Vieta's formulas, can determine the error location based on the comparison table of exponents and polynomials, without having to traverse all possible values ​​and substitute them into the Galois field equation, which can reduce the amount of computation in the decoding process and reduce complexity. Attached Figure Description

[0045] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments provided in this application. For those skilled in the art, other drawings can be obtained based on these drawings.

[0046] Figure 1A flowchart illustrating a decoding method for error-correcting codes provided in an embodiment of this application;

[0047] Figure 2 A schematic diagram illustrating the working principle of a conjugate XOR module provided in an embodiment of this application;

[0048] Figure 3 A schematic diagram of a decoding device for error-correcting codes provided in an embodiment of this application;

[0049] Figure 4 This is a schematic diagram of a decoding device for error correction codes provided in an embodiment of this application. Detailed Implementation

[0050] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. The described embodiments are merely exemplary implementations of this application and not all implementation methods. Those skilled in the art can obtain other embodiments in conjunction with the embodiments of this application without creative effort, and these embodiments are also within the protection scope of this application.

[0051] To facilitate understanding of the technical solutions provided in the embodiments of this application, the technical background involved in the embodiments of this application will be introduced below.

[0052] A field is an algebraic system that defines two mathematical operations on its elements. A field consists of the set of addition operations on all elements and the set of multiplication operations on all non-zero elements. It exhibits closure property in addition and multiplication, meaning that the result of adding or multiplying elements within a field is still an element within the field. Multiplication and addition within a field can be defined using the AND operation (module-2 addition) and XOR operation in the C programming language, respectively. However, by convention, the symbols "+" and "*" are still used to represent addition and multiplication operations.

[0053] Consider a set of elements G = {0, 1, 2, 3, ..., p-1}, where p is a prime number. Define two mathematical operations: modulo-p addition and module-p multiplication. To satisfy the closure property of multiplication, p must be a prime number, and the set contains p elements. From this, we can deduce that if we restrict the coefficients of a polynomial to elements in a finite field GF(p), and redefine the addition, subtraction, multiplication, and division operations of the polynomial based on the rules of operations in a finite field, then such a set of polynomials is called a polynomial based on a finite field. Extending GF(p) to GF(2^p), p is no longer limited to prime numbers, but still satisfies the idea of ​​the addition and multiplication rules of finite fields: mapping the numerical elements of the finite field to polynomial elements, i.e., the elements of the finite field are 2^p polynomials including 0 and 1. This finite field GF(2^p) is also called a Galois field.

[0054] BCH codes are cyclic codes belonging to the Galois field. Their key feature is on-demand design; that is, the BCH code for a given application scenario is determined based on the number of errors required. Error locations can then be obtained by decoding the BCH code. The main decoding steps include: calculating the adjoint polynomial using the receiver polynomial; using the coefficients of the adjoint polynomial to find the coefficients of the error location polynomial; and finally, determining the error location by solving for the root of the error location polynomial. The reciprocal of this root represents the error location to be determined.

[0055] In flash storage scenarios, BCH error-correcting codes with an error-correcting capability of 2 are primarily used to achieve error correction. This means that decoding the BCH code yields information about two error locations in the flash storage. The core step of the decoding is calculating the roots of the polynomials corresponding to the error locations in the BCH code. Since the error-correcting capability is 2, these roots are the roots of the quadratic equation in the Galois field. Because the elements in the Galois field are essentially polynomials, the current method for solving the equation's roots is the Chien search algorithm. This involves traversing all possible values ​​in the Galois field and substituting them into the quadratic equation to determine if the result is zero. This results in a large computational load for finding the roots, making the decoding process quite complex.

[0056] Based on this, embodiments of this application provide a decoding method for error-correcting codes to reduce the computational load and complexity of the decoding process. Specifically, when decoding the error-correcting code, the Galois field equation corresponding to the error-correcting code can be obtained, wherein the total length of the error-correcting code is a preset number of bits. Based on the Galois field equation, a target relational expression corresponding to the error position determined after decoding the error-correcting code is determined, wherein the target relational expression can be derived based on Vieta's formulas. Then, multiple conjugate position pairs are determined based on the target relational expression. For any conjugate position pair among the multiple conjugate position pairs, based on the exponent-polynomial lookup table of the Galois field, the first polynomial corresponding to the exponent coefficient of the first position and the second polynomial corresponding to the exponent coefficient of the second position in the conjugate position pair are determined. The coefficients of the first polynomial and the coefficients of the second polynomial are XORed to obtain the XOR result. When the XOR result matches the target coefficient of the Galois field equation, the first and second positions in the conjugate position pair can be determined as error positions.

[0057] The decoding method of the error correction code provided in the embodiments of this application will be described in detail below with reference to the accompanying drawings.

[0058] See Figure 1 , Figure 1 A flowchart illustrating a decoding method for error-correcting codes provided in an embodiment of this application.

[0059] The method may include the following steps:

[0060] S101: Obtain the Galois domain equation corresponding to the error correction code.

[0061] When decoding error-correcting codes, the Galois domain equation corresponding to the error location can be determined based on the decoding principle of error-correcting codes. This is the error location polynomial described above. The main steps include: calculating the adjoint polynomial using the received polynomial; obtaining the coefficients of the error location polynomial from the coefficients of the adjoint polynomial; and finally determining the error location by solving for the roots of the error location polynomial. This part can be found in the conventional decoding process of error-correcting codes in existing technologies and can be implemented by the computing module of the decoding device; therefore, it will not be elaborated further here.

[0062] In this embodiment, the focus is on solving the roots of the Galois domain equation using an error-correcting code with an error-correcting capability of 2, i.e., the Galois domain equation is a quadratic equation. For example, the error-correcting code can be a BCH code. The total length of the error-correcting code can be pre-configured according to the actual needs of flash storage, i.e., the total length of the error-correcting code is a preset number of bits. For example, it can be set to 255 bits or 144 bits; this embodiment does not limit this.

[0063] S102: Determine the target relational expression corresponding to the error position after decoding the error correction code based on the Galois domain equation. This target relational expression is derived based on Vieta's theorem.

[0064] For applications with an error correction capability of 2, the Galois equation is a quadratic equation in one variable. In this embodiment, we will only introduce the Galois equation when it has two distinct roots. The Galois equation is also subject to Vieta's formulas, and the roots of the Galois equation and the error locations satisfy a reciprocal relationship. Therefore, the target relation corresponding to the two error locations can be derived based on Vieta's formulas.

[0065] A Galois field contains generators, and all non-zero elements in the Galois field can be expressed as powers of the generators, i.e., exponential forms of the generators. In practice, based on the generators of the Galois field equation, the first exponent corresponding to the first coefficient of the Galois field equation can be determined. That is, the first exponent of the Galois field equation is expressed as an exponential form of the generator. Based on the generators, the second exponent corresponding to the first root of the Galois field equation and the third exponent corresponding to the second root are determined; that is, both roots of the Galois field equation are expressed as exponential forms of the generators, where the power of the generator corresponding to each root can be represented by a variable. Then, the product relationship between the second and third exponents is determined based on Vieta's formulas. That is, the product relationship between the two roots of the Galois field equation can be determined based on Vieta's formulas, since the two roots can be expressed as exponential forms of the generators, thus allowing the determination of the product relationship between the second and third exponents. According to Vieta's formulas, the product of the two roots of an equation can be expressed by the coefficient of the highest power element and the coefficient of the constant term, that is, by the first coefficient and the coefficient of the constant term. Therefore, the product expression includes the first exponent corresponding to the first coefficient. As shown in the above example, the roots of the Galois domain equation are reciprocals of the error positions. Therefore, the target expression corresponding to the two error positions can be determined based on the product expression of the two roots.

[0066] In one possible implementation, after determining the product relationship between the second and third exponents, the logarithm of both sides of the product relationship can be taken to obtain the summation relationship. Then, based on the reciprocal relationship between the first root and the first error position, and the reciprocal relationship between the second root and the second error position, the target relationship between the first and second error positions is determined according to the summation relationship. The principle of deriving the target relationship based on Vieta's formulas will be introduced below with a specific application scenario.

[0067] In one possible implementation, after determining the product relationship between the second and third exponents, the logarithm of both sides of the product relationship can be taken to obtain the summation relationship. Then, based on the reciprocal relationship between the first root and the first error position, and the reciprocal relationship between the second root and the second error position, the target relationship between the first and second error positions is determined according to the summation relationship. The principle of deriving the target relationship based on Vieta's formulas will be introduced below with a specific application scenario.

[0068] In this application scenario, the Galois domain equation can be expressed as: u1x 2 +u2x+1=0(GF(2 n The first coefficient is u1. In this Galois field, the generator is denoted as a. Therefore, the first coefficient u1 can be expressed as the first exponent of a using the generator a, i.e., u1 = a. r1The two roots of the Galois domain equation are represented as the first root x1 and the second root x2. Then, using the generator a, the first root x1 and the second root x2 are represented as the second and third exponents, respectively, i.e., x1 = a. r2 x2 = a r3 Based on Vieta's formulas, the product of the first and second roots can be expressed as x1*x2=u1 -1 Using generators, let a be the representation of the generator. r2+r3 =a -r1 Taking the logarithm of both sides of the product relation yields the summation relation: r1 + r2 + r3 ≡ 0 mod (2 n -1). Let e1 represent the first error position and e2 represent the second error position. Since the first error position e1 and the second error position e2 correspond to the reciprocals of the first root and the second root, according to the summation formula, the target relationship between the first error position e1 and the second error position e2 can be obtained as: e1 + e2 ≡ r3 mod (2 n -1).

[0069] S103: Determine multiple conjugate position pairs based on the target relation.

[0070] After determining the target relationship between the first and second error positions, multiple conjugate position pairs in the flash memory can be determined based on the target relationship and the total length of the error correction code. Each conjugate position pair contains two corresponding positions.

[0071] In practical implementation, the target relation represents the summation relationship between two error positions. The midpoint position can be determined based on this target relation. Based on the midpoint position and the value space of the Galois domain equation, the first and second side position spaces corresponding to the midpoint position are determined. These first and second side position spaces are non-overlapping value spaces, and they together with the midpoint position form the value space of the Galois domain equation. Then, the first position is determined in the first side position space, and the second position is determined in the second side position space, ensuring that the distance between the first position and the midpoint position is equal to the distance between the second position and the midpoint position. The first and second positions are then paired as conjugate position pairs, allowing multiple conjugate position pairs to be determined based on the first and second side position spaces.

[0072] S104: For any conjugate position pair among multiple conjugate position pairs, based on the index-polynomial comparison table of the Galois field, determine the first polynomial corresponding to the exponent coefficient of the first position and the second polynomial corresponding to the exponent coefficient of the second position in the conjugate position pair.

[0073] Each element in the Galois field is essentially a polynomial, where the coefficient of each term is either 0 or 1. Using an exponent-polynomial mapping table, each polynomial can be mapped to an exponential form, corresponding to the exponential form at each position in the flash memory. Therefore, during decoding, the first polynomial corresponding to the exponent coefficient at the first position can be determined using the exponent-polynomial mapping table, and the second polynomial corresponding to the exponent coefficient at the second position can be determined.

[0074] S105: XOR the coefficients of the first polynomial and the coefficients of the second polynomial to obtain the XOR result.

[0075] Then, the coefficients of the first polynomial are XORed with the coefficients of the second polynomial to obtain the XOR result. Optionally, multiple matching pairs with the same exponent in the first and second polynomials can be identified. For any matching pair, the two coefficients of that pair are XORed to obtain the XOR result of the multiple matching pairs. For example, if the coefficients of the first polynomial can be represented as "1 0 0 1 1" and the corresponding coefficients of the second polynomial can be represented as "1 1 0 0 1", then the XOR result is "1 0 1 0 1".

[0076] S106: When the XOR result matches the target coefficient of the Galois domain equation, determine the first and second positions as erroneous positions.

[0077] The XOR result is checked against the target coefficients of the Galois domain equation. If they match, the first and second positions corresponding to the XOR result are identified as incorrect positions. Specifically, when the Galois domain equation is a quadratic equation, the coefficients of the linear terms in the quadratic equation are identified as target coefficients. Then, based on the exponent-polynomial comparison table, the target polynomial corresponding to the target coefficients is determined. The XOR result is then checked against the coefficients of the target polynomial. If they match, the first and second positions for XORing are identified as incorrect positions.

[0078] To facilitate understanding of the decoding method for the error correction code provided in the embodiments of this application, it will be introduced below in conjunction with specific application scenarios.

[0079] In one possible application scenario, the total length of the BCH code can be configured to be 255 bits, corresponding to a finite field of GF(2). 8 That is, the possible value space corresponding to the Galois field equation is [0, 254], the error correction capability is 2, and the corresponding Galois field equation in the decoding process is: a 56 x 2 +a 65 x+1=0(GF(2 8In this context, 'a' is a generator of the Galois field. Based on the target relation derived from Vieta's theorem, the target relation for the first error position e1 and the second error position e2 is: e1 + e2 = 56 mod 255. The midpoint position can then be determined as 56 / 2 = 28. Starting from this midpoint position 28, we sequentially move left and right, taking symmetrical positions of equal distance as conjugate pairs, such as bit27 and bit29, bit26 and bit30, bit25 and bit31, etc. For the conjugate pair bit27 and bit29, we can determine the Galois field polynomial corresponding to the exponent of bit27 and the Galois field polynomial corresponding to bit29 using the exponent-polynomial comparison table. We then XOR the coefficients of the two polynomials to determine the coefficient 'a' of the linear term x. 65 If the corresponding polynomial coefficients are the same, then bit27 and bit29 can be identified as two incorrect positions. This process is repeated for all possible conjugate pairs until a conjugate pair with the same coefficient as the polynomial corresponding to the linear term is identified.

[0080] In one possible application scenario, the total length of the BCH code can be configured to be 144 bits, and the corresponding finite field is GF(2). 8 The error correction capability is 2, and the corresponding Galois domain equation during the decoding process is: a 67 x 2 +a 236 x+1=0(GF(2 8 The possible value space corresponding to the Galois domain equation is [0, 254], where a is the generator of the Galois domain. Based on the target relation derived from Vieta's theorem, the target relation for the first error position e1 and the second error position e2 is: e1 + e2 = 67 mod 255. Then, the midpoint position can be determined as 67 / 2 = 33.5. Starting from 33.5, symmetrical positions at equal distances to the left and right are taken as conjugate position pairs, such as bit33 and bit34, bit32 and bit35, bit31 and bit36, etc. The specific XOR process can be found in the above method implementation examples, and will not be repeated here.

[0081] The decoding method of the error-correcting code provided in this application can reduce the traversal range of error positions by applying the Galois field equation and Vieta's formulas, without having to traverse all possible values, thereby reducing the amount of computation in the decoding process and lowering the complexity.

[0082] In one possible implementation, the XOR operation based on the Galois domain equations can be performed by the conjugate XOR module of the decoding device. See also Figure 2This is a schematic diagram illustrating the working principle of a conjugate XOR module provided in an embodiment of this application. The conjugate XOR model may include a one-to-many data register, a shift register, a comparator, a multiplexer, etc.

[0083] Taking a 255-bit error correction code as an example, when the input parameter n is used, it can be assigned to 256 registers through a multi-data divider register, and then the result n / 2 is generated through a shift register. In this embodiment, the parameter n can correspond to the value on the right side of the target relation. Taking the target relation as e1+e2=56mod255 as an example, then n=56. After simple arithmetic operations, 127 sets of data are generated by adding / subtracting arithmetic values ​​from the value of n / 2, thus obtaining multiple conjugate position pairs. Then, the 127 sets of data are output through the input address to obtain the polynomial value at the corresponding position. The values ​​of the current 127 sets of polynomials are XORed pairwise to generate 127 results. A comparator compares whether any of the 127 results are equal to the polynomial coefficient value of the one-time coefficient, and then the 127 comparison results are sent to a multiplexer to select the correct result that is equal to the polynomial coefficient value of the one-time coefficient. Based on the XOR result corresponding to the multiplexer, the two error positions can be obtained by inputting data and outputting the address.

[0084] Taking a 255-bit error-correcting code as an example, compared to the traditional Qian search algorithm, which requires completing this step within one cycle, a fully parallel exhaustive circuit would need at least 128 paths. Each path includes two conversion table operations to transform from exponential to polynomial form. Under SMIC 40nm process, this conversion table has approximately 1500 gates, so a total of 128 * 2 * 1500 = 384000 gates would be needed. However, the solution of this invention avoids the exhaustive step by using conjugate XOR units, requiring only about 80,000 gates in practical applications, greatly reducing hardware costs and improving decoding efficiency.

[0085] Based on the above method embodiments, this application also provides a decoding apparatus for error-correcting codes. See also Figure 3 , Figure 3 This is a schematic diagram of a decoding device for error-correcting codes provided in an embodiment of this application.

[0086] The device 300 includes:

[0087] The first acquisition unit 301 is used to acquire the Galois domain equation corresponding to the error correction code, wherein the total length of the error correction code is a preset number of bits.

[0088] The first determining unit 302 is used to determine the target relational expression corresponding to the error position after decoding the error correction code based on the Galois domain equation. The target relational expression is derived based on Vieta's theorem.

[0089] The second determining unit 303 is used to determine multiple conjugate position pairs based on the target relation;

[0090] The third determining unit 304 is used to determine, for any one of the multiple conjugate position pairs, the first polynomial corresponding to the exponent coefficient of the first position and the second polynomial corresponding to the exponent coefficient of the second position in the conjugate position pair based on the exponent-polynomial lookup table of the Galois domain.

[0091] The second acquisition unit 305 is used to perform an XOR operation on the coefficients of the first polynomial and the coefficients of the second polynomial to obtain the XOR result.

[0092] The fourth determining unit 306 is used to determine the first position and the second position as erroneous positions when the XOR result matches the target coefficient of the Galois domain equation.

[0093] In one possible implementation, the second acquisition unit 305 is specifically used to determine multiple matching pairs in the first polynomial and the second polynomial that have the same exponent; for any matching pair in the multiple matching pairs, the two coefficients of the matching pair are XORed to obtain the XOR result of the multiple matching pairs.

[0094] In one possible implementation, the process of matching the XOR result with the target coefficients of the Galois domain equation includes:

[0095] Obtain the target coefficients of the Galois domain equation, where the target coefficients are the coefficients of the linear terms in the Galois domain equation; determine the target polynomial corresponding to the target coefficients based on the exponent-polynomial lookup table; and match the coefficients of the target polynomial with the XOR result.

[0096] In one possible implementation, the derivation process for determining the target relation based on Vieta's formulas includes:

[0097] Based on the generators of the Galois equation, determine the first exponent corresponding to the first coefficient of the Galois equation, where the first coefficient is the coefficient of the highest power term; based on the generators, determine the second exponent corresponding to the first root of the Galois equation and the third exponent corresponding to the second root of the Galois equation; based on Vieta's formulas, determine the product relationship between the second exponent and the third exponent, where the product relationship includes the first exponent; based on the product relationship, determine the target relationship, where the first root and the first error position are reciprocals, and the second root and the second error position are reciprocals.

[0098] In one possible implementation, the first determining unit 302 is specifically used to take the logarithm of both sides of the product relation to determine the summation relation; and to determine the target relation based on the reciprocal relationship between the first root and the first error position, the reciprocal relationship between the second root and the second error position, and the summation relation.

[0099] In one possible implementation, the second determining unit 303 is specifically used to determine the midpoint position based on the target relation; based on the midpoint position and the value space of the Galois domain equation, determine the first side position space and the second side position space corresponding to the midpoint position, wherein the first side position space and the second side position space are non-overlapping value spaces, and the first side position space, the second side position space, and the midpoint position constitute the value space of the Galois domain equation; determine the first position in the first side position space, determine the second position in the second side position space, determine the first position and the second position as a conjugate position pair, and the distance between the first position and the midpoint position is equal to the distance between the second position and the midpoint position.

[0100] In one possible implementation, the Galois domain equation is a quadratic equation in one variable.

[0101] The beneficial effects of the decoding device for the error correction code provided in this application embodiment can be found in the above method embodiment, and will not be repeated here.

[0102] Based on the above method and apparatus embodiments, this application also provides a decoding device for error-correcting codes. See also Figure 4 , Figure 4 This is a schematic diagram of a decoding device for error correction codes provided in an embodiment of this application.

[0103] Device 400 includes: memory 401 and processor 402;

[0104] The memory 401 is used to store relevant program code;

[0105] The processor 402 is used to call the program code and execute the decoding method of the error correction code described in the above method embodiment.

[0106] Furthermore, embodiments of this application also provide a computer-readable storage medium for storing a computer program for executing the decoding method of the error-correcting code described in the above method embodiments.

[0107] It should be noted that the various embodiments in this specification are described in a progressive manner, with each embodiment focusing on the differences from other embodiments. Similar or identical parts between embodiments can be referred to interchangeably. In particular, for system or device embodiments, since they are basically similar to method embodiments, the description is relatively simple, and relevant parts can be referred to the descriptions in the method embodiments. The device embodiments described above are merely illustrative. The units or modules described as separate components may or may not be physically separate. The components shown as units or modules may or may not be physical modules; that is, they may be located in one place or distributed across multiple network units. Some or all of the units or modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without creative effort.

[0108] It should be understood that in this application, "at least one (item)" means one or more, and "more than" means two or more. "And / or" is used to describe the relationship between related objects, indicating that three relationships can exist. For example, "A and / or B" can represent three cases: only A exists, only B exists, and both A and B exist simultaneously, where A and B can be singular or plural. The character " / " generally indicates that the preceding and following related objects are in an "or" relationship. "At least one (item) of the following" or similar expressions refer to any combination of these items, including any combination of single or plural items. For example, at least one (item) of a, b, or c can represent: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, and c can be single or multiple.

[0109] It should also be noted that, in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

[0110] The steps of the methods or algorithms described in conjunction with the embodiments disclosed herein can be implemented directly by hardware, a software module executed by a processor, or a combination of both. The software module can be located in random access memory (RAM), main memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, removable disk, CD-ROM, or any other form of storage medium known in the art.

[0111] The above description of the disclosed embodiments enables those skilled in the art to make or use this application. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of this application. Therefore, this application is not to be limited to the embodiments shown herein, but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims

1. A decoding method for error-correcting codes, characterized in that, The method includes: Obtain the Galois domain equation corresponding to the error correction code, wherein the total length of the error correction code is a preset number of bits; Based on the Galois domain equation, the target relational expression corresponding to the error position after decoding the error correction code is determined. The target relational expression is derived based on Vieta's theorem. Multiple conjugate position pairs are determined based on the target relation; For any of the multiple conjugate position pairs, based on the exponent-polynomial lookup table of the Galois field, determine the first polynomial corresponding to the exponent coefficient of the first position and the second polynomial corresponding to the exponent coefficient of the second position in the conjugate position pair. XOR the coefficients of the first polynomial and the coefficients of the second polynomial to obtain the XOR result; When the XOR result matches the target coefficient of the Galois domain equation, the first position and the second position are determined to be erroneous positions.

2. The method according to claim 1, characterized in that, The step of XORing the coefficients of the first polynomial and the coefficients of the second polynomial to obtain the XOR result includes: Identify multiple matching pairs in the first and second polynomials where the exponents of the powers are the same; For any of the multiple matching pairs, XOR the two coefficients of the matching pair to obtain the XOR result of the multiple matching pairs.

3. The method according to claim 2, characterized in that, The process of matching the XOR result with the target coefficients of the Galois domain equation includes: Obtain the target coefficients of the Galois domain equation, wherein the target coefficients are the coefficients of the first-order terms in the Galois domain equation; Based on the index-polynomial comparison table, determine the target polynomial corresponding to the target coefficient; The XOR result is matched with the coefficients of the target polynomial.

4. The method according to claim 1, characterized in that, The derivation process of determining the target relation based on Vieta's formulas includes: The first exponent corresponding to the first coefficient of the Galois domain equation is determined based on the generator of the Galois domain equation, where the first coefficient is the coefficient of the highest power term. Based on the generator, determine the second exponent corresponding to the first root of the Galois domain equation and the third exponent corresponding to the second root of the Galois domain equation. The product relationship between the second exponent and the third exponent is determined based on Vieta's formulas, and the product relationship includes the first exponent; The target relation is determined based on the product relation, wherein the first root and the first error position are inversely related, and the second root and the second error position are inversely related.

5. The method according to claim 4, characterized in that, Determining the target relation based on the product relation includes: Take the logarithm of both sides of the product expression to determine the summation expression; Based on the reciprocal relationship between the first root and the first error position, the reciprocal relationship between the second root and the second error position, and the summation formula, the target formula is determined.

6. The method according to claim 5, characterized in that, The determination of multiple conjugate position pairs based on the target relation includes: Determine the midpoint position based on the target relation; Based on the midpoint position and the value space of the Galois domain equation, the first side position space and the second side position space corresponding to the midpoint position are determined. The first side position space and the second side position space are non-overlapping value spaces, and the first side position space, the second side position space and the midpoint position constitute the value space of the Galois domain equation. The first position is determined in the first side position space, and the second position is determined in the second side position space. The first position and the second position are determined to be a conjugate position pair. The distance between the first position and the midpoint position is equal to the distance between the second position and the midpoint position.

7. The method according to any one of claims 1 to 6, characterized in that, The Galois domain equation is a quadratic equation in one variable.

8. A decoding device for error-correcting codes, characterized in that, The device includes: The first acquisition unit is used to acquire the Galois domain equation corresponding to the error correction code, wherein the total length of the error correction code is a preset number of bits. The first determining unit is used to determine the target relational expression corresponding to the error position after decoding the error correction code based on the Galois domain equation. The target relational expression is derived based on Vieta's theorem. The second determining unit is used to determine multiple conjugate position pairs based on the target relation; The third determining unit is used to determine, for any one of the multiple conjugate position pairs, the first polynomial corresponding to the exponent coefficient of the first position and the second polynomial corresponding to the exponent coefficient of the second position in the conjugate position pair based on the exponent-polynomial lookup table of the Galois domain. The second acquisition unit is used to perform an XOR operation on the coefficients of the first polynomial and the coefficients of the second polynomial to obtain the XOR result. The fourth determining unit is used to determine the first position and the second position as erroneous positions when the XOR result matches the target coefficient of the Galois domain equation.

9. A decoding device for error-correcting codes, characterized in that, The device includes: a memory and a processor; The memory is used to store the relevant program code; The processor is used to call the program code to execute the decoding method of the error correction code according to any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium is used to store a computer program for executing the decoding method of the error-correcting code according to any one of claims 1 to 7.

Citation Information

Patent Citations

  • High-speed parallel BCH code decoding method and device

    CN106549677A

  • RS error correction decoding method

    US20180138926A1