Ferramentas do usuário

Ferramentas do site


geopro:pedro:swarm

Diferenças

Aqui você vê as diferenças entre duas revisões dessa página.

Link para esta página de comparações

Ambos lados da revisão anteriorRevisão anterior
Próxima revisão
Revisão anterior
geopro:pedro:swarm [2007/07/09 18:59] pedrogeopro:pedro:swarm [2007/07/17 19:50] (atual) pedro
Linha 11: Linha 11:
 ^**Homepage**  | http://www.swarm.org/wiki/Main_Page | ^**Homepage**  | http://www.swarm.org/wiki/Main_Page |
 ^**Origin**    | Santa Fe Institute | ^**Origin**    | Santa Fe Institute |
-^**Year**      | 1994/1997 |+^**Year**      | 1996 |
 ^**Version**   | 2.2.3 | ^**Version**   | 2.2.3 |
 ^**License**   | GNU-GPL | ^**License**   | GNU-GPL |
Linha 25: Linha 25:
  
 How to compile swarm in ubuntu [[http://br.geocities.com/alves_aq/swarm.en.html|here]] How to compile swarm in ubuntu [[http://br.geocities.com/alves_aq/swarm.en.html|here]]
 +
 +[[http://www.humboldt.edu/~ecomodel/software.htm|EcoSwarm]]: Tools for Ecological Models in Swarm
 +
 +\\
 +==== The Swarm Simulation System: A Toolkit for Building Multi-agent Simulations====
 +|N. Minar, R. Burkhart, C. Langton, M. Askenazi, | [[http://leg.ufpr.br/~pedro/papers/swarm-intro.pdf|pdf]]| [[http://scholar.google.com.br/scholar?hl=pt-BR&lr=&cites=14912459563270754412| 246 citations in Scholar]] (the book) |
 +\\
 +
 +**Abstract:** Swarm is a multi-agent software platform for the simulation of complex adaptive
 +systems. In the Swarm system the basic unit of simulation is the swarm, a collection of agents executing a schedule of actions. 
 +Swarm supports hierarchical modeling approaches whereby agents can be composed of swarms of other agents in nested
 +structures. Swarm provides object oriented libraries of reusable components for building models and analyzing, displaying, and 
 +controlling experiments on those models.
 +
 +\\
 +
 +[...] collection of independent agents interacting via discrete events. [...] There are no domain 
 +specific requirements such as particular spatial environments, physical phenomena, agent representations, or interaction patterns. 
 +Swarm simulations have been written for such diverse areas [...]
 +
 +The basic unit of a Swarm simulation is the agent. An agent is any actor in a system,
 +any entity that can generate events that affect itself and other agents. Simulations consist
 +of groups of many interacting agents. [...] Simulation of discrete interactions between 
 +agents stands in contrast to continuous system simulations, where simulated
 +phenomena are quantities in a system of coupled equations.
 +
 +In addition to being containers for agents, swarms can themselves be agents. [...]
 +an agent can also itself be a swarm: a collection of objects and a schedule of actions. 
 +In this case, the agent's behavior is defined by the emergent phenomena of the agents inside 
 +its swarm. Hierarchical models can be built by nesting multiple swarms.
 +
 +Swarm has the following components:
 +  * **SwarmObject**: All agent classes inherit behavior from it. SwarmObject defines the basic interface for memory management as well as the support for probes.
 +  * **Swarm**: Model swarms and observer swarms are written by using code inherited from this base class.
 +  * **Activity**: defines the scheduling data structures and execution support.
 +  * **Simtools**: classes to control the execution of the entire simulation apparatus: a fully graphical and a batch mode. 
 +
 +Ambiguity can occur in partial orders and time-based schedules as a result of two or
 +more actions scheduled at the same time or in the same relative order. Swarm resolves
 +such ambiguity by defining a "concurrent group type," an explicit indication of how to
 +execute a group of actions that are defined at the same time. Options include running the
 +group in an arbitrary, fixed order running the group in a random order every time or
 +actually running each action concurrently, for future implementation on parallel machines.
 +The explicit notation of a concurrent group type helps to expose and remove any hidden
 +assumptions in the time structure of a model.
 +
 +__TerraME:__ this control of ambiguity can be very interesting
 +
 +
  
 =====Swarm User Guide===== =====Swarm User Guide=====
Linha 39: Linha 88:
 One agent always inherits the class SwarmObject, and has a description such as One agent always inherits the class SwarmObject, and has a description such as
  
-  @interface Heatbug: SwarmObject +  @interface Person: SwarmObject { 
-  +      int x, y; 
-    double unhappiness;                 // my current unhappiness +      int xsize,ysize
-    int x, y;                   // my spatial coordinates +      int myColor
-    HeatValue idealTemperature            // my ideal temperature +      int unhappy; 
-    HeatValue outputHeat              // how much heat I put out +      int nhoodType; 
-    float randomMoveProbability           // chance of moving randomly+      int radius; 
 +      int idnumber; 
 +      double myTolerance, fracMyColor;
      
-    id <Grid2d> world                 // the world I live in +      BOOL edgeWrap
-    int worldXSize, worldYSize            // how big that world is +      BOOL moved
-    HeatSpace *heat               // the heat for the world +      SchellingWorld myWorld;
-    Color bugColor;                 // my colour (display)+
   }   }
  
Linha 60: Linha 110:
 should have a method, such as getAgentList, that returns a list of agents that the observer swarm can use.// should have a method, such as getAgentList, that returns a list of agents that the observer swarm can use.//
  
-  buildActions +The ModelSwarm controls the application, contains the world and the set of agents. 
 + 
 +  @interface ModelSwarm : Swarm { 
 +      // [...] 
 +      id <List> agentList; 
 +      id world; 
 +  } 
 +   
 +  // functions of the class 
 +  // [...] 
 +  stepThroughList; 
 +  getAgentList; 
 + 
 +The ModelSwarm defines a scheduler of actions it will execute, and it sends "step" messages to the agents. 
 + 
 +  buildActions
   {   {
-    modelSchedule=[Schedule createBegin: self]; +      [super buildActions];    // super is the class this object inherits 
-    [modelSchedule setRepeatInterval1]; +      id modelActions = [ActionGroup createself]; 
-    modelSchedule = [modelSchedule createEnd];+      [modelActions createActionTo: output message: M(step)];
      
-    [modelSchedule atcreateActionTo: aBug message: M(step)];+      [modelActions createActionToself message: M(stepThroughList)]; // function to activate the agents it controls 
 +      if (synchronous) 
 +          [modelActions createActionTo: world message: M(stepRule)];
      
-    return self;+      modelSchedule = [Schedule createBegin: self]; 
 +      [modelSchedule setRepeatInterval: 1]; 
 +      modelSchedule = [modelSchedule createEnd]; 
 +   
 +      [modelSchedule at: 0 createAction: modelActions]; 
 +      return self;
   }   }
  
-  [modelSchedule at: 0 createActionForEach: bugList message: M(step)]; 
  
  
Linha 100: Linha 171:
   * Object2dDisplay: displays 2d arrays of objects   * Object2dDisplay: displays 2d arrays of objects
   * Int2dFiler: (deprecated) save the state of any Discrete2d: object (or a subclass thereof) to a specified file.    * Int2dFiler: (deprecated) save the state of any Discrete2d: object (or a subclass thereof) to a specified file. 
 +
 +
  
 ===== Examples available at swarm wiki===== ===== Examples available at swarm wiki=====
Linha 171: Linha 244:
  
  
-=====Papers=====+The creation of a group of agents, by a Model Swarm. Note that the model creates and puts it in the world.
  
-==== The Swarm Simulation System: A Toolkit for Building Multi-agent Simulations==== +  for(i 0; i < 100; i++) 
-|N. Minar, R. Burkhart, C. Langton, M. Askenazi, | [[http://leg.ufpr.br/~pedro/papers/swarm-intro.pdf|pdf]][[http://scholar.google.com.br/scholar?hl=pt-BR&lr=&cites=14912459563270754412| 246 citations in Scholar]] (the book) |+  { 
 +      StupidBug* stupidBug nil; 
 +   
 +      stupidBug = [StupidBug create: modelZone]; 
 +      [stupidBug setWorldworld]
 +      [stupidBug setRandPosition]
 +   
 +      [bugList addLaststupidBug]
 +  }
  
-//Swarm is a multi-agent software platform for the simulation of complex adaptive +__TerraME__: It could be possible to create all the set of agents, and then insert the whole group in the scaleAt 
-systems. In the Swarm system the basic unit of simulation is the swarm, a collection of agents executing a schedule of actions.  +this moment, each agent chooses his position/trajectories in the space.
-Swarm supports hierarchical modeling approaches whereby agents can be composed of swarms of other agents in nested +
-structuresSwarm provides object oriented libraries of reusable components for building models and analyzing, displaying, and  +
-controlling experiments on those models.//+
  
-//[...] collection of independent agents interacting via discrete events. [...] There are no domain  
-specific requirements such as particular spatial environments, physical phenomena, agent representations, or interaction patterns.  
-Swarm simulations have been written for such diverse areas [...]// 
  
-//The basic unit of a Swarm simulation is the agent. An agent is any actor in a system, +=====TODO===== 
-any entity that can generate events that affect itself and other agents. Simulations consist + 
-of groups of many interacting agents. [...] Simulation of discrete interactions between  +Some applications using swarm:
-agents stands in contrast to continuous system simulations, where simulated +
-phenomena are quantities in a system of coupled equations.//+
  
-//In addition to being containers for agentsswarms can themselves be agents[...] +  * SchelhornT., O'Sullivan, D., Hakley, Mand Thurstain-Goodwin, M. (1999), STREETS: An Agent-Based Pedestrian Model, Centre for Advanced Spatial Analysis (University College London): Working Paper 9, London
-an agent can also itself be a swarma collection of objects and a schedule of actions.  +  * Haklay, M., O'Sullivan, D., Thurstain-Goodwin, M. and Schelhorn, T. (2001), '"So Go Downtown"Simulating Pedestrian Movement in Town Centres', Environment and Planning B: Planning and Design, 28(3): 343-359
-In this casethe agent's behavior is defined by the emergent phenomena of the agents inside  +  * Batty, M., Desyllas, J. and Duxbury, E. (2003), 'Safety in Numbers? Modelling Crowds and Designing Control for the Notting Hill Carnival', Urban Studies, 40(8): 1573-1590. 
-its swarmHierarchical models can be built by nesting multiple swarms,// as shown in the + 
-figure below.+Swarm learning curve: 
 + 
 +  * Najlis, R., Janssen, M.A. and Parker, D.C. (2001), 'Software Tools and Communication Issues', in Parker, D.C., Berger, T. and Manson, S.M. (eds.), Meeting the Challenge of Complexity: Proceedings of a Special Workshop on Land-Use/Land-Cover Change, Irvine, California.
  
  
geopro/pedro/swarm.1184007581.txt.gz · Última modificação: 2007/07/09 18:59 por pedro