Skip to main content

PQCA (Partitioned Quantum Cellular Automata)

A quantum cellular automaton iteratively applies some update circuit to some initial state. A partitioned quantum cellular automaton (PQCA) derives its update circuit by partitioning a lattice of qubits into cells, and then applying the same circuit to each cell. The full update circuit is created by composing several such partitioned updates. There is a review of Quantum Cellular Automata by Terry Farrelly, published in Quantum, and available at doi:10.22331/q-2020-11-30-368.

This python module allows for the easy creation and execution of partitioned quantum cellular automata. To create an automaton you will need:

  • A starting state (list of 0s and 1s)
  • Update Frames (see pqca.update_frame)
  • A simulator / quantum computer (see pqca.backend)

An Update Frame combines a tessellation with a circuit to be applied to each cell in that tessellation. A tessellation just partitions a list of qubits into cells. For example pqca.tessellation.one_dimensional(10,2) partitions 10 qubits into 5 cells, each of size 2. The Update Frame would then need to be a circuit on 2 qubits. For more complicated tessellations you can use, e.g. pqca.tessellation.n_dimensional([4,2,4],[2,2,2]) which partitions 32 qubits as though they were arranged in a lattice of shape 4 x 2 x 4, with each cell of size 2 x 2 x 2. The Update Frame would then need to be a circuit on 8 qubits.

One can then call next(automaton) which will advance the internal state of the automaton and return the new state.

Installation

Install via pip from the command line with the command:

pip install pqca

Example

Here is an example that creates two update frames, both applying a simple CX gate, but with offset tessellations.

# Create circuit
cx_circuit = qiskit.QuantumCircuit(2)
cx_circuit.cx(0, 1)

# Create tessellation
tes = pqca.tessellation.one_dimensional(10, 2)

# Create update frames
update_1 = pqca.UpdateFrame(tes, cx_circuit)
update_2 = pqca.UpdateFrame(tes.shifted_by(1), cx_circuit)


# Create initial state
initial_state = [1]*10

# Specify a backend; `pqca.backend.aer()` returns IBM's Aer simulator
# See backend.py for more details and instructions on coding your own backend
backend = pqca.backend.aer()

# Create the automaton
automaton = pqca.Automaton(initial_state, [update_1, update_2], backend)

# The automaton can be called like any other iterator
# The following line advances the internal state, and returns the new state
next(automaton)

Documentation

Detailed documentation can be found at readthedocs.io as well as in the docstrings of the python files themselves.

Licensing

The source code is available under the MIT licence and can be found on Hector Miller-Bakewell's github.

Acknowledgements

This package was created as part of the QuTune Project.

Metadata

Release files for pqca 2.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pqca 2.0.0
File Size Uploaded
pqca-2.0.0.tar.gz 12.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pqca 2.0.0
File Interpreter ABI Platform
pqca-2.0.0-py3-none-any.whl Python 3 none any Details

Total release size: 26.8 kB

Release files / pqca-2.0.0.tar.gz

Download URL pqca-2.0.0.tar.gz
Size 12.3 kB
Tags Source
SHA-256 checksum
How to use checksums
b38dd76f05db98e657b1ba45122e44199a8a467a31841bd7922a293cfd54f8df
BLAKE2b-256 checksum
How to use checksums
a1e24c1e48b9cba9f474d27964cca5077378f0b927cc45c8d865ef5df70f53d8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / pqca-2.0.0-py3-none-any.whl

Download URL pqca-2.0.0-py3-none-any.whl
Size 14.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
bd5c0891858fccc2df7b4b7d039a2de22653da1f4e011586b3ce1954f3f8e5d0
BLAKE2b-256 checksum
How to use checksums
e21eef33738cf7bbd9d6a0710d75a6609fd363466079fc9ee6dede3222530a38
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release history Release notifications | RSS feed

This release

2.0.0 This release

2 release files

1.1.1

2 release files

1.1.0

2 release files

1.0.3

2 release files

1.0.2

2 release files

1.0.1

1 release file

1.0.0

1 release file

0.1.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page