Download presentation
Presentation is loading. Please wait.
1
Finite Arithmetics of Integers FORTRAN codes: INTEGER*2INTEGER HTML HTML version
2
value sign bit 2 n 1 1 to 2 n 1 value sign bit 0 0 000 88 1 000 +10001 11 1001 +20010 22 1010 +30011 33 1011 +40100 44 1100 +50101 55 1101 +60110 66 1110 +70111 77 1111 4-bit Integers
3
Crossing boundaries (1) 1+7 0111 2 + 0001 2 1000 2 8 1 8 1001 2 + 1000 2 10001 2 1000 2 8
4
Multiplication (division) by 2 3 2 left-shift 0011 2 0110 2 6 3/2 right-shift 0011 2 0001 2 1
5
Crossing boundaries (2) 4 2 L-S 0100 2 1000 2 8 8 2 L-S 1000 2 0000 2 0 For an n-bit object, 2 n 2 2 2 n 1 gives 2 n 1. 2 n 1 2 gives 0. codes
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.