Professional Documents
Culture Documents
3 Hexadecimal notation
where
⋄ l is the number of bits of the whole part.
⋄ k is the number of bits of the fractional part.
For example:
l = 10, k = 6 ⇒
00 0000 0010 1000 00 = (0+· · ·+0+1∗21 +0∗20 +1∗2−1 )10 = (2.5)10
00 0000 0101 0100 00 =
(0 + · · · + 0 + 1 ∗ 22 + 0 ∗ 21 + 1 ∗ 20 + 0 ∗ 2−1 + 1 ∗ 2−2 )10 = (5.25)10
0 0 1 1 1 1 1 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
31 30 23 22 0
Sign = 0
Exponent = 2(e−127)
P23= 2 124−127
= 2 −3
Logical operations
Integer arithmetic
• Addition
• Subtraction
• Multiplication
• Division
• Shifting
e=3; s=4.734612
× e=5; s=5.417242
-----------------------
e=8; s=25.648538980104