MODULE 2 Notes
MODULE 2 Notes
COMPUTING, Module-2
Dr Biju V.G.
Associate Professor & Head,
Dept. of ECE
March 26, 2025
Contents
1 Binary Number system 3
1.1 Decimal to Binary Conversion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
1.1.1 Example 1: Convert 25 to Binary . . . . . . . . . . . . . . . . . . . . . . . 3
1.1.2 Example 2: Convert 43 to Binary . . . . . . . . . . . . . . . . . . . . . . . 3
1.1.3 Example 3: Convert 78 to Binary . . . . . . . . . . . . . . . . . . . . . . . 3
1.2 Binary to Decimal Conversion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
1.2.1 Example 4: Convert (1011)2 to Decimal . . . . . . . . . . . . . . . . . . . 4
1.2.2 Example 5: Convert (11010)2 to Decimal . . . . . . . . . . . . . . . . . . . 4
1.2.3 Example 6: Convert (1001101)2 to Decimal . . . . . . . . . . . . . . . . . . 4
1.3 Practice Questions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
1.3.1 Decimal to Binary Solutions . . . . . . . . . . . . . . . . . . . . . . . . . . 5
1.3.2 Binary to Decimal Solutions . . . . . . . . . . . . . . . . . . . . . . . . . . 5
1.4 Conclusion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
1
GYEST203 FOUNDATIONS OF COMPUTING, Module-1 CE Munnar
4. The binary equivalent is obtained by reading the remainders from bottom to top.
2 ÷ 2 = 1 remainder 0
1 ÷ 2 = 0 remainder 1
Answer: (78)10 = (1001110)2
(1011)2 = (1 × 23 ) + (0 × 22 ) + (1 × 21 ) + (1 × 20 )
= (1 × 8) + (0 × 4) + (1 × 2) + (1 × 1)
= 8 + 0 + 2 + 1 = (11)10
(11010)2 = (1 × 24 ) + (1 × 23 ) + (0 × 22 ) + (1 × 21 ) + (0 × 20 )
= (1 × 16) + (1 × 8) + (0 × 4) + (1 × 2) + (0 × 1)
= 16 + 8 + 0 + 2 + 0 = (26)10
(1001101)2 = (1 × 26 ) + (0 × 25 ) + (0 × 24 ) + (1 × 23 ) + (1 × 22 ) + (0 × 21 ) + (1 × 20 )
= (1 × 64) + (0 × 32) + (0 × 16) + (1 × 8) + (1 × 4) + (0 × 2) + (1 × 1)
= 64 + 0 + 0 + 8 + 4 + 0 + 1 = (77)10
(54) = (110110)
10 2
(77) = (1001101)
10 2
(99) = (1100011)
10 2
(145) = (10010001)
10 2
(110110) = (54) 2 10
(101010) = (42) 2 10
(111111) = (63) 2 10
(1000001) = (65) 2 10
1.4 Conclusion
Understanding binary number systems and their conversions is essential in digital electronics and
computing. This knowledge is fundamental in computer architecture, microprocessor design, and
software development.
10 2
Add 1: (11101101) 2
Answer: (11101101)2
Answer: (00101101)2
Add 1: (11010011) 2
Answer: (11010011)2
Answer: (10000000)2
(1) +27
(2) -27
(3) +63
(4) -63
(5) -100
2.4 Practice Solutions
2.4.1 Two’s Complement Solutions
(27) = (00011011)
10 2
(-27) = (11100101)
10 2
(63) = (00111111)
10 2
(-63) = (11000001)
10 2
(-100) = (10011100)
10 2
2.5 Conclusion
Understanding binary number systems, integer representation, and conversions is essential in
digital electronics and computing. Two’s complement representation is widely used for signed
integer storage and arithmetic operations in computer systems.
(1) +27
(2) -27
(3) +63
(4) -63
(5) -100
Answer the following data storage questions:
(-27) = (11100101)
10 2
(63) = (00111111)
10 2
(-63) = (11000001)
10 2
(-100) = (10011100)
10 2
4. Space ‘ ’ 32 (0100000) 2
Can be complex to implement due to different encoding formats (UTF-8, UTF-16, UTF-32).
Some older systems only support ASCII, leading to compatibility issues.
4.4 Comparison Table: ASCII vs Unicode
4.5 Conclusion
ASCII and Unicode are fundamental encoding systems in computing. ASCII is limited to En-
glish characters and symbols, while Unicode provides a universal standard supporting multiple
languages and symbols. Unicode’s flexibility makes it suitable for modern applications, despite
requiring more storage and processing power.
3. Execute: The ALU performs the required operation, and the result is stored.
4. Store: The result is written back to memory or a register for further use.
1. Fetch: The CPU fetches an instruction from memory (address held in the Program Counter).
2. Decode: The Control Unit decodes the instruction to determine the required operation.
6.2 Conclusion
Understanding CPU architecture, instruction formats, and the fetch-execute cycle is essential to
learning how computers process data efficiently. The ALU, Control Unit, and Registers work
together to execute instructions, making computing possible.
45 ÷ 2 = 22 remainder 1
22 ÷ 2 = 11 remainder 0
11 ÷ 2 = 5 remainder 1
5 ÷ 2 = 2 remainder 1
2 ÷ 2 = 1 remainder 0
1 ÷ 2 = 0 remainder 1
Reading the remainders from bottom to top, the binary representation of 45 is 101101.
1 Byte = 8 Bits
Dr. Biju V.G. Page 15 Associate Professor & Head, ECE
GYEST203 FOUNDATIONS OF COMPUTING, Module-1 CE Munnar
5 GB = 5 × 1024 MB
= 5 × 1024 × 1024 KB
= 5 × 1024 × 1024 × 1024 Bytes
= 5, 368, 709, 120 Bytes
Registers: Small, high-speed storage locations within the CPU used for temporary data
storage during execution.
Control Unit (CU): Manages and coordinates all activities of the CPU. It fetches instruc-
tions from memory, decodes them, and executes them by directing ALU and registers.
2. Decode: The control unit decodes the instruction to determine the operation and operands.
3. Execute: The ALU performs the required operation, and the result is stored in the appro-
priate register or memory.
4. Store: The result is written back to memory if needed, and the next instruction is fetched.
Two-Address Instructions: Two explicit operands, allowing direct data movement (e.g.,
MOV A, B).