# Tag Info

17

Specific Circuit The first gate is a Hadamard gate which is normally represented by $$\frac{1}{\sqrt{2}}\begin{bmatrix}1&1\\1&-1\end{bmatrix}$$ Now, since we're only applying it to the first qubit, we use a kronecker product on it (this confused me so much when I was starting out - I had no idea how to scale gates; as you can imagine, it's rather ...

8

For any matrix $A$ we can write $$A =\sum_{i,j,k,l}h_{ijkl}\cdot \frac{1}{4}\sigma_i\otimes\sigma_j\otimes\sigma_k\otimes\sigma_l,$$ where $$h_{ijkl} = \frac{1}{4}\text{Tr}\big((\sigma_i\otimes\sigma_j\otimes\sigma_k\otimes\sigma_l)^\dagger \cdot A\big) = \frac{1}{4}\text{Tr}\big((\sigma_i\otimes\sigma_j\otimes\sigma_k\otimes\sigma_l) \cdot A\big)$$ ...

7

From IBM Q Documentation (the link is hard to find) here is the definition of the generic gate: $$U(\theta, \phi, \lambda) = \begin{pmatrix} \cos\left(\frac{\theta}{2}\right) & -e^{i\lambda} \sin\left(\frac{\theta}{2}\right) \\ e^{i\phi} \sin\left(\frac{\theta}{2}\right) & e^{i(\lambda + \phi)} \cos\left(\frac{\theta}{2}\right) \end{pmatrix}$$ ...

7

The Hilbert space dimension of $n$ qudits is $d^n$, where $d$ is the dimension of the qudit ($d=2$ for qubit, $d=3$ for qutrit, etc). So three qubits have an $8$ dimensional space, two qutrits have a $9$ dimensional space, and one $d=6$ qudit has a six dimensional space. As such, we cannot regard them as equivalent. I guess you meant to compare situations ...

6


5

That's not the right way to look at it. In quantum mechanics, time evolutions are considered to be unitary and any unitary evolution can be written as a sequence of unitary operators $U_1, U_2, U_3,\ldots$ acting on a quantum state $|\Psi\rangle$. Any single-qubit unitary operation is a $2\times 2$ matrix of the form: $$U=\begin{pmatrix}a&b\\-e^{i\phi}b^... 5 Yes, in the circuit the qubit "enters" to the left, and exits to the right, but when applying the gates to a state you must apply the one on the far left first, then the next and so on, so concretely you do write them down right to left, but it's just a consequence of writing the operator that we want to apply on the left of the vector, while our natural way ... 5 You specifically ask about qubits, so I'll keep it to that. Imagine you have a state$$ |\psi\rangle=\sum_{x\in\{0,1\}^n}a_x|x\rangle. $$You can choose to look at each qubit. I'll take the first qubit for the sake of simplicity. We have that$$ |\psi\rangle=|0\rangle\sum_{y\in\{0,1\}^{n-1}}a_{0y}|y\rangle+|1\rangle\sum_{y\in\{0,1\}^{n-1}}a_{1y}|y\rangle $$... 5 Here, what you need to do is to understand writing CNOT gate based on the control qubit. Your first CNOT gate has qubit 1 as control and qubit 2 as target. So, what this means is the second qubit will not be flipped until qubit 1 is set to zero. I am going to use computational basis for this CNOT_1\left|00\right> = \left|00\right>, CNOT_1\left|01\... 5 All tensor products of n Pauli operators \{I,X,Y,Z\} (that is 4^n combinations) form an orthogonal basis for the vector space of 2^n \times 2^n complex matrices. Hence, for every matrix there is a unique decomposition as a linear combination of tensor products of Pauli unitaries. Same is true if we fix some other unitary basis. If we not fix the ... 4 Mostly I'm confused over whether the common convention is to use +i or -i along the anti-diagonal of the middle 2x2 block. The former. There are two +i's along the anti-diagonal of the middle 2\times 2 block of the iSWAP gate. See page 95 here[\dagger]. [\dagger]: Explorations in Computer Science (Quantum Gates) - Colin P. Williams 4 You can use Python with Qiskit. Say your string representation is written using OpenQASM syntax. qasm = """ OPENQASM 2.0; include "qelib1.inc"; qreg q[2]; h q[0]; t q[1]; cx q[0], q[1]; """ You can build a circuit out of this and simulate it on a unitary simulator: import qiskit as qk import numpy as np circuit = qk.load_qasm_string(qasm) result = qk.... 4 Consider the linear maps A: V\to W and B: W\to X. The composition BA is a linear map from V to X. Now, how can \mathcal{M}(BA) be computed from \mathcal{M}(B) and \mathcal{M}(A)? \mathcal{M}(A) is the n\times p matrix representation of the linear map A w.r.t the basis \{v_1,...,v_p\} and \{w_1,...,w_n\}. \mathcal{M}(B) is the m\... 4$$ CNOT = \begin{bmatrix} 1 & 0 & 0 & 0 \\ 0 & 1 & 0 & 0 \\ 0 & 0 & 0 & 1 \\ 0 & 0 & 1 & 0 \\ \end{bmatrix} $$But what does this matrix mean? The above matrix means: on a two qubit system (such as \left|00\right>, \left|10\right>, \left|11\right>, etc.) if the first qubit is a one,... 4 This is called Sylvester's Criterion. There's plenty of information available once you have the name. The linked wikipedia article contains a proof. Strictly, Sylvester's Criterion requires that W_2,W_3,W_4> 0 for the state to be positive under the partial transpose. However, for a density matrix, W_2 is always positive semi-definite. This is because ... 4 Recall that the trace is both linear and invariant under cyclic permutation of the operators$$ \mathrm{Tr}(\Phi(\rho))=\mathrm{Tr}\left(\sum_j F_j^\dagger \rho F_j\right)=\sum_j\mathrm{Tr}\left( F_j^\dagger \rho F_j\right)=\sum_j \mathrm{Tr}\left(F_jF_j^\dagger \rho \right)= \mathrm{Tr}\left(\sum_jF_jF_j^\dagger \rho \right)$$You can clearly see that if ... 4 Consider that a control qubit is q_k and a target qubit is q_{k+n} and you want to apply operator U on the target qubit. Denote N=2^{n+1}. Then matrix representation of this controlled U is $$CU= \begin{pmatrix} I_{\frac{N}{2}} & O_{\frac{N}{2}} \\ O_{\frac{N}{2}} & I_{\frac{N}{4}} \otimes U \\ \end{pmatrix}$$ ... 3 If we write$$ U=\sum_{i,j}U_{ij}|i\rangle\langle j|\quad V=\sum_{kl}V_{kl}|k\rangle\langle l|, $$and$$ |x\rangle=\sum_jx_j|j\rangle\quad |y\rangle=\sum_ly_l|l\rangle, $$then we can evaluate both sides of the equation$$ (U\otimes V)(|x\rangle\otimes|y\rangle)=(U|x\rangle)\otimes(V|y\rangle) $$using the definition of the tensor product as$$ U\otimes V=\...

3

I will give you a few elements for the demonstration on real vectors which you can extend to complex. Let {$e_i$} be the standard basis for the space where $U (n*n)$ is defined . Let {$e_j$} be the standard basis for the space where $V (m*m)$ is defined. First, it is a property that the basis {$e_i \otimes e_j$} is a basis for the n*m-matrices space. \$ U \...

3

$$| \psi_3 \rangle = a | 0 1 1 \rangle + b | 1 1 1 \rangle\\$$ Because the 1 on B and C criterion is met. $$| \psi_4 \rangle = a | 0 0 1 \rangle + b | 1 1 1 \rangle\\$$ Because only the first term meets the criterion for the controls so it is the only part affected to flip the B index. $$| \psi_5 \rangle = a | 0 0 0 \rangle + b | 1 1 1 \rangle\\$$ ...

Only top voted, non community-wiki answers of a minimum length are eligible