16sample - 2. Let x ( n ) ∼ N (0 . 1 , . 0004) ⇔ E [ x...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
EECS 501 EXAMPLES OF SAMPLE FUNCTIONS Fall 2001 EX #1: To generate sample functions x ( n ) of a Bernoulli process with p=0.6: 1. Spin a wheel of fortune once , resulting in a number ω o [0 , 1). 2. Let ω o have decimal expansion 0 .w 1 w 2 w 3 w 4 w 5 . . . where w i = 0 , 1 . . . 9. 3. Set x ( n )=1 if w n =0,1,2,3,4 or 5 and x ( n )=0 if w n =6,7,8 or 9. ω o = 0.141592653589793 . . . → { x ( n ) } = { 1,1,1,1,0,1,0,1,1,1,0,0,0,0,1 . . . } . ω o = 0.718281828459045 . . . → { x ( n ) } = { 0,1,0,1,0,1,0,1,0,1,1,0,1,1,1 . . . } . 1. Di±erent sequence of 0’s and 1’s associated with each ω o Ω=[0,1). Each sequence is a sample function of the Bernoulli random process. 2. Digits independent of each other (if ω o irrational); Pr[x(n)=1]=0.6. 3. Pr[ ω o irrational]=1 so this almost surely works (need precision). EX #2: Monte Carlo simulation of compounded rate of return on investments: 1. Let x ( n ) be the annual rate of return on investments in year 2000+n.
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: 2. Let x ( n ) ∼ N (0 . 1 , . 0004) ⇔ E [ x ( n )] = 10% (historical average). 3. Con²dence limits or intervals (see pp. 275-280 and recitation) are: Pr [8% < x ( n ) < 12%] = 67%; Pr [6% < x ( n ) < 14%] = 95%. 4. Let y ( n ) = p n i =1 (1+ x ( i )). Assume x ( n ) iidrvs. Then E [ y ( n )] = (1 . 1) n . 5. Generate 10 sample functions of x ( n ) (Matlab’s randn ) and y ( n ). Results plotted below. Curves are di±erent sample functions of y ( n ). • Note that the actual return can vary greatly from the expected return! So don’t plan on retiring too quickly! “Your performance may vary. ..” 10 20 30 40 20 40 60 #years invested since 2000 value of $1 invested...
View Full Document

This note was uploaded on 07/22/2011 for the course EECS 370 taught by Professor Lehman during the Spring '10 term at University of Florida.

Ask a homework question - tutors are online