Page 79 - ExtendSim User Guide
P. 79

Simulation Concepts 53
Other modeling approaches
weather state is animated on the icon of the Weather Forecast block. It does this by showing different icon views, depending on the state. (For information about icon views, see page 573.)
Markov Chain Weather model
☞ The Markov Chain Weather model is located in the folder \Examples\Continuous\Standard Block Models.
Agent-based models
Most of the models discussed in this User Guide represent a system where the behavior of the components of the system are known or can be estimated in advance. With agent-based model- ing you usually do not know model dynamics in advance; instead, you obtain that information from the interaction of the agents in the model.
Agent-based models share the following characteristics:
• Theidentificationofindividualentitieswithinthemodel
• Asetofrulesthatgovernindividualbehavior
• The premise that local entities affect each other’s behavior
Agent-based modeling is concerned with individual entities (called “agents”) that interact with other agents within their specified locality. All the agents have a set of rules to follow but they also have a degree of autonomy such that model dynamics cannot be predefined. This is because agents can have intelligence, memory, social interaction, contextual and spatial aware- ness, and the ability to learn.
Programming for agent-based models
The agents used in agent-based modeling are programmed as ExtendSim blocks. Blocks and their enclosed data have unique searchable identities and locations within the model. Extend- Sim functions can find and send messages to blocks that have specific characteristics, loca- tions, and values. This makes it easy to create intelligent behavior, facilitate block-to-block interaction, and cause blocks to be moved in, added to, or removed from, a model.
The Developer’s Reference includes several categories of functions that are helpful when cre- ating agents for agent-based modeling:
• Scripting functions are used to build a new model or to add or remove blocks from an exist- ing model. They do this by creating, placing, and connecting blocks, then populating the blocks with specific data. These functions can be called from an ExtendSim block within the model or from an external application.
• Blockandinter-blockcommunicationfunctionsquerythestatusofablock–itstype,label, data, location, size, and connectivity with the rest of the model. They also get information about block dialog values and data table settings.
Tutorial


































































































   77   78   79   80   81