ScholarQuill logoScholarQuillUniversity Notes
My Semester
Explore Notes
Past Papers12 New
Video CoursesNew
Search
Settings
Study Tools
GPA/CGPA Calculator
Schedule & To-Do
Student Portal
Contact
Contact
ScholarQuill logo
My Semester
Explore Notes
Past Papers12 New
Video CoursesNew
Search
Settings
GPA/CGPA Calculator
Schedule & To-Do
Student Portal
Contact
ScholarQuill logoScholarQuillUniversity Notes
Study PortalPHYS4129Number Systems Convers…
Ctrl + K
Login
Explore
Search
Semester
Papers
CGPA
    PHYS4129

    Digital Logic and Design

    Progress0 / 20 done
    Topics20
    1Binary, octal and hexadecimal number system their inter conversion2Basic logic gates
    3BCD, ASCII, Gray etc.4Parity in codes
    5Demorgan theorems6Simplification of Boolean expression by Boolean postulates and theorem7SOP and POS conversions8K maps and their uses9Don't care condition
    10Logic circuits based on AND-OR, OR-AND, NAND, NOR Logic gates design11Addition, subtraction, 2's compliments12Half adder, full adder13Half subtractor, full subtractor14Encoder, decoder15Multiplexer and demultiplexer
    16Latches
    17S-R, J-K, T and D flip flops18Master-slave flip-flops
    19Basic characteristics (Propagation delay time, dissipation, noise margins etc.)
    20DTL, RTL, TTL, CMOS
    7 min read
    Topic 1 of 20
    Topic Study Note Illustration
    01

    Review of Number Systems: Binary, octal and hexadecimal number system their inter conversion

    In digital logic design (DLD) and computer science, the understanding of number systems is crucial as digital computers use different bases to represent data. The most commonly...

    Review of Number Systems: Binary, Octal, and Hexadecimal Number Systems and Their Interconversion

    In digital logic design (DLD) and computer science, the understanding of number systems is crucial as digital computers use different bases to represent data. The most commonly used number systems are binary, octal, and hexadecimal. These number systems are essential for understanding how computers perform arithmetic operations, how data is stored, and how different number formats are converted between each other.


    1. Binary Number System

    • The binary number system is the foundation of digital systems. It uses only two digits: 0 and 1, which are called bits (binary digits).
    • A bit can represent two states: 0 (off) and 1 (on). These bits are used to represent all types of data in a computer.
    • The place value for each bit in a binary number is based on powers of 2, starting from the rightmost digit.

    Example:

    The binary number 1101 represents:

    • 1×23+1×22+0×21+1×20=8+4+0+1=131 \times 2^3 + 1 \times 2^2 + 0 \times 2^1 + 1 \times 2^0 = 8 + 4 + 0 + 1 = 131×23+1×22+0×21+1×20=8+4+0+1=13 in decimal.

    2. Octal Number System

    • The octal number system uses eight digits: 0, 1, 2, 3, 4, 5, 6, 7. It is a base-8 number system.
    • Each octal digit represents exactly three binary digits (bits), because 23=82^3 = 823=8. This makes octal a convenient way to represent large binary numbers.

    Example:

    The octal number 15 represents:

    • 1×81+5×80=8+5=131 \times 8^1 + 5 \times 8^0 = 8 + 5 = 131×81+5×80=8+5=13 in decimal.

    3. Hexadecimal Number System

    • The hexadecimal number system is a base-16 system that uses sixteen symbols: 0-9 for values 0 to 9 and A-F for values 10 to 15.
    • Hexadecimal is widely used in computer science because it is more compact than binary and easier for humans to read and interpret. Each hexadecimal digit represents exactly four binary digits (bits), because 24=162^4 = 1624=16.

    Example:

    The hexadecimal number 1A represents:

    • 1×161+A×160=16+10=261 \times 16^1 + A \times 16^0 = 16 + 10 = 261×161+A×160=16+10=26 in decimal.

    4. Interconversion Between Binary, Octal, Decimal, and Hexadecimal

    Understanding how to convert between these number systems is very important for programming, data representation, and digital logic design. The conversion can be done either by direct methods or through intermediate representations (like binary).

    (a) Binary to Octal Conversion

    • Step 1: Group the binary number into groups of three bits, starting from the right. If there are fewer than three bits on the leftmost group, pad with leading zeros.
    • Step 2: Convert each group of three binary bits into its octal equivalent.

    Example: Convert binary 101110 to octal.

    1. Group binary into triplets: 101 110
    2. Convert each group to octal:
      • 101 in binary = 5 in octal
      • 110 in binary = 6 in octal
    3. The result is 56 in octal.

    (b) Binary to Hexadecimal Conversion

    • Step 1: Group the binary number into groups of four bits, starting from the right. If there are fewer than four bits on the leftmost group, pad with leading zeros.
    • Step 2: Convert each group of four binary bits into its hexadecimal equivalent.

    Example: Convert binary 1011101 to hexadecimal.

    1. Group binary into nibbles (groups of 4 bits): 0101 1101
    2. Convert each group to hexadecimal:
      • 0101 in binary = 5 in hexadecimal
      • 1101 in binary = D in hexadecimal
    3. The result is 5D in hexadecimal.

    (c) Octal to Binary Conversion

    • Step 1: Convert each octal digit to its 3-bit binary equivalent.

    Example: Convert octal 56 to binary.

    1. Convert each octal digit to binary:
      • 5 in octal = 101 in binary
      • 6 in octal = 110 in binary
    2. Combine the binary values: 101 110 → 101110

    (d) Hexadecimal to Binary Conversion

    • Step 1: Convert each hexadecimal digit to its 4-bit binary equivalent.

    Example: Convert hexadecimal 3F to binary.

    1. Convert each hexadecimal digit to binary:
      • 3 in hexadecimal = 0011 in binary
      • F in hexadecimal = 1111 in binary
    2. Combine the binary values: 0011 1111 → 00111111

    (e) Octal to Hexadecimal Conversion

    • Step 1: Convert the octal number to binary.
    • Step 2: Convert the resulting binary number to hexadecimal.

    Example: Convert octal 56 to hexadecimal.

    1. Convert octal 56 to binary:

      • 5 in octal = 101 in binary
      • 6 in octal = 110 in binary
      • So, 56 in octal = 101 110 in binary.
    2. Convert binary 101110 to hexadecimal:

      • Group binary into nibbles: 0010 1110
      • Convert each group to hexadecimal:
        • 0010 in binary = 2 in hexadecimal
        • 1110 in binary = E in hexadecimal
      • The result is 2E in hexadecimal.

    (f) Hexadecimal to Octal Conversion

    • Step 1: Convert the hexadecimal number to binary.
    • Step 2: Convert the resulting binary number to octal.

    Example: Convert hexadecimal 3F to octal.

    1. Convert hexadecimal 3F to binary:

      • 3 in hexadecimal = 0011 in binary
      • F in hexadecimal = 1111 in binary
      • So, 3F in hexadecimal = 00111111 in binary.
    2. Convert binary 00111111 to octal:

      • Group binary into triplets: 000 111 111
      • Convert each group to octal:
        • 000 in binary = 0 in octal
        • 111 in binary = 7 in octal
        • 111 in binary = 7 in octal
      • The result is 77 in octal.

    5. Summary of Interconversion

    From To Method
    Binary Octal Group binary digits into groups of 3 and convert each group into an octal digit.
    Binary Hexadecimal Group binary digits into groups of 4 and convert each group into a hexadecimal digit.
    Octal Binary Convert each octal digit into a 3-bit binary equivalent.
    Octal Hexadecimal Convert octal to binary and then convert the binary result into hexadecimal.
    Hexadecimal Binary Convert each hexadecimal digit into a 4-bit binary equivalent.
    Hexadecimal Octal Convert hexadecimal to binary and then convert the binary result into octal.

    6. Summary

    • Binary is the base-2 number system and is the language of computers.
    • Octal is the base-8 system and is often used as a shorthand for binary.
    • Hexadecimal is the base-16 system and is commonly used in computer science for compact representation of binary numbers.
    • Interconversion between these systems is essential for computer engineers and programmers, and understanding the rules of conversion makes it easier to deal with digital data and memory addressing.

    By mastering conversions between binary, octal, and hexadecimal systems, you can effectively work with digital logic design and other aspects of computer science.

    Next topic 2 →
    Basic logic gates

    Past Papers

    Open this section to view and download past papers

    Click on Show Past Papers to load available exam papers.

    Reading Progress
    0%
    7mremaining
    1.2kwords
    Intermediatelevel
    On This Page

    No headings found

    Study Toolkit

    Subject Portal

    Digital Logic and Design