Skip to content
This repository was archived by the owner on Jun 15, 2023. It is now read-only.

Hybrid Schrödinger-Feynman Simulation Preparation #12

Merged
merged 16 commits into from
May 7, 2021

Conversation

burgholzer
Copy link
Member

@burgholzer burgholzer commented May 3, 2021

This PR adds the essential functionality to the JKQ DD Package to support hybrid Schrödinger-Feynman simulation.
The main change is that decision diagrams might now "start" (from the bottom) with a different qubit than 0, which is needed for splitting the circuit horizontally.
Additionally, this PR adds functionality that allows to efficiently export a complete set of amplitudes from a state vector DD and to transfer an existing DD to another package instance.

✨ state generation, matrix generation, and multiplication receive an additional parameter start (default 0) that indicates the bottom-most qubit the DD is built from
💥 removed the makeGateDD constructor taking two Qubit arguments for control and target, as it is ambiguous with the new start parameter
✨ method for deleting a specific edge of a DD node
kronecker receives an additional parameter indicating whether to increase the indices of the top DD
✨ method for tranfering a DD Edge from one package to another
✨ methods for (recursively) exporting and adding amplitudes
✨ ComplexValue addition
🏁 fix binary serialization issues under Windows
♻️ runtime exceptions instead of assertions
📝 fix readme example
📄 updated license

✨ state generation, matrix generation, and multiplication receive an additional parameter `start` (default 0) that indicates the bottom-most qubit the DD is built from
💥 removed the `makeGateDD` constructor taking two `Qubit` arguments for control and target, as it is ambiguous with the new `start` parameter
✨ method for deleting a specific edge of a DD node
✨ `kronecker` receives an additional parameter indicating whether to increase the indices of the top DD
✨ method for tranfering a DD Edge from one package to another
✨ methods for (recursively) exporting and adding amplitudes

Signed-off-by: Lukas Burgholzer <[email protected]>
@burgholzer burgholzer added the enhancement New feature or request label May 3, 2021
@burgholzer burgholzer self-assigned this May 3, 2021
@codecov
Copy link

codecov bot commented May 3, 2021

Codecov Report

Merging #12 (79c0af3) into master (9a98015) will decrease coverage by 0.0%.
The diff coverage is 98.6%.

Impacted file tree graph

@@           Coverage Diff            @@
##           master     #12     +/-   ##
========================================
- Coverage    95.4%   95.3%   -0.1%     
========================================
  Files          17      17             
  Lines        2274    2290     +16     
========================================
+ Hits         2170    2184     +14     
- Misses        104     106      +2     
Impacted Files Coverage Δ
include/dd/ComplexValue.hpp 97.0% <ø> (ø)
include/dd/Package.hpp 92.5% <98.3%> (-0.1%) ⬇️
include/dd/Export.hpp 93.5% <100.0%> (ø)
test/test_complex.cpp 100.0% <100.0%> (ø)
test/test_package.cpp 100.0% <100.0%> (ø)

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 9a98015...79c0af3. Read the comment docs.

♻️ adjust to removed constructor
🐛 `BM_MakeControlledQubitGateDD_ControlBottom_TargetTop` did not actually construct a controlled operation

Signed-off-by: Lukas Burgholzer <[email protected]>
Signed-off-by: Lukas Burgholzer <[email protected]>
burgholzer added 6 commits May 4, 2021 15:48
Signed-off-by: Lukas Burgholzer <[email protected]>
Signed-off-by: Lukas Burgholzer <[email protected]>
Signed-off-by: Lukas Burgholzer <[email protected]>
Signed-off-by: Lukas Burgholzer <[email protected]>
⬆️ benchmark

Signed-off-by: Lukas Burgholzer <[email protected]>
@burgholzer burgholzer marked this pull request as ready for review May 6, 2021 10:02
@burgholzer burgholzer requested review from HartwigB and hillmich May 6, 2021 10:02
burgholzer added 5 commits May 6, 2021 14:32
Signed-off-by: Lukas Burgholzer <[email protected]>
Signed-off-by: Lukas Burgholzer <[email protected]>
Signed-off-by: Lukas Burgholzer <[email protected]>
@burgholzer burgholzer requested a review from hillmich May 6, 2021 12:58
Copy link
Collaborator

@hillmich hillmich left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nicely done.

burgholzer added 2 commits May 6, 2021 17:08
Signed-off-by: Lukas Burgholzer <[email protected]>
Signed-off-by: Lukas Burgholzer <[email protected]>
@burgholzer burgholzer merged commit 17800b5 into master May 7, 2021
@burgholzer burgholzer deleted the slicing_new_package branch May 7, 2021 08:43
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants