Rini Article Number

The Rini Article Number (RAN) is a system of identifiers that identify a group of players, such as Pokemon Go and Fortnite, who contribute to the Chibiusa Contributor Database.

Rini-13
Rini-13 is a 13-digit identifier that identifies Pokemon Go players contributed to Chibiusa Contributor Database. It consists of two elements (trainer code and check digit).

To create a Rini-13 number, the Trainer Code is inserted as the first twelve digits of Rini-13, and suffixing Rini-13 with a check digit at the end according to the rules below.

Rini-18
Rini-18 is an 18-digit identifier that identifies Fortnite players contributed to Chibiusa Contributor Database. Unlike Rini-13, Rini-18 consists of three zeroes, a local operation element (a number between 10000 and 99999), work element (between 000000100 and 999999999) and a check digit.

Check digit
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.

In Rini-13, the checksum is the last digit and is calculated as a sum of products - taking an alternating weight value (3 or 1) times the value of each data digit. The checksum digit is the digit, which must be added to this checksum to get a number divisible by 10 (i.e. the additive inverse of the checksum, modulo 10).

Calculation examples
For the Rini-13 code 611582151570x (from Pokemon Go trainer code 6115 8215 1570), where x is the check digit, the calculation is perfomed as:


 * {| class="wikitable" style="text-align: center"

!position !trainer code !weight !partial sum !sum
 * 12||11||10||9||8||7||6||5||4||3||2||1
 * 6||1||1||5||8||2||1||5||1||5||7||0
 * 1||3||1||3||1||3||1||3||1||3||1||3
 * 6||3||1||15||8||6||1||15||1||15||7||0
 * || || || || || || || || || || ||78
 * } The nearest multiple of 10 that is equal to or higher than the sum, is 80. Subtract them: 80 - 78 = 2, which is the check digit x of Rini-13.

For the Rini-13 code 473435478887x (from Pokemon Go trainer code 4734 3547 8887), where x is the check digit, the calculation is perfomed as:


 * {| class="wikitable" style="text-align: center"

!position !trainer code !weight !partial sum !sum
 * 12||11||10||9||8||7||6||5||4||3||2||1
 * 4||7||3||4||3||5||4||7||8||8||8||7
 * 1||3||1||3||1||3||1||3||1||3||1||3
 * 4||21||3||12||3||15||4||21||8||24||8||21
 * || || || || || || || || || || ||144
 * } The nearest multiple of 10 that is equal to or higher than the sum, is 150. Subtract them: 150 - 144 = 6, which is the check digit x of Rini-13.

In Rini-18 numbers, the check digit is calculated as MOD 11-2 of ISO 7064 standard. For the Rini-18 code 00025864317489689, where x is the check digit, the calculation is perfomed as:


 * {| class="wikitable" style="text-align: center"

!position !Rini-18 partial !sum
 * 17||16||15||14||13||12||11||10||9||8||7||6
 * 5
 * 4
 * 3
 * 2
 * 1
 * 0||0||0||2||5||8||6||4||3||1||7||4
 * 8
 * 9
 * 6
 * 8
 * 9
 * 0||0||0||4||18||52||116||240||486||974||1962||3932
 * 7880
 * 15778
 * 31568
 * 63152
 * 126322
 * } Dividing 126322 by 11 gives 11483 with a remainder of 9 (126322 ÷ 11 = 11483 R 9). Subtracting the remainder from 11 gives the check digit of 2 (11 - 9 = 2).
 * NOTE: If the calculation returns 10 then the number 10 is replaced by an 'X'.