Skip to main content
. 2019 Aug 15;21(8):800. doi: 10.3390/e21080800

Figure 28.

Figure 28

Four different quantum circuit implementations of the same balanced function, computing the majority MAJ (see Figure 24) of three bits. (A) Straightforward construction using four T˜(3) gates. (B) The majority is computed in place in the query register, the answer is copied out to the answer register, and the intermediate step is then uncomputed by applying MAJ to the query register. (C) is an optimization of A, tuned for as few gates as possible, and (D) is another optimized for few Toffolis followed by few CNOTs, generated as part of the list of all 72 possible functions in Appendix A.