CP10_random - Random Processes Random or Stochastic...

Info iconThis preview shows pages 1–4. Sign up to view the full content.

View Full Document Right Arrow Icon
1 1 Random Processes Monte Carlo Simulation 2 Random or Stochastic processes Random or Stochastic processes You cannot predict from the observation of one event, how the next will come out Examples: Coin: the only prediction about outcome – 50% the coin will land on its tail Dice: In large number of throws – probability 1/6 3 Question: What is the most probable number for the sum of two dice? 12 11 10 9 8 7 | 6 11 10 9 8 7 6 | 5 10 9 8 7 6 5 | 4 9 8 7 6 5 4 | 3 8 7 6 5 4 3 | 2 7 6 5 4 3 2 | 1 6 5 4 3 2 1 36 possibilities 6 times – for 7 4 Applications for MC simulation Stochastic processes Complex systems (science) Numerical integration Risk management Financial planning Cryptography 5 How do we do that? You let the computer to throw “the coin” and record the outcome You need a program that generates randomly a variable … with relevant probability distribution Part 1 Random number generators
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
2 7 Sources of Random Numbers Tables Hardware (external sources of random numbers – generates random numbers from a physics process. Software (source of pseudorandom numbers) 8 Tables Most significant A Million Random Digits with 100,000 Normal Deviates by RAND 00000 10097 32533 76520 13586 34673 54876 80959 09117 39292 74945 00001 37542 04805 64894 74296 24805 24037 20636 10402 00822 91665 00002 08422 68953 19645 09303 23209 02560 15953 34764 35080 33606 00003 99019 02529 09376 70715 38311 31165 88676 74397 04436 27659 00004 12807 99970 80157 36147 64032 36653 98951 16877 12171 76833 00005 66065 74717 34072 76850 36697 36170 65813 39885 11199 29170 00006 31060 10805 45571 82406 35303 42614 86799 07439 23403 09732 00007 85269 77602 02051 65692 68665 74818 73053 85247 18623 88579 00008 63573 32135 05325 47048 90553 57548 28468 28709 83491 25624 00009 73796 45753 03529 64778 35808 34282 60935 20344 35273 88435 00010 98520 17767 14905 68607 22109 40558 60970 93433 50500 73998 00011 11805 05431 39808 27732 50725 68248 29405 24201 52775 67851 00012 83452 99634 06288 98083 13746 70078 18475 40610 68711 77817 00013 88685 40200 86507 58401 36766 67951 90364 76493 29609 11062 00014 99594 67348 87517 64969 91826 08928 93785 61368 23478 34113 ..... 9 http://www.toshiba.co.jp/about/press/2008_02/pr0702.htm 10 Software - Random Number Generators There are no true random number generators but pseudo RNG! Reason: computers have only a limited number of bits to represent a number It means: the sequence of random numbers will repeat itself (period of the generator) 11 Good Random Number Generators Other (still important) issues 1. independent of the previous number 2. long period 3. produce the same sequence if started with same initial conditions 4. fast Two important issues: 1. randomness 2. knowledge of the distribution. 12 Two basic techniques for RNG The standard methods of generating pseudorandom numbers use modular reduction in congruential relationships. Two basic techniques for generating uniform random numbers: 1. congruential methods 2. feedback shift register methods. For each basic technique there are many variations.
Background image of page 2
3 13 Linear Congruent Method for RNG Generates a random sequence of numbers { x 1 , x 2 , …x k } of length M over the interval [ 0,M-1 ] starting value x 0 is called “seed” coefficients a and c should be chosen very carefully note: ) , mod( 1 M c ax x i i + = M M b b M b * ) / int( ) , mod( = the method was suggested by D. H. Lehmer in 1948 M x i < 1 0 14 Example: a=4, c=1, M=9, x 1 =3 x 2 = 4 x 3 = 8 x 4 = 6 x 5-10 = 7, 2, 0, 1, 5, 3 M M b b M b M c ax x i i * ) / int( ) , mod( ) , mod( 1 = + = interval: 0-8, i.e. [0,M-1] period: 9 i.e. M numbers (then repeat) 15 Random Numbers on interval [A,B] Scale results from x i on [0,M-1] to y i on [0,1] Scale results from x i on [0,1] to y i on [A,B] i i x A B A y ) ( + = ) 1 /( = M x y i i 16
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 4
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 09/29/2009 for the course PHYSICS 811 taught by Professor Godunov during the Fall '09 term at Old Dominion.

Page1 / 13

CP10_random - Random Processes Random or Stochastic...

This preview shows document pages 1 - 4. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online