Exact finite-state machine identification from scenarios and temporal properties

  • Vladimir Ulyantsev
  • Igor Buzhinsky
  • Anatoly Shalyto
Regular Paper
  • 96 Downloads

Abstract

Finite-state models, such as finite-state machines (FSMs), aid software engineering in many ways. They are often used in formal verification and also can serve as visual software models. The latter application is associated with the problems of software synthesis and automatic derivation of software models from specification. Smaller synthesized models are more general and are easier to comprehend, yet the problem of minimum FSM identification has received little attention in previous research. This paper presents four exact methods to tackle the problem of minimum FSM identification from a set of test scenarios and a temporal specification represented in linear temporal logic. The methods are implemented as an open-source tool. Three of them are based on translations of the FSM identification problem to SAT or QSAT problem instances. Accounting for temporal properties is done via counterexample prohibition. Counterexamples are either obtained from previously identified FSMs, or based on bounded model checking. The fourth method uses backtracking. The proposed methods are evaluated on several case studies and on a larger number of randomly generated instances of increasing complexity. The results show that the Iterative SAT-based method is the leader among the proposed methods. The methods are also compared with existing inexact approaches, i.e., the ones which do not necessarily identify the minimum FSM, and these comparisons show encouraging results.

Keywords

Finite-state machine identification Linear temporal logic Model checking SAT QSAT 

References

  1. 1.
    Alur, R., Martin, M., Raghothaman, M., Stergiou, C., Tripakis, S., Udupa, A.: Synthesizing finite-state protocols from scenarios and requirements. In: Hardware and Software: Verification and Testing, pp. 75–91. Springer (2014)Google Scholar
  2. 2.
    Amla, N., Du, X., Kuehlmann, A., Kurshan, R.P., McMillan, K.L.: An analysis of SAT-based model checking techniques in an industrial environment. In: Correct Hardware Design and Verification Methods, pp. 254–268. Springer (2005)Google Scholar
  3. 3.
    Beschastnikh, I., Brun, Y., Schneider, S., Sloan, M., Ernst, M.D.: Leveraging existing instrumentation to automatically infer invariant-constrained models. In: Proceedings of the 19th ACM SIGSOFT Symposium and the 13th European Conference on Foundations of Software Engineering, pp. 267–277. ACM (2011)Google Scholar
  4. 4.
    Biere, A., Cimatti, A., Clarke, E.M., Strichman, O., Zhu, Y.: Bounded model checking. Adv. Comput. 58, 117–148 (2003)CrossRefGoogle Scholar
  5. 5.
    Bodik, R., Jobstmann, B.: Algorithmic program synthesis: introduction. Int. J. Software Tools Technol. Trans. 15(5–6), 397–411 (2013)CrossRefGoogle Scholar
  6. 6.
    Broy, M., Jonsson, B., Katoen, J.P., Leucker, M., Pretschner, A. (eds.): Model-based testing of reactive systems: advanced lectures. Lecture Notes in Computer Science, vol. 3472. Springer (2005)Google Scholar
  7. 7.
    Cheng, C.H., Huang, C.H., Ruess, H., Stattelmann, S.: G4LTL-ST: Automatic generation of PLC programs. In: Computer Aided Verification, pp. 541–549. Springer (2014)Google Scholar
  8. 8.
    Chivilikhin, D., Ulyantsev, V.: MuACOsm: a new mutation-based ant colony optimization algorithm for learning finite-state machines. In: Proceedings of the 15th Annual Conference on Genetic and Evolutionary Computation (GECCO), pp. 511–518. ACM (2013)Google Scholar
  9. 9.
    Chivilikhin, D., Ulyantsev, V., Shalyto, A.: Combining exact and metaheuristic techniques for learning extended finite-state machines from test scenarios and temporal properties. In: Proceedings of the 13th International Conference on Machine Learning and Applications (ICMLA), pp. 350–355. IEEE (2014)Google Scholar
  10. 10.
    Chongstitvatana, P., Aporntewan, C.: Improving correctness of finite-state machine synthesis from multiple partial input/output sequences. In: Proceedings of the 1st NASA/DoD Workshop on Evolvable Hardware, pp. 262–266. IEEE (1999)Google Scholar
  11. 11.
    Chow, T.S.: Testing software design modeled by finite-state machines. IEEE Trans. Software Eng. 4(3), 178–187 (1978)CrossRefMATHGoogle Scholar
  12. 12.
    Clarke, E.M., Grumberg, O., Peled, D.: Model checking. MIT press, USA (1999)Google Scholar
  13. 13.
    Dorigo, M., Stützle, T.: Ant colony optimization. MIT Press, USA (2004)MATHGoogle Scholar
  14. 14.
    Duret-Lutz, A.: Manipulating LTL formulas using Spot 1.0. In: Automated technology for verification and analysis, pp. 442–445. Springer (2013)Google Scholar
  15. 15.
    Eén, N., Sörensson, N.: Temporal induction by incremental SAT solving. Electr. Notes Theor. Comp. Sci. 89(4), 543–560 (2003)CrossRefMATHGoogle Scholar
  16. 16.
    Ehlers, R.: Unbeast: Symbolic bounded synthesis. In: Abdulla, P., Leino, K. (eds.) Tools and Algorithms for the Construction and Analysis of Systems. Lecture Notes in Computer Science, vol. 6605, pp. 272–275. Springer, Berlin Heidelberg (2011)Google Scholar
  17. 17.
    Ehlers, R.: Symbolic bounded synthesis. Formal Methods Syst. Design 40(2), 232–262 (2012)CrossRefMATHGoogle Scholar
  18. 18.
    Filiot, E., Jin, N., Raskin, J.F.: An antichain algorithm for LTL realizability. In: Computer Aided Verification, pp. 263–277. Springer (2009)Google Scholar
  19. 19.
    Finkbeiner, B., Jacobs, S.: Lazy synthesis. In: International Workshop on Verification, Model Checking, and Abstract Interpretation, pp. 219–234. Springer (2012)Google Scholar
  20. 20.
    Finkbeiner, B., Schewe, S.: Bounded synthesis. Int. J. Software Tools Technol. Trans. 15(5–6), 519–539 (2013)CrossRefMATHGoogle Scholar
  21. 21.
    Gold, E.M.: Complexity of automaton identification from given data. Inform. Contr. 37(3), 302–320 (1978)MathSciNetCrossRefMATHGoogle Scholar
  22. 22.
    Heule, M.J., Verwer, S.: Exact DFA identification using SAT solvers. In: Grammatical Inference: Theoretical Results and Applications, pp. 66–79. Springer (2010)Google Scholar
  23. 23.
    Heule, M.J., Verwer, S.: Software model synthesis using satisfiability solvers. Empir. Software Eng. 18(4), 825–856 (2013)CrossRefGoogle Scholar
  24. 24.
    Hölldobler, S., Nguyen, V.H.: On SAT-encodings of the at-most-one constraint. In: Proceedings of the 12th International Workshop on Constraint Modelling and Reformulation, Uppsala, Sweden, pp. 16–20 (2013)Google Scholar
  25. 25.
    Jackson, P.B., Sheridan, D.: A compact linear translation for bounded model checking. Electr. Notes Theor. Comp. Sci. 174(3), 17–30 (2007)CrossRefMATHGoogle Scholar
  26. 26.
    Jobstmann, B., Bloem, R.: Optimizations for LTL synthesis. In: Formal Methods in Computer Aided Design (FMCAD), pp. 117–124. IEEE (2006)Google Scholar
  27. 27.
    Lang, K.J., Pearlmutter, B.A., Price, R.A.: Results of the Abbadingo One DFA learning competition and a new evidence-driven state merging algorithm. In: Grammatical Inference, pp. 1–12. Springer (1998)Google Scholar
  28. 28.
    Lo, D., Mariani, L., Pezzè, M.: Automatic steering of behavioral model inference. In: 7th Joint Meeting of the European Software Engineering Conference and the ACM SIGSOFT Symposium on the Foundations of Software Engineering (ESEC-FSE), pp. 345–354. ACM (2009)Google Scholar
  29. 29.
    Lonsing, F., Bacchus, F., Biere, A., Egly, U., Seidl, M.: Enhancing search-based QBF solving by dynamic blocked clause elimination. In: Proceedings of the 20th International Conference on Logic for Programming, Artificial Intelligence and Reasoning (LPAR), Lecture Notes in Computer Science (to appear). Springer (2015)Google Scholar
  30. 30.
    Mitchell, M.: An introduction to genetic algorithms. MIT press, USA (1998)MATHGoogle Scholar
  31. 31.
    Ohmann, T., Herzberg, M., Fiss, S., Halbert, A., Palyart, M., Beschastnikh, I., Brun, Y.: Behavioral resource-aware model inference. In: Proceedings of the 29th ACM/IEEE International Conference on Automated Software Engineering (ASE), pp. 19–30. ACM (2014)Google Scholar
  32. 32.
    Pnueli, A.: The temporal logic of programs. In: 18th Annual Symposium on Foundations of Computer Science, 1977, pp. 46–57. IEEE (1977)Google Scholar
  33. 33.
    Rosner, R.: Modular synthesis of reactive systems. Ph.D. thesis, Weizmann Institute of Science (1992)Google Scholar
  34. 34.
    Tsarev, F., Egorov, K.: Finite state machine induction using genetic algorithm based on testing and model checking. In: 13th Annual Conference Companion on Genetic and Evolutionary Computation (GECCO), pp. 759–762. ACM (2011)Google Scholar
  35. 35.
    Ulyantsev, V., Tsarev, F.: Extended finite-state machine induction using SAT-solver. In: Proceedings of the 14th IFAC Symposium “Information Control Problems in Manufacturing (INCOM)”, pp. 512–517. IFAC (2012)Google Scholar
  36. 36.
    Ulyantsev, V., Zakirzyanov, I., Shalyto, A.: BFS-based symmetry breaking predicates for DFA identification. In: Language and Automata Theory and Applications, pp. 611–622. Springer (2015)Google Scholar
  37. 37.
    Vyatkin, V.: IEC 61499 function blocks for embedded and distributed control systems design, Second ed. Instrumentation Society of America (2012)Google Scholar
  38. 38.
    Walkinshaw, N., Bogdanov, K.: Inferring finite-state models with temporal constraints. In: Proceedings of the 23rd IEEE/ACM International Conference on Automated Software Engineering (ASE), pp. 248–257. IEEE Computer Society (2008)Google Scholar
  39. 39.
    Walkinshaw, N., Taylor, R., Derrick, J.: Inferring extended finite state machine models from software executions. Empir. Software Eng. 21(3), 811–853 (2016)CrossRefGoogle Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 2016

Authors and Affiliations

  • Vladimir Ulyantsev
    • 1
  • Igor Buzhinsky
    • 1
    • 2
  • Anatoly Shalyto
    • 1
  1. 1.Computer Technologies LaboratoryITMO UniversitySt. PetersburgRussia
  2. 2.Department of Electrical Engineering and AutomationAalto UniversityEspooFinland

Personalised recommendations