Abstract:
A multiplier for use with polynomials in an error correction system wherein the multiplier and multiplicand are first encoded from m bits to N bits, where N is greater than m, and wherein the multiplication is accomplished on a bit basis by arrays of AND gates and where the resultant product is decoded from R bits to S bits where S is less than R.

Description:
BACKGROUND OF THE INVENTION 
     This invention relates to digital multipliers as used in the field of error correction techniques. More particularly this invention relates to the multiplication of polynomials representing finite fields such that the system of error correcting constrains the numbers to be multiplied in certain ways so as to influence the resulting hardware implemented multiplier. 
     SUMMARY OF THE INVENTION 
     With respect to the multiplication of two binary sequences certain properties have been observed. Thus, it has been determined that if a pair of binary numbers, having certain properties, is to be multiplied, the numbers are transformed to a longer binary sequence, one of which is an inverse, and the hardware multiplication network is simplified. 
     Thus a particular binary network for multiplication has been invented where the binary inputs are transformed by an encoding network and in which the product is decoded to produce the output resultant. 
     The encoding circuits may be an array of Exclusive OR gates for both inputs, one of which forms an inverse in the transform process. The multiplier circuit appears for ease of understanding as a matrix like network having AND gates coupled to it. Exclusive OR gates are coupled to the AND gates to form an intermediate resulting product. Finally, further Exclusive ORs decode or transform the intermediate result to a final product. 
    
    
     IN THE FIGURES 
     The single drawing FIGURE is a schematic circuit diagram showing an embodiment of the present invention for multiplication of four bit binary numbers of a particular type. 
    
    
     DESCRIPTION OF THE PREFERRED EMBODIMENT 
     Let GF(2 4 ) represent a finite field with (2 4  =) 16 elements, each of which can be represented by a byte of four binary digits. These entities of four-bit-bytes can be taken either as vectors or as polynomials over the binary field that has only two elements, namely, 0 and 1. To facilitate the algebraic manipulation, 
     
         A=a.sub.0 +a.sub.1 x+a.sub.2 x.sup.2 +a.sub.3 x.sup.3 
    
     where a 0 ,a 1 ,a 2 , and a 3  assume either 0 or 1. Occasionally, however, the vector (a 0 ,a 1 ,a 2 ,a 3 ) or its transpose will be used for convenience to refer to A. 
     With an appropriately chosen primitive or irreducible polynomial M(x), e.g., x 4  +x+1, we can picture our finite field GF(2 4 ) as the residual class of all polynomials, with binary coefficients, module M(x). Additions as well as multiplications between elements of GF(2 4 ) can then be simply defined in terms of the wellknown arithmetic of polynomials, reduced by M(x) to yield a resultant element as a polynomial of degree less than 4. Note that additions and multiplications of coefficients are understandably carried out over the binary field where the latter is just the logical &#34;AND&#34; operation and the former the logical &#34;EXCLUSIVE-OR&#34;, usually abreviated &#34;XOR&#34; or &#34;EOR&#34;. 
     The implementation of addition over GF(2 4 ) may be accomplished with XOR operations bit-by-bit in parallel. That of multiplication can nevertheless be quite involved because, as is common, the degree of the product of two polynomials is the sum of the degrees of the multiplicants. Consequently, the process of reduction modulo M(x) has to be performed more often than not. For instance, ##EQU1## The complex process of the reduction modulo M(x) can however be avoided as we notice 
     
         1=x.sup.15 =(x.sup.3).sup.5 
    
     That is, if 
     
         r=x.sup.3 
    
     then 
     
         r.sup.2 =x.sup.3 +x.sup.2 
    
     
         r.sup.3 =x.sup.3 +x 
    
     
         r.sup.4 =x.sup.3 +x.sup.2 +x+1 
    
                                                                (1) 
     and 
     
         r.sup.5 =1 
    
     This provides us a transformation from a representation in terms of x into that of r with the following ##EQU2## In order to find the product C=AB where 
     
         B=b.sub.0 +b.sub.1 x+b.sub.2 x.sup.2 +b.sub.3 x.sup.3 
    
     and 
     
         C=c.sub.0 +c.sub.1 x+c.sub.2 x.sup.2 +c.sub.3 x.sup.3 
    
     we can first transform A into A&#39;, and B into B&#39; based on (2) to get 
     
         A&#39;=a.sub.0 &#39;+a.sub.1 &#39;r+a.sub.2 &#39;r.sup.2 +a.sub.3 &#39;r.sup.3 +a.sub.4 &#39;r.sup.4 
    
     
         B&#39;=b.sub.0 &#39;+b.sub.1 &#39;r+b.sub.2 &#39;r.sup.2 +b.sub.3 &#39;r.sup.3 +b.sub.4 &#39;r.sup.4 
    
     and perform the multiplication C&#39;=A&#39;B 
     
         =(a.sub.0 &#39;b.sub.0 &#39;)+(a.sub.0 &#39;b.sub.1 &#39;+a.sub.1 &#39;b.sub.0 &#39;) r+(a.sub.0 &#39;b.sub.2 &#39;+a.sub.1 &#39;b.sub.1 &#39;+a.sub.2 &#39;b.sub.0 &#39;) r.sup.2 +(a.sub.0 &#39;b.sub.3 &#39;+a.sub.1 &#39;b.sub.2 &#39;+a.sub.2 &#39;b.sub.1 &#39;+a.sub.3 &#39;b.sub.0 &#39;) r.sup.3 +(a.sub.0 &#39;b.sub.4 &#39;+a.sub.1 &#39;b.sub.3 &#39;+a.sub.2 &#39;b.sub.2 &#39;+a.sub.3 &#39;b.sub.1 &#39;+a.sub.4 &#39;b.sub.0 &#39;) r.sup.4 +(a.sub.1 &#39;b.sub.4 &#39;+a.sub.2 &#39;b.sub.3 &#39;+a.sub.3 &#39;b.sub.2 &#39;+a.sub.4 &#39;b.sub.1 &#39;) r.sup.5 +(a.sub.2 &#39;b.sub.4 &#39;+a.sub.3 &#39;b.sub.3 &#39;+a.sub.4 &#39;b.sub.2 &#39;) r.sup.6 +(a.sub.3 &#39;b.sub.4 &#39;+a.sub.4 &#39;b.sub.3 &#39;) r.sup.7 +(a.sub.4 &#39;b.sub.4 &#39;) r.sup.8 
    
     As r 5  =1, r 6  =r, r 7  =r 2 , and r 8  =r 3 , the only reduction necessary is a proper realignment. Let 
     
         C&#39;=c.sub.0 &#39;+c.sub.1 &#39;r+c.sub.2 &#39;r.sup.2 +c.sub.3 &#39;r.sup.3 +c.sub.4 &#39;r.sup.4 
    
     this means 
     
         ______________________________________c.sub.0 &#39; = a.sub.0 &#39;b.sub.0 &#39; + a.sub.1 &#39;b.sub.4 &#39; + a.sub.2 &#39;b.sub.3 &#39;+ a.sub.3 &#39;b.sub.2 &#39; +a.sub.4 &#39;b.sub.1 &#39;c.sub.1 &#39; = a.sub.0 &#39;b.sub.1 &#39; + a.sub.1 &#39;b.sub.0 &#39; + a.sub.2 &#39;b.sub.4 &#39;+ a.sub.3 &#39;b.sub.3 &#39; + a.sub.4 &#39;b.sub.2 &#39;c.sub.2 &#39; = a.sub.0 &#39;b.sub.2 &#39; + a.sub.1 &#39;b.sub.1 &#39; + a.sub.2 &#39;b.sub.0 &#39;+ a.sub.3 &#39;b.sub.4 &#39; + a.sub.4 &#39;b.sub.3 &#39;c.sub.3 &#39; = a.sub.0 &#39;b.sub.3 &#39; + a.sub.1 &#39;b.sub.2 &#39; + a.sub.2 &#39;b.sub.1 &#39;+ a.sub.3 &#39;b.sub.0 &#39; + a.sub.4 &#39;b.sub.4 &#39;c.sub.4 &#39; = a.sub.0 &#39;b.sub.4 &#39; + a.sub.1 &#39;b.sub.3 &#39; + a.sub.2 &#39;b.sub.2 &#39;+ a.sub.3 &#39;b.sub.1 &#39; + a.sub.4 &#39;b.sub.0 &#39;______________________________________ 
    
     Or in matrix form, we have ##EQU3## Having obtained the intermediate product C&#39; in terms of r, we can then transform C&#39; into C based on (1) 
     Therefore, in the example (0), we have have 
     
         ______________________________________ (x +  x.sup.2) (x + x.sup.3)    =    ((r.sup.3 + r) +  (r.sup.2 + r))        ((r.sup.3 + r) +  (r))    =   (r.sup.3 + r.sup.2 ) (r.sup.3 )    =   r.sup.6 + r.sup.5    =   r+ 1    =   x.sup.3 + 1______________________________________ 
    
     In fact, (1) can be put into matrix form for coefficients as ##EQU4## and similarly (2) as ##EQU5## The significance is that this transform T as well as its inverse U can easily be implemented in a logic network of the sort shown in the drawing FIG. 1. 
     This invention also provides a means to find the multiplicative inverse, which is: 
     Given an element A=a 0  +a 1  x+a 2  x 2  +a 3  x 3 , to seek an element B=b 0  +b 1  x+b 2  x 2  +b 3  x 3 , such that 
     
         ______________________________________AB =    (a.sub.0 + a.sub.1 x + a.sub.2 x.sup.2 + a.sub.3 x.sup.3)   (b.sub.0 + b.sub.1 x + b.sub.2 x.sup.2 + b.sub.3 x.sup.3)=       1 mod M(x)______________________________________ 
    
     It is necessary to transform A=a 0  +a 1  x+a 2  x 2  +a 0  x 3  into, based on (2&#39;), 
     
         A&#39;=a.sub.0 &#39;+a.sub.1 &#39;r+a.sub.2 &#39;r.sup.2 +a.sub.3 &#39;r.sup.3 +a.sub.4 &#39;r.sup.4 
    
     Then a polynomial B&#39;=b 0  &#39;+b 1  &#39;r+b 2  &#39;r 2  +b 3  &#39;r 3  +b 4  &#39;r 4  is proposed as an intermediate step, such that 
     
         A&#39;B&#39;=(a.sub.0 &#39;+a.sub.1 &#39;r+a.sub.2 &#39;r.sup.2 +a.sub.3 &#39;r.sup.3 +a.sub.4 &#39;r.sup.4)(b.sub.0 &#39;+b.sub.1 &#39;r+b.sub.2 &#39;r.sup.2 +b.sub.3 &#39;r.sup.3 +b.sub.4 &#39;r.sup.4)=1 
    
     Finally, the result B=b 0  +b 1  x+b 2  x 2  +b 3  x 3  can be obtained from B&#39; with the transform (substitution (1&#39;) 
     To illustrate the present invention, consider the case where a 0  =a 1  =a 3  =1, a 2  =0. That is, determine the multiplicative inverse of A=1+x+x 3 . With (2), the substitution can be made: 
     
         ______________________________________A =       1 + x + x.sup.3=         (r + r.sup.2 + r.sup.3 + r.sup.4) + (r + r.sup.3) + r=         r + r.sup.2 + r.sup.4 = A&#39;______________________________________ 
    
     or, a 0  &#39;=a 3  &#39;=0 and a 1  &#39;=a 2  &#39;=a 4  &#39;=1. Suppose the multiplicative inverse of A&#39; is B&#39;=b 0  &#39;+b 1  &#39;r+b 2  &#39;r 2  +b 3  &#39;r 3  +b 4  &#39;r 4 , then A&#39;B&#39;=(r+r 2  +r 4 )(b 0  &#39;+b 1  &#39;r+b 2  &#39;r 2  +b 3  &#39;r 3  +b 4  &#39;r 4 )=1. 
     By expansion of the lefthand side of the equation 
     
         b.sub.0 &#39;r+(b.sub.0 &#39;+b.sub.1 &#39;)r.sup.2 +(b.sub.1 &#39;+b.sub.2 &#39;)r.sup.3 +(b.sub.0 &#39;+b.sub.2 &#39;+b.sub.3 &#39;)r.sup.4 +(b.sub.1 &#39;+b.sub.3 &#39;+b.sub.4 &#39;)r.sup.5 +(b.sub.2 &#39;+b.sub.4 &#39;)r.sup.6 +b.sub.3 &#39;r.sup.7 +b.sub.4 &#39;r.sup.8 =1. 
    
     Invoking the identities (2), the further substitutions can be made: 
     
         (b.sub.1 &#39;+b.sub.3 &#39;+b.sub.4 &#39;)+(b.sub.0 &#39;+b.sub.2 &#39;+b.sub.4 &#39;)r+(b.sub.0 &#39;+b.sub.1 &#39;+b.sub.3 &#39;)r.sup.2 +(b.sub.1 &#39;+b.sub.2 &#39;+b.sub.4 &#39;)r.sup.3 +(b.sub.0 &#39;+b.sub.2 &#39;+b.sub.3 &#39;)r.sup.4 =r+r.sup.2 +r.sup.3 +r.sup.4 
    
     This means that we have to require, for B&#39;, ##EQU6## or in matrix form, ##EQU7## which is a system of five equations for five unknowns b 0  &#39;, b 1  &#39;, b 2  &#39;, b 3 , b 4  &#39;. For solution, we perform row operations on the array ##EQU8## to yield, in canonical form, ##EQU9## to indicate that the system of equations (3) is equivalent to the following ##EQU10## Hence, there is an intermediate step B&#39;=r 4  +r 3 . By inverse transform (1&#39;) then 
     
         ______________________________________B&#39;         = r.sup.3 + r.sup.4      = (x + x.sup.3) + (1 + x + x.sup.2 + x.sup.3)      = 1 + x.sup.2 = B______________________________________ 
    
     Notice that the leftmost column of matrix (4) is merely the transpose of the vector (a 0  &#39;, a 1  &#39;, a 2  &#39;, a 3  &#39;, a 4  &#39;) for A&#39;. The other columns, to the left of the vertical line, are each given by cyclically shifting the column to its left one position downward. The column to the right of the vertical line is the vector for the element 1 as 1=r+r 2  +r 3  +r 4 . The intermediate answer B&#39;, as a column vector, can be taken directly from the column to the right of the vertical line in (5). 
     The findings are summarized as follows: 
     Given A=a 0  +a 1  x+a 2  x 2  +a 3  x 3 , get A&#39;=a 0  &#39;+a 1  &#39;r+a 2  &#39;r 2  +a 3  &#39;r 3  +a 4  &#39;r 4  by (1). Construct the array ##EQU11## With row operations, reduce the square matrix at the left to its canonical form, i.e., identity matrix if at all possible, as in the following: ##EQU12## When c 4  =1, then c 0  =c 1  =c 2  =c 3  =0 and there is an identity matrix at left. Otherwise, i.e., when c 4  =b 4  &#39;=0, c 0 , c 1 , c 2 , c 3  can be arbitrary. In either case, the multiplicative inverse B&#39; of A&#39; can be taken directly from the right-most column of the array (5&#39;). That is, use the transpose of the row vector (b 0  &#39;, b 1  &#39;, b 2  &#39;, b 3  &#39;, b 4  &#39;) to form 
     
         B&#39;=b.sub.0 &#39;+b.sub.1 &#39;r+b.sub.2 &#39;r.sup.2 +b.sub.3 &#39;r.sup.3 +b.sub.4 &#39;r.sup.4                                                  (6) 
    
     To yield B=b 0  +b 1  x+b 2  x 2  +b 3  x 3 , the multiplicative inverse of A=a 0  +a 1  x+a 2  x 2  +a 3  x 3 , the transform (1&#39;) is applied to B&#39; of (6). 
     In fact, (1&#39;) can be put in the matrix form for coefficients as ##EQU13## and similarly (1) as ##EQU14## The significance is that this transform as well as its inverse can easily be implemented in a logic network of the sort shown in the drawing FIGURE. 
     A system according to the present invention can be formed for any size multiplication where the number of operand bits m meets the test of 2 m  -1 is divisible by m+1 to produce an integer. The present embodiment is shown for m=4 in a system GF(2 4 ) and it will work for m=6,10,12,16,18,22,28, according to the test described. 
     Referring now to the single drawing FIGURE, a finite field multiplier 10 according to the present invention is shown where the system is mathematically described by the preceding discussion for a 4×4 multiplication. A four bit A operand is supplied to input terminals a 0 , a 1 , a 2 , a 3  and enters a first input transpose network 12 which generates a five bit intermediate operand using Exclusive OR gates 14, 16 and 18. The five bit intermediate A&#39; operand is supplied to multiplier busses a&#39; 0 , a&#39; 1 , a&#39; 2 , a&#39; 3  and a&#39; 4 . 
     Similarly a four bit B operand is supplied to input terminals b 0 , b 1 , b 2 , and b 3  of a second input transpose network 20. The first input transpose network 12 is similar to the second input transpose network 20. Second input transpose network 20 is comprised of Exclusive OR gates 22, 24 and 26. The output of network 20 is a five bit intermediate B&#39; operand which is supplied to multipler busses b&#39; 0 , b&#39; 1 , b&#39; 2  b&#39; 3  and b&#39; 4 . 
     The contents of the ten multiplier, busses a&#39; 0  --a&#39; 4  and b&#39; 0  --b&#39; 4  are connected in the array shown in the FIGURE to five groups of AND gates 30, 32, 34, 36 and 38 which generate partial product bits. Exclusive OR gates 40, 42, 44, 46 and 48 connected with AND gate groups 30, 32, 34, 36 and 38 respectively decode the partial product bits and provide outputs to five product busses c&#39; 0 , c&#39; 1 , c&#39; 2 , c&#39; 3  and c&#39; 4 . 
     The product busses are connected to an output inverse transpose network 50 which comprises Exclusive OR gates 52, 54, 56 and 58. The output of transpose network 50 is the four bit product operand C consisting of output bits c 0 , c 1 , c 2  and c 3  from Exclusive OR gates 52, 54, 56 and 58, respectively.