Converter

advertisement

Decimal Hexadecimal and Binary converter


From

To


How to convert

Hexadecimal and Binary are simple to understand once you get it. They are basically different counting systems to our general 0 to 9 decimal system. Binary only has 0 and 1, Hexadecimal goes from 0 to F with F being decimal 15.


Between Decimal and Hexadecimal

Decimal Hexadecimal Calculation From Hexadecimal
0 0
1 1
2 2
3 3
4 4
5 5
6 6
7 7
8 8
9 9
10 A
11 B
12 C
13 D
14 E
15 F
16 10 (1=1)*16+0
17 11 (1=1)*16+1
18 12 (1=1)*16+2
19 13 (1=1)*16+3
20 14 (1=1)*16+4
32 20 (2=2)*16+0
240 F0 (F=15)*16+0
4086 FF6 ((F=15)*16²)+((F=15)*16¹)+((6=6)*16⁰)
65520 FFF0 ((F=15)*16³)+((F=15)*16²)+((F=15)*16¹)+((0=0)*16⁰)

Hexadecimal to Decimal

Converting from hexadecimal to decimal starts by seeing how many digits there are, starting from 0. You then use the number of each digit as the factor that you use to multiply 16 with for each digit in the Hexadecimal value.

Example (DE9A):

  1. There are 4 charcters, so 3 last one will be ³.
  2. (D=13)*16³ = 53248
  3. (E=14)*16² = 3584
  4. 9*16¹ = 144
  5. (A=10)*16⁰ = 10
  6. 53248 + 3584 + 144 + 10 = 56986
  7. DE9A = 56986

Decimal to Hexadecimal

Keep dividing the number by 16, noting down the remainders. Then add those together from right to left.

Here an example, using the number 2001.

Division Quotiient Remainder (Digit) Digit number
2001/16 125 1 0
125/16 7 13 1
7/16 0 7 2

That means that the number would be 7 + (13 = D) + 1. The Hex therefor is 7D1


Between Decimal and Binary


Binary to Decimal

Binary is a system where every added has double the value of the one before (going form right to left). You add all the values that have a 1 together to make any number possible.

In order to go from Binary to Decimal, simply start at the most right digit. This digit has the value 1 and can be 1 or 0. 1 means that you need to add the number to your total, 0 means you do not. The one to the left of the first digit will have the value 2, the one to the left of that will have 4, the one to the left of that will have 8 and so it continues infinitly.

State(0 or 1) Value Number to be added
0 1 0
1 2 2
0 4 0
1 8 8
0 16 0
0 32 0
1 64 64
The number in decimal 74

Decimal to Binary
Division Quotient Remainder
76/2 38 0
38/2 19 0
19/2 9 1
9/2 4 1
4/2 2 0
2/2 1 0
1/2 0 1
The number in Binary 1001100

Converting Decimal to Binary is almost the same as with the Hexadecimals, however now you are using a factor of 2 instead of 16.

You keep dividing the number by 2, every time there is a modulus/remainder of 1 you note on how many divisions that has been. You then make the number like in the table on the left.


We do our best to keep measurements as accurate as possible, but they come with no guarantees.

copyrighted © SirMrDany 2021-2021