|
|
Example:
(x2 + x + 1) × (x + 1) = (x3 + x2 + x) + (x2 + x + 1)
= x3 + 2x2 + 2x + 1
= x3 + 1 (mod 2)
|
|
|
Example:
Generator polynomial: 1001 has the factor 11 |
|
Message: 10011 (has an odd # 1 bits)
CRC polynomial: 1001 (1001 has 11 as factor)
Compute CRC code:
-------------
1001 / 10011000
1001
----
01000
1001
-----
001 <---- Remainder
CRC protected message:
10011001 (has an even number 1 bits !!!)
|
|
|
This makes sense, because:
|
|
Error polynomial representing k-consecutive errors: 1111..1
<----->
k bits
Generator polynomial = 1.........1
<--------->
n+1 bits
The division:
-----------
1.........1 / 1111..1
<---------> <----->
n+1 bits k bits
will have a non-zero remainder if:
k ≤ n
|
|
| Name | Generator polynomial |
|---|---|
| CRC-CCITT | 10001000000100001 |
| CRC-16 | 11000000000000101 |
| CRC-32 | 100000100110000010001110110110111 |