Fractional hexadecimal addition.

1k Views Asked by At

i have searched the web and through out the forums but, i couldn't find an exact answer. This is my first question, and please excuse my english. I am doing my CS homework which includes adding some fractional hexadecimal numbers. I know the method i am using is correct, however is there an online calculator for hexadecimal that supports fractiional number?. All the calculators i had found, only supported intergers. I just want to check if my answers are correct.

1

There are 1 best solutions below

0
On

Manual Hexadecimal Arithmetic With Decimal Points Remembering decimals base 10 expand to fractions, $$0.123 = 1/10 + 2/10^2 + 3/10^3.$$ Each hexadecimal digit is $$\frac{d_p}{16^p}.$$ where p is 1 for sixteenths (or tenths in decimal), 2 for 256ths (or hundredths in decimal), etc. For example, the number, $$0.27495 = 2/16 + 7/16^2 + 4/16^3+ 9/16^4 + 5/16^5.$$ If you expanded second number to add, how would they add? Can you generalize and describe how hexadecimals with decimal points add or subtract? What about borrowing in other bases? Proofs or justifications should be short or not terribly complex.

Note 1: Although the question seems obscure from a math perspective, every numeric capable computer implements it to perform fraction or decimal arithmetic.