Idealized States Redux—Multi-Qubit Version

Before learning to precisely manipulate multiple qubits in quantum circuits, like you did with single qubits in Chapter 6, Designer Genes—Custom Quantum States, and Chapter 7, Small Step for Man—Single Qubit Programs, you need to augment your understanding of idealized states.

Idealized States for One Qubit

The idealized states for single qubits are the two ways that it can collapse. Consider, for example, a qubit having five pentagon images/_pragprog/svg-17.png and two triangle images/_pragprog/svg-18.png qubelets (both rotated), as shown in the following figure:

images/multi_qubit_algebra/Rotated_Qubelets_5_Pentagon_2_Triangles.png

Regardless of how the pentagon images/_pragprog/svg-17.png and triangle images/_pragprog/svg-18.png qubelets are rotated, this qubit collapses in one of the following two ways:

Collapses to images/_pragprog/svg-17.png
images/multi_qubit_algebra/Qubelets_Collapsing_to_0.png
Collapses to images/_pragprog/svg-18.png
images/multi_qubit_algebra/Qubelets_Collapsing_to_1.png

Of course, the qubit would collapse more frequently to images/_pragprog/svg-17.png than images/_pragprog/svg-18.png because the qubit has a greater number of pentagon images/_pragprog/svg-17.png qubelets than triangle images/_pragprog/svg-18.png qubelets. But it would always collapse to one of these two types.

Thus, as in Quantum States and Probabilities, any quantum state images/_pragprog/svg-127.png can be expressed in terms of the idealized states images/_pragprog/svg-17.png and images/_pragprog/svg-18.png, as follows:

images/_pragprog/svg-block-241.png

The parameters images/_pragprog/svg-84.png and images/_pragprog/svg-85.png are the amplitudes associated with the idealized states. By setting different values for the amplitudes images/_pragprog/svg-84.png and images/_pragprog/svg-85.png, you can specify any quantum state. And the subscript on the quantum state images/_pragprog/svg-127.png indicates that it’s a quantum state for a single qubit.

In terms of vectors, as shown in Quantum States as Vectors, the quantum state images/_pragprog/svg-127.png can also be written as:

images/_pragprog/svg-block-242.png

Idealized States for Two Qubits

When dealing with two qubits, the situation is similar: each qubit collapses to either images/_pragprog/svg-17.png or images/_pragprog/svg-18.png. Thus, we can write the ways that two qubits collapse as follows:

Qubit 1

Qubit 2

images/_pragprog/svg-17.png

images/_pragprog/svg-17.png

images/_pragprog/svg-17.png

images/_pragprog/svg-18.png

images/_pragprog/svg-18.png

images/_pragprog/svg-17.png

images/_pragprog/svg-18.png

images/_pragprog/svg-18.png

Thus, the idealized states of the two qubits are as follows:

images/_pragprog/svg-block-243.png

These, then, are the 22, or 4, idealized states for two qubits, and any two-qubit quantum state can be expressed in terms of these four idealized states. Specifically, if the quantum state of the first qubit is images/_pragprog/svg-127.png and that of the second is images/_pragprog/svg-312.png, then the quantum state of the two-qubit system is written as images/_pragprog/svg-313.png.

images/_pragprog/svg-block-244.png

The coefficients images/_pragprog/svg-314.png, images/_pragprog/svg-315.png, images/_pragprog/svg-316.png, and images/_pragprog/svg-317.png are the amplitudes of the idealized states images/_pragprog/svg-71.png, images/_pragprog/svg-74.png, images/_pragprog/svg-318.png, and images/_pragprog/svg-319.png, respectively.

Since the two qubits can only collapse to these four idealized states, the probabilities of collapsing to them, the “squares” of the amplitudes—an amplitude multiplied by its conjugate—sum up to 1:

images/_pragprog/svg-block-245.png

The quantum state of a two-qubit system is completely defined by these four amplitudes. It’s also expressed by the vector shown.

images/_pragprog/svg-block-246.png

This vector, in turn, can be written in terms of the four idealized states:

images/_pragprog/svg-block-247.png

Since there are four idealized states, the quantum state of a two-qubit system will be a images/_pragprog/svg-320.png vector. Specifically, the vectors for the four idealized states are:

images/_pragprog/svg-block-248.png

Each element in the vector corresponds to an idealized state. So, the first element is associated with images/_pragprog/svg-71.png, the second with images/_pragprog/svg-74.png, and so on, till the last with images/_pragprog/svg-319.png.

These idealized states aren’t just theoretical concepts. They underpin all quantum programs, as shown in the next section.

Idealized States and Quantum Programs

Idealized states are closely intertwined with quantum programs—they’re the outputs. Consider, for example, the two-qubit quantum circuit shown in the following figure:

images/multi_qubit_algebra/0_Measure_1_H_S_Measure.png

Analyze this circuit by first looking at each qubit individually:

Qubit q[0]

No gates act on the q[0] qubit:

images/_pragprog/svg-block-249.png
Qubit q[1]

The H gate splits the images/_pragprog/svg-17.png qubit in q[0] to a pentagon images/_pragprog/svg-17.png qubelet and a triangle images/_pragprog/svg-18.png qubelet. The S gate then rotates the triangle images/_pragprog/svg-18.png qubelet 90°, or a quarter turn clockwise, as shown in the following figure:

images/quantum_gates_algebra/One_Pentagon_One_Triangle_Quarter_Rotated.png

Alternatively, you can also use the gate matrices (see Classifying Quantum Gates) and the vector for the idealized state images/_pragprog/svg-17.png, as follows:

images/_pragprog/svg-block-250.png

This vector indicates that the quantum state images/_pragprog/svg-312.png is made up of a pentagon images/_pragprog/svg-17.png qubelet and a triangle images/_pragprog/svg-18.png qubelet rotated 90° anticlockwise.

But, because this is a quantum circuit, there’s an additional step that has no classical equivalent: the formation of the mega-qubit, as described in Multi-Qubit Superposition: The Mega-Qubit, to get the quantum state images/_pragprog/svg-313.png of the two-qubit circuit.

The pentagon images/_pragprog/svg-17.png qubelet in the top qubit q[0] pairs up with the qubelets in the bottom qubit q[1] to give the mega-qubit shown in the figure.

images/multi_qubit_algebra/Mega_Qubit_for_0_1_H_S.png

This mega-qubit can collapse to either of the two qubelet combinations with equal probability. To get the quantum state of the mega-qubit, normalize the chances of picking a qubelet combination by following the procedure similar to that described in Normalizing Qubelets, but apply it for qubelet combinations instead of qubelets:

images/_pragprog/svg-block-251.png

The triangle images/_pragprog/svg-18.png qubelet at the bottom of the second qubelet combination is rotated a quarter turn anticlockwise. As a result you see the complex number images/_pragprog/svg-106.png associated with the second term.

Since this qubit has two qubelet combinations, it collapses in one of the following two ways:

Collapses to images/_pragprog/svg-71.png

When this mega-qubit is measured, the qubelet combination on the left is selected roughly 50% of the time and collapses to images/_pragprog/svg-71.png, as shown here:

images/multi_qubit_algebra/Mega_Qubit_for_0_1_H_S_Collapsing_to_0_0.png

 

This corresponds to the following vector:

images/_pragprog/svg-block-252.png
Collapses to images/_pragprog/svg-74.png

When this mega-qubit is measured, the qubelet combination on the right is selected roughly 50% of the time and collapses to images/_pragprog/svg-74.png, as shown in the following figure:

images/multi_qubit_algebra/Mega_Qubit_for_0_1_H_S_Collapsing_to_0_1.png

Although rotated qubelets play a pivotal role in quantum effects such as entangling and canceling qubelets, when a qubit collapses, qubelets are reset to their non-rotated orientations. Thus, the rotated triangle images/_pragprog/svg-18.png qubelet snaps back to the non-rotated position.

The collapsed qubelet combination corresponds to the following vector:

images/_pragprog/svg-block-253.png

You can verify that this circuit does indeed work as the analysis just described by running it on the IBM Quantum Computer. The code listing for this circuit is as follows:

1: qreg q[2];
2: creg c[2];
3: 
4: h q[1];
5: s q[1];
6: measure q[0] -> c[0];
7: measure q[1] -> c[1];

The H and S gates acting on the q[1] qubit are declared on lines 4 and 5, respectively, followed by the Measure gates.

The output of this program running on a real quantum computer is shown in the following figure:

images/multi_qubit_algebra/0_Measure_1_H_S_Measure_Output.png

This program collapses to the two binary states 00 and 10 roughly half the time. The other two states are just noise when using a real quantum computer. Because of the way that IBM’s classical register is structured (see Using the IBM Computer: Multi-Bit Classical Register), the highest numbered classical bit, in this case c[1], is written first. Thus, the 10 state corresponds to c[1]c[0], which, in turn, records the qubits q[1]q[0]. Hence, the measured classical states 00 and 01 correspond to images/_pragprog/svg-71.png and images/_pragprog/svg-74.png, respectively. In other words, the measured classical states reflect the idealized states.

Idealized States for Three or More Qubits

Determining the idealized states for three or more qubits is analogous: document the ways that the qubits collapse. For example, a three-qubit quantum state images/_pragprog/svg-321.png collapses to the following images/_pragprog/svg-322.png vectors:

images/_pragprog/svg-block-254.png

The idealized states for images/_pragprog/svg-4.png qubits follow a similar pattern: you’ll end up with 2n states. As images/_pragprog/svg-4.png—the number of qubits in your program—grows, the number of idealized states grows exponentially and become impossible to write down. But the mega-qubit is able to handle all these states simultaneously. So, whereas it’s difficult for a classical computer to work with them, a quantum computer merely needs images/_pragprog/svg-4.png qubits, a far smaller number, to work with.

In the next section, you’ll see how the idealized states are intimately tied to the gate matrix.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.138.174.195