4.9.7 · D1Probability Theory & Statistics

Foundations — Continuous random variables — PDF, CDF, percentiles

2,373 words11 min readBack to topic

This page assumes you have seen none of the notation in the parent note. We build each symbol from scratch, in the order they depend on each other, so that when you meet you already own every piece of it.


0. What is a "random variable" at all?

The capital-vs-lowercase difference is a habit worth keeping: is the machine, is one output you point at. When we write we mean "the chance that the machine's output lands at or below the particular number ."

Two flavours exist:

  • Discrete — lands on separate dots (). See Discrete random variables — PMF.
  • Continuous — can land anywhere in a range (a person's exact height, cm). This whole topic is about the continuous flavour.

1. The symbol — "the probability that…"

Inside the brackets goes a statement about :

  • = chance the output is at most .
  • = chance the output lands between and .

The symbol means "less than or equal to"; means "strictly less than." Hold that distinction — for continuous variables it will stop mattering, and we will prove why in D2, but you must know the two symbols apart first.


2. Area under a curve, and why we need

Here is the leap from discrete to continuous. For dots, you add the chances of each dot. For a continuous range there are infinitely many values crammed together, so adding one-by-one is hopeless. Instead we measure area.

Why this tool and not a plain sum ? A sum adds a countable list of separate items — perfect for dots. But a continuous range has no "next" value to step to; between any two numbers lies another. The integral is the one tool built to total up a smooth, gap-free quantity. That is precisely why continuous probability lives on integrals and discrete probability lives on sums.


3. Density — the height of the curve

The critical warning, stated now so it never surprises you:

The mass-density analogy makes this concrete:


4. The two rules that make a probability density

Because area is probability and total probability is , two rules fall out immediately:

The symbols and ("negative infinity", "positive infinity") mean "sweep across all real numbers, from the far left to the far right." We use them because could in principle be any real number; the curve is simply wherever can't land.


5. The symbol — running total from the left

Now we accumulate. Instead of asking about a single strip, ask: "how much area have I collected sweeping from the far left up to the point ?"

Two notational points that trip beginners:

  • Why the dummy letter inside? The upper limit of the integral is already called . We cannot reuse as the sweeping variable too, or the symbol would mean two things at once. So we sweep with a throwaway name ; it disappears after integrating. and are the same thing.
  • Why capital ? Convention: lowercase = the small local density; uppercase = the big accumulated total. "Small letter, small idea (thickness here); big letter, big idea (everything so far)."

From the picture you can read off every property of :

  • At the far left, no area collected yet: .
  • At the far right, all area collected: .
  • Sweeping rightward only adds area (since ), so never goes down — it is non-decreasing.

You now have two curves for the same variable: the density and its running-total . They are two sides of one coin, connected by the Fundamental Theorem of Calculus.

The new symbol (or ) is the derivative — it measures the slope / rate of change of .


7. The inverse — asking "where?" instead of "how much?"

A percentile flips the question. Normally we hand a value and it returns a probability . A percentile hands over a probability and asks: which produced it?

Why is guaranteed to exist here? Only functions that never repeat a value can be inverted. Because is strictly increasing wherever , each probability corresponds to exactly one — no ambiguity. That is what makes "the 90th percentile" a single well-defined number. More on using to generate random numbers lives in Quantile function and inverse-transform sampling.


8. Symbols you'll meet in the worked examples

The parent note's examples borrow a few more pieces. Grab them now so nothing is new later.

Other everyday shorthand you'll see: (square root, undoes squaring), (evaluate an expression at the top limit minus the bottom limit — this is the "plug in and subtract" step of every integral).


Prerequisite map

Random variable X

Probability P between 0 and 1

Sum for dots

Integral = area for ranges

Derivative = slope

Inverse function undoes

exp and log undo each other

Density f x

Cumulative F x

Percentile x p

Continuous RVs PDF CDF Percentiles


Equipment checklist

Test yourself — cover the right side of each line.

What does a capital mean vs a lowercase ?
is the random output (the machine); is one specific value you plug in.
What does ask?
The probability the output lands between and \int\sum\int_a^b f(x),dxfx=ax=bf(x)\timesff(x)\ge 0\int_{-\infty}^{\infty} f(x),dx = 1fxf(x)>0f=0F(x)fxP(X \le x)t\int_{-\infty}^{x} f(t),dtxfFf(x)=F'(x)F^{-1}(p)xF(x)=pF-1Ff>0Fpx\lne^{(\cdot)}xe^{-2x}=0.1$.

Connections

  • Discrete random variables — PMF (the dots-and-sums cousin of this whole page)
  • Fundamental Theorem of Calculus (the engine behind and )
  • Exponential distribution (where and show up)
  • Uniform distribution (the simplest constant-density example to test these ideas on)
  • Quantile function and inverse-transform sampling (using in earnest)
  • Expectation and Variance of continuous RVs (next tools built on this same )
  • Normal distribution (its CDF is a percentile machine)