On the Quantitative Semantics of Regular Expressions over Real-Valued Signals

  • Alexey Bakhirkin
  • Thomas Ferrère
  • Oded Maler
  • Dogan Ulus
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 10419)


Signal regular expressions can specify sequential properties of real-valued signals based on threshold conditions, regular operations, and duration constraints. In this paper we endow them with a quantitative semantics which indicates how robustly a signal matches or does not match a given expression. First, we show that this semantics is a safe approximation of a distance between the signal and the language defined by the expression. Then, we consider the robust matching problem, that is, computing the quantitative semantics of every segment of a given signal relative to an expression. We present an algorithm that solves this problem for piecewise-constant and piecewise-linear signals and show that for such signals the robustness map is a piecewise-linear function. The availability of an indicator describing how robustly a signal segment matches some regular pattern provides a general framework for quantitative monitoring of cyber-physical systems.


  1. 1.
    Abbas, H., Rodionova, A., Bartocci, E., Smolka, S.A., Grosu, R.: Regular expressions for irregular rhythms. arXiv preprint arXiv:1612.07770 (2016)
  2. 2.
    Alur, R., Dill, D.L.: A theory of timed automata. Theoret. Comput. Sci. 126(2), 183–235 (1994)MathSciNetCrossRefzbMATHGoogle Scholar
  3. 3.
    Alur, R., Feder, T., Henzinger, T.A.: The benefits of relaxing punctuality. J. ACM 43(1), 116–146 (1996)MathSciNetCrossRefzbMATHGoogle Scholar
  4. 4.
    Alur, R., Fisman, D., Raghothaman, M.: Regular programming for quantitative properties of data streams. In: Thiemann, P. (ed.) ESOP 2016. LNCS, vol. 9632, pp. 15–40. Springer, Heidelberg (2016). doi: 10.1007/978-3-662-49498-1_2 CrossRefGoogle Scholar
  5. 5.
    Asarin, E., Caspi, P., Maler, O.: Timed regular expressions. J. ACM 49(2), 172–206 (2002)MathSciNetCrossRefzbMATHGoogle Scholar
  6. 6.
    Asarin, E., Caspi, P., Maler, O.: A Kleene theorem for timed automata. In: Logic in Computer Science (LICS), pp. 160–171 (1997)Google Scholar
  7. 7.
    Bagnara, R., Hill, P.M., Zaffanella, E.: The Parma Polyhedra Library: Toward a complete set of numerical abstractions for the analysis and verification of hardware and software systems. Sci. Comput. Program. 72(1–2), 3–21 (2008)MathSciNetCrossRefGoogle Scholar
  8. 8.
    Bagnara, R., Hill, P.M., Zaffanella, E.: Not necessarily closed convex polyhedra and the double description method. Formal Asp. Comput. 17(2), 222–257 (2005)CrossRefzbMATHGoogle Scholar
  9. 9.
    Basin, D., Klaedtke, F., Müller, S., Zălinescu, E.: Monitoring metric first-order temporal properties. J. ACM (JACM) 62(2), 15 (2015)MathSciNetCrossRefzbMATHGoogle Scholar
  10. 10.
    D’Antoni, L., Veanes, M.: Minimization of symbolic automata. In: POPL, pp. 541–554. ACM (2014)Google Scholar
  11. 11.
    Deshmukh, J.V., Jin, X., Seshia, S., et al.: Learning auditable features from signals using unsupervised temporal projection (2017)Google Scholar
  12. 12.
    Deshmukh, J.V., Majumdar, R., Prabhu, V.S.: Quantifying conformance using the skorokhod metric. In: Kroening, D., Păsăreanu, C.S. (eds.) CAV 2015. LNCS, vol. 9207, pp. 234–250. Springer, Cham (2015). doi: 10.1007/978-3-319-21668-3_14 CrossRefGoogle Scholar
  13. 13.
    Dill, D.L.: Timing assumptions and verification of finite-state concurrent systems. In: Sifakis, J. (ed.) CAV 1989. LNCS, vol. 407, pp. 197–212. Springer, Heidelberg (1990). doi: 10.1007/3-540-52148-8_17 CrossRefGoogle Scholar
  14. 14.
    Donzé, A.: Breach, a toolbox for verification and parameter synthesis of hybrid systems. In: Touili, T., Cook, B., Jackson, P. (eds.) CAV 2010. LNCS, vol. 6174, pp. 167–170. Springer, Heidelberg (2010). doi: 10.1007/978-3-642-14295-6_17 CrossRefGoogle Scholar
  15. 15.
    Donzé, A., Maler, O.: Robust satisfaction of temporal logic over real-valued signals. In: Chatterjee, K., Henzinger, T.A. (eds.) FORMATS 2010. LNCS, vol. 6246, pp. 92–106. Springer, Heidelberg (2010). doi: 10.1007/978-3-642-15297-9_9 CrossRefGoogle Scholar
  16. 16.
    Donzé, A., Ferrère, T., Maler, O.: Efficient robust monitoring for STL. In: Sharygina, N., Veith, H. (eds.) CAV 2013. LNCS, vol. 8044, pp. 264–279. Springer, Heidelberg (2013). doi: 10.1007/978-3-642-39799-8_19 CrossRefGoogle Scholar
  17. 17.
    Fainekos, G.E., Pappas, G.J.: Robustness of temporal logic specifications. In: Havelund, K., Núñez, M., Roşu, G., Wolff, B. (eds.) FATES/RV -2006. LNCS, vol. 4262, pp. 178–192. Springer, Heidelberg (2006). doi: 10.1007/11940197_12 CrossRefGoogle Scholar
  18. 18.
    Henzinger, T.A.: Quantitative reactive modeling and verification. Comput. Sci. Res. Dev. 28(4), 331–344 (2013)CrossRefGoogle Scholar
  19. 19.
    Henzinger, T.A., Otop, J.: From model checking to model measuring. In: D’Argenio, P.R., Melgratti, H. (eds.) CONCUR 2013. LNCS, vol. 8052, pp. 273–287. Springer, Heidelberg (2013). doi: 10.1007/978-3-642-40184-8_20 CrossRefGoogle Scholar
  20. 20.
    Jakšić, S., Bartocci, E., Grosu, R., Ničković, D.: Quantitative monitoring of STL with edit distance. In: Falcone, Y., Sánchez, C. (eds.) RV 2016. LNCS, vol. 10012, pp. 201–218. Springer, Cham (2016). doi: 10.1007/978-3-319-46982-9_13 CrossRefGoogle Scholar
  21. 21.
    Jin, X., Donzé, A., Deshmukh, J.V., Seshia, S.A.: Mining requirements from closed-loop control models. IEEE Trans. Comput. Aided Des. Integr. Circuits Syst. 34(11), 1704–1717 (2015)CrossRefzbMATHGoogle Scholar
  22. 22.
    Koymans, R.: Specifying real-time properties with metric temporal logic. Real-Time Syst. 2(4), 255–299 (1990)CrossRefGoogle Scholar
  23. 23.
    Maler, O., Nickovic, D.: Monitoring temporal properties of continuous signals. In: Lakhnech, Y., Yovine, S. (eds.) FORMATS/FTRTFT -2004. LNCS, vol. 3253, pp. 152–166. Springer, Heidelberg (2004). doi: 10.1007/978-3-540-30206-3_12 CrossRefGoogle Scholar
  24. 24.
    Maler, O., Nickovic, D., Pnueli, A.: Checking temporal properties of discrete, timed and continuous behaviors. In: Avron, A., Dershowitz, N., Rabinovich, A. (eds.) Pillars of Computer Science. LNCS, vol. 4800, pp. 475–505. Springer, Heidelberg (2008). doi: 10.1007/978-3-540-78127-1_26 CrossRefGoogle Scholar
  25. 25.
    Mens, I.E., Maler, O.: Learning regular languages over large ordered alphabets. Log. Methods Comput. Sci. (LMCS) 11(3)Google Scholar
  26. 26.
    Nickovic, D., Maler, O.: AMT: A property-based monitoring tool for analog systems. In: FORMATS, pp. 304–319 (2007)Google Scholar
  27. 27.
    Pnueli, A.: The temporal logic of programs. In: Proceedings of the 18th Annual Symposium on Foundations of Computer Science (FOCS), pp. 46–57 (1977)Google Scholar
  28. 28.
    Rizk, A., Batt, G., Fages, F., Soliman, S.: On a continuous degree of satisfaction of temporal logic formulae with applications to systems biology. In: Heiner, M., Uhrmacher, A.M. (eds.) CMSB 2008. LNCS (LNAI), vol. 5307, pp. 251–268. Springer, Heidelberg (2008). doi: 10.1007/978-3-540-88562-7_19 CrossRefGoogle Scholar
  29. 29.
    Trakhtenbrot, B.A.: Origins and metamorphoses of the trinity: Logic, nets, automata. In: LICS, pp. 506–507 (1995)Google Scholar
  30. 30.
    Trakhtenbrot, B.A.: Understanding basic automata theory in the continuous time setting. Fundam. Inform. 62(1), 69–121 (2004)MathSciNetzbMATHGoogle Scholar
  31. 31.
    Ulus, D.: Montre: A tool for monitoring timed regular expressions. CoRR abs/1605.05963 (2016)Google Scholar
  32. 32.
    Ulus, D., Ferrère, T., Asarin, E., Maler, O.: Timed pattern matching. In: Legay, A., Bozga, M. (eds.) FORMATS 2014. LNCS, vol. 8711, pp. 222–236. Springer, Cham (2014). doi: 10.1007/978-3-319-10512-3_16 Google Scholar
  33. 33.
    Veanes, M., Hooimeijer, P., Livshits, B., Molnar, D., Björner, N.: Symbolic finite state transducers: algorithms and applications. In: POPL, pp. 137–150. ACM (2012)Google Scholar

Copyright information

© Springer International Publishing AG 2017

Authors and Affiliations

  • Alexey Bakhirkin
    • 1
    • 2
  • Thomas Ferrère
    • 3
  • Oded Maler
    • 1
    • 2
  • Dogan Ulus
    • 1
    • 2
  1. 1.Université Grenoble-Alpes, VERIMAGGrenobleFrance
  2. 2.CNRS, VERIMAGGrenobleFrance
  3. 3.IST AustriaKlosterneuburgAustria

Personalised recommendations