Sie sind auf Seite 1von 40

Continuous Random

Variables and Probability


Distribution

Continuous Random Variables


Continuous random variable: the outcome can
be any value in an interval
Example of CRV = height, time, weight, and
money.
Probability
density
function/
probability
distribution for a continuous random variable X is a
curve such that the area under the curve over an
interval equals the probability that X is in that interval.

P(a X b) =
area under density curve over the
interval between the values a and b.
2

Probability Density Function- CRV

Density
Curve

Continuous Random Variables


For DRV (Discrete RV) we can find the probability that
the variable X exactly equals a specified value. We cant
do this for CRV.
For CRV we are only able to find the probability that X
falls between 2 values or is greater than or is less than
the given value.
We do this by determining the area between the two
values under a curve called the probability density
function or density curve of the random variable.
Unlike DRV, CRV do not have probability distribution
functions specifying the exact probabilities of specified
values.
Instead, they have a probability density function which
are used to find probabilities that the random variable
falls into a specified interval of values.
4

Continuous Random Variables


A density curve (or probability density function)
is a graph of a
continuous probability
distribution. It must satisfy the following 2
properties.
Total area under the curve = 1.0
Every point on the curve must have a
vertical height that is 0 or greater (the curve
cannot fall below the x-axis)

Examples- CRV
If in the study of the ecology of a lake, we make
depth measurements at randomly chosen
locations, then X the depth at such a location is
a continuous rv.
If a chemical compound is randomly selected
and its pH X is determined, then X is a CRV
because any pH value between 0 and 14 is
possible.
6

Continuous Probability Distributions

Continuous Random Variables


Uses of the probability density function of CRV
Used to find the probability that the random
variable X is
greater or equal to some value
less or equal to some value
within a certain range of values.

Continuous Random Variables


Problem Examples
What is the probability that the concrete strength at
certain site will exceed 25N/mm2?
What is the likelihood that a randomly selected
student spends less than 30 minutes at the computer
lab?
What is the probability that the strength of the steel
members supplied by Manufacturer X will be within
5 units of the specified strength?
8

Continuous Random Variables


Finding the actual probability values (areas):
The probabilities of various events may be found using
either
- geometry
- integration (calculus)

Continuous Probability Distributions

Probability Density Function- CRV

S urvey Results: Duration of Fast Food Visits


"How much time (minutes) do you typically spend
dining in a fast food restaurant at each visit?"
Person
Time Spent
Person 1
23
Person 2
22
Person 3
35
Person 4
20
Person 5
30
Person 6
20
Person 7
25
Person 8
10
Person 9
20
Person 10
16
Person 11
12
Person 12
20
Person 13
30
Person 14
15
Person 15
8
Person 16
7
Person 17
15
Person 18
20
Person 19
15
Person 20
5

Time spent
0 to 5 mins

Frequency
1

5+ to 10 mins

10+ to 15 mins

15+ to 20 mins

20+ to 25 mins

25+ to 30 mins

30+ to 35 mins

35+ to 40 mins

10

Probability Density Function - CRV


Survey Results : Duration of Fast Food Visit
Probability Distribution Table for Time Spent
Time Spent
(minutes)

Frequency

Relative Frequency
(Probability)

<0
0+ to 5
5+ to 10
10+ to 15
15+ to 20
20+ to 25
25+ to 30
30+ to 35

0
1
3
4
6
3
2
1

0
0.05
0.15
0.2
0.3
0.15
0.1
0.05
11

Probability Density Function- CRV


Survey Results : Duration of Fast Food Visit
Probability Distribution Curve for Time Spent
Relative Freq (probability)

0.35
0.3
0.25
0.2

0.15
0.1
0.05
0
0

10

15
20
Time Spent (Minutes)

25

30

35

Note: The more people we survey, and the smaller the intervals
of plotting (e.g, 1 minute or 30 seconds instead of 5 minutes)
the more the function becomes truly continuous!
12

Probability Density Function- CRV

The more data points we have in our sample , the


smaller the intervals of plotting and the more the function
becomes truly continuous!
13

Continuous Random Variables


Probability that a student selected at random spends
more than 10 minutes in library; P(X 10)

Finding the actual probability values (areas): using geometry


0.062

0.04

0.02

0.062

0.04

0.02

Area I = 0.5*3*(0.04+0.058) = 0.147


Area II= 0.5*15*(0.058+0.018) = 0.57

Area III = 0.5*13*0.018 = 0.12


Total Area (required probability) = 0.834

14

Probability Density Function- CRV


Finding the actual probability values (areas):

Using Calculus

p( X a)

f ( x)dx

p ( X b)

f ( x)dx

p( X c) f ( x)dx
c

15

Continuous Probability Distributions

Probability Density Function- CRV


Finding the actual probability values (areas):

Using Calculus

p( X d ) f ( x)dx
d

p(a X b) f ( x)dx
a

16

Probability Density Function- CRV


Complete definition of the continuous probability
density function
If X is a continuous random variable X,
Then the continuous pdf for X, defined over the set of all real
numbers R, is
1.

f ( x) 0

2.

f ( x)dx 1

3.

p(a X b) f ( x)dx
a
17

Continuous Probability Distributions

Probability Density Function- CRV


Frequently asked questions (FAQs)
1. Is the continuous probability density function always
bell-shaped?
2. Which is better for finding the probability of a
continuous random variable (i.e., area under curve):
- geometry, or calculus?
3. Can density functions be expressed in equation form?

18

Probability Density Function- CRV


Answers
1. Continuous probability density functions may take one of
several possible forms, such as those shown

2. If you know the equation of the density function, then it is always


better to use Calculus. If however, the equation of the density
function is not known, then geometry would be more appropriate.
3. Like discrete probability distribution functions, a continuous
probability density function may be expressed as a graph, or
equation.
19

Probability Density Function- CRV


Example
A certain parameter for the reaction temperature in a certain
controlled lab experiment is a continuous random variable X
having the following probability density function:
x2/3

when 1<x<2

otherwise

f(x) =

Find the probability that the parameter takes any value between
0 and 1.
1

Answer:

p(0 X 1)
0

x
x 1 1
dx
|0
3
9
9

20

Uniform CRV Density Curve


A continuous rv X is said to have a uniform
distribution on the interval [A, B] if the pdf of X
is

21

Uniform CRV Density Curve


Example:

CE 835 - Probability and Statistics

22

Example: CRV - Time Spent Waiting for Bus


Bus arrives at stop every 10 minutes. Person arrives at
stop at a random time, how long will s/he have to wait?
X = waiting time until next bus arrives.
X is a continuous random variable over 0 to 10 minutes.
Note: Height is 0.10
so total area under the
curve is (0.10)(10) = 1

This is a uniform
distribution,
thus
area of rectangle =
wxh

This is an example of a Uniform Random Variable


Density Curve
23

Example: Waiting for Bus (cont..)


What is the probability the waiting time X was between 5
to 7 minutes?
Probability = area under curve between interval 5 and 7
= (base)(height) = (2)(.1) = .2
P(aXb) is the
area under the
density curve over
the
interval
between values a
and b

24

CRV

Probability assigned to any particular value is zero, and


the probability of an interval does not depend on
whether either of its endpoints are included.

These properties follow from the facts that the area


under the graph of f (x) and above the single value c is
zero and that the area under the graph above an interval
is unaffected by exclusion or inclusion of the endpoints
of the interval.
25

Continuous Probability Distributions

Cumulative Distribution for Continuous


Density Functions
The cumulative distribution function (cdf)
F(x) for a discrete rv X gives, for any specified
number x, the probability P(X x). It is
obtained by summing the pmf p(y) over all
possible values of y satisfying y x.
The cdf of a continuous rv gives the same
probabilities P(X x) and is obtained by
integrating the pdf f(y) between the limits -
and x.
26

Continuous Probability Distributions

Cumulative Distribution for Continuous Density


Functions
Cumulative distribution tables and graphs are
obtained for density functions in the same way as
they are obtained for discrete probability
distributions.
The cumulative distribution equation for the two cases
is however different:
In the discrete case, the summation sign is used,
whereas for the continuous case the integral sign is
used
27

Continuous Probability Distributions

Cumulative Distribution for Continuous


Density Functions
The cumulative distribution F(x) of a
continuous random variable X with density
function f(x) is:
x

F ( x) p ( X x)
f(x)

f ( x)dx

28

Cumulative Distribution for Continuous


Density Functions
pdf

cdf

For each x, F(x) is the area under the density


curve to the left of x. As illustrated in figure
where F(x) increases smoothly as x increases.
29

Cumulative Distribution for Continuous


Density Functions
Survey Results : Duration of Fast Food Visit
Cumulative Probability Density Table for Time
Spent in Fast Food Restaurant
Time Spent
(minutes)

Frequency

Relative Frequency
(probability)

Cum Prob

<0
0+ to 5
5+ to 10
10+ to 15
15+ to 20
20+ to 25
25+ to 30
30+ to 35

0
1
3
4
6
3
2
1

0
0.05
0.15
0.2
0.3
0.15
0.1
0.05

0
0.05
0.2
0.4
0.7
0.85
0.95
1

30

Cumulative Distribution for Continuous


Density Functions
Survey Results : Duration of Fast Food Visit
Cumulative Probability Density Curve for Time
Spent in Fast Food Restaurant
Cumulative Probability

1
0.8
0.6
0.4

0.2
0
0

10

20
30
Time Spent (Minutes)

40
31

Cumulative Distribution for Continuous


Density Functions

0.35
0.3
0.25
0.2
0.15
0.1
0.05
0
0

20
Time Spent (Minutes)

Density function, f(x)

40

Cumulative Probability

Relative Freq (probability)

The difference between density function and cumulative


distribution function, for continuous random variables
1
0.8
0.6
0.4
0.2
0
0

20
40
Time Spent (Minutes)

Cumulative distribution
function, F(x)

32

Cumulative Distribution for Continuous Density


Functions
How to calculate probability ranges from
cumulative continuous distributions
P(a<X<b) = F(b) F(a)
F(b)

F(a)
P(a<X<b)

33

Cumulative Distribution for Continuous


Density Functions - Example
Let X, the thickness of a certain metal sheet,
have a uniform distribution on [A, B].
pdf

34

Cumulative Distribution for Continuous


Density Functions - Example
The density function is shown in Figure. 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.
pdf

CE 835 - Probability and Statistics

35

Cumulative Distribution for Continuous Density


Functions - Example
For A x B

pdf

cdf

36

Using F(x) (cdf) to Compute Probabilities


Let X be a continuous rv with pdf f(x) and
cdf F(x). Then for any number a,
P(X > a) = 1 - F(a)
and for any two numbers a and b with a < b,
P(a X b) = F(b) - F(a)
P(a X b) = F(b) - F(a)

CE 835 - Probability and Statistics

37

Using F(x) (cdf) to Compute Probabilities


Example

pdf

cdf
38

Using F(x) (cdf) to Compute Probabilities


Example

39

Using F(x) (cdf) to Compute Probabilities


Example

40

Das könnte Ihnen auch gefallen