3.3, 5.10, 5.11, 5.12, 5.15 from Kasirajan
and the other document.
Kasirajan
3.3
Question
Consider a system of 4 qubits (spin- states). How many states are exhibited by the system?
Proof
Since there are 4 qubits, each with a possible or , which we relabel to the corresponding states. As such, this question is just asking how many different numbers are represented by 4 bits, which is total states of the system. This is assuming that no entanglement from our QC occurs, but we can assume that's not the case since this is independents of the QC.
☐
5.10
Question
Verify whether the circuits shown in the following figure are equivalent:
Proof
Consider arbitrary inputs given . Since we have 2 qubits, we have 4 possible quantum states where is a superposition of these:
Apply each QC to this state to see what happens.
(a):
And similarly:
Thus applying CNOT:
Then applying the last gate to just the top two rows:
(b):
Notice that, in general, so these QC's are not equal. This is best shown doing the computation where the input is , as then while which are different states (not even by some relative phase).
☐
5.11
Question
What is the output of the quantum circuit shown in the following figure? Assume all qubits are initialized to the default state . Calculate the circuits's width and depth. Evaluate the circuit for other combinations of inputs and produce a truth table.
Proof
Notice that since our initial input states are all in , then we start in the state. As such:
Let's consider each gate operating on our starting arbitrary input state:
for each part of . Notice that we can write:
We write all our steps in a table:
Step (CNOT Gate #)
bits
States that change and corresponding maps
Effect on 's
1
Control: 2, 3 Target: 4
2
Control: 0, 1 Target: 3
3
Control: 2, 3 Target: 4
4
Control: 0, 1 Target: 3
We can itemize all our entries and see what swapped with what:
All in all, this gate is equivalent to the identity except that it swaps the probabilities associated with around. Namely:
As such, the truth table is:
Input
Output
Anything Else
Identity (same input)
As such, then the output state of our given circuit is . We have 4 qubits, so a width of 4 and our longest path is 4 so a depth of 4 is also apparent.
☐
5.12
Question
What is the output of the quantum circuit illustrated in the following figure? Calculate the circuit's width and depth.
Proof
We go step by step along the depth of the circuit:
:
Notice for qubit 1 after :
Similarly at the same time:
So our total state would be:
:
We do on as the control and as the target:
So we have entanglement here!
We have:
On the other qubit :
Putting them together:
:
Replicate the same calculation done for here, except do it for . As a result:
:
:
:
:
So our final state will be
Notice that we have 4 qubits so our width is 4. Furthermore, we have the longest path is traversed by with a length of 4 (we can ignore the reading steps and parallelize all of them), so our depth is 4.
☐
5.15
Question
The square root of the -gate and it Hermitian conjugate are called the and gates. The matrices from the following equation define them. Develop quantum circuits to emulate them. Derive the math and establish that the circuit works.
Notice that all we have to do to show that is show that which we do:
Thus is the unique square root of the -gate (it's unique since we only deal with unitary matrices, so all matrices like is positive). Clearly is correctly defined as it is the complex conjugate of .
To construct to start, we know that can span any gate, so make it out of that. Notice specifically that:
So equate entries. Notice that we need:
But will never be imaginary for . As such, we need to do some rotations first to get ourselves in the correct relative phase. We essentially want to multiply our number by the complex conjugate to get our real entry:
Thus we need to apply some transformation like perhaps:
So we need to rotate radians, preferably via :
We still need to reduce this to the identity, as then we apply the gates backwards to get our implementation.
We can now can use the gate. Equating items that we currently have, we see that we need:
As a result, looking at the next entry:
Thus we can get our last parameter :
Therefore, we can construct:
Notice we can verify that this combinations of gates works by flipping their order in the way we applied them here: