Thursday, November 11, 2010

Logic Gates, this one total Universal.


Expressing my apology for not posting the notes in time, but it is very difficult to prepare the note in HTML format with so many diagrams. We already discussed about logic gates in previous blog and given you the idea of drawing as well as Boolean laws and theorems. Today we will look at the universal gates NAND and NOR. Any logic circuit can be built using only NAND gates, or only NOR gates. They are the only logic gate needed to build a circuit. Before that I am giving one small example of drawing logic gate

Draw a Logic diagram for following Boolean expression
(x.y’)+(y’.z)

Truth Table
x y z xy' y'z (x.y’)+(y’.z)
0 0 0 0 0 0
0 0 1 0 1 1
0 1 0 0 0 0
0 1 1 0 0 0
1 0 0 1 0 1
1 0 1 1 1 1
1 1 0 0 0 0
1 1 1 0 0 0



Different Logic Gates using NAND and NOR Gates.
NOT using NAND :   
OR using NAND
AND using NAND
NOR using NAND

NOT using NOR
OR using NOR

AND using NOR

NAND using NOR

Drawing these diagrams are very painful experience, if you find any error please inform me. My Next blog will be also about Boolean laws and algebra.
!!!Wish you all A Very Very Happy and prosperous Diwali!!!

Thursday, October 14, 2010

Boolean Laws and Teorems - Go by the rule


Sorry, could not post the notes as scheduled, was little busy with other thing. Today giving some Boolean Laws and Theorems. Boolean logic was developed by an English mathematician George Boole, used to construct and solve Boolean algebra and helped to design the electrical circuits.

The basic laws of Boolean algebra:

 


Proof (Using Truth Table)

A + A.B = A

A( A + B) = A

A

B

A.B

A+A.B


A

B

A+B

A.(A+B

0

0

0

0


0

0

0

0

0

1

0

0


0

1

1

0

1

0

0

1


1

0

1

1

1

1

1

1


1

1

1

1


Proof (Using Postulate)


If A and B  are elements of a Boolean algebra

A+A.B = A


  A( A + B) = A


A.1+A.B

A.1 = A

  A.A + A.B

Distributive Law

A(1 + B)

Distributive Law

  A + A.B

Idempotent law

A.1

Law on the property
of 1

  A.1 + A.B

A.1 = A

A

A.1 = A

  A(1 +  B)

A.1



  A

A


Now just tell you about principle of duality.
Principle of Duality
The dual of any statement in a Boolean algebra is the statement obtained by interchanging OR with AND, and simultaneously inter-changing the elements 0 and 1 in the statement.



IdentityBoolean


Dual

A + 0 = A

  A.1 = A

A + 1 = 1

  A.0 = 0

A + A = A

  A.A=A

A + A’ = 1

  A.A’ = 0

A + B = B + A

  A . B = B . A

A+ B.C = (A + B)(A + C)

  A(B + C) = A . B + A. C

A( A + B) = A

  A+A.B=A

A + AB = A + B

  A.(A+B) = A

(A+ B)’ = A’.B’

  (AB)’=A’ + B’


DeMorgan’s theorems provide mathematical verification of: :

1. The equivalency of the NAND and negative-OR gates

2. The equivalency of the NOR and negative-AND gates.


(A.B)'    =

A'+B'


(A + B)'       =

A'.B'

**Change the sign and break the line.


(A.B)' = A'+B'

(A + B)' = A'.B'

A

B

A.B

(A.B)'

A'

B'

A'+B'

     

A

B

A+B

(A+B)'

A'

B'

A'.B'

0

0

0

1

1

1

1


0

0

0

1

1

1

1

0

1

0

1

1

0

1


0

1

1

0

1

0

0

1
0

0

1

0

1

1


1

0

1

0

0

1

0

1

1

1

0

0

0

0


1

1

1

0

0

0

0


Next time it will be time for Logic circuits using Logic Gates.


!!!Wish all of you a Shuvo Vijaya Dashami / Happy Dussera!!!

Thursday, September 16, 2010

Some Logical Moments With Logic Gates


Sorry for this long break as I was away, could not post the required notes as schedule d, today we will go through basic logic gates.

Logic Gates:

A logic gate is an elementary digital circuit. Logic gates process signals which represent true or false. Normally the positive supply voltage +Vs represents true or high and 0V represents false or low.

Truth Table:
Truth tables are used to help show the function of a logic gate. Number of terms depend upon the number of Input. It will be always 2n,where 'N' is the numbers of Inputs.


AND gate
The AND gate is an electronic circuit that gives a high output(1) if all its inputs are high. A dot (.) is used to show the AND operation i.e. A.B.

Truth Table
AND Gate
A B A.B
0 0 0
0 1 0
1 0 0
1 1 1

OR Gate

The output is true if one of input is true or both of them are true. An OR gate can have two or more inputs.
Truth Table
OR Gate
A B A+B
0 0 0
0 1 1
1 0 1
1 1 1

NOT gate (inverter)

The output is true when the input A is NOT true, the output is the inverse of the input. A NOT gate can only have one input. A NOT gate is also called an inverter.


Truth Table
NOT Gate
A
Ā
0 1
1 0

NAND Gate:
The NAND gate operates as an AND with NOT gate to follow. It acts in the manner of the logical operation AND followed by negation. The output is false if both inputs are true. Otherwise, the output is true.

Truth Table
NAND Gate
A B (A.B)'
0 0 1
0 1 1
1 0 1
1 1 0

NOR Gate:

The NOR gate operates as an OR with NOT gate to follow. It acts in the manner of the logical operation Or followed by negation. The output is true if both inputs are false, otherwise, the output is false.

Truth Table
NOR Gate
A B (A+B)'
0 0 0
0 1 0
1 0 0
1 1 1

XOR Gate:

The 'Exclusive-OR' gate is a circuit which will give a high output if either, but no t both, of its two inputs are high. While writing the truth table using more than three input remember when numbers of 1 is odd in input values then output will be 1. An encircled plus sign Å is used to show the XOR operation. The Boolean Expression : A'B + B'A
Truth Table
XOR Gate
A B A'B + B'A
0 0 0
0 1 1
1 0 1
1 1 0
Diagram Using Logic Gates

XNOR Gate:

The XNOR [Exclusive-NOR] gate is a XOR gate followed by an inverter. Its output is true if the inputs are the same, and false if the inputs are different. The Boolean Expression : (A'B + B'A)'
Truth Table
XNOR Gate
A B (A'B + B'A)'
0 0 1
0 1 0
1 0 0
1 1 1

Next time I will come up with Boolean Laws and Theorems.


!!!Time to say Bye, today we move to Karnataka and say Hogibitt Barthene Or Olleyadu Matthe Siguva.!!!

Thursday, August 12, 2010

Addition & Subtraction - Other Number System


Subtraction of Octal number, Hexadecimal and Decimal can be done using compliments too. Therefore, a few examples are given below for Octal - 7 and 8 compliment, Hexadecimal - 15 and 16 compliments and for Decimal - 9 and 10 compliments.


Octal Number

Example : Using 7 Compliments

(1546)8 - (467)8


Minuend : 1546 and Subtrahend : 467. Minuend contain 4 digits where Subtrahend having 3, so add a leading 0 to Subtrahend 0467. Now 7'th compliment mean subtract the Subtrahend from 7's.


  7 7 7 7
  0 4 6 7
-------------
  7 3 1 0
-------------

Now add the Subtrahend to the minuend

   1
   1 5 4 6
+ 7 3 1 0
-------------
1 1 0 5 6         (Discard the Carry [1])
-------------
    1 0 5 6
            1  ( Adding Carry digits [Refer to Binary subtraction])
-------------
    1 0 5 7

Result of : (1546)8 - (467)8 = (1057)8



Example : Using 8 Compliments

(1546)8 - (467)8


Minuend : 1546 and Subtrahend : 467. Minuend contain 4 digits where Subtrahend having 3, so add a leading 0 to Subtrahend 0467. Now 7'th compliment mean <> subtract the Subtrahend from 7's.

  7 7 7 7
  0 4 6 7
-------------
  7 3 1 0
+        1     (Add one to the 7 compliment)
-------------
  7 3 1 1    Now add the Subtrahend to the minuend
-------------  

           1
   1 5 4 6
+ 7 3 1 1
-------------
1  1 0 5 7  (discard the Carry digits)
-------------

Result of : (1546)8 - (467)8 = (1057)8



Hexadecimal Number

Subtraction of Hexadecimal number can be done with with 15 or 16 compliments
Example : Using 15 Compliments

(15CB)16 - (2BC)16 = 1 5 12 11 - 2 11 12

Minuend : 15CB and Subtrahend : 2BC Minuend contain 4 digits where Subtrahend having 3, so add a leading 0 to Subtrahend 0 2 11 12. Now 15'th compliment mean  subtract the Subtrahend from 15's.

15 15 15 15
  0   2 11 12
-------------
 15 13  4  3    Now add the Subtrahend to the minuend
-------------

1 1
   1  5 12  11
 15 13   4   3
---------------
1 1 3 0 14
              1 ( Remove the extra carry digits and add it to the remainder)
-------------
1 3 0 15 = 130F

Result of : (15CB)16 - (2BC)16 = (130F)16



Example : Using 16 Compliments

(15CB)16 - (2BC)16 = 1 5 12 11 - 2 11 12

Minuend : 15CB and Subtrahend : 2BC Minuend contain 4 digits where Subtrahend having 3, so add a leading 0 to Subtrahend 0 2 11 12. Now 15'th compliment mean subtract the Subtrahend from 15's.

15 15 15 15
  0   2 11  12
---------------
 15 13  4   3
+               1 (Add 1 [16 Compliment])
---------------
 15 13  4  4  Now add the Subtrahend to the minuend
---------------
  1   1
  1   5 12 11
15 13  4    4
--------------
1 1  3   0  15 ( Discard the Carry digit)
--------------
1 3 0 15 = 130F

Result of : (15CB)16 - (2BC)16 = (130F)16

Decimal Number

We can do it for our (yes our) Decimal number system too. Subtraction of decimal number can be done with with 9 or 10 compliments

Example : Using 9 Compliments

(1497)10 - (879)10

Minuend : 1497 and Subtrahend : 879 Minuend contain 4 digits where Subtrahend having 3, so add a leading 0 to Subtrahend 0879 . Now 9'th compliment mean subtract the Subtrahend from 9's.

 9 9 9 9
 0 8 7 9
----------
 9 1 2 0                 Now add the Subtrahend to the minuend
----------
     1
 1  4  9  7
 9  1  2  0
--------------
1 0 6 1 7
            1      ( Remove the extra carry digits and add it to the remainder) +1
---------------
6 1 8

Result of : (1497)10 - (879)10=(618)10


Example : Using 10 Compliments

(1497)10 - (879)10

Minuend : 1497 and Subtrahend : 879 Minuend contain 4 digits where Subtrahend having 3, so add a leading 0 to Subtrahend 0879 . Now 9'th compliment mean subtract the Subtrahend from 9's.

  9 9 9 9
  0 8 7 9
----------
  9 1 2 0       (add 1 to make it 10 compliment)
        + 1
----------
  9 1 2 1        Now add the Subtrahend to the minuend
----------

      1
   1 4 9 7
   9 1 2 1
--------------
1 0 6 1 8      (Discard the carry digits)
-------------
      6 1 8 
-------------

Result of : (1497)10 - (879)10= (618)10



We yet to finish with number system, but promise you, next one will be the last
in these series!.

Thursday, July 29, 2010

Arithmetic Operation -Octal & Hexadecimal

Octal Addition and Subtraction : Radix or Base for Octal numbers are 8 and consists 0 to 7. While adding we follow following rules:

Addition

We already know that 8 is the base or radix of the Octal Number System, after adding of two digit if you get below 8 then write down it, but if it is more than 7 then divide the result by 8 and write down the remainder in the place of result and the quotient as carry numbers.

Example-1

(447)8 + (622)8
                      
                                                                    Rules

       1                     1) 7 + 2 = 9 (above 7) 9/8 Quotient=1 Remainder=1 (Carry = 1)
 ------------            2) 4 + 2 + 1(carry)=7 is below 8 (Carry = 0)
    4 4 7                   3) 4 + 6 = 10 (above 7) 10/8 Quotient=1 Remainder=2(Carry = 1)
    6  2 2
 ------------
  1 2 7 1
 ------------
  Answer :  (447)8 + (622)8= (1271)8



Example-2

(237.54)8 + (753.74)8
    
                                                            Rules

    1 1 1 1                1) 4 + 4 = 8 (8/8 Quotient=1 Remainder=0)(Carry = 1)
---------------          2) 5 + 7 + 1 (carry) = 13(13/8 Quotient=1 Remainder=5)Carry = 1)
   
3 7 . 5 4               3) 7 + 2 + 1 (carry) = 10(10/8 Quotient=1 Remainder=2)(Carry = 1)
    7 2 . 7 4              4) 3 + 7 + 1 (carry) = 11(11/8 Quotient=1 Remainder=3)(Carry = 1)
---------------
 1 3 2 . 5 0
---------------

  Answer :  (37.54)8 + (72.74)8= (132.50)8


Subtraction


Octal Subtraction : While subtracting if minuend digit smaller than subtend then add 8 to the minuend digit and then subtract and in the process 1 should be borrow from the minuend digit at the end.

Example-1

(345)8 - (126)8

                                                    Rules
     1                     1) 5 is less than 6 so 5+8 = 13 - 6= 7 (Borrow = 1)
------------          2) 4 -1(borrow) = 3 is bigger than subtend so 3 - 2=1(Borrow = 0)
  
3 4 5                 3) 3 -1 = 2 (Borrow = 0)
   1 2 6
 ------------
   2 1 7
 ------------
  Answer :  (345)8 - (126)8 = (217)8



Example-2

(246.24)8 - (157.56)8

                                                           Rules


   1 1 1    1           1) 4 + 8 - 6 = 6 (Borrow = 1)
 --------------      2) 2-1(borrow) =1 + 8 - 5 = 4 (Borrow = 1)
    2 4 5 .2 4         3) 5-1(borrow) =4 + 8 - 7 = 5 (Borrow = 1)
   1 5 7 . 5 6         4) 4-1(borrow) =3 + 8 - 5 = 6 (Borrow = 1)
 ---------------       5) 2-1(borrow) =1 - 1 = 0 (Borrow = 0)
   0 6 5 . 4 6
 ---------------

  Answer :  (246.24)8 - (157.56)8 = (65.56)8



Hexadecimal Addition and Subtraction : Radix or Base for Octal numbers are 16 and consists 0 to 15 (0 - 9, A, B, C, D, E, F). While adding we follow following rules:

Addition

We already know that 16 is the base or radix of the Hexadecimal Number System, after adding of two digit if you get below 16 then write down it, but if it is more than 15 then divide the result by 15 and write down the remainder in the place of result and the quotient as carry numbers. Replace Alphabet with its equivalent decimal numbers. e.g.. A = 10 or E = 14

Example-1

B83)16 + (A2D)16 = (11 8 3)16 + (10 2 13)16

                                                             Rules

         1                 1) 3 + 13 = 16(above 15) 16/16 Quotient=1 Remainder=0(Carry=1)
 ------------          2) 8 + 2 + 1(carry)= 11 is below 15 (Carry=0)
    11   8   3         3) 10 + 11 = 21(above 15) 21/16 Quotient=1 Remainder=5(Carry=1)
    10   2 13
 ------------
  1 5   11 0  = 1 5 B 0
 ------------

  Answer :(B83)16 + (A2D)16 = (15B0)16



Example-2

(AB.CD)16 + (D5.2F)16 = (10 11.12 13)16 + (13 5.2 15)16

                                                      Rules

   1          1                1) 13 + 15 = 28 (28/16 Quotient=1 Remainder=12(Carry = 1))
 -----------------        2) 12 + 2 + 1(carry) = 15 is below 15 (Carry = 0))
   10 11 .12 13          3) 11 + 5 = 16 (16/16 Quotient=1 Remainder=0 (Carry = 1))
   13  5  .  2 15         4) 10 + 13 + 1(carry)= 24 (24/16 Quotient=1 Remainder=8 (Carry = 1))
-----------------
  1 8 0  . 15 12       = 180.FC16
------------
  Answer : (AB.CD)16 + (D5.2F)16  = (180.FC)16



Subtraction


Hexadecimal Subtraction : While subtracting if minuend digit smaller than subtend then add 16 to the minuend digit and then subtract and in the process 1 should be borrow from the minuend
digit at the end.

Example-1

(BA3)16 - (AB4)16 = (11 10 3)16 - (10 11 5)16)

                                                             Rules

         1              1) 3 is less than 5 so 3 + 16 = 19 - 4= 15 (F) (Borrow = 1)
-------------       2) 10 - 1(borrow) = 9 + 16 = 25 - 11 = 14 (E) (Borrow = 1)
  11 10  3           3) 11 -1 = 10 = 10 - 10 = 0 (Borrow = 0)
 
10 11  4
------------
   0   E   F
------------

  Answer : (BA3)16 - (AB4)16 = (EF)16



Example-2

(C5.A2)16 - (A7.B3)16 =  ((12 5.10 2)16 - (10 7.11 3)16)

                                               Rules

   1    1    1                 1)  2 + 16 - 3 = 15 (F) (Borrow = 1)
---------------              2)  10-1(borrow) =9 + 16 - 11 = 14 (E) (Borrow = 1)
  12  5 . 10  2             3)  5-1(borrow) =4 + 16 - 7 = 13 (D) (Borrow = 1)
  10  7 . 11  3             4)  12-1(borrow) =11 - 10 = 1
---------------
  1  D .  E   F
---------------
  Answer : (C5.A2)16 - (A7.B3)16 = (17.EF)8



After fortnight coming back with some more with system only. !

Thursday, July 15, 2010

Binary Addition & Subtraction - Back to the basic

Binary Addition  : Radix or Base for Binary numbers are 2 and having two digits 0 and 1. so while adding we follow following rules:


0 + 0 = 0
0 + 1 = 1
1 + 0 = 1
1 + 1 = 0 and carry 1 (Decimal 2 and Binary 10)
1 + 1 + 1 = 1 and carry 1 (Decimal 3 and Binary 11)
1 + 1 + 1 + 1 = 0 carry 10 (Decimal 4 and Binary 100)




Example : 1 Example : 2
Carry >>
       1 1 1 1
Carry >>
    1  1 1 1      1
    1 1 1 0 1     1 0 1 0 . 1 0 1

    0 1 1 1 1

    1 1 0 1 . 1 0 1
Answer :  1 0 1 1 0 0 Answer :  1 1 1 0 0 . 0 1 0

Binary Subtraction
While subtracting we follow the following rules:
0 - 0     = 0
0 + 1     = 1  borrow 1
1 + 0     = 1
1 + 1     = 0


Example : 1 Example : 2

Borrow >>

    1 1 1

Borrow >>

          1

    1 1 1 0 1

   1 0 1 0 . 1 0 1


    0 1 1 1 1


    1 0 0 1 . 1 0 0
Answer :     0 1 1 1 0 Answer :     0 0 0 1 . 0 0 1




Subtraction often is very tricky, you can solve it by using 1's Compliment or 2's Compliment

Like you have 50 - 12 = 38 same 50 + (-12) = 38



Compliment means Invert or all 0's change to 1 and 1's become 0. So Rules for 1's Compliment is :

Make the both side equal by placing leading 0's. Replace all the 1's with 0's and the 0's with 1's, then add both the numbers.

If there was 4 bits and after adding you getting five, the leading bits known as carry bits. If there is a carry bits then remove that from leading position and add to the result of the addition and write the answer down.



 Example :(10010)2 - (1001)2 Minuend : 10010 and Subtrahend : 1001. Minuend contain 5 bits where Subtrahend having 4, so it will be 01001 (both side with same numbers of digits and done by adding leading zeros) 01001 (decimal 9) 0110 (one's complement) Add




Example : 1  Addition

Carry >>

       1 1 1
   18    1 0 0 1 0

+ -9

    1 0 1 1 0
 1 0 1 0 0 0
    0 1 0 0 0
 +             1   
Answer :+9     0 1 0 0 1

1 is a carry bit because after adding two four bits number we are getting 5 bits, remove the carry from there and add to the remaining part of the result.

Result of : (10010)2 - (1001) = (1001)2 or 18 + (-9) = 9



The two's complement of a binary number is obtained by:
1. Replacing all the 1's with 0's and the 0's with 1's (1's Compliment).
2. Adding 1 to the result of 1's compliment using the rules of binary addition.
Now you have the two's complement. The decimal subtraction 18 - 9 = 9 is the same as adding (18) + (-9) = 9
1. Convert the number to be subtracted to its two's complement:(10010)2 - (1001)2 = (10010)2 - (01001)2, 01001 (decimal 9) 10110 (one's complement) + 00001 (add 1 (two's complement)) 10111 (We get)

10111 now represents -9.


Example : 1  Addition

Carry >>


       1 1 1
  18    1 0 0 1 0

+ -9

    1 0 1 1 1
Answer :+9 1 0 1 0 0 1
Note that the final carry 1 is ignored and dropped permanently. So you get :Result of : (10010)2 - (1001) = (1001)2 or 18 + (-9) = 9



If no carry that indicate a negative result. When a subtraction produce negative result then you have to re-compliment the result of addition to get the correct answer.
(1000)2 - (1001)2 = (1000)2 - (0110)2, (one's complement).

Example : 1  Addition

Carry >>

     8    1 0 0 0

+ -9

    0 1 1 0
    1 1 1 0


If no carry bit then re-compliment the result 1110 = 0001 (after 1's compliment)   Result of : (1000)2 - (1001) = (-1)2 or 8 + (-9) = -1  

Answer :  (1000)2 - (1001)2 = (-0001)2




With above example with 2's compliment :(1000)2 - (1001)2 1001 (decimal 9) after 1'compliment we get 0110 + 1 (2's Compliment ) ------- 0111

Example : 1  Addition

Carry >>


 
    8    1 0 0 0

+ -9

    0 1 1 1
    0 1 1 1


If no carry bit then re-compliment the result

0111 = 1111 (after 1's compliment) 1111+1 = 0001(2's compliment)


The result will be -0001 Result of : (1000)2 - (1001) = (-1)2 or 8 + (-9) = -1



 Binary Multiplication

Binary multiplication is same as normal multiplication only we have to know the rules of addition properly.
(1010.11)2 x (101.10)2



Example : 1
      
            1 0 1 0 . 1 1
 x                   1 0 1 . 1 0
                  0 0 0 0 0 0
               1 0 1 0 1 1
            1 0 1 0 1 1
         0 0 0 0 0 0

     1 0 1 0 1 1
  1 1 1 0 1 1 . 0 0 1 0

Answer : (1010.11)2 x (101.11)2= (1javascript:void(0)11011.0010)2



Binary Division

Binary division too is same as decimal division but binary subtraction rules going used here.
(110011)2 / (111)2

Example : 1
1 1 1   1 1 0 0 1 1 1


     1 1 1    


  1 0 0 0 1


     1 1 1

        1 1 1 1


        1 1 1

        0 0 0

          1 1 1
Answer : (110011)2 / (111)2= (111)2


!!!Hope it will be helpful!!!

Thursday, July 1, 2010

Number Systems-II - This one not that systematic, do not get lost.


Last time we have seen the methods and way to convert the Decimal numbers to Binary, Octal and Hexadecimal. Today I will tell you how you can convert the Binary, Octal and Hexadecimal numbers to Decimal

Binary to Decimal

(101)2=(?)10  (Convert binary 101 to decimal). Now we have 101 means three digit, so let us consider n=3.

101 = 1 x 2n-1+ 0 x 2n-2 + 1 x 2n-3

= 1 x 23-1 + 0 x 23-2 + 1 x 2n-3
= 1 x 22 + 0 x 21 + 1 x 20
= 1 x 4 + 0 x 2 + 1 x 1
= 4 + 0 + 1 = 5
= (101)2 = (5)10


For fractional Numbers :

(.11)2=(?)10

Here 'n' is 2,
.11 = 1 x 2n-(n+1) + 1 x 2n-(n+2)
= 1 x 2-1 + 1 x 2n-2
= 1/21 + 1/22
= 1/2 +1/4
= 3/4 = .75
= (.11)2 - (.75)10


Another example : (11.011)2 - (?)10
= 1 x 21+ 1 x 20             + 0 x 2-1 + 1 x 2-2 + 1 x 2-3
 = 1 x 21 + 1 x 20           + 0 x 2-1 + 1 x 2-2 + 1 x 2-3
 = 2 + 1                         + 1/4 + 1/8
= 3.3/8  = 3.375
= (11.011)2 - (3.375)10


Easy way out:

8 4 2 1   2 4
1 0 0 1 . 1 1
Check the numbers on the top, its 20 onwards 2n-1, values written on the top for whole number right most digit to start with and for fractional numbers left most digit. For whole numbers add the values for non zero elements like 1 and 8 because 4 and 2 having a '0' below it. So by adding 8 + 1 =9 and divide the values for fractional numbers: 1/2 + 1/4 = 3/4 = .75.

(1001.11)2=(9.75)10



Octal to Decimal

if you understand the conversion of Binary to decimal then other number system will be same process with different power.

Octal to Decimal
(56.34)8=(?)10

Two digit means n=2,
 = 5 x 8n-1+ 6 x 8n-2          + 3 x 8n-(n+1)+ 4 x 8n-(n+2)
= 5 x 81+ 6 x 80                 + 3/81+ 4 x 82
= 5 x 8 + 6 X 1                  + 3/8 + 4/ 64
= 40 + 6                             + 3/8 + 4/ 64
= 46.4375
= (56.34)8 = (46.4375)10



Hexadecimal to Decimal

(75.55)16=(?)10
Two digit means n=2, so
 = 7 x 16n-1+ 5 x 16n-2         + 5 x 16n-(n+1)+ 5 x 16n-(n+2)
= 7 x 161+ 5 x 160               + 5/161+ 5 x 162
= 7 x 16 + 5 x 1                   + 5/16 + 5/256
= 112 + 5 + 5/16 + 5/256
= 117.332031

(75.55)16 = (117.332031)10



Another Example :

(3A.B)16=(?)10

Here 'A to F' to be considered as 10 to 15 and as a single unit
3 x 16n-1+ 10 x 16n-2        +11 x 16n-(n+1)
= 3 x 16 + 10 x 1              + 11/16
=  48 + 10                        + 11/16
=   58.6875
= (3A.B)16 = (58.6875)10



Octal to Binary and Binary to Octal

Last number of Octal number system is 7. 7 equivalent to binary is 111, that means three digit. so while converting Octal to binary just write down the binary value of the octal number.

(56.34)8=(?)2

   5     6   .  3    4
101 110   011 100(56.34)8=(101110.011100)2


Same for Binary to Octal, only first you have to three digits of binary nose, where for whole number start from last digit and fractional numbers start from first digit. At the end if numbers of digits less than three than put a leading zero for whole number and a trailing zero for fractional part.

(1011011101.1101101)2=(?)8

001 011 011 101 . 110 110 100

1      3      3     5   .   6    6     4

(1011011101.1101101)1=(13335.664)8



Hexadecimal to Binary and Binary to Hexadecimal

Last number of Octal number system is F means 15. 15 equivalent to binary is 1111, that means four digit. so while converting Hexadecimal to binary just write down the binary value of the Hexadecimal number.
(7A.3B)16=(?)2

0111 1010   . 0011 1011

7         A      .    3       B

(7A.3B)16=(01111010.00111011)2


Same for Binary to Hexadecimal, only first you have to group four bits for whole numbers right to left and for fractions left to right  At the end if numbers of digits less than three than put a zero at leading position for whole numbers and a trailing zero for fractional part.
(1010011100.1101101)2=(?)8

 0010 1001 1100  .  1101 1010

2          9       12    .    13      10

(1011011101.1101101)2=(29C.DA)16