Quantum algorithm for calculation of transition amplitudes in hybrid tensor networks
Abstract
The hybrid tensor network approach allows us to perform calculations on systems larger than the scale of a quantum computer. However, when calculating transition amplitudes, there is a problem that the number of terms to be measured increases exponentially with that of the contracted operators. The problem is caused by the fact that the contracted operators are represented as non-Hermitian operators. In this study, we propose a method for the hybrid tensor network calculation that contracts non-Hermitian operators without an exponential increase in the number of terms. In the proposed method, transition amplitudes are calculated by combining the singular value decomposition of the contracted non-Hermitian operators with a Hadamard test. The method significantly extends the applicability of the hybrid tensor network approach.
I introduction
Quantum computers are expected to be capable of executing classically intractable calculations [1, 2, 3, 4, 5, 6, 7, 8]. It has been reported that quantum computers can outperform classical computers in some tasks [9, 10, 11]. However, quantum resource limitations are obstacles to the practical application of quantum computers. Current quantum computers are so-called noisy intermediate-scale quantum (NISQ) devices [12], and we can control only tens to hundreds of noisy qubits on them [13, 14, 15, 4, 16, 17, 18]. Their hardware limitation makes it difficult to apply quantum computers to practical tasks that require large numbers of qubits or deep quantum circuits [19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31].
The hybrid tensor network approach has recently been proposed to overcome the limitations of NISQ devices [19]. The approach enables the treatment of a larger number of quantum states than the number of qubits of actual quantum devices by representing quantum states as a combination of conventional classical tensors and quantum tensors. A quantum tensor has upper and lower indices, for example, , which represents -qubit systems indexed by an -bit string. In other words, the quantum state is defined in terms of classical bits as
(1) |
where , , and is a computational basis of the -qubit Hilbert space. One of the most vital forms of the hybrid tensor network is the hybrid tree-tensor network, where a network of quantum and classical tensors composes a tree graph. While contraction of general hybrid tensor networks can be costly, hybrid tree-tensor networks can be contracted efficiently to obtain expectation values [19]. In this paper, we mainly discuss a two-layer hybrid tree-tensor network with only quantum tensors, which is called a quantum-quantum tree-tensor network, since it captures the essential properties of hybrid tree-tensor networks and the use of classical tensors restricts the range of representation to classically tractable quantum states such as matrix product states [32]. A quantum-quantum tree-tensor network that expresses subsystems of -qubit states is represented as
(2) |
where is the unnormalized state, is the probability amplitude of a -qubit state , and is an -qubit state of the -th subsystem indexed by a classical bit . Figure 1 shows the network diagram of . While the state represents a -qubit state, we can efficiently calculate the expectation value of an observable , where operates on via proper tensor contractions, using a quantum computer with qubits. The contraction for evaluating the expectation value (without normalization) can be implemented as follows. First, we measure with multiple states and construct operators . Note that each is a Hermitian matrix when is Hermitian. Then, since is Hermitian, we can measure the expectation value of for the state , which is equal to .

The approach allows for simulations beyond the scale of the quantum hardware. For example, the energy and spin-spin correlation functions of electrons can be calculated with this approach. However, the approach has a serious problem preventing it from being used in a range of applications: it can only calculate the expectation value of observables. In other words, there is a problem in the approach when the contracted operator is non-Hermitian. Hereinafter, we denote the Hermitian and non-Hermitian contracted operators as and , respectively. The reason for the problem is that the number of terms to be measured increases exponentially with when is calculated naively. Specifically, non-Hermitian operators are decomposed into sums of Pauli operators, as in , where is the identity operator, , , and are Pauli operators which act on the -th qubit, and are the corresponding coefficients, with up to terms appearing. One example where the problem occurs is in the calculation of the transition amplitude related to Green’s functions and photon emissions/absorptions [33, 34]. Overlap of two quantum states, which is exploited in subroutines in many algorithms [35, 36, 37, 38], is a special case of the transition amplitude. Thus, the difficulty of computing the expectation value of a non-Hermitian operator limits the applicability of the hybrid tensor network approach.
In this study, we propose a method for calculating transition amplitudes with the hybrid tensor network approach. The main point of the method is the treatment of tensor products of non-Hermitian operators. In a naive calculation, an exponential number of terms in will appear. We propose two ways to avoid the problem. One is a Monte-Carlo contraction method and the other is a singular value decomposition (SVD) contraction method, and the second method is the main proposal in this paper. Although the first method can avoid having to measure all the terms whose number increases exponentially with , the second method is exponentially more efficient than the first one in terms of the sampling cost.
In the following, we give an overview of quantum-quantum tree-tensor networks [19] for obtaining the expectation values of observables in Sec. II. Then, the method of calculating transition amplitudes and overlaps is described in Sec. III; the contraction of quantum tensors in subsystems is discussed in Sec. III.1 and the contraction of non-Hermitian matrices in Sec. III.2. We discuss the future applications of the method in Sec. IV.
II Overview of the hybrid tensor network
We present an overview of the hybrid tensor network simulation on the state described by Eq. (2) introduced in Ref. [19]. Letting the observable be and (), the expectation value of the observable including the normalization constant can be described as
(3) | ||||
and
(4) | ||||
where is a normalization constant, with taking either or , , and . () is an element of the matrix (). When is assumed to be an observable, i.e., a Hermitian operator, also becomes a Hermitian operator. is a Hermitian operator since is a special case of in , where is the identity operator.
The procedure for constructing and depends on how the indices of the wave function are mapped. We suppose there are two cases of the mapping; one case is where the indices are mapped to unitary gates, i.e., ; the other case is where the indices are mapped to the initial wave function as , where and are unitary operators with polynomial depth in the -th subsystem. The second case can be regarded as a special example of the first case, since and we can think of as , where is a Pauli operator which acts on the first qubit. Note that the first method needs a Hadamard test circuit while and can be efficiently constructed via direct measurements in the second case, as will be described later.
First, we consider the construction of in the case of . Since the procedure for measuring the diagonal elements is relatively straightforward, we will focus on the measurement of the non-diagonal elements. Figure 2(a) shows a quantum circuit to obtain the matrix element . The procedure for constructing is as follows. First, we prepare initial states. We use a Hadamard test to prepare and . The ancilla qubit is initialized to , where is the phase. We set () to obtain the real (imaginary) part of . Since is a Hermitian matrix, only measurements of , and are required. Then, we measure on a computational basis. We use the fact that is a Hermitian operator and has a spectral decomposition: , where is a unitary matrix and is a diagonal matrix. Also, we assign elements of to the measurement results. More concretely, denoting , the measured value is computed as corresponding to the measured outcome .

We explain how to construct . Figure 2(b) shows the circuit to construct . In the case of , since the are non-orthogonal to each other, we have . Therefore, must be calculated. The circuit in Fig. 2(b) is a modified version of that in Fig. 2(a), except that system measurements are not necessary; we can construct by using the same construction procedure as for .
Next, we assume the case of . In this case, we can obtain all the elements of only from the results of direct measurements. Figure 2(c) shows a quantum circuit to construct . The initial states are set to , where takes four states as , , and . can be obtained using the corresponding measurement results. Refer to Appendix A for the details of the procedure. Also, since is orthogonal, and does not have to be calculated.
Finally, we show the procedure to obtain , which can be implemented by contracting and . Now, denoting , we can rewrite Eq. (3) as
(5) | ||||
where we have used the fact that is a Hermitian operator and has a spectral decomposition, . Figure 2(d) shows a quantum circuit to measure . Henceforth, we will assume , where is a unitary operator with polynomial depth. We can compute by applying , measuring in a computational basis, and assigning elements of to the measurement results. More concretely, denoting , the measured value is computed as corresponding to the measured outcome . In a similar procedure, we can measure by contracting ; hence, we can obtain .
III Calculation of transition amplitudes and overlaps
We describe the measurement of transition amplitudes with the hybrid tensor network approach. The difference from Sec. II is that we need to contract a non-Hermitian operator .

III.1 Contraction of quantum tensors in subsystems
This section describes construction of in the calculation of in the transition amplitudes and that of in the overlaps, where and are two different states represented by a quantum-quantum tensor network.
To begin with, we will consider the calculation of the transition amplitude because the overlap is a special case of in the transition amplitude, where is the identity operator. We will comment on the overlap at the end of this section. The transition amplitude can be defined as
(6) | ||||
where is a normalization constant corresponding to , , is a matrix with elements of , and . The notation is the same as in Eqs. (3), (4) and (5), except for the superscript , which corresponds to . The reason that is a non-Hermitian matrix comes from the fact that . We will not discuss in the following since the procedure for calculating is the same as the one for in the previous section.
First, let us consider the case of . Figure 3(a) shows the quantum circuit for constructing . The flow of constructing is similar to that of . However, since is a non-Hermitian matrix with elements of complex numbers, eight types of measurement are required to construct . Next, we consider the case of . Figure 3(b) shows a quantum circuit to obtain the matrix element . Specifically, the wave function is initialized by using one of the four types of unitary gates in the lower panel in Fig. 3(b) to prepare the initial states and . The subsequent process is the same as in the case of .
When calculating the overlap , i.e., the case of in Eq. (6), only the circuits to construct (Figs. 3(a) and (b)) differ from the cases of the transition amplitude. Figures 3(c) and (d) shows the circuits in the cases of and , which are the same quantum circuits as in Figs. 3(a) and (b) except that the measurements of the system qubits are not involved. Note that although the calculation of the transition amplitude and the overlap requires the construction of non-Hermitian operators using the ancilla qubit in general, it can be circumvented in the calculation of the square of the overlap by using the destructive SWAP test [36] (Appendix B for details).
III.2 Contraction of non-Hermitian matrices
The next step is to calculate for non-Hermitian matrices . We describe two methods of contraction: a Monte-Carlo contraction method and an SVD contraction method. In this section, we describe the SVD contraction method because it is exponentially more efficient than the Monte-Carlo contraction method in terms of the sampling cost. Refer to Appendixes C and D for details of the Monte-Carlo contraction method and the comparison of the two methods, respectively.
Now let us describe how to perform the SVD contraction method. We perform SVD for each , that is, , where and are unitary matrices and is a diagonal matrix with non-negative elements. can be described as
(7) | ||||
where is the operator norm of an operator , . We can assume that , where , , and takes a value in a range , without loss of generality.
Figure 3(e) shows the circuit for measuring by using the SVD contraction method. We can compute as follows. We implement a Hadamard test circuit for for obtaining the real or imaginary part of with probability (i.e., 1:1 ratio) by changing the phase of the ancilla qubit. We define and in the cases of measurements of the real and imaginary parts, respectively, where and are the measurement outcomes of the system and ancilla qubits in the -th measurement, respectively. Then, the sum of the total sample averages of each of and approximates .
Letting denote the sample average of a random variable , denotes the expected value of , and = approximates . Denoting the number of measurements as and assuming , we have
(8) |
Thus, we have
(9) |
for the required accuracy .
We mention that is expected not to increase exponentially with if is large enough. Here, we consider the case where the measured observable is a product of Pauli operators. This is because in the conventional variational quantum eigensolver (VQE) [13] scenario, we decompose the Hermitian operator of interest into a linear combination of a polynomial number of products of Pauli operators with the system size. We numerically generate four types of random unitary matrices, , , , and , and a product of random Pauli operators, , and create a matrix consisting of elements , where and take 0 or 1. Then, we evaluate the average values of obtained using samples of . As a result, we obtain , including error bars when (See Appendix D for details). Therefore, if is large enough, will be valid.
Additionally, we should note that in the case of , is strictly satisfied regardless of . In this case, since can be regarded as a submatrix of the unitary matrix as , we have . Thus, because we have assumed here, we have regardless of .
IV Conclusion
We proposed a method to calculate transition amplitudes using a hybrid tensor network. When the hybrid tensor network approach is naively applied to the transition amplitude calculation, the contracted operators become non-Hermitian, and the number of terms to be measured increases exponentially. Our method obtains the expectation value without increasing the number of terms exponentially by using singular value decomposition and a Hadamard test. Our theory can be easily generalized to cases with a mixture of classical and quantum tensors called quantum-classical and classical-quantum tree-tensor networks, and those with deeper tree structures. Moreover, we can easily extend the scenario to the case where the measured operator is a tensor product of non-Hermitian operators by using the SVD contraction method. This study significantly expands the applicability of the hybrid tensor network.
Future work includes the application of our method to algorithms related to hybrid tensor networks. For example, Deep VQE, [20, 21], which is a large-scale computational algorithm for NISQ devices based on the divide and conquer method, can be treated in the framework of hybrid tensor networks in theory. By applying the proposed method to such algorithms, we can extend the range of applications to various large-scale quantum algorithms.
V Acknowledgments
This work is supported by PRESTO, JST, Grants No. JPMJPR1916 and No. JPMJPR2114; ERATO, JST, Grant No. JPMJER1601; CREST, JST, Grant No. JPMJCR1771; Moonshot R&D, JST, Grant No. JPMJMS2061; MEXT Q-LEAP Grant No. JPMXS0120319794 and JPMXS0118068682. S.E. acknowledges useful discussions with Jinzhao Sun and Xiao Yuan.
References
- Bharti et al. [2021] K. Bharti, A. Cervera-Lierta, T. H. Kyaw, T. Haug, S. Alperin-Lea, A. Anand, M. Degroote, H. Heimonen, J. S. Kottmann, T. Menke, W.-K. Mok, S. Sim, L.-C. Kwek, and A. Aspuru-Guzik, (2021), arXiv:2101.08448 [quant-ph] .
- Cerezo et al. [2020] M. Cerezo, A. Arrasmith, R. Babbush, S. C. Benjamin, S. Endo, K. Fujii, J. R. McClean, K. Mitarai, X. Yuan, L. Cincio, and P. J. Coles, (2020), arXiv:2012.09265 [quant-ph] .
- Cao et al. [2019] Y. Cao, J. Romero, J. P. Olson, M. Degroote, P. D. Johnson, M. Kieferová, I. D. Kivlichan, T. Menke, B. Peropadre, N. P. D. Sawaya, S. Sim, L. Veis, and A. Aspuru-Guzik, Chem. Rev. 119, 10856 (2019).
- Endo et al. [2021] S. Endo, Z. Cai, S. C. Benjamin, and X. Yuan, J. Phys. Soc. Jpn. 90, 032001 (2021).
- Shikano et al. [2020] Y. Shikano, H. C. Watanabe, K. M. Nakanishi, and Y.-Y. Ohnishi, (2020), arXiv:2011.01544 [quant-ph] .
- McArdle et al. [2020] S. McArdle, S. Endo, A. Aspuru-Guzik, S. C. Benjamin, and X. Yuan, Rev. Mod. Phys. 92, 015003 (2020).
- Bauer et al. [2020] B. Bauer, S. Bravyi, M. Motta, and G. Kin-Lic Chan, Chem. Rev. 120, 12685 (2020).
- Moll et al. [2018] N. Moll, P. Barkoutsos, L. S. Bishop, J. M. Chow, A. Cross, D. J. Egger, S. Filipp, A. Fuhrer, J. M. Gambetta, M. Ganzhorn, A. Kandala, A. Mezzacapo, P. Müller, W. Riess, G. Salis, J. Smolin, I. Tavernelli, and K. Temme, Quantum Sci. Technol. 3, 030503 (2018).
- Arute et al. [2019] F. Arute, K. Arya, R. Babbush, D. Bacon, J. C. Bardin, R. Barends, R. Biswas, S. Boixo, F. G. S. L. Brandao, D. A. Buell, B. Burkett, Y. Chen, Z. Chen, B. Chiaro, R. Collins, W. Courtney, A. Dunsworth, E. Farhi, B. Foxen, A. Fowler, C. Gidney, M. Giustina, R. Graff, K. Guerin, S. Habegger, M. P. Harrigan, M. J. Hartmann, A. Ho, M. Hoffmann, T. Huang, T. S. Humble, S. V. Isakov, E. Jeffrey, Z. Jiang, D. Kafri, K. Kechedzhi, J. Kelly, P. V. Klimov, S. Knysh, A. Korotkov, F. Kostritsa, D. Landhuis, M. Lindmark, E. Lucero, D. Lyakh, S. Mandrà, J. R. McClean, M. McEwen, A. Megrant, X. Mi, K. Michielsen, M. Mohseni, J. Mutus, O. Naaman, M. Neeley, C. Neill, M. Y. Niu, E. Ostby, A. Petukhov, J. C. Platt, C. Quintana, E. G. Rieffel, P. Roushan, N. C. Rubin, D. Sank, K. J. Satzinger, V. Smelyanskiy, K. J. Sung, M. D. Trevithick, A. Vainsencher, B. Villalonga, T. White, Z. J. Yao, P. Yeh, A. Zalcman, H. Neven, and J. M. Martinis, Nature 574, 505 (2019).
- Zhong et al. [2020] H.-S. Zhong, H. Wang, Y.-H. Deng, M.-C. Chen, L.-C. Peng, Y.-H. Luo, J. Qin, D. Wu, X. Ding, Y. Hu, P. Hu, X.-Y. Yang, W.-J. Zhang, H. Li, Y. Li, X. Jiang, L. Gan, G. Yang, L. You, Z. Wang, L. Li, N.-L. Liu, C.-Y. Lu, and J.-W. Pan, Science 370, 1460 (2020).
- Wu et al. [2021] Y. Wu, W.-S. Bao, S. Cao, F. Chen, M.-C. Chen, X. Chen, T.-H. Chung, H. Deng, Y. Du, D. Fan, M. Gong, C. Guo, C. Guo, S. Guo, L. Han, L. Hong, H.-L. Huang, Y.-H. Huo, L. Li, N. Li, S. Li, Y. Li, F. Liang, C. Lin, J. Lin, H. Qian, D. Qiao, H. Rong, H. Su, L. Sun, L. Wang, S. Wang, D. Wu, Y. Xu, K. Yan, W. Yang, Y. Yang, Y. Ye, J. Yin, C. Ying, J. Yu, C. Zha, C. Zhang, H. Zhang, K. Zhang, Y. Zhang, H. Zhao, Y. Zhao, L. Zhou, Q. Zhu, C.-Y. Lu, C.-Z. Peng, X. Zhu, and J.-W. Pan, (2021), arXiv:2106.14734 [quant-ph] .
- Preskill [2018] J. Preskill, Quantum 2, 79 (2018).
- Peruzzo et al. [2014] A. Peruzzo, J. McClean, P. Shadbolt, M.-H. Yung, X.-Q. Zhou, P. J. Love, A. Aspuru-Guzik, and J. L. O’Brien, Nat. Commun. 5, 4213 (2014).
- Kandala et al. [2017] A. Kandala, A. Mezzacapo, K. Temme, M. Takita, M. Brink, J. M. Chow, and J. M. Gambetta, Nature 549, 242 (2017).
- Temme et al. [2017] K. Temme, S. Bravyi, and J. M. Gambetta, Phys. Rev. Lett. 119, 180509 (2017).
- Endo et al. [2018] S. Endo, S. C. Benjamin, and Y. Li, Phys. Rev. X 8, 031027 (2018).
- Kandala et al. [2019] A. Kandala, K. Temme, A. D. Córcoles, A. Mezzacapo, J. M. Chow, and J. M. Gambetta, Nature 567, 491 (2019).
- Takagi [2021] R. Takagi, Phys. Rev. Research 3, 033178 (2021).
- Yuan et al. [2021] X. Yuan, J. Sun, J. Liu, Q. Zhao, and Y. Zhou, Phys. Rev. Lett. 127, 040501 (2021).
- Fujii et al. [2020] K. Fujii, K. Mitarai, W. Mizukami, and Y. O. Nakagawa, (2020), arXiv:2007.10917 [quant-ph] .
- Mizuta et al. [2021] K. Mizuta, M. Fujii, S. Fujii, K. Ichikawa, Y. Imamura, Y. Okuno, and Y. O. Nakagawa, (2021), arXiv:2104.00855 [quant-ph] .
- Takeshita et al. [2020] T. Takeshita, N. C. Rubin, Z. Jiang, E. Lee, R. Babbush, and J. R. McClean, Phys. Rev. X 10, 011004 (2020).
- Yamazaki et al. [2018] T. Yamazaki, S. Matsuura, A. Narimani, A. Saidmuradov, and A. Zaribafiyan, (2018), arXiv:1806.01305 [quant-ph] .
- Bauman et al. [2019] N. P. Bauman, E. J. Bylaska, S. Krishnamoorthy, G. H. Low, N. Wiebe, C. E. Granade, M. Roetteler, M. Troyer, and K. Kowalski, J. Chem. Phys. 151, 014107 (2019).
- Kottmann et al. [2021] J. S. Kottmann, P. Schleich, T. Tamayo-Mendoza, and A. Aspuru-Guzik, J. Phys. Chem. Lett. 12, 663 (2021).
- Huggins et al. [2019] W. Huggins, P. Patil, B. Mitchell, K. Birgitta Whaley, and E. Miles Stoudenmire, Quantum Sci. Technol. 4, 024001 (2019).
- Cong et al. [2019] I. Cong, S. Choi, and M. D. Lukin, Nat. Phys. 15, 1273 (2019).
- Kim [2017] I. H. Kim, (2017), arXiv:1702.02093 [quant-ph] .
- Liu et al. [2019] J.-G. Liu, Y.-H. Zhang, Y. Wan, and L. Wang, Phys. Rev. Research 1, 023025 (2019).
- Foss-Feig et al. [2020] M. Foss-Feig, D. Hayes, J. M. Dreiling, C. Figgatt, J. P. Gaebler, S. A. Moses, J. M. Pino, and A. C. Potter, (2020), arXiv:2005.03023 [quant-ph] .
- Eddins et al. [2021] A. Eddins, M. Motta, T. P. Gujarati, S. Bravyi, A. Mezzacapo, C. Hadfield, and S. Sheldon, (2021), arXiv:2104.10220 [quant-ph] .
- Schollwöck [2011] U. Schollwöck, Ann. Phys. 326, 96 (2011).
- Endo et al. [2020] S. Endo, I. Kurata, and Y. O. Nakagawa, Phys. Rev. Research 2, 033281 (2020).
- Ibe et al. [2020] Y. Ibe, Y. O. Nakagawa, N. Earnest, T. Yamamoto, K. Mitarai, Q. Gao, and T. Kobayashi, (2020), arXiv:2002.11724 [quant-ph] .
- Romero et al. [2017] J. Romero, J. P. Olson, and A. Aspuru-Guzik, Quantum Sci. Technol. 2, 045001 (2017).
- LaRose et al. [2019] R. LaRose, A. Tikku, É. O’Neel-Judy, L. Cincio, and P. J. Coles, npj Quantum Information 5, 1 (2019).
- Jones et al. [2019] T. Jones, S. Endo, S. McArdle, X. Yuan, and S. C. Benjamin, Phys. Rev. A 99, 062304 (2019).
- Higgott et al. [2019] O. Higgott, D. Wang, and S. Brierley, Quantum 3, 156 (2019).
Appendix A Construction of in the case where indices are mapped to initial wave functions
We explain the procedure of constructing in the case of by using the circuit in Fig. 2(c). The diagonal elements, and , can be easily obtained by measuring the expectation values of for and because and , respectively. We can also obtain non-diagonal elements by combining four types of measurement results. By setting and , we have
(10) |
and
(11) |
Then, we can obtain the non-diagonal elements by
(12) | ||||
and .
Appendix B Calculation of the square of overlaps without the ancilla qubit
In this section, we show the procedure of the calculation for the square of overlaps by using the destructive SWAP test without using the ancilla qubit. The main point of the procedure is that we regard as the expectation value of the SWAP operator for the state , where and are two different states represented by a quantum-quantum tensor network. Since the SWAP operator is an observable, we can calculate by following almost the same procedure as Sec. II without the ancilla qubit.
Specifically, letting the SWAP operator and and substituting for and for in Eq. (3), the square of overlaps can be obtained from the expectation value as
(13) | ||||
and can be also described as
(14) | ||||
where () with taking either or , and is a matrix with elements of
(15) | ||||
Here, is an observable on -th qubits of and , and is an observable on -th qubits of and . We consider only the case of , and thus we omit the normalization constant.
Figure 4(a) shows a quantum circuit to obtain the matrix element using the destructive SWAP test. The procedure of obtaining the matrix elements is as follows. Firstly, the initial states are set to , where takes four states as , , and . To construct , types of the states are required in total (Table 1). After preparing the states , unitary gates for the measurement consisting of CNOT gates and Hadamard gates are applied. Here, is obtained by the spectral decomposition of as , where is a unitary matrix and is a diagonal matrix. Finally, we assign elements of to the measurement results from each qubit pair.

|
|||
---|---|---|---|
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
Figure 4(b) shows a quantum circuit to construct . We can obtain by preparing , applying unitary gates for the measurement , and assigning elements of to the measurement results from each qubit pair, where , is a unitary matrix, and is a diagonal matrix.
Appendix C Monte-Carlo contraction method
In this section, we introduce a Monte-Carlo contraction method and discuss the sampling cost. We decompose , where is an identity operator, , and are Pauli operators which act on the -th qubit, and are the corresponding coefficients. If we expand the last expression, it has an exponentially increasing number of terms with . To circumvent this problem, a Monte-Carlo implementation can be used to calculate . From now on, for notational simplicity, we will denote , , , , , , , and . Introducing , , , and , we have and
(16) | ||||
Therefore, we can compute as follows. We generate with probability and implement a Hadamard test circuit for obtaining the real or imaginary part of with probability (i.e., 1:1 ratio) by changing the phase of the ancilla qubit. We define and in the cases of measurements of the real and imaginary parts, respectively, where is the measurement outcomes of the ancilla qubit in the -th measurement. Then, the sum of the total sample averages of each of and approximates .
Below, denotes the sample average of a random variable , denotes the expected value of , and approximates . Denoting the number of measurements as and assuming , we have
(17) |
Thus, we need
(18) |
for the required accuracy .
Appendix D Comparison of Monte-Carlo contraction method and SVD contraction method
Here, we compare with . Since , we have
(19) |
where we have used .
Equations (9), (18), and (19) indicate and
(20) |
Thus, the SVD contraction method is exponentially more efficient than the Monte-Carlo contraction method in terms of the sampling cost.
We present numerical calculations for in order to check the superiority of the SVD contraction method over the Monte-Carlo contraction method. We obtain samples of and by the procedure in Sec. III.2 and from the Pauli decomposition of . Fig. 5(a) shows the average of the ratio ; we found that the average value is about for any . Therefore, from Eq. (20) and the result in Fig. 5(a), we can conclude that the SVD contraction method is expected to be times faster on average than the Monte-Carlo contraction method.
We also numerically evaluate the number of measurements for the two methods. The averages of and are shown in Fig. 5(b). and in and , respectively, can be considered to be less than 1, including the standard deviation. Thus, we expect and ; that is, and are not expected to increase exponentially with , if is large enough.
