BrightChamps Logo
Login
Creative Math Ideas Image
Live Math Learners Count Icon1124 Learners

Last updated on June 18th, 2025

Math Whiteboard Illustration

Random Variable

Professor Greenline Explaining Math Concepts

A random variable is a way to measure a random experiment's result by assigning numerical values to its outcome. In a probability experiment, assigning a precise number to each possible outcome helps in mathematical analysis and prediction. Random variables are classified into two categories since data can be either continuous or discrete. In this article, we will explore random variables and their properties.

Random Variable for Vietnamese Students
Professor Greenline from BrightChamps

What is a Random Variable?

A random variable is one that has an unknown value, or a function that assigns values to every experiment result. It is typically represented by letters and divided into two groups: continuous, which can have any value within a specified or continuous range, and discrete, which takes specific values. Random variables are crucial in probability and statistics, as they help in the quantification of uncertainty. Some key takeaways of a random variable are listed below: 
 

  • Either an unknown value or a function that assigns values or numbers to the results of an experiment are examples of random variables.

     
  • It is divided into two categories: continuous (covering any value within a range) and discrete (taking specified values).

     
  • In probability and statistics, random variables are most commonly used to quantify the results of random events.

     
  • The risk analysts employ random variables to determine the probability of unfavorable events. 
     

Struggling with Math?

Get 1:1 Coaching to Boost Grades Fast !

curious child
Professor Greenline from BrightChamps

What are the Types of Random Variables?

Based on the types of values they can have, random variables are divided into two categories: 
 

  • Discrete random variables 
  • Continuous random variables
Professor Greenline from BrightChamps

Discrete random variables

There is a finite number of possible values for a discrete random variable. In simple terms, we can say that a specific set of countable values characterizes a discrete random variable.


For a clearer insight, consider an experiment where a coin is tossed four times. The number of times the coin lands on heads is denoted as X.

Depending on how many heads appear, x can have any of the following values such as 0, 1, 2, 3, or 4. There are no other possible values for X.

The probability function associated with a discrete random variable is known as the probability mass function (PMF). If X is a discrete random variable and its PMF is P(xi).

Here, we have to keep in mind that each probability value (pi) lies between 0 and 1, i.e., 0 ≤ pi ≤ 1.
 

Also, the possible values of X are covered by the sum of all the probability values, which equals 1, i.e., ∑pi = 1.  
 

Professor Greenline from BrightChamps

Continuous random variables

Continuous random variables have an endless number of possible values and can take any value within a given range or interval. It can have an infinite number of possible values.

For better clarity, we can consider an experiment that measures the rainfall in a city over a year.

The possible result is a continuous figure since the amount can be 30 inches, 30.5 inches, 30.75 inches, or even 30.752 inches. It is clear that there are countless possible values.

Because of this, rainfall is a continuous random variable rather than a discrete variable. The corresponding probability function of continuous random variables is known as the probability density function (PDF).

If X is a continuous random variable, then the probability of X falling within an interval is P (x < X < x + dx) ≈ f(x)dx. 

The key characteristics of a probability density function (PDF) are:

For each value of x, the probability density function, (fx), always remains between 0 and 1. So, the probabilities are never negative or greater than 1 (0 ≤ f(x) ≤ 1). 

Additionally, over all possible values of X, ∫ f(x) dx = 1 since the total area under the curve of f(x) equals 1. 

The distribution’s PDF is referred to as P(X).  
 

Professor Greenline from BrightChamps

Real-life Applications of the random variable

In many real-life situations, we can use the random variable to predict the outcomes, analyze the data, and make well-informed decisions. Here are some of the real-life applications of the concept:

 

  • To predict the weather such as forecast the storms, rainfall, and temperature, weather forecasters employ the random variable. For instance, to measure the rainfall that happens tomorrow, let X represent the total rainfall.  X is a continuous random variable because of uncertainty and can take any amount within a range. 
     
  • Business and finance professionals use random variables to assess the prices in a stock market, check the profits of their companies, and understand the demands of the customers and clients. 

     
  • To examine the condition of a patient after receiving medication, doctors, and other medical professionals use random variables to study the spread of the disease and the duration of the recovery.

     
  • To forecast the outcome or results, sports analysts use random variables to examine players’ performance. 
     
Max Pointing Out Common Math Mistakes

Common Mistakes and How to Avoid Them on Random Variable

A random variable represents the numerical result of a random event. It provides a specific number for each possible outcome in a probability experiment. Understanding the concepts of random variables helps in making accurate predictions and avoiding errors during calculations. Here are some common mistakes and their helpful solutions that will enhance our mathematical and problem-solving skills. 
 

Mistake 1

Red Cross Icon Indicating Mistakes to Avoid in This Math Topic

Assuming any number is a random variable

Green Checkmark Icon Indicating Correct Solutions in This Math Topic

Remember that a random variable represents the potential outcomes of a random event, it is not a normal number. Sometimes students think of a random variable as a regular number. It changes based on chance.

For example, when flipping a coin twice, the number of heads might be either 0 or 1. It is represented as X. However, we won’t know the precise value of X until we flip the coin. This describes how X is dependent on chance.  
 

Mistake 2

Red Cross Icon Indicating Mistakes to Avoid in This Math Topic

Confusion between discrete and continuous random variable
 

Green Checkmark Icon Indicating Correct Solutions in This Math Topic

Keep in mind that discrete variables count things, they take specific and separate values. For example, if we count the number of apples in a basket, it can be 1, 2, or 3, but not 3.5. Also, the continuous variables measure things, they take any value within a range.


For instance, the amount of rainfall could be 30 inches, 30.5 inches, or 30.75 inches, including the decimals. Kids should understand that random variables can be discrete or continuous, and both of them are different. 
 

Mistake 3

Red Cross Icon Indicating Mistakes to Avoid in This Math Topic

 Ignoring that probabilities must add up to 1
 

Green Checkmark Icon Indicating Correct Solutions in This Math Topic

Students should check the sum of all probabilities equals 1 or 100%. If the sum is greater than or less than 1 or 100%, there is an error in the probability calculations.

For example, if the calculated probability is 102% or 98% then there is an error. 
 

Mistake 4

Red Cross Icon Indicating Mistakes to Avoid in This Math Topic

Thinking a random variable gives a fixed answer
 

Green Checkmark Icon Indicating Correct Solutions in This Math Topic

 Recognize that random variables define all possible outcomes and their probabilities, not a specific outcome. A random variable represents a range of possible results of an experiment.

 

For instance, if we flip a coin, we might hope for heads, but the probability is only 1/ 2.  We cannot be certain of the result. It might be heads or tails. 

Mistake 5

Red Cross Icon Indicating Mistakes to Avoid in This Math Topic

Confusing probability with expected value

Green Checkmark Icon Indicating Correct Solutions in This Math Topic

Kids should understand that the expected value is not the precise outcome of a single event, but rather the long-term average of numerous experiments. The expected value helps in understanding the trends in the long term. Some students think that expected value is the most likely outcome of an event or an experiment.    
 

arrow-right

Level Up with a Math Certification!

2X Faster Learning (Grades 1-12)

curious child
Max from BrightChamps Saying "Hey"

Solved Examples of the random variable

Ray, the Character from BrightChamps Explaining Math Concepts
Max, the Girl Character from BrightChamps

Problem 1

Sam has drawn a single card from a standard deck of 52. Let z be the values of the drawn card (Ace = 1, 2 to 10 = face value, Jack = 11, Queen = 12, King =13). Find P(Z = 10).

Ray, the Boy Character from BrightChamps Saying "Let’s Begin"

1 / 13

Explanation

A deck of 52 contains four 10s. These are the only cards that satisfy Z =10. Here, the total number of possible outcomes is 52, since Sam has drawn a single card from the deck.

Next, we can apply the probability formula: 

P (Z = 10) = Total number of favorable outcomes / Total number of possible outcomes

P (Z = 10) = 4 / 52 

P (Z = 10) = 1 / 13 

This means, there is a 1 in 13 chance that the card will be a 10. 
 

Max from BrightChamps Praising Clear Math Explanations
Max, the Girl Character from BrightChamps

Problem 2

A bus arrives every 5 to 15 minutes. Let T be the waiting time. Find P(T < 10) assuming a uniform distribution.

Ray, the Boy Character from BrightChamps Saying "Let’s Begin"

 0.5 or 50%
 

Explanation

For a uniform distribution between a = 5 and b = 15, the probability is calculated as:

    P (a ≤ T≤ b) = b - a / Range

Here, the range is 15 - 5 = 10

  P (5 ≤ T≤ 10) = 10 - 5 / 15 - 5 = 5 / 10 = 0.5

P (T < 10) = 0.5 or 50%

This means there is a 50% probability that the waiting time for the bus will be less than 10 minutes. 

Max from BrightChamps Praising Clear Math Explanations
Max, the Girl Character from BrightChamps

Problem 3

A fair coin is tossed 2 times. Let Y be the number of heads. Find P (Y = 1).

Ray, the Boy Character from BrightChamps Saying "Let’s Begin"

1 / 2 or 50%
 

Explanation

Here the possible outcomes are 4. 

So the random variable Y can take values 0, 1, or 2. 

Favorable outcomes for Y =1 (exactly 1 head appears). From the possible outcomes, the favorable cases where Y = 1 are:

HT (1 head, 1 tail)

TH (1 head, 1 tail)

There are 4 total outcomes, so the probability of each outcome is:

P (Each outcome) = 1 /4

P (Y =1) = P(HT)+ P(TH)

P (Y =1) = 1 / 4 + 1/ 4 = 2 / 4 = 1 / 2

P (Y =1) = 1 / 2 or 50%

The probability of getting exactly one head when tossing a fair coin twice is 1 / 2 or 50%.

Max from BrightChamps Praising Clear Math Explanations
Max, the Girl Character from BrightChamps

Problem 4

The heights of students in a school follow a normal distribution with a mean of 150 cm and a standard deviation of 10 cm. Find the probability that a randomly selected student is taller than 160 cm.

Ray, the Boy Character from BrightChamps Saying "Let’s Begin"

0.1587 or 15.87%
 

Explanation

We can use the Z-Score formula: 

Z = X - μ / σ

Here, X = 160 (desired height)

μ = 150 (mean)

σ = 10 (standard deviation)

Z = 160 - 150 / 10 = 10 / 10 = 1

From the z table, P (Z < 1) = 0.8413

The probability of being taller than 160 cm is:

P(X > 160) = 1 − P(X ≤ 160) 

P(X > 160) = 1 − 0.8413 = 0.1587 or 15.87%

The probability that a randomly selected student is taller than 160 cm is 0.1587 or 15.87%.
 

Max from BrightChamps Praising Clear Math Explanations
Max, the Girl Character from BrightChamps

Problem 5

A student takes a test with possible scores ( 30, 40, 50, 60), each equally likely. Find the expected test score.

Ray, the Boy Character from BrightChamps Saying "Let’s Begin"

The expected test score is 45.

Explanation

The possible test scores: 30, 40, 50, 60 

Each score has probability P(X = x) 

P(X = 10) =  P(X = 30) = P(X = 40) = P(X = 50) = P(X = 60) = 1 / 4

The formula for calculating the expected mean is:

E [X] = ∑ xi P (X = xi)

E [X] = (30 × 1 / 4) +  (40 × 1 / 4) + (50 × 1 / 4) + (60 × 1 / 4) 

E [X] = 30 / 4 + 40 / 4 + 50 / 4 + 60 / 4

E [X] = 7.5 + 10 + 12.5 + 15 

E [X] = 45
 
Hence, the expected test score is 45.
 

Max from BrightChamps Praising Clear Math Explanations

Turn your child into a math star!

#1 Math Hack Schools Won't Teach!

curious child
Ray Thinking Deeply About Math Problems

FAQs on Random Variable

1.What do you mean by random variable?

Math FAQ Answers Dropdown Arrow

2.What distinguishes a continuous variable from a discrete variable?

Math FAQ Answers Dropdown Arrow

3.Give two examples of a continuous variable.

Math FAQ Answers Dropdown Arrow

4.What is the probability distribution function (PDF)?

Math FAQ Answers Dropdown Arrow

Struggling with Math?

Get 1:1 Coaching to Boost Grades Fast !

curious child
INDONESIA - Axa Tower 45th floor, JL prof. Dr Satrio Kav. 18, Kel. Karet Kuningan, Kec. Setiabudi, Kota Adm. Jakarta Selatan, Prov. DKI Jakarta
INDIA - H.No. 8-2-699/1, SyNo. 346, Rd No. 12, Banjara Hills, Hyderabad, Telangana - 500034
SINGAPORE - 60 Paya Lebar Road #05-16, Paya Lebar Square, Singapore (409051)
USA - 251, Little Falls Drive, Wilmington, Delaware 19808
VIETNAM (Office 1) - Hung Vuong Building, 670 Ba Thang Hai, ward 14, district 10, Ho Chi Minh City
VIETNAM (Office 2) - 143 Nguyễn Thị Thập, Khu đô thị Him Lam, Quận 7, Thành phố Hồ Chí Minh 700000, Vietnam
Dubai - BrightChamps, 8W building 5th Floor, DAFZ, Dubai, United Arab Emirates
UK - Ground floor, Redwood House, Brotherswood Court, Almondsbury Business Park, Bristol, BS32 4QW, United Kingdom