Random Variate Generation R.B. Lenin (rblenin@daiict.ac.in) Autumn 2007 R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 1 / 46
Outline Random Variates 1 Introduction General methods Inverse method 2 Inverse method – continuous case Uniform random variate Exponential random variate Weibull random variate Triangle random variate Inverse method – discrete case Geometric random variate Convolution Method 3 Binomial random variate Erlang random variate Poisson random variate Composition Method 4 Hyperexponential random variate Acceptance-Rejection Method 5 Gamma random variate Normal random variate Log-normal random variate R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 2 / 46
Random Variates Introduction Random variates The outcome of simulation of a random variable according to a given distribution law is called a random variate . R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 3 / 46
Random Variates Introduction Random variates The outcome of simulation of a random variable according to a given distribution law is called a random variate . The procedure of simulating a random variable is called random variate generation . R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 3 / 46
Random Variates Introduction Random variates The outcome of simulation of a random variable according to a given distribution law is called a random variate . The procedure of simulating a random variable is called random variate generation . Random variate generation refers to the generation of variates whose probability distribution is different from that of the uniform on the interval [0 , 1]. R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 3 / 46
Random Variates General methods General methods Inverse transform method Continuous case Discrete case R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 4 / 46
Random Variates General methods General methods Inverse transform method Continuous case Discrete case Convolution method R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 4 / 46
Random Variates General methods General methods Inverse transform method Continuous case Discrete case Convolution method Composition method R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 4 / 46
Random Variates General methods General methods Inverse transform method Continuous case Discrete case Convolution method Composition method Acceptance-rejection method R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 4 / 46
Random Variates General methods General methods Inverse transform method Continuous case Discrete case Convolution method Composition method Acceptance-rejection method Polar coordinate method R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 4 / 46
Inverse method Inverse method – continuous case Inverse method – continuous case Let U be a uniform random variable in [0 , 1]. R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 5 / 46
Inverse method Inverse method – continuous case Inverse method – continuous case Let U be a uniform random variable in [0 , 1]. For any continuous distribution function F , the random variable X defined by X = F − 1 ( U ) has distribution F . R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 5 / 46
Inverse method Inverse method – continuous case Inverse method – continuous case Let U be a uniform random variable in [0 , 1]. For any continuous distribution function F , the random variable X defined by X = F − 1 ( U ) has distribution F . F − 1 ( u ) is defined to be that value of x such that F ( x ) = u . R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 5 / 46
Inverse method Inverse method – continuous case Inverse method – continuous case · · · Let F X denote the distribution function of X . Proof: We have to show that F X = F . F X ( x ) = Pr { X ≤ x } Pr { F − 1 ( U ) ≤ x } = Pr { F ( F − 1 ( U ) ≤ F ( x ) } = = Pr { U ≤ F ( x ) } = F ( x ) R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 6 / 46
Inverse method Inverse method – continuous case Inverse method – continuous case · · · Let F X denote the distribution function of X . Proof: We have to show that F X = F . F X ( x ) = Pr { X ≤ x } Pr { F − 1 ( U ) ≤ x } = Pr { F ( F − 1 ( U ) ≤ F ( x ) } = = Pr { U ≤ F ( x ) } = F ( x ) A sample value of x of X is simulated as follows: R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 6 / 46
Inverse method Inverse method – continuous case Inverse method – continuous case · · · Let F X denote the distribution function of X . Proof: We have to show that F X = F . F X ( x ) = Pr { X ≤ x } Pr { F − 1 ( U ) ≤ x } = Pr { F ( F − 1 ( U ) ≤ F ( x ) } = = Pr { U ≤ F ( x ) } = F ( x ) A sample value of x of X is simulated as follows: Generate a uniform random number r in [0 , 1]. R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 6 / 46
Inverse method Inverse method – continuous case Inverse method – continuous case · · · Let F X denote the distribution function of X . Proof: We have to show that F X = F . F X ( x ) = Pr { X ≤ x } Pr { F − 1 ( U ) ≤ x } = Pr { F ( F − 1 ( U ) ≤ F ( x ) } = = Pr { U ≤ F ( x ) } = F ( x ) A sample value of x of X is simulated as follows: Generate a uniform random number r in [0 , 1]. Set x = F − 1 ( r ) R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 6 / 46
Inverse method Inverse method – continuous case Inverse method – continuous case · · · The steps involved in using the inverse transform method in practice are R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 7 / 46
Inverse method Inverse method – continuous case Inverse method – continuous case · · · The steps involved in using the inverse transform method in practice are Given:- The CDF F X ( x ) or the PDF f X ( x ): 1 R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 7 / 46
Inverse method Inverse method – continuous case Inverse method – continuous case · · · The steps involved in using the inverse transform method in practice are Given:- The CDF F X ( x ) or the PDF f X ( x ): 1 If f X is given, then first integrate it to get F X . R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 7 / 46
Inverse method Inverse method – continuous case Inverse method – continuous case · · · The steps involved in using the inverse transform method in practice are Given:- The CDF F X ( x ) or the PDF f X ( x ): 1 If f X is given, then first integrate it to get F X . Generate a uniform random number r in [0 , 1]. 2 R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 7 / 46
Inverse method Inverse method – continuous case Inverse method – continuous case · · · The steps involved in using the inverse transform method in practice are Given:- The CDF F X ( x ) or the PDF f X ( x ): 1 If f X is given, then first integrate it to get F X . Generate a uniform random number r in [0 , 1]. 2 Set F X ( x ) = r and solve for x . 3 R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 7 / 46
Inverse method Inverse method – continuous case Inverse method – continuous case · · · Figure: Inverse method – continuous case R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 8 / 46
Inverse method Inverse method – continuous case Inverse method – continuous case · · · Example Let X be a random variable having distribution function F X ( x ) = x n , 0 < x < 1 . R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 9 / 46
Inverse method Inverse method – continuous case Inverse method – continuous case · · · Example Let X be a random variable having distribution function F X ( x ) = x n , 0 < x < 1 . Let r be a uniform random number from [0 , 1]. Then F X ( x ) = r ⇒ x n = r 1 ⇒ x = r n . R.B. Lenin (rblenin@daiict.ac.in) () Random Variate Generation Autumn 2007 9 / 46
Recommend
More recommend