Skip to content

Repository files navigation

Pauli Propagation Virtual Machine

A fast quantum circuit simulator written in Rust, with Python bindings.

DocsCILicense

Install

Python (with uv):

uv add git+https://github.com/QuEraComputing/ppvm.git#subdirectory=ppvm-python

Rust:

[dependencies]
ppvm-pauli-sum = { git = "https://github.com/QuEraComputing/ppvm" }

Examples

Pauli propagation runs backwards (Heisenberg picture): write gates in reverse order.

fromppvmimportPauliSumstate=PauliSum.new(n_qubits=2, terms=["ZZ"])
state.cnot(0, 1) # GHZ preparation, written in reversestate.h(0)
print(state) # 1.000 * IZprint(state.overlap_with_zero())

The generalized stabilizer tableau is itself a form of Pauli propagation — it tracks stabilizer generators under Heisenberg evolution, extended to handle non-Clifford gates and measurements:

fromppvmimportGeneralizedTableautab=GeneralizedTableau(n_qubits=2)
tab.h(0)
tab.cnot(0, 1)
r0, r1=tab.measure(0), tab.measure(1)
print(f"Qubit 0: {r0}, Qubit 1: {r1}") # always correlated

See the documentation for the Rust API, Stim integration, and symbolic propagation.

License & contributing

Licensed under Apache 2.0; see NOTICE for attribution. Contributions are welcome — read CONTRIBUTING.md and the CLA before opening a pull request.

Releases

Packages

Used by

Contributors

Languages