Skip to content

Commit

Permalink
Updated QMCI test
Browse files Browse the repository at this point in the history
  • Loading branch information
renezander90 committed Dec 21, 2024
1 parent 87cd809 commit 7ea3b2a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/qrisp/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,6 @@
from qrisp.alg_primitives import *
from qrisp.algorithms import *

for i in ['shor','qaoa','qiro','grover','quantum_backtracking','quantum_counting','vqe']:
for i in ['shor','qaoa','qiro','grover','quantum_backtracking','quantum_counting','vqe','qmci']:
sys.modules['qrisp.'+i] = sys.modules['qrisp.algorithms.'+i]
from qrisp.default_backend import *
5 changes: 3 additions & 2 deletions tests/test_QMCI.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ def test_QMCI():
def f(qf):
return qf*qf

qf = QuantumFloat(3,-3)
a = QMCI([qf], f)
qf_x = QuantumFloat(3,-3)
qf_y = QuantumFloat(6,-6)
a = QMCI([qf_x,qf_y], f)

assert np.abs(a-0.2734375)<0.01

0 comments on commit 7ea3b2a

Please sign in to comment.