0% found this document useful (0 votes)
239 views75 pages

CRV Complete-1

The document discusses continuous random variables and their probability density functions (PDFs). It defines continuous random variables as those with a continuous range of possible values described by a PDF. The key properties of a PDF are that it is always non-negative and its total area under the curve is equal to 1. The cumulative distribution function (CDF) provides the probability that a random variable is less than or equal to a given value.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
239 views75 pages

CRV Complete-1

The document discusses continuous random variables and their probability density functions (PDFs). It defines continuous random variables as those with a continuous range of possible values described by a PDF. The key properties of a PDF are that it is always non-negative and its total area under the curve is equal to 1. The cumulative distribution function (CDF) provides the probability that a random variable is less than or equal to a given value.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 75

Continuous Random

Variables
• Random variables with a continuous range of possible experimental
values are quite common e.g., velocity of vehicle.
• Weight of a person over a period of time
CONTINUOUS RANDOM VARIABLES AND PDFS
• Random variable X is called continuous if its probability law can be
described in terms of a nonnegative function fX, called the probability
density function of X, or PDF for short, which satisfies
𝑃(𝑋єB) = න 𝑓(𝑥) 𝑑𝑥
𝐵 𝑏
𝑃(𝑎 ≤ 𝑋 ≤ b) = න 𝑓(𝑥) 𝑑𝑥
𝑎
𝑃 𝑋 = 𝑎 = 𝑃(𝑎 ≤ 𝑋 ≤ a)
𝑎
𝑃(𝑎 ≤ 𝑋 ≤ a) = න 𝑓 𝑥 𝑑𝑥 = 0
𝑎
• Including or excluding the endpoints of an interval has no effect on its
probability
𝑃(𝑎 ≤ 𝑋 ≤ b)=𝑃(𝑎 < 𝑋< b)=𝑃(𝑎 ≤ 𝑋<b)=𝑃(𝑎 < 𝑋 ≤ b)

And 𝑃(−∞ ≤ 𝑋 ≤ ∞) = ‫׬‬−∞ 𝑓 𝑥 𝑑𝑥 = 1
CONTINUOUS RANDOM VARIABLES AND PDFS
CONTINUOUS RANDOM VARIABLES AND PDFS
Graphically, this means that the entire area under the graph of the
PDF must be equal to 1.
To interpret the PDF, note that for an interval [x, x + δ] with very
small length δ, we have
Example 3.1
A gambler spins a wheel of fortune, continuously calibrated between 0
and 1, and observes the resulting number. Assuming that all
subintervals of [0,1] of the same length are equally likely, this
experiment can be modeled in terms a random variable X with PDF
𝑐 𝑖𝑓0 ≤ 𝑥 ≤ 1
𝑓 𝑥 =ቊ
0 𝑜𝑡ℎ𝑒𝑟𝑤𝑖𝑠𝑒
Solution
Example
More generally, we can consider a random variable X that takes values
in an interval [a, b],

Note that the probability P(X ∈ I) that X takes value in a set I is


Example
Alvin’s driving time to work is between 15 and 20 minutes if the day is
sunny, and between 20 and 25 minutes if the day is rainy, with all times
being equally likely in each case. Assume that a day is sunny with
probability 2/3 and rainy with probability 1/3. What is the PDF of the
driving time, viewed as a random variable X?
Solution
Example
Consider a random variable X with PDF Solution

Solution
Summary of PDF Properties
Let X be a continuous random variable with PDF fX.
Expectation
The expectation of X
is defined by
The expected value
rule for a function
g(X) has the form
The variance of X is
defined by

We have

If Y = aX + b, where a
and b are given
scalars, then
Example 3.4
Consider the case of a uniform PDF over an interval [a, b], as in
Example 3.1. We have
Example
To obtain the variance, we first calculate the second moment. We have
Example
To obtain the variance, we first calculate the second moment. We have
Example
Thus, the variance is obtained as

Suppose now that [a, b] = [0, 1], and consider the function g(x) = 1 if
x ≤ 1/3, and g(x) = 2 if x > 1/3. The random variable Y = g(X) is a discrete
one with PMF pY (1) = P(X ≤ 1/3) = 1/3, pY (2) = 1 − pY (1) = 2/3. Thus,

The same result could be obtained using the expected value rule:
Exponential Random Variable
An exponential random variable has a PDF of the form

where λ is a positive parameter characterizing the PDF

the probability that X exceeds a certain value falls exponentially and for
any a ≥ 0, we have
Exponential Random Variable

The PDF λe−λx of an exponential random variable.


Mean of Exponential Random Variable
Variance of Exponential Random Variable

Finally, using the formula


Example 3.5
The time until a small meteorite first lands anywhere in the Sahara
desert is modeled as an exponential random variable with a mean of 10
days. The time is currently midnight. What is the probability that a
meteorite first lands some time between 6am and 6pm of the first day?
Solution
Let X be the time elapsed until the event of interest, measured in days.
Then, X is exponential, with mean 1/λ = 10, which yields λ = 1/10. The
desired probability is

where we have used the formula


CUMULATIVE DISTRIBUTION FUNCTIONS
CDF random variables with a single mathematical concept.
The CDF of a random variable X is denoted by FX and provides the
probability P(X ≤ x).
The CDF FX(x) “accumulates” probability “up to” the value x.
CUMULATIVE DISTRIBUTION FUNCTIONS

CDFs of some discrete random variables


CUMULATIVE DISTRIBUTION FUNCTIONS

CDFs of continuous random variables


Properties of a CDF
The CDF FX of a random variable X is defined by

and has the following properties


• FX is monotonically non-decreasing:
if x ≤ y, then FX(x) ≤ FX(y).
• FX(x) tends to 0 as x→−∞, and to 1 as x→∞.
• If X is discrete, then FX has a piecewise constant and staircase-like
form.
• If X is continuous, then FX has a continuously varying form.
Properties of a CDF
• If X is discrete and takes integer values, the PMF and the CDF can be
obtained from each other by summing or differencing:

for all integers k.


• If X is continuous, the PDF and the CDF can be obtained from each
other by integration or differentiation:
Example 1
If 𝑋 is a discrete r.v. we can find a cumulative
probability by adding up all the probabilities up to a
certain value. We denote the cumulative probability
using 𝐹 𝑥 = 𝑃(𝑋 ≤ 𝑥)
Example: given the distribution for 𝑋 shown, find the
cumulative distribution function

x 1 2 3 4 5 6
1 1 1 1 1 1
P(X = x ) 6 6 6 6 6 6
1
𝐹 1 =𝑃 𝑋≤1 =
6
1 1 1
𝐹 2 =𝑃 𝑋 ≤2 =𝑃 𝑋 =1 +𝑃 𝑋 =2 = + =
6 6 3
Example 1

x 1 2 3 4 5 6
1 1 1 1 1 1
P(X = x ) 6 6 6 6 6 6
1
𝐹 1 =𝑃 𝑋≤1 =
6
1 1 1
𝐹 2 =𝑃 𝑋 ≤2 =𝑃 𝑋 =1 +𝑃 𝑋 =2 = + =
6 6 3
Example 1
x 1 2 3 4 5 6
1 1 1 1 1 1
P(X = x ) 6 6 6 6 6 6
1
𝐹 1 =𝑃 𝑋≤1 =
6
1 1 2
𝐹 2 =𝑃 𝑋 ≤2 =𝑃 𝑋 =1 +𝑃 𝑋 =2 = + =
6 6 6
3
𝐹 3 =𝑃 𝑋≤3 = 𝑥
6
4
Therefore 𝐹 𝑥 = for 𝑥 = 1,2,3, … , 6
6
𝐹 4 =𝑃 𝑋≤4 =
6

𝐹 5 =𝑃 𝑋≤5 =
5 It is not always possible to write a
6 formula – see next example
6
𝐹 6 =𝑃 𝑋≤6 =
6
Example 2
The probability distribution for the r.v. 𝑋 is shown in the
table. Construct the cumulative distribution table.
𝑥 0 1 2 3 4 5 6
𝑃(𝑋 = 𝑥) 0.03 0.04 0.06 0.12 0.4 0.15 0.2
𝐹(𝑥) 0.03 0.07 0.13 0.25 0.65 0.8 1

𝐹 0 =𝑃 𝑋 ≤ 0 = 0.03
𝐹 1 =𝑃 𝑋 ≤ 1 = 0.03 + 0.04 = 0.07
𝐹 2 =𝑃 𝑋 ≤ 2 = 0.03 + 0.04 + 0.06 = 0.13
And so on. This gives us the cumulative distribution table
Example 3
Given the cumulative distribution function 𝐹(𝑥) for the
discrete r.v. 𝑋, find
𝑥 1 2 3 4 5
(a) 𝑃 𝑋 = 3 𝐹(𝑥) 0.2 0.32 0.67 0.9 1
(b) 𝑃(𝑋 > 2)
Solution
(a) From the table
𝐹 3 = 𝑃 𝑋 ≤ 3 = 𝑃 𝑋 = 1 + 𝑃 𝑋 = 2 + 𝑃 𝑋 = 3 = 0.67
𝐹 2 = 𝑃 𝑋 ≤ 2 = 𝑃 𝑋 = 1 + 𝑃 𝑋 = 2 = 0.32
Now 𝑃 𝑋 = 3 = 𝐹 3 − 𝐹 2
= 0.67 − 0.32
= 0.35
(b) 𝑃 𝑋 > 2 = 1 − 𝑃 𝑋 ≤ 2
=1−𝐹 2
= 1 − 0.32
= 0.87
Example 4

• Let X, the thickness of a certain metal sheet, have a uniform


distribution on [A, B].
• The density function is shown in Figure

The pdf for a uniform distribution


Example 4

• For x < A, F(x) = 0, since there is no area under the graph of the
density function to the left of such an x.
• For x  B, F(x) = 1, since all the area is accumulated to the left of such
an x. Finally for A  x  B,
Example 4

• The entire cdf is

• The graph of this cdf appears in Figure 4.7.

The cdf for a uniform distribution


Example 5
• “Time headway” in traffic flow is the elapsed time between the time
that one car finishes passing a fixed point and the instant that the
next car begins to pass that point.
• Let X = the time headway for two randomly chosen consecutive cars
on a freeway during a period of heavy flow. The following pdf of X is
essentially the one suggested in “The Statistical Properties of Freeway
Traffic” (Transp. Res., vol. 11: 221–228):
Example 5
• The graph of f(x) is given in Figure; there is no density associated with
headway times less than .5, and headway density decreases rapidly
(exponentially fast) as x increases from .5.

The density curve for time headway in Example


Example 5

• Clearly, f(x)  0; to show that f(x)dx = 1, we use the calculus result

• e–kx dx = (1/k)e–k  a.

• Then
Example 5

• The probability that headway time is at most 5 sec


is

• P(X  5) =

• = .15e–.15(x – .5) dx

• = .15e.075 e–15x dx

• =
Example 5

• = e.075(–e–.75 + e–.075)

• = 1.078(–.472 + .928)

• = .491

• = P(less than 5 sec)

• = P(X < 5)
Example 6

• Suppose the pdf of the magnitude X of a dynamic load on a bridge (in


newtons) is

• For any number x between 0 and 2,


Example 6
cont’d

• Thus

• The graphs of f(x) and F(x) are shown in Figure 4.9.

The pdf and cdf for Example 4.7


Figure 4.9
Example 6
cont’d

• The probability that the load is between 1 and 1.5 is


• P(1  X  1.5) = F(1.5) – F(1)

• The probability that the load exceeds 1 is


• P(X > 1) = 1 – P(X  1)
• = 1 – F(1)
Example 6

• =1–

• Once the cdf has been obtained, any probability involving X can easily
be calculated without any further integration.
Obtaining f(x) from F(x)

• For X discrete, the pmf is obtained from the cdf by taking the
difference between two F(x) values. The continuous analog of a
difference is a derivative.

• The following result is a consequence of the Fundamental Theorem of


Calculus.
• Proposition
• If X is a continuous rv with pdf f(x) and cdf F(x), then at every x at
which the derivative F(x) exists, F(x) = f(x).
Example
• When X has a uniform distribution, F(x) is differentiable except at x =
A and x = B, where the graph of F(x) has sharp corners.

• Since F(x) = 0 for x < A and F(x) = 1 for


x > B, F(x) = 0 = f(x) for such x.

• For A < x < B,


Example 7
• The distribution of the amount of gravel (in tons) sold by a particular
construction supply company in a given week is a continuous rv X
with pdf

• The cdf of sales for any x between 0 and 1 is


Example 7
• The graphs of both f(x) and F(x) appear in Figure

The pdf and cdf


NORMAL RANDOM VARIABLES
The statement that X is normally distributed with parameters  and 2

Clearly f(x; , )  0, but a somewhat complicated calculus argument


must be used to verify that f(x; , ) dx = 1.

It can be shown that E(X) =  and V(X) = 2, so the parameters are the
mean and the standard deviation of X.
The Normal Distribution
Figure presents graphs of f(x; , ) for several different (, ) pairs.

Two different normal density Visualizing  and  for a


curves normal distribution
The Normal Distribution

• Each density curve is symmetric about  and bell-shaped, so the


center of the bell (point of symmetry) is both the mean of the
distribution and the median.

• The value of  is the distance from  to the inflection points of the


curve (the points at which the curve changes from turning downward
to turning upward).
The Normal Distribution

• Large values of  yield graphs that are quite spread out


about , whereas small values of  yield graphs with a high peak
above  and most of the area under the graph quite close to .

• Thus a large  implies that a value of X far from  may well be


observed, whereas such a value is quite unlikely when 
is small.
The Standard Normal Distribution
The computation of P(a  X  b) when X is a normal rv with parameters
 and  requires evaluating

None of the standard integration techniques can be used to accomplish


this. Instead, for  = 0 and  = 1, Expression has been calculated using
numerical techniques and tabulated for certain values of a and b.
This table can also be used to compute probabilities for any other
values of  and  under consideration.
The Standard Normal Distribution
• Definition
The normal distribution with parameter values  = 0 and
 = 1 is called the standard normal distribution.
• The graph of function is called the standard normal (or z) curve. Its
inflection points are at 1 and –1.

• Let X be a normal random variable with mean μ and variance σ2. We


“standardize” X by defining a new random variable Y given by
The Standard Normal Distribution
• illustrates the type of cumulative area (probability) tabulated in Z-
Table . From this table, various other probabilities involving Z can be
calculated.

Standard normal cumulative areas tabulated in Z Table


Example 8
Let’s determine the following standard normal probabilities:
(a) P(Z  1.25), (b) P(Z > 1.25),
(b) (c) P(Z  –1.25), and (d) P(–.38  Z  1.25).

a. P(Z  1.25) = φ(1.25), a probability that is tabulated in


Z-Table at the intersection of the row marked 1.2 and the column
marked .05.

The number there is .8944, so P(Z  1.25) = .8944.


Example 8
cont’d
• Figure illustrates this probability.

Normal curve areas (probabilities) for Example 13

• b. P(Z > 1.25) = 1 – P(Z  1.25) = 1 – φ (1.25), the area


under the z curve to the right of 1.25 (an upper-tail
area). Then φ (1.25) = .8944 implies that
P(Z > 1.25) = .1056.
Example 8 cont’d

• Since Z is a continuous rv, P(Z  1.25) = .1056.


See Figure 4.15(b).

Normal curve areas (probabilities) for Example 13


Figure 4.15(b)

c. P(Z  –1.25) = φ (–1.25), a lower-tail area. Directly from


Z Table A.3, φ (–1.25) = .1056.

• By symmetry of the z curve, this is the same answer as


in part (b).
Example 8 cont’d

• d. P(–.38  Z  1.25) is the area under the standard


normal curve above the interval whose left endpoint is
–.38 and whose right endpoint is 1.25.

• From Section 4.2, if X is a continuous rv with cdf F(x),


then P(a  X  b) = F(b) – F(a).

Thus P(–.38  Z  1.25) = φ (1.25) – φ (–.38)

= .8944 – .3520

• = .5424
Example 8 cont’d

P(–.38  Z  1.25) as the difference between two cumulative areas


Two Continuous Random Variables

• The probability that the observed value of a continuous rv X lies in a


one-dimensional set A (such as an interval) is obtained by integrating
the pdf f(x) over the set A.
• Similarly, the probability that the pair (X, Y) of continuous rv’s falls in a
two-dimensional set A (such as a rectangle) is obtained by integrating
a function called the joint density function.
Two Continuous Random Variables
• Definition
• Let X and Y be continuous rv’s. A joint probability density function f
(x, y) for these two variables is a function satisfying f(x, y)  0 and

• Then for any two-dimensional set A


Two Continuous Random Variables
• In particular, if A is the two-dimensional rectangle
{(x, y): a  x  b, c  y  d}, then

• We can think of f(x, y) as specifying a surface at height


f(x, y) above the point (x, y) in a three-dimensional coordinate system.

Then P[(X, Y)  A] is the volume underneath this surface and above the
region A, analogous to the area under a curve in the case of a single rv.
Two Continuous Random Variables
• This is illustrated in Figure

P[(X, Y )  A] = volume under density surface above A

Figure
Example 9
A bank operates both a drive-up facility and a walk-up window. On a randomly
selected day, let X = the proportion of time that the drive-up facility is in use (at
least one customer is being served or waiting to be served) and Y = the
proportion of time that the walk-up window is in use. Then the set of possible
values for (X, Y) is the rectangle D = {(x, y): 0  x  1, 0  y  1}. Suppose the
joint pdf of (X, Y) is given by
Example 9
• To verify that this is a legitimate pdf, note that f(x, y)  0 andcont’d
Example 9 cont’d

The probability that neither facility is busy more than one-quarter of the
time is
Two Continuous Random Variables
• The marginal pdf of each variable can be obtained in a manner
analogous to what we did in the case of two discrete variables.
• The marginal pdf of X at the value x results from holding x fixed in the
pair (x, y) and integrating the joint pdf over y. Integrating the joint pdf
with respect to x gives the marginal pdf of Y.
Two Continuous Random Variables
Definition
• The marginal probability density functions of X and Y, denoted by fX
(x) and fY(y), respectively, are given by
Example 10
The marginal pdf of X, which gives the probability distribution of busy
time for the drive-up facility without reference to the walk-up window, is

for 0 < x < 1 and 0 otherwise. The marginal pdf of Y is


Example 11
A nut company markets cans of deluxe mixed nuts containing almonds,
cashews, and peanuts. Suppose the net weight of each can is exactly 1 lb,
but the weight contribution of each type of nut is random. Because the
three weights sum to 1, a joint probability model for any two gives all
necessary information about the weight of the third type. Let X = the
weight of almonds in a selected can and Y = the weight of cashews. Then
the region of positive density is D = {(x, y): 0 ≤ x ≤ 1, 0 ≤ y ≤ 1, x + y ≤ 1}, the
shaded region pictured in Figure.
Now let the joint pdf for (X, Y) be
First all the probabilities are positive. To verify the second condition on
a joint pdf, recall that a double integral is computed as an iterated
integral by holding one variable fixed
• To compute the probability that the two types of nuts together make up at
most 50% of the can, let A = {(x, y): 0 ≤ x ≤ 1, 0 ≤ y ≤ 1, and x + y ≤ .5},
Example 12
The joint density of random variables X and Y is given as
𝑘𝑥𝑦 𝑖𝑓0 ≤ 𝑥 ≤ 1, 0 ≤ 𝑦 ≤ 1
𝑓 𝑥 =ቊ
0 𝑜𝑡ℎ𝑒𝑟𝑤𝑖𝑠𝑒
Find (i) value of k (ii) marginal density function of X, Y, (iii) Check for
independence of X and Y (iv) P(X+Y ≤1)
Example 12
Example 12

You might also like