Unit 1.1 - Number systems Flashcards
What is binary?
The number system used by computers. This number system has values of 0 and 1, meaning it is a base-2 number system. Computers represent data in binary because there being only 2 states (on and off) means that it is less likely to make errors and because logic gates (electric circuits which determine how binary data is processed) use on and off and because they can only process and store the numbers 1 and 0.
What are registers?
A small location in the CPU (central processing unit) where memory is temporarily stored and can be accessed after being processed.
What does digitized mean?
Converted into binary
What is the denary number system?
The numbering system humans are accustomed to; base-10
What is the hexadecimal number system and what is it used for?
A numbering system used to represent binary numbers in a more human-friendly form; Base-16. Used for representing colors (#RRGGBB) , show error messages to make it easier for humans to read and understand, representing large numbers will less digits.
How to convert between different types of number systems
- Binary to Denary - write the powers of 2 above each digit, starting with 1 at the very right, multiply the top and bottom number together and then add them.
- Denary to Binary - see if number is bigger than 128, if not move onto next power of 2, if yes subtract 128 from that number and continue the cycle.
- Binary to Hexadecimal - 1 nibble (4bits) = hexadecimal digit so multiply the binary digits by powers of 2 like before and add them together is 4s.
- Hexadecimal to Binary - write out each hexadecimal digit as a nibble and place them one after another
- Hexadecimal to Denary - multiple each digit by a power of 16, starting with the LSB (least significant bit) by 1, then by 16, etc. Add all numbers together
- Denary to Hexadecimal - first convert denary number into binary, and then convert from binary to hexadecimal because its easier
What is an overflow error?
The largest denary number that can be represented by 8 bits is 255. If a computer tries to represent or calculate a value which exceeds this, an overflow error will occur. An overflow error occurs when a computer can’t store the results of a calculation in the register allocated for the task. The computer system will likely crash because of that.
What are logical shifts?
An operation that moves the digits of the binary number left or right depending on type of shift. This will either multiply or divide the number - right:dividing) , left:(multiplying)
What kind of error will result if a logical shift right results in removing a positive bit?
Rounding error
What is two’s complement?
Method of representing positive and negative binary digits. Done by writing the number as positive, and then flipping every 1 and 0 until the last one. The last one and every digit after it is not not changed.