# Division of a hexadecimal number by another

• Aug 22nd 2010, 07:55 AM
yuud
Division of a hexadecimal number by another
Does anybody have a guide to division of hexadecimal base numbers?(Doh)

For example divide 57F6D by B9.... without first converting to decimal...
• Aug 22nd 2010, 08:11 AM
undefined
Quote:

Originally Posted by yuud
Does anybody have a guide to division of hexadecimal base numbers?(Doh)

For example divide 57F6D by B9.... without first converting to decimal...

You can use the same method of division taught in elementary (primary) schools for decimal. It would help if you gave more details. Do you need to do this on paper? Create a computer program? In a certain langauge? Do you need it to be efficient or just get the job done?
• Aug 22nd 2010, 08:13 AM
yuud
I need to do it using long division... on paper... without converting it to any other base... I've been given an example, but when I've been revising, I can't understand how to do it...

57F6D is divided by B9 to give 79B as quotient and 6A as remainder... that's the example...
• Aug 22nd 2010, 09:10 AM
Soroban
Hello, yuud!

Quote:

Does anybody have a guide to division of hexadecimal base numbers?

For example: .$\displaystyle 57F6D_{16} \div B9_{16}\quad\hdots$ without converting to decimal.

My advice is to learn to "think" in hexidecimal
. . or learn to quickly covert from hexidecimal to decimal and back.

In hexidecimal, the division looks like this:

. . $\displaystyle \begin{array}{cccccccc} && & & 7 & 9 & B\\ && -- &--&--&--&-- \\ B\,\;9 & ) & 5 & 7 & F & 6 & D \\ & & 5 & 0 & F \\ & & -- & -- & -- \\ &&& 7 & 0 & 6 \\ &&& 6 & 8 & 1 \\ &&& --&--&-- \\ &&&& 8 & 5 & D \\ &&&& 7 & F & 3 \\ &&&& --&--&-- \\ &&&&& 6 & A \end{array}$

• Aug 22nd 2010, 09:12 AM
yuud
Quote:

Originally Posted by Soroban
Hello, yuud!

My advice is to learn to "think" in hexidecimal
. . or learn to quickly covert from hexidecimal to decimal and back.

In hexidecimal, the division looks like this:

. . $\displaystyle \begin{array}{cccccccc} && & & 7 & 9 & B\\ && -- &--&--&--&-- \\ B\,\;9 & ) & 5 & 7 & F & 6 & D \\ & & 5 & 0 & F \\ & & -- & -- & -- \\ &&& 7 & 0 & 6 \\ &&& 6 & 8 & 1 \\ &&& --&--&-- \\ &&&& 8 & 5 & D \\ &&&& 7 & F & 3 \\ &&&& --&--&-- \\ &&&&& 6 & A \end{array}$

Thanks for this...

But how do you start? How to divide? For example, what do you do on the first line? Just guide me, i'll understand it...
• Aug 22nd 2010, 09:13 AM
yuud
Quote:

Originally Posted by Soroban
Hello, yuud!

My advice is to learn to "think" in hexidecimal
. . or learn to quickly covert from hexidecimal to decimal and back.

In hexidecimal, the division looks like this:

. . $\displaystyle \begin{array}{cccccccc} && & & 7 & 9 & B\\ && -- &--&--&--&-- \\ B\,\;9 & ) & 5 & 7 & F & 6 & D \\ & & 5 & 0 & F \\ & & -- & -- & -- \\ &&& 7 & 0 & 6 \\ &&& 6 & 8 & 1 \\ &&& --&--&-- \\ &&&& 8 & 5 & D \\ &&&& 7 & F & 3 \\ &&&& --&--&-- \\ &&&&& 6 & A \end{array}$

Thanks for this...

But how do you start? How to divide? For example, what do you do on the first line? Just guide me, i'll understand it...
• Aug 22nd 2010, 10:17 AM
HallsofIvy
As everyone has said, exactly like you divide in decimal.

Of course, you need to know some multiplication and division "facts" first- again just like you learned for decimals:

Multiplication tables:
1 times 1= 1, times 2= 2, times 3= 3, ..., to 1 times F= F.

2 times 1= 2, times 2= 4, times 3= 6, times 4= 8, time 5= A, times 6= C, times 7= E, times 8= 10, times 9= 12, times A= 14. times B= 16, time C= 18, times D= 1A, times E= 1C, times F= 1E.

3 times 1= 3, times 2= 6, times 3= 9, times 4= C, times 5= F, times 6= 12, times 7= 15, times 8= 18, times 9= 1B, times A= 1E, times B= 21, times C= 24, times D= 27, time E= 2A, times F= 2D
etc.

continuing in that way, you would eventually get to

7 times 1= 7, times 2= E, times 3= 15, times 4= 1C, times 5= 23, times 6= 2A, times 7= 31, times 8= 38, times 9= 3F, times A= 46, times B= 4E, times C= 54

it was that last one, that 7 times B= 4E and 7 times C= 54 that caused Soroban to try B as the first "digit" in the quotient, just as if, in base 10, you had 79 divided into 4883, you would try a trial divisor of 7 or 8 because you know that 7 tmes 7 is 49 and 7 times 8 is 56 (it would be that "9" in the one's place of the divisor that would cause you to try 8 rather than 7). Once you have an idea of where a trial divisor should be, it's just "try and check".
• Aug 22nd 2010, 10:17 AM
undefined
Quote:

Originally Posted by yuud
Thanks for this...

But how do you start? How to divide? For example, what do you do on the first line? Just guide me, i'll understand it...

To start out with, in hexadecimal,

B9 * 7 = 50F < 57F
B9 * 8 = 5C8 > 57F

So the most significant hex-digit must by 7. It helps if you know how to multiply (and add and subtract) before you divide.