Thewalrus Versions Save

A library for the calculation of hafnians, Hermite polynomials and Gaussian boson sampling.

v0.6.1

4 years ago

Summary of changes

New features

  • Added two new sampling functions in hafnian.sample, allowing efficient sampling from classical Gaussian states:

    • hafnian_sample_classical_state
    • torontonian_sample_classical_state
  • Added functions to calculate the probability amplitudes directly for pure states:

    • pure_state_amplitude
    • state_vector
  • Added utility functions to check the validity of covariance matrices:

    • is_valid_cov
    • is_pure_cov
    • is_classical_cov

Improvements

  • All functions in the quantum package now take as arguments xp-covariance matrices and vectors of means for consistency.

Contributors

This release contains contributions from (in alphabetical order):

Nicolas Quesada

v0.6.0

4 years ago

Summary of changes

New features

  • Added a new sampling submodule hafnian.sample, allowing sampling from the underlying hafnian/Torontonian distribution of graphs/Gaussian states

  • Documentation overhaul: now contains some of the best and most up-to-date information about hafnians, loop hafnians, and Torontonians

  • C++ library has been significantly improved, tested, and refactored

Improvements

  • Ported the hafnian_approx.F90 Fortran file to C++

  • The Torontonian function is now parallelized via OpenMP

  • Tests and the C++ header library have been refactored

  • Addition of new C++ tests using Googletest

  • C++ library is now documented via Doxygen; this is integrated directly into Sphinx

Contributors

This release contains contributions from (in alphabetical order):

Brajesh Gupt, Josh Izaac, Nicolas Quesada

v0.1.2

5 years ago

Bug fixes

  • Solve type conflict preventing the pip wheel to build correctly (see #4).

Contributors

@emaballarin

v0.1.1

5 years ago

New features

  • Odd-dimensioned matrices no longer raise an error, as the loop hafnian is well defined for matrices with odd dimensions. The non-loop hafnian will now return 0 for matrices with odd-dimensions.

0.1.1-beta

5 years ago