|
||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
Data Representation and Memory |
|
|||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Binary NumbersDigital computers operate on data represented as binary numbers, such as 0, 1, 10, 11, 100, 101, 110, 111, ... (0, 1, 2, 3, 4, 5, 6, 7, ...). All data, whether in the form of magnitudes, text, pictures, sound, symbols, or calculus (such as integration and differentiation), are represented as binary numbers in a digital computer. Any type of data can be processed by addition, multiplication, comparison, or other simple operations by the ALU. A "1" in binary is evaluated as an ON switch in the electronics. A "0" in binary is evaluated as OFF switch in the electronics. This value can also represent another meaning: a "1" in binary is TRUE and "0" is FALSE. Through these values you get binary logic, which allows a computer to actually "compute". In a binary number with p positions, each position is occupied by either 1 or 0. 1 in the rightmost position represents 1 (i.e., 20), 1 in the second position from the right represents 2 (i.e., 21), 1 in the third position represents 4 (i.e., 22), and so on, and 1 in the pth position means 2p - 1. Thus, the binary number 101 is 1 x 22 + 0 x 21 + 1 x 20 --that is, decimal number 5. MemoryMemory is a sequence of numbered "cells" or "pigeon holes," each containing a small piece of information. The information may be an instruction to tell the computer what to do. The cell may contain data that the computer needs to perform the instruction. Any slot may contain either, and indeed what is at one time data might be instructions later. The size of each cell, and the number of cells, varies greatly from computer to computer, and the technologies used to implement memory have varied greatly - from electromechanical relays, to mercury-filled tubes (and later springs) in which acoustic pulses were formed, to matrices of permanent magnets, to individual transistors, to integrated circuits with millions of capacitors on a single chip. Data are stored in a computer as binary digits, or bits. If a binary number consists of n positions, it is said to be an n-bit number. Eight consecutive bits is called a byte. Therefore, a binary number of 16 bits has 2 bytes, a binary number of 32 bits has 4 bytes, and so on. Both the primary and auxiliary devices have capacity measured in bits, bytes, kilobytes, megabytes and gigabytes. There are 8 bits in a byte. Many computers store one character as one byte. One byte is enough information to store one alphanumeric character (e.g. letter or decimal digit). A kilobyte is 1024 bytes, a megabyte is 1024 kilobytes (1,048,576 bytes), and a gigabyte is 1024 megabytes (1,073,741,824 bytes). Each location in a memory is assigned a unique numeric address, by which the location is accessed. Data stored in each memory location consists of a fixed number of bits. This number is usually a power of 2 -- i.e., 4, 8, 16, 32, or 64 bits); such a binary sequence is called a memory word, or simply word. The physical memory of a computer is either random access memory (RAM), which can be read or changed by the user or computer, or read-only memory ( ROM), which can be read but not altered. Computer chips hold memory, as do floppy disks, hard disks, and CD-ROMs (compact discs). Memory HierarchyAs CPUs have become faster and more powerful, a fundamental bottleneck in computer design is the flow of information back and forth from memory to the CPU. Currently, there are now many types of memory devices with different costs, access times and storage capacities. Generally the faster the access time, the more expensive the memory. Consequently, good design is based on a memory pyramid for providing increasing amounts of less costly, slower memory.
|
|||||||||||||||||||||||||||
|
EncycloZine ® © 1998 - 2006 • Artzia.com • CuriousMinds.co.UK • diXionary.com • Eluzions.com • Kosmoi.com |
|||||||||||||||||||||||||||