150 likes | 324 Views
UML for Behavior-Oriented Multi-Agent Simulations. Christoph Oechslein , Franziska Klügl, Rainer Herrler, and Frank Puppe University Würzburg, Germany. UML for Behavior-Oriented Multi-Agent Simulations. Christoph Oechslein , Franziska Klügl, Rainer Herrler, and Frank Puppe
E N D
UML for Behavior-Oriented Multi-Agent Simulations Christoph Oechslein, Franziska Klügl, Rainer Herrler, and Frank Puppe University Würzburg, Germany
UML for Behavior-Oriented Multi-Agent Simulations Christoph Oechslein, Franziska Klügl, Rainer Herrler, and Frank Puppe University Würzburg, Germany
UML for Behavior-Oriented Multi-Agent Simulations • Motivation • UML • Behavior-Oriented Multi-Agent Simulation (bMASim) • Using UML for bMAS • Small Example • Conclusion & Future Work Christoph Oechslein, Franziska Klügl, Rainer Herrler, and Frank Puppe University Würzburg, Germany
Motivation • Model concept to running experiment non trivial: • Top-down analysis bottom-up implementation • Concurrent (inter)actions • Complex agent behavior leads to large models • Huge amount of parameters • Own non standard specification language • Need for tools and frameworks which • Are easy to learn, clear and understandable and • Solve the above problems, e.g. scale for concrete domains. CEEMAS 2001 - UML for bMAS
UML • Already established framework in software engineering. • Diagram types for static and dynamic parts(e.g. activity graph and sequence diagram). • Includes OCL a formal language for attaching additional information, like invariants, constraints, etc.. • Meets criteria for ‘ideal’ framework CEEMAS 2001 - UML for bMAS
Behavior-OrientedMulti-Agent Simulation (bMASim) • Focus not on the internal reasoning process,but on the agent behavior and its interactions. • Associate task fulfillment with activities. • Incorporating organizational concepts like roles. • Includes a simulated environment. • Agent entails state variables and a rule-based behavior representation (based on activities). CEEMAS 2001 - UML for bMAS
+ deposit_trail (Pheromone) + following_trail (Pheromone) + forage (Environment) – feed (Ant) Class Diagrams • Shows state variables: • Type • Visibility attribute(private or public) • Constant • Interaction methods: • Visibility attribute(private or public) • Interaction partner Ant – energy_level: double + const size: double CEEMAS 2001 - UML for bMAS
Ant Nest – energy_level: double + ants: List of Ants + constsize: double + preys: List of Prey + deposit_trail (Pheromone) + following_trail (Pheromone) + forage (Environment) energy_level > 0 ants.count > 0 Ant.allInstances->sum(energy_level) < MAX_VALUE ants.sum(size) + preys.sum(size) < MAX_SIZE global invariants local invariants OCL in Class Diagrams • Class invariants: local and global CEEMAS 2001 - UML for bMAS
Activity Graphs for bMAS • Describing the behavior of an agent as an activity graph • State-like activities also well suited • Transitions are conditions on external and internal state variables • Example Missing: Describing the interactions CEEMAS 2001 - UML for bMAS
... Larva behavior Adult behavior • Interaction via Agent Generation interaction via ... creating larva creating larva transform ... interaction via creating adult ... • Interactionvia Variable Modification Ant behavior Nest interaction via variable food + food: double forage in nest ... Interaction Types • Interaction via Object Flow Ant behavior ... ... Pheromone follow trail deposit trail ... ... CEEMAS 2001 - UML for bMAS
Prey_Class Predator_class Energy : number Energy : number Reproduction_Cost (RC) Absorbable_Energy_from_food (abE) Reproduction_Cost ( RC ) Energy_boundary (E ) Absorbable_Energy_from_prey bound ( abE ) Success_probability ( prob ) Predator takes all succ Energy < abE Energy_boundary ( E ) energy of prey bound instance Generate new predator Generate new instance prey instance with Energy := with Energy := StartEnergy StartEnergy Food_Class Prey acquires energy of Energy : number food instance, no change in food instance ‘Predator – Prey’ Example Perishing Perishing Succumb always energy := 0 Energy < abE same position as successful predator Searching random movement Searching Ù random movement Ù RC - with always same position as prey always same position as predator RC Energy > prob same position as always same position as prey food instance Energy > always succ Reproduce Feeding Reproduce Capure Prey energy := energy + energy = energy + generate new predator generate new prey instance Food.Energy *abE prey.energy * abE instance energie = energie - RC energie = energie - RC CEEMAS 2001 - UML for bMAS
OCL in activities or states • Pre- and post conditions: • in activities or states • describing interactions Pick up Prey precondition: jawfull != true post condition jawfull = = true • OCL for adding precise and unambiguous information • basis for validation and verification • lower the gap between implementation and design CEEMAS 2001 - UML for bMAS
Conclusion and Future Work • Using various parts of UML for bMASim: • Activity graphs prominent mean • Describing interactions in activity graph • Using OCL for adding precise and unambiguous information • Classification of interaction types • Future work: • Structuring the information in documentation nodes • Methodology from concept model to UML • Application of this framework in real world models CEEMAS 2001 - UML for bMAS