1-2: Number Systems And Binary Flashcards
explain how binary works
as we move from right to left, each digit is worth twice as much as the previous one.
2^0, 2^1, 2^2, 2^3, 2^4……
what is the range of values that an 8 bit integer can store
256
(0-255)
what is the largest binary number that can be held in 8 bits
255
what is one byte
8 bits
what do computers always begin their count from
0
explain the method of twos complement
-convert the positive integer into binary
-starting from the right-hand side copy all bits up to and including the one
-flip all other bits
what are the 5 basic binary addition rules
0 + 0 = 0
0 + 1 = 1
1 + 0 = 1
1 + 1 = 0 (carry the one)
1 + 1 +1(has been carried over) = 1 (carry the one)
how do you subtract binary numbers
-convert the negative number to binary
-using twos complement represent the negative number
-convert the other number to binary
-add the numbers together
how do you multiply numbers in binary
Step 1: Write down the multiplicand
and the multiplier(one below the other in proper positions).
Step 2: Multiply the rightmost digit or the least significant bit (LSB) of the multiplier with all the digits of the multiplicand
Step 3: Add a placeholder of ‘0’ before multiplying the next higher-order digit of the multiplier& with the multiplicand.
Step 4: Repeat the same process for all the next higher-order digits until we reach the most significant bit (MSB) which is the left-most digit of the multiplicand with the multiplier.
Step 5: The product obtained in each row is called the partial product. Finally, add all the partial products. To add all the binary numbers use the rules of binary addition.
what is base 2, base 10 and base 16
base 2 is binary
base 10 is denary
base 16 is hex
explain what the numbers in hex are
0 - 9 = 0 to 9
10 - 15 = A to F
what are natural numbers and give an example
positive whole numbers
Eg, 1
what are integer numbers and give an example
positive and negative whole numbers
Eg, -3 and 5
what are rational numbers and give an example
set of numbers that can be written as fractions. Since a number such as 7 can be written as 7/1 all integers are rational numbers
what are irrational numbers and give an example
one that cannot be written as a fraction
Eg, square root of 2 or pi