In simple terms
A friendly intro before the formal notes — no formulas yet.
Teaching a Computer to Think
Artificial Intelligence is about making computers perform tasks that normally require human intelligence, like learning from experience or understanding language. We achieve this through methods like rule-based expert systems and data-driven machine learning.
Think of AI like training a pet. You can give it very specific, direct commands like 'sit' or 'stay', which is similar to how a rule-based expert system works. Alternatively, you can show it lots of examples of good and bad behaviour over time, letting it figure out the patterns for itself, which is how machine learning works. The goal in both cases is for it to make the right decision on its own.
- 1
Define AI as the simulation of human intelligence in machines, enabling them to learn, reason, and problem-solve.
- 2
Explore expert systems, which are rule-based programs that mimic a human expert's decision-making in a specific, narrow domain.
- 3
Differentiate between the main types of machine learning: supervised (using labelled data), unsupervised (finding patterns in unlabelled data), and reinforcement (learning via rewards and penalties).
- 4
Grasp the basics of deep learning, where layered neural networks, inspired by the human brain, learn complex patterns from vast amounts of data.
Explore the concept
Use the live diagram and synced steps — play it or tap a step card to walk through.
2 more simulations for this topic — run them in the Simulations section below
Simulations
Every simulation here runs the real model — try the steps on a card, then check what you see against the notes.
2 simulations
- GeoGebra9618 18.1
Fit a line to data (regression)
A scatter of points and a red line you move by its two end points. Your SSE (total squared error) updates against a Target SSE. Randomize Data resets.
Try this
- Drag the two red points to tilt and shift the line until Your SSE is as close to Target SSE as you can get.
- Tick Show Regression Line to compare your line with the best fit.
- Press Randomize Data and repeat: the method is the same whatever the data.
Look for Supervised learning in miniature: labelled examples go in, the model (here a straight line) is adjusted until its error on them is as small as possible, and then it can predict values it has not seen.
GeoGebra Institute of Southern Connecticut · GeoGebra · GeoGebra Terms of Service
- GeoGebra9618 18.1
Gradient descent stepper
A point sits on the curve of an error function. Step moves it once and Run keeps going; Error and Iterations update, and you can type a Learning Rate.
Try this
- Press Step several times and watch Error fall as Iterations rises.
- Type a larger Learning Rate such as 0.1 and press Step again: each move is bigger.
- Press Run and note where the point settles.
Look for This is how a neural network is trained: back propagation measures how wrong the output is and nudges each weight a little in the direction that reduces the error, repeated over many iterations.
DESTROYER3 · GeoGebra · GeoGebra Terms of Service
Full topic notes
Formal explanation with the rigour you need for the exam.
Defining Artificial Intelligence
Artificial Intelligence (AI) is a broad branch of computer science concerned with building smart machines capable of performing tasks that typically require human intelligence. The goal is to simulate cognitive functions like learning, problem-solving, and reasoning. A classic, though now somewhat dated, concept is the Turing Test, which proposes that a machine can be considered 'intelligent' if its conversational responses cannot be distinguished from a human's. For the 9618 syllabus, we focus on 'Narrow AI' (or 'Weak AI'), which is designed to perform a specific task, such as playing chess or recognising faces, rather than possessing general human-like consciousness ('Strong AI').
Expert Systems: The Digital Specialist
An expert system is a classic example of AI. It's a computer program designed to act as a consultant or expert in a very specific and limited domain, like diagnosing a fault in a car engine or identifying a rare plant. Unlike a human, it can't reason outside its programmed domain, but within it, it can provide consistent and logical advice based on the information it's given.
Knowledge Base: This is a database containing facts and a rule base. The rule base consists of IF-THEN rules provided by human experts (e.g., 'IF the engine will not crank AND the lights are dim THEN the battery is likely flat').
Inference Engine: This is the processing component. It takes a user's query and the facts from the knowledge base, then applies the rules to infer new facts and reach a conclusion. It often uses methods like forward chaining (starting from facts to reach a goal) or backward chaining (starting from a hypothesis and working backwards).
User Interface: This allows a non-expert user to query the system and receive its recommendations. It might ask the user a series of questions to gather the necessary facts.
Explanation System: A crucial component that can explain the reasoning behind its conclusion, showing the user which rules were triggered to build trust and allow for verification.
Machine Learning: Learning from Data
Machine Learning (ML) is a powerful subset of AI where, instead of being explicitly programmed with rules, a system 'learns' from data. An ML model is trained on a large dataset to find patterns or make predictions. This approach is highly effective for problems where the rules are too complex or numerous for a human to define, such as in image recognition or stock market prediction.
Supervised Learning: The algorithm is trained on a 'labelled' dataset, where each piece of input data is tagged with the correct output. The goal is to learn a function that maps inputs to outputs. For example, training a model with thousands of emails labelled as 'spam' or 'not spam' to create a spam filter.
Unsupervised Learning: The algorithm is given 'unlabelled' data and must find its own structure. This is often used for clustering or grouping data. For example, a retail company might use it to segment customers into different groups based on purchasing behaviour, without any predefined group labels.
Reinforcement Learning: An 'agent' learns by interacting with an environment. It receives positive rewards for desired actions and negative penalties for undesired ones. Over many trials, the agent learns a 'policy' (a strategy) to maximise its cumulative reward. This is the method used to train AIs to play complex games like Go or chess.
For your exam, you must be able to clearly distinguish between expert systems and machine learning. The key difference is the source of the 'knowledge': expert systems use explicitly programmed rules from humans, while machine learning models derive their own rules or patterns from data.
Deep Learning and Neural Networks
Deep Learning is a specialised subfield of machine learning that uses Artificial Neural Networks (ANNs) with many layers. These networks are inspired by the interconnected structure of neurons in the human brain. A 'deep' neural network has multiple hidden layers between its input and output layers, allowing it to learn hierarchical patterns of increasing complexity. For example, in image recognition, the first layer might learn to recognise edges, the next to recognise shapes like eyes and noses, and a deeper layer to recognise a complete face.
Structure: A neural network consists of an Input Layer (receives the raw data), one or more Hidden Layers (perform computations), and an Output Layer (produces the final result).
Neurons and Weights: Each node, or 'neuron', receives inputs from the previous layer. Each input connection has a 'weight' which determines its importance. The neuron sums these weighted inputs and applies an 'activation function' to produce its output.
Training: The network learns by adjusting these weights. During training, it makes a prediction, compares it to the correct output, calculates the error, and then propagates this error backwards through the network to slightly adjust the weights in a way that reduces the error on the next attempt. This process is called backpropagation.
Worked examples
See the formulas applied — reveal one step at a time, like the exam.
A simple medical expert system has the following rules: R1: IF has_fever AND has_rash THEN has_measles R2: IF has_fever AND has_sore_throat THEN has_tonsillitis R3: IF has_tonsillitis THEN treatment_is_antibiotics
A user provides the facts: and . Using forward chaining, show how the inference engine determines the treatment.
- 1
Initial Facts: The system starts with two known facts: is TRUE and is TRUE. [1 mark]
A bank wants to create a system to automatically approve or deny loan applications. They have historical data from 100,000 previous applications, including each applicant's income, credit score, loan amount, and whether the loan was successfully repaid or defaulted.
(a) Which type of machine learning is most suitable for this task? Justify your answer. [2 marks] (b) Describe one input feature and the corresponding output label for a single record in the training data. [2 marks]
- 1
(a) Type: Supervised Learning. [1 mark] Justification: The historical data is 'labelled' because the outcome (repaid or defaulted) for each application is known. The system can be trained to learn the relationship between the input features (income, credit score) and the binary output (approve/deny, based on predicted risk of default). [1 mark]
How it all connects
The big idea sits in the middle — tap a linked idea to explore the link.
Tap a linked idea to see how it connects back to the main topic — that connection is what examiners reward.
Glossary
Key terms for this topic — skim now; the Check step will test them.
- Artificial Intelligence (AI)
The theory and development of computer systems able to perform tasks that normally require human intelligence, such as visual perception, speech recognition, decision-making, and translation between languages.
- Expert System
A computer system that emulates the decision-making ability of a human expert in a narrow, specific domain. It uses a knowledge base of facts and rules.
- Knowledge Base
A component of an expert system containing the facts and the rule base (IF-THEN rules) for a specific knowledge domain.
- Inference Engine
The 'brain' of an expert system. It applies logical rules from the knowledge base to the facts of a case to deduce new information and arrive at a conclusion.
- Machine Learning (ML)
A subset of AI where algorithms are trained on data to learn patterns and make predictions or decisions, without being explicitly programmed for the task.
- Supervised Learning
A type of machine learning where the algorithm learns from a dataset that has been manually labelled with the correct outputs. It learns a mapping from input to output.
- Unsupervised Learning
A type of machine learning where the algorithm learns from an unlabelled dataset, identifying hidden patterns or structures within the data on its own (e.g., clustering).
- Reinforcement Learning
A type of machine learning where an 'agent' learns to behave in an environment by performing actions and seeing the results (rewards or penalties).
- Artificial Neural Network (ANN)
A computational model inspired by the structure and function of biological neural networks in the brain. It consists of interconnected nodes (neurons) in layers.
- Deep Learning
A subfield of machine learning based on artificial neural networks with many layers (deep neural networks). It is particularly effective for learning complex patterns from large datasets.
- Turing Test
A test of a machine's ability to exhibit intelligent behaviour equivalent to, or indistinguishable from, that of a human. A human evaluator judges natural language conversations between a human and a machine.
- Forward Chaining
An inference engine strategy that starts with the available data (facts) and uses inference rules to extract more data until a goal is reached.
Name it
Read the meaning, then pick which of this lesson’s terms it describes. Miss one and you see what your choice really means.
A computational model inspired by the structure and function of biological neural networks in the brain. It consists of interconnected nodes (neurons) in layers.
Quick check
Write your answer first, then compare it with the model one — the gap is what you would have lost.
Teach it back
If you can explain it simply, you own it — gaps here are marks you’d lose.
Teach it back
Explain this topic as if teaching a friend. We name the gaps an examiner would still dock.
Revision flashcards
Guess first, then flip — retrieval beats re-reading.
Key takeaways
Review these before you close the topic — retrieval beats re-reading.
Knowledge Base: This is a database containing facts and a rule base. The rule base consists of IF-THEN rules provided by human experts (e.g., 'IF the engine will not crank AND the lights are dim THEN the battery is likely flat').
Inference Engine: This is the processing component. It takes a user's query and the facts from the knowledge base, then applies the rules to infer new facts and reach a conclusion. It often uses methods like forward chaining (starting from facts to reach a goal) or backward chaining (starting from a hypothesis and working backwards).
User Interface: This allows a non-expert user to query the system and receive its recommendations. It might ask the user a series of questions to gather the necessary facts.
Explanation System: A crucial component that can explain the reasoning behind its conclusion, showing the user which rules were triggered to build trust and allow for verification.
Practice — then mark it
The whole point: a real Cambridge question, marked mark-by-mark.
Test Your Knowledge on AI Concepts
Test Your Knowledge on AI Concepts
Extra simulations & links
PhET, GeoGebra and other curated tools — open in a new tab.
Frequently asked
Checkpoint
One marked question is worth ten re-reads — close the loop before you move on.
Reading it isn’t knowing it — prove it.
Before you move on: do Test Your Knowledge on AI Concepts on paper, snap a photo, and get examiner-style feedback on exactly where you win and lose marks.
Discuss Artificial Intelligence (AI)
Ask, share and discuss with other Computer Science students