Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
skip to main content
article

Proof Pearl: Regular Expression Equivalence and Relation Algebra

Published: 01 June 2012 Publication History

Abstract

We describe and verify an elegant equivalence checker for regular expressions. It works by constructing a bisimulation relation between (derivatives of) regular expressions. By mapping regular expressions to binary relations, an automatic and complete proof method for (in)equalities of binary relations over union, composition and (reflexive) transitive closure is obtained. The verification is carried out in the theorem prover Isabelle/HOL, yielding a practically useful decision procedure.

References

[1]
Berghofer, S., Nipkow, T.: Executing higher order logic. In: Callaghan, P., Luo, Z., McKinna, J., Pollack, R. (eds.) Types for Proofs and Programs (TYPES 2000). Lect. Notes in Comp. Sci., vol. 2277, pp. 24-40. Springer (2000).
[2]
Bonsangue, M.M., Caltais, G., Goriac, E., Lucanu, D., J. Rutten, J.M.M., Silva, A.: A decision procedure for bisimilarity of generalized regular expressions. In: Brazilian Symposium on Formal Methods (SBMF 2010). Lect. Notes in Comp. Sci. Springer (2010).
[3]
Boyer, R.S., Moore, J S.: Metafunctions: proving them correct and using them efficiently as new proof procedures. In Boyer, R., Moore, J S. (eds.) The Correctness Problem in Computer Science, pp. 103-184. Academic Press (1981).
[4]
Braibant, T., Pous, D.: An efficient Coq tactic for deciding Kleene algebras. In: Kaufmann, M., Paulson, L. (eds.) Interactive Theorem Proving (ITP 2010). Lect. Notes in Comp. Sci., vol. 6172, pp. 163-178. Springer (2010).
[5]
Brzozowski, J.: Derivatives of regular expressions. J. ACM 11, 481-494 (1964).
[6]
Haftmann, F., Nipkow, T.: Code generation via higher-order rewrite systems. In: Blume, M., Kobayashi, N., Vidal, G. (eds.) Functional and Logic Programming (FLOPS 2010). Lect. Notes in Comp. Sci., vol. 6009, pp. 103-117. Springer (2010).
[7]
Kozen, D.: A completeness theorem for Kleene algebras and the algebra of regular events. Inf. Comput. 110, 366-390 (1994).
[8]
Kozen, D.: On the coalgebraic theory of Kleene algebra with tests. Technical Report, Computing and Information Science, Cornell University. http://hdl.handle.net/1813/10173 (2008).
[9]
Krauss, A., Nipkow, T.: Regular sets and expressions. In: Klein, G., Nipkow, T., Paulson, L.C. (eds.) The Archive of Formal Proofs. Formal proof development. http://afp.sf.net/entries/Regular-Sets.shtml (2010).
[10]
Owens, S., Reppy, J., Turon, A.: Regular-expression derivatives re-examined. J. Funct. Program. 19, 173-190 (2009).
[11]
Rutten, J.J.M.M.: Automata and coinduction (an exercise in coalgebra). In: Sangiorgi, D., de Simone, R. (eds.) Concurrency Theory (CONCUR'98). Lect. Notes in Comp. Sci., vol. 1466, pp. 194-218. Springer (1998).
[12]
Thiemann, R., Sternagel, C.: Certification of termination proofs using CeTA. In: Berghofer, S., Nipkow, T., Urban, C., Wenzel, M. (eds.) Theorem Proving in Higher Order Logics (TPHOLs 2009). Lect. Notes in Comp. Sci., vol. 5674, pp. 452-468. Springer (2009).

Cited By

View all
  1. Proof Pearl: Regular Expression Equivalence and Relation Algebra

    Recommendations

    Comments

    Information & Contributors

    Information

    Published In

    cover image Journal of Automated Reasoning
    Journal of Automated Reasoning  Volume 49, Issue 1
    June 2012
    108 pages

    Publisher

    Springer-Verlag

    Berlin, Heidelberg

    Publication History

    Published: 01 June 2012

    Author Tags

    1. Decision procedure
    2. Isabelle/HOL
    3. Regular expressions

    Qualifiers

    • Article

    Contributors

    Other Metrics

    Bibliometrics & Citations

    Bibliometrics

    Article Metrics

    • Downloads (Last 12 months)0
    • Downloads (Last 6 weeks)0
    Reflects downloads up to 12 Jan 2025

    Other Metrics

    Citations

    Cited By

    View all
    • (2024)Diagrammatic Algebra of First Order LogicProceedings of the 39th Annual ACM/IEEE Symposium on Logic in Computer Science10.1145/3661814.3662078(1-15)Online publication date: 8-Jul-2024
    • (2024)Well-Behaved (Co)algebraic Semantics of Regular Expressions in DafnyTheoretical Aspects of Computing – ICTAC 202410.1007/978-3-031-77019-7_3(43-61)Online publication date: 25-Nov-2024
    • (2023)POSIX Lexing with Derivatives of Regular ExpressionsJournal of Automated Reasoning10.1007/s10817-023-09667-167:3Online publication date: 8-Jul-2023
    • (2022)Verbatim++: verified, optimized, and semantically rich lexing with derivativesProceedings of the 11th ACM SIGPLAN International Conference on Certified Programs and Proofs10.1145/3497775.3503694(27-39)Online publication date: 17-Jan-2022
    • (2019)Kleene Algebra with HypothesesFoundations of Software Science and Computation Structures10.1007/978-3-030-17127-8_12(207-223)Online publication date: 8-Apr-2019
    • (2018)Regular Language Representations in the Constructive Type Theory of CoqJournal of Automated Reasoning10.1007/s10817-018-9460-x61:1-4(521-553)Online publication date: 1-Jun-2018
    • (2016)Proving language inclusion and equivalence by coinductionInformation and Computation10.1016/j.ic.2015.11.009246:C(62-76)Online publication date: 1-Feb-2016
    • (2016)Building program construction and verification tools from algebraic principlesFormal Aspects of Computing10.1007/s00165-015-0343-128:2(265-293)Online publication date: 1-Apr-2016
    • (2015)Shape analysis in a functional language by using regular languagesScience of Computer Programming10.1016/j.scico.2014.12.006111:P1(51-78)Online publication date: 1-Nov-2015
    • (2014)A Formalisation of the Myhill-Nerode Theorem Based on Regular ExpressionsJournal of Automated Reasoning10.1007/s10817-013-9297-252:4(451-480)Online publication date: 1-Apr-2014
    • Show More Cited By

    View Options

    View options

    Media

    Figures

    Other

    Tables

    Share

    Share

    Share this Publication link

    Share on social media