• Ei tuloksia

2.2 The basics of agent-based modeling

2.2.2 Agent-based modeling principles

When specifying an AB system, at least the following aspects presented in the table 5 must be captured (Wooldridge 1997, p. 26-37). Next, in the table 6 a standard proto-col for describing an AB model is presented (Grimm et al. 2006, p. 117-119).

Table 5. The key aspects to be specified in an AB model. (Adapted from Wooldridge 1997, p. 26-37)

Aspects to be speci-fied when specifying an AB system

Description

The beliefs agents have

Agents have some information about their environment. Firstly, information may be imperfect. Agents’ sensors may be faulty, information may be out of date, or agents’ can be deliberately given false information. Secondly, the information an agent has is not directly available to others, because agents do not share and do not have private access to data structures of other agents.

Thirdly, environment contains other agents, each having its own information about the environment.

The ongoing interac-tion between agents and their environment

Reactive systems do not terminate, so it is required that the reactive nature of agents is specified. This requires using logic, which is capable of reasoning ongoing behavior. The basic idea is that an agent’s behavior is described in ways that “if something happens, do something, and if something else hap-pens thereafter, then do something different”.

The goals that agents try to achieve

The behavior of agents is goal-directed. That does not mean that agents must explicitly generate and represent goals. Goals may be regarded as commit-ments or obligations as well. The goal-directed behavior does not necessarily mean that agents meet their goals, but their actions are directed by goals.

The actions that agents perform and the effects of these actions

Agents do not typically have full control over their environment. But they are able to influence their environment through actions, which means they may have reliable control over some portions of environment.

Table 6. A standard protocol for describing an AB model. (Adapted from Grimm et al. 2006, p. 117-119)

OVERVIEW

Purpose The purpose of a model has to be stated first. The purpose is the reason why a mod-el is made, what the core functionality is (what the modmod-el can do), and why some aspects of reality are included while others are ignored.

State vari-ables and scales

First, the full set of state variables should be described. State variables characterize low-level entities in a model, i.e. individuals or habitat units. Second, higher-level entities should be described, for example a population consisting of individuals. An important distinction between low-level state variables and auxiliary or aggregated variables has to be done: auxiliary variables are deduced from low-level entities and their low-level state variables. Low-level state variables describe elementary properties of the model’s entities. Auxiliary variables aggregate information from the model entities.

Finally, in addition to state variables, the numerical scales used should be stated.

These include length of time steps and time horizon, size of habitat cells (if the model is grid-based), and extent of the model world (if the model is spatially ex-plicit). Choosing a scale is a fundamental decision determining the overall design of a model. The dimensions must be clearly defined for all parameters and variables.

Process overview and sched-uling

A conceptual overview of individual and environmental processes should be given.

This is done by giving a verbal description of each process and its effects. Also, the scheduling of the model processes should be described. This deals with the order of processes and the order in which the state variables are updated.

DESIGN CONCEPTS

Design concepts provide a common framework for designing and communicating AB models. At least these design concepts should be described (if they are relevant in a model): (1) emergence:

which system-level phenomena emerge from individual traits, and which are imposed; (2) adap-tation: how do agents adapt their behavior in relation to other agents and environment; (3) fitness or objectives: how is goal-directed behavior being modeled; (4) prediction: how do agents pre-dict future conditions and how this affects their behavior; (5) sensing: what internal and environ-mental state variables are agents assumed to sense and consider in their adaptive decisions; (6) interaction: what kind of interactions among agents are assumed; (7) stochasticity: if stochastici-ty is part of the model, what are the reasons for this and how does it emerge; (8) collectives: are agents grouped into some sort of hierarchical groups; and (9) observation: how are data collected from the model for testing, understanding and analyzing?

DETAILS

Initializa-tion

This deals with questions as: how are environment and agents created at the start of a simulation run, and what are the initial values of state variables? Is initialization always the same or varied between runs? How were the initial values chosen?

Input The dynamics of many AB models are driven by some environmental conditions that change over time and space. Environmental conditions are referred as input to the model outputs, in other words, output gives the response of the model to the input. Thus, it is vital to specify, what inputs are used, how they are generated, and how they can be generated or obtained.

Submodels All submodels representing the processes described in the overview-stages are ex-plained in detail, including the parameterization of the model. As this usually re-quires a lot of space (dependent on the model), and mathematical expressions are harder to understand than verbal ones, it is meaningful to divide the explanations of submodels into two: the first is a “mathematical skeleton”, consisting only of equa-tions, rules and parameters, and their very short and simplified explanations. And the second is a full model description, presented in the very same structure as the mathematical skeleton, but including fully detailed verbal explanations.

There are a few possibilities for designing agents technically. “The production sys-tem” is the simplest: it consists of a set of rules, a working memory and a rule inter-preter. Rules consist of two parts: a condition, which specifies when the rule is exe-cuted; and an action part, which determines what happens when the rule is executed.

The working memory keeps track of an agent’s state, which may affect its behavior.

The rule interpreter considers each rule in turn, fires those whose conditions are met, performs related actions, and repeats this cycle indefinitely. Though the production system is a simple concept, by using it, it is relatively easy to build reactive agents that respond to stimuli from the environment with some action. In the production sys-tem agents have potential to learn about their environment and from the other agents by adding knowledge to their working memories. However, the rules always remain unchanged. By using adaptive algorithms, it is possible to change agents’ rules, which simulates learning in a more fundamental level. In addition, agents are almost always modeled as operating in some environment that consists of a network of inter-actions with other agents. Sometimes, it is also useful to model a physical environ-ment that imposes constraints on the agents’ location. (Gilbert et al. 2000, p. 62-63)

One key question regarding modeling is: how can we say that the modeled results are believable? And this question yields a few key sub-questions to be answered: what is the correct level of resolution in a model; does a certain modeled behavior explain an observed pattern in the real world; and how do we cope with uncertainty regarding model parameters? These questions can be answered by applying the so called pat-tern-oriented modeling methodology:

1. Finding the correct level of resolution in a model is done by observing multi-ple patterns in the real world, and designing the model based on these pat-terns. This makes the model structurally more realistic, i.e. its ability to pro-duce independent predictions that match observed patterns is increased.

2. To determine whether a certain modeled behavior explains an observed be-havior in the real world, it is needed to formulate alternative theories, which all are being modeled. If a theory being modeled is incapable of producing

realistic results, it is rejected. If a theory can produce realistic results in mod-eling, it is much more likely to be the right theory, as alternative explanations are rejected.

3. Uncertainty regarding model parameters is reduced by making the model structurally more realistic (the first point), and this helps parameters to inter-act in ways similar to real mechanisms. It is therefore possible to test whether different parameter sets can produce all the patterns observed in the real world. If a parameter set cannot produce all the observed patterns, it is ruled out. All the parameter sets, which are able to produce realistic results, are ac-cepted and thus, uncertainty regarding parameters is reduced. (Grimm et al.

2005, p. 987-991)