Fundamentals of Data Representation Flashcards

1
Q

What are Natural Numbers?

A

All positive numbers and zero; used to count

Denoted by an N

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

What are Integer Numbers?

A

All whole numbers, positive and negative

Denoted by a Z

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

What are Rational Numbers (Quotients)?

A

Where a number can be written exactly as a fraction of one number over another where the numerator and denominator are whole numbers

Denoted by a Q

Irrational Numbers are the opposite; they have no symbol

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

What are Real Numbers?

A

All possible real-world quantities; all rational and irrational numbers

Denoted by an R

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

What are Ordinal Numbers?

A

Integers used to describe the position of objects in relation to others. E.g., 1st

Arrays index items using Ordinal Numbers, typically starting with element 0

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

Why do we use Hexadecimal?

A

Because it’s the most compact; it can represent long binary numbers in a short form.

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

How do you convert from denary to hexadecimal?

A

Convert the denary number into an 8-bit binary number.

Split the binary number into two nybbles (four bits).

Convert each nybble back into denary.

Plug them back into the hex table [0-9=0-9, 10-15=A-F]

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

For Kibi, Mebi, Gibi, Tebi… how do we work out the number of bits?

A

Kibi = 2^10, Mebi = 2^20, Gibi = 2^30 etc. It has a base of 2 and increments in powers of 10.

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

For Kilo, Mega, Giga, Tera… how do we work out the number of bits?

A

Kilo = 10^3, Mega = 10^6, Giga = 10^9 etc. It has a base of 10 and increments in powers of 3.

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

What does signed binary mean?

A

It can be used to represent both positive and negative numbers.

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

What are the four rules of binary arithmetic?

A

0 + 0 + 0 = 0 [carry 0]

0 + 0 + 1 = 1 [carry 0]

0 + 1 + 1 = 0 [carry 1]

1 + 1 + 1 = 1 [carry 1]

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

How do you multiply binary numbers?

A

Align binary numbers.

Do normal long multiplication.

Add all lines together to find the result.

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

What does Two’s Complement mean?

A

In two’s complement, the most significant bit is its negative version.

It’s used to represent negative binary numbers.

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

How do you subtract binary numbers?

A

Turn the second binary number into two’s complement negative equivalent.

Add it to the first one.

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

How do you convert a Binary Number into Two’s Complement?

A

Move from right to left, until you find the first binary 1.

Flip every bit more significant than that first binary 1.

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

How do you convert a decimal number to normalised binary number?

A

Write the number in fixed point binary. (If it’s negative, write the positive version and find its Two’s Complement).

Move the binary point to the most significant instance of 10 or 01 depending on whether it’s positive or negative.

Your exponent is the number of places you moved the binary point. Left = Positive, Right = Negative. Then convert that to binary.

The mantissa is the sequence from the 10/01 section onwards to fill the gap.

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

How do you convert a floating-point binary number to a decimal number?

A

Assume that the binary point starts after the first bit in the mantissa.

Move it by the exponent, where right is positive, and left is negative.

Now, whatever is to the left of the point is 1, and to the right of it is a half.

Convert to denary as if it were fixed point.

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

What is a Rounding Error?

A

Some decimal numbers can’t be represented exactly in binary. So, we try to get as close as possible.

Sometimes this isn’t very accurate and gives us a “Rounding Error”.

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

How can you calculate Absolute Error?

A

Absolute error is the amount by which the given value is inaccurate to the actual value.

It’s found by the difference between the two values.

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

How do you calculate Relative Error?

A

A relative error is a measure of uncertainty in a given value compared to the actual value.

Calculated using the formula: relative error = absolute error / actual value

You can multiply by 100 to find this as a percentage.

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

What are the advantages of Floating-Point Binary instead of Fixed-Point Binary?

A

It allows for representation of a greater range of numbers.

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

What are the advantages of using normalised binary?

A

Maximises precision/accuracy for a given number of bits.

Gives a unique representation of each number.

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

What are the effects of a greater mantissa and exponent (MARE)?

A

Greater Mantissa ===> Greater Accuracy

Greater Exponent ===> Greater Range

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

What is Underflow Error?

A

An underflow error occurs when very small numbers are to be represented but there aren’t enough bits available.

26
Q

What is Overflow Error?

A

An overflow error occurs when very large numbers are to be represented but there aren’t enough bits available.

Overflow happens in binary addition when a number is too large for the given number of bits.

27
Q

How many bits is ASCII?

A

7 bits

28
Q

How many bits is Unicode?

A

Anywhere from 8 to 48 bits

29
Q

What’s the advantage of using Unicode instead of ASCII?

A

It can represent a wider range of characters

30
Q

What’s the advantage of using ASCII instead of Unicode?

A

It takes up less storage space

31
Q

What is a Parity bit?

A

A single bit added to a transmission that can be used to check for errors in transmitted data.

32
Q

How do Parity bits work?

A

There are two types of parity bit: even and odd.

In even parity, the total number of ones should be even; in odd, it should be odd.

When data is received a “parity check” is carried out. If the parity check is wrong, the computer will request that the sender re-transmits the data.

33
Q

What is Majority Voting?

A

When using majority voting, each bit is sent multiple times.

Then it’ll tally up the number of each bit in each section and choose the one there is the most of.

34
Q

What is the advantage of Majority Voting?

A

Majority Voting corrects the error

35
Q

What is the disadvantage of Majority voting?

A

Means more data must be sent, since each bit must be sent multiple times

36
Q

What is a Checksum?

A

Like a parity bit, a checksum is added to the data being transmitted.

However, a checksum is made from the data using an algorithm.

37
Q

What is a Check Digit?

A

A check digit is a type of checksum in which only a single digit is added to the transmitted data.

38
Q

What is a Digital Signal?

A

A system of discrete states; 1 or 0.

39
Q

What is an Analogue Signal?

A

A continuous signal that varies in amplitude or frequency.

40
Q

Advantages of Analogue signals over Digital signals?

A

Analogue has more exact values because Digital has a finite range of values between zero and one.

41
Q

Advantages of Digital signals over Analogue signals?

A

Has less data to transmit than analogue

Easier to store and compress

42
Q

What is an ADC and how does it work?

A

Analogue to Digital Converter; converts an analogue signal into a digital signal.

Regular samples are taken of the amplitude of the analogue signal wave, that amplitude is then converted to a binary integer.

43
Q

What is a Bitmap Graphic?

A

A bitmap is organised as a grid of coloured squares called pixels; each different pixel has a colour which is stored by a binary number.

44
Q

What happens to the quality of a bitmap as it’s enlarged?

A

It decreases

45
Q

What is image resolution?

A

Number of pixels on an image; width * length

46
Q

What is image resolution?

A

Number of pixels in an image; width * length

47
Q

What is the Colour Depth of an image?

A

The number of bits used to represent each pixel in a bitmap.

48
Q

How do you figure out the number of colours each pixel could make?

A

No. Colours = 2^(bits)

49
Q

What is Nyquist Theorem?

A

the sampling rate should be at least twice the highest frequency

50
Q

Lossy Compression

A

Works by removing non-essential information.

Comes at the cost of quality

51
Q

Lossless Compression

A

Works by recording patterns in data rather than actual data, and using these patterns the computer can reverse the procedure and reassemble an image, sound or text file with exact accuracy, and no data is lost.

Can’t reduce size as much as lossy but doesn’t lose any data when it does compress.

52
Q

Run-Length Encoding (RLE)

A

an example of lossless compression; takes note of repeated data and writes them in a way they no longer are being repeated.

53
Q

Dictionary-based compression techniques

A

The compression algorithm works in a way that searches through the text to find suitable entries in its own dictionary and translates the message accordingly.

54
Q

What is encryption?

A

process of converting plaintext into ciphertext

55
Q

Caesar Cipher

A

substitution cipher that works by shifting letters of the alphabet along by a given number of characters (key)

brute force attack would only need 25 different possibilities to crack it.

56
Q

Vernam Cipher

A
  • one-time pad must be equal to or longer in characters than the plaintext but truly random and only used once
  • Boolean XOR operation is carried out between binary representation of plaintext and the one-time pad

to decrypt XOR operation carried out on the ciphertext using same one-time pad to restore to plaintext.

57
Q

What is a MIDI? What does it do?

A

Musical Instrument Digital Interface

Creates synthesized sounds as requested from from an instrument/software.

58
Q

How does a MIDI pay sounds? Why are they synthesized and not recorded?

A

The sounds are triggered by instructions called event messages, which are 2-3 bytes long. Using a synthesized sound means only the instruction is needed to play the sound, reducing data sent.

59
Q

In assembly language how do you DIVIDE

A

Logical shift RIGHT

60
Q

In assembly language how do you MULTIPLY

A

Logical shift LEFT