Discoveries and inventions · Lesson 21
The computer
Full reading material for study and lesson preparation. Original explanations accompany the experiments and illustrations on the main page.
Open interactive lesson
1. What a computer does
A computer receives data, executes instructions and produces results. Data can represent numbers, text, sound, pictures or sensor readings. A program determines what operations to perform on those data. The same computer can help write a letter, edit a photograph and calculate a route because different programs are run for those tasks.
Consider two inputs, 2 and 3. An addition instruction produces 5. A comparison instead answers a question about their order. Data and instructions have different roles: a number alone does not specify whether it should be added, compared or used as the size of a drawing.
A computer need not resemble a desktop tower. Computing devices occur in phones, cars, cameras and industrial equipment. However, not every electrical device is a general-purpose computer. Examine its functions: what enters, where instructions are held, how state changes and what is produced.
2. Babbage’s machines
In the nineteenth century, Charles Babbage designed mechanical calculating devices. His Difference Engine was intended to generate numerical tables using finite differences. This was a specialised task: performing it was useful, but did not imply the ability to run arbitrary programs. Historical components survive, and museum reconstructions were built later.
The Analytical Engine was conceived as a more general device with number storage, processing and programmed control. A complete working engine of this design was not built during Babbage’s lifetime. Distinguish a design, a constructed component and a completed device: a museum component does not establish that a finished computer existed.
3. Ada Lovelace and programming
In 1843, Ada Lovelace published notes on the Analytical Engine. They included an algorithm for calculating Bernoulli numbers. An algorithm specifies a sequence of operations; a program expresses them in a form a particular device can execute. Operations can be described before the device itself is completed.
Lovelace discussed working with symbols when their relationships could be expressed numerically; musical notes were one example. Modern digital devices do use numerical representations of many forms of information, but nineteenth-century notes were not a finished digital-audio technology or a modern operating system.
4. Punched cards and data processing
A hole at a particular position on a card can represent a value. A machine detects the hole arrangement and uses it as input data. Herman Hollerith used punched cards to process the 1890 US census, helping mechanise the handling of many similar records.
A punched card is not automatically a program. One can store a person’s record, another part of a program; its role depends on the system. Nor can arbitrary holes be treated as a binary number without specifying an encoding. Reading information requires a correspondence between positions and values.
5. Turing’s mathematical model
In 1936, Alan Turing described a mathematical model of a computing device. It reads symbols, writes new ones and changes state according to rules. The model enables precise discussion of algorithms and computability. Its tape and head are elements of a mathematical description, not a modern laptop blueprint.
A universal machine can execute descriptions of different algorithms. Some problems nevertheless have no general solving algorithm. This does not mean every difficult task is unsolvable: distinguish the fundamental absence of a general method from practical shortages of time, memory or an efficient algorithm.
6. Electronic machines and stored programs
ENIAC, presented in 1946, was an early general-purpose electronic computer. Initially, programming required configuring switches and connections. Six women programmers were important in translating mathematical tasks into machine operations. Calling a device simply “the first computer” can mislead: mechanical, relay and electronic machines have different milestones.
On 21 June 1948, the experimental Manchester Baby ran a program held in electronic memory. Cambridge’s EDSAC began operating in 1949 and was used for scientific computation. A stored program places instructions in memory where they can be read much like other data. Modern reconstruction photographs are not photographs of these first runs.
7. Computers on the desk
Transistors, integrated circuits and microprocessors helped reduce computing-device size. The Altair 8800 was a landmark hobbyist computer in 1975; the Apple II appeared in 1977, followed by the IBM PC in 1981. These milestones do not make one company the sole inventor of personal computing.
Portable computers expanded where work could be done. Early portables were larger and heavier than familiar laptops. Accessible applications and usable controls also mattered: reducing case size alone does not help a person write a document without appropriate software and an understandable interface.
8. Components work together
The processor executes instructions. Working memory holds data and instructions in current use. Storage preserves files for later use. Input devices convey human actions or sensor readings; output devices present results. The motherboard and interconnections enable communication between components, while the power supply provides energy.
Functions can be combined in one package or chip. The lesson’s division into processor, memory and storage describes roles rather than mandatory separate boxes. Its motherboard illustration presents a general arrangement, not exact connectors or instructions for repairing a particular product.
9. Executing an instruction
The experiment has six instructions and register A, a small workspace holding one number. LOAD writes a value; ADD adds; SUB subtracts; GT compares against a specified value and stores 1 for true or 0 for false. OUT displays a value; HALT stops execution. This small illustrative instruction set makes the mechanism understandable.
Each instruction has three displayed steps: fetch, decode and execute. Execution in this model includes writing the result. After LOAD 2, the register holds 2; after ADD 3 it holds 5. Only OUT sends 5 to the screen: holding a value in a register and displaying it are different events.
One click does not correspond to a real processor clock cycle. Actual architectures contain more details, and stages of several instructions can overlap. The experiment traces how instructions determine the result; it does not measure device speed.
10. Working memory and saving
Ordinary RAM is volatile: its contents are lost when power ends. An SSD retains written data without continuous power. Opening a document makes its data available for current work; saving writes a new version to storage. Fast working memory and persistent storage serve different purposes.
First write a note and switch power off without saving. Power it on: the note is gone. Repeat after pressing Save, switch power off and on, and open the file. The saved text returns. If you edited the text after saving, reopening returns the earlier saved version.
The model deliberately omits autosave. Real editors may create recovery copies, synchronise documents or save automatically. Those features do not eliminate the distinction between working data and a stored file. RAM capacity is also not the amount of free persistent space for photographs.
11. Magnetic and semiconductor media
A floppy disk stores data magnetically. In an HDD, platters rotate while heads read and write. An SSD uses semiconductor memory, generally NAND flash, without rotating platters. Removing mechanical movement changes access delays, but actual speed also depends on the controller, interface and operation.
A file is organised data with a purpose and format. Its name and extension help people and software select how to process it, but renaming does not convert its content. Naming a photograph “music” does not make it produce sound. Storing data and interpreting its format are related but different tasks.
12. A picture as data
The model drawing has eight rows of eight dots. A light cell is 0; a dark cell is 1. Row 00011000 means three light dots, two dark dots and three more light dots. The symbols describe cells from left to right; they are not one decimal value for the entire picture.
Each cell needs one bit, giving 8 × 8 = 64 bits. A byte contains eight bits, so 64 ÷ 8 = 8 bytes. That is only the monochrome data size, excluding a header, dimensions and other metadata. A real file format can add such information or use compression.
A colour display commonly uses red, green and blue components. Storing different brightness levels requires more states than the single cell’s 0 or 1. The macro illustration shows the idea of coloured display elements; their physical arrangement depends on technology. Enlarging an image alone does not create new original detail.
13. Interfaces and input
A mouse reports movement and clicks; a keyboard reports keys; a drawing tablet reports pen actions. An application interprets the data. The same mouse movement can move a window, draw a line or rotate an object depending on the program, active mode and pointer position.
A usable interface explains an action, shows its result and allows mistakes to be corrected. That is why the experiments include labels, state displays and reset controls. A user should not have to guess what an unexplained slider changes. Save is clearer when a separate stored version is visible.
14. An algorithm for the robot
The robot starts at bottom left facing right. Forward moves one cell in its current direction. Left and Right turn it through 90 degrees without moving. Turning is not a step: its coordinate remains the same, but the next movement follows a different heading.
The working example is Forward, Left, Forward twice, Forward twice, Right, Forward twice and Forward. The robot travels up a free column and then across to the goal. Seven program entries produce ten individual actions because three entries repeat a movement.
The broken example contains two Forward steps. The second meets a block. Execution stops before entering it, and the message identifies the failing instruction. Debugging means finding and correcting the cause of a wrong result. Step through, explain the error and change the sequence instead of simply running it again.
Editing the program returns the robot to start. Return to start keeps instructions; Reset removes them. The map checks the action sequence without calculating speed, wheel traction or real sensor readings. Actual engineering must account for those limits separately.
15. Conditions and repetition
An algorithm need not be a straight chain of identical actions. A condition chooses: if temperature is below 22 °C, turn heating on; otherwise off. At 18 °C the condition is true, at 27 °C false, and at exactly 22 °C false because “below” is a strict comparison.
Repetition performs an operation several times. In Forward twice, the number 2 sets the number of moves. Conditions and repetition can shorten programs but do not guarantee correctness. Repeating a wrong move twice meets an obstacle; it does not automatically avoid it.
The selected experiment temperature is an input reading, not a room-heating calculation. Real thermostats commonly use hysteresis, with different on and off thresholds. This avoids switching on every small temperature fluctuation around one boundary.
16. Why sorting works
Bubble sort compares adjacent elements, swapping them when the left is larger. For 7, 2, 5, 1, the first comparison gives 2, 7, 5, 1; the next gives 2, 5, 7, 1; the third gives 2, 5, 1, 7. The largest number reaches the end.
The next pass processes the remaining part, followed by a final comparison. This experiment uses six comparisons: three, two and one. The result is 1, 2, 5, 7. This accessible demonstration is not necessarily the method chosen for large datasets. Faster hardware does not remove the importance of an efficient algorithm.
17. Why an operating system is needed
An operating system manages resources, helps applications use devices and organises file access. A user starts an editor or music player, while the system coordinates software and hardware. The application, operating system and physical device are different parts of the work.
One processing core can switch rapidly between tasks. The system saves one task’s state and gives another a time slice. Drawing, music and archive each receive three turns in the model; all finish in nine steps. Programs can appear simultaneous although the displayed core works on them in turn.
Real multitasking includes device waits, priorities and switching costs. Multiple cores can execute work in parallel. Not every task can be easily divided because later computations may depend on earlier results. Core count alone does not determine a program’s execution time.
18. Energy, heat and speed
Electronic components consume energy and release heat. Heat sinks increase exchange area; fans move warm air. Temperature limits constrain operation. A cooling illustration should explain heat transfer without treating every highlighted line as a measured airflow path.
The experiment’s task sequentially needs 4 seconds loading, 6 computing and 2 displaying, totalling 12. Twice-fast loading gives 2 + 6 + 2 = 10 seconds. Twice-fast computing gives 4 + 3 + 2 = 9 seconds. Speeding one stage does not halve the entire total.
These are illustrative values, not measurements on an actual computer. Stages can overlap, and time depends on software, data, storage, processing and other conditions. Before changing hardware, identify which stage delays the particular task.
19. Large computations and scientific models
A supercomputer combines many computing nodes. In 2022, Frontier achieved exascale performance in the HPL benchmark. This is a historical achievement in a particular test, not a guarantee of equal performance for every program or a claim about the current world record. Such systems investigate complex processes.
A computer model represents selected properties of materials, climate or another subject. Its result depends on input data, equations and approximations. Observations and experiments test the model. Incorrect assumptions do not become correct because the calculation is fast or presented as an attractive coloured image.
20. Saving, backups and mistakes
Saving writes current work to a file. A backup provides a separate recovery path if the original is lost. The model backs up version 1, edits the original into version 2 and deletes it. Only version 1 can be restored; changes made after copying are absent.
A backup should be sufficiently independent, updated and tested through restoration. Two folders on one damaged drive can be lost together. Synchronisation is useful but can propagate deletion to every device; version recovery depends on the system. Choose a backup plan according to the loss it must protect against.
Common mistakes include confusing RAM with storage, treating instruction fetch as execution, expecting a turn to move the robot, counting 64 pixels as 64 bytes, and expecting a newer version from an older backup. Ask learners to predict a result before clicking and explain which state changed and why.
For teachers: begin with a familiar task, then contrast unsaved and saved notes, and broken and working programs. History can be read separately. Understanding several actions is more useful than quickly clicking every button. Every model states its assumptions and does not replace observation of an actual device.
Glossary
- Data
- Represented information processed by a device.
- Algorithm
- A specified method for solving a problem through operations.
- Program
- Instructions expressed for a particular computing system.
- Processor
- The component that executes machine instructions.
- Register
- A small, fast processor workspace holding a value.
- RAM
- Memory for current work; ordinary RAM is volatile.
- Storage device
- A device for storing and retrieving data.
- Bit
- An information unit with two possible values.
- Byte
- Eight bits in this lesson and ordinary modern systems.
- Pixel
- An element of a raster image.
- Operating system
- Software managing resources and application interaction with devices.
- Debugging
- Finding and correcting causes of incorrect program behaviour.
- Backup
- A preserved version for recovery if the original is lost.
Sources
Checked on 10 October 2026. Experiment results apply to their stated learning assumptions. Photo authors and licences are listed at the end of the visual lesson.
- Babbage: the engines
- Lovelace: notes
- The 1843 notes
- Hollerith and punched cards
- The Turing archive
- ENIAC and its women programmers
- Manchester Baby, 1948
- Why Baby photographs need precise captions
- EDSAC and memory
- Computer timeline
- Apple II, 1977
- IBM PC, 1981
- The instruction cycle
- The ARM7 pipeline
- Memory and storage
- Memory glossary
- NAND and SSDs
- Operating systems
- Multitasking
- Frontier: the 2022 milestone
- Backing up data