**luhn**,
a MATLAB code which
demonstrates the calculation and use of the Luhn check digit for
error detection.

The computer code and data files described and made available on this web page are distributed under the GNU LGPL license.

**luhn** is available in
a C version and
a C++ version and
a FORTRAN90 version and
a MATLAB version and
a Python version.

bank, a MATLAB code which can compute the check digit associated with a US Bank Routing Number check digit, or it can report whether a 9-digit code is actually valid.

isbn, a MATLAB code which can determine the check digit for an International Standard Book Number or report whether a given ISBN is valid.

upc, a MATLAB code which can determine the check digit for a Uniform Product Code (UPC) or report whether a given UPC is valid.

- ch_is_digit.m, is TRUE if a character is a decimal digit.
- ch_to_digit.m, returns the value of a base 10 digit.
- i4vec_print.m, prints an I4VEC.
- luhn_check_digit_calculate.m, determines the Luhn check digit of a string.
- luhn_checksum.m, determines the Luhn checksum of a string.
- luhn_is_valid.m, determines whether a string with Luhn check digit is valid.
- s_digits_count.m, counts the digits in a string.
- s_to_digits.m, extracts N digits from a string.