Show the r’s complement, Electrical Engineering

Assignment Help:

Q. Show the r’s Complement?

Step1- get the (r-1)'s complement

Step 2- add 1 to the result ex.

           93510

                                    9 9 9

                                    9 3 5 -

                           0 6 4  (r-1)'s complement

                          0 6 4

                              1 +

                           0 6 5

  • When using the r's complement we add usually, and ignore any carry from the most significant digit (MSD)
  • If the result is in negative, it will be in r's complement form ex.

            395 - 210

210 is 789 + 1 = 790 in 10's complement form

            395

            790+

            185     

Why Use 2's Complement

  • The left-most bit is still a sign bit

            1  for negative

            0  for positive

  • One way to write 0

            +0 0000 0000

            -0  0000 0000  (how?)

  • With n bits we can represent -2n-1 to ( 2n-1 - 1)

Let's now consider the subtraction 22 - 35, again both represented as 7-bit numbers with a sign bit.

                        +22 in binary is:                 00010110
                        +35 in binary is:                 00100011
                        -35 in binary is:                  10100011
                        -35 in 1's complement is:    11011100

The sum to be calculated is now:

                                            00010110
                                         + 11011100
                                            11110010 

This time the addition does not produce a 9th bit, but the sign bit is 1. In this case it again tells us two things:

  • the answer is negative
  • the answer is represented in 1's complement notation

So to get the final answer we need to turn our answer into binary. If the 1's complement notation is 11110010 then the binary representation is 10001101 (note - the sign bit doesn't change, it's still a negative number!). This is the binary for -13, again, the correct answer.


Related Discussions:- Show the r’s complement

Show the conditions necessary for sustained oscillation, The conditions nec...

The conditions necessary for sustained oscillation can be summarized as follows: 1. There should be a positive feedback. 2. The loop gain of the circuit must be equal to or g

Schematic diagram of led based system, Q. Schematic Diagram of LED based Sy...

Q. Schematic Diagram of LED based System ? As shown in the two schematic diagrams above, the LEDs in a seven-segment display are not isolated from each other. Rather, eith

Discuss direct memory access, Discuss DMA definition. Direct memory ac...

Discuss DMA definition. Direct memory access (DMA) is a process wherein an external device takes over the control of system bus by the CPU. Direct memory access is for high-sp

If a feeder circuit-breaker trips what action is required, Q. If a feeder c...

Q. If a feeder circuit-breaker trips, what action is needed? Ans: First isolate the faulty feeder check the faulty area on which fault the breaker was tripped (open circuit,

C R O DELAY LINE, WHAT IS THE FUNCTION OF DELAY LINE IN CRO

WHAT IS THE FUNCTION OF DELAY LINE IN CRO

What are magnetic materials, Magnetic materials (A) provide path to ma...

Magnetic materials (A) provide path to magnetic flux. (B) are good insulators. (C) are semiconductors. (D) None. Ans: Magnetic materials provide path to

What speed would the machine be capable of converting energy, Q. An element...

Q. An elementary two-pole rotating machine with uniform air gap, as shown in Figure, has a stator-winding self-inductance Lss of 50 mH, a rotor-winding self-inductance Lrr of 50 mH

Operation performed by instruction out 47 h, Q. Illustrate the operation p...

Q. Illustrate the operation performed by instruction OUT 47 h, AL. Ans:  It transfers contents of AL to I/O port 47h. Notice that I/O port number appears as 0047h on the 16 b

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd