Why are check digits for UPCs computed modulo 10, whereas for ISBNs, modulo 11?

555 Views Asked by At

Recently I was reading a mathematics book and encounterd the fact that UPC codes have a check digit at the end that is computed modulo 10, whereas ISBN numbers have a check digit that is computed modulo 11.

What disturbs me is the fact that why is 10 used as the modulus in UPC check digit calculation whereas 11 for ISBN check digit calculation. What would happen if we instead used 10 for ISBN check digit calculation?

2

There are 2 best solutions below

0
On BEST ANSWER

If you changed one of the digits by 5 (e.g. changed a 7 to a 2) and that digit was in a spot with an even weight, that change would not be caught using a mod 10 checksum. So the checksum would no longer be able to catch all single-digit errors. Since 11 is prime, it does not have that problem, but does have the disadvantage of occasionally needing to use a non-digit symbol for the checkdigit.

The UPC uses odd weights for each digit, so there all single-digit errors are still caught even though it uses modulus 10. However, the difference of the weights of adjacent digits is even, so it won't catch adjacent transpositions if the digits differ by 5.

0
On

We would only pick up $90\%$ of the errors instead of $91\%$