Session #12
Monte-Carlo Simulation with Crystal Ball®
Page 1
Monte-Carlo Simulation with Crystal Ball®
To run a simulation using Crystal Ball®:
1. Setup Spreadsheet
Build a spreadsheet that will calculate the performance measure (e.g., profit) in terms of
the inputs (random or not). For random inputs, just enter any number.
2. Define Assumptions—i.e., random variables
Define which cells are random, and what distribution they should follow.
3. Define Forecast—i.e., output or performance measure
Define which cell(s) you are interested in forecasting (typically the performance
measure, e.g., profit).
4. Choose Number of Trials
Select the number of trials. If you would later like to generate the Sensitivity Analysis
chart, choose ―Sensitivity Analysis‖ under Options in Run Preferences.
5. Run Simulation
Run the simulation. If you would like to change parameters and re-run the simulation,
you should ―reset‖ the simulation (click on the ―Reset Simulation‖ button on the toolbar
or in the Run menu) first.
6. View Results
The forecast window showing the results of the simulation appears automatically after
(or during) the simulation. Many different results are available (frequency chart,
cumulative chart, statistics, percentiles, sensitivity analysis, and trend chart). The results
can be copied into the worksheet.
Crystal Ball Toolbar:
Session #12
Monte-Carlo Simulation with Crystal Ball®
Define
Assumptions Forecast
Define
Start
Page 2
Run
Forecast Trend
Preferences Simulation Simulation Window Chart
Reset
Session #12
Monte-Carlo Simulation with Crystal Ball®
Page 3
Walton Bookstore Simulation with Crystal Ball®
Recall the Walton Bookstore example: It is August, and they must decide
how many of next year’s nature calendars to order. Each calendar costs the
bookstore $7.50 and is sold for $10. After February, all unsold calendars are
returned to the publisher for a refund of $2.50 per calendar. Suppose
Walton predicts demand will be somewhere between 100 and 300 (discrete
uniform).
Demand
= d ~ Uniform[100, 300]
Order Quantity = Q (decision variable)
Revenue
Cost
Refund
Profit
= $10 * Min(Q, d)
= $7.50 * Q
= $2.50 * Max(Q–d, 0)
= Revenue – Cost + Refund
Step #1 (Setup Spreadsheet)
1234567891011121314151617ABCDEFSimulation of Walton's BookstoreDataUnit Cost =$7.50Unit Price =$10.00Unit Refund =$2.50Demand Distribution (Uniform)Minimum =100Maximum =300Decision VariableOrder Quantity =200SimulationDemandRevenueCostRefundProfit200$2,000.00$1,500.00$0.00$500.00151617BCDEFSimulationDemandRevenueCostRefundProfit200=C5*MIN(C13,B17)=C4*C13=C6*MAX(C13-B17,0)=C17-D17+E17
Session #12
Monte-Carlo Simulation with Crystal Ball®
Page 4
Walton Bookstore Simulation with Crystal Ball®
Step #2 (Define Assumptions—i.e., random variables)
Select the cell that contains the random variable (B17) — color code (blue):
and click on the ―Define Assumptions‖ button in toolbar (or in the Cell menu):
Select type of distribution:
Provide parameters of distributions:
1617BDemand2008910BCDemand Distribution (Uniform)Minimum =100Maximum =300
Session #12
Monte-Carlo Simulation with Crystal Ball®
Page 5
Walton Bookstore Simulation with Crystal Ball®
Step #3 (Define Forecast—i.e., output)
Select the cell that contains the output variable to forecast (F17):
click on the ―Define Forecast‖ button in toolbar (or in the Cell menu),
and fill in the Define Forecast dialogue box.
Step #4 (Choose Number of Trials)
Click on the ―Run Preferences‖ button in toolbar (or in the Run menu):
and select the number of trials to run.
1617FProfit$500.00
Session #12
Monte-Carlo Simulation with Crystal Ball®
Page 6
Walton Bookstore Simulation with Crystal Ball®
Step #5 (Run Simulation)
Click on the ―Start Simulation‖ button in toolbar (or Run in the Run menu):
Step #6 (View Results)
The results of the simulation can be viewed in a variety of different ways (frequency
chart, cumulative chart, statistics, and percentiles). Choose different options under the
View menu in the forecast window.
The results can be copied into a worksheet or Word document (choose Copy under the Edit
menu in the simulation output window.
Session #12
Monte-Carlo Simulation with Crystal Ball®
Page 7
Using Trend Charts to Find the Impact of Order
Quantity on Potential Profit
Define several forecast cells (G14:G18) for several possible order quantities (Q=100, 150,
200, 250, 300). Use the same random order quantity for each to compare them more
equally (i.e., one assumption cell for demand—C14—with the rest set equal to C14).
After running the simulation, choose ―Open Trend Chart‖ in the Run menu. This chart
gives ―certainty bands‖ for the forecast cells. 10% of the time, the project duration will
fall within the inner band (light blue), 25% of the time within the 2nd band (red), 50% of
the time within the third band (green), and 90% of the time within the outside band
(dark blue).
123456789101112131415161718ABCDEFGSimulation of Walton's BookstoreDataUnit Cost =$7.50Unit Price =$10.00Unit Refund =$2.50Demand Distribution (Uniform)Minimum =100Maximum =300SimulationOrder QuantityDemandRevenueCostRefundProfit100200$1,000.00$750.00$0.00$250.00150200$1,500.00$1,125.00$0.00$375.00200200$2,000.00$1,500.00$0.00$500.00250200$2,000.00$1,875.00$125.00$250.00300200$2,000.00$2,250.00$250.00$0.0012131415161718BCDEFGSimulationOrder QuantityDemandRevenueCostRefundProfit100200=$C$5*MIN(B14,C14)=$C$4*B14=$C$6*MAX(B14-C14,0)=D14-E14+F14150=$C$14=$C$5*MIN(B15,C15)=$C$4*B15=$C$6*MAX(B15-C15,0)=D15-E15+F15200=$C$14=$C$5*MIN(B16,C16)=$C$4*B16=$C$6*MAX(B16-C16,0)=D16-E16+F16250=$C$14=$C$5*MIN(B17,C17)=$C$4*B17=$C$6*MAX(B17-C17,0)=D17-E17+F17300=$C$14=$C$5*MIN(B18,C18)=$C$4*B18=$C$6*MAX(B18-C18,0)=D18-E18+F18
Session #12
Monte-Carlo Simulation with Crystal Ball®
Page 8
Project Management—Global Oil
Global Oil is planning to move their credit card operation to Des Moines,
Iowa from their home office in Dallas. The move involves many different
divisions within the company. Real estate must select one of three available
office sites. Personnel has to determine which employees from Dallas will
move, how many new employees to hire, and who will train them. The
systems group and treasurer’s office must organize the new operating
procedure and make financial arrangements. The architects will have to
design the interior space, and oversee needed structural improvements.
Each site is an existing building with sufficient open space, but office
partitions, computer facilities, furnishings, and so on, must all be provided.
A complicating factor is that there is an interdependence of activities. In
other words, some parts of the project cannot be started until other parts
are completed. For example, Global cannot construct the interior of an
office before it has been designed. Neither can it hire new employees until
it has determined its personnel requirements.
The necessary activities and their necessary predecessors (due to
interdependence) are listed below. Three estimates are made for the
completion time of each activity—the minimum time, most likely time, and
maximum time.
Activity
Description
Immediate
Predecessor Minimum Most Likely Maximum
Time Estimates (days)
Select Office Site
Create Org. & Fin. Plan
Determine Personnel Req.
Design Facility
Construct Facility
Select Personnel to Move
Hire New Employees
Move Key Employees
Train New Personnel
—
—
B
A, C
D
C
F
F
E, G, H
21
20
15
20
40
12
20
28
10
21
25
20
28
48
12
25
28
15
21
30
30
42
66
12
32
28
24
A
B
C
D
E
F
G
H
I