1 / 31

DEVS as a Semantic Domain for Programmed Graph Transformation

DEVS as a Semantic Domain for Programmed Graph Transformation. Eugene Syriani. Reference. GraBaTS 2008 Tool contest E. Syriani and H. Vangheluwe : Using MoTif for the AntWorld Simulation Tool Contest

tanaya
Download Presentation

DEVS as a Semantic Domain for Programmed Graph Transformation

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. DEVS as a Semantic Domain for Programmed Graph Transformation Eugene Syriani

  2. Reference • GraBaTS 2008 Tool contestE. Syriani and H. Vangheluwe: Using MoTif for the AntWorld Simulation Tool Contest • DEVS Book (2008)E. Syriani and H. Vangheluwe: DEVS: A Semantic Domain For Programmed Graph Transformation

  3. Overview • Background • In the context • Case Study: The extended AntWorld Simulation • The Modular Timed Graph Transformation language (MoTif) • From DEVS to MoTif • The MoTif solution for the AntWorld case-study • Rules & Control Structure • Real-Time Model Transformation & Deployment • Conclusion and Future Work

  4. In the context • Model Transformation  Graph Transformation • Controlled Graph Rewriting (rewriting rules) • Control Primitives : Sequencing, Branching, Looping, Parallelism, Hierarchy • Time is inherent in our transformation models

  5. Case Study: AntWorld Simulation [1] EXTENDED [1] http://www.fots.ua.ac.be/events/grabats2008/ (2008/07/21)

  6. Case Study: AntWorld Simulation Domain-specific modelling

  7. Case Study: AntWorld Simulation Simulation Semantics • Create grid nodes when ant reaches outmost circle • Differentiate between nodes along main axis • Ant movement in search mode • Ant movement in carry mode • Ant creation, once food is brought back to the hill • Evaporation of pheromones

  8. Case Study: AntWorld Simulation++ Extended Simulation Semantics • At any moment in time, a human steps on the map • Kills all ants on the five nodes • The nodes loose food and pheromones

  9. FROM DEVS to MoTif

  10. DEVS • The Discrete Event System Specification [2] (DEVS) formalism • Highly compositional simulation framework • DEVS: • Blocks • Ports • Events • Semantics: Parallel composition of blocks/models [2] Zeigler B.P., Multifacetted Modelling and Discrete Event Simulation/ Academic Press, London (1984)

  11. DEVS Meta-Model

  12. Motif [2] • Blocks • Atomic: encapsulate a graph rewriting rule • Coupled: encapsulate a set of rules (graph grammar) • Events • Inport: receive the host graph • Outport(s): send the transformed graph [2] Syriani E. and Vangheluwe H.: Programmed Graph Rewriting with DEVS. AGTIVE 2007, LNCS (2008)

  13. MoTif Meta-Model

  14. MoTif as a DEVS Model

  15. MoTif as a DEVS Model • At most one rule will execute

  16. MoTif as a DEVS Model • Synchronize parallel threads • Success if at least one thread succeeds

  17. MoTif as a DEVS Model The select function: • If the Selector is in the imminent list, choose the Selector. • Among all the rules that still have a match, choose a corresponding ARule from the imminent list at random, no matter what depth it is at inside this CRule. • At this point no rule has any unprocessed match left, then choose any of the ARule in the imminent list. • Finally, the imminent list contains either custom atomic blocks or Synchronizers. • Proceed with a first-in-first-out selection.

  18. MotifModelling Environment in AToM3 [3] [3] de Lara J., Vangheluwe H., AToM3: A tool for multi-formalism and meta-modelling. FASE, LNCS 2306 (2002), 174-188

  19. Motif Execution Class Grabfood : def match(): … def execute(): … Class Grabfood : def match(): … def execute(): … class Grabfood: def match(): … def execute(): … COMPILE IMPORT SIMULATE class Grabfood(ARule): def __init__(self): ARule.__init__(self, name=‘GF') self.state = ARuleState(Grabfood()) def weightFunction(self): return 1.0 GENERATE

  20. MoTif solution

  21. AntWorld Rules

  22. Some AntWorld Rules dropFood checkAntOnOutCircle connectNodesInSameCircle goToSameNodeIn moveTowardsHill grabFood KillOnNode KillOnNextCircleNodeIn WeakenSameNodeOut

  23. Modelling of The transformation: Round CRule

  24. Modelling of The transformation: AntMovementsCRule

  25. Modelling of The transformation: GenerateCircleCRule

  26. Modelling of The transformation: EndOfRoundCRule

  27. Modelling of The transformation: HumanStepCRule

  28. Modelling of transformation: System • User – Controller – Autonomous loop • Feed-back to User • On User interrupt: User Controlled • Feed-back to User

  29. Synthesis of application [4] • Synthesis of a reactive application • Discard the UserBehavior block • Runs on a web browser using AJAX and SVG • Real-time model transformation (RT-DEVS) [4] E. Syriani and H. Vangheluwe. Programmed Graph Rewriting with Time for Simulation-Based Design. ICMT 2008. LNCS, vol.5063, pp. 91-106 (2008)

  30. Conclusion • Formalised MoTif in terms of DEVS • Provided solution to the AntWorld case-study • Extended solution with user interrupt • Deployment of an application • Pure parallel execution, possibly distributed • Re-use and parametrisation of transformation models • Allowing variable structure

  31. ?

More Related