Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Special pages
Niidae Wiki
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
Computer number format
(section)
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
===Converting between bases=== {| class="wikitable" style="float: right; clear:right; margin-left:1em; text-align:right;" |+ Table 3: Comparison of values in different bases |- ! Decimal !! Binary !! Octal !! Hexadecimal |- | 0 || 000000 || 00 || 00 |- | 1 || 000001 || 01 || 01 |- | 2 || 000010 || 02 || 02 |- | 3 || 000011 || 03 || 03 |- | 4 || 000100 || 04 || 04 |- | 5 || 000101 || 05 || 05 |- | 6 || 000110 || 06 || 06 |- | 7 || 000111 || 07 || 07 |- | 8 || 001000 || 10 || 08 |- | 9 || 001001 || 11 || 09 |- | 10 || 001010 || 12 || 0A |- | 11 || 001011 || 13 || 0B |- | 12 || 001100 || 14 || 0C |- | 13 || 001101 || 15 || 0D |- | 14 || 001110 || 16 || 0E |- | 15 || 001111 || 17 || 0F |} {{Main | Positional_notation#Base_conversion| l1=Positional notation (base conversion) }} Each of these number systems is a positional system, but while decimal weights are powers of 10, the octal weights are powers of 8 and the hexadecimal weights are powers of 16. To convert from hexadecimal or octal to decimal, for each digit one multiplies the value of the digit by the value of its position and then adds the results. For example: : <math> \begin{align} & \text{octal } 756 \\[5pt] = {} & (7 \times 8^2) + (5 \times 8^1) + (6 \times 8^0) \\[5pt] = {} & (7 \times 64) + (5 \times 8) + (6 \times 1) \\[5pt] = {} & 448 + 40 + 6 \\[5pt] = {} & \text{decimal } 494 \end{align} \qquad \begin{align} & \text{hex } \mathrm{3b2} \\[5pt] = {} & (3 \times 16^2) + (11 \times 16^1) + (2 \times 16^0) \\[5pt] = {} & (3 \times 256) + (11 \times 16) + (2 \times 1) \\[5pt] = {} & 768 + 176 + 2 \\[5pt] = {} & \text{decimal } 946 \end{align} </math>
Summary:
Please note that all contributions to Niidae Wiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Encyclopedia:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Search
Search
Editing
Computer number format
(section)
Add topic