Fast Algorithm for Walsh Hadamard Transform on Sliding Windows

Total Page:16

File Type:pdf, Size:1020Kb

Fast Algorithm for Walsh Hadamard Transform on Sliding Windows MANUSCRIPT TO TPAMI. PERSONAL USE OF THESE MATERIALS IS PERMITTED. HOWEVER, PERMISSION TO REPRINT/REPUBLISH THIS MATERIAL FOR ADVERTISING OR PROMOTIONAL PURPOSES OR FOR CREATING NEW COLLECTIVE WORKS FOR RESALE OR REDISTRIBUTION TO SERVERS OR LISTS, OR TO REUSE ANY COPYRIGHTED COMPONENT OF THIS WORK IN OTHER WORKS MUST BE OBTAINED FROM IEEE. 1 Fast Algorithm for Walsh Hadamard Transform on Sliding Windows Wanli Ouyang, W.K. Cham, Senior Member, IEEE Abstract—This paper proposes a fast algorithm for Walsh Hadamard Transform on sliding windows which can be used to implement pattern matching most efficiently. The computational requirement of the proposed algorithm is about 1.5 additions per projection vector per sample which is the lowest among existing fast algorithms for Walsh Hadamard Transform on sliding windows. Index Terms— Fast algorithm, Walsh Hadamard Transform, Pattern Matching, template matching, feature extraction The rest of the paper is organized as follows. Section 2 de- fines terms and symbols used in this paper. Then the WHT 1 INTRODUCTION algorithm in [9] is briefly introduced. In Section 3, we intro- Pattern matching, also named as template matching, is widely duce two examples of the proposed algorithm. Section 4 illus- used in signal processing, computer vision, image and video trates the proposed algorithm for 1-D order-N WHT. The algo- processing. Pattern matching has found application in rithm computes order-N WHT using order-4 and order-N/4 manufacturing for quality control [1], image based rendering WHT. In Section 5, the number of additions required by the [2], image compression [3], object detection [4] and video proposed algorithm is derived. Section 6 gives the experimen- compression. The block matching algorithm used for video tal result of motion estimation in video coding application, compression can be considered as a pattern matching problem which utilizes the proposed algorithm for computing 2-D [5]-[8]. To relieve the burden of high complexity and high WHT on sliding windows. Finally, Section 7 presents conclu- requirement of computational time for pattern matching, a lot sions. of fast algorithms have been proposed [9]-[13]. It has been found that pattern matching can be performed efficiently in Walsh Hadamard Transform (WHT) domain [9]. 2 WALSH HADAMARD TRANSFORM ON SLIDING In pattern matching, signal vectors obtained by a sliding win- WINDOWS dow need to be compared to a sought pattern. Hel-Or and Hel- Or’s algorithm [9] requires 2N-2 additions for obtaining all 2.1 Definitions WHT projection values in each window of size N. Note that Consider K input signal elements xn where n=0, 1, …, K-1, one subtraction is considered to be one addition regarding the which will be divided into overlapping windows of size N computational complexity in this paper. Their algorithm (K>N). Let the jth input window be: r T achieves efficiency by utilizing previously computed values in - X N (j)= [xj, xj+1, …, xj+N 1] for j = 0, 1, …, K-N. (1) the internal vertices of the tree structure in Fig. 1. Recently, A 1-D order-N WHT transforms N numbers into N projection the Gray Code Kernel (GCK) algorithm [10] which utilizes values. Let MN be an order-N WHT matrix and previously computed values in the leaves of the tree structure r r r T M= [ M (0), M (1), …, M (N-1)] , (2) in Fig. 1 was proposed. The GCK algorithm requires similar N N N N where r is the ith WHT basis vector. computation as [9] when all projection values are computed M N (i) Let y (i, j) for i = 0, 1, …N-1; j = 0, 1, …, K-N be the ith and requires less computation when only a small number of N WHT projection value for the jth window and projection vectors are computed. r T r yN(i,j)= M N(i) X N(j). (3) This paper proposes a fast algorithm for WHT on sliding r In [10], M (i) and yN(i, j) are called the ith projection kernel windows. Instead of performing order-N WHT by means of N r order-N/2 WHT and N additions in the tree structure, which is and projection result respectively. Let Y N(j) be the projection the technique adopted in [9], the proposed algorithm computes vector containing all projection values of the jth window and r T r order-N WHT by means of order-N/4 WHT and N+1 additions. Y N(j)=[yN(0, j), yN(1, j), …, yN(N-1, j)] = MN X N(j). (4) In this way, the proposed algorithm can obtain all WHT pro- For example, when N=4, we have: jection values using about 3N/2 additions per window. In the ⎛ y4 (0, j)⎞ ⎡1 1 1 1 ⎤⎛ x j ⎞ ⎜ ⎟ ⎢ ⎥⎜ ⎟ computation of partial projection values for sliding windows, y (1, j) 1 1 −1 −1 x . (5) v ⎜ 4 ⎟ ⎢ ⎥⎜ j+1 ⎟ r the proposed algorithm requires only 1.5 additions per projec- Y4 ( j) = ⎜ ⎟ = ⎜ ⎟ = M 4 X 4(j) y4 (2, j) ⎢1 −1 −1 1 ⎥ x j+2 tion vector for each window. As shown by experimental results ⎜ ⎟ ⎢ ⎥⎜ ⎟ ⎜ ⎟ ⎜ x ⎟ in Section 7, the computational time required by the proposed ⎝ y4 (3, j)⎠ ⎣1 −1 1 −1⎦⎝ j+3 ⎠ algorithm for computing ten or more projection values is about The WHT in (5) is in sequency order. Its basis vectors are 75% of that of the GCK algorithm. ordered according to the number of zero crossings. The relationship among WHTs in sequency order, dyadic order and ———————————————— natural order can be found in [15]. • The authors are with the Department of Electronic Engineering, The Chi- nese University of Hong Kong. E-mail: {wlouyang, wkcham}@ee.cuhk.edu.hk xxxx-xxxx/0x/$xx.00 © 200x IEEE 2 MANUSCRIPT TO TPAMI. PERSONAL USE OF THESE MATERIALS IS PERMITTED. HOWEVER, PERMISSION TO REPRINT/REPUBLISH THIS MATERIAL FOR ADVERTISING OR PROMOTIONAL PURPOSES OR FOR CREATING NEW COLLECTIVE WORKS FOR RESALE OR REDISTRIBUTION TO SERVERS OR LISTS, OR TO REUSE ANY COPYRIGHTED COMPONENT OF THIS WORK IN OTHER WORKS MUST BE OBTAINED FROM IEEE. 2.2 Previous WHT computation methods In [9], Hel-Or and Hel-Or proposed a fast algorithm that r r r computes Y N(j) from Y N/2(j) and Y N/2(j+N/2) using (6). ⎧y ()i / 2 , j + y ()i / 2 , j + N / 2 ,i%4 = 0 or 3 N / 2 ⎣⎦ N / 2 ⎣⎦ yN (i, j) = ⎨ , ⎩ yN / 2 ()⎣⎦i / 2 , j − yN / 2 ()⎣⎦i / 2 , j + N / 2 ,i%4 =1 or 2 (6) where % is the modulo operation; and ⌊ ·⌋ is the floor func- Fig. 2 Signal flow diagram of the Bottom up algorithm for window size tion. equal 4 As shown in Fig. 1, their algorithm first computes WHT projection values for window size N being 2, which are then used to compute WHT projection values for window size be- 3.2 Fast Algorithm for Window Size 8 ing 4 and so on. The computation starts at the root and moves The proposed algorithm and the GCK algorithm [10] for down the tree until the projection values represented by the window size being 8 are described in Table 2. The proposed r leaves are computed using (6). The algorithm in [9] requires 1 algorithm computes Y 8(j+2) for j=0, 1, …K-8, which is the r addition per window along each node of the tree in Fig. 1. The WHT projection vector in window j+2, using Y 8(j)=[y8(0,j), T GCK algorithm [10] utilizes previously computed order-N y8(1,j), …, y8(7,j)] , which is the computed projection vector in projection values for computing the current order-N projection window j. value. When a small number of projection values are com- Define tN/4(i, j) for i = 0, …, N/4-1; j = 0, 1, …, K-5N/4 as: puted, the GCK algorithm requires 2 additions per window for tN/4(i, j) = yN/4(i, j) - yN/4(i, j+N). (9) each projection value while the algorithm in [9] requires For N=8, we have: O(logN) additions. When all projection values are computed, ⎡t2 (0, j)⎤ ⎡y2 (0, j)⎤ ⎡y2 (0, j + 8)⎤ . both the algorithms in [9] and [10] require about 2N additions. ⎢ ⎥ = ⎢ ⎥ − ⎢ ⎥ ⎣t2 (1, j)⎦ ⎣ y2 (1, j)⎦ ⎣ y2 (1, j + 8)⎦ A new fast algorithm, which is more efficient than those re- From (3) and then (7), we have: ported in [9] and [10], is proposed in this paper. It can effi- ⎡t (0, j)⎤ ⎡1 1 ⎤⎡ x j ⎤ ⎡1 1 ⎤⎡x j+8 ⎤ ciently compute order-N WHT on sliding windows, i.e. yN(i, j) 2 = − ⎢ ⎥ ⎢ ⎥⎢x ⎥ ⎢ ⎥⎢x ⎥ for i = 0, …, P-1 (P≤N) and j = 0, 1, 2, …, K-N. ⎣t2 (1, j) ⎦ ⎣1 −1⎦⎣ j+1 ⎦ ⎣1 −1⎦⎣ j+9 ⎦ ⎡1 1 ⎤⎡ x − x ⎤ ⎡ d ( j) ⎤ = j j+8 = M 8 . (10) 3 FAST ALGORITHM FOR WHT ON SLIDING ⎢ ⎥⎢x − x ⎥ 2 ⎢ ⎥ ⎣1 − 1⎦⎣ j+1 j+9 ⎦ ⎣d 8 ( j + 1)⎦ WINDOWS FOR WINDOW SIZES 4 AND 8 As given by (10), t2(i, j) is the ith order-2 WHT projection T This section gives examples of computing order-N WHT on value of [d8(j), d8(j+1)] . According to Table 2 and (10), WHT sliding windows of sizes N=4 and 8 using the proposed algo- projection vector in window j+2 can be computed from those rithm. in window j as well as t2(i, j) as follows: ⎡y (0, j +2)⎤ ⎡ y (0, j) ⎤ ⎡−t (0, j)⎤ 3.1 Fast Algorithm for Window Size 4 8 8 2 ⎢ y (1, j +2)⎥ ⎢− y (2, j)⎥ ⎢ t (0, j) ⎥ The proposed algorithm and the GCK algorithm [10] for ⎢ 8 ⎥ ⎢ 8 ⎥ ⎢ 2 ⎥ ⎢ ⎥ ⎢ ⎥ ⎢ ⎥ window size being 4 are described in Table 1.
Recommended publications
  • An Introduction Quantum Computing
    An Introduction to Quantum Computing Michal Charemza University of Warwick March 2005 Acknowledgments Special thanks are given to Steve Flammia and Bryan Eastin, authors of the LATEX package, Qcircuit, used to draw all the quantum circuits in this document. This package is available online at http://info.phys.unm.edu/Qcircuit/. Also thanks are given to Mika Hirvensalo, author of [11], who took the time to respond to some questions. 1 Contents 1 Introduction 4 2 Quantum States 6 2.1 CompoundStates........................... 8 2.2 Observation.............................. 9 2.3 Entanglement............................. 11 2.4 RepresentingGroups . 11 3 Operations on Quantum States 13 3.1 TimeEvolution............................ 13 3.2 UnaryQuantumGates. 14 3.3 BinaryQuantumGates . 15 3.4 QuantumCircuits .......................... 17 4 Boolean Circuits 19 4.1 BooleanCircuits ........................... 19 5 Superdense Coding 24 6 Quantum Teleportation 26 7 Quantum Fourier Transform 29 7.1 DiscreteFourierTransform . 29 7.1.1 CharactersofFiniteAbelianGroups . 29 7.1.2 DiscreteFourierTransform . 30 7.2 QuantumFourierTransform. 32 m 7.2.1 Quantum Fourier Transform in F2 ............. 33 7.2.2 Quantum Fourier Transform in Zn ............. 35 8 Random Numbers 38 9 Factoring 39 9.1 OneWayFunctions.......................... 39 9.2 FactorsfromOrder.......................... 40 9.3 Shor’sAlgorithm ........................... 42 2 CONTENTS 3 10 Searching 46 10.1 BlackboxFunctions. 46 10.2 HowNotToSearch.......................... 47 10.3 Single Query Without (Grover’s) Amplification . ... 48 10.4 AmplitudeAmplification. 50 10.4.1 SingleQuery,SingleSolution . 52 10.4.2 KnownNumberofSolutions. 53 10.4.3 UnknownNumberofSolutions . 55 11 Conclusion 57 Bibliography 59 Chapter 1 Introduction The classical computer was originally a largely theoretical concept usually at- tributed to Alan Turing, called the Turing Machine.
    [Show full text]
  • Introductory Topics in Quantum Paradigm
    Introductory Topics in Quantum Paradigm Subhamoy Maitra Indian Statistical Institute [[email protected]] 21 May, 2016 Subhamoy Maitra Quantum Information Outline of the talk Preliminaries of Quantum Paradigm What is a Qubit? Entanglement Quantum Gates No Cloning Indistinguishability of quantum states Details of BB84 Quantum Key Distribution Algorithm Description Eavesdropping State of the art: News and Industries Walsh Transform in Deutsch-Jozsa (DJ) Algorithm Deutsch-Jozsa Algorithm Walsh Transform Relating the above two Some implications Subhamoy Maitra Quantum Information Qubit and Measurement A qubit: αj0i + βj1i; 2 2 α; β 2 C, jαj + jβj = 1. Measurement in fj0i; j1ig basis: we will get j0i with probability jαj2, j1i with probability jβj2. The original state gets destroyed. Example: 1 + i 1 j0i + p j1i: 2 2 After measurement: we will get 1 j0i with probability 2 , 1 j1i with probability 2 . Subhamoy Maitra Quantum Information Basic Algebra Basic algebra: (α1j0i + β1j1i) ⊗ (α2j0i + β2j1i) = α1α2j00i + α1β2j01i + β1α2j10i + β1β2j11i, can be seen as tensor product. Any 2-qubit state may not be decomposed as above. Consider the state γ1j00i + γ2j11i with γ1 6= 0; γ2 6= 0. This cannot be written as (α1j0i + β1j1i) ⊗ (α2j0i + β2j1i). This is called entanglement. Known as Bell states or EPR pairs. An example of maximally entangled state is j00i + j11i p : 2 Subhamoy Maitra Quantum Information Quantum Gates n inputs, n outputs. Can be seen as 2n × 2n unitary matrices where the elements are complex numbers. Single input single output quantum gates. Quantum input Quantum gate Quantum Output αj0i + βj1i X βj0i + αj1i αj0i + βj1i Z αj0i − βj1i j0i+j1i j0i−|1i αj0i + βj1i H α p + β p 2 2 Subhamoy Maitra Quantum Information Quantum Gates (contd.) 1 input, 1 output.
    [Show full text]
  • A Gentle Introduction to Quantum Computing Algorithms With
    A Gentle Introduction to Quantum Computing Algorithms with Applications to Universal Prediction Elliot Catt1 Marcus Hutter1,2 1Australian National University, 2Deepmind {elliot.carpentercatt,marcus.hutter}@anu.edu.au May 8, 2020 Abstract In this technical report we give an elementary introduction to Quantum Computing for non- physicists. In this introduction we describe in detail some of the foundational Quantum Algorithms including: the Deutsch-Jozsa Algorithm, Shor’s Algorithm, Grocer Search, and Quantum Count- ing Algorithm and briefly the Harrow-Lloyd Algorithm. Additionally we give an introduction to Solomonoff Induction, a theoretically optimal method for prediction. We then attempt to use Quan- tum computing to find better algorithms for the approximation of Solomonoff Induction. This is done by using techniques from other Quantum computing algorithms to achieve a speedup in com- puting the speed prior, which is an approximation of Solomonoff’s prior, a key part of Solomonoff Induction. The major limiting factors are that the probabilities being computed are often so small that without a sufficient (often large) amount of trials, the error may be larger than the result. If a substantial speedup in the computation of an approximation of Solomonoff Induction can be achieved through quantum computing, then this can be applied to the field of intelligent agents as a key part of an approximation of the agent AIXI. arXiv:2005.03137v1 [quant-ph] 29 Apr 2020 1 Contents 1 Introduction 3 2 Preliminaries 4 2.1 Probability ......................................... 4 2.2 Computability ....................................... 5 2.3 ComplexityTheory................................... .. 7 3 Quantum Computing 8 3.1 Introduction...................................... ... 8 3.2 QuantumTuringMachines .............................. .. 9 3.2.1 Church-TuringThesis ..............................
    [Show full text]
  • Encryption of Binary and Non-Binary Data Using Chained Hadamard Transforms
    Encryption of Binary and Non-Binary Data Using Chained Hadamard Transforms Rohith Singi Reddy Computer Science Department Oklahoma State University, Stillwater, OK 74078 ABSTRACT This paper presents a new chaining technique for the use of Hadamard transforms for encryption of both binary and non-binary data. The lengths of the input and output sequence need not be identical. The method may be used also for hashing. INTRODUCTION The Hadamard transform is an example of generalized class of Fourier transforms [4], and it may be defined either recursively, or by using binary representation. Its symmetric form lends itself to applications ranging across many technical fields such as data encryption [1], signal processing [2], data compression algorithms [3], randomness measures [6], and so on. Here we consider an application of the Hadamard matrix to non-binary numbers. To do so, Hadamard transform is generalized such that all the values in the matrix are non negative. Each negative number is replaced with corresponding modulo number; for example while performing modulo 7 operations -1 is replaced with 6 to make the matrix non-binary. Only prime modulo operations are performed because non prime numbers can be divisible with numbers other than 1 and itself. The use of modulo operation along with generalized Hadamard matrix limits the output range and decreases computation complexity. In the method proposed in this paper, the input sequence is split into certain group of bits such that each group bit count is a prime number. As we are dealing with non-binary numbers, for each group of binary bits their corresponding decimal value is calculated.
    [Show full text]
  • Dominant Strategies of Quantum Games on Quantum Periodic Automata
    Computation 2015, 3, 586-599; doi:10.3390/computation3040586 OPEN ACCESS computation ISSN 2079-3197 www.mdpi.com/journal/computation Article Dominant Strategies of Quantum Games on Quantum Periodic Automata Konstantinos Giannakis y;*, Christos Papalitsas y, Kalliopi Kastampolidou y, Alexandros Singh y and Theodore Andronikos y Department of Informatics, Ionian University, 7 Tsirigoti Square, Corfu 49100, Greece; E-Mails: [email protected] (C.P.); [email protected] (K.K.); [email protected] (A.S.); [email protected] (T.A.) y These authors contributed equally to this work. * Author to whom correspondence should be addressed; E-Mail: [email protected]; Tel.: +30-266-108-7712. Academic Editor: Demos T. Tsahalis Received: 29 August 2015 / Accepted: 16 November 2015 / Published: 20 November 2015 Abstract: Game theory and its quantum extension apply in numerous fields that affect people’s social, political, and economical life. Physical limits imposed by the current technology used in computing architectures (e.g., circuit size) give rise to the need for novel mechanisms, such as quantum inspired computation. Elements from quantum computation and mechanics combined with game-theoretic aspects of computing could open new pathways towards the future technological era. This paper associates dominant strategies of repeated quantum games with quantum automata that recognize infinite periodic inputs. As a reference, we used the PQ-PENNY quantum game where the quantum strategy outplays the choice of pure or mixed strategy with probability 1 and therefore the associated quantum automaton accepts with probability 1. We also propose a novel game played on the evolution of an automaton, where players’ actions and strategies are also associated with periodic quantum automata.
    [Show full text]
  • Hadamard Phylogenetic Methods and the N-Taxon Process
    Bulletin of Mathematical Biology (2009) 71: 339–351 DOI 10.1007/s11538-008-9364-8 ORIGINAL ARTICLE Hadamard Phylogenetic Methods and the n-taxon Process David Bryant Department of Mathematics, University of Auckland, Auckland, New Zealand Received: 11 December 2007 / Accepted: 18 September 2008 / Published online: 10 October 2008 © Society for Mathematical Biology 2008 Abstract The Hadamard transform (Hendy and Penny, Syst. Zool. 38(4):297–309, 1989; Hendy, Syst. Zool. 38(4):310–321, 1989) provides a way to work with stochastic mod- els for sequence evolution without having to deal with the complications of tree space and the graphical structure of trees. Here we demonstrate that the transform can be ex- pressed in terms of the familiar P[τ]=eQ[τ] formula for Markov chains. The key idea is to study the evolution of vectors of states, one vector entry for each taxa; we call this the n-taxon process. We derive transition probabilities for the process. Significantly, the find- ings show that tree-based models are indeed in the family of (multi-variate) exponential distributions. Keywords Phylogenetics · Stochastic models · Hadamard conjugation · Spectral decomposition 1. Introduction 1.1. Stochastic models and the Hadamard transform Stochastic models for sequence evolution now play a part in most phylogenetic analyses. Given a tree, and a set of branch lengths, the models determine a probability distribution for the patterns of nucleotides/amino acids observed at a site in the alignment (the site patterns). The real difficulty of these tree-based models is that they are, indeed, based on a tree. The graphical structure of the tree is intrinsic to the probability formulas.
    [Show full text]
  • Quantum Computing: Lecture Notes
    Quantum Computing: Lecture Notes Ronald de Wolf Preface These lecture notes were formed in small chunks during my “Quantum computing” course at the University of Amsterdam, Feb-May 2011, and compiled into one text thereafter. Each chapter was covered in a lecture of 2 45 minutes, with an additional 45-minute lecture for exercises and × homework. The first half of the course (Chapters 1–7) covers quantum algorithms, the second half covers quantum complexity (Chapters 8–9), stuff involving Alice and Bob (Chapters 10–13), and error-correction (Chapter 14). A 15th lecture about physical implementations and general outlook was more sketchy, and I didn’t write lecture notes for it. These chapters may also be read as a general introduction to the area of quantum computation and information from the perspective of a theoretical computer scientist. While I made an effort to make the text self-contained and consistent, it may still be somewhat rough around the edges; I hope to continue polishing and adding to it. Comments & constructive criticism are very welcome, and can be sent to [email protected] Attribution and acknowledgements Most of the material in Chapters 1–6 comes from the first chapter of my PhD thesis [71], with a number of additions: the lower bound for Simon, the Fourier transform, the geometric explanation of Grover. Chapter 7 is newly written for these notes, inspired by Santha’s survey [62]. Chapters 8 and 9 are largely new as well. Section 3 of Chapter 8, and most of Chapter 10 are taken (with many changes) from my “quantum proofs” survey paper with Andy Drucker [28].
    [Show full text]
  • Experimental Demonstration of a Hadamard Gate for Coherent State Qubits
    Downloaded from orbit.dtu.dk on: Sep 24, 2021 Experimental demonstration of a Hadamard gate for coherent state qubits Tipsmark, Anders; Dong, Ruifang; Laghaout, Amine; Marek, Petr; Jezek, Miroslav; Andersen, Ulrik Lund Published in: Physical Review A Link to article, DOI: 10.1103/PhysRevA.84.050301 Publication date: 2011 Document Version Publisher's PDF, also known as Version of record Link back to DTU Orbit Citation (APA): Tipsmark, A., Dong, R., Laghaout, A., Marek, P., Jezek, M., & Andersen, U. L. (2011). Experimental demonstration of a Hadamard gate for coherent state qubits. Physical Review A, 84(5), -. https://doi.org/10.1103/PhysRevA.84.050301 General rights Copyright and moral rights for the publications made accessible in the public portal are retained by the authors and/or other copyright owners and it is a condition of accessing publications that users recognise and abide by the legal requirements associated with these rights. Users may download and print one copy of any publication from the public portal for the purpose of private study or research. You may not further distribute the material or use it for any profit-making activity or commercial gain You may freely distribute the URL identifying the publication in the public portal If you believe that this document breaches copyright please contact us providing details, and we will remove access to the work immediately and investigate your claim. RAPID COMMUNICATIONS PHYSICAL REVIEW A 84, 050301(R) (2011) Experimental demonstration of a Hadamard gate for coherent state qubits Anders Tipsmark,1,* Ruifang Dong,2,1 Amine Laghaout,1 Petr Marek,3 Miroslav Jezek,ˇ 3,1 and Ulrik L.
    [Show full text]
  • On Quantum Algorithms
    Contribution to Complexity On quantum algorithms Richard Cleve, Artur Ekert, Leah Henderson, Chiara Macchiavello and Michele Mosca Centre for Quantum Computation Clarendon Laboratory, University of Oxford, Oxford OX1 3PU, U.K. Department of Computer Science University of Calgary, Calgary, Alberta, Canada T2N 1N4 Theoretical Quantum Optics Group Dipartimento di Fisica “A. Volta” and I.N.F.M. - Unit`adi Pavia Via Bassi 6, I-27100 Pavia, Italy Abstract Quantum computers use the quantum interference of different computational paths to en- hance correct outcomes and suppress erroneous outcomes of computations. In effect, they follow the same logical paradigm as (multi-particle) interferometers. We show how most known quan- tum algorithms, including quantum algorithms for factorising and counting, may be cast in this manner. Quantum searching is described as inducing a desired relative phase between two eigen- vectors to yield constructive interference on the sought elements and destructive interference on the remaining terms. 1 From Interferometers to Computers Richard Feynman [1] in his talk during the First Conference on the Physics of Computation held at MIT in 1981 observed that it appears to be impossible to simulate a general quantum evolution on a classical probabilistic computer in an efficient way. He pointed out that any classical simulation of quantum evolution appears to involve an exponential slowdown in time as compared to the natural evolution since the amount of information required to describe the evolving quantum state in classical terms generally grows exponentially in time. However, instead of viewing this as an obstacle, Feynman regarded it as an opportunity. If it requires so much computation to work out what will happen in a arXiv:quant-ph/9903061v1 17 Mar 1999 complicated multiparticle interference experiment then, he argued, the very act of setting up such an experiment and measuring the outcome is tantamount to performing a complex computation.
    [Show full text]
  • Efficient Classical Simulation of Random Shallow 2D Quantum Circuits
    Efficient classical simulation of random shallow 2D quantum circuits John Napp* Rolando L. La Placa† Alexander M. Dalzell‡ Fernando G. S. L. Brandao˜ § Aram W. Harrow¶ February 13, 2020 Abstract Random quantum circuits are commonly viewed as hard to simulate classically. In some regimes this has been formally conjectured — in the context of deep 2D circuits, this is the basis for Google’s recent announcement of “quantum computational supremacy” — and there had been no evidence against the more general possibility that for circuits with uniformly ran- dom gates, approximate simulation of typical instances is almost as hard as exact simulation. We prove that this is not the case by exhibiting a shallow random circuit family that cannot be efficiently classically simulated exactly under standard hardness assumptions, but can be simulated approximately for all but a superpolynomially small fraction of circuit instances in time linear in the number of qubits and gates; this example limits the robustness of re- cent worst-case-to-average-case reductions for random circuit simulation. While our proof is based on a contrived random circuit family, we furthermore conjecture that sufficiently shal- low constant-depth random circuits are efficiently simulable more generally. To this end, we propose and analyze two simulation algorithms. Implementing one of our algorithms for the depth-3 “brickwork” architecture, for which exact simulation is hard, we found that a laptop could simulate typical instances on a 409 409 grid with variational distance error less than 0:01 in approximately one minute per sample,× a task intractable for previously known cir- cuit simulation algorithms.
    [Show full text]
  • Quantum Algorithms
    Quantum algorithms Andrew Childs Pawel Wocjan University of Waterloo University of Central Florida 10th Canadian Summer School on Quantum Information 17{19 July 2010 Outline I. Quantum circuits II. Elementary quantum algorithms III. The QFT and phase estimation IV. Factoring V. Quantum search VI. Quantum walk Part I Quantum circuits Quantum circuit model Quantum circuits are generalizations of Boolean circuits input transformation output (probabilistic) 1 U1 0 j i U3 U6 1 U5 1 j i U2 NM 0 0 j i U6 NM 1 U4 1 j i U3 U7 NM 0 1 j i NM NM Classical bit Classical bit (bit): B := 0; 1 f g I Basis state: either 0 or 1 I General state: a probability distribution p = (p0; p1) on B Classical register n Classical register: B := B B ::: B × × × | {zn } n I Basis state: a binary string x B 2 n I General state: a probability distribution p = (px : x B ) on n 2 B (written as a column vector) Remark: Note that p is a vector with positive entries that is normalized with respect to the `1-norm (the sum of the absolute values of the entries) Classical transformation Transformations on the classical register B are described by stochastic matrices Stochastic matrices preserve the `1-norm, i.e., probability distributions are mapped on probability distributions Let p be the state of the register. The state after the transformation P is given by the matrix-vector-product Pp Qubit 2 Quantum bit (qubit): two-dimensional complex Hilbert space C I Computational basis states (classical states): 1 0 0 := and 1 := j i 0 j i 1 I General states: superpositions α0
    [Show full text]
  • Quantum Algorithms Via Linear Algebra: a Primer / Richard J
    QUANTUM ALGORITHMS VIA LINEAR ALGEBRA A Primer Richard J. Lipton Kenneth W. Regan The MIT Press Cambridge, Massachusetts London, England c 2014 Massachusetts Institute of Technology All rights reserved. No part of this book may be reproduced in any form or by any electronic or mechanical means (including photocopying, recording, or information storage and retrieval) without permission in writing from the publisher. MIT Press books may be purchased at special quantity discounts for business or sales promotional use. For information, please email special [email protected]. This book was set in Times Roman and Mathtime Pro 2 by the authors, and was printed and bound in the United States of America. Library of Congress Cataloging-in-Publication Data Lipton, Richard J., 1946– Quantum algorithms via linear algebra: a primer / Richard J. Lipton and Kenneth W. Regan. p. cm. Includes bibliographical references and index. ISBN 978-0-262-02839-4 (hardcover : alk. paper) 1. Quantum computers. 2. Computer algorithms. 3. Algebra, Linear. I. Regan, Kenneth W., 1959– II. Title QA76.889.L57 2014 005.1–dc23 2014016946 10987654321 We dedicate this book to all those who helped create and nourish the beautiful area of quantum algorithms, and to our families who helped create and nourish us. RJL and KWR Contents Preface xi Acknowledgements xiii 1 Introduction 1 1.1 The Model 2 1.2 The Space and the States 3 1.3 The Operations 5 1.4 Where Is the Input? 6 1.5 What Exactly Is the Output? 7 1.6 Summary and Notes 8 2 Numbers and Strings 9 2.1 Asymptotic Notation
    [Show full text]