Complete Test Suites for Automata in Monoidal Closed Categories

Bálint Kocsis,Jurriaan Rot
2024-11-20
Abstract:Conformance testing of automata is about checking the equivalence of a known specification and a black-box implementation. An important notion in conformance testing is that of a complete test suite, which guarantees that if an implementation satisfying certain conditions passes all tests, then it is equivalent to the specification. We introduce a framework for proving completeness of test suites at the general level of automata in monoidal closed categories. Moreover, we provide a generalization of a classical conformance testing technique, the W-method. We demonstrate the applicability of our results by recovering the W-method for deterministic finite automata, Moore machines, and Mealy machines, and by deriving new instances of complete test suites for weighted automata and deterministic nominal automata.
Formal Languages and Automata Theory,Logic in Computer Science
What problem does this paper attempt to address?
The problem that this paper attempts to solve is: to establish and prove the theoretical framework of a complete test suite in a broader class of machines (especially automata in monoidal closed categories) to ensure the equivalence between implementation and specification. Specifically, it aims to generalize the classical W - method and provide new complete test suite examples for deterministic finite automata, Moore machines, Mealy machines, weighted automata, and deterministic nominal automata, etc. ### Problem Background In conformance testing, the goal is to verify whether a known specification and a black - box implementation are equivalent. For deterministic finite automata (DFA), this is usually accomplished by constructing a complete test suite, which can ensure that if an implementation passes all tests, it is equivalent to the specification. However, the existing complete test suites mainly focus on Mealy machines and DFA, and lack corresponding theoretical support for other types of automata, such as weighted automata and deterministic nominal automata. ### Main Contributions of the Paper 1. **Generalizing the W - method**: The paper generalizes the classical W - method so that it is applicable to automata in monoidal closed categories. The W - method is a classical method for constructing complete test suites and can ensure the completeness of the test suite under a given state number limit. 2. **Framework Construction**: The author provides a framework for proving the completeness of test suites for automata in monoidal closed categories. This framework is based on the concept of bisimulation and can be applied in specific examples. 3. **New Examples**: Through this framework, the paper recovers the known complete test suites and provides new complete test suite examples for weighted automata and deterministic nominal automata. ### Key Concepts - **Complete Test Suite**: A set of tests that can ensure the equivalence between implementation and specification under specific conditions. - **W - method**: A method for constructing complete test suites, based on state cover and characterization set. - **Monoidal Closed Categories**: A class of mathematical structures that allow automata to be regarded as both algebras and coalgebras simultaneously, thus providing an abstract framework for conformance testing. ### Formula Examples In the paper, some of the key formulas involved include: - Definitions of state cover \(P\) and characterization set \(W\): - State cover \(P\) is a set of words containing access sequences such that each state can be reached through these sequences. - Characterization set \(W\) is a set of words that can distinguish non - equivalent states. - Definition of the test suite in the W - method: \[ T^k_{P,W}=P\cdot\Sigma^{\leq k + 1}\cdot W \] where \(P\) is the state cover, \(W\) is the characterization set, and \(k\) is a natural number. Through these formulas and concepts, the paper successfully generalizes the W - method and constructs complete test suites for more types of automata.