Questions tagged [quantum-computing]

Quantum Computation deals with considering computation as fundamentally physical, as well as replacing the classical binary digit (bit) with the quantum binary digit (qubit). While the classical bit is either 0 or 1, the qubit can be in a superposition of these states. Computation systems that use quantum phenomena, such as superposition and entanglement, can solve certain complex problems very quickly.

Related Links

Quantum Computing on Wikipedia

(Textbook) Quantum Computation and Quantum Information: The de-facto standard textbook for learning about quantum computing.

(Video Series) Quantum computing for the determined: Khan-academy-style videos explaining quantum computation, by Michael Nielson (co-author of Quantum Computation and Quantum Information).

Quantum Computing Q&A site on the Stack Exchange network.

369 questions
2
votes
1 answer

qiskit VQC with Amplitude Encoding for state preparation

I am trying to implement a Quantum Neural Network in qiskit, using the VQC class. The problem is that each data consists in 190 features, which just can't be encoded with the default VQC's function (ZZfeatureMap), since this would mean create a…
Fred Derf
  • 45
  • 5
2
votes
0 answers

Using qutip.mesolve() to calculate the time evolved Hamiltonian with time dependent variable

I'm trying to find the time evolution of some initial state with a time dependent hailtonian where also the z variable (gradient of time evolution) is time dependent. Usually the qutip.mesolve() function can be used for this when the z variable is a…
2
votes
1 answer

How is data encoded in an oracle on a quantum circuit?

I'm specifically looking at implementing Durr, Hoyer, A Quantum Algorithm for Finding the Minimum in qiskit, finding the index with the smallest value in a list using grover's algorithm. Say you have a list L, [1, 4, 0, 2] for example, and an oracle…
phildo
  • 21
  • 1
2
votes
1 answer

Set random seed for cirq functions

I am working with cirq and use a random unitary for testing purposes with: random_matrix = cirq.testing.random_unitary(dim=4) where can can the random seed for this function be set, using random.seed(a=1) does not seem to do this.
Marsh
  • 41
  • 6
2
votes
0 answers

Why do the constant operations in a quantum computer need second qbits?

From what I'm reading, building the constant-1 and constant-0 operations in a quantum computer involves building something like this, where there's two qbits being used. Why do we need two? The bottom qbit in both examples is not being used at all,…
MysteriousWaffle
  • 439
  • 1
  • 5
  • 16
2
votes
1 answer

Qutip Raise Warning When Specify Bra Directly From Numpy Array Transpose

I try to define a bra of a ket using qutip. A bra is a row vector and a ket is a column vector. A bra can be defined as a ket conjugate transpose. However, if I specify a bra directly using this definition in qutip a warning always raised, and the…
Willy satrio nugroho
  • 908
  • 1
  • 16
  • 27
2
votes
1 answer

Q# unit testing to check phase

I want to test a phase oracle by testing if the phase of qubit flipped. I tried to do it by AssertQubitIsInStateWithinTolerance((Complex(0., 0.), Complex(-1., 0.)), qubit, 1e-5); But it doesn't really check the phase because the same input also…
Tomer Shinar
  • 415
  • 3
  • 13
2
votes
1 answer

Unexpected keyword argument 'datatime' qiskit provider

I'm trying to set datatime calling backend.properties qiskit. this is my code : from qiskit import * from qiskit.providers.ibmq import * provider = IBMQ.get_provider(hub='ibm-q') provider.backends(simulator=False) backend =…
2
votes
1 answer

CNOT quantum gate on python with numpy

First of all i apologyse for any error i have, english is not my native lenguage. Ok so i must implement quantum teleportation in python without using any quantum library, just with linear algebra, i already implement a way to get Hadamard and…
Lord Blue
  • 21
  • 2
2
votes
1 answer

How do I implement a controlled Rx in Cirq/Tensorflow Quantum?

I am trying to implement a controlled rotation gate in Cirq/Tensorflow Quantum. The readthedocs.io at https://cirq.readthedocs.io/en/stable/gates.html states: "Gates can be converted to a controlled version by using Gate.controlled(). In general,…
Thomas Hubregtsen
  • 449
  • 1
  • 5
  • 22
2
votes
3 answers

Implement quantum teleportation in qiskit

I am trying to implement the quantum teleportation protocol from the qiskit textbook in qiskit: I start with q_0 bit = 1 and I expect that q_3 = 1 at the end but it does not work. from qiskit import * qc = QuantumCircuit(3, 3) qc.x(0) #q ->…
Felix Ha
  • 401
  • 5
  • 11
2
votes
0 answers

Quantum amplitude encoding

I would like to perform the Quantum Fourier Transform (QFT) of a sequence of, say, 8 elements. I have then the problem of encoding the sequence of 8 elements into 3 qubits. My question is how performing this task with Qiskit. I would say that one…
Vitality
  • 20,705
  • 4
  • 108
  • 146
2
votes
2 answers

OR gate implementation using Toffoli gate

Can an OR gate be implemented using not more than 2 Toffoli gates? I have already implemented it using 3 Toffoli gates but couldn't find any way to implement it using 2 Toffoli gates.
2
votes
1 answer

Quantum Fourier Transformation product representation

I have problems understanding the following step in Nielsen's and Chuang's Quantum Computation and Quantum Information (page 218, equations 5.9 and 5.10): Could someone help me please to understand this step? I tried to do it on an example n=3 and…
DianaPrince
  • 101
  • 5
2
votes
1 answer

What does the function state_fidelity() do in Qiskit?

I am trying to solve a system of linear equation using HHL algorithm in Qiskit. I have a problem with understanding the purpose of the following function. state_fidelity() To understand this I have followed their official documentation. But it is…
Protik Nag
  • 511
  • 5
  • 20