Casting out nines
Casting out elevens
Improved checksum
Credit card
Verhoeff

Checksum calculator simulations

For more information on these and other machines, see my Calculating History site.

Select one of the tabs

Malý's device for casting out nines.

“Casting out nines” is a method to check simple calculations by deriving a checksum.
To check C = A + B, or C = AB, or C = A × B, or C = A / B:
• Reset the device: the square hole should show a nine*.
• Dial in the separate digits of A. Always turn the dial anti-clockwise.
• Write down the resulting control digit rA that is shown in the square hole.
• Reset the device: the square hole should show a nine.
• Dial in the separate digits of B.
• Write down the resulting control digit rB that is shown in the square hole.
• Reset the device: the square hole should show a nine
• Dial in the separate digits of C.
• Write down the resulting control digit rC that is shown in the square hole.
• Reset the device
• If you are checking the summation C = A + B, then you should find rC = rA + rB. If rA + rB is larger than 9, subtract 9.
If you are checking the subtraction C = AB, then you should find rC = rArB If rArB is less than zero, add 9.
If you are checking the multiplication C = A × B, then you should find rC = rA × rB
If rA×rB is larger than 9, you can dial in the result in the device to get a control digit between 1 and 9 which should be equal to rC.
If you are checking the division C = A / B with remainder R, you should also derive the control digit rR and find rC × rB = rA − rR.

Reumhelm Controlex

A device for casting out elevens.
To check C = A + B, or C = AB, or C = A × B, or C = A / B:
• Reset the device: the small hole should show a zero and numbers should be visible in the inner lower half circle.
• Dial in the separate digits of A, from right to left. Always dial in the direction of the arrow.
• first digit in the inner lower half circle
• second digit in the outer lower half circle
• third digit in the inner lower half circle
• and so on...
• Write down the resulting control digit rA that is shown in the small hole in the upper half of the device. ('X' indicates 10)
• Reset the device: the small hole should show a zero, and numbers should be visible in the inner lower half circle.
• Dial in the separate digits of B, from right to left.
• Write down the resulting control digit rB that is shown in the small hole in the upper half of the device.
• Reset the device: the small hole should show a zero, and numbers should be visible in the inner lower half circle
• Dial in the separate digits of C, from right to left.
• Write down the resulting control digit rC that is shown in the small hole in the upper half of the device.
• Reset the device
• If you are checking the summation C = A + B, then you should find rC = rA + rB. The upper half of the device can be used for the summation of rA and rB.
If you are checking the subtraction C = AB, then you should find rC = rArB The upper half of the device can be used for the subtration of rA and rB, but remember to dial rB in the opposite direction.
If you are checking the multiplication C = A × B, then you should find rC = rA × rB
If rA × rB is larger than 10, you can dial in the result in the lower half of the device to get a control digit between 0 and 10 which should be equal to rC.
If you are checking the division C = A / B with remainder R, you should also derive the control digit rR and find rC × rB = rArR.

Improved check sum calculator

A general formula for checksums is
 nΣi=1 wi ai = 0 mod p
 where ai = i th digit of the number a wi = i th weight (integer) p  = an integer
For a specific application, wi and p can be choosen to best detect errors that are often occurring in that application.
Different wi's for each i and a prime number p are a good start.
Alfred Henry Fielding Richardson, from New Barnet, Hertfordshire, UK, proposed an algorithm for account numbers with a complicated weighting scheme, and p = 11
 3a1 + 6a2 + 8a3 + 5a4 + 7a5 + 10a6 + 2a7 + 4a8 + 9a9 + a10 = 0 mod 11

a10 is shown in the small window at the top left.
Because p = 11, it is possible that a10 = 10, which is indicated by an 'A'.

Use:
• make sure the small window shows “0”, eventually drag a hole in a random sector until you see the “0”
• choose the sector “1st digit”
• locate the hole near value of the 1st digit in this sector
• drag the hole clockwise to the edge of the sector
• choose, for the next digit, the next sector
• locate the hole near value of the digit in this sector
• drag the hole clockwise to the edge of the sector
• and so on
• Finally, the value of a1 is shown in the small window.

Pure Oil Company credit card number calculator

Credit card numbers obey a checksum invented by Hans P. Luhn, of IBM.
For the digits ai of a number a, with a1 being the right-most digit.
 12Σi=1 { i is odd:    ai   i  is even: 2ai mod 9 } = 0 mod 10
IBM patented a device for computing the checksum.
A much simpler device was invented by Leonard C. Zitnik, for the Pure Oil Company. Oil companies were early credit card issuers, for easy payment in their gasoline stations.
• put the pointer of the disk at the red triangle
• black numbers are visible through the holes of the disk
• start with the left-most digit of the credit card number, and work to the right
• for each digit:
• locate the digit in a hole
• drag the hole clockwise until it hits the triangle of the same color as the number
• the color of the numbers visible through the holes has changed
• Remember: credit card numbers have 12 digits, so the left-most is even (black) and the right-most is odd (red).
Try 4408 0412 3456 7890, if the credit card number is correct, the procedure ends with the disk pointer at the red triangle. 