0% found this document useful (0 votes)
93 views9 pages

Number System Conversion: Decimal To Binary

The document discusses number system conversions between decimal, binary, octal, and hexadecimal. It provides examples and steps for converting between these number systems. Decimal can be converted to binary, octal, or hexadecimal by repeated division and recording remainders. Binary can be converted to octal or hexadecimal by grouping bits and converting groups to equivalent values. Arithmetic operations like addition, subtraction, multiplication and division follow basic laws and are performed in different number systems in a similar way.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
93 views9 pages

Number System Conversion: Decimal To Binary

The document discusses number system conversions between decimal, binary, octal, and hexadecimal. It provides examples and steps for converting between these number systems. Decimal can be converted to binary, octal, or hexadecimal by repeated division and recording remainders. Binary can be converted to octal or hexadecimal by grouping bits and converting groups to equivalent values. Arithmetic operations like addition, subtraction, multiplication and division follow basic laws and are performed in different number systems in a similar way.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 9

Number System Conversion

As you know decimal, binary, octal and hexadecimal number systems are positional
value number systems. To convert binary, octal and hexadecimal to decimal number,
we just need to add the product of each digit with its positional value. Here we are
going to learn other conversion among these number systems.

Decimal to Binary
Decimal numbers can be converted to binary by repeated division of the number by 2
while recording the remainder. Let’s take an example to see how this happens.

The remainders are to be read from bottom to top to obtain the binary equivalent.
4310 = 1010112

Decimal to Octal
Decimal numbers can be converted to octal by repeated division of the number by 8
while recording the remainder. Let’s take an example to see how this happens.

Reading the remainders from bottom to top,


47310 = 7318
Decimal to Hexadecimal
Decimal numbers can be converted to octal by repeated division of the number by 16
while recording the remainder. Let’s take an example to see how this happens.

Reading the remainders from bottom to top we get,


42310 = 1A716

Binary to Octal and Vice Versa


To convert a binary number to octal number, these steps are followed −
 Starting from the least significant bit, make groups of three bits.
 If there are one or two bits less in making the groups, 0s can be added after the
most significant bit
 Convert each group into its equivalent octal number
Let’s take an example to understand this.

101100101012 = 26258
To convert an octal number to binary, each octal digit is converted to its 3-bit binary
equivalent according to this table.

Octal Digit 0 1 2 3 4 5 6 7
Binary Equivalent 000 001 010 011 100 101 110 111

546738 = 1011001101110112

Binary to Hexadecimal
To convert a binary number to hexadecimal number, these steps are followed −
 Starting from the least significant bit, make groups of four bits.
 If there are one or two bits less in making the groups, 0s can be added after the
most significant bit.
 Convert each group into its equivalent octal number.
Let’s take an example to understand this.

101101101012 = DB516
To convert an octal number to binary, each octal digit is converted to its 3-bit binary
equivalent.
Arithmetic of Number Systems
A number system is a set of symbols used to represent values derived from a common
base or radix. In a number, the value of each digit can be determined using digit,
position of the digit in the number, and the base of the number system. The base is
defined as the total number of digits are available in the number system. This is known
as positional number system.

Number System Base Digit Used

Binary 2 0, 1

Octal 8 0, 1, 2, 3, 4, 5, 6, 7

Decimal 10 0, 1, 2, 3, 4, 5, 6, 7, 8, 9

Hexadecimal 16 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F

Arithmetic operations like addition, subtraction, multiplication and division are performed
in various radix bases. These arithmetic operations may also use r’s complement and
(r-1)’s complement representation.
These representation techniques hold basic laws for various arithmetic operations:
(i) Unique Existence Law: The sum and product of any two numbers exist uniquely.
Where 0 is the identity element for additions and 1 is the identity element for
multiplication.
(ii) Associative Law:Addition and multiplication of binary numbers are associative.
(iii) Commutative Law:Addition and multiplication of binary numbers are commutative.
(iv) Distributive Law:Multiplication of binary numbers is distributive over two or more
terms in addition.
Now, arithmetic operations for various number systems are explained as following
below.

Arithmetic Operations of Binary Numbers:


In the Binary System, there are only two symbols or possible digit values, i.e., 0 and 1.
Represented by any device that only 2 operating states or possible conditions.
Generally, it is expressed by subscript 2 or binary (B).
Binary arithmetic is essential part of various digital systems. You can add, subtract,
multiply, and divide binary numbers using various methods. These operations are much
easier than decimal number arithmetic operations because binary system has only two
digits: 0 and 1.
Binary additions and subtractions are performed as same in decimal additions and
subtractions. When we perform binary additions, there will have two outputs: Sum (S)
and Carry (C) . There are four rules for binary addition. These are given as following
below,

Input A Input B Sum (S) Carry (C)


A+B

0 0 0 0

0 1 1 0

1 0 1 0

1 1 0 1

There are four rules for binary subtraction. These are given as following below,

Input A Input B Subtract (S) Borrow (B)


A-B

0 0 0 0

0 1 0 1

1 0 1 0

1 1 0 0

Borrow 1 is required from next higher order bit to subtract 1 from 0. So, result became
0.
There are four rules for binary multiplication. These are given as following below,

Input A Input B Multiply (M)


AxB

0 0 0

0 1 0

1 0 0

1 1 1

Whenever at least one input is 0, then multiplication is always 0.

There are four part in any division: Dividend, Divisor, quotient, and remainder. These
are given as following rules for binary division,

Input A Input B Divide (D)


A/B

0 0 Not defined

0 1 0

1 0 Not defined

1 1 1

Whenever divisor is 0, then result is always not defined.


Arithmetic Operations of Octal Numbers:
It has base of 8 digits ranging from 0 to 7 (i.e., 0, 1, 2, 3, 4, 5, 6, 7). Generally, it is
expressed by subscript 8 or octal (o).
Arithmetic operations of octal numbers are also performed same as decimal arithmetic
operations. The addition table for octal numbers is given as below:

+ 0 1 2 3 4 5 6 7

0 0 1 2 3 4 5 6 7

1 1 2 3 4 5 6 7 10

2 2 3 4 5 6 7 10 11

3 3 4 5 6 7 10 11 12

4 4 5 6 7 10 11 12 13

5 5 6 7 10 11 12 13 14

6 6 7 10 11 12 13 14 15

7 7 10 11 12 13 14 15 16

With the help of above table, we can perform additions of octal numbers.
Similarly, we can perform subtraction of octal numbers same as decimal number
subtractions. But you can only take borrow of a number 7, which is maximum digit
allowed in octal number systems.
 In the multiplication of octal numbers, if the product is less than radix of octal (i.e, 8),
then we take it as the result, else divide it by radix of octal (i.e., 8) and take the
remainder as the LSB (least significant bit). The quotient is taken as carry in the next
significant digit.
 Similarly, division of octal numbers can be performed by following the rules of division
of decimal numbers but maximum allowed digit will be 7.
Arithmetic Operations of Hexadecimal Numbers:
It has base of 16 digits ranging from 0 to F (i.e., 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, and A, B, C,
D, E, F). A, B, C, D, E, F are equivalent single digits of 10, 11, 12, 13, 14, 15
respectively. Generally, it is expressed by subscript 16 or Hexa (H) or (h).
Arithmetic operations of hexadecimal numbers can be performed using addition table
for hexadecimal numbers which is given as below:

+ 0 1 2 3 4 5 6 7 8 9 A B C D E F

0 0 1 2 3 4 5 6 7 8 9 A B C D E F

1 1 2 3 4 5 6 7 8 9 A B C D E F 10

2 2 3 4 5 6 7 8 9 A B C D E F 10 11

3 3 4 5 6 7 8 9 A B C D E F 10 11 12

4 4 5 6 7 8 9 A B C D E F 10 11 12 13

5 5 7 7 8 9 A B C D E F 10 11 12 13 14

6 6 7 8 9 A B C D E F 10 11 12 13 14 15

7 7 8 9 A B C D E F 10 11 12 13 14 15 16

8 8 9 A B C D E F 10 11 12 13 14 15 16 17

9 9 A B C D E F 10 11 12 13 14 15 16 17 18
A A B C D E F 10 11 12 13 14 15 16 17 18 19

B B C D E F 10 11 12 13 14 15 16 17 18 19 1A

C C D E F 10 11 12 13 14 15 16 17 18 19 1A 1B

D D E F 10 11 12 13 14 15 16 17 18 19 1A 1B 1C

E E F 10 11 12 13 14 15 16 17 18 19 1A 1B 1C 1D

F F 10 11 12 13 14 15 16 17 18 19 1A 1B 1C 1D 1E

With the help of above table, we can perform additions of hexadecimal numbers.
Subtraction of hexadecimal numbers can be performed by using complement methods
or simple as decimal subtractions. The rule of simple hexadecimal subtraction is the
digit borrowed from the immediate higher place is counted as 16.
In the multiplication of hexadecimal numbers, if the product is less than radix of
hexadecimal (i.e, 16), then we take it as the result, else divide it by radix of hexadecimal
(i.e., 16) and take the remainder as the LSB (least significant bit). The quotient is taken
as carry in the next significant digit. Using these rules, you can make a table for
hexadecimal multiplications.
Similarly, division of hexadecimal numbers can be performed by following the rules of
division of decimal numbers but maximum allowed digit will be F(=15 in decimal).

Arithmetic Operations of Decimal Numbers:


Arithmetic operations of decimal numbers are very popular and much easier. These
operations are also performed as same in other number systems.

You might also like