3.2. Sectors
49
HUMPBACK WHALE SAND LANCE MODEL
S(t) = S(t-dt) + (S_DOT) * dt
INIT S = 100
INFLOWS:
S_DOT = R*S-A*W*S
W(t) = W(t-dt) + (W_DOT) * dt
INIT W = 200
INFLOWS:
W_DOT = F*A*W*S*(K-W)/K -Q*W
A = .004
F = .1
K = 400
Q = . 03
R = .8
3.2. Sectors
As a model becomes large and complicated, it will be prudent to keep the
model components neatly arranged. After all, you are using a graphically
based programming language in part to maintain transparency of your
model structure and assumptions. One useful feature to help you keep
things organized is the ghost mentioned in Chapter 2. Generate a ghost of
the stock W'; place it next to the flow S DOT, dynamite the connection from
the original stock W to S DOT and substitute a new connection from the
ghosted Wto the flow. Proceed similarly for a specification of W DOT Also,
make a ghost of the parameter A and connect that ghost , instead of the
original, to W DOT Now the two populations appear as separate submodels, or modules, yet they are inherently connected via the ghosts .
Another tool that is useful to keep your model organized is the Sector,
which provides the means to separate different modules. The "Sector" icon
is located in the main STELLA menu (Figure 3.5). Select it and drag it over
the whale submodule, and call it Whales. You can drag or position the
edges of the border such that it contains all those sections of the model you
wish to contain in a particular sector. Repeat the process for the sand lance
module.
FIGURE 3.5
O oJfQ)
Précédent

- 66/461

Suivant