Abstract
RoboChart is a core notation in the RoboStar framework. It is a timed and probabilistic domain-specific and state machine based language for robotics. RoboChart supports shared variables and communication across entities in its component model. It has a formal denotational semantics given in CSP. Interaction Trees (ITrees) is a semantic technique to represent behaviours of reactive and concurrent programs interacting with their environments. Recent mechanisations of ITrees along with ITree-based CSP semantics and a Z mathematical toolkit in Isabelle/HOL bring new applications of verification and animation for state-rich process languages, such as RoboChart. In this paper, we use ITrees to give RoboChart a novel operational semantics, implement it in Isabelle, and use Isabelle’s code generator to generate verified and executable animations. We illustrate our approach using an autonomous chemical detector model. With animation, we show two concrete scenarios when the robot encounters different environmental inputs.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Similar content being viewed by others
Notes
- 1.
- 2.
- 3.
- 4.
- 5.
- 6.
In the Isabelle code, we include suffixes to ensure that names do not collide, but omit them here.
- 7.
References
Cavalcanti, A., et al.: RoboStar technology: a roboticist’s toolbox for combined proof, simulation, and testing. In: Cavalcanti, A., Dongol, B., Hierons, R., Timmis, J., Woodcock, J. (eds.) Software Engineering for Robotics, pp. 249–293. Springer, Cham (2021). https://doi.org/10.1007/978-3-030-66494-7_9
Hoare, C.A.R., He, J.: Unifying Theories of Programming. Prentice-Hall (1998)
Miyazawa, A., Ribeiro, P., Li, W., Cavalcanti, A., Timmis, J., Woodcock, J.: RoboChart: modelling and verification of the functional behaviour of robotic applications. Softw. Syst. Model. 18(5), 3097–3149 (2019). https://doi.org/10.1007/s10270-018-00710-z
Ye, K., Cavalcanti, A., Foster, S., Miyazawa, A., Woodcock, J.: Probabilistic modelling and verification using RoboChart and PRISM. Softw. Syst. Model. 21(2), 667–716 (2021). https://doi.org/10.1007/s10270-021-00916-8
Woodcock, J., Cavalcanti, A., Foster, S., Mota, A., Ye, K.: Probabilistic semantics for RoboChart. In: Ribeiro, P., Sampaio, A. (eds.) UTP 2019. LNCS, vol. 11885, pp. 80–105. Springer, Cham (2019). https://doi.org/10.1007/978-3-030-31038-7_5
Ye, K., Foster, S., Woodcock, J.: Automated reasoning for probabilistic sequential programs with theorem proving. In: Fahrenberg, U., Gehrke, M., Santocanale, L., Winter, M. (eds.) RAMiCS 2021. LNCS, vol. 13027, pp. 465–482. Springer, Cham (2021). https://doi.org/10.1007/978-3-030-88701-8_28
Hoare, C.A.R.: Communicating Sequential Processes. Prentice-Hall Int. (1985)
Roscoe, A.W.: Understanding Concurrent Systems. Texts in Computer Science, Springer, Heidelberg (2011)
Xia, L.Y., et al.: Interaction trees: representing recursive and impure programs in Coq. Proc. ACM Program. Lang. 4(POPL) (2019)
Foster, S., Hur, C.K., Woodcock, J.: Formally verified simulations of state-rich processes using interaction trees in Isabelle/HOL. In: Haddad, S., Varacca, D. (eds.) 32nd International Conference on Concurrency Theory (CONCUR 2021). Leibniz International Proceedings in Informatics (LIPIcs), Dagstuhl, Germany, vol. 203, pp. 20:1–20:18. Schloss Dagstuhl - Leibniz-Zentrum für Informatik (2021)
Brookes, S.D., Hoare, C.A.R., Roscoe, A.W.: A theory of communicating sequential processes. J. ACM (JACM) 31, 560–599 (1984)
Gibson-Robinson, T., Armstrong, P., Boulgakov, A., Roscoe, A.W.: FDR3—a modern refinement checker for CSP. In: Ábrahám, E., Havelund, K. (eds.) TACAS 2014. LNCS, vol. 8413, pp. 187–201. Springer, Heidelberg (2014). https://doi.org/10.1007/978-3-642-54862-8_13
Haftmann, F., Nipkow, T.: Code generation via higher-order rewrite systems. In: Blume, M., Kobayashi, N., Vidal, G. (eds.) FLOPS 2010. LNCS, vol. 6009, pp. 103–117. Springer, Heidelberg (2010). https://doi.org/10.1007/978-3-642-12251-4_9
Mayr, R., Nipkow, T.: Higher-order rewrite systems and their confluence. Theor. Comput. Sci. 192(1), 3–29 (1998)
Hilder, J.A., et al.: Chemical detection using the receptor density algorithm. IEEE Trans. Syst. Man Cybern. Part C 42(6), 1730–1741 (2012)
Miyazawa, A., et al.: RoboChart Reference Manual. Technical report, University of York (2020). https://www.cs.york.ac.uk/circus/publications/techreports/reports/robochart-reference.pdf
Blanchette, J.C., Hölzl, J., Lochbihler, A., Panny, L., Popescu, A., Traytel, D.: Truly modular (co)datatypes for Isabelle/HOL. In: Klein, G., Gamboa, R. (eds.) ITP 2014. LNCS, vol. 8558, pp. 93–110. Springer, Cham (2014). https://doi.org/10.1007/978-3-319-08970-6_7
Spivey, J.M.: The Z Notation: A Reference Manual, 2nd edn. Prentice-Hall (1992)
Toyn, I. (ed.): Information Technology—Z Formal Specification Notation—Syntax, Type System and Semantics. ISO (2002). ISO/IEC 13568:2002(E)
Ballarin, C.: Locales and locale expressions in Isabelle/Isar. In: Berardi, S., Coppo, M., Damiani, F. (eds.) TYPES 2003. LNCS, vol. 3085, pp. 34–50. Springer, Heidelberg (2004). https://doi.org/10.1007/978-3-540-24849-1_3
Kazmierczak, E., Winikoff, M., Dart, P.W.: Verifying model oriented specifications through animation. In: 5th Asia-Pacific Software Engineering Conference (APSEC 1998), Taipei, Taiwan, ROC, 2–4 December 1998, pp. 254–261. IEEE Computer Society (1998)
Boichut, Y., Genet, T., Glouche, Y., Heen, O.: Using animation to improve formal specifications of security protocols. In: 2nd Conference on Security in Network Architectures and Information Systems, SARSSI 2007, pp. 169–182 (2007)
Leuschel, M., Butler, M.: ProB: a model checker for B. In: Araki, K., Gnesi, S., Mandrioli, D. (eds.) FME 2003. LNCS, vol. 2805, pp. 855–874. Springer, Heidelberg (2003). https://doi.org/10.1007/978-3-540-45236-2_46
de Souza, D.H.O.: Joker: an animator for formal languages. Ph.D. thesis, Departamento de Informática e Matemática Aplicada, Universidade Federal do Rio Grande do Norte (2011)
Rosu, G., Serbanuta, T.: An overview of the K semantic framework. J. Log. Algebraic Methods Program. 79(6), 397–434 (2010)
Ellison, C., Rosu, G.: An executable formal semantics of C with applications. In: Field, J., Hicks, M. (eds.) Proceedings of the 39th ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, POPL 2012, Philadelphia, Pennsylvania, USA, 22–28 January 2012, pp. 533–544. ACM (2012)
Bogdanas, D., Rosu, G.: K-Java: a complete semantics of Java. In: Rajamani, S.K., Walker, D. (eds.) Proceedings of the 42nd Annual ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, POPL 2015, Mumbai, India, 15–17 January 2015, pp. 445–456. ACM (2015)
Kemeny, J.G., Snell, J.L., Knapp, A.W.: Denumerable Markov Chains (1976)
Kemeny, J.G., Snell, J.L.: Finite Markov Chains: With a New Appendix “Generalization of a Fundamental Matrix’’. Undergraduate Texts in Mathematics, Springer, Heidelberg (1983)
Acknowledgements
This work is funded by the EPSRC projects CyPhyAssure (https://www.cs.york.ac.uk/circus/CyPhyAssure/, Grant EP/S001190/1), RoboCalc (Grant EP/M025756/1), and RoboTest (Grant EP/R025479/1). The icons used in RoboChart have been made by Sarfraz Shoukat, Freepik, Google, Icomoon and Madebyoliver from www.flaticon.com, and are licensed under CC 3.0 BY.
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2022 Springer Nature Switzerland AG
About this paper
Cite this paper
Ye, K., Foster, S., Woodcock, J. (2022). Formally Verified Animation for RoboChart Using Interaction Trees. In: Riesco, A., Zhang, M. (eds) Formal Methods and Software Engineering. ICFEM 2022. Lecture Notes in Computer Science, vol 13478. Springer, Cham. https://doi.org/10.1007/978-3-031-17244-1_24
Download citation
DOI: https://doi.org/10.1007/978-3-031-17244-1_24
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-031-17243-4
Online ISBN: 978-3-031-17244-1
eBook Packages: Computer ScienceComputer Science (R0)