Data Representation Flashcards
What are the 3 Steps to create a Twos Complement Number
Create the positive number binary number
Invert all the 0’s to 1’s and all the 1’s to 0’s
Add 1 to the RIGHT of the number. (Sometimes called the Least Significant Bit)
How are positive and Negative numbers stored in a computer
As a binary number using Two’s complement.
What is the formula for the range of positive and negative integers which can be represented in twos complement using n bits.
-2n-1 …. 2n-1 - 1
What is the formula for the largest integer which can be represented in twos complement using n bits.
2n-1 - 1
What is the formula for the smallest integer which can be represented in twos complement using n bits.
-2n-1
What is the formula for the range of positive and negative integers which can be represented in twos complement using 8 bits.
-2n-1 …. 2n-1 - 1
= -28-1 to 8-1 - 1
= -27 to 27 - 1
= -128 to 128 - 1
= -128 to 127
What is the formula for the largest integer which can be represented in twos complement using 8 bits.
2=n-1 - 1
=28-1 - 1
=27 - 1
=128 - 1
=127
What is the formula for the smallest integer which can be represented in twos complement using 8 bits.
-2n-1
= -28-1
= -27
= -128
**= -128 **
How does increasing the number of bits to store the mantissa impact the number stored.
Increasing the number of bits used to store the mantissa:
increases the precision of the number.
decreases the number of bits available for the mantissa, and so the precision of the number is decreased.
How does increasing the number of bits to store the exponent impact the number stored.
Increasing the number of bits used to store the exponent:
increases the range of the number.
How does decreasing the number of bits to store the mantissa impact the number stored.
Decreasing the number of bits available for the mantissa will make precision of the number is decrease
How does increasing the number of bits to store the exponent impact the number stored.
precision of the range of numbers represented will decreased.
What impact will adding 1 extra bit to the exponent have on the range of numbers which can be stored
The range of numbers represented will double
What impact will removing a 1 bit from the exponent have on the range of numbers which can be stored
The range of numbers represented will half
Extended ASCII - How many bits does extended ASCII use to represent a character and how many characters can it represent?
uses 8 bits to represent a character
can represent 256 different characters
Extended Unicode - How many bits does extended Unicode use to represent a character and how many characters can it represent?
Unicode
uses 16 bits to represent a character
can represent 65,536 characters
State one advantage of Unicode over ASCII
Used to represent characters from many different languages (Arabic, Japanese, Latin etc) and emojis
State one disadvantage of Unicode over ASCII
Unicode uses 2 bytes (16 bits) to represent a character where ASCII only uses one byte (8 bits)
State 2 advantages of bitmap images
can produce realistic photographic images
control over pixel-level editing
State 2 disadvantages of bitmap images
resolution is set at point of creation and cannot be increased without a loss of quality (resolution dependent)
tends to have a larger file size than a vector graphics file
can be time consuming to edit
State 2 disadvantages of vector graphic images
Disadvantages
no control over pixel-level editing
unsuitable for photo-realistic images
State 2 advantages of vector graphic images
can be scaled without a loss in quality (resolution independent)
vector objects can be edited independently of each other
vector objects can be easily moved / manipulated
tends to have a smaller file size than a bit-mapped graphics file