Data Representation Flashcards

1
Q

Why do computers use binary to represent all forms of data?

A
  • Any form of data needs to be converted to binary to be processed by a computer
  • Data is stored using 1’s and 0’s
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Describe how bits are represented on a HDD:

A
  • a platter contains billions of tiny magnetic grains.
  • each grain independently magnetized (to store a 1) or demagnetized (to store a 0)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Describe how bits are represented on an optical disk e.g. CD/DVD/BluRay

A

Pits and lands used to represent 1 or 0 on the surface of a CD

A laser shines onto the surface of the disc and the reflection is measured

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is denary?

A

Denary is the standard number system used around the world

Denary is known as base 10 because there are ten choices of digits between 0 and 9

Each digit has a place value (powers of 10)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is binary?

A

Binary is a number system used in computing

Binary is known as base 2 because there are 2 choices of digits , 0 and 1

Each digit has a place value (powers of 2)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Explain the difference between the binary and denary number systems

A
  • Binary base 2 system
    • Denary base 10 system
  • Binary has 2 digits (0 and 1)
    • Denary has 10 digits (0-9)
  • Binary place values are powers of 2
    • Denary place values are powers of 10
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What are the binary place values for a byte?

A

128 64 32 16 8 4 2 1

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Convert the 8 bit binary number 10011011 into denary

A

155

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Convert the following binary numbers into denary

00011101

00100101

01010101

10010100

A

00011101 = 29

00100101 = 37

01010101 = 85

10010100 = 148

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Convert the denary value 156 into binary

A

10011100

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Convert the following denary numbers into 8 bit binary

96

72

161

74

A

96 = 01100000

72 = 01001000

161 = 10100001

74 = 01001010

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What is the largest value that can be stored in 8 bits?

A

255 (128 + 64 + 32 + 16 + 8 + 4 + 2 + 1)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What is the largest value that can be stored in 10 bits?

A

1023 (512 + 256 + 128 + 64 + 32 + 16 + 8 + 4 + 2 + 1)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

How many bits in a byte?

A

8

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

How many bits in a nibble?

A

4

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

How many nibbles in 4 bytes?

A

8

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

What is hexadecimal?

A
  • Base 16 number system
  • 16 choices of digits (0-9, A-F)
  • Place values are powers of 16
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

What are the place values for the hexadecimal value A7F3?

A
  • 4096 256 16 1
  • A 7 F 3
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

What is the denary value of the hex digit A?

A

10

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

What is the denary value of the hex digit E?

A

14

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

What is the denary value of the hex digit 7?

A

7

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
Q

Convert the hex value AAA to Denary

A

2730

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
23
Q

Convert the following hex values to denary

  • 1F
  • 42
  • CC
A
  • 1F = 31
  • 42 = 66
  • CC = 204
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
24
Q

Convert the hex value CA to Binary

A

11001010

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
25
Q

Convert the following hexadecimal values to binary

  • B3
  • 5A
  • B0F
A
  • B3 = 1011 0011
  • 5A = 0101 1010
  • B0F = 1011 0000 1111
26
Q

Convert the binary value 1111 1010 to hexadecimal

A

FA

27
Q

Convert the following binary values to hexadecimal

  • 1011 1101
  • 1010 0110
  • 1111 1010 1100 1110
A
  • 1011 1101 = BD
  • 1010 0110 = A6
  • 1111 1010 1100 1110 = FACE
28
Q

Convert the hex value AB to Denary

A

171

29
Q

Convert the denary value 166 to hexadecimal

A

A6

30
Q

Convert the following denary values to hexadecimal

  • 22
  • 42
  • 170
A
  • 22 = 16
  • 42 = 2A
  • 170 = AA
31
Q

Why do we use hexadecimal?

A
  • Easier for programmers to read and understand
  • Conversion to binary easier than denary to binary
  • Takes up less space when displayed or printed
  • Faster than binary for entering numbers
32
Q

Where is Hexadecimal used?

A
  • HTML colour codes e.g. red = #FF0000
  • Display MAC (Media Access Control) addresses e.g. 01-23-45-67-89-AB-CD
  • Display ASCII or Unicode values e.g. %41 = 65 = A
  • Display error codes e.g. error #404 page not found
  • Display memory dumps e.g. 5F 3A 09 F1
33
Q

What is a character set?

A

A character set is a complete set of the characters and their character codes that can be recognised by a computer system.

34
Q

What is character code?

A

A value/binary number that represents a character

35
Q

What is ASCII?

A
  • American Standard Code for Information Interchange.
  • It is a code for representing 128 English characters as numbers
  • Each character is assigned a number from 0 to 127
36
Q

How many bits does ASCII use?

A

7 bits

37
Q

How many characters can be represented using ASCII?

A
  • Uses 7 bits so …
  • 000 0000 to 111 1111 = 0 to 127 = 128 unique characters (2^7)
38
Q

How many bits does extended ASCII use?

A

8

39
Q

How many characters can be represented using extended ASCII?

A
  • 0000 0000 to 1111 1111 = 0 to 255 = 256 unique characters (2^8)
40
Q

How many bits does Unicode use?

A

16

41
Q

How many characters can be represented using Unicode?

A
  • Uses 16 bits so … 65536 unique characters (2^16)
42
Q

Describe the difference between ASCII and Unicode

A
  • ASCII uses 7 (or 8 bits) and can represent 128 (or 256 characters)
  • Unicode uses 16 bits and can represent 2^16 characters.
43
Q

Describe one advantage of Unicode

A

Can represent a wider range of characters and therefore more languages than ASCII

44
Q

Describe one disadvantage of Unicode

A

Each character uses more memory space than ASCII

45
Q

Describe what is meant by a character set

A
  • All the characters and symbols that can be represented by a computer system.
  • Each character and symbol is assigned a unique value.
46
Q

What is a bitmap image?

A

A collection of pixels where each pixel is assigned a value that represents it’s colour.

47
Q

What is a pixel?

A

Short for picture element
The smallest block of colour in an image

48
Q

What is colour/bit depth?

A

The number of bits used to represent the colour of a single pixel

49
Q

How many colours can be stored using 1-bit?

A

2

There are 2 possible values - 0 or 1

50
Q

How many colours can be stored using 2-bits?

A

4

There are 4 possible values (00, 01, 10, 11)

51
Q

How many colours can be stored using 4-bits?

A

16

Range of possible value is 0000 - 1111 = 0 - 15

52
Q

For n bits you can store 2^n different colour codes.

How many colours can be stored using 12 bits?

A

4096 (2^12)

53
Q

What is image resolution?

A

The number of pixels in the image e.g. 600 px x 400 px = 240 000 px

54
Q

How do you calculate the size of an image?

A

image size = number of pixels x colour depth

55
Q

If a 12-bit colour depth is used and the image size is 800 x 600 pixels, what is the minimum file size for the image in bytes?

A

Number of pixels = 800 x 600
Number of bits per pixel = 12
Total number of bits = 12 x 800 x 600 = 5760000
Number of bytes = 5760000 ÷ 8 = 720000 bytes

56
Q

What is meant by image metadata?

A

Image files usually also contain metadata .
Metadata means ‘data about data’
It provides additional information about the image.
Computers needs this data to interpret the file

57
Q

Give 3 examples of image metadata

A

file format - eg JPG, GIF, BMP, PNG
resolution
colour depth
time/date the image was taken
camera settings
GPS data

58
Q

Explain how captured camera images are converted to digital photo files

A

Image is turned into pixels
Pixels form a grid
Each pixel is give a binary value
Each pixel is given a colour
Pixels are stored in the correct sequence
Meta data is also stored about the image e.g. dimensions/resolution/colour depth
Different file formats are used e.g. JPEG

59
Q

What happens when you increase the colour depth of an image?

A

The quality of the image increases
You are more accurately able to represent the range of colours
Also increases the memory size of the image

60
Q

What happens when you increase the number of pixels in an image?

A

The density of pixels in the same sized area increases
More pixels per inch, improving sharpness
Can enlarge without visible loss of quality
Increases the memory size of the image