Skip to main content
Check Digit Calculator
Core

Custom Modulus Calculator

Explore check digits with a chosen modulus and weight pattern. Follow the input rules, weighted sum and output mapping in an example.

Last updated:

Core Algorithms & Modulus

Specify modulus, weights, and output rules.

Length: 10 chars
Calculated Check Character / Checksum
--Ready
Complete Validated Sequence:
--
Arithmetic Steps & Mathematical Specification

Initialising algorithm engine for Custom Modulus Calculator...

How Custom Modulus Calculator Works?

The Custom Modulus Calculator works by applying a user-chosen modulus, weight list, direction, and output rule to any numeric payload. The tool reproduces most weighted check digit schemes without code.

  1. 1Choose the modulus m (for example 7, 10, 11, 23, 31, 37, 43, 89, or 97).
  2. 2Enter the weight list and choose left-to-right or right-to-left application.
  3. 3Choose the product rule: plain product or digit-sum of the product (Luhn style).
  4. 4Choose the output rule: remainder r, complement m − r, or (m − r) mod m.
  5. 5Map output values above 9 to letters or symbols with a character table.

Custom Modulus Calculator Formula

The Custom Modulus formula is Check = g( Σ h(dᵢ × wᵢ) mod m ), where h is the product rule and g is the output rule.

S = Σ h(dᵢ × wᵢ)
r = S mod m   (CUSTOM MODULUS)
Check = g(r) ∈ { r,  m − r,  (m − r) mod m }  → mapped through the character table
  • m is the modulus.
  • h is identity or digit-sum.
  • g is the output rule.
  • wᵢ is the weight for digit i.
Worked example: 1234567890, m = 11, weights 2–7 from the right, g = (11 − r) mod 11
S = 195
r = 8
Check = 3

Custom Modulus Calculator Conversion Table

The Custom Modulus conversion table lists the parameter sets that reproduce well-known schemes.

SchemeModulusWeightsDirectionOutput rule
GS1 GTIN103, 1Right(10 − r) mod 10
Luhn102, 1 + digit-sumRight(10 − r) mod 10
ISBN-101110…2Left(11 − r) mod 11, 10 = X
ABA routing103, 7, 1Left(10 − r) mod 10
NHS number1110…2Left11 − r, 11 = 0, 10 invalid
Spanish NIF23none—r → letter table
Finnish HETU31none—r → 31-character table
Code 39431—r → Code 39 set
ABN8910, 1, 3…19Leftvalid when r = 0
IBAN97ISO 7064Left98 − r

What is Custom Modulus Calculator?

A Custom Modulus Calculator is a general check digit engine where the user defines the modulus, weights, and output mapping. The tool suits schemes that no dedicated calculator covers.

Most check digit schemes differ in 4 parameters: modulus, weights, direction, and output mapping. Setting those 4 values reproduces the scheme exactly.

What are the uses of Custom Modulus Calculator?

There are 4 main uses of the Custom Modulus Calculator, including in-house schemes, legacy data, and teaching.

  • In-house identifier schemes: Companies check proprietary part or member numbers.
  • Legacy data recovery: Analysts test parameter sets until historic records validate.
  • Specification testing: Engineers confirm a written specification before writing code.
  • Teaching modular arithmetic: Teachers show how each parameter changes the result.