1. Random Variable

Definition — Random Variable

A random variable (RV) is a function that assigns a real number to each outcome in the sample space .
Capital letters () denote the variable; lower-case () denotes one of its values.

Definition — Discrete vs. Continuous RV

  • Discrete: takes a finite or countably infinite set of values (counts).
  • Continuous: takes values on an interval of real numbers (measurements).

Example. Toss a coin 3 times; = number of heads.

OutcomeHHHHHTHTHTHHHTTTHTTTHTTT
32221110

Definition — Bernoulli RV

An RV taking only values 0 and 1 (failure/success).


2. Discrete Probability Distributions

Definition — Probability Mass Function (pmf)

is a pmf of a discrete RV if, for every possible :

Definition — Cumulative Distribution Function (discrete)


For a discrete RV, is a step function, jumping by at each possible value.

Worked Example — Three Coin Tosses

From the table above: .

pmf of X = # heads in 3 tosses (shaded: P(1 ≤ X ≤ 2) = 3/4) 0.125 0.375 0.375 0.125 0 1 2 3

.

Theorem — Getting the pmf Back from the CDF

For integer-valued : .

⚠️ With discrete RVs the endpoints matter: . Here .


3. Continuous Probability Distributions

Definition — Probability Density Function (pdf)

is a pdf of a continuous RV if:

  1. for all
  2. (area under the curve)

Theorem — Single Points Have Zero Probability

For a continuous RV, , hence

⚠️ is a density, not a probability: it may exceed 1 (e.g. uniform on has ). Only areas are probabilities.


4. Probability Density Function — Worked Example

Let for , and elsewhere.

Step 1 — find .

Step 2 — a probability.

f(x) = ¾x(2−x); shaded area P(0.5 < X < 1.5) = 0.6875 0.6875 0 0.5 1 1.5 2

5. Cumulative Distribution Function (continuous)

Definition — CDF of a Continuous RV

Theorem — Properties of

  1. is non-decreasing, ,
  2. wherever the derivative exists (Fundamental Theorem of Calculus)

Worked Example — CDF of the Example pdf

For :

so

Check: ✓. Also , so is the median (the pdf is symmetric about 1).

Comparison Table

DiscreteContinuous
Describes probabilities bypmf pdf (density)
Total
, may be always
CDF shapestep functioncontinuous curve
From CDF to

⚠️ When computing piecewise, always state all three pieces (below, inside, above the support).