19 decimal is 13 hex, since there is 1 set of 16, with 3 left over. In the example above, B + 8 in decimal is 11 + 8 = 19. Hex addition involves calculating basic decimal addition while converting between hex and decimal when values larger than 9 (the numerals A through F) are present. Work through the example, and refer to the text below it for further details. It may be convenient to have the decimal equivalent values of A through F handy when performing hex operations if the values have not yet been committed to memory. Hex addition follows the same rules as decimal addition with the only difference being the added numerals A, B, C, D, E, and F. The process is the same regardless of whether the hex value contains letter numerals or not. Multiply each digit in the hex value by its corresponding place value, and find the sum of each result. Remember that 10-15 have letter numerals In hex: 13 = D, and 12 = CĬonverting from hex to decimal utilizes the same principles, but is arguably simpler. Assign each of the values found in each iteration of Step 2 to its respective place value to determine the hex value.ġ6 is larger than 12, so 12 is the value in the 16 0 place valueġ500 = (5 × 16 2) + (13 × 16 1) + (12 × 16 0).Continue the process until 16 is larger than the remaining value, and assign the remainder to the 16 0 place value. Repeat Steps 1-3 using Y as the new starting value.If, for example, the largest power of 16 was found to be 16 4, and the number in Step 2 was found to be 3, the hex value would have the number 3 in its 16 4 place value: 3qrst, where qrst represents the 16 0 through 3 place values. Note that the number found in Step 2 will be the value written in the place value for the power of 16 that was found.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |