Foundations · 3:36
Sample Spaces & Events
Learn to describe randomness through experiments, outcomes, sample spaces, and events.
- A random experiment is a process whose result cannot be predicted for certain.
- The sample space (denoted omega) is the set of all possible outcomes of an experiment.
- Two events that cannot occur together are called mutually exclusive.
| Term | Definition | Example |
|---|---|---|
| Sample space | Set of all possible outcomes | Coin: {heads, tails} |
| Event | Any subset of a sample space | Die roll even: {2, 4, 6} |
| Union | A OR B happens | Even OR >3: {2,4,5,6} |
| Intersection | A AND B happen | Even AND >3: {4,6} |
| Complement | A does NOT happen | Not even: {1,3,5} |
Do this in your own tools, step by step. Ticks are saved on this device.
What is a sample space?
The set of all possible outcomes of an experiment.
When are two events mutually exclusive?
When they cannot happen together.
00:00 Welcome. In this course, we build probability and statistics from first principles for data science, machine learning, and AI. You only need basic arithmetic. Every idea starts as a picture, then becomes notation, and then we see where it is used in real models. Why probability? Because data is noisy and the world is uncertain. A model
00:24 never knows the answer for sure. It says, "This email is spam with probability 92%." Probability is the language of uncertainty and statistics is how we learn from data. It is everywhere in machine learning. A classifier outputs probabilities. Training finds the parameters that make the data most likely. A language model predicts the probability of the next
00:46 word. And AB tests decide which product change really works. Here is the road map. We start with the basics: events, rules, conditional probability, and Bayes' theorem. Then random variables, expectation, and the famous distributions. Then joint distributions, the central limit theorem, and the multivariate normal. Next comes statistics. Estimation,
01:11 maximum likelihood, confidence intervals, and hypothesis tests. We finish with Bayesian inference, entropy, and the big picture of probability in AI. Every chapter has a worked example with real numbers. Let us begin. Chapter 1: randomness, sample spaces, and events. Before we can measure uncertainty, we need to describe what can happen.
01:34 A random experiment is any process whose result we cannot predict for sure. Flipping a coin, rolling a die, or showing an ad to a user and seeing if they click. Each run of the experiment gives one outcome. The set of all possible outcomes is called the sample space, written with the Greek letter omega. For a coin, omega is heads and tails. For a die, it
01:58 is 1 2 3 4 5 and 6. For two coins, it is four outcomes. Heads heads, heads tails, tails heads, and tails tails. An event is any collection of outcomes, a subset of the sample space. Rolling an even number is the event 2 4 6. We say the event happens if the outcome lands inside it.
02:20 Events combine like sets. A union B means A or B happens. A intersection B means both happen. And the complement of A, written A with a small C, means A does not happen. If two events cannot happen together, they are called mutually exclusive. Let us work one out. Roll a die. Let A be rolling an even number, 2 4 6. Let B be rolling more than 3, 4 5 6.
02:47 Then A union B is 2 4 5 6. A intersection B is 4 and 6. The complement of A is 1 3 5. Because every outcome of a fair die is equally likely, the probability of A is three out of six, 1/2, and the probability of A and B together is two out of six, 1/3. In data science, every prediction
03:11 problem has a sample space. For spam filtering, it is spam or not spam. For digit recognition, it is the 10 digits. For a language model, the sample space is every word in its vocabulary. Defining it clearly is the first step of any model. Key idea. The sample space lists everything that can happen, and an event is a subset of it. Events combine with or, and, and not.
Get the other 14 chapters, the exam and your certificate for LinkedIn, plus all 700+ AI courses.