<<

arXiv:quant-ph/0601078v3 28 Apr 2006 fqubits. of h aaadgt n ylcpruaino h uis,adtwo b and fixed a ), (for on the phase-flip universal of (non-local) is a permutation and set an cyclic ) by arbitrary a composed but and is fixed here gate e defined at Hadamard lines set the qubit The choice the lines. ( require total qubit sets not the universal do whenever finite they change qubits, standard all unitaries on the globally that act means This machine. at u fmaueetpoess vr opttoa ste computational every processes, H measurement of out fact, h reo fapplying of freedom the rpryo h e sta h hieo h uist hc apply which to qubits the of choice the that is set the of property i sntdffiutt eiyta the the that Namely, verify graph. to difficult not is u htayqatmagrtmcnb ena h iceediffusion discrete the as seen be can on-the-fly corrected quantum any that out osdrdb ubro aes(e 1 ]adtereferences the and 9] gate [1, Hadamard (see the papers of of consists number a by considered egho h odadteodro h etr.Ti a oeflavo some has This letters. So, the (see of machines three. order sequential cardinality the other of and and r conctr alphabet word to an is the of useful from computation length taken be quantum commute) may universal which it doing of However, b which t view, in the expensive). of to physically framework, point justification is impementation a physical (which be the qubits to from inconvenient like is would observation here This unitaries. the ,w omlysaeadpoetemi eut hsi oeb proving by done is This result. main the prove and state formally we 3, ∗ lcrncades [email protected] address: Electronic otevre labeled vertex the to ’s, nti ae,w en nvra e fuiayqatmoperat quantum unitary of set universal a define we paper, this In h td fuieslt nqatmcmuainge akt 3.I [3]. to back goes computation quantum in universality of study The h eane fti ae sognzda olw.I eto ,w g we 2, Section In follows. as organized is paper this of remainder The T sadiett arcs h ubro ieetuiaisotie in obtained unitaries different of number The matrices. identity and ’s ASnmes 81P68 numbers: PACS hieo ui ie snee o h plcto fteope d discrete the a of as application interpreted be the c can graph, for set in Bruijn needed this Therefore, on is based three. lines algorithm cardinality variab qubit of of of word alphabet a choice then an is from operations, taken these on based and qubits n ylcpruaino h uis,tgte ihtodi two with together qubits), the of permutation cyclic a and a ouieslqatmcmuainon phase-fli computation non-local quantum a and universal qubit) do arbitrary but can fixed a (for flip eso htan that show We n ij yaqbtflpadapaeflp ohfie u rirr.Ti remind This arbitrary. but fixed both phase-flip, a and qubit-flip a by uis erdc tto it reduce we qubits, nvra unu optto ihulbldqubits unlabeled with computation quantum Universal t nr fti ntr snneoi n nyi hr sadrce ed directed a is there if only and if nonzero is unitary this of entry -th j nted ringaho 2 on graph Bruijn de the in , H orce on-the-fly corrected 1 eateto ahmtc n eateto optrScien Computer of Department and Mathematics of Department and H e.g. n nvriyo ok elntn O05DYr,U.K. York, 5DD YO10 Heslington, York, of University T t oto h as-aaadtasom(bandfo the from (obtained transform Walsh-Hadamard the of root -th n oehrwt h ooigate Toffoli the with together , oabtayqbt ftecomputer: the of qubits arbitrary to t oto h as-aaadtasomrset h topolog the respects transform Walsh-Hadamard the of root -th e.g. H and 4 7]). [4, T yaxlaymdfiain ftepae soitdt h ar the to associated phases the of modifications auxiliary by H hr h ae ea xdbtmyb ple ovrigcocso choices varying to applied be may but fixed reman gates the where ) .INTRODUCTION I. and ioeSeverini Simone T n n cigo n ui n n he uis h characteristic The qubits. three any and qubit any on acting , n t oto h as-aaadtasom(osrce from (constructed transform Walsh-Hadamard the of root -th etcs nScin4 nvru fti bevto,w point we observation, this of virtue in 4, Section In vertices. uis unu optto,mkn s of use making computation, quantum A qubits. sidcdb ntr,otie ytnoigtogether tensoring by obtained unitary, a by induced is p T hri) rbby h ipetuieslsto gates of set universal simplest the Probably, therein). 1, 9.O ore nodrt aeuieslt,w need we universality, have to order in course, Of [9]. tabtaycecet.T rv httedefined the that prove To coefficient). arbitrary ut ∗ rta eid fqatmfiiesaeautomata state finite quantum of reminds that ur osdpnigo h opttoa pc fthe of space computational the on depending ions frafie u rirr coefficient), arbitrary but fixed a (for p ubro uiscags ic h operations the Since changes. qubits of number H gnlmtie,nml oa qubit- local a namely matrices, agonal elnt,btwoeltesaealways are letters whose but length, le ffso faqatmpril nade a on particle quantum a of iffusion nrs ihohruieslst,no sets, universal other with ontrast h ucm facmuaindpnso the on depends computation a of outcome the cuei eursnnoa neato between interaction nonlocal requires it ecause cigwrswoeltesaeuiais(two unitaries are letters whose words ucting ain ecie ee quantum A here. described rations teo h ae.O ore h e described set the course, Of paper. the of itle c opttoa tp hsi ncnrs to contrast in is This step. computational ach H faqatmpril nad ringraph, Bruijn de a on particle quantum a of mr httestpoie mathematical a provides set the that emark and ignlmtie:a(oa)qbtflp(o a (for qubit-flip (local) a matrices: diagonal v oepeiiaydfiiin.I Section In definitions. preliminary some ive nvraiywt euto to reduction a with universality oayqbtand qubit any to h ici oe,uieslt a been has universality model, circuit the n hswyi hnafnto ftenumber the of function a then is way this T sntrflce notesrcue of structures the into reflected not is ce, aaadgate Hadamard ftecneto discrete of context the of s efo h etxlabeled vertex the from ge T oaytreqbt.In qubits. three any to fted Bruijn de the of y cs. n { ,T H, } It . f 2 quantum walks [2] or the processes studied in [6]. A natural open question would be to prove that the n-th root of the Walsh-Hadamard transform and a phase-flip (for a fixed but arbitrary coefficient) form a universal set.

II. DEFINITIONS

In this section we introduce some preliminary definitions.

n 1 Definition of Vn. We denote by Vn a square matrix of dimension 2 such that [Vn]i,j 0, and with exactly ∈{ ± √2 } the following nonzero entries:

1 V V n−1 V , [ n]1,1 = [ n]1,2 +1 = [ n]2,1 = √2 1 V n−1 , [ n]2,2 +1 = √2 − 1 V V n−1 V , [ n]3,2 = [ n]3,2 +2 = [ n]4,2 = √2 1 [Vn] n−1 = , 4,2 +2 − √2 (1) . . 1 V n n−1 V n n V n n−1 , [ n]2 1,2 = [ n]2 1,2 = [ n]2 ,2 = √2 − 1 − [Vn]2n,2n = . − √2 n The matrix Vn is real-orthogonal and it is an n-th root of Hn := H⊗ , where H is the 1-qubit hadamard gate: 1 1 1 H := . (2) √  1 1  2 − For example, 10 1 0 1 0 1 0 V = 1   (3) 2 √2 01− 0 1  01 0 1   −  2 and V2 = H. An alternative and more direct definition of Vn can be given as follows. Let Sn be the full symmetric group on the set 1, 2, ..., n . We denote permutations of length n as ordered sets. For example, the elements of S3 are (1, 2, 3), (1, 3,{2), (3, 2, 1),} (2, 3, 1), (2, 1, 3), and (3, 1, 2). With an abuse of our notation, their regular permutation representations are denoted in the same way. The matrix Vn is defined as

n 1 Vn := P H I⊗ − , (4) · ⊗  where

P = (1, 3, ..., 2n 1, 2, 4, ..., 2n). (5) − This permutation is nothing but a cyclic-shift of the qubits:

P : a1a2...an an 1a1...an 2 . (6) | i −→ | − − i n n This explains why Vn = Hn (Hn := H⊗ ). It is easy to verify that Eq. 1 and Eq. 4 define the same matrices. Notice that, when n = 2, the permutation P is the Swap-gate: 1000 0010 (1, 3, 2, 4) =   . (7) 0100    0001 

n n Definition of Pn(k). Let us denote by Pn(k) the 2 2 matrix defined by × 0 if i = j; 6 n [Pn(k)]i,j :=  1 if i = k with k 1, ..., 2 ; (8)  −1∈{ otherwise.}  3

1 0 The matrix Pn(k) is the Pauli operator Z = on the n-th qubit controlled by all other qubits 1, 2, ..., n 1  0 1  − and then conjugated by the permutation that interchanges− dimensions k and 2n. For example,

10 0 0 01 0 0 P2(3) =   = I2 XZX, (9) 0 0 1 0 ⊕  −   00 0 1  0 1 where X is the Pauli operator X = .  1 0 

n n Definition of Fn(k). Let us denote by Fn(k) the 2 2 matrix defined by × 0 if i = j; 6 [Fn(k)]i,j :=  1 if the k-th qubit is 1; (10)  −1 otherwise.  The matrix Fn(k) is the Pauli operator Z acting on the k-th qubit and the identity on all other qubits. For example,

10 0 0 10 0 0 0 10 0 01 0 0 F2(1) =  −  = I Z and F2(2) =   = Z I. (11) 00 1 0 ⊗ 0 0 1 0 ⊗  0 0 0 1   00− 0 1   −   − 

III. MAIN RESULT

In this section we prove the following theorem.

Theorem 1 The set

B = Vn, Pn(i), Fn(j) , (12) { } for fixed but arbitrary i 1, ..., 2n and j 1, ..., n , is universal for quantum computation on n qubits. ∈{ } ∈{ } By this theorem, any quantum computation in the circuit model can be seen as a word whose letters are taken from the alphabet B.

The Toffoli gate T is the 3-qubit gate defined as T : (a,b,c) (a,b,ab c), where denotes addition modulo 2 and a,b,c 0, 1 . The matrices defined by the Toffoli gate are−→ then a special⊕ kind of t⊕ransposition. If we label the states of the∈{ computational} in lexicographic order, the matrices defined by the Toffoli gate on 3 qubits are

10000000 10000000 10000000  01000000   01000000   01000000  00100000 00100000 00100000        00010000   00000001   00010000    ,   and   . (13)  00001000   00001000   00001000         00000100   00000100   00000001         00000001   00000010   00000010   00000010   00010000   00000100       

The set B′ = H,T is universal for quantum computation [1, 9]. We prove Theorem 1 by showing that the set { } B is equivalent to the set B′, once the number of qubits has been fixed. In order to verify this equivalence, we show that any expression made by the tensor product of H, T , and the 2 2 I2 corresponds to a sequence of the three elements of B defined in the statement of the above theorem.× We will consider the set

n Dn := Pn(i):1 i 2 . (14) { ≤ ≤ }

Lemma 2 The set A = Vn Dn is universal for quantum computation on n qubits. ∪ 4

Proof. By the definition of Vn (Eq. 4 above), we have 1 n 1 P − Vn = H I⊗ − , (15) · ⊗ where 1 n 1 n 1 n 1 n n n 1 P − = (1, 2 − +1, 2, 2 − +2, 3, ..., 2 − , 2 )=(1, 3, ..., 2 1, 2, 4, ..., 2 )− . − 1 This means that if we can construct the matrix P − then we can also construct the Hadamard gate. Firstly, observe that 1 2n 1 T Vn− = Vn − = Vn , since 2n n n n Vn = Vn Vn = HnHn = I⊗ . T The matrix Vn can be then obtained directly from Vn. The nonzero entries in the last two rows of Vn are 1 V n n−1 V n n V n n−1 , [ n]2 1,2 = [ n]2 1,2 = [ n]2 ,2 = √2 − 1 − [Vn]2n,2n = . − √2 n T The nonzero entries in the last two columns of Qn = Pn(2 ) V are · n n T 1 Q n−1 n Q n n P V n−1 n , [ n]2 ,2 1 = [ n]2 ,2 1 = [ n(2 ) n ]2 ,2 = √2 − 1 − · [Qn]2n,2n = . − √2 1 1 Since H 1 = X, it follows that · √2  1 1  − n T n n n VnQn = VnPn(2 )Vn = I2n 2 X = (1, 2, ..., 2 2, 2 , 2 1), (16) − ⊕ − − which is indeed the Toffoli gate. Now, given that n n n n S2n = (1, 2, ..., 2 2, 2 , 2 1), (2, 3, ..., 2 , 1) , h − − i n if we can construct the cyclic permutation (2, 3, ..., 2 , 1) then we will have the full symmetric group S2n . If we can 1 construct S2n then we will get P − and all the permutations that we need for applying H and T to arbitrary qubits. The permutation (2, 3, ..., 2n, 1) can be constructed with the following procedure (most probably not optimal): n 1 1. Let M1 = HnFn(n)Hn = X I⊗ − . By applying elements from Dn, tranform the bottom-left block of M1 into ⊗ the diagonal matrix dia(p1, ..., p2n−3 , p2n−3+1, ..., p2n−2 ), where pi = (1, 1). Let M2′ be the matrix obtained in this way. − − − 1 2. Let M2 = Vn− M2′ Vn. By applying elements from Dn, transform the top-right block of M2 into the identity matrix and the bottom-left block into the diagonal matrix dia(p1, ..., p n−4 , p n−4 , ..., p n−3 ). 2 − 2 +1 − 2 3. Repeating the second step n 2 times one gets the permutation matrix (2, 3, ..., 2n, 1). (This can be easily checked with any computer algebra− system.) An example with three qubits may help to clarify the procedure:

H3 1, 2, 3, 4, 5, 6, 7, 8 H3 = (5, 6, 7, 8, 1, 2, 3, 4), 1  V3− 5, 6, 7, 8, 1, 2, 3, 4 V3 = 3, 4, 5, 6, 7, 8, 1, 2 , 1   V3− 3, 4, 5, 6, 7, 8, 1, 2 V3 = (2, 3, 4, 5, 6, 7, 8, 1). The notation is easily explained:  1000  0 0100  0010    0001  5, 6, 7, 8, 1, 2, 3, 4 =   .  10 00      0 1 0 0   − 0   0 0 1 0     −   00 01  5

By the above constructions, we have the following fact: the matrix group G = Vn,Dn has the regular permutation h i representation of S2n as a subgroup. Then T , obtained with Eq. 16, can be applied to any three qubits; H, obtained from Eq. 15, can be applied to to any qubit. Since B′ = H,T is universal, the lemma follows. { } n Lemma 3 The matrix group G = Vn, Pn(i), Fn(j) , for fixed but arbitrary i 1, ..., 2 and j 1, ..., n , contains h i ∈{ } ∈{ } the set Dn.

Proof. By the definitions,

k k n 1 k n 1 n 1 k V Fn(n)V − = P H I⊗ − Z I⊗ − P H I⊗ − − n n ⊗ · ⊗ · ⊗ k n 1 n 1  n 1 k = P H I⊗ − Z I⊗ − H I⊗ − P − ⊗ · ⊗ · ⊗ k n 1 k   = P X I⊗ − P − ⊗ = I I X I I, ⊗···⊗ ⊗ ⊗ ···⊗ 1 1 where X is at the k-th position of the tensor product. For example, V3 F3(3)V3− = I I X. Let H be the matrix ⊗ ⊗ Zn group generated by the matrices I I X, I I X I,X I I. The group H is isomorphic to 2 ⊗···⊗ ⊗ ⊗···⊗ ⊗ ⊗ ⊗ ⊗···⊗ Zn (indeed, the above matrices are the permutation representations of the standard generators of 2 ). Since, for every n n n i, j 1, ..., 2 , there is an element of H sending Pn(i) to Pn(j), we can construct Dn, that is the set of all 2 2 ∈{ } × diagonal matrices with entries 1 and 1. We considered Fn(n), but we could also take Fn(j), for any j 1, ..., n , without loss of generality. − ∈ { }

Theorem 1 is a consequence of Lemma 2 together with Lemma 3.

IV. A RELATION WITH DE BRUIJN GRAPHS

Let Σ be an alphabet of cardinality d and let Σn∗ be the set of all words of length n over Σ. The d-ary n-dimensional de Bruijn graph is a directed graph denoted by B(d, n) and defined as follows [5]: the set of vertices is Σk∗; there is an arc from i to j if and only if the last n 1 letters of i are the same as the first n 1 letters of j. The graph B(2,n) is called (directed) binary de Bruijn graph− . Notice that B(2,n) has exactly two loops:− one loop is at the vertex 0 ... 0; the other one at the vertex 1 ... 1. These graphs have important applications in cryptography and distributed computing. In particular, they provide some of the best-known topologies for communication networks. For example, the Galileo space probe of NASA used a network based on a de Bruijn graph to implement a signal decoder [8]. Let Mn be the adjacency matrix of B(2,n). The rows and the columns of this matrix can be ordered in such a way that

[Mn]1,1 = [Mn]1,2n−1+1 = [Mn]2,1 = [Mn]2,2n−1+1 =1, [Mn]3,2 = [Mn]3,2n−1+2 = [Mn]4,2 = [Mn]4,2n−1+2 =1, . .

[Mn]2n 1, 1 2n 1 = [Mn]2n 1,2n = [Mn]2n, 1 2n 1 = [Mn]2n,2n =1. − 2 − − 2 −

Tanner [11] pointed out that the matrix Vn is obtained from the matrix Mn by negating the entries 1 M n−1 , M n−1 , ..., M n n M [ n]2,2 +1 [ n]4,2 +2 [ n]2 ,2 and rescaling n by √2 . It is easy to see that a simple random walk on B(d, n) converges very quickly to uniformity, in fact it is perfectly mixed after n steps. Simple means that at each vertex the walker chooses to cross an incident edge by tossing a fair die with d faces. We associate the vertices of n 1 B(2,n) with the elements of the computational basis 0 0...0 , 1 0...01 , ..., 2 − 1...1 . For every i and | i ≡ | in| i ≡n | i | i ≡ | i | i j , there is a diagonal matrix Q Dn such that HnQHn i = V QV i = j . We may interpret this process as a | i ∈ | i n n | i | i discrete quantum walk on B(2,n) induced by Vn and corrected on-the-fly by an appropriate diagonal unitary with 1 2n ± entries. If the walk is not corrected then Vn i = i for every i, given that Hn is symmetric. The walk on B(2,n) is perfectly mixed at the n-th step, but it can| i be driven| i with probability 1 to any vertex in exactly 2n steps. For example, the following is an algorithm that takes the state 0 to the state 2n 1 in 2n steps: | i | − i n n Vn 0 = + ⊗ ; | i n | i n F1(1)⊗ + ⊗ = ψ ; | i | i V n ψ = 2n 1 . n | i | − i 6

(A curiosity: the positions of the minus sign in the state ψ correspond to the numbers with an odd number of 1’s in their binary expansion (A007413 [10])). A generalization| i for any i and j is straightforward. | i | i Aknowledgments. I would like to thank the anonymous referees. Their comments helped me to improve the presentation of this paper.

[1] D. Aharonov, Simple Proof that Toffoli and Hadamard are Quantum Universal, quant-ph/0301040. [2] A. Ambainis, Quantum walks and their algorithmic applications, quant-ph/0403120. [3] D. Deutsch, Quantum computational networks, Proc. Roy. Soc. Lond. A 425 73-90, 1989. [4] S. Gudder, Quantum automata: an overview, Internat. J. Theoret. Phys. 38 (1999), no. 9, 2261–2282. [5] M.-C. Heydemann, Cayley graphs and interconnection networks, Graph symmetry (Montreal, PQ, 1996), 167–224, NATO Adv. Sci. Inst. Ser. C Math. Phys. Sci., 497, Kluwer Acad. Publ., Dordrecht, 1997. [6] J. Koˇs´ık, Scattering Quantum Random Walk, Optics and Spectroscopy 99, 224-226 (2005). [7] C. Moore, J. P. Crutchfield, Quantum automata and quantum grammars, Theoret. Comput. Sci. 237 (2000), no. 1-2, 275–306. [8] B. Mukherjee, Optical Communication Networks, Series on Computer Communications, McGraw-Hill, New York, 1997. [9] Y. Shi, Both Toffoli and controlled-Not need little help to do universal quantum computation, quant-ph/0205115. [10] N. J. A. Sloane, (2005), The On-line Encyclopedia of Integer Sequences, www.research.att.com/˜njas/sequences/. [11] G. Tanner, Spectral statistics for unitary transfer matrices of binary graphs, J. Phys. A 33 (2000), no. 18, 3567–3585.