-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Permutations Improvement, Kronecker Commutation #45
Open
wjbs
wants to merge
16
commits into
main
Choose a base branch
from
permutations-improvement
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…t, create several new files associated with permutations and perform code repair to account for these changes. Also many small additions and improvements to various parts of QuantumLib.
… file exporting PermutationsBase, PermutationInstances, and PermutationMatrices, for backward compatibility
Looks like the CI is failing for 8.16/8.17. It looks like it's not too bad to fix (at least the current error) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request has two (non-independent) main parts:
Significantly improve handling of permutations. This includes splitting
Permutations.v
into several files.PermutationsBase.v
is roughly equivalent to the originalPermutations.v
file without any reference to permutation matrices.PermutationInstances.v
contains definitions of and results about a large number of permutations, as well as building off ofPermutationAutomation.v
to provide robust automatic simplification of permutations, including a robust Setoid instance forperm_eq
, bounded extensional equality of functions.PermutationMatrices.v
defines and proves results about the matrices associated to permutations. Associated to these updates are numerous proof repairs and improvements.Implement
kron_comm
, which commutes the kronecker product. In particular, this is the (symmetric) braiding of the monoidal category of matrices under kronecker product. Numerous results are proven, many of which are consequences of the main naturality result,kron_comm n p × (A ⊗ B) = B ⊗ A × kron_comm o m
(for appropriate dimensions and WF matrices).This depends on a number of lemmas added to base files (such as
Complex.v
and particularlyModulus.v
), and also leads to a number of improved proofs. Many (especially computational) proofs aboutswap
are special cases of results aboutkron_comm
and are sped up by applying the general results.In addition to lemmas directly used by the above sections, many other small lemmas are added to various files. Some of these come from needs in VyZX, especially the development of bipermutations. Likewise, numerous proofs have been shortened or sped up across a number of files. This was not done in any particularly systematic way, but in each case the change was done carefully. Some small to moderate compilation time improvements (no doubt offset by added code from permutations and
kron_comm
) may be present.