ptuece.loremate.com digital electronics 1

Upload: tapas-banerjee

Post on 03-Jun-2018

246 views

Category:

Documents


0 download

TRANSCRIPT

  • 8/12/2019 Ptuece.loremate.com Digital Electronics 1

    1/8

    http://ptuece.loremate.com/die/node/8 March 7, 2012

    Digital Electronics

    Q 34 Represent the decimal number 8620 in BCD and as a binary number.

    Ans. (8620)10 = (?)BCD = (?)2

    (1000 01.10 0010 0000)BCD

    Q 35. List the advantages of octalover hexadecimal number system.

    Ans. When dealing with largequantity of binary numbers of manybits, it is easy and more efficientfor us to write the numbers in octalform. This system is used to

    express large numbers as used incomputers e.g. 16 bits or 32 bits used to express data, memory address, instruction code,processor status etc. Moreover, octal multiplication and division are more easy than thehexadecimal number system. As they are complex because they make use of alphabets A to Fafter 0 to 9. -

    Q 36. Convert decimal 225.225 to binary, octal and hexadecimal bases.

    Ans. 225.225

    Q 37. Find twos complement of the numbers (i)

    01001110 ; (ii) 01100100.

    Ans (i) 01001110

    (ii) 01100100.

    Q 38. What is the need to study octal andhexadecimal system, when the Digital

    machine understands only binary code

    Ans. The binary code consists of only two binary digits0 and 1 known as bits. All the combinations of codesare with the help of 0s and 1. It is very hard toremember the code in the form of 0s and 1s when itbecomes lengthly. Secondly, chances of error are muchmore long sequences of binary code. Moreover, threebit and four bit combinations are possible octal andhexadecimal systems.

    Q 39. Where do we use ASCII, Excess-3 and Graycodes?

    Ans. ASCII : American Standard Code forInformation Interchange is a 7 bit code. Inlanguage, only two symbols 0 and 1 areused. It is not enough to communicate usingthese two symbols between two computers.

    http://www.printfriendly.com/print?url=http%3A%2F%2Fptuece.loremate.com%2Fdie%2Fnode%2F8&partner=a2a#
  • 8/12/2019 Ptuece.loremate.com Digital Electronics 1

    2/8

    Users require 26 alphabets capital andsmall. Numbers 0 to 9, punctuation marksand many other symbols. This all is availablein ASCII code.

    Gray Code : Gray code is mainly used inshaft position encoders. A shaft encoderbasically produces a code word which

    represents the angular position of the shaft.

    Excess-3 code : It is non-weighted code. It is derived from8421 BCD code. It is a sequential and self complimentingcode.

    Q. 40. Convert decimal 27. 125 to octal.

    Ans.

    Q 41. Determine the decimal representation of a negative

    integer whose 8-bit twos complement code is 10010110.

    Ans. Taking original no. = 10010110

    Q 42. Give the binary code for the hexadecimal number AEO.

    Ans.

    So (1010 1110 0000)2

    Q 43. Convert decimal 100. 625 to binary, octal and hexadecimalcodes.

    Ans. In binary:

    (1100100.101)2

    In Octal:

    (144.5)8

    In Hexadecimal:

    (64.A)16

    Q. 44. How negative numbers are accountedfor in digital system?

    Ans. In digital system sometimes signednumbers are used. To denote positive numbers (+) plussign is used and 0 is used as MSB bit in binary numbers. Incase of negative numbers (-) minus sign is used to denote

    it. In binary system, bit us used as MSB bit in negativenumbers.

    e.g. (+7)2 = (0111)2

    (-7)2 = (1111)2

  • 8/12/2019 Ptuece.loremate.com Digital Electronics 1

    3/8

    Q 45. Give the binary code for the hexadecimal numberF01.

    Ans. (F01)16 = (?)2

    Q 46. Determine the decimal representation of a negative integer whose 8bit

    twos complement code 10010110.

    Ans. 8-bit 2s complement code is:

    10010110

    Its 2s complement is:

    Q 47. Subtract the following numbers

    (i) (1100.10)2 (111.01)2

    (ii) (10001.01)2 (1111.11)2

    Ans. (i) Add 1100.10 and is complement of111.01

    There is no carry, so answer is ye and in complement form, Again taking complement.

    (0010.11)2 Ans.

    (ii) Add 10001.01 and 1s complement of 1111.11

    Q 48. Add the following numbers in Excess - 3Code.

    (i) 108 + 789

    (ii) 275 + 496

    Ans. Add in excess-3 code

    (i) 108 + 789

    (ii) 275 + 496

    (i) Firstly converting (108)10 and (789) 10 to excees-3 form

    Adding

    If no carry i.e. c = 0, subtract 0011

    If carry i.e. c = 1, add 0011

  • 8/12/2019 Ptuece.loremate.com Digital Electronics 1

    4/8

    (ii) (275) 10 + (496) 10

    Firstly, converting into Excess-3 form

    Addition of (275) 10 + (496) 10

    If no carry i.e. c = 0, subtract 0011

    If carry i.e. c = 1, add 0011 to sum

    = (1010 1010 0100) or (771)10

    Q 49. Subtract the following numbers

    (i) (BC5)16 (A2B)16 = ?

    (ii) (1 75.6)8 (47.7)8 = ?

    Ans. (i) Firstly, convert it into binary form (4 digits)

    (ii) Firstly, convert it into binary (3 digits)

    Q 50. Add the following numbers in BCD

    (i) 89.6 + 273.7

    (ii) 205.7 + 193.65

    Ans, (i) 89.6 + 273.7

    Add (0110)2 to only the invalid BCD numbers.

    (ii) 205.7 + 193.65

    Add (0110)2 to only the invalid BCD numbers.

    Q 51. How will you detect overflow in signed magnitude and 2s

    complement

    integer additions?

    Ans. Let (10)10 and (11)10 be the two integers.

  • 8/12/2019 Ptuece.loremate.com Digital Electronics 1

    5/8

    In signed magnitude

    (10) 10 = (1010)2

    (11) 10 = (1011)2

    Addition :

    The end around carry is the overflow in this case.

    In 2s complement:

    The end around carry is the overflow in this case.

    Q 52. What are the applications of hexadecimal system?

    Perform the following conversions

    (a) (225225)10 into hexadecimalnumber.

    (b) (10011.1101)2 into hexadecimalnumber.

    Ans. Applications of hexadecimal,system :

    1. It is particularly useful for humancommunications with a computer.

    2. It is used in memory systems.

    3. It is useful to convert hexadecimal to binary and vice-versa a easily.

    (a) (225.225)10 = (?)16

    Integer Part:

    Fractional part:

    Q 53. What is the importance and applications of Graycode? Convert the binary

    number 10100111 to Gray code.

    Ans. Importance of gray code is that it has a very specialfeature as only one bit will change each time when the decimalnumber is incremented by 1. Due to this reason it is alsoknown as unit distance code.

    Applications of Gray Code

    1. These are used in the shaft position encoders.

    2. These are used in the optical discs to produce anappropriate binary code.

  • 8/12/2019 Ptuece.loremate.com Digital Electronics 1

    6/8

    Q 54. Represent the decimal numbers (a) 27, (b) 396 and (c)4096 in binary form in (i) ASCII code, (ii) Gray code and (iii )Excess 3 code.

    Ans.

    (11011)2

    (27)10 = (11011)2

    (27)10 = 00100111 in BCD

    (i) ASCII Code

    0110010 0110111

    (ii) Gray Code

    (11011)2 =

    (iii) Excess 3 Code

    (27)10

    Binary = (101111000)2

    (396)10 = 0011 1001 0110 BCD

    (i) ASCII Code

    0110011 0111001 0110110 ASCII code

    (ii) Gray Code

    (iii) Excess 3 Code

    (c) (4096) =

    (4096)10 = (1000000000000)2

    (i) ASCII code (4096)o

    0100 0000 1001 0110 BCD

    0110100 0110000 01110010110110 ASCII code

    (ii) Gray Code

  • 8/12/2019 Ptuece.loremate.com Digital Electronics 1

    7/8

    (iii) Excess 3 Code

    Q 55. If A = 1101 and B = 101 find:

    Ans A = 1101, B = 0101

    Q 56. Find the difference (6C1-1DA) in thehexadecimal system. Check your resultconverting all number, i.e. the given twonumbers and the result obtained fromsubtraction to the decimal system.

    Ans. (6C1)16.(1DA)16

    Firstly convert it into binary form (4 bits. each)

    (6C1)16.(1DA)16 = (4E7)16

    Conversion to decimal system :

    Hence, verified.

  • 8/12/2019 Ptuece.loremate.com Digital Electronics 1

    8/8