Tool for decoding/encoding numbers via the Stibitz code also called Excess-3, a binary digital system similar to the BCD code, used by old processors coding each digit on 4 bits.

Excess-3 Code (Stibitz) - dCode

Tag(s) : Character Encoding

dCode is free and its tools are a valuable help in games, maths, geocaching, puzzles and problems to solve every day!

A suggestion ? a feedback ? a bug ? an idea ? *Write to dCode*!

Tool for decoding/encoding numbers via the Stibitz code also called Excess-3, a binary digital system similar to the BCD code, used by old processors coding each digit on 4 bits.

The code **Excess-3** (also called **Stibitz** code and sometimes shortcut XS3 or XS-3) is a 4-bit binary decimal code (like the BCD) created to optimize some calculations in base 10 on older processors.

The representation of a number in **Excess-3** code is said to be biased because it has an offset of 3 (hence the 3 of XS-3) with the expected values and used by the conventional BCD code.

__Example:__ 0 is coded 0011 in XS-3 whereas 0011 is 3 in BCD code.

The use of this offset allows a quick calculation trick for the complement to 9 (decimal) by inverting the bits, which is a big time saver for the calculation of subtractions by the processors.

__Example:__ The digit 0 is coded 0011 in XS3 and its binary complement (inverting the 1's and 0's) is 1100 which corresponds to 9 in XS3.

The Decimal to **Excess-3** conversion table:

Digit | Code XS-3 |
---|---|

0 | 0011 |

1 | 0100 |

2 | 0101 |

3 | 0110 |

4 | 0111 |

5 | 1000 |

6 | 1001 |

7 | 1010 |

8 | 1011 |

9 | 1100 |

__Example:__ 123 is coded 0100,0101,0110

The codes 0000 or 1111 are not used to represent numbers, which can be interesting in the sending of communication (the sequences of 0 and 1 are often representative of reading errors)

Split the binary number into groups of 4 bits and replace each group with the corresponding number in the conversion table (above).

__Example:__ 11001011 is split 1100,1011 and corresponds respectively to the numbers 9,8, so the conversion into decimal is 98

The code has a binary representation, it is not really distinguishable from another binary code (BCD, Gray, etc.) apart from its particularity to avoid sequences of more than 7 0000000 or 1111111.

Any reference to the old processors, calculators or electronic cash machine of the 70s is a clue.

George **Stibitz** created a calculating machine based on this principle in 1937.

dCode retains ownership of the online 'Excess-3 Code (Stibitz)' tool source code. Except explicit open source licence (indicated CC / Creative Commons / free), any algorithm, applet or snippet (converter, solver, encryption / decryption, encoding / decoding, ciphering / deciphering, translator), or any function (convert, solve, decrypt / encrypt, decipher / cipher, decode / encode, translate) written in any informatic language (PHP, Java, C#, Python, Javascript, Matlab, etc.) no data, script or API access will be for free, same for Excess-3 Code (Stibitz) download for offline use on PC, tablet, iPhone or Android !

Please, check our community Discord for help requests!

excess,xs,3,code,stibitz,binary

Source : https://www.dcode.fr/excess-3-code

© 2021 dCode — The ultimate 'toolkit' to solve every games / riddles / geocaching / CTF.

Feedback

▲