Skip to content

Measurement error in the README.md? #12

@bortzmeyer

Description

@bortzmeyer

README.md says (example "Pure python quantum computing machinery"):

qc.measure("q1")
qc.measure("q2")
Probability.pretty_print_probabilities(qc.qubits.get_quantum_register_containing("q1").get_state())

If you do so, the last line always output:

|psi>=|00>
Pr(|00>)=1.000000; 
<state>=1.000000

Because measurement destroyed the state. IMHO, it should be get_noop instead of get_state.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions