# International Standard Book Number | check digits

## Check digits

A check digit is a form of redundancy check used for error detection, the decimal equivalent of a binary check bit. It consists of a single digit computed from the other digits in the number. The method for the ten-digit code is an extension of that for SBNs, the two systems are compatible, and SBN prefixed with "0" will give the same check-digit as without – the digit is base eleven, and can be 0-9 or X. The system for thirteen-digit codes is not compatible and will, in general, give a different check digit from the corresponding 10-digit ISBN, and does not provide the same protection against transposition. This is because the thirteen-digit code was required to be compatible with the EAN format, and hence could not contain an "X".

### ISBN-10 check digits

According to the 2001 edition of the official manual of the International ISBN Agency,[43] the ISBN-10 check digit[44] – which is the last digit of the ten-digit ISBN – must range from 0 to 10 (the symbol X is used for 10), and must be such that the sum of all the ten digits, each multiplied by its (integer) weight, descending from 10 to 1, is a multiple of 11.

For example, for an ISBN-10 of 0-306-40615-2:

{\displaystyle {\begin{aligned}s&=(0\times 10)+(3\times 9)+(0\times 8)+(6\times 7)+(4\times 6)+(0\times 5)+(6\times 4)+(1\times 3)+(5\times 2)+(2\times 1)\\&=0+27+0+42+24+0+24+3+10+2\\&=132=12\times 11\end{aligned}}}

Formally, using modular arithmetic, this is rendered:

${\displaystyle (10x_{1}+9x_{2}+8x_{3}+7x_{4}+6x_{5}+5x_{6}+4x_{7}+3x_{8}+2x_{9}+x_{10})\equiv 0{\pmod {11}}.}$

It is also true for ISBN-10's that the sum of all the ten digits, each multiplied by its weight in ascending order from 1 to 10, is a multiple of 11. For this example:

{\displaystyle {\begin{aligned}s&=(0\times 1)+(3\times 2)+(0\times 3)+(6\times 4)+(4\times 5)+(0\times 6)+(6\times 7)+(1\times 8)+(5\times 9)+(2\times 10)\\&=0+6+0+24+20+0+42+8+45+20\\&=165=15\times 11\end{aligned}}}

Formally, this is rendered:

${\displaystyle (x_{1}+2x_{2}+3x_{3}+4x_{4}+5x_{5}+6x_{6}+7x_{7}+8x_{8}+9x_{9}+10x_{10})\equiv 0{\pmod {11}}.}$

The two most common errors in handling an ISBN (e.g., typing or writing it) are a single altered digit or the transposition of adjacent digits. It can be proven that all possible valid ISBN-10s have at least two digits different from each other. It can also be proven that there are no pairs of valid ISBN-10s with eight identical digits and two transposed digits. (These are true only because the ISBN is less than 11 digits long, and because 11 is a prime number.) The ISBN check-digit method therefore ensures that it will always be possible to detect these two most common types of error, i.e., if either of these types of error has occurred, the result will never be a valid ISBN – the sum of the digits multiplied by their weights will never be a multiple of 11. However, if the error occurs in the publishing house and goes undetected, the book will be issued with an invalid ISBN.[45]

In contrast, it is possible for other types of error, such as two altered non-transposed digits, or three altered digits, to result in a valid ISBN (although it is still unlikely).

### ISBN-10 check digit calculation

Each of the first nine digits of the ten-digit ISBN—excluding the check digit itself—is multiplied by its (integer) weight, descending from 10 to 2, and the sum of these nine products found. The value of the check digit is simply the one number between 0 and 10 which, when added to this sum, means the total is a multiple of 11.

For example, the check digit for an ISBN-10 of 0-306-40615-? is calculated as follows:

{\displaystyle {\begin{aligned}s&=(0\times 10)+(3\times 9)+(0\times 8)+(6\times 7)+(4\times 6)+(0\times 5)+(6\times 4)+(1\times 3)+(5\times 2)\\&=130\end{aligned}}}

Adding 2 to 130 gives a multiple of 11 (132 = 12 x 11) − this is the only number between 0 and 10 which does so. Therefore, the check digit has to be 2, and the complete sequence is ISBN 0-306-40615-2. The value ${\displaystyle x_{10}}$ required to satisfy this condition might be 10; if so, an 'X' should be used.

Alternatively, modular arithmetic is convenient for calculating the check digit using modulus 11. The remainder of this sum when it is divided by 11 (i.e. its value modulo 11), is computed. This remainder plus the check digit must equal either 0 or 11. Therefore, the check digit is (11 minus the remainder of the sum of the products modulo 11) modulo 11. Taking the remainder modulo 11 a second time accounts for the possibility that the first remainder is 0. Without the second modulo operation the calculation could end up with 11 – 0 = 11 which is invalid. (Strictly speaking the first "modulo 11" is unneeded, but it may be considered to simplify the calculation.)

For example, the check digit for the ISBN-10 of 0-306-40615-? is calculated as follows:

{\displaystyle {\begin{aligned}s&=(11-(((0\times 10)+(3\times 9)+(0\times 8)+(6\times 7)+(4\times 6)+(0\times 5)+(6\times 4)+(1\times 3)+(5\times 2))\,{\bmod {\,}}11)\,{\bmod {\,}}11\\&=(11-(0+27+0+42+24+0+24+3+10)\,{\bmod {\,}}11)\,{\bmod {\,}}11\\&=(11-(130\,{\bmod {\,}}11))\,{\bmod {\,}}11\\&=(11-(9))\,{\bmod {\,}}11\\&=(2)\,{\bmod {\,}}11\\&=2\end{aligned}}}

Thus the check digit is 2.

It is possible to avoid the multiplications in a software implementation by using two accumulators. Repeatedly adding t into s computes the necessary multiples:

// Returns ISBN error syndrome, zero for a valid ISBN, non-zero for an invalid one.
// digits[i] must be between 0 and 10.
int CheckISBN(int const digits[10])
{
int i, s = 0, t = 0;

for (i = 0; i < 10; i++) {
t += digits[i];
s += t;
}
return s % 11;
}


The modular reduction can be done once at the end, as shown above (in which case s could hold a value as large as 496, for the invalid ISBN 99999-999-9-X), or s and t could be reduced by a conditional subtract after each addition.

### ISBN-13 check digit calculation

The 2005 edition of the International ISBN Agency's official manual[46] describes how the 13-digit ISBN check digit is calculated. The ISBN-13 check digit, which is the last digit of the ISBN, must range from 0 to 9 and must be such that the sum of all the thirteen digits, each multiplied by its (integer) weight, alternating between 1 and 3, is a multiple of 10.

Formally, using modular arithmetic, this is rendered:

${\displaystyle (x_{1}+3x_{2}+x_{3}+3x_{4}+x_{5}+3x_{6}+x_{7}+3x_{8}+x_{9}+3x_{10}+x_{11}+3x_{12}+x_{13})\equiv 0{\pmod {10}}.}$

The calculation of an ISBN-13 check digit begins with the first 12 digits of the thirteen-digit ISBN (thus excluding the check digit itself). Each digit, from left to right, is alternately multiplied by 1 or 3, then those products are summed modulo 10 to give a value ranging from 0 to 9. Subtracted from 10, that leaves a result from 1 to 10. A zero (0) replaces a ten (10), so, in all cases, a single check digit results.

For example, the ISBN-13 check digit of 978-0-306-40615-? is calculated as follows:

s = 9×1 + 7×3 + 8×1 + 0×3 + 3×1 + 0×3 + 6×1 + 4×3 + 0×1 + 6×3 + 1×1 + 5×3
=   9 +  21 +   8 +   0 +   3 +   0 +   6 +  12 +   0 +  18 +   1 +  15
= 93
93 / 10 = 9 remainder 3
10 –  3 = 7


Thus, the check digit is 7, and the complete sequence is ISBN 978-0-306-40615-7.

In general, the ISBN-13 check digit is calculated as follows.

Let

${\displaystyle r={\big (}10-{\big (}x_{1}+3x_{2}+x_{3}+3x_{4}+\cdots +x_{11}+3x_{12}{\big )}\,{\bmod {\,}}10{\big )}.}$

Then

${\displaystyle x_{13}={\begin{cases}r&{\text{ ; }}r<10\\0&{\text{ ; }}r=10.\end{cases}}}$

This check system – similar to the UPC check digit formula – does not catch all errors of adjacent digit transposition. Specifically, if the difference between two adjacent digits is 5, the check digit will not catch their transposition. For instance, the above example allows this situation with the 6 followed by a 1. The correct order contributes 3×6+1×1 = 19 to the sum; while, if the digits are transposed (1 followed by a 6), the contribution of those two digits will be 3×1+1×6 = 9. However, 19 and 9 are congruent modulo 10, and so produce the same, final result: both ISBNs will have a check digit of 7. The ISBN-10 formula uses the prime modulus 11 which avoids this blind spot, but requires more than the digits 0-9 to express the check digit.

Additionally, if the sum of the 2nd, 4th, 6th, 8th, 10th, and 12th digits is tripled then added to the remaining digits (1st, 3rd, 5th, 7th, 9th, 11th, and 13th), the total will always be divisible by 10 (i.e., end in 0).

### ISBN-10 to ISBN-13 conversion

An ISBN-10 is converted to ISBN-13 by prepending "978" to the ISBN-13 and calculating the new checksum using the ISBN-13 algorithm. The reverse process can also be performed, but not for numbers commencing other than 978, which have no 10 digit equivalent.

### Errors in usage

Publishers and libraries have varied policies about the use of the ISBN check digit. Publishers sometimes fail to check the correspondence of a book title and its ISBN before publishing it; that failure causes book identification problems for libraries, booksellers, and readers.[47] For example, ISBN 0-590-76484-5 is shared by two books – Ninja gaiden®: a novel based on the best-selling game by Tecmo (1990) and Wacky laws (1997), both published by Scholastic.

Most libraries and booksellers display the book record for an invalid ISBN issued by the publisher. The Library of Congress catalogue contains books published with invalid ISBNs, which it usually tags with the phrase "Cancelled ISBN".[48] However, book-ordering systems such as Amazon.com will not search for a book if an invalid ISBN is entered to its search engine.[citation needed] OCLC often indexes by invalid ISBNs, if the book is indexed in that way by a member library.

### eISBN

Only the term "ISBN" should be used; the terms "eISBN" and "e-ISBN" have historically been sources of confusion and should be avoided. If a book exists in one or more digital (e-book) formats, each of those formats must have its own ISBN. In other words, each of the three separate EPUB, Amazon Kindle, and PDF formats of a particular book will have its own specific ISBN. They should not share the ISBN of the paper version, and there is no generic "eISBN" which encompasses all the e-book formats for a title.[49]

Other Languages
Afrikaans: ISBN
asturianu: ISBN
Avañe'ẽ: ISBN
azərbaycanca: ISBN
Bân-lâm-gú: ISBN
беларуская (тарашкевіца)‎: Міжнародны стандартны кніжны нумар
भोजपुरी: आइएसबीएन
brezhoneg: ISBN
català: ISBN
español: ISBN
Esperanto: ISBN
føroyskt: ISBN
Frysk: ISBN
galego: ISBN
Ido: ISBN
íslenska: ISBN
italiano: ISBN
עברית: מסת"ב
Basa Jawa: ISBN
қазақша: ISBN
kurdî: ISBN
latviešu: ISBN
Lëtzebuergesch: ISBN
lietuvių: ISBN
lumbaart: ISBN
magyar: ISBN
मैथिली: आइएसबिएन
македонски: ISBN
مازِرونی: شابک
မြန်မာဘာသာ: International Standard Book Number
नेपाली: आइएसबिएन

norsk: ISBN
norsk nynorsk: ISBN
occitan: ISBN
русиньскый: ISBN
shqip: ISBN
srpskohrvatski / српскохрватски: ISBN
suomi: ISBN
svenska: ISBN
తెలుగు: ISBN
українська: ISBN
Tiếng Việt: ISBN
Winaray: ISBN
ייִדיש: ISBN
Yorùbá: ISBN