https://github.com/dpbm/ghz
Testing GHZ state creation
https://github.com/dpbm/ghz
circuit-cutting circuit-knitting error-mitigation ghz-state ibm-quantum python qiskit qiskit-sampler quantum-computing quantum-states
Last synced: 30 days ago
JSON representation
Testing GHZ state creation
- Host: GitHub
- URL: https://github.com/dpbm/ghz
- Owner: Dpbm
- Created: 2024-06-14T19:33:16.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-07-27T15:33:57.000Z (over 1 year ago)
- Last Synced: 2025-01-19T18:51:54.023Z (about 1 year ago)
- Topics: circuit-cutting, circuit-knitting, error-mitigation, ghz-state, ibm-quantum, python, qiskit, qiskit-sampler, quantum-computing, quantum-states
- Language: Jupyter Notebook
- Homepage: https://dpbm.github.io/ghz/
- Size: 7.96 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# GHZ
This repo contains some tests on creating `GHZ` states using [Qiskit](https://www.ibm.com/quantum/qiskit).
For this project, the idea was to explore some different techniques to create big `GHZ states`.
The techniques I used were:
- circuit knitting
- topology mapping
- circuit transpilation (using Qiskit `PassManager` and `Sampler`)
In total, 4 circuits were built mixing some of these techniques.
## Circuits
### 5 qubits GHZ - [notebook](./circuit-cutting-test.ipynb)

This one was the first test done with circuit knitting, using the `cutqc` module from `circuit knitting toolbox` package.
Here the circuit was cut in 2 separated parts, measured and them joined together.

| cuts | exported data |
|-----------------------------------------------|-----------------------------------------------------------------------|
|[subcircuit 0](./5-qubits-GHZ-subcircuit-0.qpy)|[cuts](./5-qubits-GHZ-cuts.json) |
|[subcircuit 1](./5-qubits-GHZ-subcircuit-1.qpy)|[probabilities](./5-qubits-GHZ-probs.json) |
| |[reconstructed probabilities](./5-qubits-GHZ-reconstructed-probs.json) |
### 16 qubits GHZ - [notebook](./16-qubits-ghz-circuit-knitting.ipynb)

The second is a 16 qubits circuit, following the topology of IBM's Guadalupe backend. After mapping each qubit connection, the resulting distribution after simulating was:

This one, was also cut using `cutqc` giving the following results:

| cuts | exported data |
|------------------------------------------------|-----------------------------------------------------------------------|
|[subcircuit 0](./16-qubits-GHZ-subcircuit-0.qpy)|[cuts](./16-qubits-GHZ-cuts.json) |
|[subcircuit 1](./16-qubits-GHZ-subcircuit-1.qpy)|[probabilities](./16-qubits-GHZ-probs.json) |
|[subcircuit 2](./16-qubits-GHZ-subcircuit-2.qpy)|[reconstructed probabilities](./16-qubits-GHZ-reconstructed-probs.json)|
## 28 qubits GHZ - [notebook](./28-qubits-ghz-circuit-knitting.ipynb)

The 28 qubits version was based on IBM's Cambridge backend, however this one wasn't executed due to hardware issues.
Nevertheless, some cuts were done.
| cuts | exported data |
|------------------------------------------------|-----------------------------------------------------------------------|
|[subcircuit 0](./28-qubits-GHZ-subcircuit-0.qpy)|[cuts](./28-qubits-GHZ-cuts.json) |
|[subcircuit 1](./28-qubits-GHZ-subcircuit-1.qpy)|[probabilities](./28-qubits-GHZ-probs.json) |
|[subcircuit 2](./28-qubits-GHZ-subcircuit-2.qpy)| |
|[subcircuit 3](./28-qubits-GHZ-subcircuit-3.qpy)| |
## 127 qubits GHZ - [notebook](./ghz-127-qubits.ipynb)

The biggest one, is based on IBM's Osaka backend. This one, was transpiled and executed on real hardware, the outcomes were the following:

These results seem really wrong, once the expected was nearly 50% of probability for $|00000...0\rangle$ and 50% for $|11111...1\rangle$. However, due the amount of errors for `cx` gates, it's probably the accurate result for a real device.
This effect can be seem in a local test executed with 20 qubits.


Even that the extreme states are with high probability, it tends to deviate at each qubit addition.