Skip to main content

The Complexity of Evaluating Nfer

  • Conference paper
  • First Online:

Part of the book series: Lecture Notes in Computer Science ((LNCS,volume 13299))

Abstract

Nfer is a rule-based language for abstracting event streams into a hierarchy of intervals with data. Nfer has multiple implementations and has been applied in the analysis of spacecraft telemetry and autonomous vehicle logs. This work provides the first complexity analysis of nfer evaluation, i.e., the problem of deciding whether a given interval is generated by applying rules.

We show that the full nfer language is undecidable and that this depends on both recursion in the rules and an infinite data domain. By restricting either or both of those capabilities, we obtain tight decidability results. We also examine the impact on complexity of exclusive rules and minimality. For the most practical case, which is minimality with finite data, we provide a polynomial time algorithm.

This research was partly funded by the ERC Advanced Grant LASSO, the Villum Investigator Grant S4OS and DIREC, Digital Research Center Denmark.

This is a preview of subscription content, log in via an institution.

Buying options

Chapter
USD   29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD   79.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD   99.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Learn about institutional subscriptions

References

  1. Aceto, L., Della Monica, D., Goranko, V., Ingólfsdóttir, A., Montanari, A., Sciavicco, G.: A complete classification of the expressiveness of interval logics of Allen’s relations: the general and the dense cases. Acta Inform. 53(3), 207–246 (2015). https://doi.org/10.1007/s00236-015-0231-4

    Article  MathSciNet  MATH  Google Scholar 

  2. Allen, J.F.: Maintaining knowledge about temporal intervals. Commun. ACM 26(11), 832–843 (1983)

    Article  Google Scholar 

  3. Arora, S., Barak, B.: Computational Complexity: A Modern Approach, 1st edn. Cambridge University Press, USA (2009)

    Book  Google Scholar 

  4. Barringer, H., Havelund, K.: TraceContract: a scala DSL for trace analysis. In: Butler, M., Schulte, W. (eds.) FM 2011. LNCS, vol. 6664, pp. 57–72. Springer, Heidelberg (2011). https://doi.org/10.1007/978-3-642-21437-0_7

    Chapter  Google Scholar 

  5. Chen, J., DeWitt, D.J., Tian, F., Wang, Y.: NiagaraCQ: a scalable continuous query system for internet databases. In: International Conference on Management of Data (ACM SIGMOD 2000), pp. 379–390. ACM (2000). https://doi.org/10.1145/342009.335432

  6. Convent, L., Hungerecker, S., Leucker, M., Scheffel, T., Schmitz, M., Thoma, D.: TeSSLa: temporal stream-based specification language. In: Massoni, T., Mousavi, M.R. (eds.) SBMF 2018. LNCS, vol. 11254, pp. 144–162. Springer, Cham (2018). https://doi.org/10.1007/978-3-030-03044-5_10

    Chapter  Google Scholar 

  7. Faymonville, P., Finkbeiner, B., Schwenger, M., Torfah, H.: Real-time stream-based monitoring (2019)

    Google Scholar 

  8. Hallé, S.: When RV meets CEP. In: Falcone, Y., Sánchez, C. (eds.) RV 2016. LNCS, vol. 10012, pp. 68–91. Springer, Cham (2016). https://doi.org/10.1007/978-3-319-46982-9_6

    Chapter  Google Scholar 

  9. Halpern, J.Y., Shoham, Y.: A propositional modal logic of time intervals. J. ACM 38(4), 935–962 (1991). https://doi.org/10.1145/115234.115351

    Article  MathSciNet  MATH  Google Scholar 

  10. Havelund, K.: Rule-based runtime verification revisited. Int. J. Softw. Tools Technol. Transfer 17(2), 143–170 (2014). https://doi.org/10.1007/s10009-014-0309-2

    Article  Google Scholar 

  11. Havelund, K.: Git repository (2022). git@github.com:rv-tools/nfer.git. Accessed January 2022

    Google Scholar 

  12. Havelund, K., Omer, M., Peled, D.: Monitoring first-order interval logic. In: Calinescu, R., Păsăreanu, C.S. (eds.) SEFM 2021. LNCS, vol. 13085, pp. 66–83. Springer, Cham (2021). https://doi.org/10.1007/978-3-030-92124-8_4

    Chapter  Google Scholar 

  13. Kahn, A.B.: Topological sorting of large networks. Commun. ACM 5(11), 558–562 (1962). https://doi.org/10.1145/368996.369025

    Article  MATH  Google Scholar 

  14. Kauffman, S.: nfer – a tool for event stream abstraction. In: Calinescu, R., Păsăreanu, C.S. (eds.) SEFM 2021. LNCS, vol. 13085, pp. 103–109. Springer, Cham (2021). https://doi.org/10.1007/978-3-030-92124-8_6

    Chapter  Google Scholar 

  15. Kauffman, S.: Runtime monitoring for uncertain times. Ph.D. thesis, University of Waterloo, Department of Electrical and Computer Engineering, Waterloo, ON, Canada (2021). http://hdl.handle.net/10012/16853

  16. Kauffman, S.: Website (2022). http://nfer.io/. Accessed January 2022

  17. Kauffman, S., Dunne, M., Gracioli, G., Khan, W., Benann, N., Fischmeister, S.: Palisade: a framework for anomaly detection in embedded systems. J. Syst. Architect. 113, 101876 (2021). https://doi.org/10.1016/j.sysarc.2020.101876

    Article  Google Scholar 

  18. Kauffman, S., Havelund, K., Joshi, R.: nfer – a notation and system for inferring event stream abstractions. In: Falcone, Y., Sánchez, C. (eds.) RV 2016. LNCS, vol. 10012, pp. 235–250. Springer, Cham (2016). https://doi.org/10.1007/978-3-319-46982-9_15

    Chapter  Google Scholar 

  19. Kauffman, S., Havelund, K., Joshi, R., Fischmeister, S.: Inferring event stream abstractions. Formal Methods Syst. Design 53(1), 54–82 (2018). https://doi.org/10.1007/s10703-018-0317-z

    Article  Google Scholar 

  20. Kauffman, S., Joshi, R., Havelund, K.: Towards a logic for inferring properties of event streams. In: Margaria, T., Steffen, B. (eds.) ISoLA 2016. LNCS, vol. 9953, pp. 394–399. Springer, Cham (2016). https://doi.org/10.1007/978-3-319-47169-3_31

    Chapter  Google Scholar 

  21. Kauffman, S., Zimmermann, M.: The complexity of evaluating nfer. arXiv:2202.13677 (2022)

  22. Luckham, D.: The power of events: an introduction to complex event processing in distributed enterprise systems. In: Bassiliades, N., Governatori, G., Paschke, A. (eds.) RuleML 2008. LNCS, vol. 5321, p. 3. Springer, Heidelberg (2008). https://doi.org/10.1007/978-3-540-88808-6_2

  23. Minsky, M.L.: Computation. Prentice-Hall, Englewood Cliffs (1967)

    MATH  Google Scholar 

  24. Montanari, A., Puppis, G., Sala, P.: Maximal decidable fragments of Halpern and Shoham’s modal logic of intervals. In: Abramsky, S., Gavoille, C., Kirchner, C., Meyer auf der Heide, F., Spirakis, P.G. (eds.) ICALP 2010. LNCS, vol. 6199, pp. 345–356. Springer, Heidelberg (2010). https://doi.org/10.1007/978-3-642-14162-1_29

    Chapter  MATH  Google Scholar 

  25. Montanari, A., Puppis, G., Sala, P., Sciavicco, G.: Decidability of the interval temporal logic ABB over the natural numbers. In: Proceedings of STACS 2010. pp. 597–608. Schloss Dagstuhl - Leibniz-Zentrum für Informatik (2010). https://hal.archives-ouvertes.fr/hal-00717798

  26. Narayan, A., et al.: System call logs with natural random faults: experimental design and application. In: International Workshop on Silicon Errors in Logic - System Effects (SELSE 2017). SELSE-13, IEEE (2017)

    Google Scholar 

  27. Rosser, B.: Explicit bounds for some functions of prime numbers. Am. J. Math. 63(1), 211–232 (1941). http://www.jstor.org/stable/2371291

  28. Suhothayan, S., Gajasinghe, K., Loku Narangoda, I., Chaturanga, S., Perera, S., Nanayakkara, V.: Siddhi: a second look at complex event processing architectures. In: Workshop on Gateway Computing Environments (GCE 2011), pp. 43–50. ACM (2011). https://doi.org/10.1145/2110486.2110493

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Sean Kauffman .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2022 Springer Nature Switzerland AG

About this paper

Check for updates. Verify currency and authenticity via CrossMark

Cite this paper

Kauffman, S., Zimmermann, M. (2022). The Complexity of Evaluating Nfer. In: Aït-Ameur, Y., Crăciun, F. (eds) Theoretical Aspects of Software Engineering. TASE 2022. Lecture Notes in Computer Science, vol 13299. Springer, Cham. https://doi.org/10.1007/978-3-031-10363-6_26

Download citation

  • DOI: https://doi.org/10.1007/978-3-031-10363-6_26

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-031-10362-9

  • Online ISBN: 978-3-031-10363-6

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics