Search the web
Sign In
New User? Sign Up
vmu-dev · The VMU Development list
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Real people. Real stories. See how Yahoo! Groups impacts members worldwide.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
Division   Message List  
Reply | Forward Message #441 of 1156 |
Re: Division

Hello MORB

On 04-Aug-00, you wrote:

> Hi,
>
> for my current vmu project, I need to divide a 24 bits number by a 16
> bits number (otherwise, it's too imprecise and gives crapy results), and
> I wonder how to do this by using the DIV instruction (which divides a 16
> bits number by a 8 bits number)...
>
> I figured easily how to do multiplications of 16 bits (or more) values,
> because I remember how to do a multiplication by hand, but I can't
> remember at all how division works :(
>
> If somebody could help...


Here's my memory of long division (using decimals)

...
820 / 37 = 22.162 (.162 recurring)

-----------------------------------

2 .
37 | 820.
--

82 / 37 = 2 (Rem 8)



22.
37 | 828.0
- -

80 / 37 = 2 (Rem 6)



22.1
37 | 828.60
--

60 / 37 = 1 (Rem 23)



22.16
37 | 828.6230
--- [since 23 < 37, use 230 instead]

230 / 37 = 6 (rem 8)

..etc

I have no idea if this will be of any help to you, but as you said you
managed to program long multiplication since you remembered how to do it
manually, then maybe it will be useful

--
_ Richard Munn RAMTronics Software
// www : http://come.to/ramtronics
\X/ email : richard.munn@...


__________________________________________________
Do You Yahoo!?
Talk to your friends online with Yahoo! Messenger.
http://im.yahoo.com



Fri Aug 4, 2000 12:56 pm

richard.munn@...
Send Email Send Email

Forward
Message #441 of 1156 |
Expand Messages Author Sort by Date

Hi, for my current vmu project, I need to divide a 24 bits number by a 16 bits number (otherwise, it's too imprecise and gives crapy results), and I wonder how...
MORB
MORB@...
Send Email
Aug 4, 2000
7:36 am

Hello MORB On 04-Aug-00, you wrote: > Hi, > > for my current vmu project, I need to divide a 24 bits number by a 16 > bits number (otherwise, it's too...
Richard Munn
richard.munn@...
Send Email
Aug 4, 2000
5:53 pm
Advanced

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help