Luhn algorithm,luhn algorithm check calculator
https://hash.onlinetoolsland.com/luhn...
The Luhn algorithm is also called the Luhn formula,and it is also known as "mod 10" algorithm or the "modulus 10",
The Luhn algorithm is a simple checksum function used to check and validate many kinds of identification numbers, such as IMEI numbers, credit card and National Provider Identifier numbers in Canadian Social Insurance Numbers, Greek Social Security Numbers USA National Provider Identifier numbers and Israel ID Numbers.
The Luhn algorithm is invented by Hans Peter Luhn who was an IBM scientist
He made the Luhn algorithm a , filed on January 6, 1954, and granted on August 23, 1960.
The Luhn algorithm is in the public domain and the algorithm is in wide use. but this Luhn algorithm is not a cryptographically secure hash function;the Luhn algorithm was made to guard against accidental errors, not malicious attacks.
Many government identification numbers and credit cards companies use the algorithm as method to distinguish valid numbers from mistyped or otherwise incorrect numbers.
The Luhn algorithm detail
The Luhn algorithm check a number against its included check digit, and it is usually appended to a partial check number to get the full account number. This number must pass the test below:
1 From the rightmost digit, which is the check digit, and moving left, double the value of every second digit. The check digit is not doubled, the first digit doubled is immediately to the left of the check digit.
luhn algorithm check calculator
you can also use the same checksum creation algorithm, ignoring the checksum already in place as if it had not yet been calculated. And Then calculate the checksum and compare this calculated checksum to the original checksum included with the number. If the included checksum matches the calculated checksum, then the number is valid.
Advantage and disadvantage of Luhn algorithm
The Luhn algorithm will find any single-digit error, as well as almost all transpositions of adjacent digits. It will not, however, detect transposition of the two-digit sequence 09 to 90 (or vice versa). It will detect 7 of the 10 possible twin errors (it will not detect 22 ? 55, 33 ? 66 or 44 ? 77).
There are other more complex check-digit algorithms for example the Verhoeff algorithm and the Damm algorithm ,which can detect more transcription errors. The Luhn mod N algorithm is an extension which can be used on non-numerical strings.
the algorithm can work on the digits in a right-to-left manner and zero digits affect the result only if they cause shift in position, zero-padding the beginning of a string of numbers does not affect the calculation.so systems that pad to a specific number of digits could use Luhn validation before or after the padding and get the same result.
Prepending a 0 to odd-length numbers makes it possible to calculate the number from left to right rather than right to left, doubling the odd-place digits.
The Luhn algorithm first appear in a US Patent[2] for a hand-held, mechanical device for calculate the checksum. It was quite simple. The equipment took the mod 10 sum by mechanical means. The substitution digits, that is, the results of the double and reduce procedure, were not produced mechanically. Rather, the digits were marked in their permuted order on the body of the machine,luhn algorithm check calculator.
https://hash.onlinetoolsland.com/luhn...
Информация по комментариям в разработке