Commit 4918724 1 parent 9cbc8ce commit 4918724 Copy full SHA for 4918724
File tree 2 files changed +9
-6
lines changed
include/mqt-core/algorithms
2 files changed +9
-6
lines changed Original file line number Diff line number Diff line change 9
9
10
10
#pragma once
11
11
12
- #include " QuantumComputation.hpp"
12
+ #include " ir/ QuantumComputation.hpp"
13
13
14
14
namespace qc {
15
15
/* *
Original file line number Diff line number Diff line change 10
10
#include " algorithms/StatePreparation.hpp"
11
11
12
12
#include " CircuitOptimizer.hpp"
13
+ #include " ir/operations/Operation.hpp"
13
14
#include " ir/operations/StandardOperation.hpp"
15
+ #include " ir/operations/OpType.hpp"
14
16
15
17
#include < cmath>
16
18
#include < complex>
17
- #include < utility>
19
+ #include < tuple>
20
+ #include < stddef.h>
18
21
19
22
static const double EPS = 1e-10 ;
20
23
21
24
namespace qc {
22
25
using Matrix = std::vector<std::vector<double >>;
23
26
24
27
auto createStatePreparationCircuit (
25
- const std::vector<std::complex<double >>& amplitudes) -> QuantumComputation {
28
+ std::vector<std::complex<double >>& amplitudes) -> QuantumComputation {
26
29
27
30
if (!isNormalized (amplitudes)) {
28
31
throw std::invalid_argument{
@@ -95,9 +98,9 @@ template <typename T>[[noexcept]] auto twoNorm(std::vector<T> vec) -> double {
95
98
return identity;
96
99
}
97
100
98
- [[noexcept ]] auto matrixVectorProd ( const Matrix& matrix,
99
- std::vector< double > vector)
100
- -> std::vector<double> {
101
+ [[noexcept ]] auto
102
+ matrixVectorProd ( const Matrix& matrix,
103
+ std::vector< double > vector) -> std::vector<double > {
101
104
std::vector<double > result;
102
105
for (const auto & matrixVec : matrix) {
103
106
double sum{0 };
You can’t perform that action at this time.
0 commit comments