Difference between revisions of "JQ Manual"

From Qugate
Jump to: navigation, search
(C(control, gate) [Universal Control Gate])
Line 66: Line 66:
 
[H(0)]
 
[H(0)]
 
</qu>
 
</qu>
 +
  
 
=== X(bit) [Pauli X-gate] ===
 
=== X(bit) [Pauli X-gate] ===
Line 78: Line 79:
 
[X(0)]
 
[X(0)]
 
</qu>
 
</qu>
 +
  
 
=== Y(bit) [Pauli Y-gate] ===
 
=== Y(bit) [Pauli Y-gate] ===
Line 90: Line 92:
 
[Y(0)]
 
[Y(0)]
 
</qu>
 
</qu>
 +
  
 
=== Z(bit) [Pauli Z-gate] ===
 
=== Z(bit) [Pauli Z-gate] ===
Line 102: Line 105:
 
[Z(0)]
 
[Z(0)]
 
</qu>
 
</qu>
 +
  
 
=== R(n, bit) [Phase Shift Gate] ===
 
=== R(n, bit) [Phase Shift Gate] ===
Line 114: Line 118:
 
[R(2,0)]
 
[R(2,0)]
 
</qu>
 
</qu>
 +
  
 
=== CNot(control, bit) [Controled Not Gate] ===
 
=== CNot(control, bit) [Controled Not Gate] ===
Line 131: Line 136:
 
[CNot(1,0)]
 
[CNot(1,0)]
 
</qu>
 
</qu>
 +
  
 
=== CCNot(control1, control2, bit) [Toffoli Gate] ===
 
=== CCNot(control1, control2, bit) [Toffoli Gate] ===
Line 140: Line 146:
 
[CCNot(2,1,0)]
 
[CCNot(2,1,0)]
 
</qu>
 
</qu>
 +
  
 
=== C(control, gate) [Universal Control Gate] ===
 
=== C(control, gate) [Universal Control Gate] ===
Line 152: Line 159:
 
[C(1,H(0))]
 
[C(1,H(0))]
 
</qu>
 
</qu>
 +
  
 
=== U([argbit<sub>0</sub>, ...,argbit<sub>n</sub>],[valbit<sub>0</sub>, ...,valbit<sub>m</sub>], function) [Universal Function Gate] ===
 
=== U([argbit<sub>0</sub>, ...,argbit<sub>n</sub>],[valbit<sub>0</sub>, ...,valbit<sub>m</sub>], function) [Universal Function Gate] ===

Revision as of 16:18, 21 May 2013

jQ — Quantum Computer Simulator
Powered by QuGate.org

Contents

 [hide

Quick Overview

For quick start, please note 3 inputs. We we will name them: 1st, 2nd and 3rd — from left to right. Please also note 2 buttons: Run and Load.

1st input - init state

1st.png You enter init state of qubits here. Decimal integer is required here. Its binary representation defines start states of qubits in qregister. Qubit 0 is on the top.

2nd input - qubit signature

2nd.png You enter list of integers here in the following format: [qubit1, qubit2, ..., qubitn]. This qubit signature is used for displaying probabilities.

Assume you entered here [3,4] and assume that list of probabilies is like the following:

01 : 0.3 (1)
10 : 0.7 (2)

It simply means that a lot of hypothetical measurements would show that Prob(qubit 4 is in state 0 AND qubit 3 is in state 1) = 0.3 and Prob(qubit 4 is in state 1 AND qubit 3 is in state 0) = 0.7.

Formally, this is a list of integers with given probability. The n-th bit of chosen integer (from right) represents the state of n-th quibit in qubit signature (from left) after hypothetical measurment. Note that you have these integer in binary and in decimal in ().

3rd input - quantum circuit

3rd.png

You enter a list of quantum gates here in the following format [gate1, gate2, ..., gaten]. You can also add measurments to this list, they are represented by M(.).

Run Button

Ok, after you've entered initial state (if you don't the default state is 0) and qunatum circuit you press button Run, which applies quantum circuit to qregister and displays end state and probabilities after hypothetical measurement of qubits listed in qubit signature (2nd input). Like the following:

01 : 0.5 (1)
10 : 0.5 (2)

(0.707106781187,0)|1>
(0.707106781187,0)|2>

The first list are probabilities described in 2nd input - qubit signature section. The second list is just a state of quregister (a complex vector).

Load Button

When you create some more complex and long circuit you want to have it in saved text file. You can. Write your circuit in text file using your favorite editor, save it on your drive and then just press Load to load circuit to Quantum Simulator.

Doesn't work under IE, so please use some other browser for this feature.

Specification

Supported gates

H(bit) [Hadamard Gate]

Defined on base vectors |[bit]\rangle:

H|0\rangle = \frac{1}{\sqrt{2}}(|0\rangle + |1\rangle)

H|1\rangle = \frac{1}{\sqrt{2}}(|0\rangle - |1\rangle)

jQ — Quantum Computer Simulator
Powered by QuGate.org


X(bit) [Pauli X-gate]

Defined on base vectors |[bit]\rangle:

X|0\rangle = |1\rangle

X|1\rangle = |0\rangle

jQ — Quantum Computer Simulator
Powered by QuGate.org


Y(bit) [Pauli Y-gate]

Defined on base vectors |[bit]\rangle:

X|0\rangle = i|1\rangle

X|1\rangle = -i|0\rangle

jQ — Quantum Computer Simulator
Powered by QuGate.org


Z(bit) [Pauli Z-gate]

Defined on base vectors |[bit]\rangle:

X|0\rangle = |0\rangle

X|1\rangle = -|1\rangle

jQ — Quantum Computer Simulator
Powered by QuGate.org


R(n, bit) [Phase Shift Gate]

Defined on base vectors |[bit]\rangle:

R_n|0\rangle = |0\rangle

R_n|1\rangle = e^{i\pi/2^n}|1\rangle

jQ — Quantum Computer Simulator
Powered by QuGate.org


CNot(control, bit) [Controled Not Gate]

Defined on base vectors |[control][bit]\rangle:

CNot|00\rangle = |00\rangle

CNot|01\rangle = |01\rangle

CNot|10\rangle = |11\rangle

CNot|11\rangle = |10\rangle


jQ — Quantum Computer Simulator
Powered by QuGate.org


CCNot(control1, control2, bit) [Toffoli Gate]

Defined on base vectors |[control1][control2][bit]\rangle:

CCNot(|c_1c_2b>) = |c_1c_2(c_1\cdot c_2\oplus b)\rangle

jQ — Quantum Computer Simulator
Powered by QuGate.org


C(control, gate) [Universal Control Gate]

Defined on base vectors |[control]x\rangle:

C(gate)(|0\rangle|x\rangle) = |0\rangle|x\rangle

C(gate)(|1\rangle|x\rangle) = |0\rangle gate|x\rangle

jQ — Quantum Computer Simulator
Powered by QuGate.org


U([argbit0, ...,argbitn],[valbit0, ...,valbitm], function) [Universal Function Gate]

Defined on base vectors |[argbit_n]\dots[argbit_0]\rangle|[valbit_m]\dots[valbit_0]\rangle:

U_{function}|x\rangle|y\rangle = |x\rangle|y \oplus function(x)\rangle

jQ — Quantum Computer Simulator
Powered by QuGate.org

Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox