Questions tagged [quantum-gate]

For questions regarding usage, performance, implementation, application or theory related to quantum gates.

Filter by
Sorted by
Tagged with
3
votes
1answer
53 views

Help Identifying a Gate In Nielsen and Chuang

I am seeking help to identify the oracle gates listed in this example. I understand that the right-most one is a toffoli gate, but what are the other ones? Specifically, I do not understand what a ...
2
votes
1answer
47 views

Phase Kickback and Controlled Operations

I am reading the chapter about phase kickback from "An Introduction to Quantum Computing" by Kaye, Laflamme, Mosca. I understand why $U_f :|x \rangle |-\rangle \rightarrow (-1)^{f(x)} |x\rangle |-\...
1
vote
0answers
23 views

Error in qiskit.aqua.operator

I want to implement this thing: Operator([[3, Pauli([1,0,0], [0,0,0])], [2, Pauli([0,0,0],[0,0,3])]]) But while doing this there is an error in ...
2
votes
2answers
111 views

How to check if a quantum circuit is deterministic?

I'm trying to find a way to check if a given quantum circuit is essentially a classical one (up to changes in phase). Given a description of a quantum circuit by a list (of size $l$) of ordered ...
1
vote
1answer
50 views

A question about quantum circuit simulation on PC

In classical logic circuit consisting of AND, OR and others, common gates can be realized by electrnic signal. Each time cycle can run a function unit like the picture below. Now I have read many ...
1
vote
1answer
37 views

IBM quantum circuit - order of tensor product for equivalent matrix

I'm trying to understand how to apply tensor products on a 3 qbit systems (or well at least 2 qbits). Let's take a basic example: where $$\lvert \psi \rangle = \lvert q2q1q0\rangle $$ with q2 being ...
2
votes
1answer
122 views

How to perform Quantum Process Tomography for three qubit gates?

I am trying to perform Quantum process tomography (QPT) on three qubit quantum gate. But I cannot find any relevant resource to follow and peform the experiment. I have checked Nielsen and Chuang's ...
3
votes
1answer
44 views

Implementing a controlled-controlled-U using controlled-U

Suppose I know how to implement a 2 qubit gate $C-U$ (i.e controlled U), and I want to implement $CC-U$ using $C-U$ and other 1 or 2 qubit gates, is that possible?
1
vote
1answer
55 views

Cheap Toffoli gates with phase errors

Here, a cheap verion of a Toffoli, up to a phase flip for $|101\rangle$, is given by with $A=R_y(\pi/4)$. Are there similar versions of cheap implementation of general $C^nNOT$ gates? I tried to ...
3
votes
2answers
156 views

Controlled-U gate on IBMQ

I want to construct a following 16x16 matrix (system of four qubits) $U=\text{diag}(1,1,...,1,e^{-iV},e^{-iV})$ where $V$ is a constant. So this matrix describe these rotations: $|1110 \rangle \...
3
votes
1answer
65 views

In which type of Hamiltonian does the ansatz need an entangler in VQE?

I would like to prepare an ansatz for VQE. I know UCC ansatz is one of the most useful ansatz, but I would like to reduce the number of CNOT. From the matrix of a given Hamiltonian, can we know the ...
-1
votes
1answer
66 views

What do we mean by “derive full operator of a quantum circuit” and to describe the mapping from input quantum registers to output quantum registers?

There is a quantum circuit with several controlled NOT and controlled swap gates, with two 2-qubit input registers $X$ and $Y$ and two 2-qubit output registers $X'$ and $Y'$ where we have to find the ...
1
vote
1answer
34 views

Show how the Bell state arises from the circuit with Hadamard and CNOT, using matrix notation

I understand that starting with , we can get to $\vert \Phi^+ \rangle$. First, we start with $\vert Q_1 \rangle \otimes \vert Q_2 \rangle = \vert 0 \rangle \otimes \vert 0 \rangle$ and then applying ...
1
vote
1answer
58 views

Any two level flip in $n$ qubit system

Let start with a multi controlled Toffoli gate. Looking at the matrix representation (in the binary base), you easily see $$ \pmatrix{ 1& 0& 0& 0& 0& 0& 0& 0\\ 0& 1&...
2
votes
0answers
34 views

Shifting amplitude from one basis to another with a control qubit

I was reading a forum where people were talking about a proposed quantum algorithm that solves an NP-complete problem in polynomial time. The algorithm appears to have flaws (after all, none of you ...
3
votes
1answer
186 views

Does Controlled-U gate entangle qubits?

I've read C-NOT gate entangles qubits, but is it only for C-NOT or any arbitrary CU gate (apart from the likes if CI) entangles qubits?
3
votes
1answer
51 views

$H = e^{i\pi/4} \sqrt{iNOT}$?

In the paper Valley qubit in Gated MoS$_2$ monolayer quantum dot, a description of how a $NOT$ gate would be performed on a qubit in the described device is given. The authors say that in the ...
1
vote
1answer
72 views

Trying to use matrices for Hadamard and Controlled Not gates

I have the following simple quantum circuit: This outputs are 00 and 11 for the two qubits. Using matrices, I have applied the H gate to the first qubit (ket 0): $\frac{1}{\sqrt{2}}\begin{pmatrix}1&...
2
votes
1answer
48 views

It two unitaries are delta apart in trace norm, then what is the trace norm of outputs states when the same input state is applied to two unitaries?

Suppose we are given two unitary matrices $U$ and $V$, with the following guarantee, $$||U - V||_1 \geqslant \delta$$ for some $\delta \geqslant 0$. We apply an input density state $\rho$ ...
0
votes
2answers
53 views

How to perform operations like sin over Qiskit parameters

I want to create a parameter dependent gate in qiskit and I need to compute some complex operations as sympy.atan2 or sympy.sin ...
2
votes
1answer
40 views

In Google's Quantum Supremacy experiment, what if we use $\theta=45°$ for two-qubit $f_{sim}$ gates?

In Google's Quantum Supremacy experiment, they use $f_{sim}$(fermionic-simulation) gates with $\theta=90°$ and $\phi=30°$ as their two-qubit gates. What if we use $\theta=45°$ for the two-qubit $f_{...
0
votes
2answers
45 views

How to switch bit in the quantum state?

I want to transform binary representation from one to other. Here, I have 2 registers one act as control register and another is target register with the same number of qubits $n$. Consider $n = 3$ ...
0
votes
1answer
110 views

How is data encoded in a quantum neural network?

I am a newbie to quantum machine learning. I am trying to build a quantum neural network (QNN). What I studied so far about QNN is that input would be qubits and hidden layer parameter can be set ...
1
vote
1answer
33 views

Construct a orale for XOR

I am trying to construct an oracle which should accept 10 or 01 (i.e. $|1\rangle$ should be returned for these input). In the below picture the oracle is between the barrier and after the barrier we ...
2
votes
1answer
57 views

Gate corresponding to $-I$

I am implementing a quantum circuit in Qiskit. I create the equal superposition state $$ -|00\rangle + |01\rangle + |10\rangle +|11\rangle $$ but I want to obtain the quantum state $$ |00\rangle - |...
3
votes
1answer
75 views

Rotations to encode $f(x)$ into ancilla qubit for quantum Monte Carlo

I'm trying to understand the quantum monte-carlo algorithm starting at the most basic version. A key step is rotating (Algorithm 1 p.g 8), an ancilla bit by rotation $R$ with respect to the value of a ...
0
votes
1answer
35 views

Creating Bell states (a question from tutorial) [closed]

I was going through a Quantum Computation lecture series on YouTube given by Umesh Vazirani. There in Lecture 6.3 he talks about creating a Bell state using a Hadamard and CNOT gate. He seems to be ...
2
votes
1answer
22 views

S gate vs P gate?

The paper A Fully Fault-Tolerant Representation of Quantum Circuits uses the $P$ gate which is given as: $$P = \begin{bmatrix}1 & 0\\0 & i\\\end{bmatrix}.$$ Nielsen and Chuang Quantum ...
4
votes
3answers
299 views

Quantum circuit to implement matrix exponential

I want to build a circuit which will implement $e^{iAt}$, where $ A= \begin{pmatrix} 1.5 & 0.5\\ 0.5 & 1.5\\ \end{pmatrix} $ and $t= \pi/2 $. We see that $A$ can be written as, $A=1.5I+0.5X$. ...
1
vote
0answers
28 views

Decompose Toffoli gate with minimum cost for IBM quantum computer

The known decomposition of toffoli gate that can be used on IBM quantum computer is : I want to know any other Toffoli gate decompositions that can be used on IBM quantum computer and have a cost ...
0
votes
1answer
43 views

Qubit in a mix sin/cosine state

The question is pretty simple. How can I get an input qubit $|0⟩$ in the state, say $$\cos{\frac{\pi}{10}}|0⟩ + \sin{\frac{\pi}{10}}|1⟩$$ Or any other sine/cosine mix state? Which gates do I need to ...
1
vote
1answer
148 views

Simple algebraic explanation for normalizing states

I'm wondering how a set of three 0-state qubits, each prepared identically, like so: When considered together, may produce the fraction: along with their combined states. This is the entire circuit....
3
votes
1answer
56 views

Error bound on approximating arbitrary rotation gates

I'm working on the following problem form Nielsen and Chuang (Ex. 4.40) regarding the universality of Hadamard, phase and $\pi/8$ gates for single qubit gates: For arbitrary $\alpha$, $\beta$, $E(R_{\...
3
votes
2answers
84 views

What is a local operator?

I have a sort of basic question. I think an operator that acts on $n$-partite states is defined (up to permutation of parties) to be local if it can be written as $$A = A_1 \otimes_{i=2}^n \mathbb{I}...
4
votes
2answers
231 views

How can I fill a unitary knowing only its first column?

I have a unitary matrix that I want to construct. I only care what happens to the first computational state, so the first column is specified. So far, I've been assigning each question mark to a ...
5
votes
1answer
131 views

CNOT gate in ZX-calculus

In ZX-calculus, the CNOT gate is represented by this: Can someone show my why this is true, using just the basic rewriting rules? All books/papers I have seen simply take it without proof, but I can'...
5
votes
0answers
105 views

Physical implementation of gates on IBM Q

There is a lot of quantum gates in IBM Q Composer, however, only few are implemented physically while others can be composed of them. When one looks at description of a quantum processor in IBM Q ...
2
votes
0answers
61 views

How does Quantum Teleportation works? [duplicate]

I've started learning Quantum Computing from the Qiskit Textbook and was able to easily understand or work out everything until it came to the working of Quantum Teleportation I can understand the ...
4
votes
1answer
191 views

How to decompose a multi-target controlled gate?

I'm trying to replicate with qiskit the results of this paper in which basically they implement a quantum version of the Principal Component Analysis applying Quantum Phase Estimation algorithm in ...
1
vote
1answer
43 views

$\sf BQP$ and general $\mathrm{SU}(2^n)$ gates

In his lecture on quantum computing, Scott Aaronson describes polynomial-size quantum circuits, Now, once we fix a universal set (any universal set) of quantum gates, we'll be interested in those ...
3
votes
0answers
42 views

Why are two qubits gates more noisy?

I would like to understand why two qubit gates are generally more noisy. If I am interested in single qubit gates, I can have an effective modelling as a master equation: $$\dot{\rho}=\frac{1}{i \...
2
votes
3answers
52 views

What does the $\sqrt{NOT}$ gate have to do with irreversibility?

In his essay "Why now is the right time to study quantum computing" Aram Harrow writes, after describing the action of the $\sqrt{NOT}$ gate, that: However, if we apply $\sqrt{NOT}$ a second time ...
5
votes
1answer
103 views

Aproximating unitaries with elements from a t-design

(This is basically a reference request) I am wondering if there are any results out there on to what accuracy a given unitary can be approximated with an element drawn from a t-design. To ...
6
votes
2answers
135 views

How to represent an $n$-qubit circuit in matrix form?

If a given quantum circuit has $n$ qubit inputs and a certain number of gates, how can we represent the whole circuit in matrix form? Here's an example: I am sorry, I am confused on how to express ...
3
votes
2answers
355 views

How does the CNOT gate work?

As defined, CNOT should for the two input states $|0\rangle = \pmatrix{1 \\ 0}$ and $\pmatrix{\alpha \\ \beta}$ should result in the second state unchanged: $\pmatrix{\alpha \\ \beta}$. However, to me ...
3
votes
0answers
36 views

What limits speed of quantum gates?

I would like to check something. Consider I am working on cQED (superconducting qubits), or ion trapped, or silicon qubits (I would like to exclude "exotic for me" quantum computing like photon based,...
0
votes
0answers
32 views

State fidelity in Qiskit

Can someone provide me an example for finding state fidelity of two circuits? For example, if I have a Toffoli gate with two different approaches of decomposition then how do I calculate fidelity ...
3
votes
1answer
74 views

General approach for switching control and target qubit

It is well known that circuit can be replaced with this circuit The situation is even easier in case of controlled $\mathrm{Z}$ where gate controlled by $q_0$ and acting on $q_1$ have same matrix as ...
1
vote
1answer
64 views

How do I know in which state the qubit is in each step of the circuit for the simulator in qiskit?

I would like to know how to know in which state a qubit is (I am talking about single-qubit errors), because in order to apply a non unitary gate in the simulator I have to renormalize the state or ...
0
votes
1answer
43 views

Interpretation of CNOT after basis-change

Consider the product of gates acting on two qubits: $$ \begin{pmatrix} 1 & 0 & 0 & 0 \\ 0 & 1 & 0 & 0 \\ 0 & 0 & 0 & 1 \\ 0 & 0 & 1 & 0 \\ \end{pmatrix} ...

1 2
3
4 5
12