Skip to content

Update decomposeU.py#1

Open
AlphaC137 wants to merge 1 commit intomarkf94:masterfrom
AlphaC137:master
Open

Update decomposeU.py#1
AlphaC137 wants to merge 1 commit intomarkf94:masterfrom
AlphaC137:master

Conversation

@AlphaC137
Copy link
Copy Markdown

  • Separated concerns into logical components, easibly readable
  • Worked on Error Handling and Validation
  • Added some feautures

- Separated concerns into logical components, easibly readable
- Worked on Error Handling and Validation
- Added some feautures
@AlphaC137
Copy link
Copy Markdown
Author

Modifications on the run file

Example usage

matrix = UnitaryMatrix(
    u00=0.19509,
    u01=-0.98079,
    u10=0.98079,
    u11=0.19509
)

decomposer = GateDecomposer(matrix)
angles = decomposer.decompose()

if angles:
    # Verify the decomposition
    if decomposer.verify_decomposition(angles):
        print("Decomposition successful!")

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant