kids encyclopedia robot

Computer memory facts for kids

Kids Encyclopedia Facts
RAM Module (SDRAM-DDR4)
DDR4 SDRAM module. As of 2021, over 90 percent of computer memory used in PCs and servers was of this type.

Computer memory is like a computer's short-term workspace. It holds information, like programs and data, that the computer needs to use right away. When people talk about "memory," they often mean RAM, main memory, or primary storage.

This main memory works super fast. It's much quicker than mass storage devices like hard drives. Besides holding programs that are open, computer memory also helps speed up reading and writing information. It acts like a temporary storage area for data that the computer might need soon. If the computer needs more space, it can move information from memory to slower storage using a trick called virtual memory.

Most modern computer memory uses special electronic parts called semiconductor memory. Data is stored in tiny memory cells made from MOS transistors and other parts on a small chip. There are two main types: volatile and non-volatile. Volatile memory needs power to keep its information, like the RAM in your computer. Non-volatile memory keeps data even when the power is off, like flash memory in a USB stick or your phone.

Most memory cells store one bit of information (a 0 or a 1). These bits are grouped into "words" of a certain size, like 8, 16, or 64 bits. Each word has a unique address, so the computer can find and use it quickly.

How Computer Memory Grew Over Time

Historical cost of computer memory and storage
Historical lowest retail price of computer memory and storage

In the early 1940s, computers could only store a few bytes of information. The first electronic digital computer, the ENIAC, used thousands of vacuum tubes. It could handle about 20 numbers at a time.

A big step forward was the delay-line memory in the early 1940s. It stored information as sound waves in a glass tube filled with mercury. This type of memory could hold a few thousand bits.

In 1946, two new ideas came along: the Williams tube and Selectron tube. Both used electron beams in glass tubes to store data. The Williams tube was the first random-access computer memory. This meant the computer could access any piece of data directly, without having to read through everything before it. The Williams tube could store thousands of bits and was cheaper than the Selectron tube.

Non-Volatile Memory Arrives

People soon wanted memory that wouldn't lose data when the power went off. This led to Magnetic-core memory in the late 1940s and early 1950s. It became the main type of memory until the 1960s.

The first semiconductor memory (memory made from electronic components) appeared in the early 1960s. These early versions used bipolar transistors. In 1961, the idea of putting solid-state memory on a single integrated circuit (IC) chip was suggested. The first such chip came out in 1965. While faster, these early semiconductor memories were bigger and more expensive than magnetic-core memory at first.

The Rise of MOS Memory

The invention of the MOSFET (metal–oxide–semiconductor field-effect transistor) changed everything. This led to MOS memory in 1964. MOS memory was faster, cheaper, and used less power than magnetic-core memory. By the early 1970s, MOS memory had become the most common type.

The two main types of fast, temporary memory (RAM) are static RAM (SRAM) and dynamic RAM (DRAM). SRAM was invented in 1963 and uses six transistors for each bit of data. It was used in early computers like the System/360 Model 95 in 1965.

DRAM, which is what most computers use today for main memory, was developed by Robert H. Dennard at IBM in 1966. He realized that a single MOS transistor and a capacitor could store one bit of data. This made DRAM much smaller and cheaper per bit. The first commercial DRAM chip, the Intel 1103, came out in 1970. Later, SDRAM arrived in 1992, which is even faster.

Memory that keeps data without power, like read-only memory (ROM), also developed. Programmable read-only memory (PROM) was invented in 1956. Then came EPROM (erasable PROM) in 1971, which could be erased with ultraviolet light. EEPROM (electrically erasable PROM) followed in 1972, allowing electrical erasing. Finally, Flash memory was invented in the early 1980s by Fujio Masuoka at Toshiba. Flash memory is now used in USB drives, solid-state drives (SSDs), and smartphones.

Volatile Memory

Kinds-of-RAM
Various memory modules containing different types of DRAM (from top to bottom): DDR SDRAM, SDRAM, EDO DRAM, and FPM DRAM

Volatile memory needs power to keep its information. If the power goes off, the data is lost. The most common types of volatile memory are static RAM (SRAM) and dynamic RAM (DRAM).

  • DRAM is used for the main memory in most desktop computers and laptops. It's very dense, meaning it can store a lot of data in a small space, and it's cheaper per bit. However, it needs to be "refreshed" constantly to prevent losing its contents.
  • SRAM is faster than DRAM and doesn't need refreshing. It's often used for CPU cache memory, which is a small, super-fast memory area close to the computer's brain (the CPU). SRAM uses more transistors per bit, making it more expensive and less dense than DRAM.

Non-Volatile Memory

Non-volatile memory can hold onto information even when there's no power. Think of it like long-term storage for your computer.

Examples of non-volatile memory include:

Scientists are always working on new types of non-volatile memory to make them faster and store even more data.

Memory Management

Properly managing memory is super important for a computer to work well. Modern operating systems (like Windows or macOS) have complex systems to handle memory. If memory isn't managed correctly, it can lead to problems or slow down your computer.

Common Memory Problems

  • Memory Leak: This happens when a program asks for memory but never gives it back when it's done. Over time, the program uses more and more memory until the computer runs out, causing the program to crash.
  • Segmentation Fault: This occurs when a program tries to access memory it's not allowed to use. The operating system usually stops the program to prevent it from causing more trouble.
  • Buffer Overflow: This is when a program tries to write too much data into a specific memory area, spilling over into other areas. This can make programs act strangely, crash, or even create security risks that bad guys can use.

Virtual Memory

Virtual memory is a clever system where the operating system manages both fast RAM and slower hard drive space as if it were one big memory pool. This means computer programmers don't have to worry about how much physical RAM a user has. The operating system moves data between RAM and the hard drive (using a swapfile) as needed. It keeps the most used data in fast RAM.

However, if the computer doesn't have enough RAM and has to move data back and forth too much, it can slow down a lot. This is called thrashing.

Protected Memory

Protected memory is a system that gives each program its own private area of memory. It stops programs from trying to use or change memory that belongs to other programs. If a program tries to do this, the operating system usually shuts it down.

This makes computers much more reliable and secure. Without protected memory, a bug in one program could mess up the memory of another program, causing crashes or allowing harmful software like viruses to take control.

Images for kids

See also

Kids robot.svg In Spanish: Memoria principal para niños

  • Memory geometry
  • Memory hierarchy
  • Memory organization
  • Processor registers store data but normally are not considered as memory, since they only store one word and do not include an addressing mechanism.
kids search engine
Computer memory Facts for Kids. Kiddle Encyclopedia.