A Synthesis Method for
Quaternary Quantum Logic Circuits
Abstract
Synthesis of quaternary quantum circuits involves basic quaternary gates and logic operations in the quaternary quantum domain. In this paper, we propose new projection operations and quaternary logic gates for synthesizing quaternary logic functions. We also demonstrate the realization of the proposed gates using basic quantum quaternary operations. We then employ our synthesis method to design of quaternary adder and some benchmark circuits. Our results in terms of circuit cost, are better than the existing works.
Keywords:
Quaternary algebra, Quaternary quantum logic gates, Quaternary logic synthesis, Quaternary adder1 Introduction
Quaternary quantum computing is gaining importance in the field of quantum information theory and quantum cryptography as it can represent a Galois Field(4) quantum system by the basis states , , and . The unit of information is called a qudit which is characterized by a wave function [1, 2] expressed as a linear superposition of basis states. Multi-valued quantum algebra comprises the rules for a set of basic logic operations that can be performed on qudits. While in [3] the structure of a multi-valued logic gate is proposed which is experimentally feasible with a linear ion trap scheme for quantum computing; this approach can produce large dimensional circuits. A universal architecture for multi-valued reversible logic is given in [4], but quantum realization of the circuits thus obtained is not apparent. The universality of -qudit gates is presented in [5], but no algorithms for synthesis were given. Al-Rabedi et al. proposed in [6] the minimization technique for multi-valued quantum Galois field sum of products (QGFSOP). Quaternary logic is one of the promising multi-valued quantum logic systems. The binary logic functions can be expressed by grouping -bits together into equivalent quaternary value [7]. This theoretically reduces the total volume of the physical devices needed to approximately , i.e. the volume needed for binary system [7].
The realization of a given quaternary quantum function as a quantum circuit requires a set of gates for the quaternary logic operations. In [8], the realization of quaternary Feynman and Toffoli gates using -qudit and -qudit quaternary Muthukrishnan-Stroud gates (M-S Gate)[3] are illustrated. The QGFSOP expressions can be realized by using these Feynman and Toffoli gates [8]. The method of synthesizing incompletely specified multi-output quaternary function using quaternary -qudit gates and multi-qudit controlled gates has been proposed in [9]. But this synthesis method is not applicable for any arbitrary quaternary functions. In [10], a heuristic alogorithm is proposed for minimization of a QGFSOP expression for multi-output quaternary logic functions using a Quaternary Galois Field Decission Diagram (QGFDD). But no quantum gate level implementation was provided. In this paper, our specific contributions are as follows:
-
new projection operation for synthesizing quaternary logic functions;
-
new quaternary logic gates, namely Generalized Quaternary Gate (), permutative quaternary Controlled Cyclic Shift gate () and Modulo addition gate;
-
new simplification rules for reduction in gate count and circuit levels for multivalued quantum circuits.
The rest of the paper is organized as follows. We provide the preliminary concepts of multivalued quantum computing in section 1. We propose the qua- ternary algebra with a new projection operation in section 2. In section 3, we introduce some new quaternary logic gates. The proposed synthesis methodology along with its simplification rules are presented in section 4. The synthesis results for some example circuits and their comparison with related work are given in section 5. Concluding remarks appear in section 6.
2 Quaternary Algebra
A brief summary of the quaternary addition, multiplication and NOT operations as well as the quaternary projection operations , and (the new one) are presented next. .
2.1 GF(4) arithmetic
Quaternary Galois field GF(4) is an algebraic structure consisting the set of elements Q={0, 1, 2, 3}. The addition () and multiplication (.) operations over GF(4) are shown in the Table 1.
| . | |||||||||
|---|---|---|---|---|---|---|---|---|---|
| 0 | 0 | 1 | 2 | 3 | 0 | 0 | 0 | 0 | 0 |
| 1 | 1 | 0 | 3 | 2 | 1 | 0 | 1 | 2 | 3 |
| 2 | 2 | 3 | 0 | 1 | 2 | 0 | 2 | 3 | 1 |
| 3 | 3 | 2 | 1 | 0 | 3 | 0 | 3 | 1 | 2 |
2.2 Quaternary Logical NOT
The logical NOT in quaternary quantum system is defined as , where denotes the modulo 4 addition, and ={0, 1, 2, 3}.
2.3 Quaternary Projection Operations , and
We present nine projection operations, grouped into three types , , and , where = {, , , }. While and types were defined earlier [11, 12] as
= if = and otherwise, and
= if = and otherwise.
We introduce the new type operations, which are defined as
= 3 if a = and a = otherwise.
Table 2 presents the truth tables for , , and types of operators as well as for the derived operators , and . The , and operations are commutative, associative and distributive over AND and OR logic.
| 0 | 1 | 2 | 3 | 0 | 1 | 2 | 3 | 0 | 1 | 2 | 3 | 0 | 1 | 2 | 3 | ||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 | 0 | 0 | 0 | 0 | 0 | 2 | 0 | 0 | 1 | 1 | 1 | 2 | 2 | 0 | 2 | ||||
| 0 | 1 | 0 | 0 | 0 | 0 | 0 | 2 | 1 | 0 | 1 | 1 | 2 | 2 | 2 | 0 | ||||
| 0 | 0 | 1 | 0 | 3 | 0 | 0 | 0 | 1 | 1 | 0 | 1 | 0 | 3 | 3 | 3 | ||||
| 0 | 0 | 0 | 1 | 0 | 3 | 0 | 0 | 1 | 1 | 1 | 0 | 3 | 0 | 3 | 3 | ||||
| 2 | 0 | 0 | 0 | 0 | 0 | 3 | 0 | 0 | 2 | 2 | 2 | 3 | 3 | 0 | 3 | ||||
| 0 | 2 | 0 | 0 | 0 | 0 | 0 | 3 | 2 | 0 | 2 | 2 | 3 | 3 | 3 | 0 |
3 Quaternary Logic Gates
The definitions of the existing quaternary logic gates as well as a few newly introduced quaternary logic gates are provided below. We also show the implementation of the newly proposed gates using basic quantum ternary operations.
3.1 Quaternary Feynman, Quaternary Toffoli, MAX and MIN gates
The -qudit Quaternary Feynman gate [8] is defined as:
Feynman(, ) = + , where ’+’ operator is addition over GF(4)(Figure 1.a).
The quaternary -qudit Toffoli gate [8], shown in Figure 1.b is defined as:
Toffoli, where and are the control inputs and the target input, ’+’ and ’.’ operators are addition and multiplication over GF(4). We use the quaternary and gates [13] respectively to replace the OR and the AND gates. These two gates are defined as
MAX(, )=
MIN(, ) =
where = (Figures 2.a, 2.b). The quaternary Feynman and Toffoli gates can be realized using quaternary M-S gates [7, 8], defined as (Figure 2.c)
M-S(, ) = operation on if = , otherwise , where is one of the shift operations [10] shown in Table 3.
| Symbol | Operation | Symbol | Operation | Symbol | Operation | Symbol | Operation |
|---|---|---|---|---|---|---|---|
| = | = | = | = | ||||
| = | = | = | = | ||||
| = | = | = | = | ||||
| = | = | = | = | ||||
| = | = | = | = | ||||
| = | = | = | = |
3.2 Generalized Quaternary Gate
A new generalized quaternary gate (GQG) is required to realize the 24 shift operations [10] given in the Table 3. It is a multi-qudit gate shown in Figure 3.a. The controlling input of GQG can be used to select the -qudit shift operation on the target input. The GQG is formally defined as
=
The realization of a GQG gate using quaternary M-S gates, is shown in Figure 3.b.
Implementation of , and operations using GQG
We can implement the , and operations by using a GQG, as shown in Figures 4.a, 4.b and 4.c respectively. For , and type operations, we set GQG(a,1), GQG(a,2) and GQG(a,3) respectively.
3.3 Quaternary Controlled Cyclic Shift gate
We propose a new -qudit gate, used for realizing the simplification rules for quaternary minterms, as
where the values of the inputs are from the set {1, 2, 3} and is the cyclic shift operation defined in Table 3. The symbolic representation of is shown in Figure 5.a and an instance of this gate is shown in Figure 5.b, where shift operation is applied on if , or , . The realization of the gate using M-S gates is shown in Figure 6.
3.4 A new Modulo Addition Gate
We introduce the new -qudit quaternary Modulo Addition gate as: ADD(A, B)= , where represent the modulo addition. This gate can be used as a template for simplification of adder circuits. The symbolic representation of ADD gate is shown in Figure 7.a and the realization using quaternary M-S gate is shown in Figure 7.b
4 Proposed Synthesis Methodology
4.1 Overview
Consider an -variable quaternary quantum logic function
= (minterms for one )i + (minterms for two)j + (minterms for three)k,
where implies logical quaternary OR, n, p and s are respectively the number of input vectors for which is , and . Thus, is 0 for of the input vectors. We express the minterms for one, two and three using the , and operations respectively. From Table II, we can state that
=
=
=
=
=
where .
Hence, the minterms for which are
1. ,
2. ,
3. ,
4. ,
5.
Similarly from Table 2, the minterms for which are
1. ,
2. ,
3. ,
4. ,
5.
The minterms for which are
1. ,
2. ,
3. ,
4. ,
5. .
4.2 Simplification Rules
Next, we define six simplification rules derived from Table 2
1. , and
2. , and
3. , and
4. , and
5. , and
6. , and
Simplification Rules for reducing ancilla qudits
For gate level realization of , , and we need an ancilla qudit for each of them. Further, to synthesize an -variable quaternary function with minterms specified in our proposed methodology, we have maximum of ancilla qudits. However, we can reduce the number of ancilla qudits by the following three simplification rules based on the new quaternary gate and Table 2:
7. ,
and Where , ={1, 2, 3}
8. , and
9. , , and
, .
5 Synthesis of Quaternary Functions
5.1 -qudit Quaternary Arbitrary Function
The truth table for the -qudit arbitrary function is given in Table 4.
| a , b | 00 | 01 | 02 | 03 | 10 | 11 | 12 | 13 | 20 | 21 | 22 | 23 | 30 | 31 | 32 | 33 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 0 | 3 | 1 | 2 | 3 | 3 | 2 | 0 | 1 | 2 | 1 | 3 | 2 | 1 | 3 | 2 |
We re-write the function using our proposed methodology as
= +
By using simplification rules and , we get
=
5.2 Quaternary Adder
We synthesize the -qudit half and full adder circuits using our proposed methodology and these circuits are simplified with the use of Modulo4 Addition gate. But the details are not provided due to limitation of space. The gate level implementation of -qudit half and full adder are shown in Figure and respectively.
5.3 Comparison of Results
The quantum cost of the half and the full adder circuits, as shown in Figures 10 and 11, and of the benchmark circuits such as , , , are evaluated in terms of the number of M-S gates used. The number of M-S gates required to realize a -qudit Feynman gate, a -qudit Toffoli, and gates are 5, 17, 6, 6 respectively [7, 13]. To realize the new GQG, , ADD gates we need 8 M-S gates for each of them. The M-S gate count cost comparison of our circuits with that in [14] are given in Table 6. While the second column of the table indicates the maximum number of ancilla qudits required to synthesize the above mentioned circuits, the third column shows the number of ancilla qudits required after using our simplification rules in Section 4.2. The columns 4, 5 and 6 establish that although our design has a small increase in cost for the circuits , , , the results for the -qudit quaternary half and full adder shows that there is more than reduction in the M-S gate count cost compared to [14].
| # Levels | Total Cost | |||||
|---|---|---|---|---|---|---|
| Circuit | maximum ancilla qudits | Reduced ancilla qudits | Ours | [14] | Ours | [14] |
| Half Adder | 36 | 6 | 6 | 23 | 46 | 114 |
| Full Adder | 120 | 17 | 17 | 40 | 128 | 304 |
| Sum2 | 24 | 0 | 4 | - | 8 | - |
| mul2 | 16 | 5 | 5 | - | 40 | - |
| ham3 | 135 | 95 | 25 | - | 135 | - |
| rd53 | 275 | 245 | 15 | - | 120 | - |
| rd73 | 475 | 435 | 35 | - | 280 | - |
| xor5 | 150 | 120 | 7 | - | 56 | - |
6 Conclusion
In this paper, we have proposed a methodology for logic synthesis of quaternary quantum circuits. We have defined a minterm based approach of expressing a quaternary logic function using , and operations. We have also stated the simplification rules for the method. Quaternary half adder, full adder and some benchmark circuits synthesized by our method, use fewer ternary quantum gates and hence reduce quantum realization cost compared to earlier method in [14]. While the number of levels is fewer in our synthesis, the number of ancilla bits is higher. A synthesis methodology for reduction of the number of ancilla qudits is being investigated.
References
- [1] M. A. Nielsen and I. L. Chuang, Quantum Computation and Quantum Information, Cambridge University Press , 2002.
- [2] A. Ekert and A. Zeilinger, The physics of quantum information, Springer Verlag, Berlin, 2002, pp. 1-14.
- [3] A. Muthukrishnan and C. R. Stroud Jr., Multi-Valued Logic Gates for Quantum Computation, Phys. Rev. A62, 2000, pp. 0523091-8.
- [4] P. Picton, A Universal Architecture for Multiple-Valued Reversible Logic, Multiple-Valued Logic - An International Journal, Vol. 5, 2000, pp. 27-37
- [5] J. L. Brylinski and R. Brylinski, Universal Quantum Gates, (to appear in Mathematics of Quantum Computation, CRC Press, 2002) LANL e-print quant-ph/010862.
- [6] M. Perkowski, A. Al-Rabadi, P. Kerntopf, A. Mishchenko, and M. Chrzanowska-Jeske, Three-Dimensional Realization of Multivalued Functions Using Reversible Logic, Booklet of 10th Int. Workshop on Post-Binary Ultra-Large-Scale Integration Systems (ULSI), Warsaw, Poland, May 2001, pp.47- 53
- [7] M.M.M Khan, A. K. Biswas, S. Chowdhury, M.Tanzid, K.M.Mohsin, M. Hasan, A. I. Khan , Quantum realization of some quaternary circuits, TENCON 2008 - 2008 IEEE Region 10 Conference , vol., no., pp.1-5, 19-21 Nov. 2008
- [8] M. H. Khan, Quantum Realization of Quaternary Feynman and Toffoli Gates Electrical and Computer Engineering, 2006. ICECE ’06. International Conference on , vol., no., pp.157-160, 19-21 Dec. 2006
- [9] M. H. Khan, Synthesis of incompletely specified multi-output quaternary function using quaternary quantum gates, Computer and information technology, 2007. iccit 2007. 10th international conference on , vol., no., pp.1-6, 27-29 Dec. 2007
- [10] M.H.A. Khan, N.K. Siddika, M.A. Perkowski, Minimization of Quaternary Galois Field Sum of Products Expression for Multi-Output Quaternary Logic Function Using Quaternary Galois Field Decision Diagram, Multiple Valued Logic, 2008. ISMVL 2008. 38th International Symposium on , vol., no., pp.125-130, 22-24 May 2008
- [11] S.B.Mandal, A. Chakrabarti, and S. Sur-Kolay, Synthesis Technique for Ternary Quantum Logic, 41 th International Symposium on Multiple-Valued Logic, Tuusula, 2011, pp. 218-223.
- [12] R. L. Herrmann, Selection and implementation of a ternary switching algebra, Spring Joint Computer Conference, Atlantic City, 1968, pp. 283-290 .
- [13] N. Giesecke, D. H. Kim, S. Hossain and M. Perkowski, Search for Universal Ternary Quantum Gate Sets with Exact Minimum Costs, Proceedings of RM Symposium, Oslo, May 16, 2007.
- [14] M. H. A. Khan, A recursive method for synthesizing quantum/reversible quaternary parallel adder/subtractor with look-ahead carry Journal of Systems Architecture 54 (2008) 1113–1121 .