4.5: section 3: data representation: number, binary and information coding systems Flashcards
what are natural numbers and their set letter
all positive whole numbers including 0 used for counting
N={0,1,2,3}
what are in integers and their set letter
any positive or negative whole number
Z={…-2,-1,0,1,2,3}
what are rational number and their set letter
values expressed as fractions or ratios
Q={…2/1,2/2,2/3,2/4…}
Q={…2.1,0.6,0.5}]
what are real numbers
numbers that are rational or irrational and are used for measurement
what are ordinal numbers
not real or natural numbers and are used to show position
what are irrational numbers
a number that cannot be written as a fraction
I = { pi }
what type of numbers are used for counting
natural numbers
what type of numbers are used for measurement
real numbers
what are base 10 numbers
decimal numbers which are all represented with a selection of 10 digits
0,1,2,3,4,5,6,7,8,9
what are base 2 numbers
binary numbers which are all represented with a selection of 2 digits
1,0
what are base 16
hexadecimal numbers which are all represented using a selection of 16 characters
0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F
why is hexadecimal used
hexadecimal is used as a shorthand for binary as it makes it easier to write and remember without making as many mistakes
what is a bit
what is a byte
a bit is a single binary value
a byte is a set of 8 binary values
what are the binary units
kilo, k - 10^3 kibi, Ki -2^10 mega, M - 10^6 mebi, Mi -2^20 giga, G - 10^9 gibi, Gi -2^30 tera, T - 10^12 tebi, Ti -2^40
what is the difference between signed and unsigned binary
- unsigned binary can only be used to represent positive decimal numbers
- signed binary is used to represent both positive and negative binary numbers with coding schemes like twos complement
what are some rules of binary addition
0+0=0
1+0=1
1+1 =10
1+1+1=11
how is binary subtraction completed
one of the binary numbers is translated using twos compliment and then added to the other binary number
how is binary multiplication completed
the binary number is shifted by the amount of spaces necessary
what is an absolute error
the difference between the target number and the closest rounded number that can be represented
what is a relative error
the absolute error divided by the target number as a percentage
compare the range provided by fixed point and floating point binary
fixed: depends on the position of the binary point
the more digits to the left the greater the range but the lower the precision
floating: can easily represent large numbers and small fractions. more bits used for the exponent means increased range
compare the precision provided by fixed point and floating point binary
fixed: depends on the position of the binary point
the more digits to the right the greater the precision but the lower the range
floating:more bits for the mantissa means increased precision
compare the calculation speed needed for fixed point and floating point binary
fixed: simpler to calculate so the processing speed tends to be faster
floating: point has to be moved first which make sit longer to be processed and calculated
why are binary numbers normalised
as there are multiple ways of representing a single integer in binary binary numbers are normalised so there is only one representation for each digit.
negative numbers start with 10
positive numbers start with 01