260 likes | 382 Vues
IENG 217 Cost Estimating for Engineers. Project Simulation. A 1 A 2. 10,000. Simulation. Let us arbitrarily pick a value for A 1 and A 2 in the uniform range (5000, 7000). Say A 1 = 5,740 and A 2 = 6,500. A 1 A 2. 5,740 6,500. 10,000. 10,000. Simulation.
E N D
IENG 217Cost Estimating for Engineers Project Simulation
A1 A2 10,000 Simulation Let us arbitrarily pick a value for A1 and A2 in the uniform range (5000, 7000). Say A1 = 5,740 and A2 = 6,500.
A1 A2 5,740 6,500 10,000 10,000 Simulation NPW = -10,000 + 5,740(1.15)-1 + 6,500(1.15)-2 = (93.96)
A1 A2 5,740 6,500 10,000 10,000 Simulation We now have one realization of NPW for a given realization of A1 and A2.
A1 A2 5,740 6,500 10,000 10,000 Simulation We now have one realization of NPW for a given realization of A1 and A2. Choose 2 new values for A1, A2.
A1 A2 6,820 6,218 10,000 10,000 A1 = 6,820 A2 = 6,218 NPW = -10,000 + 6,820(1.15)-1 + 6,218(1.15)-2 = 632.14
Summary A1 A2 NPW 5,740 6,500 (93.96) 6,820 6,218 632.14 Choose 2 new values.
A1 A2 5,273 6,422 10,000 10,000 A1 = 5,273 A2 = 6,422 NPW = -10,000 + 5,273(1.15)-1 + 6,422(1.15)-2 = (558.83)
Summary A1 A2 NPW 5,740 6,500 (93.96) 6,820 6,218 632.14 5,273 6,422 (558.83) Choose 2 new values.
Summary A1 A2 NPW 5,740 6,500 (93.96) 6,820 6,218 632.14 5,273 6,422 (558.83) . . . 6,855 5,947 457.66
Freq. NPW -1,871 0 1,380 Simulation With enough realizations of A1, A2, and NPW, we can begin to get a sense of the distribution of the NPW.
Simulation What we now need is a formal method of selecting random values for A1 and A2 to avoid selection bias.
1/2,000 5,000 7,000 Simulation What we now need is a formal method of selecting random values for A1 and A2 to avoid selection bias. Recall the uniform f(x)
F(x) 0 , x 5 , 000 1 x 5 , 000 F ( x ) 2 , 000 1 , x 7 , 000 5,000 7,000 Simulation The uniform has cumulative distribution given by:
Simulation Recall that 0 < F(x) < 1. Using modulo arithmetic, it is fairly easy to generate random numbers between 0 and 1 (Rand Function in Excel). Let P be a random variable uniformly from 0 to 1. P U(0,1)
Simulation Recall that 0 < F(x) < 1. Using modulo arithmetic, it is fairly easy to generate random numbers between 0 and 1. Let P be a random variable uniformly from 0 to 1. P U(0,1) Algorithm: 1. Randomly generate P 2. Let P = F(x) 3. Solve for x = F-1(p)
F(x) 1 x 5 , 000 F ( x ) 2 , 000 5,000 7,000 Simulation 1. Randomly generate P U(0,1). P = .7 5,000 < x < 7,000
F(x) 1 x 5 , 000 F ( x ) 2 , 000 5,000 7,000 Simulation 1. Randomly generate P U(0,1). P = .7 2. Let P = F(x). .7 5,000 < x < 7,000
F(x) 1 x 5 , 000 F ( x ) 2 , 000 5,000 7,000 Simulation 1. Randomly generate P U(0,1). P = .7 2. Let P = F(x). 3. x = F-1(p). .7 5,000 < x < 7,000 6,400
x 5 , 000 F ( x ) 2 , 000 x 5 , 000 P F(x) 7 , 000 5 , 000 1 x 5 , 000 2 , 000 5,000 7,000 Formal Derivation Recall, for 5,000 < x < 7,000. Then P
F(x) x 5 , 000 2 , 000 P 1 5,000 7,000 Formal Derivation Solving for x = F-1(p), P Note: 1. P = 0 x = 5,000 2. P = 1 x = 7,000 x
A1 A2 A3 7,000 ( x 1 , 000 ) / 3 , 000 F ( x ) 1 e Class Problem You are given the following cash flow diagram. The Ai are iid shifted exponentials with location parameter a = 1,000 and scale parameter = 3,000. The cumulative is then given by , x > 1,000
A1 A2 A3 7,000 ( x 1 , 000 ) / 3 , 000 F ( x ) 1 e Class Problem You are given the first 3 random numbers U(0,1) as follows: P1 = 0.8 P2 = 0.3 P3 = 0.5 You are to compute one realization for the NPW. MARR = 15%.
x 1000 P 1 e 3000 x 1000 e 3000 1 P x 1000 ln( 1 P ) 3000 x 1 , 000 3 , 000 ln( 1 P ) Class Problem
x 1 , 000 3 , 000 ln( 1 P ) Class Problem A1 = 1,000 - 3000 ln(1 - .8) = 5,828 A2 = 1,000 - 3000 ln(1 - .3) = 2,070 A3 = 1,000 - 3000 ln(1 - .5) = 3,079
5,828 3,079 2,070 7,000 Class Problem NPW = -7,000 + 5,828(1.15)-1 + 2,070(1.15)-2 + 3,079(1.15)-3 = 1,657