q5m.js - Quantum Computing Library - v0.1.1
    Preparing search index...

    Function grover

    • Convenient wrapper for searching a specific item using Grover's algorithm.

      This function provides a simple interface for searching for a single target item in the quantum search space using the optimized Grover implementation.

      Parameters

      • numQubits: number

        Number of qubits in the system

      • targetItem: string

        Binary string to search for (must be numQubits long)

      • options: GroverOptions = {}

        Optional configuration for the search

      Returns Circuit

      Circuit that searches for the target item

      If target item length doesn't match numQubits