Skip to main content

Exponential Distribution and Continuous Random Variables

Exponential Distribution and Continuous Random Variables

The exponential distribution models the time between events in a Poisson process, while the theory of continuous random variables extends probability to quantities that can take any value in an interval.

Board Coverage

BoardPaperNotes
AQAPaper 2Continuous RVs; limited exponential coverage
EdexcelS3, S4Exponential distribution in S4; continuous RVs in S3
OCR (A)Paper 2Continuous RVs and exponential
CIE (9231)S2Both continuous RVs and exponential covered
The exponential distribution is the continuous counterpart to the geometric distribution.

Both are memoryless. The Poisson process links all three distributions: Poisson counts events, exponential measures inter-arrival times, and geometric counts trials until the first event. :::


1. Continuous Random Variables

1.1 Probability density function

Definition. A probability density function (PDF) f(x)f(x) of a continuous random variable XX is a non-negative function satisfying:

f(x)0forallx,f(x)dx=1f(x) \geq 0 \quad \mathrm{for all } x, \qquad \int_{-\infty}^{\infty}f(x)\,dx = 1

Probabilities are found by integration:

P(aXb)=abf(x)dxP(a \leq X \leq b) = \int_a^b f(x)\,dx

For a continuous random variable, P(X=a)=0P(X = a) = 0 for any single value aa. This is why

P(aXb)=P(a<X<b)P(a \leq X \leq b) = P(a < X < b) — the inequalities at individual points do not matter. :::

1.2 Cumulative distribution function

Definition. The cumulative distribution function (CDF) is

F(x)=P(Xx)=xf(t)dtF(x) = P(X \leq x) = \int_{-\infty}^{x}f(t)\,dt

Properties:

  • F()=0F(-\infty) = 0, F()=1F(\infty) = 1
  • FF is non-decreasing
  • f(x)=F(x)f(x) = F'(x) where FF is differentiable
  • P(a<Xb)=F(b)F(a)P(a < X \leq b) = F(b) - F(a)

1.3 Expected value

Definition. The expected value of a continuous random variable XX is

E(X)=xf(x)dx\boxed{E(X) = \int_{-\infty}^{\infty}x\,f(x)\,dx}

For a function g(X)g(X):

E(g(X))=g(x)f(x)dxE(g(X)) = \int_{-\infty}^{\infty}g(x)\,f(x)\,dx

1.4 Variance

Definition.

Var(X)=E(X2)[E(X)]2=x2f(x)dx(xf(x)dx)2\boxed{\mathrm{Var}(X) = E(X^2) - [E(X)]^2 = \int_{-\infty}^{\infty}x^2\,f(x)\,dx - \left(\int_{-\infty}^{\infty}x\,f(x)\,dx\right)^2}

The linear properties carry over from the discrete case:

E(aX+b)=aE(X)+b,Var(aX+b)=a2Var(X)E(aX + b) = aE(X) + b, \qquad \mathrm{Var}(aX + b) = a^2\,\mathrm{Var}(X)

1.5 Median, mode, and quartiles

Definition. The median mm satisfies F(m)=0.5F(m) = 0.5, i.e., mf(x)dx=0.5\int_{-\infty}^{m}f(x)\,dx = 0.5.

Definition. The mode is the value of xx at which f(x)f(x) is maximised.

Definition. The lower quartile Q1Q_1 satisfies F(Q1)=0.25F(Q_1) = 0.25 and the upper quartile Q3Q_3 satisfies F(Q3)=0.75F(Q_3) = 0.75.

The interquartile range is IQR=Q3Q1\mathrm{IQR} = Q_3 - Q_1.


2. The Exponential Distribution

2.1 Definition

Definition. A continuous random variable XX follows an exponential distribution with rate parameter λ\lambda (where λ>0\lambda > 0), written XExp(λ)X \sim \mathrm{Exp}(\lambda), if

f(x)=λeλx,x0\boxed{f(x) = \lambda e^{-\lambda x}, \quad x \geq 0}

and f(x)=0f(x) = 0 for x<0x < 0.

2.2 Cumulative distribution function

F(x)=P(Xx)=0xλeλtdt=[eλt]0x=1eλxF(x) = P(X \leq x) = \int_0^x \lambda e^{-\lambda t}\,dt = \left[-e^{-\lambda t}\right]_0^x = 1 - e^{-\lambda x}

F(x)=1eλx,x0\boxed{F(x) = 1 - e^{-\lambda x}, \quad x \geq 0}

2.3 Proof that E(X)=LB1RB◆◆LBλRBE(X) = \frac◆LB◆1◆RB◆◆LB◆\lambda◆RB◆

Proof

E(X)=0xλeλxdx\begin{aligned} E(X) &= \int_0^{\infty}x\cdot\lambda e^{-\lambda x}\,dx \end{aligned}

Using integration by parts with u=xu = x, dv=λeλxdxdv = \lambda e^{-\lambda x}\,dx:

du=dxdu = dx, v=eλxv = -e^{-\lambda x}.

E(X)=[xeλx]0+0eλxdx=limx(xeλx)+0+[LB1RB◆◆LBλRBeλx]0=0+LB1RB◆◆LBλRB=LB1RB◆◆LBλRB\begin{aligned} E(X) &= \left[-xe^{-\lambda x}\right]_0^{\infty} + \int_0^{\infty}e^{-\lambda x}\,dx \\ &= \lim_{x\to\infty}(-xe^{-\lambda x}) + 0 + \left[-\frac◆LB◆1◆RB◆◆LB◆\lambda◆RB◆e^{-\lambda x}\right]_0^{\infty} \\ &= 0 + \frac◆LB◆1◆RB◆◆LB◆\lambda◆RB◆ = \frac◆LB◆1◆RB◆◆LB◆\lambda◆RB◆ \quad \blacksquare \end{aligned}

Note: limxxeλx=0\lim_{x\to\infty}xe^{-\lambda x} = 0 by L'Hôpital's rule (exponential decay dominates).

2.4 Proof that Var(X)=LB1RB◆◆LBλ2RB\mathrm{Var}(X) = \frac◆LB◆1◆RB◆◆LB◆\lambda^2◆RB◆

Proof

First compute E(X2)E(X^2):

E(X2)=0x2λeλxdxE(X^2) = \int_0^{\infty}x^2\cdot\lambda e^{-\lambda x}\,dx

Integration by parts twice with u=x2u = x^2, dv=λeλxdxdv = \lambda e^{-\lambda x}\,dx:

du=2xdxdu = 2x\,dx, v=eλxv = -e^{-\lambda x}.

E(X2)=[x2eλx]0+02xeλxdx=0+2LB1RB◆◆LBλRBE(X)=LB2RB◆◆LBλRBLB1RB◆◆LBλRB=LB2RB◆◆LBλ2RB\begin{aligned} E(X^2) &= \left[-x^2 e^{-\lambda x}\right]_0^{\infty} + \int_0^{\infty}2x\,e^{-\lambda x}\,dx \\ &= 0 + 2\cdot\frac◆LB◆1◆RB◆◆LB◆\lambda◆RB◆\cdot E(X) = \frac◆LB◆2◆RB◆◆LB◆\lambda◆RB◆\cdot\frac◆LB◆1◆RB◆◆LB◆\lambda◆RB◆ = \frac◆LB◆2◆RB◆◆LB◆\lambda^2◆RB◆ \end{aligned}

Var(X)=E(X2)[E(X)]2=LB2RB◆◆LBλ2RBLB1RB◆◆LBλ2RB=LB1RB◆◆LBλ2RB\mathrm{Var}(X) = E(X^2) - [E(X)]^2 = \frac◆LB◆2◆RB◆◆LB◆\lambda^2◆RB◆ - \frac◆LB◆1◆RB◆◆LB◆\lambda^2◆RB◆ = \frac◆LB◆1◆RB◆◆LB◆\lambda^2◆RB◆ \quad \blacksquare

E(X)=LB1RB◆◆LBλRB,Var(X)=LB1RB◆◆LBλ2RB,σ=LB1RB◆◆LBλRB\boxed{E(X) = \frac◆LB◆1◆RB◆◆LB◆\lambda◆RB◆, \qquad \mathrm{Var}(X) = \frac◆LB◆1◆RB◆◆LB◆\lambda^2◆RB◆, \qquad \sigma = \frac◆LB◆1◆RB◆◆LB◆\lambda◆RB◆}

2.5 The memoryless property

Theorem. The exponential distribution is the only continuous memoryless distribution:

P(X>s+tX>s)=P(X>t)P(X > s + t \mid X > s) = P(X > t)

Proof

P(X>s+tX>s)=P(X>s+t)P(X>s)=LBeλ(s+t)RB◆◆LBeλsRB=eλt=P(X>t)\begin{aligned} P(X > s + t \mid X > s) &= \frac{P(X > s+t)}{P(X > s)} = \frac◆LB◆e^{-\lambda(s+t)}◆RB◆◆LB◆e^{-\lambda s}◆RB◆ \\ &= e^{-\lambda t} = P(X > t) \quad \blacksquare \end{aligned}

This uses P(X>x)=1F(x)=eλxP(X > x) = 1 - F(x) = e^{-\lambda x}.

The memoryless property has important practical implications. If a component with an

exponentially distributed lifetime has been working for ss hours, the remaining lifetime has the same distribution as a brand new component. This means exponential lifetimes imply no "wear out" effect — which is why it is more appropriate for electronic components than mechanical ones. :::

A Poisson process with rate λ\lambda satisfies:

  • The number of events in an interval of length tt follows Po(λt)\mathrm{Po}(\lambda t)
  • The time between consecutive events follows Exp(λ)\mathrm{Exp}(\lambda)
  • The inter-arrival times are independent and identically distributed

Proof sketch that inter-arrival times are exponential. Let TT be the time until the first event. P(T>t)=P(noeventsin[0,t])=P(N(t)=0)=LBeλt(λt)0RB◆◆LB0!RB=eλtP(T > t) = P(\mathrm{no events in }[0,t]) = P(N(t) = 0) = \dfrac◆LB◆e^{-\lambda t}(\lambda t)^0◆RB◆◆LB◆0!◆RB◆ = e^{-\lambda t}.

So P(Tt)=1eλtP(T \leq t) = 1 - e^{-\lambda t}, which is the CDF of Exp(λ)\mathrm{Exp}(\lambda). \blacksquare

2.7 Percentiles

For the exponential distribution:

F(x)=1eλx=p    x=LB1RB◆◆LBλRBln(1p)F(x) = 1 - e^{-\lambda x} = p \implies x = -\frac◆LB◆1◆RB◆◆LB◆\lambda◆RB◆\ln(1-p)

The median is x0.5=LBln(0.5)RB◆◆LBλRB=LBln2RB◆◆LBλRBx_{0.5} = -\dfrac◆LB◆\ln(0.5)◆RB◆◆LB◆\lambda◆RB◆ = \dfrac◆LB◆\ln 2◆RB◆◆LB◆\lambda◆RB◆.


3. Worked Examples

3.1 Finding probabilities

Example. XExp(0.5)X \sim \mathrm{Exp}(0.5). Find P(X>3)P(X > 3), P(1<X<4)P(1 < X < 4), and the median.

P(X>3)=e0.5×3=e1.50.2231P(X > 3) = e^{-0.5 \times 3} = e^{-1.5} \approx 0.2231.

P(1<X<4)=F(4)F(1)=(1e2)(1e0.5)=e0.5e20.60650.1353=0.4712P(1 < X < 4) = F(4) - F(1) = (1-e^{-2}) - (1-e^{-0.5}) = e^{-0.5} - e^{-2} \approx 0.6065 - 0.1353 = 0.4712.

Median =LBln2RB◆◆LB0.5RB=2ln21.386= \dfrac◆LB◆\ln 2◆RB◆◆LB◆0.5◆RB◆ = 2\ln 2 \approx 1.386.

3.2 Continuous random variable from a PDF

Example. XX has PDF f(x)=38x2f(x) = \dfrac{3}{8}x^2 for 0x20 \leq x \leq 2 and f(x)=0f(x) = 0 otherwise.

Verify: 0238x2dx=3883=1\int_0^2 \dfrac{3}{8}x^2\,dx = \dfrac{3}{8}\cdot\dfrac{8}{3} = 1. \checkmark

E(X)=02x38x2dx=3802x3dx=38164=32E(X) = \int_0^2 x\cdot\dfrac{3}{8}x^2\,dx = \dfrac{3}{8}\int_0^2 x^3\,dx = \dfrac{3}{8}\cdot\dfrac{16}{4} = \dfrac{3}{2}.

E(X2)=3802x4dx=38325=125E(X^2) = \dfrac{3}{8}\int_0^2 x^4\,dx = \dfrac{3}{8}\cdot\dfrac{32}{5} = \dfrac{12}{5}.

Var(X)=125(32)2=12594=320\mathrm{Var}(X) = \dfrac{12}{5} - \left(\dfrac{3}{2}\right)^2 = \dfrac{12}{5} - \dfrac{9}{4} = \dfrac{3}{20}.

Median: 0m38x2dx=0.5    m38=0.5    m3=4    m=431.587\int_0^m \dfrac{3}{8}x^2\,dx = 0.5 \implies \dfrac{m^3}{8} = 0.5 \implies m^3 = 4 \implies m = \sqrt[3]{4} \approx 1.587.

3.3 CDF from PDF

Example. f(x)=2xf(x) = 2x for 0x10 \leq x \leq 1. Find F(x)F(x).

For 0x10 \leq x \leq 1: F(x)=0x2tdt=x2F(x) = \int_0^x 2t\,dt = x^2.

For x<0x < 0: F(x)=0F(x) = 0. For x>1x > 1: F(x)=1F(x) = 1.


4. Hypothesis Testing with the Exponential Distribution

Example. The lifetime of a component is modelled by XExp(λ)X \sim \mathrm{Exp}(\lambda). A sample of 10 components gives a mean lifetime of 420 hours. Test at the 5% level whether λ=0.005\lambda = 0.005 against H1:λ0.005H_1: \lambda \neq 0.005.

Under H0H_0: E(X)=1/λ=200E(X) = 1/\lambda = 200 hours. Since nn is large, use the approximate normal distribution of Xˉ\bar{X}:

XˉN ⁣(LB1RB◆◆LBλRB,LB1RB◆◆LBnλ2RB)=N(200,4000)\bar{X} \sim N\!\left(\frac◆LB◆1◆RB◆◆LB◆\lambda◆RB◆, \frac◆LB◆1◆RB◆◆LB◆n\lambda^2◆RB◆\right) = N(200, 4000) approximately.

z=LB420200RB◆◆LB4000RB=22063.25=3.48z = \dfrac◆LB◆420 - 200◆RB◆◆LB◆\sqrt{4000}◆RB◆ = \dfrac{220}{63.25} = 3.48.

z=3.48>1.96|z| = 3.48 > 1.96, so reject H0H_0.


Problems

Details

Problem 1 XExp(2)X \sim \mathrm{Exp}(2). Find P(X>1)P(X > 1), P(0.5<X<2)P(0.5 < X < 2), and the 90th percentile.

Details

Solution 1 P(X>1)=e2(1)=e20.1353P(X > 1) = e^{-2(1)} = e^{-2} \approx 0.1353.

P(0.5<X<2)=(1e4)(1e1)=e1e40.36790.0183=0.3496P(0.5 < X < 2) = (1-e^{-4}) - (1-e^{-1}) = e^{-1} - e^{-4} \approx 0.3679 - 0.0183 = 0.3496.

90th percentile: F(x)=0.9    1e2x=0.9    x=LBln(0.1)RB◆◆LB2RB1.151F(x) = 0.9 \implies 1 - e^{-2x} = 0.9 \implies x = -\dfrac◆LB◆\ln(0.1)◆RB◆◆LB◆2◆RB◆ \approx 1.151.

If you get this wrong, revise: Percentiles — Section 2.7.

Details

Problem 2 A continuous random variable XX has PDF f(x)=3x28f(x) = \dfrac{3x^2}{8} for 0x20 \leq x \leq 2. Find E(X)E(X), Var(X)\mathrm{Var}(X), and the median.

Details

Solution 2 E(X)=02x3x28dx=38[x44]02=384=1.5E(X) = \int_0^2 x\cdot\dfrac{3x^2}{8}\,dx = \dfrac{3}{8}\cdot\left[\dfrac{x^4}{4}\right]_0^2 = \dfrac{3}{8}\cdot 4 = 1.5.

E(X2)=02x23x28dx=38[x55]02=38325=2.4E(X^2) = \int_0^2 x^2\cdot\dfrac{3x^2}{8}\,dx = \dfrac{3}{8}\cdot\left[\dfrac{x^5}{5}\right]_0^2 = \dfrac{3}{8}\cdot\dfrac{32}{5} = 2.4.

Var(X)=2.41.52=2.42.25=0.15\mathrm{Var}(X) = 2.4 - 1.5^2 = 2.4 - 2.25 = 0.15.

Median: 0m3x28dx=0.5    m38=0.5    m=431.587\int_0^m \dfrac{3x^2}{8}\,dx = 0.5 \implies \dfrac{m^3}{8} = 0.5 \implies m = \sqrt[3]{4} \approx 1.587.

If you get this wrong, revise: Median, mode, and quartiles — Section 1.5.

Details

Problem 3 Prove the memoryless property of the exponential distribution.

Details

Solution 3 P(X>s+tX>s)=P(X>s+t)P(X>s)=LBeλ(s+t)RB◆◆LBeλsRB=eλt=P(X>t)P(X > s+t \mid X > s) = \dfrac{P(X > s+t)}{P(X > s)} = \dfrac◆LB◆e^{-\lambda(s+t)}◆RB◆◆LB◆e^{-\lambda s}◆RB◆ = e^{-\lambda t} = P(X > t). \blacksquare

This uses the survival function P(X>x)=eλxP(X > x) = e^{-\lambda x}.

If you get this wrong, revise: The memoryless property — Section 2.5.

Details

Problem 4 Calls arrive at a switchboard as a Poisson process with rate λ=4\lambda = 4 per hour. Find the probability that the time between two consecutive calls exceeds 30 minutes.

Details

Solution 4 The inter-arrival time TExp(4)T \sim \mathrm{Exp}(4) (rate in hours).

P(T>0.5)=e4×0.5=e20.1353P(T > 0.5) = e^{-4 \times 0.5} = e^{-2} \approx 0.1353.

If you get this wrong, revise: Link to Poisson processes — Section 2.6.

Details

Problem 5 XX has PDF f(x)=12xf(x) = \dfrac{1}{2}x for 0x20 \leq x \leq 2. Find the CDF, E(X)E(X), and Var(X)\mathrm{Var}(X).

Details

Solution 5 CDF: F(x)=0xt2dt=x24F(x) = \int_0^x \dfrac{t}{2}\,dt = \dfrac{x^2}{4} for 0x20 \leq x \leq 2. F(x)=0F(x) = 0 for x<0x < 0, F(x)=1F(x) = 1 for x>2x > 2.

E(X)=02xx2dx=12[x33]02=43E(X) = \int_0^2 x\cdot\dfrac{x}{2}\,dx = \dfrac{1}{2}\left[\dfrac{x^3}{3}\right]_0^2 = \dfrac{4}{3}.

E(X2)=12[x44]02=124=2E(X^2) = \dfrac{1}{2}\left[\dfrac{x^4}{4}\right]_0^2 = \dfrac{1}{2}\cdot 4 = 2.

Var(X)=2(43)2=2169=29\mathrm{Var}(X) = 2 - \left(\dfrac{4}{3}\right)^2 = 2 - \dfrac{16}{9} = \dfrac{2}{9}.

If you get this wrong, revise: Expected value — Section 1.3.

Details

Problem 6 The lifetime of a light bulb follows XExp(0.01)X \sim \mathrm{Exp}(0.01) (in hours). Given that the bulb has been working for 500 hours, find the probability it lasts at least another 200 hours.

Details

Solution 6 By the memoryless property: P(X>500+200X>500)=P(X>200)=e0.01×200=e20.1353P(X > 500+200 \mid X > 500) = P(X > 200) = e^{-0.01 \times 200} = e^{-2} \approx 0.1353.

If you get this wrong, revise: The memoryless property — Section 2.5.

Details

Problem 7 A continuous random variable XX has CDF F(x)=x327F(x) = \dfrac{x^3}{27} for 0x30 \leq x \leq 3. Find the PDF, E(X)E(X), and the upper quartile.

Details

Solution 7 PDF: f(x)=F(x)=x29f(x) = F'(x) = \dfrac{x^2}{9} for 0x30 \leq x \leq 3.

E(X)=03xx29dx=19[x44]03=19814=94=2.25E(X) = \int_0^3 x\cdot\dfrac{x^2}{9}\,dx = \dfrac{1}{9}\left[\dfrac{x^4}{4}\right]_0^3 = \dfrac{1}{9}\cdot\dfrac{81}{4} = \dfrac{9}{4} = 2.25.

Upper quartile: F(Q3)=0.75    Q3327=0.75    Q33=20.25    Q32.725F(Q_3) = 0.75 \implies \dfrac{Q_3^3}{27} = 0.75 \implies Q_3^3 = 20.25 \implies Q_3 \approx 2.725.

If you get this wrong, revise: Cumulative distribution function — Section 1.2.

Details

Problem 8 Prove that E(X)=1/λE(X) = 1/\lambda for XExp(λ)X \sim \mathrm{Exp}(\lambda), using integration by parts.

Details

Solution 8 E(X)=0xλeλxdxE(X) = \int_0^{\infty}x\lambda e^{-\lambda x}\,dx.

Let u=xu = x, dv=λeλxdxdv = \lambda e^{-\lambda x}\,dx, so du=dxdu = dx, v=eλxv = -e^{-\lambda x}.

E(X)=[xeλx]0+0eλxdx=0+[LB1RB◆◆LBλRBeλx]0=LB1RB◆◆LBλRBE(X) = \left[-xe^{-\lambda x}\right]_0^{\infty} + \int_0^{\infty}e^{-\lambda x}\,dx = 0 + \left[-\dfrac◆LB◆1◆RB◆◆LB◆\lambda◆RB◆e^{-\lambda x}\right]_0^{\infty} = \dfrac◆LB◆1◆RB◆◆LB◆\lambda◆RB◆. \blacksquare

If you get this wrong, revise: Proof that E(X)=LB1RB◆◆LBλRBE(X) = \frac◆LB◆1◆RB◆◆LB◆\lambda◆RB◆ — Section 2.3.

Details

Problem 9 Buses arrive at a stop as a Poisson process with rate 6 per hour. Find the probability that a passenger waits between 5 and 15 minutes for a bus.

Details

Solution 9 Waiting time TExp(6)T \sim \mathrm{Exp}(6) (rate per hour).

P(1/12<T<1/4)=F(1/4)F(1/12)=(1e1.5)(1e0.5)=e0.5e1.5P(1/12 < T < 1/4) = F(1/4) - F(1/12) = (1-e^{-1.5}) - (1-e^{-0.5}) = e^{-0.5} - e^{-1.5}

0.60650.2231=0.3834\approx 0.6065 - 0.2231 = 0.3834.

If you get this wrong, revise: Link to Poisson processes — Section 2.6.

Details

Problem 10 XX has PDF f(x)=4x3f(x) = 4x^3 for 0x10 \leq x \leq 1. Find P(X>0.5)P(X > 0.5), E(X)E(X), Var(X)\mathrm{Var}(X), and the mode.

Details

Solution 10 P(X>0.5)=0.514x3dx=[x4]0.51=10.0625=0.9375P(X > 0.5) = \int_{0.5}^1 4x^3\,dx = \left[x^4\right]_{0.5}^1 = 1 - 0.0625 = 0.9375.

E(X)=014x4dx=[4x55]01=45E(X) = \int_0^1 4x^4\,dx = \left[\dfrac{4x^5}{5}\right]_0^1 = \dfrac{4}{5}.

E(X2)=014x5dx=[4x66]01=23E(X^2) = \int_0^1 4x^5\,dx = \left[\dfrac{4x^6}{6}\right]_0^1 = \dfrac{2}{3}.

Var(X)=23(45)2=231625=504875=275\mathrm{Var}(X) = \dfrac{2}{3} - \left(\dfrac{4}{5}\right)^2 = \dfrac{2}{3} - \dfrac{16}{25} = \dfrac{50 - 48}{75} = \dfrac{2}{75}.

Mode: f(x)=4x3f(x) = 4x^3 is increasing on [0,1][0,1], so the mode is at x=1x = 1.

If you get this wrong, revise: Median, mode, and quartiles — Section 1.5.


5. Memoryless Property: Detailed Proof and Interpretation

5.1 Rigorous proof using conditional probability

Theorem. If XExp(λ)X \sim \mathrm{Exp}(\lambda), then for all s,t>0s, t > 0:

P(X>s+tX>s)=P(X>t)P(X > s + t \mid X > s) = P(X > t)

Proof

By definition of conditional probability:

P(X>s+tX>s)=LBP(X>s+tX>s)RB◆◆LBP(X>s)RB=P(X>s+t)P(X>s)P(X > s + t \mid X > s) = \frac◆LB◆P(X > s + t \,\cap\, X > s)◆RB◆◆LB◆P(X > s)◆RB◆ = \frac{P(X > s + t)}{P(X > s)}

since X>s+tX > s + t implies X>sX > s.

Using the survival function S(x)=P(X>x)=eλxS(x) = P(X > x) = e^{-\lambda x}:

P(X>s+t)P(X>s)=LBeλ(s+t)RB◆◆LBeλsRB=eλt=P(X>t)\frac{P(X > s + t)}{P(X > s)} = \frac◆LB◆e^{-\lambda(s+t)}◆RB◆◆LB◆e^{-\lambda s}◆RB◆ = e^{-\lambda t} = P(X > t) \quad \blacksquare

5.2 Converse: exponential is the only continuous memoryless distribution

Theorem. If a continuous random variable XX on (0,)(0, \infty) satisfies P(X>s+tX>s)=P(X>t)P(X > s+t \mid X > s) = P(X > t) for all s,t>0s, t > 0, then XExp(λ)X \sim \mathrm{Exp}(\lambda) for some λ>0\lambda > 0.

Proof

Let G(t)=P(X>t)G(t) = P(X > t). The memoryless condition gives:

G(s+t)=G(s)G(t)G(s + t) = G(s)G(t)

This is Cauchy's functional equation. Since GG is non-increasing and 0G10 \leq G \leq 1, the only solutions are:

G(t)=eλtG(t) = e^{-\lambda t}

for some λ0\lambda \geq 0. Since GG is non-trivial (not identically 1), λ>0\lambda > 0. Therefore:

P(Xt)=1eλtP(X \leq t) = 1 - e^{-\lambda t}

which is the CDF of Exp(λ)\mathrm{Exp}(\lambda). \blacksquare

5.3 Practical interpretation

The memoryless property means:

  • If a light bulb has been on for 100 hours, the probability it lasts another 50 hours is the same as a new bulb lasting 50 hours.
  • If you have waited 20 minutes for a bus, your expected additional wait time is the same as if you had just arrived.
  • This property makes exponential models appropriate for random failure mechanisms (electronic components) but inappropriate for wear-out mechanisms (mechanical parts).

6. Poisson-Exponential Connection: Inter-Arrival Times

6.1 Derivation

Theorem. In a Poisson process with rate λ\lambda, the time between consecutive events follows Exp(λ)\mathrm{Exp}(\lambda).

Proof

Let TT be the time from an arbitrary starting point until the first event.

P(T>t)=P(noeventsin[0,t])P(T > t) = P(\mathrm{no events in }[0,t])

Since the number of events in [0,t][0,t] follows Po(λt)\mathrm{Po}(\lambda t):

P(N(t)=0)=LBeλt(λt)0RB◆◆LB0!RB=eλtP(N(t) = 0) = \frac◆LB◆e^{-\lambda t}(\lambda t)^0◆RB◆◆LB◆0!◆RB◆ = e^{-\lambda t}

Therefore P(Tt)=1eλtP(T \leq t) = 1 - e^{-\lambda t}, which is the CDF of Exp(λ)\mathrm{Exp}(\lambda). \blacksquare

6.2 Sum of inter-arrival times

If T1,T2,,TnT_1, T_2, \ldots, T_n are nn independent inter-arrival times, each Exp(λ)\sim \mathrm{Exp}(\lambda), then the total time until the nn-th event is:

Sn=T1+T2++TnGamma(n,λ)S_n = T_1 + T_2 + \cdots + T_n \sim \mathrm{Gamma}(n, \lambda)

This connects the exponential to the gamma distribution.

6.3 Worked example: call centre

Example. Calls arrive at a call centre as a Poisson process at rate 5 per hour.

(a) Find the probability that the time between two consecutive calls exceeds 20 minutes.

TExp(5)T \sim \mathrm{Exp}(5) (rate per hour). P(T>1/3)=e5/30.1889P(T > 1/3) = e^{-5/3} \approx 0.1889.

(b) Find the probability that at least 3 calls arrive in the next 30 minutes.

N(0.5)Po(2.5)N(0.5) \sim \mathrm{Po}(2.5). P(N3)=1P(N2)=1e2.5(1+2.5+2.52/2)=10.0821×9.12510.749=0.251P(N \geq 3) = 1 - P(N \leq 2) = 1 - e^{-2.5}(1 + 2.5 + 2.5^2/2) = 1 - 0.0821 \times 9.125 \approx 1 - 0.749 = 0.251.

(c) Find the median inter-arrival time.

Median =LBln2RB◆◆LBλRB=LBln2RB◆◆LB5RB0.139hours8.3minutes= \dfrac◆LB◆\ln 2◆RB◆◆LB◆\lambda◆RB◆ = \dfrac◆LB◆\ln 2◆RB◆◆LB◆5◆RB◆ \approx 0.139\,\mathrm{hours} \approx 8.3\,\mathrm{minutes}.


7. The Continuous Uniform Distribution

7.1 Definition

Definition. XU(a,b)X \sim U(a, b) if:

f(x)=1ba,axbf(x) = \frac{1}{b - a}, \quad a \leq x \leq b

and f(x)=0f(x) = 0 otherwise.

7.2 Proof of E(X)E(X) and Var(X)\mathrm{Var}(X)

Proof

E(X)=abx1badx=1ba[x22]ab=b2a22(ba)=(ba)(b+a)2(ba)=a+b2E(X) = \int_a^b x \cdot \frac{1}{b-a}\,dx = \frac{1}{b-a}\left[\frac{x^2}{2}\right]_a^b = \frac{b^2 - a^2}{2(b-a)} = \frac{(b-a)(b+a)}{2(b-a)} = \frac{a+b}{2} \quad \blacksquare

E(X2)=abx21badx=1ba[x33]ab=b3a33(ba)=a2+ab+b23E(X^2) = \int_a^b x^2 \cdot \frac{1}{b-a}\,dx = \frac{1}{b-a}\left[\frac{x^3}{3}\right]_a^b = \frac{b^3 - a^3}{3(b-a)} = \frac{a^2 + ab + b^2}{3}

Var(X)=a2+ab+b23(a+b)24=4(a2+ab+b2)3(a+b)212\mathrm{Var}(X) = \frac{a^2 + ab + b^2}{3} - \frac{(a+b)^2}{4} = \frac{4(a^2 + ab + b^2) - 3(a+b)^2}{12}

=4a2+4ab+4b23a26ab3b212=a22ab+b212= \frac{4a^2 + 4ab + 4b^2 - 3a^2 - 6ab - 3b^2}{12} = \frac{a^2 - 2ab + b^2}{12}

Var(X)=(ba)212\boxed{\mathrm{Var}(X) = \frac{(b-a)^2}{12}} \quad \blacksquare

7.3 CDF of the continuous uniform

F(x)={0x<axabaaxb1x>bF(x) = \begin{cases} 0 & x \lt{} a \\ \dfrac{x - a}{b - a} & a \leq x \leq b \\ 1 & x > b \end{cases}


8. Mixture Distributions

8.1 Definition

A mixture distribution arises when a random variable is selected from one of several sub-populations. If XX comes from distribution 1 with probability pp and from distribution 2 with probability 1p1-p:

f(x)=pf1(x)+(1p)f2(x)f(x) = p\,f_1(x) + (1-p)\,f_2(x)

E(X)=pE(X1)+(1p)E(X2)E(X) = p\,E(X_1) + (1-p)\,E(X_2)

Var(X)=pVar(X1)+(1p)Var(X2)+p(1p)[E(X1)E(X2)]2\mathrm{Var}(X) = p\,\mathrm{Var}(X_1) + (1-p)\,\mathrm{Var}(X_2) + p(1-p)[E(X_1) - E(X_2)]^2

The variance formula includes an extra term from the difference in means — this is the law of total variance.

8.2 Worked example

Example. A machine produces components. With probability 0.7 it is correctly calibrated, producing components with lifetime Exp(0.01)\sim \mathrm{Exp}(0.01). With probability 0.3 it is faulty, producing components with lifetime Exp(0.002)\sim \mathrm{Exp}(0.002). Find the overall PDF, the expected lifetime, and P(X>100)P(X > 100).

f(x)=0.7(0.01e0.01x)+0.3(0.002e0.002x)=0.007e0.01x+0.0006e0.002xf(x) = 0.7(0.01\,e^{-0.01x}) + 0.3(0.002\,e^{-0.002x}) = 0.007\,e^{-0.01x} + 0.0006\,e^{-0.002x}

E(X)=0.7×100+0.3×500=70+150=220hoursE(X) = 0.7 \times 100 + 0.3 \times 500 = 70 + 150 = 220\,\mathrm{hours}.

P(X>100)=0.7e0.01×100+0.3e0.002×100=0.7e1+0.3e0.20.7(0.3679)+0.3(0.8187)P(X > 100) = 0.7\,e^{-0.01 \times 100} + 0.3\,e^{-0.002 \times 100} = 0.7e^{-1} + 0.3e^{-0.2} \approx 0.7(0.3679) + 0.3(0.8187)

0.2575+0.2456=0.5031\approx 0.2575 + 0.2456 = 0.5031.


9. Common Pitfalls

Confusing PDF with CDF

The PDF f(x)f(x) gives the density of probability at xx. It is not a probability itself — f(x)f(x) can be greater than 1. The CDF F(x)F(x) gives the accumulated probability up to xx, and always satisfies 0F(x)10 \leq F(x) \leq 1.

Common error: writing P(X=a)=f(a)P(X = a) = f(a) for a continuous RV. This is wrong — P(X=a)=0P(X = a) = 0 always. Probabilities are areas under the PDF, not values of the PDF.

Discrete vs continuous probability

For a discrete RV, P(X=a)>0P(X = a) > 0 for specific values, and probabilities sum to 1.

For a continuous RV, P(X=a)=0P(X = a) = 0 for any single value, and probabilities integrate to 1.

Never use summation for a continuous RV or integration for a discrete RV (unless using the CDF formalism).

Exponential rate vs mean

XExp(λ)X \sim \mathrm{Exp}(\lambda) has mean 1/λ1/\lambda. A common error is to confuse λ\lambda (the rate) with the mean. If the mean lifetime is 200 hours, then λ=1/200=0.005\lambda = 1/200 = 0.005, not λ=200\lambda = 200.

Check: a larger λ\lambda means shorter lifetimes on average (events happen more frequently).

Units in Poisson-exponential problems

If events occur at rate λ=5\lambda = 5 per hour, then the inter-arrival time is Exp(5)\mathrm{Exp}(5) measured in hours. If you want the probability of waiting more than 20 minutes, convert to hours: t=1/3t = 1/3 hours. Using t=20t = 20 directly would give P(T>20)=e100P(T > 20) = e^{-100}, which is essentially zero and clearly wrong.


10. Problem Set

Q1. XExp(λ)X \sim \mathrm{Exp}(\lambda). Find the value of λ\lambda such that P(X>2)=0.3P(X > 2) = 0.3, and hence find E(X)E(X) and the 80th percentile.

P(X>2)=e2λ=0.3    2λ=ln(0.3)    λ=LBln(0.3)RB◆◆LB2RB=1.2042=0.602P(X > 2) = e^{-2\lambda} = 0.3 \implies -2\lambda = \ln(0.3) \implies \lambda = \dfrac◆LB◆-\ln(0.3)◆RB◆◆LB◆2◆RB◆ = \dfrac{1.204}{2} = 0.602.

E(X)=1/0.6021.661E(X) = 1/0.602 \approx 1.661.

80th percentile: F(x)=0.8    1e0.602x=0.8    e0.602x=0.2    x=LBln(0.2)RB◆◆LB0.602RB=1.6090.6022.673F(x) = 0.8 \implies 1 - e^{-0.602x} = 0.8 \implies e^{-0.602x} = 0.2 \implies x = \dfrac◆LB◆-\ln(0.2)◆RB◆◆LB◆0.602◆RB◆ = \dfrac{1.609}{0.602} \approx 2.673.

Q2. A continuous random variable XX has PDF f(x)=kx(4x)f(x) = kx(4-x) for 0x40 \leq x \leq 4. Find kk, E(X)E(X), Var(X)\mathrm{Var}(X), and the median.

04kx(4x)dx=k04(4xx2)dx=k[2x2x33]04=k(3264/3)=k(32/3)=1    k=3/32\int_0^4 kx(4-x)\,dx = k\int_0^4 (4x - x^2)\,dx = k\left[2x^2 - \dfrac{x^3}{3}\right]_0^4 = k(32 - 64/3) = k(32/3) = 1 \implies k = 3/32.

E(X)=33204(4x2x3)dx=332[4x33x44]04=332(256364)=332(2561923)=6432=2E(X) = \dfrac{3}{32}\int_0^4 (4x^2 - x^3)\,dx = \dfrac{3}{32}\left[\dfrac{4x^3}{3} - \dfrac{x^4}{4}\right]_0^4 = \dfrac{3}{32}\left(\dfrac{256}{3} - 64\right) = \dfrac{3}{32}\left(\dfrac{256 - 192}{3}\right) = \dfrac{64}{32} = 2.

E(X2)=33204(4x3x4)dx=332[x4x55]04=332(256204.8)=LB3×51.2RB◆◆LB32RB=4.8E(X^2) = \dfrac{3}{32}\int_0^4 (4x^3 - x^4)\,dx = \dfrac{3}{32}\left[x^4 - \dfrac{x^5}{5}\right]_0^4 = \dfrac{3}{32}(256 - 204.8) = \dfrac◆LB◆3 \times 51.2◆RB◆◆LB◆32◆RB◆ = 4.8.

Var(X)=4.84=0.8\mathrm{Var}(X) = 4.8 - 4 = 0.8.

Median: 3320m(4xx2)dx=0.5    332(2m2m33)=0.5\dfrac{3}{32}\int_0^m (4x - x^2)\,dx = 0.5 \implies \dfrac{3}{32}\left(2m^2 - \dfrac{m^3}{3}\right) = 0.5.

2m2m33=163    6m2m3=162m^2 - \dfrac{m^3}{3} = \dfrac{16}{3} \implies 6m^2 - m^3 = 16.

By inspection: m=2m = 2 gives 248=1624 - 8 = 16. So the median is 22 (equal to the mean, reflecting the symmetry of the PDF about x=2x = 2).

Q3. Emails arrive at a server as a Poisson process with rate 12 per hour. Find the probability that the time between two consecutive emails is between 2 and 5 minutes, and find the probability that the third email arrives within 10 minutes.

Inter-arrival time TExp(12)T \sim \mathrm{Exp}(12) per hour.

P(2/60<T<5/60)=e12(2/60)e12(5/60)=e0.4e10.67030.3679=0.3024P(2/60 \lt{} T \lt{} 5/60) = e^{-12(2/60)} - e^{-12(5/60)} = e^{-0.4} - e^{-1} \approx 0.6703 - 0.3679 = 0.3024.

For the third email: the total time S3=T1+T2+T3Gamma(3,12)S_3 = T_1 + T_2 + T_3 \sim \mathrm{Gamma}(3, 12).

Alternatively, use the Poisson count: P(atleast3in10min)=P(N(1/6)3)P(\mathrm{at least 3 in 10 min}) = P(N(1/6) \geq 3) where N(1/6)Po(2)N(1/6) \sim \mathrm{Po}(2).

=1P(N2)=1e2(1+2+2)=15e210.6767=0.3233= 1 - P(N \leq 2) = 1 - e^{-2}(1 + 2 + 2) = 1 - 5e^{-2} \approx 1 - 0.6767 = 0.3233.

Q4. XU(0,a)X \sim U(0, a). Given that E(X)=3E(X) = 3 and Var(X)=3\mathrm{Var}(X) = 3, find aa and the 90th percentile.

E(X)=a/2=3    a=6E(X) = a/2 = 3 \implies a = 6.

Check: Var(X)=(ba)2/12=36/12=3\mathrm{Var}(X) = (b-a)^2/12 = 36/12 = 3. \checkmark

90th percentile: F(x)=(x0)/6=0.9    x=5.4F(x) = (x - 0)/6 = 0.9 \implies x = 5.4.

Q5. The lifetime of Component A follows Exp(0.02)\mathrm{Exp}(0.02) and Component B follows Exp(0.05)\mathrm{Exp}(0.05) (in hours). They are connected in series, so the system fails when either component fails. Assuming independence, find the PDF of the system lifetime, the expected system lifetime, and P(systemlasts>50hours)P(\mathrm{system lasts} > 50\,\mathrm{hours}).

System lifetime T=min(XA,XB)T = \min(X_A, X_B).

P(T>t)=P(XA>t)P(XB>t)=e0.02te0.05t=e0.07tP(T > t) = P(X_A > t)P(X_B > t) = e^{-0.02t} \cdot e^{-0.05t} = e^{-0.07t}.

So TExp(0.07)T \sim \mathrm{Exp}(0.07).

E(T)=1/0.0714.3hoursE(T) = 1/0.07 \approx 14.3\,\mathrm{hours}.

P(T>50)=e0.07×50=e3.50.0302P(T > 50) = e^{-0.07 \times 50} = e^{-3.5} \approx 0.0302.

Note: the minimum of independent exponential RVs is itself exponential, with rate equal to the sum of the individual rates.

Q6. A random variable XX has PDF f(x)=2x9f(x) = \dfrac{2x}{9} for 0x30 \leq x \leq 3. Find the CDF, E(X)E(X), Var(X)\mathrm{Var}(X), the median, and P(1<X<2)P(1 \lt{} X \lt{} 2).

CDF: F(x)=0x2t9dt=x29F(x) = \int_0^x \dfrac{2t}{9}\,dt = \dfrac{x^2}{9} for 0x30 \leq x \leq 3. F(x)=0F(x) = 0 for x<0x \lt{} 0, F(x)=1F(x) = 1 for x>3x > 3.

E(X)=03x2x9dx=29[x33]03=29×9=2E(X) = \int_0^3 x \cdot \dfrac{2x}{9}\,dx = \dfrac{2}{9}\left[\dfrac{x^3}{3}\right]_0^3 = \dfrac{2}{9} \times 9 = 2.

E(X2)=29[x44]03=29×814=92=4.5E(X^2) = \dfrac{2}{9}\left[\dfrac{x^4}{4}\right]_0^3 = \dfrac{2}{9} \times \dfrac{81}{4} = \dfrac{9}{2} = 4.5.

Var(X)=4.54=0.5\mathrm{Var}(X) = 4.5 - 4 = 0.5.

Median: m29=0.5    m2=4.5    m=4.52.12\dfrac{m^2}{9} = 0.5 \implies m^2 = 4.5 \implies m = \sqrt{4.5} \approx 2.12.

P(1<X<2)=F(2)F(1)=4919=13P(1 \lt{} X \lt{} 2) = F(2) - F(1) = \dfrac{4}{9} - \dfrac{1}{9} = \dfrac{1}{3}.


8. Advanced Worked Examples

Example 8.1: Exponential distribution and memorylessness

Problem. The lifetime TT of a component follows an exponential distribution with mean 200 hours. Given that the component has survived 150 hours, find the probability it survives a further 100 hours.

Solution. By the memoryless property of the exponential distribution:

P(T>150+100T>150)=P(T>100)P(T > 150+100 \mid T > 150) = P(T > 100)

λ=1200=0.005\lambda = \dfrac{1}{200} = 0.005.

P(T>100)=e0.005×100=e0.5=0.607P(T > 100) = e^{-0.005 \times 100} = e^{-0.5} = \boxed{0.607} (3 s.f.).

Example 8.2: Continuous uniform — conditional probability

Problem. XU(0,10)X \sim \mathrm{U}(0, 10). Find P(X>6X>3)P(X > 6 \mid X > 3).

Solution. P(X>6X>3)=P(X>6)P(X>3)=0.40.7=470.571P(X > 6 \mid X > 3) = \dfrac{P(X > 6)}{P(X > 3)} = \dfrac{0.4}{0.7} = \dfrac{4}{7} \approx \boxed{0.571}.

Alternatively: conditional on X>3X > 3, the distribution is U(3,10)\mathrm{U}(3, 10), so P(X>6X>3)=106103=47P(X > 6 \mid X > 3) = \dfrac{10-6}{10-3} = \dfrac{4}{7}.

Example 8.3: Sum of independent exponential random variables

Problem. XX and YY are independent with XExp(λ1)X \sim \mathrm{Exp}(\lambda_1) and YExp(λ2)Y \sim \mathrm{Exp}(\lambda_2). Find P(X<Y)P(X < Y).

Solution. Using the joint density and integration:

P(X<Y)=0xλ1eλ1xλ2eλ2ydydxP(X < Y) = \int_0^{\infty} \int_x^{\infty} \lambda_1 e^{-\lambda_1 x} \cdot \lambda_2 e^{-\lambda_2 y}\,dy\,dx

=0λ1eλ1xeλ2xdx=λ10e(λ1+λ2)xdx= \int_0^{\infty} \lambda_1 e^{-\lambda_1 x} \cdot e^{-\lambda_2 x}\,dx = \lambda_1 \int_0^{\infty} e^{-(\lambda_1+\lambda_2)x}\,dx

=LBλ1RB◆◆LBλ1+λ2RB= \frac◆LB◆\lambda_1◆RB◆◆LB◆\lambda_1 + \lambda_2◆RB◆

For example, if λ1=λ2\lambda_1 = \lambda_2: P(X<Y)=12P(X < Y) = \dfrac{1}{2} (by symmetry).

Example 8.4: Finding a CDF from a PDF with a parameter

Problem. A continuous random variable XX has PDF f(x)=kx(4x)f(x) = kx(4-x) for 0x40 \leq x \leq 4. Find kk, the CDF, and P(1<X<3)P(1 < X < 3).

Solution. 04kx(4x)dx=k ⁣[2x2x33]04=k ⁣(32643)=32k3=1    k=332\displaystyle\int_0^4 kx(4-x)\,dx = k\!\left[2x^2 - \frac{x^3}{3}\right]_0^4 = k\!\left(32 - \frac{64}{3}\right) = \frac{32k}{3} = 1 \implies k = \frac{3}{32}.

CDF: F(x)=332 ⁣(2x2x33)=3x216x332F(x) = \dfrac{3}{32}\!\left(2x^2 - \dfrac{x^3}{3}\right) = \dfrac{3x^2}{16} - \dfrac{x^3}{32} for 0x40 \leq x \leq 4.

P(1<X<3)=F(3)F(1)=(27162732)(316132)=2732532=1116P(1 < X < 3) = F(3) - F(1) = \left(\dfrac{27}{16} - \dfrac{27}{32}\right) - \left(\dfrac{3}{16} - \dfrac{1}{32}\right) = \dfrac{27}{32} - \dfrac{5}{32} = \boxed{\dfrac{11}{16}}.

Example 8.5: Normal approximation to the exponential

Problem. X1,X2,,X50X_1, X_2, \ldots, X_{50} are independent, each following Exp(0.1)\mathrm{Exp}(0.1). Approximate P(X>12)P(\overline{X} > 12).

Solution. E(Xi)=10E(X_i) = 10, Var(Xi)=100\mathrm{Var}(X_i) = 100. E(X)=10E(\overline{X}) = 10, Var(X)=10050=2\mathrm{Var}(\overline{X}) = \dfrac{100}{50} = 2.

By the CLT, XN(10,2)\overline{X} \approx N(10, 2) approximately.

P(X>12)=P ⁣(Z>LB1210RB◆◆LB2RB)=P(Z>1.414)=10.9214=0.0786P(\overline{X} > 12) = P\!\left(Z > \frac◆LB◆12-10◆RB◆◆LB◆\sqrt{2}◆RB◆\right) = P(Z > 1.414) = 1 - 0.9214 = \boxed{0.0786}

Example 8.6: Transformation of a continuous random variable

Problem. XX has PDF fX(x)=2xf_X(x) = 2x for 0<x<10 < x < 1. Find the PDF of Y=X2Y = X^2.

Solution. For 0<y<10 < y < 1: FY(y)=P(Yy)=P(X2y)=P(Xy)=(y)2=yF_Y(y) = P(Y \leq y) = P(X^2 \leq y) = P(X \leq \sqrt{y}) = (\sqrt{y})^2 = y.

fY(y)=ddyFY(y)=1for 0<y<1f_Y(y) = \frac{d}{dy}F_Y(y) = \boxed{1} \quad \text{for } 0 < y < 1

So YU(0,1)Y \sim \mathrm{U}(0,1).

Example 8.7: Mode and median of a triangular distribution

Problem. XX has the triangular distribution with PDF f(x)={2x0x12(2x)1<x2f(x) = \begin{cases}2x & 0 \leq x \leq 1 \\ 2(2-x) & 1 < x \leq 2\end{cases}. Find the mode, median, mean, and variance.

Solution. Mode: The PDF peaks at x=1x = 1, so mode =1= \boxed{1}.

Median: For m1m \leq 1: 0m2xdx=m2\displaystyle\int_0^m 2x\,dx = m^2. Set m2=0.5    m=LB1RB◆◆LB2RB0.707m^2 = 0.5 \implies m = \dfrac◆LB◆1◆RB◆◆LB◆\sqrt{2}◆RB◆ \approx 0.707.

Mean: E(X)=012x2dx+122x(2x)dx=23+[2x22x33]12=23+43=2E(X) = \displaystyle\int_0^1 2x^2\,dx + \int_1^2 2x(2-x)\,dx = \dfrac{2}{3} + \left[2x^2 - \dfrac{2x^3}{3}\right]_1^2 = \dfrac{2}{3} + \dfrac{4}{3} = \boxed{2}.

Wait, let me recalculate: 122x(2x)dx=12(4x2x2)dx=[2x22x33]12=(8163)(223)=8343=43\displaystyle\int_1^2 2x(2-x)\,dx = \int_1^2 (4x - 2x^2)\,dx = \left[2x^2 - \dfrac{2x^3}{3}\right]_1^2 = (8-\dfrac{16}{3}) - (2-\dfrac{2}{3}) = \dfrac{8}{3} - \dfrac{4}{3} = \dfrac{4}{3}.

E(X)=23+43=2E(X) = \dfrac{2}{3} + \dfrac{4}{3} = \boxed{2}. This is the midpoint of [0,2][0,2], as expected for a symmetric triangular distribution.

E(X2)=012x3dx+12(4x22x3)dx=12+[4x33x42]12=12+323843+12=83E(X^2) = \displaystyle\int_0^1 2x^3\,dx + \int_1^2 (4x^2 - 2x^3)\,dx = \dfrac{1}{2} + \left[\dfrac{4x^3}{3} - \dfrac{x^4}{2}\right]_1^2 = \dfrac{1}{2} + \dfrac{32}{3} - 8 - \dfrac{4}{3} + \dfrac{1}{2} = \dfrac{8}{3}.

Var(X)=834=43\mathrm{Var}(X) = \dfrac{8}{3} - 4 = \boxed{-\dfrac{4}{3}}? This is impossible. Let me recheck E(X2)E(X^2).

E(X2)=012x3dx+12x22(2x)dx=12+28343...E(X^2) = \displaystyle\int_0^1 2x^3\,dx + \int_1^2 x^2 \cdot 2(2-x)\,dx = \dfrac{1}{2} + \dfrac{28}{3} - \dfrac{4}{3} \cdot ...

Actually E(X2)=12+12(4x22x3)dx=12+[43x3x42]12=12+(3238)(4312)=12+8343+12=1+43=73E(X^2) = \dfrac{1}{2} + \int_1^2 (4x^2 - 2x^3)\,dx = \dfrac{1}{2} + \left[\dfrac{4}{3}x^3 - \dfrac{x^4}{2}\right]_1^2 = \dfrac{1}{2} + (\dfrac{32}{3}-8) - (\dfrac{4}{3}-\dfrac{1}{2}) = \dfrac{1}{2}+\dfrac{8}{3}-\dfrac{4}{3}+\dfrac{1}{2} = 1+\dfrac{4}{3} = \dfrac{7}{3}.

Var(X)=734=53\mathrm{Var}(X) = \dfrac{7}{3} - 4 = -\dfrac{5}{3}. This still cannot be right. The issue is E(X)=1E(X) = 1 (not 2) since the distribution is on [0,2][0,2] with peak at 1.

Let me redo: E(X)=23+43=2E(X) = \dfrac{2}{3} + \dfrac{4}{3} = 2. But the distribution is symmetric about x=1x=1, so E(X)E(X) should be 11.

Rechecking the second integral: 122(2x)xdx\int_1^2 2(2-x)x\,dx. At x=1x=1: 2(1)(1)=22(1)(1) = 2. At x=2x=2: 00. This integral should give 2/32/3 by symmetry.

12(4x2x2)dx=[2x22x33]12=(8163)(223)=8343=43\int_1^2 (4x-2x^2)\,dx = [2x^2-\frac{2x^3}{3}]_1^2 = (8-\frac{16}{3})-(2-\frac{2}{3}) = \frac{8}{3}-\frac{4}{3} = \frac{4}{3}.

Total: 23+43=2\frac{2}{3}+\frac{4}{3} = 2. But the range is [0,2][0,2] and the function is symmetric about x=1x=1. The mean of a symmetric distribution on [0,2][0,2] about x=1x=1 is 11. There must be a normalization error. Let me verify: 012xdx=1\int_0^1 2x\,dx = 1 and 122(2x)dx=[4xx2]12=(84)(41)=1\int_1^2 2(2-x)\,dx = [4x-x^2]_1^2 = (8-4)-(4-1) = 1. Total area =21= 2 \neq 1.

The PDF should be f(x)=xf(x) = x for 0x10 \leq x \leq 1 and f(x)=2xf(x) = 2-x for 1<x21 < x \leq 2. Then E(X)=01x2dx+12x(2x)dx=13+23=1E(X) = \int_0^1 x^2\,dx + \int_1^2 x(2-x)\,dx = \frac{1}{3}+\frac{2}{3} = 1. ✓


9. Common Pitfalls

PitfallCorrect Approach
Confusing the rate λ\lambda with the mean LB1RB◆◆LBλRB\dfrac◆LB◆1◆RB◆◆LB◆\lambda◆RB◆ for exponential distributionsE(X)=LB1RB◆◆LBλRBE(X) = \dfrac◆LB◆1◆RB◆◆LB◆\lambda◆RB◆; the rate parameter is λ\lambda
Forgetting that the total area under a PDF must equal 1Always verify: f(x)dx=1\displaystyle\int_{-\infty}^{\infty} f(x)\,dx = 1
Applying the exponential memoryless property to other distributionsOnly the exponential distribution has this property
Using P(a<X<b)=f(b)f(a)P(a < X < b) = f(b) - f(a)This is for CDFs, not PDFs. Use abf(x)dx\displaystyle\int_a^b f(x)\,dx

10. Additional Exam-Style Questions

Question 8

Calls arrive at a call centre at a rate of 4 per hour. Find the probability that the time between two consecutive calls exceeds 45 minutes.

Solution

Time between calls TExp(4)T \sim \mathrm{Exp}(4) (rate =4= 4 per hour).

P(T>0.75)=e4×0.75=e30.0498P(T > 0.75) = e^{-4 \times 0.75} = e^{-3} \approx \boxed{0.0498}.

Question 9

XX is a continuous random variable with PDF f(x)=34(2xx2)f(x) = \dfrac{3}{4}(2x - x^2) for 0x20 \leq x \leq 2. Find E(X)E(X), Var(X)\mathrm{Var}(X), and the median.

Solution

E(X)=3402(2x2x3)dx=34 ⁣[2x33x44]02=34 ⁣(1634)=3443=1E(X) = \dfrac{3}{4}\displaystyle\int_0^2 (2x^2-x^3)\,dx = \dfrac{3}{4}\!\left[\dfrac{2x^3}{3}-\dfrac{x^4}{4}\right]_0^2 = \dfrac{3}{4}\!\left(\dfrac{16}{3}-4\right) = \dfrac{3}{4}\cdot\dfrac{4}{3} = 1.

E(X2)=3402(2x3x4)dx=34 ⁣[x42x55]02=34 ⁣(8325)=3485=65E(X^2) = \dfrac{3}{4}\displaystyle\int_0^2 (2x^3-x^4)\,dx = \dfrac{3}{4}\!\left[\dfrac{x^4}{2}-\dfrac{x^5}{5}\right]_0^2 = \dfrac{3}{4}\!\left(8-\dfrac{32}{5}\right) = \dfrac{3}{4}\cdot\dfrac{8}{5} = \dfrac{6}{5}.

Var(X)=651=15\mathrm{Var}(X) = \dfrac{6}{5}-1 = \dfrac{1}{5}.

Median mm: 34 ⁣(m2m33)=12\dfrac{3}{4}\!\left(m^2-\dfrac{m^3}{3}\right) = \dfrac{1}{2}. By inspection or numerical methods: m0.908m \approx 0.908.

Question 10

Prove that for XExp(λ)X \sim \mathrm{Exp}(\lambda), the memoryless property holds: P(X>s+tX>s)=P(X>t)P(X > s+t \mid X > s) = P(X > t).

Solution

P(X>s+tX>s)=P(X>s+t)P(X>s)=LBeλ(s+t)RB◆◆LBeλsRB=eλt=P(X>t)P(X > s+t \mid X > s) = \frac{P(X > s+t)}{P(X > s)} = \frac◆LB◆e^{-\lambda(s+t)}◆RB◆◆LB◆e^{-\lambda s}◆RB◆ = e^{-\lambda t} = P(X > t)

\blacksquare


11. Connections to Other Topics

11.1 Exponential distribution and Poisson process

The exponential distribution models inter-arrival times in a Poisson process. See Poisson and Geometric Distributions.

11.2 Continuous distributions and integration

Finding CDFs, means, and variances of continuous random variables requires integration. See Further Calculus.

11.3 Normal distribution and the CLT

The Central Limit Theorem connects the exponential and uniform distributions to the normal distribution. See Chi-Squared Tests.


12. Key Results Summary

DistributionPDFE(X)E(X)Var(X)\mathrm{Var}(X)
Exp(λ)\mathrm{Exp}(\lambda)λeλx\lambda e^{-\lambda x}, x0x \geq 0LB1RB◆◆LBλRB\dfrac◆LB◆1◆RB◆◆LB◆\lambda◆RB◆LB1RB◆◆LBλ2RB\dfrac◆LB◆1◆RB◆◆LB◆\lambda^2◆RB◆
U(a,b)\mathrm{U}(a,b)1ba\dfrac{1}{b-a}, axba \leq x \leq ba+b2\dfrac{a+b}{2}(ba)212\dfrac{(b-a)^2}{12}
PropertyExponentialUniform
MemorylessYesNo
CDF1eλx1 - e^{-\lambda x}xaba\dfrac{x-a}{b-a}
MedianLBln2RB◆◆LBλRB\dfrac◆LB◆\ln 2◆RB◆◆LB◆\lambda◆RB◆a+b2\dfrac{a+b}{2}

13. Further Exam-Style Questions

Question 11

The lifetime of a light bulb follows an exponential distribution with mean 500 hours. Find: (a) the probability it lasts more than 600 hours; (b) the probability it lasts between 400 and 600 hours; (c) the median lifetime.

Solution

λ=1500=0.002\lambda = \dfrac{1}{500} = 0.002.

(a) P(X>600)=e1.20.301P(X > 600) = e^{-1.2} \approx \boxed{0.301}.

(b) P(400<X<600)=e0.8e1.20.4490.301=0.148P(400 < X < 600) = e^{-0.8} - e^{-1.2} \approx 0.449 - 0.301 = \boxed{0.148}.

(c) Median mm: e0.002m=0.5    m=LBln2RB◆◆LB0.002RB=346.6hourse^{-0.002m} = 0.5 \implies m = \dfrac◆LB◆\ln 2◆RB◆◆LB◆0.002◆RB◆ = \boxed{346.6\,\text{hours}}.

Question 12

Prove that for XU(a,b)X \sim \mathrm{U}(a,b), Var(X)=(ba)212\mathrm{Var}(X) = \dfrac{(b-a)^2}{12}.

Solution

E(X)=a+b2E(X) = \dfrac{a+b}{2}.

E(X2)=1baabx2dx=b3a33(ba)=a2+ab+b23E(X^2) = \dfrac{1}{b-a}\displaystyle\int_a^b x^2\,dx = \dfrac{b^3-a^3}{3(b-a)} = \dfrac{a^2+ab+b^2}{3}.

Var(X)=a2+ab+b23(a+b)24=4a2+4ab+4b23a26ab3b212=a22ab+b212=(ba)212\mathrm{Var}(X) = \dfrac{a^2+ab+b^2}{3} - \dfrac{(a+b)^2}{4} = \dfrac{4a^2+4ab+4b^2-3a^2-6ab-3b^2}{12} = \dfrac{a^2-2ab+b^2}{12} = \boxed{\dfrac{(b-a)^2}{12}}. \blacksquare


14. Advanced Topics

14.1 The moment generating function (MGF)

The MGF of a random variable XX is MX(t)=E(etX)M_X(t) = E(e^{tX}).

Properties:

  • MX(0)=1M_X(0) = 1
  • MX(0)=E(X)M_X'(0) = E(X)
  • MX(0)=E(X2)M_X''(0) = E(X^2)
  • If XX and YY are independent, MX+Y(t)=MX(t)MY(t)M_{X+Y}(t) = M_X(t)M_Y(t)

MGFs:

  • Exp(λ)\mathrm{Exp}(\lambda): M(t)=LBλRB◆◆LBλtRBM(t) = \dfrac◆LB◆\lambda◆RB◆◆LB◆\lambda-t◆RB◆ for t<λt < \lambda
  • U(a,b)\mathrm{U}(a,b): M(t)=ebteat(ba)tM(t) = \dfrac{e^{bt}-e^{at}}{(b-a)t}

14.2 The cumulative distribution function approach

For any continuous random variable with PDF f(x)f(x):

P(a<Xb)=F(b)F(a)P(a < X \leq b) = F(b) - F(a) where F(x)=xf(t)dtF(x) = \displaystyle\int_{-\infty}^x f(t)\,dt.

14.3 Order statistics

For i.i.d. random variables X1,,XnX_1, \ldots, X_n, the order statistics are X(1)X(2)X(n)X_{(1)} \leq X_{(2)} \leq \cdots \leq X_{(n)}.

For XU(0,1)X \sim \mathrm{U}(0,1): X(k)Beta(k,nk+1)X_{(k)} \sim \mathrm{Beta}(k, n-k+1).


15. Further Exam-Style Questions

Question 13

Find the MGF of XExp(λ)X \sim \mathrm{Exp}(\lambda) and use it to find E(X)E(X) and Var(X)\mathrm{Var}(X).

Solution

M(t)=0etxλeλxdx=λ0e(λt)xdx=LBλRB◆◆LBλtRBM(t) = \displaystyle\int_0^{\infty} e^{tx}\lambda e^{-\lambda x}\,dx = \lambda\displaystyle\int_0^{\infty} e^{-(\lambda-t)x}\,dx = \frac◆LB◆\lambda◆RB◆◆LB◆\lambda-t◆RB◆ for t<λt < \lambda.

M(t)=LBλRB◆◆LB(λt)2RBM'(t) = \dfrac◆LB◆\lambda◆RB◆◆LB◆(\lambda-t)^2◆RB◆. M(0)=LB1RB◆◆LBλRB=E(X)M'(0) = \dfrac◆LB◆1◆RB◆◆LB◆\lambda◆RB◆ = E(X). ✓

M(t)=LB2λRB◆◆LB(λt)3RBM''(t) = \dfrac◆LB◆2\lambda◆RB◆◆LB◆(\lambda-t)^3◆RB◆. M(0)=LB2RB◆◆LBλ2RB=E(X2)M''(0) = \dfrac◆LB◆2◆RB◆◆LB◆\lambda^2◆RB◆ = E(X^2).

Var(X)=LB2RB◆◆LBλ2RBLB1RB◆◆LBλ2RB=LB1RB◆◆LBλ2RB\mathrm{Var}(X) = \dfrac◆LB◆2◆RB◆◆LB◆\lambda^2◆RB◆ - \dfrac◆LB◆1◆RB◆◆LB◆\lambda^2◆RB◆ = \boxed{\dfrac◆LB◆1◆RB◆◆LB◆\lambda^2◆RB◆}. ✓

Question 14

Prove that if XU(0,1)X \sim \mathrm{U}(0,1), then Y=LB1RB◆◆LBλRBlnXY = -\dfrac◆LB◆1◆RB◆◆LB◆\lambda◆RB◆\ln X follows Exp(λ)\mathrm{Exp}(\lambda).

Solution

FY(y)=P(Yy)=P ⁣(LB1RB◆◆LBλRBlnXy)=P(lnXλy)=P(Xeλy)F_Y(y) = P(Y \leq y) = P\!\left(-\dfrac◆LB◆1◆RB◆◆LB◆\lambda◆RB◆\ln X \leq y\right) = P(\ln X \geq -\lambda y) = P(X \geq e^{-\lambda y}).

=1eλy= 1 - e^{-\lambda y} for y0y \geq 0.

This is the CDF of Exp(λ)\mathrm{Exp}(\lambda). \blacksquare