1

199917310179
199957410250
199935910137
200025902253
199960710304
199836610072
199904610305
199911310180
199957710108
199957510123

The above are numbers which the ending number is a check digit for the entire number (apart from the last digit obviously)

I want to know which check digit algorithm is used to calculate this checksum I used Luhn algorithm (1954), Verhoeff algorithm (1969) and the Damm algorithm (2004) with no luck, they create check digits but not the one already shown here

I am confident that these are valid number for the check digit, it's just that I don't know what the algorithm, can anyone help or give some pointers

  • 1
    Are they from barcodes ? If yes, can you show one ? –  Apr 29 '19 at 09:12
  • they are not from bar codes, they are from the national identity card of Sri Lanka, which has not published how they generate the check digit – Miyuru Dharmage May 05 '19 at 06:23
  • At least try one of these, or variations: https://en.wikipedia.org/wiki/International_Standard_Book_Number. Sri Lanka might have taken inspiration there. –  May 05 '19 at 07:10
  • I posted the question after these test algo including the ISBN, IBAN among others including the raw modulo 10 and other variation, my question is there a way to reverse the formula or are there any good pattern identification formulas – Miyuru Dharmage May 05 '19 at 08:57
  • 1
    Sorry.

    Reversing the formula doesn't seem possible, as the checksum function performs a strong compression, from eleven digits to a single.

    A pattern could be easier to spot if you could change a single digit at a time.

    –  May 05 '19 at 09:47
  • so what are the suggestions that you have on finding, any pointers or directions i can take on cracking this problem – Miyuru Dharmage May 05 '19 at 10:13
  • Give us consecutive numbers. –  May 05 '19 at 13:25
  • I would not know how to give consecutive numbers the format you see here is as follows first four digits year next three digits day from beginning of year | if you are female 500 gets added to the number the remaining numbers are a birth certificate id, but the last is a check digits to prevent human errors etc, I need to know the formula inorder to ensure consistency – Miyuru Dharmage May 07 '19 at 07:18
  • @MiyuruDharmage have you find the algorithm? – Sankha Karunasekara Apr 25 '20 at 13:37
  • no i have not, and i gave up on it – Miyuru Dharmage Sep 23 '20 at 05:58

0 Answers0