0% found this document useful (0 votes)
4 views18 pages

Binary

The document explains the binary number system, which uses two states (ON as 1 and OFF as 0) to represent data. It covers the conversion of denary numbers to binary, the concept of bits, bytes, and overflow errors in binary addition. Additionally, it discusses the representation of integers and floating-point numbers in various bit lengths.

Uploaded by

blooketracoon
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
4 views18 pages

Binary

The document explains the binary number system, which uses two states (ON as 1 and OFF as 0) to represent data. It covers the conversion of denary numbers to binary, the concept of bits, bytes, and overflow errors in binary addition. Additionally, it discusses the representation of integers and floating-point numbers in various bit lengths.

Uploaded by

blooketracoon
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 18

Binary

introduction

A computer has many electronic


components that work as switches.
These components have two logics as
input and output: ON and OFF. A similar
logic is used to represent data in binary
form. ON is represented as 1 and OFF is
represented as 0.
topics:

Place value of denar Place value of binar


1 y system
2 y system

Converting denar
3 y to binary
Place value of denary system

The denary system has a base value of 10. It counts


in multiples of 10. The number 7324 has 7
thousands, 3 hundreds, 2 tens and 4 ones. The
following figure illustrates the place values in a
denary system.

back
Place value of binary system

Real-time Data CollectionThe binary numbers


can also be represented using place values. The
place values have a base 2. The first 8 digits
are represented in the table below.

back
IN THE FIGURE BELOW, THE DENARY NUMBER 24 IS
CONVERTED TO BINARY.

Figure 2: Binary
equivalent of 24
IN THE FIGURE BELOW, THE DENARY NUMBER 43 IS
CONVERTED TO BINARY.

Figure 3: Binary
equivalent of 43
CONVERTING DENARY TO BINARY
A denary number is converted to binary by
dividing it by 2 and calculating the
remainders, as shown in the following
example. Let us convert 91 to a binary
number.

Figure 3: Converting the denary number 91 to


binary
The binary equivalent of the denary number
91 is obtained by arranging the remainders
in reverse order.

The answer can be checked by:

(0×128)+(1×64)+(0×32)+(1×16)+(1×8)+(0×4)+(1×2)+(1
×1)= 91

A binary digit is referred to as a bit. A nibble consists of 4


bits. A byte consists of 8 bits. A byte is the smallest unit of
Binary

Binary com 5 Representing


4 binations numbers

6 Adding binary
numbers
Binary
combinations
AUDIO FILES USE BIT DEPTH TO DENOTE THE NUMBER OF BITS OF
INFORMATION IN EACH SAMPLE. A ONE-BIT SYSTEM HAS ONE-
PLACE VALUE AND CAN HAVE 2 POSSIBLE COMBINATIONS: 0 OR 1.

Similarly, a 3-bit system has three-place values and has 8


possible combinations, as shown in the table below:
Binary
Similarly, a 3-bit system has three-place
combinations values and has 8
possible combinations, as shown in the table below:

back
From the above examples, it can be noted that an n-bit system
has 2n possible combinations.
Adding binary numbers
Adding binary numbers

When the binary digits 1 and 0 are added, the sum


is 1. When both the digits are 0, the sum is 0. When
both the digits are 1, the sum is 10 and 1 is carried
over. 0101 and 1001 represent the denary numbers
5 and 9. The sum of 5 and 9 is 14. Convert the sum
obtained to denary number.

(8×1)+(4×1)+(2×1)+(0×1)=14
Overflow Error

A CPU with an 8-bit register has a capacity of up to


11111111 in binary. If an extra bit is added, it is said to
be an overflow error. Consider the addition of two binary
numbers 11101101 and 10000100 as shown below:
Representing numbers

Programmers use many arithmetic


operations in a program. The numbers are
either represented as integers or floating-
point numbers. Integers are whole numbers
and floating-point numbers are used to
represent numbers with decimal points. A
16-bit system can represent integers up to
2^16-1=65535. 8-bit, 16-bit, 32-bit and 64-
bit are the most common bit lengths. back
Overflow Error

The sum of these two numbers is bigger than 8 bits (an


extra bit than the register can hold). The computer
thinks that 11101101+10000100=01110001 as it does
not have space to store the extra bit. The number of
bits a register can hold is called word size. Exceeding
the capacity of a word size in a register results in an
End of the topic

You might also like