From 9decb7ce57f4343c47c28a51bdaa0212b2d10b3f Mon Sep 17 00:00:00 2001 From: SoniaLopezBravo Date: Tue, 13 Aug 2024 20:37:53 +0200 Subject: [PATCH] scrubbing LaTeX --- katas/content/multi_qubit_measurements/index.md | 3 +-- .../multi_qubit_measurements/joint_measurements/solution.md | 4 ++-- .../multi_qubit_measurements/state_preparation/index.md | 2 +- .../multi_qubit_measurements/state_preparation/solution.md | 2 +- 4 files changed, 5 insertions(+), 6 deletions(-) diff --git a/katas/content/multi_qubit_measurements/index.md b/katas/content/multi_qubit_measurements/index.md index 089132fefb..7d83226aa2 100644 --- a/katas/content/multi_qubit_measurements/index.md +++ b/katas/content/multi_qubit_measurements/index.md @@ -407,8 +407,7 @@ For certain multi-qubit systems prepared in a superposition state, it's possible Any multi-qubit state can be prepared from the $\ket{0...0}$ state using an appropriate combination of quantum gates. However, sometimes it's easier and more efficient to prepare a state using partial measurements. -You could prepare a simpler state involving additional qubits, which, when measured, result in a collapse of the remaining qubits to the desired state with a high probability. This is called **post-selection**, and is particularly useful if it' -s easier to prepare the pre-measurement state with the extra qubits than to prepare the desired state directly using unitary gates alone. This is demonstrated by the following exercise. +You could prepare a simpler state involving additional qubits, which, when measured, result in a collapse of the remaining qubits to the desired state with a high probability. This is called **post-selection**, and is particularly useful if it's easier to prepare the pre-measurement state with the extra qubits than to prepare the desired state directly using unitary gates alone. This is demonstrated by the following exercise. @[exercise]({ "id": "multi_qubit_measurements__state_preparation_using_partial_measurements", diff --git a/katas/content/multi_qubit_measurements/joint_measurements/solution.md b/katas/content/multi_qubit_measurements/joint_measurements/solution.md index 4845b3b913..bef55dc02b 100644 --- a/katas/content/multi_qubit_measurements/joint_measurements/solution.md +++ b/katas/content/multi_qubit_measurements/joint_measurements/solution.md @@ -1,11 +1,11 @@ -If you weren't asked to maintain the state of the qubits, one approach would be to measure both the qubits separately in the computational basis, and check if the result is the same for both the measurements. If the measurement results are equal, the input state must have been a superposition of $\ket{00}$ and $\ket{11}$, while different measurement outcomes will imply that the input state must have been a superposition of $\ket{01}$ and $\ket{10}$. However, in these measurements we will lose the information about the original superposition states: a state $\alpha \ket{00} + \beta \ket{11}$ will collapse to either $\ket{00}$ or $\ket{11}$, and you won't be able to recover the information about the coefficients $\alpha$ and $\beta$. +If you weren't asked to maintain the state of the qubits, one approach would be to measure both the qubits separately in the computational basis, and check if the result is the same for both the measurements. If the measurement results are equal, the input state must have been a superposition of $\ket{00}$ and $\ket{11}$, while different measurement outcomes will imply that the input state must have been a superposition of $\ket{01}$ and $\ket{10}$. However, in these measurements you'll lose the information about the original superposition states: a state $\alpha \ket{00} + \beta \ket{11}$ will collapse to either $\ket{00}$ or $\ket{11}$, and you won't be able to recover the information about the coefficients $\alpha$ and $\beta$. You need to measure the *parity* of the state without collapsing it all the way to the basis states. Pauli measurements can be used for joint measurements involving multiple qubits. For this task we need to do the $Z \otimes Z$ measurement on both qubits. A joint measurement using $Z \otimes Z$ operator can be thought of as projecting the measured state to one of the two eigenspaces of $Z \otimes Z$ with $+1$ and $-1$ as the corresponding eigenvalues. The measurement returns `Zero` if the measured state is projected to the space with an eigenvalue of $+1$, and a result of `One` if projected to the space with an eigenvalue of $-1$. As you've seen in the tutorial, the state $\alpha \ket{00} + \beta \ket{11}$ is an eigenstate of the $Z \otimes Z$ operator with the eigenvalue $+1$, and the state $\alpha \ket{01} + \beta \ket{10}$ is an eigenstate with the eigenvalue $-1$. -Hence, you can use this joint measurement to recognize which of the superposition states we were given while preserving the initial superposition state. +Hence, you can use this joint measurement to recognize which of the superposition states you were given while preserving the initial superposition state. In Q#, the operation `Measure` can be used to measure multiple qubits using an array of `Pauli` constants (`PauliI`, `PauliX`, `PauliY`, or `PauliZ`) that define the basis for measurement. diff --git a/katas/content/multi_qubit_measurements/state_preparation/index.md b/katas/content/multi_qubit_measurements/state_preparation/index.md index 588cf667e8..51b9e09644 100644 --- a/katas/content/multi_qubit_measurements/state_preparation/index.md +++ b/katas/content/multi_qubit_measurements/state_preparation/index.md @@ -6,5 +6,5 @@
Need a hint? Consider a 3-qubit state $\frac{1}{2}(\ket{00} + \ket{01} + \ket{11}) \otimes \ket{0} + \frac{1}{2} \ket{11} \otimes \ket{1}$. - What happens when one measures the third qubit? + What happens when you measure the third qubit?
diff --git a/katas/content/multi_qubit_measurements/state_preparation/solution.md b/katas/content/multi_qubit_measurements/state_preparation/solution.md index fd431a2930..523797cd19 100644 --- a/katas/content/multi_qubit_measurements/state_preparation/solution.md +++ b/katas/content/multi_qubit_measurements/state_preparation/solution.md @@ -1,6 +1,6 @@ While it's possible to prepare the state $\ket \psi$ directly using unitary rotations, it's simpler to use post-selection for preparing it. -Initially, you prepare an equal superposition of all basis states on the first two qubits by applying the **H** gate to each of them, and allocate an extra qubit in the $\ket{0}$ state: +Initially, you prepare an equal superposition of all basis states on the first two qubits by applying the $H$ gate to each of them, and allocate an extra qubit in the $\ket{0}$ state: $$\frac{1}{2} \big(\ket{00} + \ket{01} + \ket{10} + \ket{11}\big) \otimes \ket 0$$ The state of the first two qubits is a superposition of the state you want to prepare and the $\ket{11}$ state that you want to discard.