Moving Switching Functions to Continuous Domain Tolga Ayav Department of Computer Engineering ˙ Izmir Institute of Technology 35430 Urla-Izmir Turkey Email: tolgaayav@iyte.edu.tr Hasan S¨ ozer Department of Computer Science Ozyegin University 34794 Cekmekoy-Istanbul Turkey Email: hasan.sozer@ozyegin.edu.tr Abstract—This paper proposes a method for moving switching functions to continuous domain. The benefits of this approach are twofold. First, the elementary calculus works with the transformed functions. Second, this transformation approach facilitates various analyses relying on Boolean algebra and other existing Boolean-based calculi like Boolean difference. We present one of the potential applications and show how MCDC test pairs can be computed solely by means of elemen- tary calculus. 1. Introduction Switching functions (or Boolean functions) are essential abstractions that are used for the specification and analysis of digital systems. They are used for the implementation of basic control structures that steer the control flow during system operation. As such, switching functions constitute fundamental concepts for the design and implementation of systems and software. Boolean algebra is mainly used as the basic mathematical tool for analyzing these functions [1]. In this paper, we introduce a novel analysis approach in which, switching functions are transformed to their counterpart representations in continuous domain. These representations allow the application of elementary calculus for analysis. They support various Boolean-based calculi like Boolean difference. They can also be transformed back to their coun- terpart representations in discrete domain with an inverse transformation. Our approach is subject to a broad range of applications since switching functions are fundamental building blocks for the specification of any harware/software system. In this paper, we present one of these potential applications in the context of test case generation. In particular, we show how a set of test cases can be generated such that these test cases satisfy a structural coverage criterion, namely the modified condition and decision coverage (MCDC). Concerning this specific application of our approach, there already exist other methods to compose a set of test cases that satisfy MCDC [2]. In a broader context, there also exist methods to analyze Boolean expressions in general [3]. However, unlike existing methods, computations in our approach are performed based solely on elementary calculus. To the best of our knowledge, the use of elementary calculus has not been considered for the analysis of switching functions before. The remainder of this paper is organized as follows. In the following section, we provide background information regarding switching functions and introduce the notation we use for Boolean variables and operations. In Section 3, we introduce Boolean difference calculus. In Section 4, we explain our transformation approach for representing switching functions in continuous domain. In Section 5, we illustrate the application of the approach for computing test pairs that satisfy MCDC. Finally, in Section 6, we conclude the paper. 2. Switching Functions In this section, we introduce the basic notation for Boolean variables and operations that take part in switching functions. This notation will be used throughout the rest of the paper. In this study, Boolean variables and operations are de- fined as follows: x ::= F | T x|x 1 Θx 2 , where Θ= {∧ , , , , ⊕}. where x, x 1 and x 2 are boolean variables. Hereby, F and T symbols denote false and true values, respectively. Negation of a variable is denoted as ¬x. In addition, 5 more operators (Θ) can be defined on two different variables. These operators are “”, “”, “”, “”, “”, and they represent AND, OR, NAND, NOR and XOR operations, respectively. We define switching functions as g : B n B where B = {F, T}. For example, g(x)= ¬a b is a switching function where x =[a, b] T is the input vector. The truth table for this function is as follows: a b g(a, b) F F T F T T T F F T T T 2016 IEEE International Conference on Software Quality, Reliability and Security Companion 978-1-5090-3713-1/16 $31.00 © 2016 IEEE DOI 10.1109/QRS-C.2016.40 265 2016 IEEE International Conference on Software Quality, Reliability and Security Companion 978-1-5090-3713-1/16 $31.00 © 2016 IEEE DOI 10.1109/QRS-C.2016.40 265