Data Representation 1.1 - 1.3 Flashcards

(56 cards)

1
Q

What is the binary number system?

A

Base 2 system using only 0 and 1, with place values as powers of 2 (e.g. 128,64,32,16,8,4,2,1 for 8 bits).

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

Why do computers use binary?

A

Switches are ON (1) or OFF (0), so binary matches computer’s hardware logic gates and storage.

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

How to convert binary to denary?

A

Add place values (powers of 2) where there is a 1. E.g. 11101110 = 128+64+32+8+4+2 = 238.

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

Denary to binary Method 1?

A

Successive subtraction of largest possible powers of 2, write 1 if subtractable, 0 if not.

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

What is hexadecimal?

A

Base 16 system using 0–9 and A–F (A=10, F=15), place values powers of 16.

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

Binary to hex?

A

Group into 4 bits from right, convert each group (e.g. 1111=F).

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

Hex to binary?

A

Each hex digit to 4-bit binary (e.g. F=1111).

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

Hex to denary?

A

Multiply each digit by power of 16, sum (e.g. 45A: 4×256 + 5×16 + 10×1 = 1114).

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

Denary to hex?

A

Repeatedly divide by 16, remainders bottom to top (10–15 as A–F).

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

What is a MAC address?

A

48-bit hex identifier for network card: NN-NN-NN-DD-DD-DD (manufacturer + serial).

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

What is an IP address?

A

Unique network address. IPv4: 32-bit (e.g. 109.108.158.1). IPv6: 128-bit hex groups.

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

How does HTML use hex?

A

RRGGBB for RGB colours (FF0000=red, 00FF00=green).

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

What are the uses of hexadecimal?

A

.

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

What are the advantages of using hexadecimal representation?

A

.

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

How many unique numbers can be represented in a n bit binary number?

A

2^n

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

What is the largest possible number that can be represented by n bit binary number?

A

2^n-1

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

what is the smallest and largest 8 bit number that can made in 2s complement? (binary and denary)

A

.

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

Binary addition rules?

A

0+0=0 c0; 0+1=1 c0; 1+0=1 c0; 1+1=0 c1 (carry 1).

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

What is overflow in 8-bit addition?

A

Carry out of MSB when result >255 (e.g. 240+48=288 → overflow). And an extra bit gets generated from the availible bits

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

Logical left shift effect?

A

Multiplies by 2^n (bits shift left, 0s in from right, MSB lost if overflow).

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

Logical right shift effect?

A

Divides by 2^n (bits shift right, 0s in from left, LSB lost).

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

What is two’s complement?

A

Method to represent signed 8-bit integers (−128 to +127). MSB=sign bit.

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

Positive denary to 8-bit two’s comp?

A

Convert to binary, pad to 8 bits (MSB=0).

24
Q

Negative denary to two’s comp?

A

Take positive binary, invert bits, add 1.

25
What is extended ASCII?
.
26
Two's comp to denary (negative)?
Take -128 (first bit) and then add the bits to get a denary value (e.g -128 + 32 + 16)
27
E.g. −25 to 8-bit two's comp?
+25=00011001 → invert 11100110 +1=11100111.
28
What is a character set?
List of characters + their binary codes (e.g. ASCII, Unicode).
29
What is ASCII?
7-bit character set (128 codes) for letters, numbers, symbols.
30
What are the advantages of Unicode over ASCII?
ASCII can't represent all languages/symbols; Unicode uses more bits for millions of characters.
31
What is sampling?
Measuring sound wave amplitude at regular intervals to digitise.
32
Sample rate?
Samples per second (Hz). Higher = more accurate time changes, bigger file.
33
Sample resolution/bit depth?
Bits per sample. Higher = more amplitude levels, better quality, bigger file.
34
What is a bitmap image?
Grid of pixels where each pixel has a binary colour value.
35
What is a pixel?
Picture element: smallest unit of image, has colour value.
36
Image resolution?
Width × height in pixels. Higher = more detail, bigger file.
37
Colour depth?
Bits per pixel for colour. 2^n colours. Higher = more colours, bigger file.
38
Pixelated image?
Low resolution shown too large: pixels visible as blocks.
39
Bit?
Single binary digit (0 or 1).
40
Nibble?
4 bits.
41
Byte?
8 bits.
42
KiB?
1024 bytes.
43
MiB?
1024 KiB = 1 048 576 bytes.
44
GiB?
1024 MiB = 1 073 741 824 bytes.
45
GiB?
1024 MiB = 1 073 741 824 bytes.
46
Bitmap file size formula?
(width × height × colour depth in bits) ÷ 8 = bytes.
47
E.g. 2048×2048, 16‑bit colour file size?
Pixels=4 194 304; bits=67 108 864; bytes=8 388 608; MiB=8.
48
Mono sound file size?
Sample rate × resolution (bits) × seconds.
49
Stereo sound adjustment?
Multiply by 2 (two channels).
50
Why compress data?
Reduce file size for faster transmission, less storage, less bandwidth.
51
Lossless compression?
Reduces size without data loss (e.g. RLE). Original fully recoverable.
52
Lossy compression?
Permanently removes data (e.g. reduce resolution). Smaller but quality loss.
53
When use lossy?
Photos/music/video where minor quality loss OK.
54
RLE (run length encoding)?
Replaces runs of identical values with (count, value). Best for repeated data.
55
E.g. RLE for 'AAAAAABBBB'?
(6,A)(4,B).
56
What are the disadvantages of RLE?
.