From a long ago checkdigit is used in every important sequence of numbers, such as bank account, taxpayer number, etc.

Multiply each number in the sequence of numbers by the value called weight in specified algorithm. Figure out a sum of these numbers, and divide it by specified modulus. Then,

• DR checkdigit ... this remainder.
• DSR checkdigit ... subtract this remainder from modulus.
Checkdigit is a great help to us for avoiding forgery, misreading, etc.

In the process of printing the barcode, bars sometimes get thick or thin illegally. Checkdigit is indispensable to avoid misreading caused by these errors. That is, when the sequence of numbers written in the barcode doesn't match with the checkdigit we had read, the computer refuses the sequence of numbers to input.

Barcode does/doesn't need the checkdigit by its type;

• always needs checkdigit: (eg. JAN/EAN, CODE-93, CODE-128, etc.),
• doesn't always need: (eg. CODE-39, NW-7, ITF, etc.)

Some of them can choose the algorithm of the checkdigit. Some data indicates that addition of checkdigit might decrease the misreading ratio under 1/1000.

We'll take an example, frequently employed JAN(EAN) barcode (Modulus 10, Weight 3:1) and illustrate the relation of weight, modulus, etc.

 sequence 4 9 0 1 2 3 4 5 6 7 8 9 x x x x x x x x x x x x weight 1 3 1 3 1 3 1 3 1 3 1 3 sum 4 +27 +0 +3 +2 +9 +4 +15 +6 +21 +8 +27 =126 126 (sum) / 10 (modulus) = 12, remains 6 10 - 6 (remainder) = 4 (check digit)

Moreover, dividing directly the sequence of numbers with the modulus, then

• the remainder is the checkdigit of the type 7DR and 9DR; or
• (modulus - remainder) is the type 7DSR and 9DSR.

There are many type of checkdigit we cannot display here at once.
In detail, see "Barcode Haya-wakari (A Quick Guide to a Barcode)".

Back