circuit_optimizer.hpp
Go to the documentation of this file.
1 
2 #pragma once
3 
4 #include "type.hpp"
5 
6 class QuantumCircuit;
7 class QuantumGateBase;
9 
17 private:
18  QuantumCircuit* circuit;
19  UINT get_rightmost_commute_index(UINT gate_index);
20  UINT get_leftmost_commute_index(UINT gate_index);
21  UINT get_merged_gate_size(UINT gate_index1, UINT gate_index2);
22  bool is_neighboring(UINT gate_index1, UINT gate_index2);
23 public:
28 
33 
44  void optimize(QuantumCircuit* circuit, UINT max_block_size=2);
45 
52  QuantumGateMatrix* merge_all(const QuantumCircuit* circuit);
53 };
54 
55 
#define DllExport
Definition: type.hpp:30
Definition: gate_matrix.hpp:9
Definition: circuit.hpp:25
virtual ~QuantumCircuitOptimizer()
Definition: circuit_optimizer.hpp:32
Definition: circuit_optimizer.hpp:16
QuantumCircuitOptimizer()
Definition: circuit_optimizer.hpp:27
Definition: gate.hpp:75