Related Concepts: 1.02 Base Complements & Subtraction Mechanics | 1.03 Signed Representation, Overflow & Two’s Complement | 2.01 BCD & Weighted Digital Codes

1.01 Positional Number Systems & Base Conversions

Overview

Digital systems process data in binary (), but human interfaces use decimal (). Practical interfaces also employ octal () and hexadecimal () to condense long binary strings. Understanding the mathematical foundations of positional notation and conversion algorithms is essential for digital logic design.


1. Positional Radix Number Theory

A positional number system represents numbers by a sequence of digits. The position of each digit determines its weight, which is a power of the base (or radix) .

1.1 The Positional Expansion Theorem

Mathematical Definition

Any real number in a base positional number system is represented as:

Where:

  • The dot () represents the radix point (decimal point in base 10, binary point in base 2).
  • is the number of integer digits, and is the number of fractional digits.
  • The digits/coefficients must satisfy:

The quantitative decimal value of is obtained by summing each digit multiplied by its position weight:

For example, in decimal (), digits are . In binary (), digits are strictly . In hexadecimal (), the alphanumeric symbols represent decimal values .


2. Base Conversion Mechanics (Pencil-and-Paper Tutorial)

When converting numbers from decimal (base 10) to a target base , the conversion is split into two distinct algorithms for the integer and fractional components.

graph TD
    Input["Decimal Number N"] --> Split{"Split into Components"}
    
    Split -->|Integer Component| IntDiv["Successive Division by Base r"]
    IntDiv --> CollectRem["Collect Remainders Bottom to Top (MSB to LSB)"]
    
    Split -->|Fractional Component| FracMult["Successive Multiplication by Base r"]
    FracMult --> CollectInt["Collect Integer Carries Top to Bottom (MSB to LSB)"]
    
    CollectRem & CollectInt --> Combine["Combined Base-r Result"]

Part A: Converting Integers (Successive Division Method)

To convert a decimal integer to a target base :

  1. Divide the decimal number by the target radix .
  2. Record the remainder (this becomes a digit of the result, starting from the Least Significant Bit (LSB)).
  3. Take the integer quotient and divide it by again.
  4. Repeat this process until the quotient becomes . The last remainder recorded is the Most Significant Bit (MSB).

Successive Division: Convert to Binary ()

Reading the remainders from bottom to top:


Part B: Converting Fractions (Successive Multiplication Method)

To convert a decimal fraction to a target base :

  1. Multiply the decimal fraction by the target radix .
  2. Record the integer part of the resulting product (this becomes a digit of the result, starting from the MSB).
  3. Take the remaining fractional part of the product and multiply it by again.
  4. Repeat until the fractional part becomes (or until you reach the desired bit precision).

Successive Multiplication: Convert to Binary ()

Reading the integer parts from top to bottom:

Part C: Comparison of Conversion Methods

FeatureSuccessive Division MethodSuccessive Multiplication Method
Target ComponentInteger part of the decimal number.Fractional part of the decimal number.
Mathematical OperationDivision by target base .Multiplication by target base .
Result ExtractionRemainders of the division.Integer carries of the multiplication.
Reading DirectionBottom-to-top (First remainder is LSB, last is MSB).Top-to-bottom (First carry is MSB, last is LSB).
Termination ConditionInteger quotient becomes .Fractional part becomes or desired precision is met.

3. Unsigned Binary Multiplication & Division (Paper-and-Pencil Methodology)

Foundational Concept (Outside Direct PYQ Scope)

Paper-and-pencil binary multiplication and division are foundational mathematical topics required to understand computer arithmetic circuits (like multipliers and dividers in Chapter 5), but they are rarely tested directly as calculation problems in ECE 2103 examinations.

To build arithmetic logic units (ALUs), we must understand paper-and-pencil multiplication and division for unsigned binary numbers.

3.1 Unsigned Binary Multiplication (Shift-and-Add)

Unsigned binary multiplication is identical to decimal long multiplication. Since binary digits are only 0 or 1, the partial products are either equal to the multiplicand or zero.

Step-by-Step Algorithm:

  1. Align the multiplicand and multiplier.
  2. For each bit of the multiplier, from Least Significant Bit (LSB) to Most Significant Bit (MSB):
    • If the multiplier bit is 1, write down the multiplicand as a partial product, shifted left according to the bit position.
    • If the multiplier bit is 0, write down a row of 0s (or simply shift the next partial product).
  3. Sum all the partial products using binary addition rules.

Unsigned Multiplication: Multiply by () [Syllabus Week 2]

       1011   (Multiplicand = 11_10)
     x 0101   (Multiplier = 5_10)
     ------
       1011   (Partial Product 1: Multiplier LSB = 1)
      0000.   (Partial Product 2: Multiplier bit = 0, shifted left)
     1011..   (Partial Product 3: Multiplier bit = 1, shifted left 2)
    0000...   (Partial Product 4: Multiplier MSB = 0, shifted left 3)
    -------
    0110111   (Binary Sum = 110111_2 = 32 + 16 + 4 + 2 + 1 = 55_10)

3.2 Unsigned Binary Division (Long Division Method)

Binary division is performed using long division, matching the decimal algorithm.

Step-by-Step Algorithm:

  1. Align the divisor with the most significant bits of the dividend.
  2. Compare the divisor with the selected portion of the dividend:
    • If the dividend portion divisor, write 1 in the quotient, subtract the divisor from the dividend portion, and bring down the next bit of the dividend.
    • If the dividend portion divisor, write 0 in the quotient and bring down the next bit.
  3. Repeat this process until all bits of the dividend are processed.

Unsigned Division: Divide by () [Syllabus Week 2]

           000101   (Quotient = 5_10)
        _________
  1001 | 101101   (Dividend = 45_10)
       - 1001     (1011 >= 1001 -> Quotient bit = 1, subtract 1001)
       ------
         00100    (Remainder is 0010; bring down next dividend bit '0')
       - 00000    (0100 < 1001 -> Quotient bit = 0, subtract 0)
       -------
          1001    (Remainder is 0100; bring down next dividend bit '1')
        - 1001    (1001 >= 1001 -> Quotient bit = 1, subtract 1001)
        ------
          0000    (Remainder = 0; Stop. Result: Quotient = 101_2 = 5_10)

4. Conversions to “Unusual” Radices (Base-3, Base-4, Base-7, Base-12)

Examiners test your grasp of these algorithms by asking for conversions to non-standard bases (PYQ 2015, 2016, 2022, 2023, 2025 — 12 marks). The algorithm never changes; only the radix you divide and multiply by changes.

Worked Exam Problem (2015, 2016, 2022, 2023 — 12 marks)

Convert the decimal number to base-3, base-4, and base-7.

A. Converting to Base-4

  1. Integer Part () Successive Division by 4:
    • Integer Result:
  2. Fractional Part () Successive Multiplication by 4:
    • (repeats infinitely…)
    • Fractional Result:

B. Converting to Base-7

  1. Integer Part () Successive Division by 7:
    • Integer Result:
  2. Fractional Part () Successive Multiplication by 7:
    • Fractional Result:

C. Converting to Base-3

  1. Integer Part () Successive Division by 3:
    • Integer Result: — check: ✓
  2. Fractional Part () Successive Multiplication by 3:
    • (fraction returns to — the block 1210 now repeats)


D. The Base-12 Variant (PYQ 2025 — 12 marks)

The 2025 paper asked for to base-3, base-7, and base-12. Base-12 is the only radix in this course where a single digit can exceed 9, so it carries a trap of its own.

Integer part (), divided by 12:

  • Integer Result: — check: ✓

Fractional part (), multiplied by 12:

  • (fraction returns to — block 9724 repeats)

For completeness, the same number in the other two requested bases: .

Exam Traps in Base Conversion

  • Base-12 digits run . A remainder of must be written as A and as B — never as the two characters “10”. This is the single most common lost mark in this question.
  • Repeating fractions never terminate. in base-3 and base-4 recurs forever. Do not keep multiplying — write 4–6 digits, mark the repeating block, and move on.
  • Digit ceiling check: every digit you write must satisfy . A "" appearing in a base-7 answer means you made an arithmetic slip.
  • Always verify the integer part by expanding it back (positional sum). It costs 15 seconds and catches most division errors.

5. Hexadecimal Fractions to Binary, Octal, and Decimal

When converting between bases that are powers of 2 (, , ), we can convert directly by grouping bits.

graph LR
    Hex["Hexadecimal (Base-16)"] -->|4-Bit Expansion| Binary["Binary (Base-2)"]
    Binary -->|3-Bit Grouping| Octal["Octal (Base-8)"]
    Hex -->|Polynomial Expansion| Decimal["Decimal (Base-10)"]

Worked Exam Problem: Convert to Binary, Octal, and Decimal (2015, 2017, 2025 - 12 Marks)

Step 1: Hexadecimal to Binary (4-Bit Expansion)

Replace each hex digit with its 4-bit binary equivalent:

Step 2: Binary to Octal (3-Bit Grouping)

Group the binary bits in clusters of 3, starting from the binary point:

  • Integer (Left of point):
  • Fractional (Right of point):

Step 3: Hexadecimal to Decimal (Polynomial Expansion)

Evaluate the polynomial weight sum:


6. Fractional Binary Equivalence & Precision Analysis

Converting decimal fractions to binary can introduce precision errors {the gap between the true value and the value a fixed number of bits can actually store}, because a fraction that terminates in decimal often recurs forever in binary and must be cut short.

Worked Exam Problem: The "2/3" Fraction Analysis (PYQ 2021, 2023 — 12 marks)

Question (2021, verbatim): Do the following conversion problems: (i) Convert decimal to binary. (ii) Calculate the binary equivalent of out to eight places. Then convert from binary to decimal. How close is the result to ? (iii) Convert the binary result in (ii) into hexadecimal. Then convert the result to decimal. Is the answer the same?

(The 2023 paper replaced part (i) with the base-4/base-7 conversion solved in §4, keeping (ii) and (iii) word-for-word.)

Solution:

Part 0: Convert to Binary (2021 part i)

Integer part (), successive division by 2: , read bottom-up .

Fractional part (), successive multiplication by 2:

  • (stop at 8 places)

Reading back: , an error of against the true value — this non-terminating behaviour is exactly what parts (ii) and (iii) probe.

Part A: Binary Equivalent of to 8 Places

Decimal

  • (pattern repeats)

Part B: Convert back to Decimal & Find Error

  • Precision Loss (Error):

Part C: Convert to Hexadecimal & Back to Decimal

  • Group binary bits:
  • Convert Hex to Decimal:
  • Conclusion: The decimal values are identical. Grouping bits between base 2 and base 16 does not introduce any additional precision loss.

Past Year Questions (PYQs)

This topic has appeared in every single paper from 2015 to 2025. It is the most reliable 12 marks in Chapter 1.

Question (as asked)YearsMarksSolved in
Decimal → base-3, base-4, base-72015, 2016, 202212§4 A–C
Decimal → base-3, base-4, base-7201712§4 (same method)
Decimal → base-3, base-7, base-12202512§4 D
Hexadecimal → decimal, octal, binary2015, 202512§5
Hexadecimal → decimal, octal, binary201712§5 (same method)
Convert decimal to binary202112§6 Part 0
Binary equivalent of to 8 places; back to decimal; how close?; then to hex and back2021, 202312§6 A–C

Pattern to notice: the examiner recycles the same three numbers (, , ) with the digits shuffled. Drill the algorithm, not the answers.