non-restoring binary divide, twos complement 4-bit numbers
note: 7 = 0 1 1 1 -7 = 1 0 0 1
1 1 0 0 quotient
________________
0 1 1 1 / 0 1 0 1 0 1 0 1
pre shift +1 0 0 1 adding twos complement of divisor
_______
10 - 7 = 3 0 0 1 1 1
quotient=1 +1 0 0 1
next bit subtract _______
7 - 7 = 0 0 0 0 0 0
quotient=1 +1 0 0 1
next bit subtract _______
0 - 7 = -7 1 0 0 1 1
quotient=0 +0 1 1 1 adding divisor
next bit add _______
2 + 7 = 9 = -7 1 0 1 0
quotient=0 +0 1 1 1
correction add _______
final remainder 0 0 0 1 remainder
(5 cycles using adder)
Home
Algorithm
COA
Code
Division
program
Restoring
Program for Implementation of Non-Restoring Algorithm.
Saturday, 1 June 2013
Program for Implementation of Non-Restoring Algorithm.
Artikel Terkait
Subscribe to:
Post Comments (Atom)
EmoticonEmoticon