SLR11 - Number Bases Flashcards

(29 cards)

1
Q

How is a number’s base shown using subscript?

A

Unsigned binary only represents positive numbers. Smallest value = 0, largest = 2ⁿ - 1

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

What is signed binary?

A

Signed binary uses the MSB as a sign bit:

0 = positive

1 = negative
Used with two’s complement.

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

What is the maximum value you can store in 8-bit unsigned binary?

A

255 (from 0 to 255)

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

Why is the max value in 8-bit unsigned binary 255 and not 256?

A

Because we start counting from 0. So 256 values, but highest number is 255.

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

In two’s complement, what is the range for 8 bits?

A

-128 to +127

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

Why does two’s complement allow one more negative number than positive?

A

Because the MSB has negative weight (e.g., -128 in 8 bits), and there’s no +128.

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

How do you convert a positive denary to binary?

A

Divide by 2, record remainders, reverse the result.

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

How do you convert negative denary to binary (two’s complement)?

A
  1. Convert absolute value to binary
  2. Invert the bits
  3. Add 1
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

How do you convert binary (two’s complement) to denary?

A

If MSB is 0 → convert normally

If MSB is 1 →
1. Invert the bits
2. Add 1
3. Convert to denary and add minus sign

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

What are the binary addition rules?

A

0 + 0 = 0
0 + 1 = 1
1 + 0 = 1
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
11
Q

What are the two possible errors in binary arithmetic?

A

Overflow: result is too big for available bits

Underflow: result is too small to be stored

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

How do you detect overflow in binary addition?

A

If carry out of MSB ≠ carry into MSB

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

What is fixed point binary representation?

A

Binary numbers where the binary point is in a fixed position (e.g., 4 bits for integer, 4 for fraction).

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

Can fixed point binary represent negatives?

A

Yes, using two’s complement for the integer part.

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

What are limitations of fixed point?

A
  1. Limited range
  2. Limited precision
  3. Some fractions like 1/3 can’t be stored accurately
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What is floating point binary representation?

A

A way to represent real numbers using two parts:

Mantissa = actual digits

Exponent = moves the binary point left/right

17
Q

What is the benefit of floating point over fixed point?

A

Much wider range, useful for scientific or very large/small numbers.

18
Q

What does a positive exponent mean in floating point?

A

Move binary point right → larger number

19
Q

What does a negative exponent mean in floating point?

A

Move binary point left → smaller number

20
Q

In floating point, what does accuracy depend on?

A

Length of the mantissa

21
Q

In floating point, what does range depend on?

A

Length of the exponent

22
Q

What is absolute error?

A

Actual value - stored value

23
Q

What is relative error?

A

(Absolute error ÷ Actual value) × 100

24
Q

What is hexadecimal?

A

Base-16 number system. Digits go from 0–9 then A–F.

25
Why is hexadecimal used?
Easier to read than long binary Compact way to represent binary values
26
How many bits does each hex digit represent?
4 bits per hex digit
27
How do you convert binary to hex?
Split into 4-bit chunks, convert each to hex
28
How do you convert hex to binary?
Convert each hex digit to its 4-bit binary equivalent
29
How do you convert hex to denary?
Multiply each digit by its positional value (16ⁿ) and add