Quantum Katas

repository·main·Indexed 26 days ago

https://github.com/microsoft/quantumkatas

A collection of self-paced tutorials and programming exercises designed to teach quantum computing concepts and Q# programming. Using a task-based approach with unit tests, the katas cover topics including basic gates, Grover's search algorithm, the BB84 protocol, Quantum Fourier Transform (QFT), phase estimation, and quantum error-correction via the three-qubit bit-flip code.

Tokens
93.5K
Snippets
372
Records
490
Agent score
39%

What's inside Quantum Katas

  1. Overview of the Three-Qubit Bit-Flip Code Kata

    main
    This kata focuses on the three-qubit bit-flip code, the simplest quantum error-correction (QEC) code. It involves encoding a single logical qubit into three physical qubits to protect against single bit-flip errors (X gate errors). This is the quantum version of the classical repetition code, adapted for quantum mechanics where state cloning is impossible.
  2. Overview of the GHZ Game Kata

    main
    The GHZ (Greenberger-Horne-Zeilinger) game kata focuses on a nonlocal (entanglement) game. In this scenario, multiple cooperating players play against a referee. Players can share information or qubits before the game begins but are prohibited from communicating once the game starts. The kata demonstrates how quantum entanglement allows players to achieve higher winning probabilities than classical strategies permit.
  3. Overview of the BoundedKnapsack Kata

    main

    The BoundedKnapsack quantum kata is a series of exercises focused on using Grover's search algorithm to solve the knapsack optimization problem.

    Key objectives:

    • Implement oracles that represent various parts of the knapsack problem.
    • Use these oracles within Grover's algorithm to find an optimal solution.

    This kata is based on the circuits described in the paper "Quantum-based algorithm and circuit design for bounded knapsack optimization problem" by Wenjun Hou and Marek Perkowski.

  4. Overview of the Quantum Fourier Transform (QFT) Kata

    main

    The Quantum Fourier Transform kata provides exercises to learn the basics of the quantum Fourier transform. It focuses on two primary areas:

    1. Implementation: Implementing the quantum Fourier transform algorithm.
    2. Application: Using the QFT to solve simple quantum tasks.

    The kata follows the standard algorithm described in Nielsen, M. A. & Chuang, I. L. (2010). Quantum Computation and Quantum Information. pp.217-221 and the lecture notes by John Watrous.

  5. Overview of Grover's Algorithm Kata

    main
    The Grover's Algorithm kata focuses on implementing Grover's search algorithm, a fundamental quantum algorithm used to find an input to a black box (oracle) that produces a specific output. The tasks in this kata are aligned with the theoretical explanations found in Quantum Computation and Quantum Information by Nielsen and Chuang (Section 6.1.2).
  6. Overview of the Teleportation Kata

    main

    The Teleportation kata focuses on the quantum teleportation protocol. This protocol enables the communication of a quantum state using only classical communication and pre-shared quantum entanglement.

    For further study, you can refer to:

  7. Overview of the Graph Coloring Kata

    main

    The Graph Coloring kata is an advanced exploration of Grover's search algorithm. It focuses on writing oracles that describe a problem (using graph coloring as the example) rather than the solution itself. It also covers implementing Grover's search to handle problems with an unknown number of solutions.

    Prerequisites: