Lesson 2 - Introduction to Scenario Modeling
Although scenario modeling is conceptually simple to understand, actually using the feature in the software is somewhat complex, as your model will be storing multiple sets of inputs and results, and you must take care to clearly understand what is being displayed (and why) at any given time.
Therefore, before discussing the details of scenario modeling, in this Lesson, we will provide an overview of how the scenario modeling capability works. To do this, we will open and explore an existing model that uses scenarios. In subsequent Lessons, we will start with the same model (without scenarios) and add all of the scenario modeling features that we will briefly explore here.
The model can be found in the “Examples” subfolder of the “Basic GoldSim Course” folder you should have downloaded and unzipped to your Desktop. In that folder, open a model file named Example25_Basic_Scenarios.gsm.
The model looks like this:
This is a model of a pond that has an inflow rate and an evaporation rate. It is almost identical to an Example model that we looked at previously (Unit 11, Lesson 7).
The Inflow is defined as a probability distribution. If you double-click on it, and then press the Edit… button, you will see that the Inflow is specified as a Truncated Normal distribution. Note, however, that the Mean is linked to a Data element (named Mean_Inflow). The Inflow is resampled every day.
If you look at the Simulation Settings (the Monte Carlo tab), you will note that the model is specified to run for 1000 realizations.
As we shall see momentarily, within this model, we have already defined three different scenarios. Before we explore the model any further, however, let’s take a step back and discuss what exactly we mean by the term “scenario”.
In GoldSim, a scenario is a specific set of input data (and corresponding outputs) for a model. When modeling scenarios, multiple scenarios will be defined within a model. Different scenarios within a model are specifically differentiated by having different values for one or more Data elements. These elements are referred to as Scenario Data. Scenario Data element actually have a different appearance in GoldSim: the “pencil” in the icon is orange (instead of green):
In this model, you will note that both Mean_Inflow and Evaporation_Rate are Scenario Data.
It is important to understand that the only elements that can differ between scenarios in a model are Data elements. Of course, not all Data elements in a model will actually differ between scenarios. In most cases (i.e., anything other than very simple models), you will define a subset of the model’s Data elements as being Scenario Data.
You can view a list of defined scenarios in a model in the Scenario Manager. The Scenario Manager can be accessed from the main menu (Run|Scenario Manager…) or by pressing F7. There is also a toolbar button for the Scenario Manager:
Open the Scenario Manager for the model now:
You will see that this model has three scenarios defined. Each scenario has a Scenario Name and a Scenario Description.
Note: If your screen does not look exactly like this (in particular, if under the Action column it does not say "Delete Results"), press the Run All button now and then close the dialog.
Of course, simply creating and naming a scenario is of no value if you do not specify the Scenario Data for each scenario (i.e., the specific Data elements that differentiate the scenarios). We can see the Scenario Data for this model by pressing the Scenario Data… button in the Scenario Manager dialog:
Each row in this dialog represents a Scenario Data element. Each column represents a scenario. In this model, there are two Scenario Data elements (i.e., both of the Data elements in the model have been defined as Scenario Data). This model has three scenarios, and all three are represented as columns in the table (there is an additional column here called “Live Model” that we will discuss in a subsequent Lesson).
We will discuss in detail how to create scenarios, specify which inputs are Scenario Data, and define the values for the various Scenario Data elements in the next Lesson. For now, it is sufficient to note that GoldSim provides a mechanism for you to specify multiple values for the Data elements defined as Scenario Data (i.e., one for each scenario) and this provides the mechanism for creating different scenarios. This table provides a clear definition of what each scenario represents, since it displays all Scenario Data values for all defined scenarios side-by-side.
Close the Scenario Data and Scenario Manager dialogs so we can look at some results. This particular model already has results for all three scenarios. In fact, this model is in a special mode that we have not seen before. Previously, we have seen models in Edit Mode and Result Mode. We also briefly saw a model in Pause Mode when a simulation was interrupted. (Models can also be in Run Mode, but the models we have looked at in this Course run so quickly that they probably would not have been in that mode long enough for you to notice). This model, however, is in a new mode we have not seen before: Scenario Mode.
The fact that the model is in Scenario Mode is indicated in lower left-hand corner of the GoldSim screen in the Status bar (which is orange):
Scenario Mode can be thought of as a special type of Result Mode that allows scenario results to be displayed and compared (and we will discuss how you enter this mode in subsequent Lessons). For now, it is sufficient to understand that it is the way in which you can view and compare the results from multiple scenarios. Although it is similar to Result Mode, it has some special restrictions. In particular, when in Scenario Mode, scenario results can only be viewed in Time History Result elements and Distribution Result elements. No other results are available.
This particular model has both a Time History Result element and a Distribution Result element. Double-click on the Time History Result element now:
What are we looking at here? Is this the output of three different elements? No. It is the output of a single element (Pond) for three different scenarios. You can see this by viewing Result Properties dialog (by pressing the Edit Properties button):
The dialog shows that only a single output is being displayed:
What this should make clear is that in Scenario Mode, when you view a Result element, it displays the results for all of the scenarios (for which results are available) for each output. We can see the same thing if we double-click on the Distribution Result element:
This displays the distribution of the final value of the Pond element (i.e., at 100 days) for all three scenarios.
The purpose of this Lesson was simply to provide a quick overview of scenario modeling in GoldSim. Over the next several Lessons, we will start with a version of this same model (before any scenarios have been added), and walk through and discuss in detail how to create, define, run and compare scenarios.