9514 1404 393
Answer:
101000₂
Explanation:
The usual place-value rules apply. Bit positions have values that increase by a factor of 2 as you go leftward from the units bit.
40 = 32 + 8 = 2⁵ +2³ = 101000₂
_____
The usual conversion algorithm has you repeatedly divide the number by 2. The remainder at each step is the binary digit (bit) next to the left. The first remainder is the units bit.
40/2 = 20r0
20/2 = 10r0
10/2 = 5r0
5/2= 2r1
2/2 = 1r0
1/2 = 0r1
The bits left to right are the remainders from the bottom up: 101000.
__
Additional comment
Along the same lines, a fraction can be converted to a binary fraction by repeatedly multiplying by 2. If the result is 1+(something), the fraction bit is 1. Otherwise it is 0. The next step repeats with the fractional part of that result. This develops the fraction bits left to right.
Example:
1/16 × 2 = 1/8 + 0
1/8 × 2 = 1/4 + 0
1/4 × 2 = 1/2 + 0
1/2 × 2 = 0 +1
The binary equivalent of 1/16 is 0.0001₂.
__
Fractions that do not have denominators that are a power of 2 will be repeating binary fractions. Of course, irrational numbers will have non-repeating binary fractions.