105 Flashcards

1
Q

What is the decimal number system?

A

> Base 10 system

> Maximum number value that can be stored goes up by the equation 10^n - 1

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

What is the binary number system?

A

> Base 2 system

> The max value that can be stored goes up by the equation 2^n - 1

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

How are binary numbers grouped?

A

> In groups of 4

> Leading 0’s are added

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

What is a 4 bit group called?

A

A nibble

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

What is an 8 bit group called?

A

Byte

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

What is the hexadecimal number system?

A

> Base 16 system
Symbols 0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F
A-F represents 10-15
The max number that can be stored goes by the equation: 16^n - 1

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

Why is hexadecimal useful when compared to binary?

A

Each nibble can be represented by a single hexadecimal digit

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

How are hexadecimal often notated?

A

> This a 0x at the front

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

How are decimal numbers converted to binary?

A

> Construct the decimal number by summing powers of 2

> 97 = (2^6) + (2^5) + (2^0)

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

How are binary numbers converted to hexadecimal?

A

Split the binary number into nibbles and convert each nibble into a corresponding hexadecimal number

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

How are hexadecimal numbers converted to binary?

A

Convert each hexadecimal digit into the equivalent nibble

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

How are decimal number converted to hexadecimal?

A
> Construct the decimal number by summing multiples of powers of 16
> 3740 = 14(16^2) + 9(2^1) + 12(2^0) = 0xE9C
# 3740/16^2 = 14 remainder 156
# 156/16^1 = 9 remainder 12
# 12/16^0 = 12
# so 0xE9C
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What is a signed number?

A

> A way of writing negative numbers in binary
Positive integers are unsigned integers
Negative integers are signed integers

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

What are the 3 ways of displaying negative numbers?

A

> Sign-magnitude format
1’s Complement format
2’s Complement format

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

What is sign-magnitude format?

A

> Most significant bit is used to represent the sign
0 represents positive numbers
1 represents negative numbers
The remaining bits represent the number

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

What is the problem with sign-magnitude format?

A

> There are 2 ways of representing 0
0000
1000

17
Q

What is the range of sign-magnitude format?

A

-2^(n-1) + 1 ≤ x ≤ 2^(n-1) - 1

18
Q

What is 1’s compliment?

A

> Positive numbers are represented normally

> Negative number are represented as the inverse (1’s become 0 and 0’s become 1)

19
Q

What is the problem with 1’s complement?

A

> There are 2 ways of representing 0
0000
1111

20
Q

What is 2’s complement?

A

> This is a method of representing positive and negative numbers without there being 2 numbers for 0

21
Q

What is the range of 1’s complement?

A

-2^(n-1) + 1 ≤ x ≤ 2^(n-1) - 1

> Same as sign-change

22
Q

How does 2’s complement work?

A

> The most significant bit is treated as negative and the rest is calculated like normal.

23
Q

What are the parallels between 1’s and 2’s complement?

A

> 2’s Complement is the same as 1’s Complement except 1 has been added to the number

24
Q

What is the range of 2’s complement?

A

> It is 1 decimal number larger than 1’s complement because there is only one representation of 0 (0000)
-2^(n-1) ≤ x ≤ 2^(n-1) - 1

25
Q

What are the 4 basic rules for adder circuits?

A

> 0 + 0 = 0
0 + 1 = 1
1 + 0 = 1
1 + 1 = 0 carry 1 = 10

26
Q

What is a half adder? What is the circuit?

A

> This is a circuit that sums 2 bits
An XOR gate for the sum bit in parallel with…
An AND gate for the carry bit

27
Q

What happens when you have multiple bits to be added in a half adder system?

A

The carry bit is then fed into the next adder which has 3 input gates

28
Q

What is a full adder?

A

> This takes into consideration the carry bit into the addition of 2 bits.
Multiple full adders can be strung together to add multiple bits

29
Q

What are the 2 boolean expressions for a full adder?

A

> sum= A⨁B⨁Ci

> Co=A.B+Ci.(A⨁B)

30
Q

What is it called when multiple full adders are joined together?

A

A ripple adder

31
Q

Do ripple adders work for all signed numbers?

A

> No

> Just 2’s complement

32
Q

How can a ripple adder work with 2’s complement?

A

As long as the final carry bit is ignored