All posts by Admin

BinaryNumbers

NUMBER SYSTEM

NUMBER SYSTEM

collection of digit makes number.

unlke analog system signal say data are continouly changing such as amplitude, frequency with respective time,digital system have only two stage High (1) or Low (0) in +ve logic.

only series of 1’s and 0’s represent signal say data.

Generaly used number system are shown in table format.

Number may consist of integrail and fractional part as shown in table

number base Noof weight example

symbol asign

Binary 2 0,1 2’n 10110.10

Octal 8 0,1,..7 8’n 157.27

Decimal 10 0,1,..9 10’n 159.24

Hex 16 0,1,..9,

A,B,.F 16’n 2DF5.A7

BINARY NUMBER SYSTEM

Combinatin of 0’s and 1 form binary number.

Nibble: Group of 4 bit called nibble.

Byte: Group of 8 bitcalled byte.

binary to decimal conversion:

let we convert (10110)2 to decimal (??)10

10110 == IMAGE NS01

Decimal to binary conversion:

METHOD 1

Succesive operasion method

First subtract the largest possible POWER of TWO (for binary base) and then keeping subtraction largest number from remainder as shown in the table.

putting 1 for respective no.

let we convert (55)dec to binary Val

55

-32 ==> 1 MSB

—-

23

-16 ==> 1

—-

07

-04 ==> 1

—-

03

-02 ==> 1

—-

01 ==> 1 LSB

(if remainder 1 last bit 1

if remainder 0 last bit 0)

nth power .. 7 6 5 4 3 2 1 0

Lage_val .. 128 64 32 16 08 04 02 01

Bin_dig .. 0 0 1 1 0 1 1 1

thus (55)dec=(110111)bin

Method 2

division by base method

55/2 =27 remainder 1 lsb

27/2 =13 remainder 1

13/2 =6 remainder 1

6/2 =3 remainder 0

3/2 =1 remainer 1

1/2 =0 remainder 1 msb

Thus

(55)dec=(110111)bin

OCTAL NUMBER SYSTEM

Octal number system has base 8, means it can represent as sysbol consist of digit 0,1,2,..7.

Decimal to octal conversion

let we do with succesive division by BASE 8

(247)dec to (??)oct

247/8 =30 remainder (247-240) 7 lsb

30/8 =3 remainder (30-24) 6

3/8 =0 remainder (3-0) 3 msb

Thus

(247)dec = (367)oct

Octal to decimal conversion

(367)oct to (??)dec

here base is 8

(367)oct =3×8^2+6×8^1+7×8^0

=3×64+6×8+7×1

=(247)dec

Octal to binary conversion

octal number can be converted to binary number just replacing equivalent binary.

for example

(367)oct =(011 110 111)bin

=(011110111)bin

Binary to octal conversion

binary number can be converted into octal number just making group of 3 bit starting from lsb.

for example

(11000110101)bin =(??)oct

(011 000 110 101)bin =(3 0 6 5)oct (start from lsb)

=(3065)oct

Hexadecimal number system

These number system is very popular in computer lower langauges, Assembly langages are coaded in Hex format.

It has base 16.

It is form by 16 distist symbol (0,1,..9,A,..F).

Hex to decimal conversion

Let we convert (103A)hex to its equivalent value

(103A)hex =(??)dec

=(1×16^3+0x16^2+3×16^1+Ax16^0)

=(1×4096+0x256 +3×16 +10×1)

=(4154)dec

Decimal to hex conversion

Decimal to hex can be convert by seccesevely dividing with 16 and keeping track on remainder.

let we convert (4154)dec to its hex value.

(4154)dec =(??)hex

4154/16 = 259 remainder(4154-4144) 10 A lsb

259/16 = 1 remainder(259-256) 3 03

1/16 = 0 remainder(1- 1 01 msb

Thus

(4154)dec=(0103A)hex

Hex to binary conversion

hex to binary conversion is carried out by replacing hex bit of equivalent four digit binary bit.

let we convert (103A)hex to (??)bin value.

(103A)hex =(0001 0000 0011 1010)bin

=(1000000111010)bin