Skip to content

Bug in wc.mapped_basis #14

@adriankoehlerfu

Description

@adriankoehlerfu
  • weylchamber version: 0.6.0
  • Python version: 3.12
  • Operating System: Windows

Description

The mapped_basis function is supposed to map N basis states via a unitary N x N gate to N final states. However, a simple example for the known CNOT gate shows that something is wrong. The code is here.

The CNOT gate in the canonical form (see first output) flips the second qubit if the first qubit is |1>. Applying the CNOT to a superposition of the form |00> + |10> should always result in the maximally entangled state |00> + |11>. Numerically of course this boils to down to U*|psi> ~ U* |00> + |10>. This manual procedure works as intended (see second output).

The outputs of weylchamber.mapped_basis function are shown in the third output. None of the outputs are entangled, so its not even the ordering of outputs that resolves this problem. Even if the labels of 01 and 10 are twisted, the state |00> + |11> wouldnt change.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions