Download 1 STAT 370: Probability and Statistics for y Engineers [Section 002]

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts

History of statistics wikipedia , lookup

Probability wikipedia , lookup

Statistics wikipedia , lookup

Transcript
North Carolina State University
STAT 370: Probabilityy and Statistics for
Engineers
[Section 002]
Announcements
• HW 9 (continuous R.V., 10pt) due Friday Mar 30 @
6PM
• Midterm 2 (100 pts) on Apr 2 (Learning Objectives
posted on course website; ignore H7-H11)
• No class on Apr 4 (Enjoy the spring holiday!)
Instructor: Hua Zhou
Harrelson Hall 210
11:45AM-1:00PM, Mar 28, 2012
Plan
Last time:
Discrete RV, Binomial distribution (pmf, mean/variance)
Today:
• Remark on Quiz 4 (always read problem carefully)
• Continuous random variable (pdf, cdf, mean/variance)
Continuous Random Variables
• A continuous random variable is a random variable that
takes on an uncountable number of possible values. (It takes
values in intervals).
Eg: The speed off the next car that passes the state trooper
(continuous, takes values greater than zero).
• Can take on any value in a given interval
– Examples: height, weight, length, mass, temperature,
concentration
1
Probability density function (PDF)
Remarks on PDF
• The probability density function (pdf) f(x) defines the
distribution of a continuous RV by giving probability over an
interval:
• f(x) can be greater than 1 but integral over any (a,b): can
only be 0 ≤ P(a ≤ X ≤ b) ≤ 1;
b
P (a  X  b) 
 f ( x ) dx
a
• Necessary and sufficient conditions for f(x) to be a PDF
1. f(x) has to be nonnegative: f(x)>=0;
( ) is 1:
2. Total area under the curve f(x)
• Don’t need to worry about “ < “ or “ ≤ “ when
we talk about probability of a continuous RV:
a
P( X  a)  P(a  X  a)   f ( x)dx  0
a

 f ( x)dx  1

and area under the curve for a specific interval (a,b) is
the probability for the interval.
One key difference between continuous and discrete RV
is that in the continuous case there is no probability at a
point; positive probability is only given to intervals. For
discrete RV …..
Example: Uniform distribution
• Uniform distribution on interval [0,1]
• PDF: f(x) = 1 if 0<=x<=1
f(x) = 0 otherwise
• Verify it is a PDF.
• Calculate P(1/2<=X<=3/4)
Example
• Consider X to be a continuous RV with pdf given by:
f(x) = 2x, 0 ≤ x ≤ 1
= 0 otherwise
i) Verify that f(x) is indeed a pdf
1) f(x) is nonnegative for 0 ≤ x ≤ 1
2) it integrates to 1



1
f ( x)dx
d   2 xdx
d  x2
ii) Calculate P(1/4<=X<=2/3)
1
0
1
0
2/ 3
P(1/ 4  X  2/ 3) 
 2xdx  4/ 9 1/16  55/144
1/ 4
2
In class exercise
Home exercise
Let
• Assume X ~ has the pdf given by
 x
f ( x)  
x
•
•
•
•
-1  x  0
0  x 1
Show this is a valid density function
Compute P (  1/ 4  X  1/ 8)
Calculate the mean and variance of X;
Find the cdf of X, F (t )  P( X  t ) , for all t
3 2
 x
f (x)   2
 0
Example
• Assume X ~ has the pdf given by
 x
f ( x)  
x
F : (, )  [0,1]
[0 1]
is defined as
F (t )  P ( X  t ) 
t

otherw ise
a) Show that f(x) is a valid pdf for some RV X
b) Compute P(0<X<1/2)
c) Compute P(-1/2<X<1/2)
d) Compute the CDF F(t)=P(X ≤ t) for all t and draw its
graph.
g
p
e) Compute E(X) and Var(X)
Cumulative Distribution Function (CDF)
• Consider a continuous RV, X with PDF given by f(x) .
The cumulative distribution function F(t)
-1  x  1
-1  x  0
0  x 1
f ( x ) dx

Necessary and
N
d sufficient
ffi i t conditions
diti
ffor F(t) to
t be
b CDF:
CDF
1. F (  )  0; F (  )  1
2. 0  F ( t )  1
3. Non-decreasing function
•
•
•
•
Show this is a valid density function
Compute P (  1/ 4  X  1/ 8)
Calculate the mean and variance of X;
Find the cdf of X, F (t )  P( X  t ) , for all t. Draw its graph.
3
Example
Relationship between CDF and PDF
Given two independent RVs: Y and Z, both are Uniform
on [0,1]. Consider the RV, X=max(Y,Z), which is the
maximum of Y and Z
• Remark:
We integrate f(x) to get F(x). The fundamental theorem
of calculus says that if we differentiate F(x) we get f(x).
f(x)
What is the CDF of X?
F (t )  0 if t  0
=t 2 if 0  t  1
=1 if t  1
What is the PDF of X?
Mean and variance of a continuous RV with pdf f(x)
• Mean of a continuous RV:
• For continuous RV X with pdf f(x)=2x if 0 ≤ x ≤ 1
=0 otherwise,

  E(X ) 

xf ( x )dx
• Mean

• Variance of a continuous RV

 Var ( X ) 
 (x  EX )
2
f ( x)dx




x f ( x)dx  ( EX )
Var ( X ) 



 EX
2
2
 (EX )
1
 xf ( x)dx   2 x dx  2 / 3
2

• Variance

2

E( X ) 

2
Example
0
1
x 2 f ( x )dx  (2 / 3) 2   2 x 3dx  4 / 9  1 / 18
0
2
4
In class exercise
Home exercise
The pdf of a random variable X is given by
x0
0
x
0  x 1

f ( x)  
2  x 1  x  2
0
2 x
Consider a random variable with cumulative distribution
function
x0
0
1/ 2
0  x 1

F(x)  
1 x  2
3/ 4
1
x2
a) Graph the function
b) Compute P ( X  1 .55 )
c) Compute E(X).
• Find mean, variance, and CDF of X
Home exercise
Consider a random variable with cumulative distribution
function
0
 2
x / 2
F ( x)  
2
2 x  ( x / 2)  1
1

x0
0  x 1
1 x  2
x2
a) Graph the function
b) Compute
C
t P ( X  1 .55 )
c) Compute E(X) and Var(X)
5