Computer Fundamentals Northern College Diploma Philip Bird
Bits and Bytes Computers work with on’s and off’s – Binary digital values 0 and 1. Binary digits (bits) are usually organised into groups of 8 – a byte. We can use a byte to represent a whole number (integer), a fraction (real) and a character. We can also represent negative numbers.
Converting to Binary Base4 Base3 Base2 Base1 Base0 10000 1000 100 10 1 Decimal 16 8 4 2 Binary
Converting from Binary 16 8 4 2 1 = 13 = 22
Binary Addition 128 64 32 16 8 4 2 1 =102 =117 1 1 1 1 1 1 1 1 1 =219
Storing Characters 128 64 32 16 8 4 2 1 =65 ‘A’ =97 ‘a’ =43 ‘+’
Storing Negative Numbers -128 64 32 16 8 4 2 1 =38 =-90 =127 =-128
Storing Fractions 1/2 1/4 1/8 1/16 1/32 1 =13/16 =23/32
Logic Gates Used to process the binary digits. Originally made as valves, then transistors then integrated into circuits on a chip. History of smaller, faster, denser, cheaper. Each gate governed by a rule.
NOT Gate In Out 1 NOT 1 1 Rule: 1 NOT 1 1 Rule: The output is the opposite of the input.
AND Gate In1 In2 Out 1 1 1 AND Rule: 1 1 1 AND Rule: The output is 1 if all the inputs are 1.
OR Gate In1 In2 Out 1 1 1 OR Rule: 1 1 1 OR Rule: The output is 1 if any of the inputs are 1.
XOR Gate In1 In2 Out 1 1 1 XOR Rule: 1 1 1 XOR Rule: The output is 1 if either of the inputs are 1 but not both.
Summary Why do computers use binary? What can be stored in binary? What is a logic gate used for?