# radix 2 srt division

January 16, 2010 at 03:56:58
Specs: win
 helloDoes somebody knows about RADIX 2 SRT division ?I cant understand all of it !z : dividendd : divisorQ : quotients : remainderthis is the algorithm(pseudo code) :z = s(0)for j=1 to kif 2s(j-1) > 1/2 thenq(j) = 1;s(j) = 2s(j-1) -d ;els if s(j-1) <-1/2 thenq(j) = -1;s(j) = 2s(j-1) +d ;else q(j) = 0;s(j) = 2s(j-1);end if ;end for;and this is an example :z 0.01000101d 0.1010-d 1.0110=============================s(0) 0.010001012s(0) 0.1000101 >1/2 so q(-1)=1+(-d)=============================s(1) 1.11101012s(1) 1.110101 in [-1/2,1/2) so q(-2)=0 =============================s(2) 1.1101012s(2) 1.10101 <-1/2 so q(-3)=-1+d 0.1010=============================s(3) 0.010012s(3) 0.1001 >1/2 so q(-4)=1+(-d) 1.0110=============================s(4) 1.1111 negative so add to correct2s(4) 0.1010=============================s(4) 0.1001s 0.0000 1001q 0.10(-1)1 uncorrect BSD quotient q 0.0110 convert and subtract ulpi think this is not true : (line 13)s(2) 1.1101012s(2) 1.10101 <-1/2 so q(-3)=-1+d 0.1010and what is "ulp" and how convert 0.1.(-1)1 to 0.0110 ?thnxImpossible is nothing !!!

See More: radix 2 srt division

#1
January 19, 2010 at 10:39:58
 Is this a programming language or a logical calculator or so ?

Report •

#2
January 21, 2010 at 06:03:59
 it is a pseudo code but i need it in VHDL language , Impossible is nothing !!!

Report •

Related Solutions