XanaduAI / thewalrus

A library for the calculation of hafnians, Hermite polynomials and Gaussian boson sampling.
https://the-walrus.readthedocs.io
Apache License 2.0
99 stars 54 forks source link

Adding_symp #334

Closed MHoude2 closed 2 years ago

MHoude2 commented 2 years ago

Adds a function to verify whether a given matrix is symplectic.

codecov[bot] commented 2 years ago

Codecov Report

Merging #334 (4c21bca) into master (f2ad864) will not change coverage. The diff coverage is 100.00%.

@@            Coverage Diff            @@
##            master      #334   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           24        24           
  Lines         1708      1722   +14     
=========================================
+ Hits          1708      1722   +14     
Impacted Files Coverage Δ
thewalrus/quantum/__init__.py 100.00% <ø> (ø)
thewalrus/quantum/gaussian_checks.py 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update f2ad864...4c21bca. Read the comment docs.

nquesada commented 2 years ago

@josh146 , @sduquemesa : there seems to be an issue with the docs that has nothing to do with this PR. Other than that this seems like a very handy function to have.

josh146 commented 2 years ago

Thanks @MHoude2! @nquesada I've fixed the docs in 4adb3f1

sduquemesa commented 2 years ago

@MHoude2 @nquesada, this seems ready to merge! 🚀 Don't forget to edit the PR template erasing the checklist and adding a description of the changes.