Xkappa21
Xkappa21

Reputation: 1

Solve errors in Quantum Computing using Qiskit

I've been studying quantum computing, but I recently found 3 problems that I am not being able to solve, if you could help me it would be a big help.

My first question is does (a),(b) and (c) protect against Y errors or do I have to implement something to protect Y errors? Because if they protect against Y errors shouldn't the result of the circuit the '0': (all the qubits), but in 1024 shots I get the result= '0':756 and '1': 268

I also have this problem but I can't solve it: Using the type Y error correction circuit as a basis, design and implement a circuit to correct generic errors of a qubit.

qc_a = QuantumCircuit(3, 1)
qc_a.ry(np.pi / 3, 0)

qc_a.cx(0, 1)
qc_a.cx(0, 2)

qc_a.s(0)
qc_a.s(1)
qc_a.s(2)


qc_a.cx(0, 1)
qc_a.cx(0, 2)


qc_a.sdg(0)
qc_a.sdg(1)
qc_a.sdg(2)


qc_a.cx(0, 2)
qc_a.cx(0, 1)
qc_a.ccx(1, 2, 0)

qc_a.measure(0, 0)

print(qc_a)

compiled_circuit_a = transpile(qc_a, simulator)
result_a = simulator.run(compiled_circuit_a, shots=total).result()
counts_a = result_a.get_counts()

print(counts_a)

Upvotes: 0

Views: 22

Answers (0)

Related Questions