Beruflich Dokumente
Kultur Dokumente
Burst errors
Denition: A burst of length l is an n-tuple whose nonzero symbols are conned to a span of l symbols and no fewer. Denition: A wraparound burst of length l is any cyclic shift of a burst of length l. A burst is specied by location and burst pattern. Location is dened to be least signicant digit of burst. Burst pattern for a burst of length l is a polynomial b(x) of degree l 1. Burst: e(x) = xib(x), where i is location and b(x) is pattern (b0 = 0). Wraparound burst: e(x) = xib(x) mod (xn 1). Example: Consider the following 10-tuples: 0001011000 is a burst of length 4, location 3, pattern 1 + x2 + x3 . 1100000010 is a wraparound burst of length 4, location 8, pattern 1 + x2 + x3 . (It is a burst of length 9.)
EE 387 Notes #6, Page 1
Exercise: The burst error detecting ability of any (n, k) block code is n k.
EE 387 Notes #6, Page 2
r(x)
c(x)
Corollary: A linear block code can correct all bursts of length l if and only if no codeword is the sum of two bursts of length l. Theorem: (Rieger Bound): The burst error correcting ability l of an (n, k) linear block code satises 2l n k. Proof : All Q2l polynomials of degree < 2l must have distinct syndromes. Otherwise the dierence of two such polynomials would be a codeword that is a sum of 2 bursts of length l.
EE 387 Notes #6, Page 3
2l . nk
r (i)(x) i j
r (i)(x) mod g(x) = s[i](x) e(x) s(x) = r(x) mod g(x) e(i)(x) The syndromes s[1](x), . . . , s[n1](x) of cyclic shifts r (1)(x), . . . , r (n1)(x) can be computed by repeatedly shifting syndrome register with g(x) feedback.
EE 387 Notes #6, Page 5
Cyclic decoding
Lemma: The syndrome of r (1)(x) is s[1](x) = xs(x) mod g(x). Proof : Lets evaluate the syndrome of r (1)(x). r (1)(x) mod g(x) = (xr(x) rn1(xn 1)) mod g(x) = xr(x) mod g(x) (since g(x) | (xn 1)) = x(r(x) mod g(x)) mod g(x) = xs(x) mod g(x) = s[1](x) The cyclic decoding principle suggests the following decoding method: Calculate s(x) = r(x) mod g(x). Shift syndrome register with feedback until s[i](x) contains a syndrome that is known to correspond to error e(x). Decode r(x) using e(i)(x). This method works especially well for burst errors (see error trapping later).
EE 387 Notes #6, Page 6
The syndrome of e(x) = x14 is 1001 = 1 + x3, which is the last column of H. If we shorten the code to, say, (12, 8), the syndrome of an error in the msb would be x11 mod g(x) = 0111 = x + x2 + x3.
We can generalize this approach to correcting short burst errors. It can be shown that the generator polynomial (x + 1)(x4 + x + 1) = x5 + x4 + x2 + 1 can correct bursts of length 2. A decoder should correct the msb when the syndrome register contains the syndromes of either x14 or x13 + x14 . EE 387 Notes #6, Page 7
r(x) s(x)
parallel transfer
clear SR
c(x)
The decoder can be pipelined. In the rst phase, the syndrome of r(x) is computed using the rst LFSR. In the second phase, the buered codeword is corrected one bit at a time. If the syndrome register is nonzero at the end of the correction phase, an uncorrectable error has been detected.
EE 387 Notes #6, Page 8
Error trapping
replacements If error pattern e(x) is in low order n k symbols, then deg e(x) < n k.
r(x)
In this case, s(x) = r(x) mod g(x) = e(x) mod g(x) = e(x) . The syndrome polynomial is the same as the error polynomial. In general, r(x) s(x) is a codeword obtained by correcting only check digits. If s(x) is a plausible i.e., correctable error pattern, we estimate e(x) = s(x). Since deg s(x) < n k, only error patterns that are conned to n k consecutive locations can be corrected by this method. By Rieger bound, correctable burst have length 1 (n k), so they can be rotated 2 into low order n k positions.
r(x)
r (nk)(x)
nk
Then we test syndrome of shifted senseword to see if it is a burst of length l located in high-order l check digits. When correctable burst is located in the high-order l check symbols, then the low-order n k l syndrome digits are 0.
0 0 ... 0 x x ... x l
EE 387 Notes #6, Page 10
nkl
c(x)
The syndrome circuit uses the same datapath as the systematic encoder.
c(x)
r(x) s0(x)
r(x) s1(x)
Since 2 right shifts = 5 left shifts, error location satises i mod 7 = 5. s1 (x) = 1100 s1 (x) = 0110 s1 (x) = 0011
[2] [1] [0]
s1 (x) = 1101 = b(x) Since 3 right shifts = 12 left shifts, error location satises i mod 15 = 12. Error location is unique solution modulo 105: i = 12.
EE 387 Notes #6, Page 16
[3]
Interleaved codes
Denition: The -way interleave of an (n, k) block code C is the (n, k) block code C {} in which each subsequence (cj , cj+, cj+2, . . . , cj+(n1) ) ,
c{3} c{1} c{0} c{2} c{4}
j = 0, 1, . . . , 1
One way to represent a -way interleaved code c0 c c2 c c+1 c2+1 1 c = . . . . . . c1 c21 c31
11111 00000 11111 00000 11111 00000 11111 00000 11111 00000 11111 00000 11111 00000 11111 00000 checks
correctable burst
uncorrectable burst
Every row has h/ consecutive errors (usually at least h/ errors). A burst of length l causes a burst of length l in any row correctable. Conversely, an uncorrectable burst of length l + 1 in one row is not correctable. Its length in the serialized data is l + 1.
EE 387 Notes #6, Page 18
Interleaving is a simple, eective way to handle long bursts. Only costs: memory: the code array (except for last column) must be stored before any row decoding can be completed (n 1) symbols delay: the code array (except for last column) must be received before decoding the rst row (n 1) symbols in worst case. Storage cost can be reduced about half by using a convolutional interleaver.
Cyclic burst correcting codes can decode in n steps using error trapping. Fire code has generator polynomial g(x) = (x2t1 1)p(x) and can correct bursts of length m. The -way interleave of a code multiplies the burst error protection ability by .
The Rieger bound holds for all (n, k) block codes, not just linear. EE 387 Notes #6, Page 20
GF(Q) is a vector space over GF(q) of dimension n. Q = q n pM = (pm)n = pmn M = nm m | M . The exponent of the subeld divides the exponent of the extension eld. Example: Subelds of GF(235) are GF(27), GF(25), GF(2) . GF(219) is not contained in GF(235) since 19 is not a divisor of 35. Smallest subeld that contains both GF(219) and GF(235) is GF(2lcm(19,35)) = GF(21935) = GF(2665) .
GF(235 ) has additive subgroups of order 219 but no subeld of size 219 .
two zeroes of x2 + x + 1. 12 zeroes of three prime polynomials of degree 4. x4 + x + 1, x4 + x3 + 1, x4 + x3 + x2 + x + 1 . 240 zeroes of 30 prime polynomials of degree 8. x8 + x4 + x3 + x2 + 1, . . . , x8 + x7 + x6 + x5 + x4 + x3 + 1
EE 387 Notes #6, Page 22
12
3
GF(64)
[ 54 ]
GF(16)
[12]
4
3 2
GF(8) [ 6 ] GF(4) [ 2 ]
3
2
3 2
GF(2) [ 2 ]
GF(212) has 4096 64 16 + 4 = 4020 elements not in any proper subeld. Each maximally complex element of GF(212) is a zero of some prime polynomial over GF(2) of degree 12, so there are 4020 = 335 prime polynomials of degree 12. 12
6 There are (4095) = 2 4 7 12 4095 = 1728 primitive elements, so there are 3 5 13 1728 12 = 144 primitive polynomials over GF(2) of degree 12.
EE 387 Notes #6, Page 23
Conjugacy classes
GF(Q) can be partitioned into conjugacy classes for any subeld GF(q) GF(Q). Each conjugacy class consists of all the zeroes of a minimal polynomial over GF(q). Example: GF(16) GF(2). Conjugacy classes for 0 and 1 are {0} and {1}. element conjugacy class 3 5 7 {, 2, 4, 8} {5, 10} {7, 14, 13, 11} (16 = ) (20 = 5) (22 = 7) {3, 6, 12, 24 = 9} (18 = 3)
Every element of GF(Q) = GF(q m) is a power of a primitive element . Conjugacy classes can be represented by exponents (logs base ). The exponents of the members of the conjugacy class containing i are i, qi mod (Q1), q 2i mod (Q1), . . . , q r1i mod (Q1) for some r m. (In fact, r | m.)
EE 387 Notes #6, Page 24
Exponents in each conjugacy class are found by multiplying by 2 modulo 63. Elements with fewer than 6 conjugates belong to proper subelds. The exponents of the nonzero elements of proper subelds of GF(64). GF(2) = {0} GF(4) = {21, 42} GF(8) = {9, 18, 36}, {27, 54, 45}
EE 387 Notes #6, Page 25
Minimal polynomial of 9 is x3 + x2 + 1 because 9 = 000110 , 18 = 111100 , 27 = 011100 27 + 18 + 1 = 0 Minimal polynomial of 21 is x2 + x + 1 because 21 = 110111 , 42 = 010111 42 + 21 + 1 = 0 Minimal polynomial of is x6 + x + 1 .
EE 387 Notes #6, Page 26
Division is performed as multiplication by reciprocal: a/b = a b1 . Single-cycle division is not needed because decoders use few divides. Most multiplication and division methods take O(m2) bit operations.
Multiplication by constants
GF(2m) is a vector space over GF(2) of dimension m. We choose a basis {1, , 2, . . . , m1} for some usually a primitive element. Multiplication by constant b = b0 + b1 + + bm1m1 is a linear mapping. It can be described by an m m matrix B over GF(2). To derive the components of B, use the distributive law: a b = (a0 + a1 + + am1m1) b = a0b + a1(b) + + am1(m1b) . The products bi = ib for 0 i < m can be precomputed. The components of these vectors can be stored in a binary matrix b0 b0,0 b0,1 b0,m1 b1,1 b1,m1 b1 b1,0 B= . = . . . . ... . . . . bm1 bm1,0 bm1,1 bm1,m1
aibi,j =
ai
i: bi,j =1
In the above formula sum is XOR, product is logical AND. Any GF(2m) scaler can be built using m(m 1) 2-input XOR gates. The typical scaler uses 1 m2 XOR gates. 2
These gate count estimates do not include the use of common subexpressions. Finding the minimum circuit is an NP-complete problem. EE 387 Notes #6, Page 29
General multiplication
Let GF(2m) be polynomials over GF(2) modulo prime p(x) of degree m. For a(x), b(x) in GF(2m) let ti = a(x)b(x) = (t0 + t1x + + tm1xm1 + tmxm + + t2m2x2m2) mod p(x) = t0 + t1x + + tm1xm1 + tm(xm mod p(x)) + + t2m2(x2m2 mod p(x)) We can precompute the m 1 polynomials xm mod p(x), . . . , x2m2 mod p(x) and store them as rows of (m 1) m binary matrix: m m x mod p(x) xm+1 mod p(x) m+1 = . T = . . . x2m2 mod p(x) 2m2 Rows of T are obtained by shifts with feedback corresponding to p(x).
EE 387 Notes #6, Page 32
i j=0 aj bij
where I is the m m identity matrix and T is (m 1) m. Low-level computational formula for product bits yj for j = 0, . . . , m 1:
m2 j m2 m1
yj = tj +
i=0
tm+iTij =
l=0
al bjl +
i=0
Tij
l=i+1
albm+il .
Each bit of the product vector is a sum of a subset of the produt terms aibj .
The product vector consists of m bilinear functions of a and b . EE 387 Notes #6, Page 33
Even though p3 (x) is not primitive, it is prime and can be used to dene GF(24). EE 387 Notes #6, Page 34
For every GF(2m) every product aibj appears in at least one equation. Therefore m2 AND gates are needed by the obvious method. The number of XOR gates is (m 1)2 to compute {t0, t1, . . . , t2m2} plus the number of 1s in T to compute {y0 , y1, . . . , ym1 } from {t0, t1, . . . , t2m2}. Polynomials like x6 + x + 1 result in T matrices with few 1s.
We ignore common subexpression simplication. EE 387 Notes #6, Page 35
This is much larger than about 400 gates for a combinational multiplier.
The lookup table size can be reduced by using precomputation to transform the input to a value whose reciprocal is known, then postcomputation to adjust the inverse. For example, if the inverse of i is (obtained from a table) then the inverse of is i . EE 387 Notes #6, Page 39
Sequential search
The reciprocal of a can be found by testing a b = 1 for each element b of GF(2m). All nonzero values b can be generated using a maximum-length linear feedback shift register. For example, when eld is dened by p(x) = x5 + x2 + 1:
Shifting a register multiplies the contents by the primitive element . The left shift register is loaded with a while the right shift register is loaded with 1. The registers are shifted simultaneously until the left shift register reaches 1. After every shift, the ratio of the left register to the right register is a. If i is the number of shifts needed, then a i = 1, so the value i in the right shift register is the reciprocal of a.
EE 387 Notes #6, Page 40
Time-memory tradeo
An associative memory such as a hash table can be used to reduce the number of clocks needed to nd the reciprocal without using a complete lookup table. For example, suppose we store the reciprocals of 16i for i = 0, 1, . . . , (2m)/16, The following program fragment nds the reciprocal of a in at most 16 steps: for (i = 0; i < 16; i++) { if (a i is in reciprocal table) { return i reciprocal(a i) ; } } The search time can be decreased by using a larger associative memory.
The same approach can be used to reduce the storage needed for computing the discrete logarithm from 2m entries for a direct table lookup to (2m)/c entries if c lookups are used.
Reciprocals: exponentiation
If is any nonzero element of GF(q) then q1 = 1. Therefore 1 = q2 . Powers of can be computed eciently by squaring and multiplying by . Binary representation of 2m 2 contains m bits: 11 102 .
ax + (a + b) a + b a = 2 + 2 x b2 + ab + a2 b + ab + a2 b + ab + a2
Denominator = 0 because a = 0 and x2 + x + 1 is prime. Computation of (ax + b)1 uses operations from the subeld GF(2m): one inverse, one scaler, one squaring, and three multiplications.
EE 387 Notes #6, Page 43
+1 2m 1
= (2
+1)(2m1)
= 2
2m
= 1.
Since order of 2 +1 divides 2m 1, it belongs to small subeld GF(2m). Its reciprocal can be computed using a small circuit. Example: Reciprocal circuit for GF(28) = GF((24)2):
16-th power
17
16
inverse in GF(16)
17
Circuit for 2 is linear, uses 1 m2 XOR gates. Multipliers use O(m2) gates. 2 Subeld reciprocal unit is small. Overall cost of circuit 3 general multipliers.
This method was discovered by Itoh and Tsujii in 1988. Hardware implementations of Galois eld arithmetic are presented in Christof Paars 1994 University of Essen doctoral thesis, Ecient VLSI Architectures for Bit-Parallel Computation in Galois Fields. EE 387 Notes #6, Page 44