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)

Filter by
Sorted by
Tagged with
0 votes
1 answer
38 views

Custom gate labels in PennyLane

I have a circuit with Rx gate, and I want to draw it with changed gate label. For example, instead of "RX" I want to have "custom_gate" written in the gate box. I have tried ...
Daniil Tarpanov's user avatar
2 votes
1 answer
148 views

Problem with eigenvalue evaluation algorithm application on matrix $U$

Once I get to the end of the algorithm, I can't understand how to calculate the eigenvalue using formulas. Bear in mind that it is an exercise to be carried out with pen and paper. the matrix of $U$ ...
Francescov20's user avatar
1 vote
0 answers
44 views

Increasing memory usage of simulation of quantum circuits in a "for" loop

I have the following code: ...
stopper's user avatar
  • 373
1 vote
0 answers
11 views

Adding measurement circuits to the singlet state circuit and want to create single circuit

I am trying to add the measurement of Alice and bob's circuit to the singlet circuit. Actually, I am trying to build the e91 protocol. But it is giving me an error like this. ...
Bloodknofsky's user avatar
3 votes
2 answers
125 views

Equivalence of circuits in measurement-based QC

I am looking at Slide 40 from this deck. It is claimed that the circuits 1 to 4 are equivalent. I don't understand the step to go from 2 to 3. How does one backpropagate a measurement in the X basis ...
user1936752's user avatar
  • 2,597
2 votes
1 answer
65 views

Constructing a two 3-qubit state involving either X, Y or Z rotation gate

The goal is to construct the state $|\psi\rangle = \frac{1}{2}|010\rangle + \frac{\sqrt{3}}{2}|101\rangle$ Two issues I am facing: What is a good choice for initial state? What is a good choice for ...
Physkid's user avatar
  • 510
1 vote
2 answers
49 views

creating a generalised Bell state with gates

The Bell state is $$|\beta(a,b)\rangle = \frac{1}{\sqrt{2}}\sum_{k=0}^{1}(-1)^{ka}|k,k \oplus b\rangle\,.$$ How do I get to a general Bell state given an initial state $|ab\rangle$ here $a,b = 0, 1$? ...
Physkid's user avatar
  • 510
3 votes
1 answer
50 views

Role of qubit registers in HHL circuit

I'm trying to figure out how the HHL algorithm works from reading Dervovic's paper and IBM's tutorial. Dervovic shows the following HHL circuit in Fig 5: whereas IBM uses: I want to clarify the IBM ...
Medulla Oblongata's user avatar
2 votes
1 answer
301 views

Is the full quantum circuit always in a pure state?

I'm aware, that if you measure just a subset of a circuit, which is entangled to another subset, it'll be in a mixed state. For example, if you measure q1 in the ...
Eenoku's user avatar
  • 245
0 votes
1 answer
45 views

Random quantum circuits with expectation values not close to 0 for large number of qubits

I'm studying output expectation values of random quantum circuits. These random circuits are built using random gates from a universal set. I have noticed that the distribution of the output ...
stopper's user avatar
  • 373
2 votes
0 answers
34 views

What's a quantum algorithm in the black box model to find $j_1,j_2$ such that $f(x_1,...,x_n)=x_{j1}\oplus x_{j2}$?

Consider the set of all functions $f : \{0, 1\}^n → \{0, 1\}$ that are of the form $f(x_1, x_2, . . . , x_n) = x_{j1}\oplus x_{j2}$ for some distinct $j_1, j_2 \in \{1, 2, . . . , n\}$. Suppose that ...
metaUser's user avatar
1 vote
1 answer
47 views

What does Quantum Circuit Wires and Separated mean?

From Quantum Circuits, there are two statements that are not clear. Quantum Circuits Quantum circuits are collections of quantum gates interconnected by quantum wires. The actual structure of a ...
Moo's user avatar
  • 153
1 vote
1 answer
78 views

How to interpret the circuit that measures stabilizers in the 5-qubit error correcting code

I would like to understand the exact role of the following circuit (By Vtomole - Own work, CC BY-SA 4.0) in the 5-qubit QECC. The image attached (from Wikipedia) is captioned "Quantum Circuit ...
QC123_367's user avatar
  • 295
1 vote
0 answers
54 views

Implementing $n$-bit Toffoli gate with $(2n-5)$ and $(4n-12)$ CCNOT gates

Papers such as Diao et al. "A Quantum Circuit Design for Grover’s Algorithm" implement an $n-1$ bit Toffoli gate with $2n-7$ gates and $n-3$ scratch bits. I want to know if there is a way to ...
requiemman's user avatar
1 vote
1 answer
59 views

How to interpret the encoding circuit for the 5-qubit QECC

I have a question on circuit which constitutes the sydnrome measurement for the 5-qubit error correcting code. If I focus on just a portion of the circuit: Reference for image. The full circuit can ...
QC123_367's user avatar
  • 295
1 vote
0 answers
35 views

Classical Fisher Information for 1-qubit vs 2-qubit in PennyLane

I'm attempting to examine the Classical Fisher Information (CFI) for a 1-qubit system in comparison to a 2-qubit system.(PennyLane) I anticipated that the CFI for the 2-qubit system would be double(at ...
Donguk kim's user avatar
2 votes
0 answers
135 views

How to build the quantum circuit ansatz to implement a diagonal unitary operator with just 1 and -1 elements?

Let's consider a set of $N = 2^n$ binary values $S_i \in \left\{-1, 1\right\}$ and define the diagonal matrix $W$ as a quantum unitary operator acting on a system of $n$ qubits: $$ W = \begin{pmatrix} ...
SimoneGasperini's user avatar
2 votes
1 answer
83 views

Can we create a W state of n qubits with constant circuit depth using mid circuit measurements?

I saw this post where the GHZ state with many qubits (here 6) can be made by performing some mid circuit measurements in constant circuit depth: Depth circuit optimization for 6-qubits GHZ state I was ...
ty.'s user avatar
  • 133
1 vote
0 answers
37 views

constructing $6$ GHZ-like states from the GHZ state

In a $3$ - qubit system, the $GHZ_{3}$ - state can be constructed in the following manner: $|\psi \rangle _{1} = (H \otimes I \otimes I)(|0\rangle \otimes |0\rangle \otimes |0\rangle) = |+\rangle \...
Physkid's user avatar
  • 510
1 vote
1 answer
72 views

Verifying CNOT on different qubits of a 3 - qubit system yields this measurement state

Below is a circuit involving two CNOT unitary gates that yields a post - measurement state $|a, b, a \oplus b \rangle$. I am struggling to convince myself this is true. Let $|a\rangle, |b\rangle$ be ...
Physkid's user avatar
  • 510
3 votes
1 answer
74 views

How to apply rotation about X and Z in stim?

I have a quantum circuit illustrated in the provided image, where I perform a series of quantum operations followed by a projective measurement.. Using Qiskit, I've already written the code for this ...
Manna's user avatar
  • 31
2 votes
1 answer
65 views

Quantum circuit implementation of shift operator in quantum walk

I'm considering discrete-time quantum walk on $2\times2$ grid with periodic quantum walk. In particular focus on shift operator which has the form : \begin{equation} S|i,j\rangle \otimes |x,y\...
Young Kindaichi's user avatar
2 votes
1 answer
107 views

AerError: 'unknown instruction: c-unitary' while using control unitary operator

I'm using the following code : ...
Young Kindaichi's user avatar
1 vote
1 answer
53 views

What is the unitary matrix for this two qubit circuit with $H$ and $I$?

Above is a circuit I am provided. I am asked to write down the matrix representation of a $4 \times 4$ matrix representation of a unitary matrix for this circuit. Using small endian notation (left to ...
Physkid's user avatar
  • 510
2 votes
1 answer
147 views

Why is this modular adder so complicated?

I'm trying to construct a controlled modular multiplication circuit and a subcomponent is a modular adder. However, it appears the basic Draper/Fourier adder is already modular. Shouldn't adding $N=2^...
Jackson Walters's user avatar
1 vote
1 answer
79 views

Compute the output of a quantum circuit with classically controlled operations

Consider the following circuit : where $|\psi\rangle$ is a qubit in $\mathbb{C}^2$, $|0\rangle= \begin{pmatrix}1 \\ 0 \end{pmatrix}$, $T= \begin{pmatrix}1 & 0\\ 0 & e^{i\pi/4} \end{pmatrix}$ ...
NotaChoice's user avatar
1 vote
0 answers
28 views

An unexpected result of the Implementation of a finding minimum values algorithm using a qRAM

Motivated by the article Quantum algorithm for finding minimum values in a Quantum Random Access Memory, I'm training to implement a simplified version of the proposed algorithm. But the output isn't ...
j__j's user avatar
  • 11
0 votes
2 answers
76 views

Help debugging implementation of Draper QFT adder

I am attempting to implement the adder found in this paper. Here is the code: ...
Jackson Walters's user avatar
1 vote
1 answer
98 views

Simplifying quantum circuits

I am very new to quantum circuits and am unsure how to simplify them. Say I'm given a very simple circuit: and I want to simplify it using basic quantum gates. I'm not looking for an answer, but more ...
Spike Spiegel's user avatar
3 votes
1 answer
155 views

4 qubit QFT decomposition in the qiskit textbook

I am reading about the quantum Fourier transform (QFT) in the qiskit textbook, but got stuck at the last part of it which shows a decomposed version of the 4 qubit QFT circuit. It seems that the ...
pilsungk's user avatar
1 vote
0 answers
29 views

Can the optimal synthesis of a parity matrix generate complex combinations of CXs?

Consider the method described in Optimal Synthesis of Linear Reversible Circuits. I am led to think that, for any parity matrix given in input to such a method, the output would be a sequence of CX ...
Daniele Cuomo's user avatar
1 vote
0 answers
57 views

MissingOptionalLibraryError: "The 'pdflatex' library is required to use 'LaTeX circuit drawing' [closed]

Trying to run the below code block in a jupyter notebook in Windows 10: ...
ulbgo lee's user avatar
3 votes
0 answers
76 views

Complexity of the quantum circuits that are needed to implement communication protocol?

Consider the following simultaneous communication problem. Alice and Bob do not share any entanglement or any common randomness, and cannot communicate directly with each other. As inputs, x is given ...
Ruben Hoba's user avatar
2 votes
0 answers
37 views

Error in repeated applications of a quantum channel?

Suppose I have two quantum channels. Assume they they consist of $r\in \mathbb{Z}$ applications of unitaries, $U$ and $V$ respectively. Let the error between the channels acting on some state $\rho$ ...
Hans Schmuber's user avatar
1 vote
1 answer
74 views

How to implement non-unitary operator in qiskit?

I am trying to make a operator for S-Box for AES. The matrix is non-unitary. When I use Operator command for declaring it as a function. It gives error, the matrix is non-unitary. Thus, the qiskit ...
Syed Shahmir Kazmi's user avatar
2 votes
1 answer
82 views

Quantum circuits, quantum Turing machine and universal quantum computer-comparing different models of quantum computations

Forgive me if this question was already asked somewhere on this site-I haven't found it but it is possible that I've overlooked it. So basically, I would like to summarize different notions of quantum ...
truebaran's user avatar
  • 133
1 vote
0 answers
28 views

Optimizing Selection of the Optimal Qubit in a 30-Qubit Quantum Circuit

I am working with a quantum circuit consisting of 30 qubits, and for each qubit, I have allocated a dedicated classical register to record individual measurement results. When I execute this circuit ...
Alaa eddine's user avatar
2 votes
1 answer
43 views

Computing the evolution of expectation values of the Pauli observable

I have a quantum state described by $N$ qubits, and I don't know anything about this quantum state except the expectation value of the single-qubit Pauli observables of the $i$-th qubit ($\langle X_i \...
stopper's user avatar
  • 373
0 votes
1 answer
111 views

How do I prove these gate identities?

How do I approach on solving the below two problems?
sriram Usc's user avatar
0 votes
2 answers
93 views

Conditional quantum circuits

Let's suppose that we have the following $\text{GHZ}$-state $$|\psi\rangle = \frac{1}{\sqrt{2}}|a_1a_2a_3a_4\rangle + \frac{1}{\sqrt{2}}|b_1b_2b_3b_4\rangle$$ By using quantum gates, can we evaluate $...
user avatar
3 votes
0 answers
44 views

Understanding circuit to Hamiltonian embedding where we do not have a separate clock register

I am trying to understand the clock construction given in this paper, to embed a circuit to a Hamiltonian, which doesn't need to access a separate clock register. The construction, at a high level, ...
BlackHat18's user avatar
  • 1,251
0 votes
0 answers
41 views

Quantum Crosstalk in gate scheduling with different gates

I am working on quantum crosstalk, specifically on CNOT and SWAP gate operations that lead to crosstalk. I have encountered works that decompose CNOT and SWAP with iSWAP and CZ gates. I would like to ...
Indu's user avatar
  • 9
1 vote
2 answers
128 views

How to design a circuit which produces the state $|\psi\rangle = \frac{1}{2}|{010}\rangle + \frac{\sqrt{3}}{2} |{101}\rangle$?

The quantum state to achieve is: $$ |{\psi}\rangle= \frac{1}{2}|{010}\rangle + \frac{\sqrt{3}}{2} |{101}\rangle $$ So far I know how to produce the $$\frac{1}{2}|{010}\rangle$$ state in qiskit as ...
Bob's user avatar
  • 11
3 votes
1 answer
211 views

Output of my quantum circuit to create 3-qubit GHZ-like state does not make sense mathematically

I want to create the GHZ-like state, $|\Psi\rangle = \frac{1}{\sqrt{2}} \left(|011\rangle - |100 \rangle \right)$. I build my circuit in the following way. apply the x gate to the first and third ...
molan li's user avatar
1 vote
1 answer
93 views

If Statement OpenQasm 2.0

in the documentation for OpenQasm 2.0 it says one can use an if statement like so: if(c_reg==int) Quantum Operation. However, I would like to execute the following: ...
Sam's user avatar
  • 31
0 votes
0 answers
29 views

How to account for a partial derivative term in an Operator, in Qiskit?

The crystal momentum p1 = h bar * k and this is defined in the reciprocal momentum, I am guessing this p1 is not a real momentum since the reciprocal space is an imaginary space which we use for ...
Jessica John Britto's user avatar
1 vote
0 answers
14 views

How to get rid of the indices of qubits at the side of a custom gate when visualizing a circuit (IBM Qiskit)

I have written a function that applies the Hadamard gate to all qubits in a circuit, and use the draw() function to visualize the circuit. However, there is this ...
John Levi's user avatar
1 vote
2 answers
142 views

Can any Qiskit circuit be converted to a gate?

I am trying to convert the following qiskit QuantumCircuit to a gate using to_gate() method. ...
squareroottwo's user avatar
1 vote
1 answer
106 views

Number of qubits in quantum circuits in ibm qiskit

How to find number of Qubits ? ...
Khilesh Chauhan's user avatar
0 votes
1 answer
70 views

"Mismatch between run_config.parameter_binds and all circuit parameters" when executing qiskit circuit

...
shc's user avatar
  • 15

1
2 3 4 5
10