# Number System Complete Tutorial (Computers) | Types | Conversions | Examples

In this post, learn about Number System in Computers, their types, examples and most importantly the conversion of numbers in of various types.

## Table of Contents

- What is Number System?
- Types of Number System
- Inter-conversion of Numbers
- Quick Conversion Table

## Number System

A number system is a writing system is a collection of various symbols which are called digits. Computers don’t understand high level languages like us. They can only understand numbers (mostly binary numbers).

### Types of Number System

There are various types of Number Systems but here we will be discussing about the most common types of Number systems.

#### Binary Number System

**Base 2**(2 Digits:**0**and**1**)- This system is a positional notation with a radix of 2. Each digit is referred to as a bit.
- Because of its straightforward implementation in digital electronic circuitry using logic gates, the binary system is used by almost all modern computers and computer-based devices.

#### Decimal Number System (Hinduâ€“Arabic Numeral System)

**Base 10**(10 Digits:**0**to**9**)- Occasionally called
**denary**. - Standard system for denoting integer and non-integer numbers.

#### Octal Number System

**Base 8**(8 Digits:**0**to**7**)

#### Hexadecimal Number System (HEX)

**Base 16**(10 Digits & 6 Characters:**0**to**9**and**A**to**F**)

## Conversion of Numbers in Various Number Systems

### A. Binary to Other Number Systems

#### 1. Binary To Octal Conversion

**(11101010) _{2} = (352)_{8}**

__Step 1__: Write down the binary number

(011101010)_{2}

Group all the digits in sets of three starting from the LSB (far right). Add zeros to the left of the last digit if there aren’t enough digits to make a set of three.

011 101 010

__Step 2__: Use the table below to convert each set of three into an octal digit. In this case,

011=3, 101=5, 010=2

So, the number **11101010** in binary is equivalent to **352** in octal.

To convert from binary to octal use the following table:

Binary: | 000 | 001 | 010 | 011 | 100 | 101 | 110 | 111 |
---|---|---|---|---|---|---|---|---|

Octal: | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 |

#### 2. Binary To Decimal Conversion

**(11101010) _{2} = (234)_{10}**

__Step 1__: Write down the binary number

11101010

__Step 2__: Multiply each digit of the binary number by the corresponding power of two

1x2^{7}+ 1x2^{6}+ 1x2^{5}+ 0x2^{4}+ 1x2^{3}+ 0x2^{2}+ 1x2^{1}+ 0x2^{0}

__Step 3__: Solve the powers

1x128 + 1x64 + 1x32 + 0x16 + 1x8 + 0x4 + 1x2 + 0x1 = 128 + 64 + 32 + 0 + 8 + 0 + 2 + 0

__Step 4__: Add up the numbers written above

128 + 64 + 32 + 0 + 8 + 0 + 2 + 0 = 234.

Thus **234** is the decimal equivalent of the binary number 11101010

#### 3. Binary To Hexadecimal Conversion

(11101010)_{2} = (EA)_{16}

__Step 1__: Write down the binary number

11101010

__Step 2__: Group all the digits in sets of four starting from the LSB (far right). Add zeros to the left of the last digit if there aren’t enough digits to make a set of four:

1110 1010

__Step 3__: Use the table below to convert each set of three into an hexadecimal digit, in this case:

1110 = E, 1010 = A

So, **EA** is is the hexadecimal equivalent to the decimal number 11101010.

To convert from binary to hexadecimal use the following table:

Binary: | 0000 | 0001 | 0010 | 0011 | 0100 | 0101 | 0110 | 0111 |
---|---|---|---|---|---|---|---|---|

Hexadecimal: | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 |

Binary: | 1000 | 1001 | 1010 | 1011 | 1100 | 1101 | 1110 | 1111 |

Hexadecimal: | 8 | 9 | A | B | C | D | E | F |

### B. Decimal To Other Number Systems

#### 1. Decimal To Binary Conversion

**(123) _{10} = (1111011)_{2}**

__Step 1__: Divide (123)_{10} successively by 2 until the quotient is 0

123/2 = 61, remainder is 1 61/2 = 30, remainder is 1 30/2 = 15, remainder is 0 15/2 = 7, remainder is 1 7/2 = 3, remainder is 1 3/2 = 1, remainder is 1 1/2 = 0, remainder is 1

__Step 2__: Read from the bottom (MSB) to top (LSB) as **1111011**. This is the binary equivalent of decimal number 123.

#### 2. Decimal To Octal Conversion

**(123) _{10} = (173)_{8}**

__Step 1__: Divide (123)_{10} successively by 8 until the quotient is 0:

123/8 = 15, remainder is 3 15/8 = 1, remainder is 7 1/8 = 0, remainder is 1

__Step 2__: Read from the bottom (MSB) to top (LSB) as 173. This is the octal equivalent of decimal number 123

#### 3. Decimal To Hexadecimal Conversion

(123)_{10} = (7B)_{16}

__Step 1__: Divide (123)_{10} successively by 16 until the quotient is 0:

123/16 = 7, remainder is 11 7/16 = 0, remainder is 7

Here is the table for conversion Decimal to Hexa and Vice-Versa

Dec: | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|

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

__Step 2__: Read from the bottom (MSB) to top (LSB) as 7B. This is the hexadecimal equivalent of decimal number 123

### B. Octal To Other Number Systems

#### 1. Octal To Binary Conversion

**(123) _{8} = (1010011)_{2}**

__Step 1__: Look up each octal digit to obtain the equivalent group of three binary digits.

(1)_{8}= (001)_{2}(2)_{8}= (010)_{2}(3)_{8}= (011)_{2}

You can use the table below to make these conversions.

Oct: | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 |
---|---|---|---|---|---|---|---|---|

Bin: | 000 | 001 | 010 | 011 | 100 | 101 | 110 | 111 |

Group each value of step 1 to make a binary number:

001 010 011

So, (1010011)_{2} is the binary equivalent to (123)_{8}

__Step 2__: Multiply each digit of the octal number by the corresponding power of eight:1x82 + 2x81 + 3x80

__Step 3__: Solve the powers:

1x64 + 2x8 + 3x1

__Step 4__: Add up the numbers written above:

64 + 16 + 3 = 83

This is the decimal equivalent of the octal number 123.

#### 2. Octal To Decimal Conversion

**(123)**_{8} = (83)_{10}

__Step 1__: Write down the octal number:

123

__Step 2__: Multiply each digit of the octal number by the corresponding power of eight:

1x8^{2} + 2x8^{1} + 3x8^{0}

__Step 3__: Solve the powers:

1x64 + 2x8 + 3x1

__Step 4__: Add up the numbers written above:

64 + 16 + 3 = 83

This is the decimal equivalent of the octal number 123.

#### 3. Octal To Hexadecimal Conversion

**(123)**_{8} = (53)_{16}

__Step 1__: Look up each octal digit to obtain the equivalent group of three binary digits. You can use the table below to make these conversions.

Octal to Binary Conversion Table

Oct: 0 1 2 3 4 5 6 7 Bin: 000 001 010 011 100 101 110 111

(1)_{8} = (001)_{2}
(2)_{8} = (010)_{2}
(3)_{8} = (011)_{2}

__Step 2__: Group each value of step 1 to make a binary number.

001 010 011

(123)8 = (1010011)2

__Step 3__: Now convert the binary number from step 2 to hexa by grouping all the digits of the binary in sets of four starting from the LSB (far right).

0101 0011

Note: add zeros to the left of the last digit if there aren’t enough digits to make a set of four.

__Step 4__: Convert each group of four to the corresponding hexadecimal (use the table below)

0101=5, 0011=3.

So, 123 in octal is equivalent to 53 in hexadecimal

To convert from binary to hexadecimal use the following table:

Bin: 0000 0001 0010 0011 0100 0101 0110 0111 Hexa: 0 1 2 3 4 5 6 7 Bin: 1000 1001 1010 1011 1100 1101 1110 1111 Hexa: 8 9 A B C D E F

### B. Hexadecimal To Other Number Systems

#### 1. Hexadecimal To Binary Conversion

**(123)**_{16} = (100100011)_{2}

__Step 1__: Look up each octal digit to obtain the equivalent group of four binary digits.

(1)_{16}= (0001)_{2}
(2)_{16}= (0010)_{2}
(3)_{16}= (0011)_{2}

You can use the table below to make these conversions.

Binary: 0000 0001 0010 0011 0100 0101 0110 0111 Hexadecimal: 0 1 2 3 4 5 6 7 Binary: 1000 1001 1010 1011 1100 1101 1110 1111 Hexadecimal: 8 9 A B C D E F

__Step 2__: Group each value of step 1

0001 0010 0011

__Step 3__: Join these values and remove zeros at left (if necessary) to get the binary result.

100100011

So, 100100011 is the binary equivalent of hexadecimal number 123.

#### 2. Hexadecimal To Octal Conversion

**(123)**_{16} = (443)_{8}

__Step 1__: Look up each hexadecimal digit to obtain the equivalent group of four binary digits.

(1)_{16} = (0001)_{2}
(2)_{16} = (0010)_{2}
(3)_{16} = (0011)_{2}

You can use the table below to make these conversions.

Bin: 0000 0001 0010 0011 0100 0101 0110 0111 Hexa: 0 1 2 3 4 5 6 7 Bin: 1000 1001 1010 1011 1100 1101 1110 1111 Hexa: 8 9 A B C D E F

__Step 2__: Group each value and remove zeros at left (if necessary) to get the partial result in base 2:

0001 0010 0011 = 100100011

So, (123)_{16} = (100100011)_{2}

__Step 3__: Rearrange all the digits in sets of three starting from the LSB (far right). Add zeros to the left of the last digit if there aren’t enough digits to make a set of three.

100 100 011

__Step 4__: Use the table below to convert each set of three into an octal digit. In this case,

100=4, 100=4, 011=30.

So,

Binary to Octal conversion table:

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

443 is the octal equivalent of hexadecimal number 123

#### 2. Hexadecimal To Decimal Conversion

**(123)**_{16} = (291)_{10}

__Step 1__: Write down the hexadecimal number:

(123)_{16}

__Step 2__: Show each digit place as an increasing power of 16:

1x16^{2} + 2x16^{1} + 3x16^{0}

__Step 3__: Convert each hexadecimal digits values to decimal values then perform the math:

1x256 + 2x16 + 3x1 = (291)_{10}

So, the number 291 is the decimal equivalent of hexadecimal number 123 (Answer).

## Quick Conversion Table

Binary Decimal Hexadecimal Octal 0 0 0 0 1 1 1 1 10 2 2 2 11 3 3 3 100 4 4 4 101 5 5 5 110 6 6 6 111 7 7 7 1000 8 8 10 1001 9 9 11 1010 10 A 12 1011 11 B 13 1100 12 C 14 1101 13 D 15 1110 14 E 16 1111 15 F 17 10000 16 10 110 10001 17 11 111 10010 18 12 112 10011 19 13 113 10100 20 14 114 10101 21 15 115 10110 22 16 116 10111 23 17 117 11000 24 18 1110 11001 25 19 1111 11010 26 1A 1112 11011 27 1B 1113 11100 28 1C 1114 11101 29 1D 1115 11110 30 1E 1116 11111 31 1F 1117 100000 32 20 11110 1000000 64 40 111111110 10000000 128 80 11111111111111110

Number System Conversion Table PDF Download

The owner of Eduonine 24. He likes to create notes and write about various things happening in the Indian Education System.

__Step 3__: Solve the powers:

__Step 4__: Add up the numbers written above:

**(123)**

_{8}= (83)_{10}__Step 1__: Write down the octal number:

__Step 2__: Multiply each digit of the octal number by the corresponding power of eight:

^{2}+ 2x8

^{1}+ 3x8

^{0}

__Step 3__: Solve the powers:

__Step 4__: Add up the numbers written above:

**(123)**

_{8}= (53)_{16}__Step 1__: Look up each octal digit to obtain the equivalent group of three binary digits. You can use the table below to make these conversions.

_{8}= (001)

_{2}(2)

_{8}= (010)

_{2}(3)

_{8}= (011)

_{2}

__Step 2__: Group each value of step 1 to make a binary number.

__Step 3__: Now convert the binary number from step 2 to hexa by grouping all the digits of the binary in sets of four starting from the LSB (far right).

__Step 4__: Convert each group of four to the corresponding hexadecimal (use the table below)

**(123)**

_{16}= (100100011)_{2}__Step 1__: Look up each octal digit to obtain the equivalent group of four binary digits.

_{16}= (0001)

_{2}(2)

_{16}= (0010)

_{2}(3)

_{16}= (0011)

_{2}

__Step 2__: Group each value of step 1

__Step 3__: Join these values and remove zeros at left (if necessary) to get the binary result.

**(123)**

_{16}= (443)_{8}__Step 1__: Look up each hexadecimal digit to obtain the equivalent group of four binary digits.

_{16}= (0001)

_{2}(2)

_{16}= (0010)

_{2}(3)

_{16}= (0011)

_{2}

__Step 2__: Group each value and remove zeros at left (if necessary) to get the partial result in base 2:

_{16}= (100100011)

_{2}

__Step 3__: Rearrange all the digits in sets of three starting from the LSB (far right). Add zeros to the left of the last digit if there aren’t enough digits to make a set of three.

__Step 4__: Use the table below to convert each set of three into an octal digit. In this case,

**(123)**

_{16}= (291)_{10}__Step 1__: Write down the hexadecimal number:

_{16}

__Step 2__: Show each digit place as an increasing power of 16:

^{2}+ 2x16

^{1}+ 3x16

^{0}

__Step 3__: Convert each hexadecimal digits values to decimal values then perform the math:

_{10}

The owner of Eduonine 24. He likes to create notes and write about various things happening in the Indian Education System.