Repository navigation
Require square matrices in the unitary predicate - #311
Draft
PawelTroka wants to merge 1 commit into
Draft
PawelTroka wants to merge 1 commit into
PawelTroka wants to merge 1 commit into
Conversation
This file contains hidden or 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
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.
Problem
isUnitary(matrix({{1,0}}))currently returnstrue. Its rows are orthonormal, but the rectangular map discards a coordinate and is not a unitary matrix. The same defect exists in the host and emitted TSL helper.Change
Require equal row and column counts before applying the existing conjugate-transpose product and relative comparison. Preserve square-matrix arithmetic, the
1e-10tolerance, input matrices, and the separate rectangular identity-pattern semantics ofisIndentity/IdentityMatrix.Update the authored and materialized reference together. This intentionally changes the previously documented rectangular-row behavior. A script that needs row orthonormality can continue to request it explicitly with
isIndentity(M*HermitianTranspose(M)).Validation
git diff --checkpassed.The uploaded tree
0b4c9131ff209eb4f53fe45792b744e49f935f65exactly matches the tested local tree.Existing work
Reviewed all 78 open issues, 14 existing open PRs, recent closed PRs, and targeted matrix/unitary searches. No existing PR repairs this predicate. This is separate from pointwise operations (#185), matrix powers (#238), and the active numerical/platform work.
Independently based on master
fe1aba49b5f9538355ffaaa3d1683f69a23d2d9c. Draft for review and native CI; no merge performed.Combined compatibility check — 2026-10-30
Also tested the final contributions in #311, #313, #314 and #315 together with the seven existing maintenance PRs (#304–#310), using the existing #312 candidate
189d28c0ec7acbf77d380f14f95ef450e7bfbd84as the local integration base.Eight shared paths required composition resolutions. These preserved all Euclid/ODE/polynomial aliases, completion and authoring registrations; Debye/unitary documentation; and Find/Replace/printing methods, test-source links and documentation entries. No feature behavior or numerical algorithm needed changing to combine the contributions. The independently published PRs remain based on master.
Combined local tree:
63225a973ea2883974a91ab26afcdc83d866e77b, SDK 10.0.403, Linux x64. The reference check used the authenticated master inventory plus current production reflection for changed entries through a portable UI shell. Native Windows tests, full native catalog execution and printer acceptance remain pending. The existing #312 PR was not changed by this local verification.