# Questions tagged [quantum-circuit]

a model in which a computation is a sequence of quantum gates, which are reversible transformations on an n-qubit register (the quantum-mechanical analog of an n-bit register)

313 questions
Filter by
Sorted by
Tagged with
1 vote
47 views

### pennylane: How to carry out MB rotation without CB rotation?

I'm looking at this MBQC tutorial where there's an example that shows that a MB and CB single qubit rotations give the same result. CB version : ...
• 1,435
62 views

### Conditions for Fault-tolerant QC to work better than not doing any EC (except the ideal decoder)

I've been exploring fault-tolerant QC with the simplest 7-qubit Steane code, yes I'm able to obtain all the predicted thresholds for various transversal gates and the EC gadgets. I then tried to ...
1 vote
54 views

### Classical register implementation in Amazon Braket

How to implement classical register in a quantum circuit in Amazon Braket ? I am trying to preproduce results of a circuit build in qiskit on AWS braket services. Thanks
• 11
67 views

### Classes of quantum circuits that can be "efficiently" simulated

Which kind of quantum circuits can be simulated with classical algorithms in a reasonable amount of time (for a large number of qubits)? For example the ones with only Clifford gates. Or the ones with ...
• 341
64 views

### Why is error correction very different for circuits compared to channels?

Background Suppose one wishes to communicate information using a noisy channel $N$ instead of an ideal channel $I$. The general framework to communicate reliably is Take $n$ copies of $N$. For some ...
• 2,383
73 views

### Is it possible to implement any random Hamiltonian using quantum circuit

Are there any restrictions on implementing the evolution of any random Hamiltonian? Suppose I want to implement Rabi oscillations using a quantum circuit, I initialize the state and the Hamiltonian ...
40 views

### Applying horizontal dots in a LaTeX Quantum Circuit diagram [closed]

I am almost done with my circuit diagram for the QAOA circuit but the \cdots does not want to cooperate. As seen there exists some wire drawn across the dots from the gate to the right and I can't ...
1 vote
102 views

### How to repeat the same Qiskit instruction $N$ times (no for loop)?

I need to build the following 1-qubit QuantumCircuit in Qiskit, repeating the pair ($X$ gate, barrier) for $N$ times: The most straightforward way to do this is by ...
47 views

### how to flatten a cirq.Circuit with CircuitOperation

I have a cirq.Circuit that uses a CircuitOperation, something like: ...
• 325
1 vote
47 views

### Does the Bell's state entanglement violate the reversibility property of unitary matrices?

I read unitary matrices are reversible, so when we apply a unitary operator $U$ on some input state and got an output state, then if we apply $U^\dagger$ (transpose conjugate) we get back the original ...
1 vote
55 views

### Commutativity of XY gate

My question is a simple one: Can 2 XY gates commute ? XY gate is a 2-qubit XX+YY interaction also sometimes referred to as iSwap gate.
91 views

### How to translate a 4-qubit Grover's algorithm circuit into a state Matrix?

Grover's algorithm circuit may be implemented as follows: (from here) It is shown very elegantly by @MartinVesely (How to interpret a 4 qubit quantum circuit as a matrix?) how to translate a 4 qubit ...
• 191
1 vote
45 views

### qiskit.algorithms.optimizers callback function for all optimizers

I am aware that VQE and VQC factory supports callback functions which can allow us to store intermediate values during optimization through callbacks in its arguments. However my loss function is ...
1 vote
51 views

### IBM composer deletes my circuit

When I work on the IBM quantum composer and I switch to another circuit, my first circuit is destroyed and replaced by the second one. I thought it was a display bug, but when I restart the composer, ...
• 23
66 views

### Difference between IBM simulator backends

I'm an Msc student working on a quantum information project (VQEs on 4 qubits). Our group is looking at different IBM simulators on the IBM platform, and have noticed that performance is different for ...
• 41
88 views

### Simulation files for noisy quantum circuits

For our study with Yosi Rinott and Tomer Shoham we need the following simple data: Starting with a quantum circuit $C$ on $n$ qubits we need two files: a) A file of probabilities (or amplitudes) for ...
• 201
1 vote
40 views

### Is a quantum circuit without measurements, a unitary operator?

Is it true that the whole circuit, viewed as a map from the input registers to the end is a unitary operator ?
1 vote
32 views

### Alternative Versions of Quantum Fourier Transform (Decimation in Time/Frequency)

Is there a good comparison of alternative versions of the Quantum Fourier Transform (QFT) that mirror the alternative decimation-in-time or decimation in frequency versions for the conventional Fast ...
28 views

### Bound on scaling mixed quantum-classical computer designs

I am familiar with some basics of quantum computation and this makes me wonder, are there any upper bounds known on the size of a quantum circuit, such that quantum circuit + some classical circuit, ...
• 101
1 vote
85 views

### Conversion error: from a QISKIT circuit to a QASM string and back

I created a circuit in qiskit and then converted it into a QASM string. When I try to make a circuit out of the QASM string I get the error: ...
• 1,748
1 vote
31 views

### How to apply CNOT with control qubits in first register and target qubit in second register

I would like to know how to mathematically describe the states of the qubits in both registers in the following circuit:
• 37
40 views

### Survival probability quantum circuit

Suppose say that I have a quantum state $\vert\psi\rangle$ at time $t = 0$, which is now evolved by a hamiltonian $H$ $$e^{-iHt}\vert\psi\rangle$$. I can ask the question, how much of initial state is ...
243 views

### What is a gate-level circuit used in the 2022 Jafferis et al. experiment on Sycamore?

A recently published Nature paper of Jafferis et al. describes an experiment with a handful of qubits performed on Google's Sycamore processor to explore the SYK model in the context of AdS/CFT and ...
• 8,477
56 views

### How do I bound parameters in RawFeatureVector with ParameterizedInitialize in Qiskit?

I'm not sure how to bind the parameters in the Qiskit RawFeatureVector circuit. Here is my code: ...
1 vote
68 views

### What does circuit-xxx accomplish after circuit gets decomposed by qiskit?

as mentioned in the title, i have a problem with the qiskit decompose function. ...
• 97
30 views

### How to implement this circuit either using Jupiter notbook or qiskit

I am new to quantum-computaions and learning qiskit. I am trying to construct a two qubits circuit that performs a bell measurement using $\{|\beta_{01}\rangle \langle \beta_{01}| \}$ projectors. ...
1 vote
32 views

### How to create Parametrized Operator

How to transform the U3 gate of parameters (theta, phi, lambda) to an Operator. (in qiskit) The following code don't work ...
57 views

### problem with parametrized circuits

I used a circuit with one parametrized gate U(theta, phi, lambda), than I fixed the parameters with qc.bind_parameters and it's worked well. But the only step that don't work is the execution in a ...
1 vote
56 views

### Label Qubit Starting State in Qiskit

$\def \ket#1{|#1\rangle} \def \bra#1{\langle#1|}$Is there a way to set qubits to be a specific value outside of resetting them like so? I understand that all qubits are initialized to the $\ket 0$ ...
1 vote
84 views

### Draw Circuit with 'latex' with to_gate involved

The circuit draw command doesn't work when there is a custom gate as follows: ...
1 vote
35 views

### Use state vector simulator with TensorCircuit

Is there a option to use instead of tensor network contraction state vector simulator for quantum circuits? This might be useful for small sized circuits, but I would still like to use TensorCircuit s....
63 views

### How to create superposition of all bitstrings with exactly two ones on 4 qubits?

On a quantum circuit, how would I create an equal superposition of the states: $$|\psi\rangle=|0011\rangle + |0101\rangle + |0110\rangle + |1001\rangle + |1010\rangle + |1100\rangle.$$
51 views

### Quantum In-place Modular Addition Circuit

Can anyone explain this in-place modular addition circuit from the paper "Quantum Resource Estimates for Computing Elliptic Curve Discrete Logarithms" by Martin Roetteler et. al (https://...
1 vote
49 views

### Vanishing expectation value $|\langle Z_1Z_2...Z_N \rangle|$

I'm doing a research involving expectation values of different observables. I've observed that, given a random Quantum Circuit $U$ with $N$ qubits acting on an inital state $|0\rangle$ in such a way ...
• 341
75 views

### How to calculate a matrix difference in a quantum circuit in the form $A - BAB$

In quantum circuits, every gate is a unitary, and these gates get multiplied together. For example, a simple circuit that performs $X$ on the least significant qubit (i.e., $I \otimes X$), and $CNOT$ ...
1 vote
69 views

### How to interface stim to a generic qiskit decoder?

I can generate encoder/decoder circuits for arbitrary QECC in qiskit. I tested a number of codes : $[[5,1,3]], [[7,1,3]],[[8,3,3]],\cdots$ and everything seems to work fine. The problem is that the ...
• 1,435
1 vote
41 views

### Plot circuit within TensorCircuit

Given an arbitrary TensorCircuit, is there a convient way to get a plot of the circuit?
35 views

### Method to use nonlinear operators within quantum circuits

I recently learned of a technique known as "block-encoding" which embeds any $M \times N$ matrix into a unitary matrix, given that the spectral norm is at most $1$. This type of result is ...
1 vote
43 views

### How $X\otimes X^{1/2}$ propagates through $CZ$

I am trying to find out how the $X\otimes X^{1/2}$ operator propagates through a $CZ$ one. Below a circuit example.
• 1,106
47 views

### How to use more than 3 classical registers in a single quantum circuit in Qiskit without getting error: not enough memory slots?

I'm trying to run a quantum circuit on qasm simulator which has more than 3 classical registers. It gives error when I try to execute it. The circuit looks ...
• 53
49 views

### gradient estimations on variational quantum algorithms

Other than the two famous parameter-shift rule and finite difference method, is there any other (perhaps simple) methods to estimate gradients of a cost function in variational quantum algorithms?
• 391
1 vote
72 views

### Is there a way to decompose a quantum circuit into layers?

For example, if take the following circuit as the input (either QASM or Qiskit): ...
• 33
1 vote
43 views

### Is there any shortcut to create a controlled gate or any technique?

I was solving Controlled H gate from qiskit textbook -> Basic Circuit Identities There I tried to find the unitary matrix for CH gate but it get's really complicated when I use tensor product or ...
• 123
58 views

### How $X$ noise propagates through controlled-$S$ gate

I am struggling to find how an $X$ noise propagates through a controlled-$S$ gate. Here`s the circuit.
• 1,106
52 views

### How to use stabilizers to simulate the circuit?

Sorry for this easy questions. That is a simple textbook question but I don't know how to solve it. I have the following circuit: The question was "use stabilizers to simulate the circuit" ...
• 544
60 views

### How can we represent a CNOT gate using a cascade of rotation gates?

I have been working using qiskit to implement the CNOT decomposition into a cascade of rotation gates from this source. After computing the unitary matrix, the resultant matrix is not the same as the ...
9 views

### Size of output and post selection registers

Let $\mathcal{A} =\{\mathsf{Q}_n\}$ be a quantum circuit, taking $n$ input qubits to $n$ output qubits. It is known that \begin{equation} \mathsf{Post}\mathcal{A} = \mathsf{Post}\mathsf{BQP}, \end{...
• 315
1 vote
38 views

### ModuleNotFoundError when running Qiskit RNG

I'm trying to generate random numbers using IBMQ backends with the following code: ...
1 vote
Let a simple quantum circuit consist of one qubit and one classical bit. Initially, a qubit has the $|0\rangle$-state and then goes through some sequence of quantum gates, see the circuit below. The ...