BNS Test - Bense Number System

Bense Number System - Lexikographisch sortierbare Zahlenkodierung

Input
Hint:
• Enter a number in "nbr" → "bns_nbr" will be calculated with BNS_encode
• Enter a BNS string in "bns_nbr" → "nbr" will be calculated with BNS_decode
• "verify" shows the original value after back conversion
• Extreme values: Largest BNS number (7y999...) → 9 (plus infinity), smallest → 0 (minus infinity)
All 256 Hex Ranges (00-FF) with Random Numbers:

Key Features

  • Lexicographic Sorting: BNS numbers can be sorted with simple string comparison
  • Unlimited Precision: Supports numbers with any number of digits through string arithmetic
  • 256 Intervals: The number range from -∞ to +∞ is divided into 256 hex ranges (00-FF)
  • Exact Encoding/Decoding: Every number is encoded and decoded exactly without rounding errors
  • String-based Arithmetic: All calculations use string operations for high precision
Intervals:
• I1: (-∞, -1) → 00-3F
• I2: (-1, 0) → 40-7F
• I3: (0, 1) → 80-BF
• I4: (1, ∞) → C0-FF

Extreme Values:
• ∞ → FF
• -∞ → 00

User Manual

  1. Encode Number: Enter a number in the "Number (nbr)" field. The BNS number will be calculated automatically.
  2. Decode BNS Number: Enter a BNS number in the "BNS-String (bns_nbr)" field. The original number will be calculated automatically.
  3. Verification: The "Verify" field shows the original value after back conversion. A green checkmark (✓) means the encoding/decoding was correct.
  4. Interval: The "Interval" field shows the hex value (00-FF) that indicates the magnitude of the number.
  5. Table: The table shows all 256 hex ranges with randomly generated numbers and their BNS encoding.
  6. Statistics: The statistics show how many numbers were encoded/decoded correctly.