Data Representation Flashcards
What is a Real Number
A number with a whole part and a fractional part e.g. 17.0, 3.3333
What is the radix point in binary
The name of the point (.)
What are the four parts of floating point representation
Sign, Mantissa, Base and Exponent
What is the Mantissa
The significant digits of the number being represented
What is the Exponent
Scales the number by shifting the position of the floating radix point
What is Single Precision floating point
When you represent floating point negative numbers of certain size and range by describing the order the information comes in
What are key features of Single Precision floating point
Occupies 32 bits in computer memory, Exponent is 8 bits, mantissa is 23 bits and the sign is 1, bias number is 127
When would Single Precision floating point be used
Wide representation, simple programs like games
Why is Single Precision floating point used
Less expensive, fewer resources needed
What are key features of Double Precision floating point
Occupies 64 bits in computer memory, Exponent is 11 bits, mantissa is 52 bits and sign is one bit, the bias number is 1023
When would Double Precision floating point be used
Used for minimization of approximation, used in complex programs like scientific calculators
Why isn’t Double Precision floating point used for every computation
The cost incurred using this format does not always justify its use, it provides more accurate results but at the cost of greater computational power, memory space and data transfer
What would be the simplest idea to represent text
Binary bit pattern per character
What are key features of ASCII
7 bits providing 128 unique characters
What are key features of Unicode
16 bits used normally (sometimes 8 or 32 bits) providing 65536 different characters
What are the ways to represent negative numbers
Sign-Magnitude or Two’s Complement
What is an Integer Overflow
When an arithmetic operation attempts to create a numeric value that is outside of the range that can be represented with the given bits
What happens when there is an integer overflow
The least significant representable bits of the results are stored, the result is said to wrap around the maximum
What is one way we can represent colors
RGB
Define Colour Depth
The number of bits used to encode color
Define Pixels
Dots of colour in the image
Define Resolution
Numbers of pixels in the image
What is Raster Graphics
Treats the image as a collection of pixels
What are examples of Raster Graphics
BMP,GIF,PNG,JPEG
Define Vector Graphics
Treats the image as a collection of mathematically defined geometric objects in the image
What is an example of Vector Graphics
SVG
What does JPEG stand for
Joint Photographic Experts Group
Why would SVG be good
The circles are mathematically defined, we can make them larger/smaller and pixilation does not occur
What are 4 ways sound can be represented
AM Radio(11kHz), CD quality (44kHz), DVD quality (48kHz), Blu-ray quality (96kHz)
Define Data Compression
Reduction in the amount of space needed to store a piece of data or the bandwidth to transmit it
Define Compression ratio
The size of the compressed data divided by the size of the original data
Define Lossless
The data can be retrieved without any loss of original information
Define Lossy
Some information may be lost in the process of compression
Define Run-Length Encoding
Replace the repeated sequence with a character and number of times repeated
When would Run-Length Encoding be used
Would be used with binary values, not often used for natural text
Define Keyword Encoding
Common patterns and single characters would be replaced with a single character
What would you need to perform Keyword Encoding
Mapping table to encode and decode the information
Define Variable Length Bit String Encoding
Changing the number of bits used to represent a value, making more frequent values use fewer bits than uncommon ones