Examples¶
Each folder of examples/ explains itself, with a README that says what it does and how to run it, and a block
diagram. Anyone can emulate them, with no account and no token: ./emulate.sh in a folder, or
all the examples on Binder.
Hamiltonian simulation on a quantum computer, step by step is a full tutorial.
To send one, ./run.sh in its folder checks it offline, with no network call and no token. Put your own project in
the manifest and in ~/.config/qdevices/qdevices.toml in place of the placeholders, then run ./submit.sh
(Install and first run). examples/ also holds an example config (qdevices.toml) and rules file (rules_bell.py,
Rules).
Folder |
Site |
What it sends |
What a perfect machine would give |
|---|---|---|---|
|
Euro-Q-Exa |
an X gate on one qubit, 100 shots |
|
|
Euro-Q-Exa |
a Bell pair (H, CX), 100 shots |
|
|
Euro-Q-Exa |
the two above, and the Bell job again: send the first order alone, look at it, then go on |
as above |
|
VLQ |
a PRX rotation by pi on one qubit, 100 shots |
|
|
VLQ |
a Bell pair in native gates, through the resonator |
|
|
Piast-Q |
an R rotation by pi, 100 shots |
|
|
Piast-Q |
one RXX gate at its largest angle, 100 shots |
|
A real machine has noise, so the counts spread.
VLQ does not compile: the indices of a VLQ text must match the table of the day (VLQ (IT4Innovations)).
In the release gate, the circuits of
vlq-one-qubit,piastq-one-qubit,euroqexa-bellandpiastq-bell(at 400 shots, then at 200) were sent with this app. The one-qubit jobs came back the same day; Euro-Q-Exa (LRZ) and Piast-Q (PCSS) say what became of the Bell jobs.euroqexa-one-qubit,euroqexa-three-jobsandvlq-bellhave not run on hardware with this app.examples/qrisp/has 16 programs for Euro-Q-Exa, written with Qrisp (Circuits written in Qrisp).
Starter examples from the sites’ own material¶
These four take their circuit from a manual or tutorial of the site or of the machine’s maker, written
again in the form the app sends. Each manifest names its source in the key source, which the record
copies to its start line. None of them has run on hardware with this app.
Folder |
What it sends |
What a perfect machine would give |
Source, and its licence |
|---|---|---|---|
|
a GHZ state on three qubits (H, CX, CX), 100 shots |
|
LRZ training material of the pilot phase, |
|
prepare |
|
MQSS adapter example |
|
a GHZ state on five qubits in native gates, through the resonator, 1000 shots |
|
the circuit of the IT4I notebook GHZ_example.ipynb (the site says all rights reserved: only the circuit is taken); the star form of the maker’s IQM Academy notebook |
|
the three native operations: RZ, R and RXX on two qubits, 100 shots |
all four outcomes, about a quarter each |
the default example of |
What was changed from each source:
Euro-Q-Exa: both texts are OpenQASM 2, the form the app sends, and the site compiles them, as the sources expect (Euro-Q-Exa (LRZ)). The GHZ source is OpenQASM 3 with 1000 shots. The inverse-unitary source builds its gates in a loop; here they are written out.
VLQ: the CX gates of the IT4I circuit are in native form. The first qubit moves into the resonator, each other qubit takes
r(pi/2, -pi/2),czwith the resonator andr(pi/2, pi/2), and the first qubit moves back. The source runs 5000 shots; 1000 shots cost the same 0.9 s floor by the published rule.Piast-Q: the operation list of the API example as it is. The source asks for 5 shots.