What is Positional Notation & Numeral Base Systems?
Mathematical Foundation
Laws & Principles
- Why Hexadecimal Exists: A single byte (8 bits) requires 8 binary digits, which is too verbose to read quickly (e.g., 10101111). Hexadecimal uses digits 0-9 and letters A-F to pack 4 bits into a single character. That same 8-bit byte becomes just two hex characters (AF), making memory addresses, color codes, and IPv6 drastically more readable.
- The Nibble Rule: Because 16 = 2⁴, each solitary hexadecimal digit maps perfectly to exactly 4 binary bits (a 'nibble'). This means hex-to-binary conversion requires no arithmetic—you simply look up each hex digit independently in a table and string the bits together.
- Leading Zeros: In all numeral systems, leading zeros on the far left do not change the mathematical value of the number (00F = F). However, in computer science, leading zeros are often kept to denote the fixed width of a register (e.g., a 16-bit register showing 0x00A3).
Step-by-Step Example Walkthrough
" Converting the hexadecimal memory address 1A3F to standard human decimal. "
- 1. Identify the 4 hex digits from left to right: 1, A (10), 3, F (15).
- 2. Assign positional weights from right to left (index 0 to 3): 16³, 16², 16¹, 16⁰.
- 3. Multiply digit 3: 1 × 16³ = 1 × 4096 = 4096.
- 4. Multiply digit 2: A(10) × 16² = 10 × 256 = 2560.
- 5. Multiply digit 1: 3 × 16¹ = 3 × 16 = 48.
- 6. Multiply digit 0: F(15) × 16⁰ = 15 × 1 = 15.
- 7. Sum the results: 4096 + 2560 + 48 + 15 = 6719.