=========================== Notes for Lab 03 (math lab) =========================== - Ian! D. Allen - idallen@idallen.ca - www.idallen.com Class Notes (2008): http://teaching.idallen.com/cst8214/08f/ Class Notes References: binary_math.txt Binary Mathematics, unsigned, two's complement, etc. hexadecimal_conversions.txt Converting to/from hexadecimal (base 16) overflow.txt Calculating the OVERFLOW flag in binary arithmetic You can check your work using any online converter; use Google to find one. e.g. http://www.tonymarston.net/php-mysql/converter.php The point of the binary-decimal conversions in Lab 3 is not to show me the answer. I already gave you the answer. The point is to show me that you have a clear *method* for getting that answer that works for you. You must show me a clear method that turns the decimal into binary. The method must work for any unsigned decimal number (or fraction). Show me your method. The point of the binary-decimal conversions in Lab 3 is not to show me that you can do the question backwards and convert the binary back to decimal by adding up powers of two in the answer. Your tests and exams won't have any answers. I asked you to convert the decimal to binary, not the other way around. Calculators are not permitted during the tests and exams. You will benefit from knowing the powers of two from 2**(-4) to 2**16. Of course you can work them out; however, having at least some of them memorized will make things go faster for you. You will also benefit from knowing the bit patterns for the sixteen hexadecimal digits from 0,...,9,A,...,F Of course you can work them out; however, having at least some of them memorized will make things go faster for you. Practice: Write down any three-digit decimal number (e.g. 314). Convert it to binary using your method. Check your work on the Internet, using a decimal-to-binary conversion web page. Google search: decimal to binary conversion Sample conversion site: http://acc6.its.brooklyn.cuny.edu/~gurwitz/core5/nav2tool.html Quiz site: http://acc6.its.brooklyn.cuny.edu/~gurwitz/core5/binquiz.html Subtraction method: http://www.is.wayne.edu/olmt/binary/page3.htm