Software & Systems Modeling

, Volume 12, Issue 2, pp 387–414 | Cite as

A modular timed graph transformation language for simulation-based design

Regular Paper

Abstract

We introduce the MoTif (Modular Timed graph transformation) language, which allows one to elegantly model complex control structures for programmed graph transformation. These include modular construction, parallel composition, and a temporal dimension in addition to the usual transformation control structures. The first part of this contribution formally introduces MoTif and its semantics is based on the Discrete EVent system Specification (DEVS) formalism which allows for highly modular, hierarchical modelling of timed, reactive systems. In MoTif, graphs are embedded in events and individual transformation rules are embedded in atomic DEVS models. A side effect of the use of DEVS is the introduction of an explicit notion of time. This allows one to model a time-advance for every rule as well as to interrupt (pre-empt) rule execution. In the second part, we design a case study to show how the explicit notion of time allows for the simulation-based design of reactive systems such as modern computer games. We use the well-known game of PacMan as an example and model its dynamics in MoTif. This also allows the modelling of player behaviour, incorporating data about human players’ behaviour, and reaction times. Thus, a model of both player and game is obtained which can be used to evaluate, through simulation, the playability of a game design. We propose a playability performance measure and change the value of some parameters of the PacMan game. For each variant of the game thus obtained, simulation yields a value for the quality of the game. This allows us to choose an “optimal” (from a playability point of view) game configuration. The user model is subsequently replaced by a visual interface to a real player, and the game model is executed using a real-time DEVS simulator.

Keywords

Simulation DEVS Graph transformation 

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. 1.
    Blostein, D., Fahmy, H., Grbavec, A.: Issues in the practical use of graph rewriting. In: Cuny, J.E., Ehrig, H., Engels, G., Rozenberg, G. (eds.) Selected Papers from the 5th International Workshop on Graph Grammars and Their Application to Computer Science. LNCS, vol. 1073, pp. 38–55. Springer, Williamsburg, November 1996Google Scholar
  2. 2.
    Nickel, U., Niere, J., Zündorf, A.: The FUJABA environment. In: ICSE’00, pp. 742–745. ACM Press, Limerick, June 2000Google Scholar
  3. 3.
    Lengyel, L., Levendovszky, T., Mezei, G., Charaf, H.: Control flow support in metamodel-based model transformation frameworks. In: EUROCON’05, pp. 595–598. IEEE, Belgrade, November 2005Google Scholar
  4. 4.
    Agrawal A., Karsai G., Kalmar Z., Neema S., Shi F., Vizhanyo A.: The design of a language for model transformations. SoSym 5(3), 261–288 (2006)CrossRefGoogle Scholar
  5. 5.
    Lengyel L., Levendovszky T., Mezei G., Charaf H.: Model transformation with a visual control flow language. IJCS 1(1), 45–53 (2006)Google Scholar
  6. 6.
    Schürr, A., Winter, A.J., Zündorf, A.: Graph grammar engineering with PROGRES. In: Schäfer, W., Botella, P. (eds.) 5th European Software Engineering Conference. LNCS, vol. 989, pp. 219–234. Springer, Sitges, September 1995Google Scholar
  7. 7.
    Amelunxen C., Königs A., Rötschke T., Schürr A.: MOFLON: a standard-compliant metamodeling framework with graph transformations. In: Rensink, A., Warmer, J. (eds) Model Driven Architecture—Foundations and Applications: Second European Conference. LNCS, vol. 4066, pp. 361–375. Springer, Berlin (2006)Google Scholar
  8. 8.
    Heckel, R.: Graph transformation in a nutshell. In: Proceedings of the School on Foundations of Visual Modelling Techniques (FoVMT 2004) of the SegraVis Research Training Network. ENTCS, vol. 148, no. 1, pp. 187–198. Elsevier (2006)Google Scholar
  9. 9.
    de Lara, J., Vangheluwe, H.: AToM3: a tool for multi-formalism and meta-modelling. In: Kutsche, R.-D., Weber, H. (eds.) FASE’02. LNCS, vol. 2306, pp. 174–188. Springer, Grenoble, April 2002Google Scholar
  10. 10.
    Ehrig, H., Engels, G., Kreowski, H.-J., Rozenberg, G.: Handbook of graph grammars and computing by graph transformation. In: Rozenberg, G. (ed.) Foundations, vol. 1. World Scientific Publishing Co. (1997)Google Scholar
  11. 11.
    Zeigler B.P.: Multifacetted Modelling and Discrete Event Simulation. Academic Press, New York (1984)MATHGoogle Scholar
  12. 12.
    Xie, H., Boukerche, A., Zhang, M., Zeigler, B.P.: Design of a QoS-aware service composition and management system in peer-to-peer network aided by DEVS. In: DS-RT, pp. 285–291 (2008)Google Scholar
  13. 13.
    Lee J.-K., Lim Y.-H., Chi S.-D.: Hierarchical modeling and simulation environment for intelligent transportation systems. Simulation 80(2), 61–76 (2004)CrossRefGoogle Scholar
  14. 14.
    Filippi J.-B., Bisgambiglia P.: JDEVS: an implementation of a DEVS based formal framework for environmental modelling. Environ. Model. Softw. 19(3), 261–274 (2004)CrossRefGoogle Scholar
  15. 15.
    Bolduc J.-S., Vangheluwe, H.: The modelling and simulation package pythonDEVS for classical hierarchical DEVS. McGill University. MSDL Technical Report MSDL-TR-2001-01, June 2001Google Scholar
  16. 16.
    Mens, T., Van Gorp, P.: A taxonomy of model transformation. In: GraMoT’05. ENTCS, vol. 152, pp. 125–142, Tallinn (Estonia), March 2006Google Scholar
  17. 17.
    Syriani E., Vangheluwe H.: Programmed graph rewriting with DEVS. In: Nagl, M., Schürr, A. (eds) AGTIVE’07. LNCS, vol. 5088, pp. 136–152. Springer, Kassel (2007)Google Scholar
  18. 18.
    Guerra E., de Lara J.: Event-driven grammars: relating abstract and concrete levels of visual languages. SoSym 6(6), 317–347 (2007)Google Scholar
  19. 19.
    Guerra E., de Lara J.: Event-driven grammars: towards the integration of meta-modelling and graph transformation. In: Ehrig, H., Engels, G., Parisi-Presicce, F., Rozenberg, G. (eds) ICGT’04. LNCS, vol. 3256, pp. 54–69. Springer, New York (2004)Google Scholar
  20. 20.
    Hart P.E., Nilsson N.J., Raphael B.: A formal basis for the heuristic determination of minimum cost paths. IEEE Trans. Syst. Sci. Cybern. 4(3), 100–107 (1968)CrossRefGoogle Scholar
  21. 21.
    Zaitsev A.V., Skorik Y.A.: Mathematical description of sensorimotor reaction time distribution. Human Physiol. 28(4), 494–497 (2002)CrossRefGoogle Scholar
  22. 22.
    Devroye L.: Non-Uniform Random Variate Generation. Springer, New York (1986)MATHGoogle Scholar
  23. 23.
    Gyapay, S., Heckel, R., Varró, D.: Graph transformation with time: causality and logical clocks. In: ICGT’02. LNCS, vol. 2505, pp. 120–134. Springer, Barcelona, October 2002Google Scholar
  24. 24.
    Heckel R., Lajios G., Menge S.: Stochastic graph transformation systems. In: Ehrig, H., Engels, G., Parisi-Presicce, F., Rozenberg, G. (eds) ICGT’04. LNCS, vol. 3256, pp. 243–246. Springer, New York (2004)Google Scholar
  25. 25.
    Agrawal, A.: Metamodel based model transformation language. In: OOPSLA’03, pp. 386–387. ACM Press, Anaheim (2003)Google Scholar
  26. 26.
    Vizhanyo A., Agrawal A., Shi F.: Towards generation of efficient transformations. In: Karsai, G., Visser, E. (eds) GPCE’04. LNCS, vol. 3286, pp. 298–316. Springer, New York (2004)Google Scholar
  27. 27.
  28. 28.
    Blostein D., Schürr A.: Computing with graphs and graph rewriting. SPE 9(3), 1–21 (1999)Google Scholar
  29. 29.
    Zündorf, A.: Graph pattern matching in PROGRES. In: Ehrig, H., Engels, G., Rozenberg, G. (eds.) Graph Grammars and Their Application to Computer Science. LNCS, vol. 1073, pp. 454–468. Springer, Williamsburg, November 1994Google Scholar
  30. 30.
    Zündorf, A.: Implementation of the imperative/rule based language PROGRES. Department of Computer Science III, Aachen University of Technology, Germany, Aachener Informatik-Berichte 92-38 (1992)Google Scholar
  31. 31.
    Fischer, T., Niere, J., Turunski, L., Zündorf, A.: Story diagrams: a new graph rewrite language based on the Unified Modelling Language and Java. In: Ehrig, H., Engels, G., Kreowski, H.-J., Rozenberg, G. (eds.) Theory and Application of Graph Transformations. LNCS, vol. 1764, pp. 296–309. Springer, Paderborn, November 2000Google Scholar
  32. 32.
    Burmester, S., Giese, H., Hirsch, M., Schilling, D., Tichy, M.: The fujaba real-time tool suite: model-driven development of safety-critical, real-time systems. In: Proceedings of the 27th International Conference on Software Engineering ICSE ’05, pp. 670–671. ACM, New York (2005)Google Scholar
  33. 33.
    Henkler, S., Greenyer, J., Hirsch, M., Schäfer, W., Alhawash, K., Eckardt, T., Heinzemann, C., Loffler, R., Seibel, A., Giese, H.: Synthesis of timed behavior from scenarios in the Fujaba Real-Time Tool Suite. In: ICSE ’09, pp. 615–618. IEEE Computer Society (2009)Google Scholar
  34. 34.
    Schürr, A.: Specification of graph translators with triple graph grammars. In: Tinhofer, G. (ed.) Graph-Theoretic Concepts in Computer Science. LNCS, vol. 903, pp. 151–163. Springer, Heidelberg, June 1994Google Scholar
  35. 35.
    4th International Workshop on Graph-Based Tools: The Contest. September 2008/07/21. [Online]. http://www.fots.ua.ac.be/events/grabats2008/
  36. 36.
    Taentzer, G.: AGG: a graph transformation environment for modeling and validation of software. In: AGTIVE’03. LNCS, vol. 3062, pp. 446–453. Springer, New York (2004)Google Scholar
  37. 37.
    Muliawan, O., Schippers, H., Van Gorp, P.: Model driven, Template based, Model Transformer (MoTMoT). http://motmot.sourceforge.net (2005)
  38. 38.
    Varró D., Balogh A.: The model transformation language of the VIATRA2 framework. Sci. Comput. Program. 68(3), 214–234 (2007)MATHCrossRefGoogle Scholar
  39. 39.
    Syriani, E., Vangheluwe, H.: Programmed graph rewriting with time for simulation-based design. In: Pierantonio, A., Vallecillo, A., Bézivin, J., Gray, J. (eds.) ICMT’08. LNCS, vol. 5063, pp. 91–106. Springer, Zürich, July 2008Google Scholar
  40. 40.
    Syriani, E.: A multi-paradigm foundation for model transformation language engineering. Ph.D. Thesis, McGill University, February 2011Google Scholar
  41. 41.
    Ráth I., Bergmann G., Ökrös A., Varró D.: Live model transformations driven by incremental pattern matching. In: Vallecillo, A., Gray, J., Pierantonio, A. (eds) ICMT’08. LNCS, vol. 5063, pp. 107–121. Springer, New York (2008)Google Scholar
  42. 42.
    Hearnden, D., Lawley, M., Raymond, K.: Incremental model transformation for the evolution of model-driven systems. In: MoDELS’06. LNCS, pp. 321–335 (2006)Google Scholar
  43. 43.
    Feng, T.H.: Model transformation with hierarchical discrete-event control. Ph.D. Thesis, EECS Department, University of California, Berkeley, USA, May 2009Google Scholar
  44. 44.
    Simulink User’s Guide. MathWorks, Natick, USA. March 2010Google Scholar
  45. 45.
    Dormoy, F.X.: SCADE 6: A Model Based Solution for Safety Critical Software Development. Esterel Technologies, Toulouse (2007)Google Scholar
  46. 46.
    Chow A.C.-H., Zeigler B.P.: Parallel DEVS: a parallel, hierarchical, modular modeling formalism. TSCS 13, 55–67 (1996)Google Scholar
  47. 47.
    Hunicke, R.: The case for dynamic difficulty adjustment in games. In: Proccedings of the ACM SIGCHI International Conference on Advances in Computer Entertainment Technology, pp. 429–433. ACM, Valencia (2005)Google Scholar

Copyright information

© Springer-Verlag 2011

Authors and Affiliations

  1. 1.McGill UniversityMontréalCanada
  2. 2.University of AntwerpAntwerpBelgium

Personalised recommendations