White Dots do Matter: Rewriting Reversible Logic Circuits

  • Mathias Soeken
  • Michael Kirkedal Thomsen
Part of the Lecture Notes in Computer Science book series (LNCS, volume 7948)


The increased effort in recent years towards methods for computer aided design of reversible logic circuits has also lead to research in algorithms for optimising the resulting circuits; both with higher-level data structures and directly on the reversible circuits. To obtain structural patterns that can be replaced by a cheaper realisation, many direct algorithms apply so-called moving rules; a simple form of rewrite rules that can only swap gate order.

In this paper we first describe the few basic rules that are needed to perform rewriting directly on reversible logic circuits made from general Toffoli circuits. We also show how to use these rules to derive more complex formulas. The major difference compared to existing approaches is the use of negative controls (white dots), which significantly increases the algebraic strength. We show how existing optimisation approaches can be adapted as problems based on our rewrite rules.

Finally, we outline a path to generalising the rewrite rules by showing their forms for reversible control-gates. This can be used to expand our method to other gates such as the controlled-swap gate or quantum gates.


Reversible logic term rewriting circuit optimisation circuit equivalence 


Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.


  1. 1.
    Abdessaied, N., Soeken, M., Wille, R., Drechsler, R.: Exact template matching using Boolean satisfiability. In: Int’l. Symp. on Multiple-Valued Logic, ISMVL (2013)Google Scholar
  2. 2.
    Arabzadeh, M., Saeedi, M., Zamani, M.S.: Rule-based optimization of reversible circuits. In: Asia and South-Pacific Design Automation Conference, ASP-DAC, pp. 849–854 (2010)Google Scholar
  3. 3.
    Axelsen, H.B., Thomsen, M.K.: Garbage-free reversible integer multiplication with constants of the form 2k±2l±1. In: Glück, R., Yokoyama, T. (eds.) RC 2012. LNCS, vol. 7581, pp. 171–182. Springer, Heidelberg (2013)CrossRefGoogle Scholar
  4. 4.
    Baader, F., Nipkow, T.: Term rewriting and all that. Cambridge University Press, New York (1998)Google Scholar
  5. 5.
    Cuccaro, S.A., Draper, T.G., Kutin, S.A., Moulton, D.P.: A new quantum ripple-carry addition circuit arXiv:quant-ph/0410184v1 (2005)Google Scholar
  6. 6.
    Feynman, R.P.: Quantum mechanical computers. Optics News 11, 11–20 (1985)CrossRefGoogle Scholar
  7. 7.
    Fredkin, E., Toffoli, T.: Conservative logic. International Journal of Theoretical Physics 21(3-4), 219–253 (1982)MathSciNetzbMATHCrossRefGoogle Scholar
  8. 8.
    Iwama, K., Kambayashi, Y., Yamashita, S.: Transformation rules for designing cnot-based quantum circuits. In: Design Automation Conference, DAC 2002, pp. 419–424. ACM (2002)Google Scholar
  9. 9.
    Landauer, R.: Irreversibility and heat generation in the computing process. IBM Journal of Research and Development 5(3), 183–191 (1961)MathSciNetzbMATHCrossRefGoogle Scholar
  10. 10.
    Maslov, D., Miller, D.M., Dueck, G.W.: Fredkin/Toffoli templates for reversible logic synthesis. In: Int’l Conf. on Computer Aided Design, ICCAD, pp. 256–261 (2003)Google Scholar
  11. 11.
    Miller, D.M., Maslov, D., Dueck, G.W.: A transformation based algorithm for reversible logic synthesis. In: Design Automation Conference, DAC, pp. 318–323 (2003)Google Scholar
  12. 12.
    Regergem, Y.V., Vos, A.D.: Young subgroups for reversible computers. Advances in Mathematics of Communications 2(2), 183–200 (2008)MathSciNetCrossRefGoogle Scholar
  13. 13.
    Soeken, M., Wille, R., Hilken, C., Przigoda, N., Drechsler, R.: Synthesis of reversible circuits with minimal lines for large functions. In: Asia and South-Pacific Design Automation Conference, ASP-DAC, pp. 85–92 (2012)Google Scholar
  14. 14.
    Thomsen, M.K.: Describing and optimising reversible logic using a functional language. In: Gill, A., Hage, J. (eds.) IFL 2011. LNCS, vol. 7257, pp. 148–163. Springer, Heidelberg (2012)CrossRefGoogle Scholar
  15. 15.
    Thomsen, M.K.: A functional language for describing reversible logic. In: Specification & Design Languages, FDL, pp. 135–142. IEEE (2012)Google Scholar
  16. 16.
    Thomsen, M.K., Glück, R., Axelsen, H.B.: Reversible arithmetic logic unit for quantum arithmetic. Journal of Physics A: Mathematical and Theoretical 43(38), 382002 (2010)MathSciNetCrossRefGoogle Scholar
  17. 17.
    Toffoli, T.: Reversible computing. In: de Bakker, J.W., van Leeuwen, J. (eds.) ICALP 1980. LNCS, vol. 85, pp. 632–644. Springer (1980)Google Scholar
  18. 18.
    Van Rentergem, Y., De Vos, A., Storme, L.: Implementing an arbitrary reversible logic gate. Journal of Physics A: Mathematical and General (38), 3555–3577 (2005)MathSciNetzbMATHCrossRefGoogle Scholar
  19. 19.
    Vedral, V., Barenco, A., Ekert, A.: Quantum networks for elementary arithmetic operations. Physical Review A 54(1), 147–153 (1996)MathSciNetCrossRefGoogle Scholar
  20. 20.
    Wille, R., Offermann, S., Drechsler, R.: SyReC: A programming language for synthesis of reversible circuits. In: Specification & Design Languages, FDL, pp. 1–6. IET (2010)Google Scholar
  21. 21.
    Yokoyama, T., Axelsen, H.B., Glück, R.: Principles of a reversible programming language. In: Conference on Computing Frontiers, CF, pp. 43–54. ACM Press (2008)Google Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 2013

Authors and Affiliations

  • Mathias Soeken
    • 1
  • Michael Kirkedal Thomsen
    • 2
  1. 1.Group of Computer ArchitectureUniversity of BremenGermany
  2. 2.DIKU, Department of Computer ScienceUniversity of CopenhagenDenmark

Personalised recommendations