PreprintPDF Available

Demonstration of a general fault-tolerant quantum error detection code for (2n+1)-qubit entangled state on IBM 16-qubit quantum computer

Authors:
Preprints and early-stage research may not have been peer reviewed yet.

Abstract and Figures

Quantum error detection has always been a fundamental challenge in a fault-tolerant quantum computer. Hence, it is of immense importance to detect and deal with arbitrary errors to efficiently perform quantum computation. Several error detection codes have been proposed and realized for lower number of qubit systems. Here we present an error detection code for a (2n+1)-qubit entangled state using two syndrome qubits and simulate it on IBM's 16-qubit quantum computer for a 13-qubit entangled system. The code is able to detect an arbitrary quantum error in any one of the first 2n qubits of the (2n+1)-qubit entangled state and detects any bit-flip error on the last qubit of the (2n+1)-qubit entangled state via measurements on a pair of ancillary error syndrome qubits. The protocol presented here paves the way for designing error detection codes for the general higher number of entangled qubit systems.
Content may be subject to copyright.
Demonstration of a general fault-tolerant quantum error detection code for
(2n+ 1)-qubit entangled state on IBM 16-qubit quantum computer
Ranveer Kumar Singh,1, Bishvanwesha Panda,2, Bikash K. Behera,3, and Prasanta K. Panigrahi3, §
1Department of Mathematics,
Indian Institute of Science Education and Research Bhopal, Bhauri 462066, Madhya Pradesh, India
2Indian Institute of Science Education and Research Kolkata,
Mohanpur 741246, West Bengal, India
3Department of Physical Sciences,
Indian Institute of Science Education and Research Kolkata, Mohanpur 741246, West Bengal, India
Quantum error detection has always been a fundamental challenge in a fault-tolerant quantum
computer. Hence, it is of immense importance to detect and deal with arbitrary errors to efficiently
perform quantum computation. Several error detection codes have been proposed and realized
for lower number of qubit systems. Here we present an error detection code for a (2n+ 1)-qubit
entangled state using two syndrome qubits and simulate it on IBM’s 16-qubit quantum computer
for a 13-qubit entangled system. The code is able to detect an arbitrary quantum error in any one
of the first 2nqubits of the (2n+ 1)-qubit entangled state and detects any bit-flip error on the last
qubit of the (2n+ 1)-qubit entangled state via measurements on a pair of ancillary error syndrome
qubits. The protocol presented here paves the way for designing error detection codes for the general
higher number of entangled qubit systems.
I. INTRODUCTION
Quantum errors are the inevitable obstacles for realis-
ing a fault-tolerant quantum computer13. Quantum sys-
tems show much more pronounced noise effects on them
through quantum errors. While classical computers are
only affected by bit-flip errors, quantum computers ex-
hibit mainly three types of errors such as bit-flip, phase-
flip and arbitrary phase-change error4,5. Thus fault tol-
erant quantum computation projects a daunting task to
accomplish. In order to run quantum algorithms with
large time complexity, improvement needs to be done us-
ing quantum error correction protocols6,7and fault tol-
erant schemes8,9. Several experiments have already been
performed to demonstrate the usefulness of quantum er-
ror correcting codes to protect a quantum memory10. To
implement an error correction code, detection of error
is needed, hence becoming an important part of error
correction scheme. Several error detection as well as cor-
rection codes have been proposed1118. The pioneering
work on error detection as well as correction had been
started by Shor19 and Steane2022. Since then quantum
error detection and error correction have been a subject
of intense study.
Recently Corcoles et al.23 proposed a quantum error
detection code for one of the Bell state using two an-
cillary syndrome qubits and demonstrated it experimen-
tally using a square lattice structure of four supercon-
ducting qubits. In the proposed error detection code,
they used a two-by-two lattice structure i.e. the square
lattice of superconducting qubits. They verify the non-
demolition nature of the protocol by demonstrating the
preservation of entangled state through high fidelity syn-
drome measurements in the presence of an arbitrary ap-
plied error.
The surface code (SC)24,25 has emerged as a promis-
ing candidate for quantum computers based on super-
conducting qubits due to its nearest-neighbour qubit in-
teraction and high fault-tolerant error thresholds8. In
recent times, superconducting qubits have become po-
tential candidates for the realisation of SC26,27 with con-
tinuous improvement in coherence times2830 and quan-
tum errors31. A highly efficient new quantum computer
has been developed by IBM which uses superconducting
transmoson based qubits for computing. IBM quantum
computer has become a completely new candidate for the
implementation of SC. Qubits of the IBM quantum com-
puters are placed at the vertices of a two dimensional
array. A lot of work is being done by researchers using
IBM quantum computers.
Recently Debjit et al.5experimentally realised an er-
ror correction code for Bell state and GHZ state on IBM
5-qubit quantum computer and generalised it to n-qubit
case. IBM quantum experience from its inception has
gained a lot of popularity in the research community
since the cloud based access provided by IBM has been
used to accomplish various tasks3252. Thus testing and
implementing error detection codes using IBM quantum
computers opens up new horizons of research. It has
been shown that error detection is very useful on IBM
5Q chips53. Error detection and correction remains a
challenging problem for arbitrary entangled states with
large number of qubits. Although several error detection
codes have made good amount of progress in the pursuit
but still much progress needs to be made.
We take the study a step forward and propose an er-
ror detecting code for a (2n+ 1)-qubit entangled state
prepared from a 2n-qubit entangled state possessing a
kind of “complementarity” property which will be ex-
plained in detail in the next Section. Simply, an entan-
gled state has the complementarity property if for ev-
ery term appearing in the state there is another term
in the state complimentary to the it, where the com-
2
plimentary state is obtained by a modular sum with 1
to each of the qubit. For exmaple |11101iis the com-
plementary state to |00010i. The entangled states with
this complementarity property are general and cover the
maximally entangled state Bell states and all the gen-
eralized GHZ states. The proposed protocol is useful
as it can be used to detect errors in generalised GHZ
states with even number of qubits and all Bell states
which are used in many quantum algorithms as quan-
tum teleportation54 , quantum cryptography55, quantum
key distribution56, quantum secret sharing57, superdense
coding58 etc. In our protocol we first take any 2n-qubit
entangled state with complementarity property and add
another qubit to the state using CN OT operations as
the result of which we get a (2n+ 1)-qubit entangled
state depending on the terms in the state of the 2n-qubit
state taken. We then add two error syndrome qubits
to the state prepared above in a way that they remain
in a product state. Then measurement is performed on
the syndrome qubits and depending on the result of the
measurement, we conclude the type of error present in
the (2n+ 1)-qubit entangled state. Our protocol detects
any arbitrary single-qubit phase-change error or bit-flip
or phase-flip error on any of the 2nqubits and detects
only bit-flip error in the last qubit of the (2n+ 1)-qubit
state. To demonstrate the usefulness of the protocol we
perform a simulation with a 13-qubit entangled state on
the IBM 16-qubit quantum computer and compare the
results for various types of errors. We implement the er-
rors on the qubits using different gates provided by IBM
quantum experience. We design the quantum circuit us-
ing QASM language and simulate it using QISKit.
II. RESULTS
Our circuit consists of a entangled state of (2n+ 1)
number of qubits and two syndrome qubits. We
first prepare a 2nqubit entangled state of a
special form as outlined here. Consider the set
An={|a1a2. . . a2ni;ai= 0,1i= 1,2, . . . 2n , n N}
of state vectors, where the first number in the ket repre-
sents the first qubit, the second number represents the
second qubit and so on. Let Bnbe a nonempty proper
subset of Anwith the property that if |a1a2. . . a2ni ∈ Bn
then |(a11)(a21) . . . (a2n1)i ∈ Bn. For brevity,
we call the ket
|(a11)(a21) . . . (a2n1)icomplementary to
|a1a2. . . a2ni ∈ B. Now consider the sum
|ψi=1
p|AnBn|"X
|a1a2...a2ni∈AnBn
± |a1a2. . . a2ni ±
|(a11)(a21) . . . (a2n1)i#
(1)
Measurement result Type of error
|00iNo error
|10iBit-flip in any one qubit.
|01iPhase-flip in any one qubit.
|11iBit-flip and phase-flip in any one qubit.
TABLE I. Measurement results of syndrome qubits
and type of errors
where is sum modulo 2 and |AnBn|is the cardinality
of the set AnBn. We call such states as states with
“complementarity” property. Any repetitions in the sum
is discarded so that each term in the sum appears only
once. We will prove later that |ψiis entangled (Theorem
III.2). For example one state of the above form with
4 qubits could be |ψi=1
6|0000i+|1111i+|1010i+
|0101i+|0111i+|1000i. We then add another qubit
to this 2nqubit state by CN OT s as shown in Fig. 1.
The resultant state is still entangled (please look Methods
for proof) depending on the terms in the sum. If the
(2n+ 1)th qubit does not get entangled to starting 2n-
qubit entangled state then the detection of error in the
2n-qubit entangled state is trivially done by the circuit.
Thus, the protocol detects any quantum error in Bell
states and generalised GHZ states as one of the special
cases. After the preparation of (2n+ 1)-qubit entangled
state, two syndrome qubits are added in the circuit as
shown in the Fig. 1. Then measurement is done on the
error syndrome qubits to detect errors. Table Iabove
summarizes the results of measurement and the type of
error ( for a detailed discussion on measurement results,
see Methods).
The circuit presented here detects any quantum error
present in any single qubit from qubit 1 to qubit 2nand
detects any bit-flip error in (2n+ 1)th qubit.
A. Implementation of the error detection protocol.
We demonstrate the quantum error detection protocol
by simulating the circuit in Fig. 1for a 13-qubit
entangled state on the ibmqx5 quantum computer (see
Methods). We apply single-qubit rotations to first qubit
in the 13-qubit entangled state with the form ε=Rθ
where Rdefines the rotation axis and θis the angle
of rotation. We choose to apply the error on the first
qubit but errors can also be introduced in any of the
12 qubits with the exception of 13th qubit where only
bit-flip error can be detected (see Methods). In the first
case, we introduce no error i.e., we apply ε=R0on
the first qubit. In this case, both the syndrome qubits
are measured to be in their ground state |0i. Next, for
bit-flip error we apply ε=Xπon the first qubit. In this
case, the first error syndrome qubit gets excited to |1i.
In case of phase-flip error, ε=Zπis applied on first
3
|0i1ε
|0i2
|0i3|ψi
|0i2n2
|0i2n1
|0i2n
|0i2n+1
|0i %
|0iH H %
FIG. 1. Quantum circuit for quantum error detection in a (2n+ 1)-qubit entangled state. The blue box generates
2n-qubit entangled state. The red box contains the additional qubit to be added to the 2nqubit entangled state. The smaller
yellow box depicts the circuit used to entangle an additional qubit to the 2nqubit entangled state to prepare a (2n+ 1)-qubit
entangled state. The orange box contains two syndrome qubits to be used to detect quantum errors in the (2n+ 1)-qubit
entangled state. The larger yellow box depicts the circuit used to add the syndrome qubits to the (2n+ 1)-qubit entangled
state for error detection. The green box contains two measurement operations to be made on the two syndrome qubits. The
error εis introduced in qubit 1 and detected from the results of the measurement on the two syndrome qubits. The circuit
works equally well for any arbitrary error introduced in any single qubit from 1 to 2nand bit-flip error in qubit 2n+ 1.
qubit and the first and the second ancillary syndrome
qubit is measured to be in |0iand |1istate respectively.
The measurement results remain the same irrespective
of the 12 qubits on which the error is applied. In case
of a bit-flip error on the 13th qubit, the measurement
result remains same i.e. |10iwhere it is understood that
the first number in the ket represents the first qubit and
the second number represents the second qubit. Thus
the simulation result confirms Table I.
B. Detecting arbitrary errors
Apart from single qubit bit-flip, phase-flip and both,
the circuit in Fig. 1also detects any arbitrary single
qubit errors. The circuit presented here detects any ar-
bitrary error in any single qubit from qubit 1 to qubit
2n. The measurement result of the syndrome qubits can
be tracked as θis varied slowly between πand πin
an applied error ε=Yθ. In a 8192 shots simulation of
the circuit in Fig. 2, the probability of different errors
is plotted as a function of θ. The probability of different
types of errors is compared (see Fig. 3) for arbitrary er-
rors ε=Xθand ε=Zθvarying the values of θbetween
πand π. To demonstrate arbitrary error detection, the
error εis constructed via combinations of Xand Yrota-
tions. A set of eight arbitrary error used in the simulation
are {Yπ/3, Xπ/3, Xπ/3Yπ /3, Xπ/3Y2π/3, X2π/3Yπ/3,
X2π/3Y2π/3, R, H }where Ris Yπ/2Xπ/2and His the
Hadamard operation. These errors are introduced in the
first qubit of the 13-qubit entangled state and the prob-
abilities of different types of errors is compared on a his-
togram for each of the eight errors as shown in Fig. 8.
III. METHODS
A. Initial entangled state
We first show that the 2n-qubit state described in Sec
II is entangled. Before we go on to prove the Theorem,
let us quickly review a measure of entanglement proposed
recently in59. This measure of entanglement generalises
Wootter’s concurrence. Since, we are dealing with qubits,
we will fix the dimension of the Hilbert space of each
particle to be 2. Consider a n-particle pure state |ψiwith
4
FIG. 2. Probability of different types of errors for different Y-error magnitudes. Probability of different types of
errors is extracted from the simulation results of the 13-qubit entangled state with ε=Yθapplied to first qubit (see Section III )
for different values of θwith θ[π , π ]. Here {0,+},{1,+},{0,−} and {1,−} represent the two qubit states |00i,|10i,|01iand
|11irespectively, where |+i=1
2|0i+|1iand |−i =1
2|0i − |1i.|+i,|−i are the states of the second ancillary syndrome
qubit before the Hadamard operation in the circuit of Fig. 2in the bit-flip and phase-flip cases respectively. The blue line
represents probability of no-error, the green line represents the probability of bit-flip as well as phase-flip error while the orange
and yellow line represents probability of bit-flip and phase-flip errors respectively. We observe non vanishing error probability
for both bit-flip and phase-flip errors as Yθcan be decomposed as combination of bit-flip and phase-flip errors. Probability of
no error shows a cosine dependence on θwhich is expected since the matrix for Yθis given as Yθ= cos (θ/2)Iisin (θ/2)σy
where Iis 2 ×2 identity and σyis the Pauli ymatrix.
(a) ε=Xθ(b) ε=Zθ
FIG. 3. Probability of different kinds of errors for arbitrary errors Xθand Zθ.Here {0,+},{1,+},{0,−} and {1,−}
represent the two qubit states |00i,|10i,|01iand |11irespectively, where |+i=1
2|0i+|1iand |−i =1
2|0i−|1i.
|+i,|−i are the states of the second syndrome qubit before the Hadamard operation in the circuit of Fig. 2in the bit-flip
and phase-flip cases respectively. The blue line represents probability of no-error, the green line represents the probability
of bit-flip as well as phase-flip error while the orange and yellow line represents probability of bit-flip and phase-flip errors
respectively. (a) Non vanishing probability for bit-flip error and no-error is observed. This is because Xθcan be decomposed
as Xθ= cos (θ/2)Iisin (θ/2)σxwhere σxis the Pauli xmatrix. The identity matrix in the decomposition is accounted for
no-error and the Pauli xmatrix introduced bit-flip error. (b) Non vanishing probability for phase-flip error and no-error is
observed since again Zθcan be decomposed as Zθ= cos (θ/2)Iisin (θ/2)σzwhere σzis the Pauli zmatrix. The identity
matrix in the decomposition is accounted for no-error and the Pauli ymatrix introduced phase-flip error.
5
the particles labeled by {1,2, . . . , n}in an orthonormal
basis as
|ψi=X
j1,j2,...,jn∈{0,1}
aj1j2...jn|j1i⊗|j2i⊗···⊗|jni
where aj1,j2,...,jnare the complex amplitudes. From now
on, we will omit the range of indices as it is clear that
they vary over {0,1}. Consider the bipartite separability
of a particular set Mof m-particles (m<n) out of the n-
particle system. Without any loss of generality, let the m-
particles be labeled by {1,2, . . . , m},so that the particle
labeled by {m+1, m+2, . . . , n}represent the rest of (n
m)-particles belonging to the complements M.Define the
measure of entanglement EMfor the bipartition Mas
E2
M= 4 X
i1,...,imX
j1i1,...,jmim
|i1j1|+...+|imjm|6=0
X
km+1,...,knai1i2...imkm+1...kn
2
X
lm+1,...,ln
|aj1j2...jmlm+1...ln|2
X
km+1,...,kn
ai1i2...imkm+1...kn¯aj1j2...jmkm+1...kn
2
.
(2)
One easily sees that 0 E2
M21/m. Then |ψiis
entangled if EM6= 0 for atleast one bipartition M. We
will need a version of the Cauchy Schwartz inequality to
deduce our result.
Theorem III.1. (Cauchy-Schwarz Inequality). If
(u1, . . . , un); (v1, . . . , vn)Cnthen
n
X
j=1
|uj|2
n
X
k=1
|vk|2
n
X
i=1
ui¯vi
2
0
This inequality is an equality if and only if one of
(u1, . . . , un) = λ(v1, . . . , vn)for some λC×=C\{0}.
Note that the summand of the second sum
in Equation (2) is non-negative. To see this,
for fixed i1, i2,...imand j1, j2,...jmidentify
{(ai1i2...imkm+1...kn)|km+1 ,...kn= 0,1}and
{(aj1j2...jmkm+1...kn)|km+1 ,...kn= 0,1}with vectors in
C2nmand apply the Cauchy-Schwartz inequality. We
are now ready to prove our Theorem.
Theorem III.2. Let An={|a1a2. . . a2ni;ai=
0,1i= 1,2, . . . 2n , n N}and Bnbe any
nonempty proper subset of Awith the property that if
|a1a2. . . a2ni ∈ Bthen |(a11)(a21) . . . (a2n1)i ∈
B. Then the state given by
|ψi=1
p|AnBn|"X
|a1a2...a2ni∈AnBn
± |a1a2. . . a2ni±|(a11)(a21) . . . (a2n1)i#(3)
is entangled.
Proof. First observe that, for our state aj1,...,j2n
n±1
|AnBn|=±K, 0o.We will show that the bipartition
Mwith m= 1 has the measure of entanglement EM6= 0
for |ψi. First observe that as a consequence of the com-
plimentarity property of |ψi, there is a ket of the form
|0b2· · · b2ni ∈ Bn. We claim that there exists a ket of the
form |1b2· · · b2ni ∈ AnBn.Indeed, if not then for every
(n1)tuple (b2· · · b2n) of 0 and 1, |1b2· · · b2ni ∈ Bn.
But by the property of Bn,|0b2· · · b2ni ∈ Bnfor every
(n1)tuple (b2· · · b2n). But this means that An=Bn
which contradicts the fact that Bnis a proper subset.
With this observation, it is clear that a0b2···b2n= 0 and
a1b2···b2n=±K6= 0. Using Equation (2), we have
E2
M= 4
X
k2,...,k2n
|a0k2...kn|2
X
l2,...,ln
|a1l2...l2n|2
4X
k2,...,k2n
a0k2...k2n¯a1k2...k2n
2
.
6
As discussed above, identify the coefficients
~a1:= {a0k2...k2n|k2, . . . , k2n= 0,1}and ~a2=
{a1k2...k2n|k2, . . . , k2n= 0,1}as vectors in C2n1
by identifying the indices with vectors in C2n1(one
possible identification is recorded in the supplementary
material). Now for the tuple b2, b3, . . . , b2ndiscussed
above, we see that a0b2···b2n= 0 and a1b2···b2n=±K6= 0.
This implies that ~a16=λ~a2for any λC×. Hence by
Cauchy-Schwartz inequality, we have that E2
M6= 0.
Theorem III.3. The state obtained after adding another
ket |0ito the state in Eq. 3using the circuit in Fig. 2is
entangled if and only if there exists a ket in the sum of
Eq. 3with odd number of 1s in it and another ket with
even number of 1s in it.
Proof. First suppose that the sum in Eq. 3has a ket with
odd number of 1s and another ket with even number of 1s.
It is easy to see that after all the CN OT operations on
the ket |0i, it remains |0iwith the terms containing even
number of 1sand becomes |1iwith the terms containing
odd number of 1s. Thus the above mentioned require-
ment guarantees that the state obtained after adding |0i
cannot be factored. Thus the entangled state in Eq. 3re-
mains entangled after addition of the ket |0i. Conversely,
suppose that the sum in Eq. 3contains only kets with
odd or even number of 1sin it but not both. In that
case after all the CN OT operations on |0iit remains |0i
for the case when only terms with even number of 1sare
there in the sum and becomes |1iwhen only terms with
odd number of terms are there in the sum. In both the
cases the last qubit added is separable and the state ob-
tained after addition of the last qubit is in product state
and hence is not entangled.
B. Working of the Protocol
Here we will verify the measurement results listed in
Table I. Consider a 2n-qubit state given in Eq. (3). We
split the analysis into two cases :
1. The 2n-qubit state contains terms with only
odd or even number of 1s : In this case, the
(2n+ 1)th-qubit we add remains separable but now
it can be easily seen that every term in the 2n-qubit
state contains even number of 1s in both the cases.
It can be observed easily from the circuit that the
first syndrome qubit always remains in the state
|0i. The second syndrome qubit acts as the control
in the CNOT operation applied on the first 2n-
qubits and the second syndrome qubit. After the
Hadamard operation on the second syndrome qubit
the |0iin |+ileaves the first 2n-qubits unchanged
while the |1ichanges each ket in the 2n-qubit state
to its complementary ket. Thus after rearrange-
ment, every ket in the 2n-qubit state has the first
and the second syndrome qubit in the states |0iand
|+irespectively. Thus the two syndrome qubits
factor out.
No error : When we introduce no error
in any of the qubits, the measurement result
gives |00iwhere the second syndrome qubit
changes to |0iafter the last Hadamard opera-
tion.
Bit-flip error : If we introduce a bit-flip er-
ror in any one of the 2n+ 1 qubits, then each
term in the 2n+ 1 qubit state has odd num-
ber of 1s and thus after the CNOT operation
on the first syndrome qubit, it changes to |1i
but the second syndrome qubit remains in-
tact since bit-flip does not destroy the comple-
mentarity property of the 2n-qubit entangled
state. Hence the measurement result turns out
to be |10i.
Phase-flip error : Now suppose we intro-
duce a phase-flip error in one of the first 2n-
qubits, then each term in the 2n-qubit en-
tangled state with |1ibecomes − |1i. The
first syndrome qubit remains in state |0iwhile
since complementarity remains undestroyed
the |1iin the second syndrome qubit |+itakes
up a negative sign. Thus the measurement re-
sult is |01i.
Bit-flip and Phase-flip error With simi-
lar analysis, it is easy to see that if both the
errors are introduced in one of the 2n-qubits
then the two syndrome qubits have the state
|1iand |−i respectively and thus the measure-
ment result is |11i.
2. The 2n-qubit state contains a ket with odd
number of 1s and another ket with even
number of 1s : In this case the state obtained
after addition of |0ito the 2n-qubit state is entan-
gled and every term in this (2n+1)-qubit entangled
state contains even number of 1s. Thus following
the same analysis as done in the above case gives
us the same result.
It is interesting to note that all the maximally entangled
Bell states and GHZ state with even number of qubits fall
under the first case. Thus using the protocol, any single-
qubit phase-change error or phase-flip or bit-flip error can
be detected. A limitation of the protocol is that phase-
flip error on the (2n+ 1)th-qubit could not be detected.
To understand this we first write our (2n+ 1)-qubit state
as
|ψi=|ψ1i |0i+|ψ2i |1i(4)
where the normalisation constant is absorbed in |ψ1i
and |ψ1iwhich are 2n-qubit states. An easy observa-
tion shows that |ψ1iand |ψ2ihave the complementarity
property independently. Now a phase-flip error in the
7
last qubit changes the above state to
|ψi=|ψ1i |0i−|ψ2i |1i
After applying all the CN OT operations given in the
circuit, we note that from both the terms in Eq. (4),
the two syndrome qubits factor out as |0iand 1
2(|0i+
|1i) leaving the state in Eq. (4) unchanged. Thus the
protocol fails to detect a phase-flip error in the (2n+1)th-
qubit.
C. Simulation of the protocol on the 16 qubit IBM
quantum computer.
We simulate the protocol for a 13-qubit entangled state
on 16-qubit ibmqx5 IBM quantum computer. ibmqx5 is
a 16-qubit quantum processor made up of superconduct-
ing qubits based on transmoson qubits60. A web-based
quantum circuit construction is provided by IBM for Q5
which is run by simulation or real experiment. To com-
pose quantum circuits, QASM language is needed. These
circuits can then be run via simulation or real experi-
ment using QISKit Python SDK61,62. In our simulation,
we first prepare a 12-qubit entangled state with the com-
plemetarity property. For this we use the quantum cir-
cuit proposed by Yuanhao et al.63 . Then we entangle an-
other qubit with this 12-qubit entangled state using the
CN OT operations as shown in Fig. 14. We write the
QISKit code for our circuit and then run the simulation
with 8192 shots and record the number of times each re-
sult in the measurement of the two error syndrome qubits
occur. Using those numbers we calculate the probability
of each kind of error (For data see Supplementary In-
formation). Bit-flip and phase-flip errors are introduced
using Xgate and U1gate respectively. Both bit-flip and
phase-flip error simultaneously is introduced by apply-
ing Xgate and U1gate simultaneously. Arbitrary phase
change and axis rotation errors are introduced using U3
gate. For example, the error Yθis introduced by the
operation U3(θ, 0,0) whereas the errors Xθand Zθis in-
troduced using U3(θ, π /2,π/2) and U1(θ) respectively.
The recorded probabilities are then compared for differ-
ent kinds of errors (details in Sec II).
IV. DISCUSSION
We have provided an error detection code for a (2n+1)-
qubit entangled system, with a general form which en-
compasses many important entangled states such as max-
imally entangled Bell states and generalised GHZ states,
and simulated its usefulness on IBM Q16 quantum com-
puter. As an immediate consequence of the protocol we
notice that any arbitrary single qubit phase change er-
ror or bit-flip and phase-flip error in GHZ states with
even number of qubits can be detected using the code.
FIG. 4. (a) ε=Yπ/3
FIG. 5. (b) ε=Xπ/3
FIG. 6. (c) ε=Xπ/3Yπ/3
FIG. 7. (d) ε=Xπ/3Y2π/3
FIG. 8. Detection of arbitrary errors. The probability for
each kind of error, no-error (Id), bit-flip (X), phase-flip (Y)
and both bit-flip and phase-flip (Z=XY ) is extracted from
the measurement results of the syndrome qubits for all the
applied errors ε.(a) For applied error ε=Yπ/3, we observe
non zero probability for no error and bit-flip and phase-flip
error simultaneously. This is because Yπ /3can be decomposed
as Yπ/3=3
2Ii
2σy.(b) For applied error ε=Xπ/3, we
observe non zero probability for no-error and bit-flip error be-
cause Xπ/3can be decomposed as Xπ /3=3
2Ii
2σx. In (c)
and (d), for applied errors ε=Xπ/3Yπ/3and Xπ/3Y2π /3, we
observe non-zero probability for all types of error with dif-
ferent amplitudes as Xθinduces bit-flip error and Yθinduces
both bit-flip and phase-flip simultaneously.
8
FIG. 9. (a) ε=X2π/3Yπ/3
FIG. 10. (b) ε=X2π/3Y2π/3
FIG. 11. (c) ε=R
FIG. 12. (d) ε=H
FIG. 13. Detection of arbitrary errors. In (a) and (b),
we observe non zero probability for each type of error due to
reasons mentioned in Fig. 3.(c) For applied error ε=R,
correspond to a Xπ/2Yπ/2operation, which maps the xyz
axes in the Block sphere to yzx, we observe almost equal
probability for each type of error. (d) For applied error ε=
Hwhich correspond to the Hadamard operation, we observe
equal probability for bit-flip and phase-flip error.
We explicitly checked our code for a 13-qubit entangled
state and concluded that the code works well and detects
any arbitrary single qubit phase-change error or bit-flip
or phase-flip error in any of the first 12 qubits and de-
tects any bit-flip error on the 13th qubit. In conclusion
we have provided an error detection code which can be
helpful in manipulating quantum algorithm. This code
can be used by different research groups to generate error
detection codes for their quantum chips. In future, the
work can be extended to the code generalizing all kinds
of entangled states although the entangled state we used
is quite general.
DATA AVAILABILITY
Data are available to any reader upon reasonable re-
quest.
9
FIG. 14. Circuit for simulation of error detection protocol in IBM Q16 quantum computer. In the circuit the first
12 qubits in box A are the 12-qubit entangled state with complementarity property. The 13th qubit is added to generate a
13-qubit entangled state. Qubits in box A is the initial state on which the error will be detected. The two qubits in box C
represent the two syndrome qubits. Box B depicts the connection of syndrome qubit with the initial entangled state. The box
with εis the error to be introduced in the entangled state. The last box (green) represents the measurement operations on the
syndrome qubits.
10
ranveersfl@gmail.com
bishvanweshapanda@gmail.com
bkb18rs025@iiserkol.ac.in
§pprasanta@iiserkol.ac.in
1J.Preskill Battling decoherence: the fault tolerant quan-
tum computer. Phys. Today 52, 24–30 (1999).
2Shor, P. W. Fault-tolerant quantum computation. Proc.
37th Conf. Found. of Comp. Sci. (1996).
3Steane, A. M. Efficient fault-tolerant quantum computing.
Nature 399, 124–126 (1999).
4Muller, M. Rivas, A. Mart´ınez, E. A.Nigg, D.Schindler,
P.Monz, T.Blatt, R.Martin-Delgado, M. A. Iterative
phase optimization of elementary quantum error correcting
codes. Phys. Rev. X 6, 031030 (2016).
5Ghosh, D., Agarwal, P., Pandey, P., Behera, B. K. & Pani-
grahi, P. K. Automated error correction in IBM quantum
computer and explicit generalization. Quantum Inf. Pro-
cess. 17, 153 (2018).
6Chiaverini, J., Leibfried, D., Schaetz, T. & Barett, M. D.
Realization of quantum error correction. Nature 432, 602–
605 (2004).
7Gottesman, D. Stabilizer Codes and Quantum Error Cor-
rection arXiv preperint arXiv:quant-ph/9705052 (1997).
8Raussendorf, R. & Harrington, J. Fault-tolerant quantum
computation with high threshold in two dimensions. Phys.
Rev. Lett. 98, 190504 (2007).
9Childress, J., Taylor, J. M., Sorensen, A. S. & Lukin, M.
D. Fault-tolerant quantum communication based on solid-
state photon emitters. Phys. Rev. Lett. 96, 070504 (2006).
10 Knill, E., Laflamme, R., Martinez, R. & Negrevergne, C.
Benchmarking quantum computers: The five-qubit error
correcting code. Phys. Rev. Lett. 86, 5811–5814 (2001).
11 Nigg, D.M¨uller, M. Martinez, E. A. Schindler, P. Hennrich,
M. Monz, T. Martin-Delgado, M. A.Blatt, R. Quantum
computations on a topologically encoded qubit. Science
345, 302–305 (2014).
12 Linke, N. M. et al. Fault-tolerant quantum error detection.
Sci. Adv. 3, 10 (2017).
13 Takita, M., Cross, A. W., orcoles, A. D., Chow, J. M.
& Gambetta. J. M. Experimental demonstration of fault-
tolerant state preparation with superconducting qubits.
Phys. Rev. Lett. 119, 180501 (2017).
14 Farkas, P. Phase matching condition for quantum search
with a generalized initial state. IEEE/ACM Trans. Net-
work. 3, 2 (1995).
15 Feldmeier, D. C. Fast software implementation of error
detection codes. IEEE/ACM Trans. Network. 3, 6 (1995).
16 McAuley, A. J. Quantum counting. IEEE/ACM Trans.
Network.,2, 1 (1994).
17 Nguyen, G. D. A General Class of Error-Detection Codes.
Proc. 32nd Conf. Inf. Sci. and Sys. 10, 451–453 (1998).
18 Gupta, M., Pathak, A., Srikanth, R. & Panigrahi, P. K.
General circuits for indirecting and distributing measure-
ment in quantum computation. Int. J. Quantum. Inf. 5,
4 (2005).
19 Shor, P. W. & Kenigsberg, D. Scheme for reducing deco-
herence in quantum computer memory. Phys. Rev. A 52,
2493–2496 (1995).
20 Steane, A. M. Error Correcting Codes in Quantum The-
ory. Phys. Rev. Lett. 77, 793–797 (1996).
21 Steane, A. Multiple particle interference and quantum
error correction. Proc. Roy. Soc. Lond. 452, 2551 (1996).
22 Steane, A. Enlargement of Calderbank Shor Steane quan-
tum codes . IEEE Trans. on Inf. Theory 45, 2492–2495
(1999).
23 orcoles, A. D. Magesan, E.Srinivasan, S. J. Cross, A. W.
Steffen, M. Gambetta, J. M.Chow, J. M. Demonstration
of a quantum error detection code using a square lattice
of four superconducting qubits. Nat. Commun. 6, 6979
(2015).
24 Bravyi, S. & Kitaev A. Quantum codes on a lattice with
boundary. arxiv Preprint arXiv quant-ph/9811052 (1998).
25 Kitaev A. Fault-tolerant quantum computation by anyons.
Ann. Phys. 303, 2–30 (1997).
26 Fowler, A. G., Mariantoni, M., Martinis, J. M. & Cleland,
A. N. Surface codes: towards practical large-scale quantum
computation. Phys. Rev. A 86, 032324 (2012).
27 Chow, J. M.Gambetta, J.M.Magesan, E.Abraham,
D.W.Cross, A.W.Johnson, B.R.Masluk, N.A. Ryan,
C.A.Smolin, J.A.Srinivasan, S.J.M Steffen, M. Implement-
ing a strand of a scalable fault-tolerant quantum comput-
ing fabric. Nat. Commun. 5, 500 (2014).
28 Paik, H.Schuster, D. I. Bishop, L. S.Kirchmair, G.Catelani,
G.Sears, A. P.Johnson, B. R.Reagor, M.J.Frunzio,
L.Glazman, L.Girvin, S. M.Devoret, M. H.Schoelkopf,
R. J. Observation of high coherence in josephson junc-
tion qubits measured in a three-dimensional circuit qed
architecture. Phys. Rev. Lett. 107, 240501 (2011).
29 Chang, J.Vissers, M.R.Corcoles, A.D.Sandberg, M.Gao,
J.Abraham, D.W.Chow, J.M.Jay M. Gambetta, JRoth-
well, M.B.Keefe, G.A.Steffen, M.Pappas, D.P. Improved
superconducting qubit coherence using titanium nitride.
Appl. Phys. Lett. 103, 012602 (2013).
30 Barends, R.Kelly, J.Megrant, A. Sank, D.Jeffrey,
E.Chen, Y.Yin, Y.Chiaro, B.Mutus, J.Neill, C.O’Malley,
P.Roushan, P.Wenner, J.White, T. C.White,
T. C.Martinis, J. M. Coherent josephson qubit suitable
for scalable quantum integrated circuits. Phys. Rev. Lett.
111, 080502 (2013).
31 Barends, R.Kelly, J. Megrant, A.Veitia, A.Sank, D.Jeffrey,
E. White, T.C. Mutus, J.Fowler, A.G. Campbell, B.Chen,
Y. Chen, Z. Chiaro, B. Dunsworth, A. Neill, C.O’Malley,
P.Roushan, P. Vainsencher, A.Wenner, J.Korotkov,
A.N.Cleland, A.N.Martinis, J.M. Superconducting quan-
tum circuits at the surface code threshold for fault toler-
ance. Nature 508, 500–503 (2014).
32 Aggarwal, D., Raj, S., Behera, B. K. & Panigrahi,
P. K. Application of quantum scrambling in Ryd-
berg atom on IBM quantum computer. arXiv preprint
arXiv:1804.08655v1 (2018).
33 Srinivasan, K., Satyajit, S., Behera, B. K. & Panigrahi,
P. K. Efficient quantum algorithm for solving travelling
salesman problem: An IBM quantum experience. arXiv
preprint arXiv:1805.10928 (2018).
34 Behera, B. K., Banerjee, A. & Panigrahi, P. K. Exper-
imental realization of quantum cheque using a five-qubit
quantum computer. Quantum Inf. Process. 16(12), 312
(2017).
35 Dash, A., Rout, S., Behera, B. K. & Panigrahi, P. K.
A Verification Algorithm and Its Application to Quan-
tum Locker in IBM Quantum Computer. arXiv preprint
11
arXiv:1710.05196 (2017).
36 Vishnu, P. K., Joy, D., Behera, B. K. & Panigrahi, P. K.
Experimental Demonstration of Non-local Controlled-
Unitary Quantum Gates Using a Five-qubit Quantum
Computer. arXiv preprint arXiv:1709.05697 (2017).
37 Satyajit, S., Srinivasan, K., Behera, B. K. & Panigrahi,
P. K. Discrimination of Highly Entangled Z-states in IBM
Quantum Computer. arXiv preprint arXiv:1712.05485
(2017).
38 Roy, S., Behera, B. K. & Panigrahi, P. K. Demonstration
of Entropic Noncontextual Inequality Using IBM Quantum
Computer. arXiv preprint arXiv:1710.10717 (2017).
39 Gangopadhyay, S., Manabputra. Behera, B. K. & Pan-
igrahi, P. K. Generalization and demonstration of an
entanglement-based Deutsch–Jozsa-like algorithm using a
5-qubit quantum computer. Quantum Inf. Process. 17, 160
(2017).
40 Hegade, N. N., Behera, B. K. & Panigrahi, P. K. Ex-
perimental Demonstration of Quantum Tunneling in IBM
Quantum Computer). arXiv preprint arXiv:1712.07326
(2017).
41 Behera, B. K., Seth, S., Das, A. & Panigrahi, P. K. Ex-
perimental Demonstration of Quantum Repeater in IBM
Quantum Computer. arXiv preprint arXiv:1712.00854
(2017).
42 Kalra, A. R., Prakash, S., Behera, B. K. & Panigrahi,
P. K. Experimental Demonstration of the No Hiding The-
orem Using a 5 Qubit Quantum Computer. arXiv preprint
arXiv:1707.09462 (2017).
43 Jha, R. Das,D.Dash, D.Jayaraman, S.Behera,
B.K.Panigrahi, P.K. A Novel Quantum N-Queens Solver
Algorithm and its Simulation and Application to Satellite
Communication Using IBM Quantum Experience. arXiv
preprint arXiv:1806.10221 (2018).
44 Dash, A., Sarmah, D. Behera, B. K. & Panigrahi, P. K.
Exact search algorithm to factorize large biprimes and
a triprime on IBM quantum computer. arXiv preprint
arXiv:1805.10478 (2018).
45 Behera, B. K. Reza, T. Gupta, A. & Panigrahi, P. K.
Designing Quantum Router in IBM Quantum Computer.
arXiv preprint arXiv:1803.06530 (2018).
46 Srinivasan, K., Behera, B. K. & Panigrahi, P. K. Solv-
ing Linear Systems of Equations by Gaussian Elimination
Method Using Grover’s Search Algorithm: An IBM Quan-
tum Experience. arXiv preprint arXiv:1801.00778 (2018).
47 Gurnani, K. Behera, B. K. & Panigrahi, P. K. Demon-
stration of Optimal Fixed-Point Quantum Search Al-
gorithm in IBM Quantum Computer. arXiv preprint
arXiv:1712.10231 (2017).
48 Kapil, M., Behera, B. K. & Panigrahi, P. K. Quantum
Simulation of Klein Gordon Equation and Observation of
Klein Paradox in IBM Quantum Computer. arXiv preprint
arXiv:1807.00521 (2018).
49 Mohanta, Y. M. et al. Spin-Boson Model to Demonstrate
Quantum Tunneling in Biomolecules using IBM Quantum
Computer. arXiv preprint arXiv:1807.00323 (2018).
50 Manabputra, Behera, B. K. & Panigrahi, P. K. A
Simulational Model for Witnessing Quantum Effects of
Gravity Using IBM Quantum Computer. arXiv preprint
arXiv:1806.10229 (2018).
51 Harper, R. & Flammia, S. Fault tolerance in the IBM Q
Experience. arXiv preprint arXiv:1806.02359 (2018).
52 Klco, N.Dumitrescu, E.F.McCaskey, A.J.Morris,
T.D.Pooser, R.C.Sanz, M.Solano, E.Lougovski, P.Savage,
M.J. Quantum-Classical Computations of Schwinger
Model Dynamics using Quantum Computers. arXiv
preprint arXiv:1803.03326 (2018).
53 Vuillot, C. Is error detection helpful on IBM 5Q chips?
arXiv preprint arXiv:1705.08957 (2017).
54 Bennett, C.H.Brassard, G.Cr´epeau, C.Jozsa, R.Peres,
A.Wootters, W.K. Teleporting an Unknown Quantum
State via Dual Classical and EPR Channels. Phys. Rev.
Lett. 70, 1895–1899 (1993).
55 Bennett, C.H. et al. Quantum cryptography: Public key
distribution and coin tossing. Proc. IEEE Int. Conf. Comp.
Sys. Sig. Process. 175, 8 (1984).
56 Bennett, C.H. et al. Experimental Quantum Cryptogra-
phy. Jour. Crypt. 5, 3–28 (1992).
57 Hillery, M., Buzek, V. & Berthiaume, A. Quantum secret
sharing. arXiv Preprint arXiv:quant-ph/9806063 (1998).
58 Bennett, C.H. & Wiesner, S. Communication via one-and
two-particle operators on Einstein-Podolsky-Rosen states.
Phys. Rev. Lett. 69, 2881 (1992).
59 Bhaskara, V.S., & Panigrahi, P.K. Generalized concur-
rence measure for faithful quantification of multiparticle
pure state entanglement using Lagrange’s identity and
wedge product. Quant. Inf. Process 16, 118 (2017).
60 Koch, J.Yu, T.M.Gambetta, J.Houck, A.A.Schuster,
D.I.Majer, J.Blais, A.Devoret, M.H.Girvin,
S.M.Schoelkopf, R.J. Charge-insensitive qubit design
derived from the Cooper pair box. Phys. Rev. A 76,
(2007).
61 IBM Quantum Experience,
URL:https://www.research.ibm.com/ibm-q/.
62 IBM Quantum Information Software Kit (QISKit),
URL:https://www.qiskit.org.
63 Wang, Y., Li, Y., Yin, Z. & Zeng, B. 16-qubit IBM uni-
versal quantum computer can be fully entangled. arXiv
preprint arXiv:1801.03782 (2018).
ACKNOWLEDGMENTS
R.K.S acknowledges the financial support of Indian
Academy of Sciences (IAS). R.K.S would also like to
thank Indian Institute of Science Education and Research
Kolkata for providing hospitality during the course of
the project. B.K.B. acknowledges the support of Inspire
Fellowship awarded by DST, Government of India. The
authors acknowledge the support of IBM Quantum Ex-
perience for producing experimental results. The views
expressed are those of the authors and do not reflect the
official policy or position of IBM or the IBM Quantum
Experience team.
AUTHOR CONTRIBUTIONS
R.K.S. has developed the quantum error detection
code. R.K.S., B.P. and B.K.B. have discussed and de-
signed all the quantum circuits, and have discussed the
data and analysed the data. R.K.S. and B.P. performed
all the experiments in IBM Quantum Experience plat-
form. B.K.B. supervised the project. P.K.P. has thor-
oughly checked and reviewed the manuscript. R.K.S.,
12
B.P. and B.K.B. have completed the project under the
guidance of P.K.P.
COMPETING INTERESTS
The authors declare no competing financial as well as
non-financial interests.
V. SUPPLEMENTARY INFORMATION:
DEMONSTRATION OF A GENERAL
FAULT-TOLERANT QUANTUM ERROR
DETECTION CODE FOR (2n+ 1)-QUBIT
ENTANGLED STATE ON IBM 16-QUBIT
QUANTUM COMPUTER
For simulating the error detection protocol, we used
QISKit to take both simulation results. The QASM code
for the same is as follows:
1# Im p ort t h e QIS Kit SDK
2from qiskit imp o r t QuantumCircuit ,
C l a s s i c a l R e g i s t e r , Qu an tu mR eg i st er
3from qiskit imp o r t a v a i l a b l e b a c k e n d s , ex e c u t e
4QX TOKEN=”9e333de2e3732e2f9b354939a8ea4336c2
50c87403c930a944ed3fd28112a40a594ca0a4165a9f0
61878 c8aacdf97af6b42f237048b836a8f8277bfd7d3b
73 b4 6 63 ”
8QX URL = h t t p s : / / qu a n tu m e x pe r i e n ce . n g . bl u em i x .
n et / a p i ”
9q = Q u an t um R eg is t er ( 1 5 )
10 c = C l a s s i c a l R e g i s t e r ( 1 5 )
11
12 qc = Qu an tu mCi rc ui t (q , c )
13 from math imp o r t p i
14
15 # We f i r s t p r e p a r e ou r e n t a n g l e d s t a t e
16
17 qc . h( q [ 0 ] )
18 qc . h( q [ 2 ] )
19 qc . h( q [ 3 ] )
20 qc . h( q [ 6 ] )
21 qc . h( q [ 8 ] )
22 qc . h( q [ 9 ] )
23 qc . cx ( q [ 2 ] , q [ 1 ] )
24 qc . cx ( q [ 3 ] , q [ 4 ] )
25 qc . cx ( q [ 6 ] , q [ 5 ] )
26 qc . cx ( q [ 8 ] , q [ 7 ] )
27 qc . cx ( q [ 9 ] , q [ 1 0 ] )
28 qc . cx ( q [ 0 ] , q [ 1 1 ] )
29
30 qc . h( q [ 2 ] )
31 qc . h( q [ 5 ] )
32 qc . h( q [ 8 ] )
33 qc . h( q [ 1 0 ] )
34
35 qc . cx ( q [ 0 ] , q [ 1 ] )
36 qc . cx ( q [ 3 ] , q [ 2 ] )
37 qc . cx ( q [ 5 ] , q [ 4 ] )
38 qc . cx ( q [ 6 ] , q [ 7 ] )
39 qc . cx ( q [ 9 ] , q [ 8 ] )
40 qc . c x (q [ 1 0 ] , q [ 1 1 ] )
41 qc . h( q [ 1 ] )
42 qc . h( q [ 2 ] )
43 qc . h( q [ 4 ] )
44 qc . h( q [ 7 ] )
45 qc . h( q [ 8 ] )
46 qc . h( q [ 1 1 ] )
47
48 # Ad d i ti o n o f an o t he r qu b i t t o mak e 1 3 q u b it
e n t a n g l e d s t a t e
49
50 qc . cx ( q [ 0 ] , q [ 1 2 ] )
51 qc . cx ( q [ 1 ] , q [ 1 2 ] )
52 qc . cx ( q [ 2 ] , q [ 1 2 ] )
53 qc . cx ( q [ 3 ] , q [ 1 2 ] )
54 qc . cx ( q [ 4 ] , q [ 1 2 ] )
55 qc . cx ( q [ 5 ] , q [ 1 2 ] )
56 qc . cx ( q [ 6 ] , q [ 1 2 ] )
57 qc . cx ( q [ 7 ] , q [ 1 2 ] )
58 qc . cx ( q [ 8 ] , q [ 1 2 ] )
59 qc . cx ( q [ 9 ] , q [ 1 2 ] )
60 qc . c x (q [ 1 0 ] , q [ 1 2 ] )
61 qc . c x (q [ 1 1 ] , q [ 1 2 ] )
62
63 # I n t r o d u c t i o n of Er r o r
64
65
66 # A dd i ti on o f f i r s t a n c i l l a r y e rr o r s yn dro me
qubit
67
68
69 qc . cx ( q [ 0 ] , q [ 1 3 ] )
70 qc . cx ( q [ 1 ] , q [ 1 3 ] )
71 qc . cx ( q [ 2 ] , q [ 1 3 ] )
72 qc . cx ( q [ 3 ] , q [ 1 3 ] )
73 qc . cx ( q [ 4 ] , q [ 1 3 ] )
74 qc . cx ( q [ 5 ] , q [ 1 3 ] )
75 qc . cx ( q [ 6 ] , q [ 1 3 ] )
76 qc . cx ( q [ 7 ] , q [ 1 3 ] )
77 qc . cx ( q [ 8 ] , q [ 1 3 ] )
78 qc . cx ( q [ 9 ] , q [ 1 3 ] )
79 qc . c x (q [ 1 0 ] , q [ 1 3 ] )
80 qc . c x (q [ 1 1 ] , q [ 1 3 ] )
81 qc . c x (q [ 1 2 ] , q [ 1 3 ] )
82
83 # A dd i ti on o f se c on d a n c i l l a r y e r r o r sy ndr om e
qubit
84
85 qc . h( q [ 1 4 ] )
86
87 qc . c x (q [ 1 4 ] , q [ 0 ] )
88 qc . c x (q [ 1 4 ] , q [ 1 ] )
89 qc . c x (q [ 1 4 ] , q [ 2 ] )
90 qc . c x (q [ 1 4 ] , q [ 3 ] )
91 qc . c x (q [ 1 4 ] , q [ 4 ] )
92 qc . c x (q [ 1 4 ] , q [ 5 ] )
93 qc . c x (q [ 1 4 ] , q [ 6 ] )
94 qc . c x (q [ 1 4 ] , q [ 7 ] )
95 qc . c x (q [ 1 4 ] , q [ 8 ] )
96 qc . c x (q [ 1 4 ] , q [ 9 ] )
97 qc . c x (q [ 1 4 ] , q [ 1 0 ] )
98 qc . c x (q [ 1 4 ] , q [ 1 1 ] )
99
100 qc . h( q [ 1 4 ] )
101
102
103
104 qc . m ea sur e ( q [ 1 3 ] , c [ 1 3 ] ) ; q c . m ea su re ( q [ 1 4 ] , c
[14])
105 # Se e a l i s t o f a v a i l a b l e l o c a l s i m u l a t o r s
106 p r i n t (” L oc a l ba c ke nd s : , a v a i l a b l e b a c k e n d s ({
local ’: Tr ue }) )
107
108 # C om pi le an d ru n t h e Quantu m c i r c u i t o n a
s i m u l a t o r b ac ke n d
13
109 j o b s i m = e x e c u t e ( qc , ”local qasm simulator ” ,
s h o t s =8 19 2 , m a x c r e d i t s =1 0)
110 s i m r e s u l t = j o b s i m . r e s u l t ( )
111
112 # Show t he r e s u l t s
113 p r i n t (”simulation : , si m r e s u l t )
114 p r i n t ( s i m r e s u l t . g e t c o u n t s ( q c ) )
A. Identification of amplitudes of the state as
vectors
Let {ak1...kn|k1, . . . , kn= 0,1}be the set of all wave-
function amplitudes of the state. Let e1, e2, . . . , enbe the
standard basis of Cn,i.e. we have
ei= (0,...,0,1,0. . . , 0)
where 1 is at ith-position. Let e0be the n-dimensional
zero vector. Consider the following set of vectors :
I={ei|i= 0,1,...n}∪{ei1+ei2|i1> i2;i1, i2= 1, . . . , n}∪{ei1+ei2+ei3|i3> i2> i1;i1, i2, i3= 1, . . . , n}
∪ · · · ∪ {ei1+· · · +ein1|in1>· · · > i1;i1, . . . , in1= 1, . . . , n}∪{e1+e2+· · · +en}.
The cardinality of each set is 1+n, n
2,n
3,...,n
n1,n
n
respectively which sums to 2nwhich is the number of all
possible values of the index k1k2. . . kn.Thus there is a
bijection between the index set and I. Thus we order the
amplitudes as follows :
(ae0, ae1, ae3, . . . , aen, ae1+e2, ae1+e3, . . . , ae1+en, . . . , ae1+e2+···+en)TC2n.
B. Possible qubit states of 8qubit graph state
We simulated the 8qubit graph state given in
Yuanhao et al 63. The list of all possible qubit states of
the eight qubits is given below :
00000000 00000001 00000010 00000011 00000100
00000101 00000110 00000111 00011000 00011001
00011010 00011011 00011100 00011101 00011110
00011111 00100000 00100001 00100010 00100011
00100100 00100101 00100110 00100111 00111000
00111001 00111010 00111011 00111100 00111101
00111110 00111111 01000000 01000001 01000010
01000011 01000100 01000101 01000110 01000111
01011000 01011001 01011010 01011011 01011100
01011101 01011110 01011111 01100000 01100001
01100010 01100011 01100100 01100101 01100110
01100111 01111000 01111001 01111010 01111011
01111100 01111101 01111110 01111111 10000000
10000001 10000010 10000011 10000100 10000101
10000110 10000111 10011000 10011001 10011010
10011011 10011100 10011101 10011110 10011111
10100000 10100001 10100010 10100011 10100100
10100101 10100110 10100111 10111000 10111001
10111010 10111011 10111100 10111101 10111110
10111111 11000000 11000001 11000010 11000011
11000100 11000101 11000110 11000111 11011000
11011001 11011010 11011011 11011100 11011101
11011110 11011111 11100000 11100001 11100010
11100011 11100100 11100101 11100110 11100111
11111000 11111001 11111010 11111011 11111100
11111101 11111110 11111111
C. Measurement data
We performed all the simulations on QISKit and
recorded the countings of each of the measurement
result over the two ancillary error syndrome qubit in
8192 shots. From the countings, the probability of each
error i.e. bit-flip error, phase-flip error and arbitrary
phase-change error was extracted. The data is shown in
the table VIII below.
14
Error {0,+} {1,+} {0,−} {1,−}
Yπ/30.747 0 0 0.253
Xπ/30.75 0.25 0 0
Xπ/3Yπ/30.56 0.185 0.066 0.188
Xπ/3Y2π/30.18 0.063 0.184 0.574
X2π/3Yπ/30.19 0.55 0.195 0.063
X2π/3Y2π/30.06 0.19 0.056 0.185
R=Xπ/2Yπ/20.25 0.252 0.252 0.245
H0 0.503 0.497 0
TABLE II. Probability of each type of error. Here
{0,+},{1,+},{0,−} and {1,−} represent the two qubit
states |00i,|10i,|01iand |11irespectively. + is the short-
hand for |+i=1
2|0i+|1iand is the shorthand for
|−i =1
2|0i − |1i.|+i,|−i are the states of the second
ancillary syndrome qubit before the Hadamard operation in
the circuit of Fig. 2in the bit-flip and phase-flip cases respec-
tively.
θ{0,+} {1,+} {0,−} {1,−}
π0 1 0 0
14π/15 0.012 0.988 0 0
13π/15 0.045 0.955 0 0
12π/15 0.092 0.908 0 0
11π/15 0.1644 0.8356 0 0.
10π/15 0.25 0.75 0 0
9π/15 0.35 0.65 0 0
8π/15 0.45 0.55 0 0
7π/15 0.55 0.45 0 0
6π/15 0.65 0.35 0 0
5π/15 0.752 0.248 0 0
4π/15 0.843 0.157 0 0
3π/15 0.905 0.095 0 0
2π/15 0.952 0.048 0 0
π/15 0.987 0.013 0 0
0 1 0 0 0
π/15 0.99 0.0091 0 0
2π/15 0.957 0.043 0 0
TABLE III. Probability of each type of error for applied
error ε=Xθwith varying θ.
15
θ{0,+} {1,+} {0,−} {1,−}
3π/15 0.906 0.094 0 0
4π/15 0.831 0.17 0 0
5π/15 0.75 0.25 0 0
6π/15 0.658 0.342 0 0
7π/15 0.554 0.446 0 0.
8π/15 0.436 0.563 0 0
9π/15 0.34 0.66 0 0
10π/15 0.25 0.75 0 0
11π/15 0.164 0.836 0 0
12π/15 0.094 0.91 0 0
13π/15 0.044 0.956 0 0
14π/15 0.012 0.988 0 0
π0 1 0 0
TABLE IV. Probability of each type of error for applied
error ε=Xθwith varying θ.(continued. . . )
θ{0,+} {1,+} {0,−} {1,−}
π0 0 0 1
14π/15 0.011 0 0 0.99
13π/15 0.044 0 0 0.956
12π/15 0.098 0 0 0.902
11π/15 0.166 0 0 0.834
10π/15 0.251 0 0 0.75
9π/15 0.35 0 0 651
8π/15 0.45 0 0 554
7π/15 0.56 0 0 0.44
6π/15 0.66 0 0 0.34
5π/15 0.75 0 0 0.25
4π/15 0.84 0 0 0.164
3π/15 0.905 0 0 0.095
2π/15 0.957 0 0 0.042
π/15 0.988 0 0 0.012
0 1 0 0 0
π/15 0.989 0 0 0.011
2π/15 0.957 0 0 0.043
TABLE V. Probability of each type of error for applied
error ε=Yθwith varying θ.
16
θ{0,+} {1,+} {0,−} {1,−}
3π/15 0.905 0 0 0.095
4π/15 0.831 0 0 0.17
5π/15 0.751 0 0 0.25
6π/15 0.65 0 0 0.35
7π/15 0.56 0 0 0.44
8π/15 0.45 0 0 0.552
9π/15 0.35 0 0 0.65
10π/15 0.25 0 0 0.75
11π/15 0.168 0 0 0.832
12π/15 0.092 0 0 0.908
13π/15 0.039 0 0 0.96
14π/15 0.012 0 0 0.99
π0 0 0 1
TABLE VI. Probability of each type of error for applied
error ε=Yθwith varying θ.(continued. . . )
θ{0,+} {1,+} {0,−} {1,−}
π0 0 1 0
14π/15 0.011 0 0.988 0
13π/15 0.044 0 0.956 0
12π/15 0.096 0 0.904 0
11π/15 0.163 0 0.837 0
10π/15 0.25 0 0.75 0
9π/15 0.35 0 0.65 0
8π/15 0.45 0 0.55 0
7π/15 0.55 0 0.45 0
6π/15 0.65 0 0.35 0
5π/15 0.75 0 0.25 0
4π/15 0.83 0 0.17 0
3π/15 0.91 0 0.09 0
2π/15 0.96 0 0.04 0
π/15 0.99 0 0.011 0
0 1 0 0 0
π/15 0.99 0 0.01 0
2π/15 0.96 0 0.043 0
TABLE VII. Probability of each type of error for ap-
plied error ε=Zθwith varying θ.
17
θ{0,+} {1,+} {0,−} {1,−}
3π/15 0.903 0 0.097 0
4π/15 0.831 0 0.17 0
5π/15 0.76 0 0.24 0
6π/15 0.65 0 0.34 0
7π/15 0.55 0 0.45 0
8π/15 0.44 0 0.56 0
9π/15 0.35 0 0.65 0
10π/15 0.25 0 0.75 0
11π/15 0.17 0 0.83 0
12π/15 0.099 0 0.9 0
13π/15 0.04 0 0.96 0
14π/15 0.011 0 0.989 0
π0 0 1 0
TABLE VIII. Probability of each type of error for ap-
plied error ε=Zθwith varying θ.(continued. . . )
ResearchGate has not been able to resolve any citations for this publication.
Article
Full-text available
Quantum computers can potentially solve problems that are computationally intractable on a classical computer in polynomial time using quantum-mechanical effects such as superposition and entanglement. The N-Queens Problem is a notable example that falls under the class of NP-complete problems. It involves the arrangement of N chess queens on an N x N chessboard such that no queen attacks any other queen, i.e. no two queens are placed along the same row, column or diagonal. The best time complexity that a classical computer has achieved so far in generating all solutions of the N-Queens Problem is of the order O(N!). In this paper, we propose a new algorithm to generate all solutions to the N-Queens Problem for a given N in polynomial time of order O(N^3) and polynomial memory of order O(N^2) on a quantum computer. We simulate the 4-queens problem and demonstrate its application to satellite communication using IBM Quantum Experience platform.
Article
Full-text available
Factoring large integers [1, 2] using a quantum computer is an outstanding research problem that can illustrate true quantum advantage [3, 4] over classical computers. Exponential time order [5] is required in order to find the prime factors of an integer by means of classical computation. However, the order can be drastically reduced by converting the factorization problem to an optimization one and solving it using a quantum computer [6, 7]. Recent works involving both theoretical and experimental approaches use Shor's algorithm [5, 8, 9], adiabatic quantum computation [7, 10-13] and quantum annealing principles [14] to factorize integers. However, our work makes use of the generalized Grover's algorithm as proposed by Liu [15], with an optimal version of classical algorithm/analytic algebra. We utilize the phase-matching property [16] of the above algorithm for only amplitude amplification purposes to avoid an inherent phase factor that prevents perfect implementation of the algorithm. Here we experimentally demonstrate the factorization of two bi-primes, 4088459 and 966887 using IBM's 5-and 16-qubit quantum processors, hence making those the largest numbers that has been fac-torized on a quantum device. Using the above 5-qubit processor, we also realize the factorization of a tri-prime integer 175, which had not been achieved to date [11]. We observe good agreement between experimental and theoretical results with high fidelities. The difficulty of the fac-torization experiments has been analyzed and it has been concluded that the solution to this problem depends on the level of simplification chosen, not the size of the number factored [17]. In principle , our results can be extended to factorize any multi-prime integer with minimum quantum resources. Prime factorization is one of the NP-complete problems [18] that lies at the heart of secure data transmission [19]. Cryptography techniques such as RSA [20] have relied on this property to ensure secure means of data communication. It is well-known that the popularly used RSA cryptosystem will be rendered inoperable if the integer factorization problem could be solved in polynomial-time [21]. In 1994, Shor demonstrated a quantum algorithm [22] which can factorize an integer N in polynomial time-specifically, it takes quantum gates of order O((log N) 2 (log log N)(log log log N)) using fast multiplication method. Then in 2001, Shor's algorithm was experimentally realized using NMR architecture, to factorize N = 15 [5]. This long standing record was broken in 2012 with the factorization of N = 21, which also used Shor's algorithm [8]. However, these implementations required prior knowledge of the answer [17]. An alternative approach to Shor's algorithm for quantum factorization takes advantage of adiabatic quantum computation [10]. This approach involves a pre-processing part requiring the transformation of the given factorization problem into an optimization problem [6], which is reducible to a set of equations by minimization. The set of equations thus formed are used to derive a complex Hamiltonian, which encodes the solution in its ground states. The first number that had been factor-ized using this technique was 143, which required only 4 qubits [7]. Dattani and Bryans [11] extended the results to demonstrate factorization of larger numbers and even the tri-prime, N = 175. However, 175 had not been experimentally factorized till date, plausibly because the Hamiltonian had been difficult to implement experimentally. A new insight into quantum factorization was presented by Dridi and Alghassi [14] recently in the year 2017, where they proposed applying quantum annealing techniques to the same optimization method discussed earlier. The authors showed the experimental factoriza-tion of certain bi-primes upto nearly 200000. In the year 2017, the integer N = 291311 had been factorized using the adiabatic approach, making it the largest number that has been factorized using a quantum device [12]. Only 3 qubits were used in this case, as it was observed that further minimization could be achieved during the pre-processing part. In the course of our current work, the method of minimization has been followed for requisite pre-processing, as is required in the adiabatic approach. However, instead of dealing with a dynamically evolving system Hamiltonian, we directly implement an unitary operation which is an exponential function of the non-unitary Hamiltonian used in the adiabatic case. The basis states encoding the required solutions could then be separated out using an exact quantum search algorithm [15]. Implementing this protocol on IBM's quantum processors (both 5-qubit and 16-qubit), we have experimentally fac-torized the integers 4088459 and 966887, using 2 and 4 qubits respectively. The choice of these numbers has been made in order to show that the complexity of the fac-torization problem (via this approach) does not depend on the largeness of the number, but is rather dependent on a certain property of the factors.
Poster
Full-text available
This paper reports on experiments realized on IBM 5Q chips which show evidence for the advantage of using error detection and fault-tolerant design of quantum circuits. By showing that fault-tolerant quantum computation is already within our reach, the author hopes to encourage this approach.
Article
Full-text available
Quantum computers will eventually reach a size at which quantum error correction becomes imperative. Quantum information can be protected from qubit imperfections and flawed control operations by encoding a single logical qubit in multiple physical qubits. This redundancy allows the extraction of error syndromes and the subsequent detection or correction of errors without destroying the logical state itself through direct measurement. We show the encoding and syndrome measurement of a fault-tolerantly prepared logical qubit via an error detection protocol on four physical qubits, represented by trapped atomic ions. This demonstrates the robustness of a logical qubit to imperfections in the very operations used to encode it. The advantage persists in the face of large added error rates and experimental calibration errors.
Article
Full-text available
Local implementation of non-local quantum gates is necessary in a distributed quantum computer. Here, we demonstrate the non-local implementation of controlled-unitary quantum gates proposed by Eisert \emph{et al.} [Phys. Rev. A 62, 052317 (2000)] using the five-qubit IBM quantum computer. Further, we analyze the same quantum task in the presence of a controller using a GHZ-like state as the quantum channel. Finally, we verify the fidelity and accuracy of the implementation through the techniques of quantum state and process tomographies.
Article
Full-text available
This paper demonstrates the use of entanglement resources in quantum speedup by presenting an algorithm which is the generalization of an algorithm proposed by Goswami and Panigrahi (Essentiality of entanglement in a quantum algorithm, 2017. arXiv:1706.09489). We generalize the algorithm and show that it provides deterministic solutions having an advantage over classical algorithm. The algorithm answers the question of whether a given function is constant or balanced and whether two functions are equal or unequal. Finally, we experimentally verify the algorithm by using IBM’s five-qubit quantum computer with a high fidelity. © 2018, Springer Science+Business Media, LLC, part of Springer Nature.
Article
Full-text available
Construction of a fault-tolerant quantum computer remains a challenging problem due to unavoidable noise and fragile quantum states. However, this goal can be achieved by introducing quantum error-correcting codes. Here, we experimentally realize an automated error correction code and demonstrate the nondestructive discrimination of GHZ states in IBM 5-qubit quantum computer. After performing quantum state tomography, we obtain the experimental results with a high fidelity. Finally, we generalize the investigated code for maximally entangled n-qudit case, which could both detect and automatically correct any arbitrary phase-change error, or any phase-flip error, or any bit-flip error, or combined error of all types of error.
Article
Full-text available
The quantum no-hiding theorem, first proposed by Braunstein and Pati [Phys. Rev. Lett. 98, 080502 (2007)], was verified experimentally by Samal et al. [Phys. Rev. Lett. 186, 080401 (2011)] using NMR quantum processor. Till then, this fundamental test has not been explored in any other experimental architecture. Here, we demonstrate the above no-hiding theorem using the IBM 5Q quantum processor. Categorical algebra developed by Coecke and Duncan [New J. Phys. 13, 043016 (2011)] has been used for better visualization of the no-hiding theorem by analyzing the quantum circuit using the ZX calculus. The experimental results confirm the recovery of missing information by the application of local unitary operations on the ancillary qubits.
Article
Full-text available
Quantum cheques could be a forgery-free way to make transaction in a quantum networked banking system with perfect security against any no-signalling adversary. Here, we demonstrate the implementation of quantum cheque, proposed by Moulick and Panigrahi (Quantum Inf Process 15:2475–2486, 2016), using the five-qubit IBM quantum computer. Appropriate single qubit, CNOT and Fredkin gates are used in an optimized configuration. The accuracy of implementation is checked and verified through quantum state tomography by comparing results from the theoretical and experimental density matrices.
Article
Robust quantum computation requires encoding delicate quantum information into degrees of freedom that are hard for the environment to change. Quantum encodings have been demonstrated in many physical systems by observing and correcting storage errors, but applications require not just storing information; we must accurately compute even with faulty operations. The theory of fault-tolerant quantum computing illuminates a way forward by providing a foundation and collection of techniques for limiting the spread of errors. Here we implement one of the smallest quantum codes in a five-qubit superconducting transmon device and demonstrate fault-tolerant state preparation. We characterize the resulting codewords through quantum process tomography and study the free evolution of the logical observables. Our results are consistent with fault-tolerant state preparation in a protected qubit subspace.