Docsity

Lecture 5: Continuous Random Variables and Probability Distributions by Nasir M Mirza, Lecture notes of Mathematical Modeling and Simulation

Partial preview of the text

Download Lecture 5: Continuous Random Variables and Probability Distributions by Nasir M Mirza and more Lecture notes Mathematical Modeling and Simulation in PDF only on Docsity!

Lecture 5: Nasir M Mirza

6/23/2012 1

Monte Carlo Simulation

Room A-114,

Department of Physics & Applied Mathematics,

Pakistan Institute of Engineering & Applied Sciences,

P.O. Nilore, Islamabad

email: [email protected]

Dr. Nasir M Mirza

Lecture Six

Course: NE-

Continuous pdfs

Lecture 5: Nasir M Mirza

6/23/2012 2

Continuous Random Variables

Consider the scattering of a photon by an atom. The angle at which the

photon is scattered has values that are continuous between 0 and 180 o .

Given that x is a real continuous random variable that varies from minus

infinity to plus infinity. Then cumulative distribution is defined as

0

( ) ( )   dx

dF x f x

  • F(x) = 0 for all x< 0. no sampling is

done, pdf = 0.

  • F(x) = x, for all 0 < x < 1

pdf = 1 in this interval.

  • F(x) = 0, for all x >1,

pdf = 0.

F(x) = P{ a random selection of X gives a value less than }

The probability density function (pdf) may be defined as

0.0 0.5 1.0 1.5 2.

0.

0.

0.

0.

0.

1.

1.

1.

III

F (x) II

x

Lecture 5: Nasir M Mirza

6/23/2012 4

Expectations of Continuous Random Variables

The mean value of a continuous random variable in an interval [a, b] is

Where, f(x) is the probability density function (pdf) for x. The normalization

condition is

The expected and variance value of any function of g(x) with this pdf are

b

a

b

a

x f x dx

E x xdF x

( )

( ) ( )

 

2 2 var{ g }  E ( g ) E ( g )

 (^ ) ^1  ()





f x dx F

E g g x f x dx

b

a

( ) (^)  ( ) ( )

Lecture 5: Nasir M Mirza

6/23/2012 5

Examples of Continuous Probability Distributions

UNIFORM DISTRIBUTION:

x a

x x a

F x x

 

  

 

1 ,

, 0

( ) 0 , 0

Average:  x  a / 2

Brief Calculations:

x a

a x a

F x x

Variance: var{ } / 12

2 xa

4 12

( )

var{ }

2 2

0

2

2 2

a a x f x dx

x x x

a   

   

0.0 0.5 1.0 1.5 2.

0.

0.

0.

0.

0.

1.

1.

1.

III

F (x) II

x

0.0 0.5 1.0 1.5 2. 0.

0.

0.

0.

0.

1.

F'(x)

x

Lecture 5: Nasir M Mirza

6/23/2012 7

Normal Probability Distribution Function

The average value:

The variance of x is

dx

x F x

x

  

0

2

2

exp 2

 

    





x x f ( x ) dx

2

2 2 var{ } ( ) ( )

 









x x f x dx x f x dx

2

2

exp 2

 

x F x

Lecture 5: Nasir M Mirza

6/23/2012 8

Cauchy or Lorentz Probability Distribution Function

The average value: improper integral diverges

The variance of x is infinite since the integral diverges no matter how it is

evaluated.

a

x F x

1 tan





x x f x dx

 









2 2 var{ x } x f ( x ) dx x f ( x ) dx

2 2

a x

a F x