Julia implementation of the tensor-network-based algorithm for simulating Gaussian boson sampling experiments proposed in [1], and of the algorithm in [2] for computing elements of Gaussian operations in the Fock number basis, plus a set of utilities for a full MPS simulation of quantum optical operations.
The functions for computing hafnians and loop hafnians of square matrices are ported from The Walrus [3].
This package is registered in my TensorNetworkSimulations registry. By first adding this registry, with
using Pkg
pkg"registry add https://github.com/phaerrax/TensorNetworkSimulations.git"(this must be done just once per Julia installation) the package can then be installed as a normal one:
using Pkg
pkg"add GaussianBosonSamplingMPS"Alternatively, straight installation from GitHub is also possible:
using Pkg
pkg "add https://github.com/phaerrax/GaussianBosonSamplingMPS.jl"[1] Changun Oh, Minzhao Liu, Yuri Alexeev, Bill Ferrerman and Liang Jiang, ‘Classical algorithm for simulating experimental Gaussian boson sampling’. Nature Physics 20, 1461–1468 (2024)
[2] Nicolás Quesada. ‘Franck-Condon factors by counting perfect matchings of graphs with loops’. The Journal of Chemical Physics 150.16 (2019)
[3] Brajesh Gupt, Josh Izaac and Nicolás Quesada. ‘The Walrus: a library for the calculation of hafnians, Hermite polynomials and Gaussian boson sampling.’ Journal of Open Source Software, 4(44), 1705 (2019)