††thanks: These two authors contributed equally.††thanks: These two authors
contributed equally.††thanks: These two authors contributed equally.

# Quantum sequential scattering model for quantum state learning

Mingrui Jing  Thrust of Artificial Intelligence, Information Hub, Hong Kong
University of Science and Technology (Guangzhou), Nansha, China  Institute for
Quantum Computing, Baidu Research, Beijing 100193, China  Geng Liu  Thrust of
Artificial Intelligence, Information Hub, Hong Kong University of Science and
Technology (Guangzhou), Nansha, China  Institute for Quantum Computing, Baidu
Research, Beijing 100193, China  Hongbin Ren  Institute for Quantum Computing,
Baidu Research, Beijing 100193, China  Xin Wang<EMAIL_ADDRESS>Thrust of Artificial Intelligence, Information Hub, Hong Kong University of
Science and Technology (Guangzhou), Nansha, China  Institute for Quantum
Computing, Baidu Research, Beijing 100193, China

###### Abstract

Learning probability distribution is an essential framework in classical
learning theory. As a counterpart, quantum state learning has spurred the
exploration of quantum machine learning theory. However, as dimensionality
increases, learning a high-dimensional unknown quantum state via conventional
quantum neural network approaches remains challenging due to trainability
issues. In this work, we devise the quantum sequential scattering model
(QSSM), inspired by the classical diffusion model, to overcome this
scalability issue. Training of our model could effectively circumvent the
vanishing gradient problem to a large class of high-dimensional target states
possessing polynomial-scaled Schmidt ranks. Theoretical analysis and numerical
experiments provide evidence for our model’s effectiveness in learning both
physical and algorithmic meaningful quantum states and show an out-performance
beating the conventional approaches in training speed and learning accuracy.
Our work has indicated that an increasing entanglement, a property of quantum
states, in the target states, necessitates a larger scaled model, which could
reduce our model’s learning performance and efficiency.

##  I Introduction

The innovation of classical machine learning has brought significant
convenience and efficiency in industry and society. In particular, learning
distributions between individual events and data is one of the crucial tasks
for multiple usages in decades Anderson  _et al._ (1977); Geng (2016). A
plethora of approaches and schemes have been designed to learn probability
distributions, such as continuous evolutionary algorithms Hansen  _et al._
(2015); Kern  _et al._ (2004) and supervised learning within the neural
network framework including Boltzmann machine, graph neural network and
diffusion model Baum and Wilczek (1987); Franceschi  _et al._ (2019);
Hoogeboom  _et al._ (2021)

Meanwhile, by the fast growth of the requirement on computational power,
quantum computing, as a prospective new framework, is expected to provide
advantages over classical technology. The remarkable achievements from
classical machine learning models LeCun  _et al._ (2015); Serban  _et al._
(2016) have spurred the generation of their counterparts within the field of
quantum machine learning (QML). See Refs. Biamonte  _et al._ (2017); Schuld
_et al._ (2015); Lloyd  _et al._ (2013); Schuld  _et al._ (2014); Cerezo  _et
al._ (2022); Abbas  _et al._ (2021); Du  _et al._ (2023); Yu  _et al._ (2022);
Chowdhury  _et al._ (2020); Ghosh  _et al._ (2019); Wang  _et al._ (2021a) for
reviews and recent progresses. Quantum neural networks (QNNs) composed of
layers of parametrised quantum circuits have received massive attention
regarding various architectures addressing computation challenges Rebentrost
_et al._ (2018); Zhao  _et al._ (2019); Cong  _et al._ (2019), including
quantum state learning.

In quantum, the correlations between quantum data are encoded in the quantum
states. Consequently, the task of learning an arbitrary quantum state bears a
resemblance to classical distribution learning, which has inspired
developments of state learning QML models Chowdhury  _et al._ (2020); Ghosh
_et al._ (2019); Wang  _et al._ (2021a). As a main solution to quantum state
learning, however, the implementation of the QNN-based methods suffers
obstacles in efficiency, scalability and trainability. Specifically, training
deep QNNs composed of multiple layers can experience exponentially vanishing
gradients, or called barren plateaus (BP) McClean  _et al._ (2018) when
targeting high-dimensional states.

This work proposed a quantum sequential scattering model (QSSM) to overcome
this bottleneck in QNN-powered state learning techniques. We provide both
theoretical and numerical demonstrations of QSSM on training efficiency and
learning accuracy, which can outperform the conventional QNN model using
universal layers. Recent research on the trainability issue of QNNs indicates
prospective directions by reducing the expressibility of QNN architectures
Cerezo  _et al._ (2021); Liu  _et al._ (2022a), adopting clever
parameterization strategies Grant  _et al._ (2019); Kulshrestha and Safro
(2022); Volkoff and Coles (2021); Friedrich and Maziero (2022) and using
adaptive algorithms Grimsley  _et al._ (2019); Zhang  _et al._ (2021); Skolik
_et al._ (2021); Grimsley  _et al._ (2022).

We drew inspiration from the classical diffusion model Yang  _et al._ (2022)
by conducting the state learning with progressively augmenting sublevels in a
sequential manner. Our model combines the ideas of quantum purification theory
and adaptive and layerwise training Quek  _et al._ (2021); Skolik  _et al._
(2021) for which the training process can be treated as the dilation of
quantum information from subsystems to the entire one. The structure of the
model ensures a dramatic reduction in the number of optimized parameters at
each training step and, therefore, avoids barren plateaus for a large class of
target states.

Our work is presented in the following order: We first introduce the basic
notations and definitions in Section II. In Section III, we present the
theoretical guarantee of the QSSM in view of information diffusion and
trainability. Then, we explicitly describe our QSSM processing state learning
task IV, including the algorithm optimization and gradient estimations. In
Section V, we illustrate the numerical simulations on the effectiveness and
trainability of the model learning both physical and algorithmic meaningful
states. Noisy simulations are also provided. Conclusion and outlook will be
given in Section VI.

##  II Preliminaries

###  II.1 Classical Distribution learning

We briefly introduce the formalism concerning classical probability
distribution learning. Correlations between discrete data variables, denoted
as $X$, can be characterized by some probability distributions $D$ Kearns  _et
al._ (1994). The learning of such a distribution can be described as
constructing a generator $G_{D^{\prime}}$ that takes $x\in X$ as an argument
and outputs $G_{D^{\prime}}[x]\in X$ with respect to a distribution
$D^{\prime}$. The generator can be realized via a classical machine learning
model, which is trained to achieve $d(D,D^{\prime})\leq\varepsilon$ for some
legal metric $d$, e.g., Kullback-Leibler divergence Csiszar (1975), and a
threshold error $\varepsilon$.

###  II.2 Quantum State Learning

A typical quantum state learning task for an unexplored target state $\rho$,
as a density matrix, solves for a generator that can be efficiently
constructed to produce a representation $\rho^{\prime}$ which ${\cal
D}(\rho,\rho^{\prime})\leq\varepsilon$ resembling classical distribution
learning. Here ${\cal D}$ is a feasible distance measure on matrix space. Such
a generator can veritably produce $\rho^{\prime}$ instead of numerically
simulating it Vidal (2003) and can be repeatedly used in further computational
tasks. This work focuses on the QNN-powered algorithms combining both
classical and quantum computation. Utilizing parameterized quantum circuits
working as the state generators that are trained by gradient descent or
gradient-free methods to determine the optimal parameters Peruzzo  _et al._
(2014); Kandala  _et al._ (2017). Beyond our scope, schemes using shadow
tomography Aaronson (2018); Huang (2022) fulfil another category of state
learning with the aim of characterizing the classical information of quantum
states.

###  II.3 Quantum Computing & QNN layers

Quantum information is encoded and processed via the fundamental cells,
namely, qubits. An $n$-qubit state can be mathematically represented by a
$2^{n}\times 2^{n}$ positive semi-definite density matrix $\rho$, i.e.,
$\rho\succeq 0$ over the complex field and $\operatorname{Tr}[\rho]=1$. A pure
state, in this formulation, satisfy $\operatorname{Rank}{(\rho)}=1$ and can be
expressed in Dirac bra-ket notation as $\rho=|\psi\rangle\\!\langle\psi|$
where $|\psi\rangle\in{{\mathbb{C}}}^{2^{n}}$ denotes a Hilbert space unit
column vector with the corresponding dual vector
$\langle\psi|^{\dagger}=|\psi\rangle$ and $\dagger$ denoting the complex
conjugate transpose operation. A mixed state satisfies
$\operatorname{Rank}{(\rho)}>1$, and based on Spectral theorem, it has a
decomposition form $\rho=\sum_{j}p_{j}|\psi_{j}\rangle\\!\langle\psi_{j}|$
where $p_{j}>0$ denotes the probability of observing
$|\psi_{j}\rangle\\!\langle\psi_{j}|$ in $\rho$ and $\sum_{j}p_{j}=1$.

The evolution of a quantum state $\rho$ is realized by applying a series of
quantum gates which are mathematically described as unitary operators. The
state $\rho^{\prime}$ that undergoes transformation via a quantum gate $U$ can
be obtained through direct matrix multiplication, expressed as
$\rho^{\prime}=U\rho U^{\dagger}$. Common single-qubit gates include the Pauli
rotations $\\{R_{P}(\theta)=e^{-i\frac{\theta}{2}P}|P\in\\{X,Y,Z\\}\\}$, which
are in the matrix exponential form of Pauli matrices

$X\mathrel{\mathop{\mathchar 58\relax}}=\begin{pmatrix}0&1\\\
1&0\end{pmatrix},Y\mathrel{\mathop{\mathchar 58\relax}}=\begin{pmatrix}0&-i\\\
i&0\end{pmatrix},Z\mathrel{\mathop{\mathchar 58\relax}}=\begin{pmatrix}1&0\\\
0&-1\end{pmatrix}.$ (1)

Multi-qubit gates, e.g., controlled-$X$ gate CX (or CNOT) $=I\oplus X$ and
controlled-$Z$ gate CZ$=I\oplus Z$ where ‘$\oplus$’ denotes the direct sum
operation live in high-dimensional linear operator space over
${{\mathbb{C}}}$. Quantum measurements working as projections are applied at
the end of the quantum circuits. Quantum neural networks are usually formed by
layers of parameterized circuits shown in Fig. 1 consisting of a bunch of
single-qubit gates and several two-qubit gates.

$\Qcircuit<EMAIL_ADDRESS>d\\\
\qw\gate{U3(\bm{\theta}_{1})}\ctrl{1}\qw\gate{U3(\bm{\theta}_{5})}\ctrl{1}\qw\gate{U3(\bm{\theta}_{9})}\qw\qw\\\
\qw\gate{U3(\bm{\theta}_{2})}\targ\ctrl{1}\gate{U3(\bm{\theta}_{6})}\targ\ctrl{1}\gate{U3(\bm{\theta}_{10})}\qw\qw\\\
\qw\gate{U3(\bm{\theta}_{3})}\ctrl{1}\targ\gate{U3(\bm{\theta}_{7})}\ctrl{1}\targ\gate{U3(\bm{\theta}_{11})}\qw\qw\\\
\qw\gate{U3(\bm{\theta}_{4})}\targ\qw\gate{U3(\bm{\theta}_{8})}\targ\qw\gate{U3(\bm{\theta}_{12})}\qw\qw\gategroup{2}{4}{5}{9}{1.3em}{--}\\\
}$
Fig 1: The general architecture of the QNN layers used for quantum state
learning. The U3-gates can be decomposed as a combination of
$R_{Z}(\phi_{1})R_{X}(-\pi/2)R_{Z}(\theta_{1})R_{X}(\pi/2)R_{Z}(\lambda_{1})$
where the parameter vector
$\bm{\theta}_{1}=(\theta_{1},\phi_{1},\lambda_{1})$. The layer consists of
CNOT gates and U3 gates. The dashed block circuit repeats $d$ times as the
depth of the layer. The above has a layer width $w=4$, which applies to $4$
quantum registers. In reality, the above circuit diagram represents a way of
applying quantum gates sequentially in order from left to right.

##  III Main Results

In this paper, we design a quantum sequential scattering model (QSSM)
absorbing the ideas of classical diffusion model and adaptive learning Quek
_et al._ (2021), which has modular structured parametrised circuits, or we
called the scattering layer, at each training step. Each layer ensures
learning the reduced density matrix of a specific part in the target state so
that the model can gradually rebuild the entire state after accomplishing all
training steps.

Our main contributions involve (1) conceptually proposing the idea of
combining quantum information diffusion and adaptive quantum state learning,
(2) technically devising a new quantum neural network model, namely QSSM and
the state learning algorithm via a sequentially subsystem-learning strategy,
(3) theoretically proving the effectiveness of the state learning algorithm
and a polynomial-scaled gradient variance of QSSM which indicates an avoidance
of barren plateaus for rank-restricted state learning, (4) numerically
demonstrating our results on learning different quantum states involving the
noise effects. We compare QSSM directly to the conventional QNN model for
handling state learning tasks and showcase its enhancement in both training
efficiency and learning accuracy. The main results are presented in the
following sections.

###  III.1 Quantum Sequential State Compositing

Quantum states are represented in a multiple-qubit system with a fixed order.
We treat each qubit as a quantum register, just like classical bit and
classical register, and label it $q_{k}$ for the $k$-th register. We then
define a special characteristic for quantum states.

###### Definition 1

Given an $n$-qubit quantum state $\rho$ represented by $n$ ordered quantum
registers labeled as $q_{1},q_{2},\cdots,q_{n}$, denoting $\rho_{k}$ as the
$k$-th reduced density matrix of the first $k$-register state, i.e.,
$\rho_{k}=\operatorname{Tr}_{q_{k+1}\mathrel{\mathop{\mathchar
58\relax}}q_{n}}[\rho]$ for $1\leq k\leq n$ where the operation
$\operatorname{Tr}_{q_{i}\mathrel{\mathop{\mathchar 58\relax}}q_{j}}[\cdot]$
representing a partial tracing over registers $q_{i}$ to $q_{j}$, the
(Schmidt) rank sequence of $\rho$ is an ordered list ${\cal R}_{\rho}$,

${\cal R}_{\rho}=\\{r_{1},r_{2},\cdots,r_{n-1},r_{n}\\},$ (2)

where $r_{k}$ indicates $\operatorname{Rank}[\rho_{k}]$. In particular, if
$\rho$ is pure, then $r_{n}=1$ since $\rho$ can be represented as
$|\phi\rangle\\!\langle\phi|$ for some pure state vector $|\phi\rangle$.

With these clarified, we could then present our sufficient and necessary
conditions for QSSM to completely learn a target state using Algorithm 1,
provided enough training time and layer width. Our analysis will concentrate
on the pure target state $\rho$. However, the statement applies to the cases
of mixed target states i.e., $\operatorname{Rank}[\rho]>1$, since we could
equivalently learn its purification state by introducing auxiliary systems.
The formal version of Proposition 1 can be found in Appendix B.

###### Proposition 1

For a given $n$-qubit pure target state $\rho$ represented by $n$ ordered
quantum registers $q_{1},q_{2},\cdots,q_{n}$, if the rank sequence of $\rho$
is ${\cal R}_{\rho}=\\{r_{1},r_{2},\cdots r_{n-1},r_{n}\\}$. Then there exists
a quantum algorithm 1, based on QSSM, that could produce a state $\sigma$
exactly satisfying $\sigma=\rho$, if and only if the $k$-th scattering layer
$U_{k}(\bm{\theta}_{k})$ of QSSM has a width $w_{k}$ scales ${\cal
O}(\lceil\log_{2}r_{k}\rceil)$.

We see that the width of each scattering layer scales only logarithmic
regarding the target states’ rank sequence. In general, even the rank of
quantum pure state scales ${\cal O}(2^{\lceil n/2\rceil})$, the logarithmic
scaling in $w_{k}$ still guarantees a linear growth in the requirement of
layer width concerning the number of qubits $n$, in the worst case.

Moreover, though many quantum states have full rank, there is a polynomial
number of dominant components in their spectral decomposition. Learning their
low-rank approximation pre-determined by the quantum principal component
analysis (QPCA) Lloyd  _et al._ (2014) can be treated as a quantum compressing
of unknown states, which still captures the main statistical behaviours of
target states. With a certain error tolerance for the low-rank approximation,
the layer width can be further reduced, leading to more advantages in QSSM
state learning. In the Numerical Simulations (Section V), we provide evidence
of learning different states’ rank-restricted approximation.

Compared to the $n$-qubit universal-QNN model state learning, QSSM demands
significantly fewer parametric degrees of freedom (DOF) to reach the same
approximating error. The generating Lie algebra of an $n$-qubit universal QNN
model has to span $\mathrm{SU}(2^{n})$, resulting in a model DOF of
$\mathcal{O}(4^{n})$. On the contrary, since the $k$-th scattering layer
involves at most $(\lfloor\frac{n}{2}\rfloor+1)$ quantum registers, the total
DOF of QSSM experiences a quadratic reduction to at most
$\mathcal{O}(4^{\lfloor\frac{n}{2}\rfloor})$. Also, to learn the polynomial
rank-bounded target state $\rho$, i.e., $r_{\max}=\max{\cal R}_{\rho}\sim{\cal
O}(\operatorname{Poly}(n))$. The DOF required for each scattering layer in
QSSM scales ${\cal O}(\operatorname{Poly}(n))$. Therefore, the entire model
comprises fewer quantum gates, rendering this approach considerably more
hardware-efficient.

###  III.2 Avoiding Barren Plateaus

Trainability is a critical challenge for the usage of quantum neural networks.
Using a global deep QNN model brings stronger expressibility despite
significantly increasing the randomness of initialization. Therefore, the
initial gradient of trainable parameters in the model would exponentially
vanish as the system scales up, called the Barren Plateau (BP) issue McClean
_et al._ (2018).

With the diffusion of local quantum state information, QSSM has illustrated a
potential to address trainability issues by focusing on subsystems in each
scattering layer instead of the whole state. From the perspective of adaptive
learning, we align the reduced quantum states of the $k$-th subsystem by
minimizing the $k$-th adaptive cost function of (3) during the respective
layer training,

$\displaystyle C_{k}(\bm{\theta})$
$\displaystyle=\|{\sigma}_{k}(\bm{\theta})-\rho_{k}\|^{2}_{2}$ (3)
$\displaystyle=\operatorname{Tr}\left[\left({\sigma}_{k}(\bm{\theta})-\rho_{k}\right)\left({\sigma}_{k}(\bm{\theta})-\rho_{k}\right)^{\dagger}\right],$

where $\|A\|_{2}$ for some linear operator $A$ denotes the Schatten-2 norm,
${\sigma}_{k}(\bm{\theta}_{k})$ and $\rho_{k}$ represent the $k$-th scattering
layer produced state and the $k$-th reduced target state, respectively.

In this section, we show that QSSM has explicit advantages in trainability by
investigating the statistical properties of the partial gradient with respect
to particular layer parameters. For the cost gradient $\partial_{\mu}C_{k}$
regarding the $\mu$-th trainable parameter in the $k$-th scattering layer
denoted as
$U_{k}(\bm{\theta})=U^{(k)}_{+}(\bm{\theta}_{+})e^{-i\theta_{\mu}H_{\mu}}U^{(k)}_{-}(\bm{\theta}_{-})$,
all the parameters in the layer are represented in a parameter vector
$\bm{\theta}=(\bm{\theta}_{+},\theta_{\mu},\bm{\theta}_{-})$, where
$\bm{\theta}_{-}$ and $\bm{\theta}_{+}$ represent the parameters of the
forward and the backward parts within the $k$-th scattering layer having
$e^{-i\theta_{\mu}H_{\mu}}$ centralized. The results are summarized.

###### Proposition 2

Given the state learning algorithm stated in Proposition 1, for an $n$-qubit
pure target state $\rho$ represented by $n$ ordered quantum registers
$q_{1},q_{2},\cdots,q_{n}$ with a rank sequence ${\cal
R}_{\rho}=\\{r_{1},r_{2},\cdots r_{n-1},r_{n}\\}$, if one of the
$U_{\pm}^{(k)}$ in the $k$-th scattering layer $U_{k}$ forms at least local
unitary $4$-design, the expectation and the variance of $C_{k}$ with respect
to $\theta_{\mu}$ can be upper bounded by,

${{\mathbb{E}}}[\partial_{\mu}C_{k}]=0;\quad{\operatorname{Var}}[\partial_{\mu}C_{k}]\in{\cal
O}\left(\frac{g(\rho_{k})}{r_{k}}\right),$ (4)

where the expectation is computed regarding the Haar measure and the factor
$g(\rho_{k})$ scales polynomially in $\operatorname{Tr}[\rho_{k}^{2}]$ known
as the purity of $\rho_{k}$.

The formal statement of Proposition 2 is presented in Appendix C. This
proposition notably implies that the gradient magnitude is significantly
determined by $r_{\max}$ in ${\cal R}_{\rho}$ rather than the total number of
quantum registers $n$. In other words, the gradient magnitude can escape from
barren plateaus by carefully setting the width of each scattering layer to
adapt to the target state. A typical example is to learn an $n$-qubit GHZ
state, which, by its symmetry, requires setting $w_{k}\leq 2$ for all
scattering layers in QSSM and hence achieves ${\cal O}(1)$ upper bound in the
variance of the gradient.

Moreover, Proposition 2 implies that QSSM can efficiently facilitate the
learning of any pure states with polynomial-scaling $r_{\max}$ in $n$. This
encompasses a broad class of quantum states, including slightly entangled
states Vidal (2003) and matrix product states Perez-Garcia  _et al._ (2006),
which extends the efficient-learnable region of quantum states using quantum
neural network models. Even in the case where $r_{\max}$ scales exponentially,
the gradient magnitude still gains a square root enhancement by the bounded
variance of ${\cal O}(2^{-\lfloor n/2\rfloor})$ compared with the conventional
model, scaling as ${\cal O}(2^{-n})$ to reach the same learning accuracy.

One may also apply the previous statement by allowing the error tolerance on
the state learning and omitting the influence of the tail eigenvalues of the
target states based on QPCA. Therefore, the efficient training condition of
QSSM still applies to the low-rank state approximation learning by fixing a
maximum scattering layer width.

##  IV Quantum sequential scattering model

The fundamental idea of state learning using the quantum sequential scattering
model (QSSM) is to composite the target states by gradually aligning reduced
density matrices of subsystems. The model diffuses the local quantum
information into the global system, which can be considered a quantum analogy
of the classical diffusion model. In contrast, the conventional QNN model
handles the entire system at a time. We now present the overview of our QSSM
with an efficient state learning algorithm.

Suppose we have access to the copies of an $n$-qubit pure target state
$\rho=|\phi\rangle\\!\langle\phi|$ from some other quantum instances. The
target state can be represented in a system containing $n$ ordered quantum
registers. Recalling $\rho_{k}$ as the reduced density matrix on the first $k$
registers, i.e.,
$\rho_{k}=\operatorname{Tr}_{q_{k+1}\mathrel{\mathop{\mathchar
58\relax}}q_{n}}[\rho]$, our model aims to construct a purification
$|\psi_{k}(\bm{\theta}_{k})\rangle=U_{k}(\bm{\theta}_{k})|\psi_{k-1}\rangle$
of $\rho_{k}$ at the $k$-th learning step ($1\leq k\leq n$) by training the
$k$-th scattering layer realized as a parameterised circuit
$U_{k}(\bm{\theta}_{k})$. Notice that the learning results from the previous
step are naturally involved in the state $|\psi_{k-1}\rangle$ having all first
$k$ registers aligned.

The training of each layer is based on minimizing some adaptive cost
functions, which in this work, we use the modified distance function of form 3
where the $k$-th layer output state
$\sigma_{k}(\bm{\theta}_{k})=\operatorname{Tr}_{q_{k+1}\mathrel{\mathop{\mathchar
58\relax}}q_{n}}[|\psi_{k}(\bm{\theta}_{k})\rangle\\!\langle\psi_{k}(\bm{\theta}_{k})|]$.
By hierarchically training the scattering layers until all registers are
aligned, we could then construct the entire target through our trained quantum
sequential scattering model.

Algorithm 1 Quantum sequential scattering model for (pure) state learning

Require: Copies of the $n$-qubit target state
$\rho=|\phi\rangle\\!\langle\phi|$, Cost tolerance $\delta$.
Ensure: The entire model has $n$ quantum registers as
$q_{1},q_{2},\cdots,q_{n}$, and are initialized to $|0\rangle^{\otimes n}$.
Parameter: All layer parameters are randomly initialized regarding Uniform
distribution of $[0,2\pi)$. Set $k=1$ and maximum layer width $w_{\max}$.

1: Update scattering layer width $w_{k}=k+1$,
$|\psi_{k}\rangle=|0\rangle^{\otimes n}$.

2: while $k\leq n$ do

3: if $k\leq\lfloor n/2\rfloor$ then

4: $w_{k}=\min\\{k+1,w_{\max}\\}$.

5: else if $k>\lfloor n/2\rfloor$ then

6: $w_{k}=\min\\{n-k+1,w_{\max}\\}$.

7: end if

8: Apply $U_{k}(\bm{\theta}_{k})$ to the quantum registers indexing $q_{k}$ to
$q_{k+w_{k}-1}$, i.e., $q_{k}\mathrel{\mathop{\mathchar
58\relax}}q_{k+w_{k}-1}$.

9: Minimize $C_{k}(\bm{\theta}_{k})$ via running classical training algorithm
based on the analytic cost function and gradient
$\nabla_{\bm{\theta}_{k}}C_{k}$ evaluations. The minimization stops until the
cost difference reaches $\delta$.

10: $k=k+1$.

11: Update $|\psi_{k}\rangle=U_{k}(\bm{\theta}_{k})|\psi_{k-1}\rangle$.

12: end while

13: Store all optimized $\bm{\theta}_{1},\cdots,\bm{\theta}_{n}$ in classical
memory.

14: return model reconstructed representation $|\psi_{n}\rangle=U_{n}\cdots
U_{1}|0\rangle^{\otimes n}\approx|\phi\rangle$.

Output: The trained QSSM as an approximate state generator
$\mathbf{U}=U_{n}\cdots U_{1}$ of target $|\phi\rangle$.

We summarize our quantum state learning algorithm via QSSM in Algorithm 1.

Fig 2: Effectiveness validation of QSSM in learning diverse $12$-qubit quantum
states regarding their final state fidelities. On the right, we show the QSSM
learnt state (b) from the MINST dataset concerning the original data (a) using
amplitude encoding. With different maximum layer widths, our QSSM outperforms
global QNN on state learning tasks.

###  IV.1 Cost Function Evaluation

As a hybrid quantum-classical model, we declare some details of the
realization of the model in the following. For the adaptive $k$-th step cost
function defined in (3). By rearranging equation (3) as,

$C_{k}(\bm{\theta}_{k})=\operatorname{Tr}[\sigma^{2}_{k}(\bm{\theta}_{k})]+\operatorname{Tr}[\rho^{2}_{k}]-2\operatorname{Tr}[\sigma_{k}(\bm{\theta}_{k})\rho_{k}],$
(5)

which is convex according to Theorem 2.10 of Carlen (2009).We chose this cost
form since it can be efficiently evaluated on quantum hardware. The high-order
state overlap terms involving $\operatorname{Tr}[\rho^{2}]$ and
$\operatorname{Tr}[\rho\sigma]$ can be evaluated via swap test Barenco  _et
al._ (1997), which have been experimentally demonstrated on real quantum
devices Islam  _et al._ (2015); Linke  _et al._ (2018). The training of the
$k$-th layer can be described as finding the $k$-th step optimal parameters
$\bm{\theta}_{k}^{opt}$ so that $C_{k}(\bm{\theta}_{k}^{opt})$ is minimized to
approximately zero. To implement that, classical gradient-based and gradient-
free methods, such as ADAM and COBYLA Kingma and Ba (2014); Powell (1994), can
either be used during optimizations. Other metrics can also be employed in
training procedures, and we left this aspect open for future research.

###  IV.2 Analytic Gradient Evaluation

Further, the analytical gradients of the cost function in (3) can be computed
efficiently, making the gradient-based scheme a prospective candidate for the
training processes. According to Schuld  _et al._ (2018); Mitarai  _et al._
(2018); Ostaszewski  _et al._ (2019); Wang  _et al._ (2021b). Suppose the
$k$-th layer $U_{k}$ consists of the gates satisfying the parameter-shift rule
Mitarai  _et al._ (2018); Schuld  _et al._ (2018) and contains $m$ trainable
parameters. Each optimization iteration is driven by the estimations of cost
gradient given by,

$\nabla_{\bm{\theta}_{k}}C_{k}({\bm{\theta}_{k}})=\Big{(}\partial_{1}C_{k}({\bm{\theta}_{k}}),\cdots,\partial_{m}C_{k}({\bm{\theta}_{k}})\Big{)},$
(6)

where $\partial_{\mu}\mathrel{\mathop{\mathchar
58\relax}}=\frac{\partial}{\partial\theta_{k}^{\mu}}$ indicating the partial
derivative with respect to a fixed $\theta^{\mu}_{k}$ in the $k$-th layer. In
particular, we derive the analytic gradient of $C_{k}$ as follows,

$\partial_{\mu}C_{k}^{*}=\left\langle
G_{k}^{*}\right\rangle_{(\theta_{k}^{\mu})^{*}+\frac{\pi}{2}}-\left\langle
G_{k}^{*}\right\rangle_{(\theta_{k}^{\mu})^{*}-\frac{\pi}{2}}$ (7)

The symbol $*$ indicating the corresponding quantity evaluated at
$\bm{\theta}_{k}=\bm{\theta}_{k}^{*}$. $G_{k}$ is a Hermitian operator
involves both $\sigma_{k}$ and $\rho_{k}$ having an expression,

$G_{k}(\bm{\theta}_{k})\mathrel{\mathop{\mathchar
58\relax}}=\Delta_{k}(\bm{\theta}_{k})\otimes\Gamma_{k}$ (8)

where $\Delta_{k}(\bm{\theta}_{k})=\sigma_{k}(\bm{\theta}_{k})-\rho_{k}$
representing the $k$-th step state difference between two density matrices;
$\Gamma_{k}$ is the maximally mixed state $I/d$ where $I$ is the identity
operator of dimension $d=2^{w_{k}-1}$. $\Gamma_{k}=1$ when $w_{k}=1$. The bra-
ket operation in the analytic form, $\langle
A\rangle_{\alpha}=\langle\psi_{k-1}|U^{\dagger}_{k}(\bm{\theta}_{k})AU_{k}(\bm{\theta}_{k})|\psi_{k-1}\rangle$
for some Hermitian operator $A$ is evaluated at $\theta_{k}^{\mu}=\alpha$.
This quantity of $G_{k}$ in (7) indicates the expectation value of $G_{k}$
regarding the $k$-th step variational ansatz $|\psi_{k}\rangle$ evaluated at
$(\theta_{k}^{\mu})^{*}\pm\pi/2$ where all other scattering layers remain
unchanged. The detailed derivation of these definitions and forms can be found
in Appendix D.

Each partial derivative of $C_{k}$ at $\bm{\theta}_{k}^{*}$ can be explicitly
determined by (7), which can be efficiently computable via shifting the
corresponding parameter and applying variational quantum eigensolver Peruzzo
_et al._ (2014). The gradient-based optimization could be applied to the cost
by specifically updating the parameters $\bm{\theta}_{k}$ in the $k$-th layer
as,

$\bm{\theta}_{k}\leftarrow\bm{\theta}_{k}^{*}-\eta\nabla_{\bm{\theta}_{k}}C_{k}(\bm{\theta}_{k}^{*})$
(9)

where $\eta$ is the learning rate settled for the classical optimizers,
defining the iteration step size. The cost function would converge to the
optimal minimum by iterating the training processes. We then repeat the above
procedures for each $k$-th layer to complete the model training with a final
output circuit representation
$\mathbf{U}(\bm{\theta}^{opt})=U_{n}(\bm{\theta}_{n}^{opt})\cdots
U_{1}(\bm{\theta}_{1}^{opt})$ to finish the state learning.

##  V Numerical Experiments

As described above, the adaptation of our quantum sequential scattering model
indicates the underlying enhancement of information diffusion in quantum state
learning. We now present numerical experiments to illustrate the effectiveness
and trainability of QSSM.

Fig 3: Noisy quantum simulation of QSSM for learning a $4$-qubit GHZ state.
(a) Comparison of the variation of cost function noisy quantum simulation and
noise-free simulation. For both cases, the optimization was processed via
COBYLA optimizer Gomez and Hennart (1994) on swap-test estimated cost values.
(b) The distribution of measurement outcomes generated noise-freely from the
state obtained by the noisy trained QSSM. The figure validates the efficacy
and efficiency of QSSM in noisy environments, consequently reinforcing our
method’s practical applicability.

We first conduct numerical simulations on QSSM for learning 12-qubit quantum
states with physical or algorithmic meaning and compare our results with the
performances from the conventional QNN model. The ground states from
Heisenberg (XXX & XXZ) models Takahashi (1971) and the LiH molecular model are
pre-determined via the OpenFermion library developed by McClean  _et al._
(2020). For the Gaussian distribution and MNIST data learning experiments, the
distribution and image data are normalized and mapped to the unit quantum
state vectors of dimension $2^{n}$ via amplitude encoding Schuld (2021) with
automatic padding of $0$’s filling out the extra grayscale pixels.

In our numerical simulations involving the global QNN and the QSSM, we employ
a general hardware efficient ansatz (HEA) Kandala  _et al._ (2017) of depth
$d=20$ with random initialized parameters for both the global model and each
scattering layer in QSSM. The optimization uses the ADAM optimizer with a
learning rate of $0.1$ and cost tolerance $0.001$, spanning $200$ iterations.

As shown in Fig. 2, comparing the outcomes with those of the global QNN, we
discern clear advantages exhibited by QSSM, which consistently attains notably
high fidelity in learning diverse quantum states. Conversely, the conventional
model does not perform well, primarily due to the significantly decreased
convergence speed during the training processes with a large number of qubits.

Besides, states with exponential growth in Schmidt ranks are not necessarily
hard to learn. Only highly entangled states, e.g., random states and maximally
entangled states (MES) Gisin and Bechmann-Pasquinucci (1998), are challenging
for QSSM. Those with concentrated Schmidt coefficients, though owning large
ranks, can be learnt up to a high fidelity Liu  _et al._ (2022b) with limited
resources.

In Table 2, we reasonably constrain the maximum scattering layer widths to
some fixed values, which counterintuitively yield superior performance with
smaller layer width. Larger values of $w_{\max}$, contrarily, decrease the
QSSM performances of state learning. A plausible explanation for this
phenomenon could be the over-parameterization and the mild BP effect during
the training of the halved-dimensional scattering layers. Notably, learning
random state undoubtedly obtains the worst learning results.

We also examine the noise robustness of using QSSM to learn a $4$-qubit GHZ
state on the IBMQ Qiskit simulator Qiskit contributors (2023). We build our
noise model from single qubit and multi-qubit depolarizing channels (DCs) and
thermal relaxation channels (TRCs) Georgopoulos  _et al._ (2021). The error
rate of DCs are set to $10^{-3}$, and the $T_{1}$, $T_{2}$ and gate time of
TRCs are set to $1000\ \mu\text{s}$, $100\ \mu\text{s}$ and $1\ \text{ns}$
respectively.

At each step, we run the optimization of the QSSM circuit $20$ times in
parallel and use the parameters that correspond to the lowest cost to update
the circuit before going to the next step. This trick can significantly
alleviate the randomness arising from sampling of bit strings in the
measurement of quantum circuits. Shown in Fig. 3, each learning step has cost
converged well compared with the ideal training in (3a). The final fidelity
between the quantum state generated from QSSM and the true GHZ state could
reach 91%, giving almost the same statistical behaviours plotted from the
sampling experiments (3b).

From the analytical description and numerical demonstration, we see that QSSM
has the ability to learn arbitrary quantum states with high fidelity compared
to the conventional model. The diffusion strategy only requires narrow
circuits in learning quantum states that are weakly entangled, thus being
extremely efficient in learning such a class of quantum states.

We then present the result to demonstrate Proposition 2 by comparing the
gradient variances of cost (3) as a function of the number of registers for
QSSM and global QNN model. We typically investigate the values in the first
step, the middle step ($\frac{n}{2}$-th step), and the last step of the QSSM
learning procedure by looking into a single parameter $R_{Z}$ gate in the
middle of each scattering layer. By assuming the two parts $U^{(k)}_{\pm}$
split by the $R_{Z}$ gate are deep enough to form local unitary 4-designs, we
sample local Haar random unitaries Dankert  _et al._ (2009) to simulate the
behaviours of random initialization on $U^{(k)}_{\pm}$ and compute the
gradient variances with respect to the parameter in $R_{Z}$. Similar
experiments are performed for the conventional QNN model by sampling global
Haar unitaries with a $R_{Z}$ gate sandwiched in. We target the GHZ state and
the ground state of the Heisenberg model, as before, with maximum width
$w_{\max}$ being 2 and 4, respectively. The variance values are computed from
sampling 500 Haar unitary pairs for both cases.

Fig 4: Comparison of the gradient variances as a function of the number of
qubits on a semi-log plot from different steps in QSSM and global QNN computed
by sampling Haar random unitaries. Panel (a) and (b) correspond to the
learning of the GHZ state and the ground state of the Heisenberg model,
respectively. The red, black and blue lines represent the gradient magnitudes
of the first step, $\frac{n}{2}$-th step and the last step training,
respectively, comparing with the global QNN results in yellow. Our method
apparently outperforms conventional global QNN in terms of gradient variance
scaling, indicating the absence of barren plateaus.

As we can observe in Fig. 4. The variance of the gradient vanishes
exponentially with the number of qubits when using the randomly initialized
global QNNs. In contrast, QSSM demonstrates a constant scaling of variance
magnitude. We note that there is a decay of the gradient variance of the
middle step in panel (b). Nevertheless, this decay is caused by a constant
factor $g(\rho_{k})$ that originates from the nature of the physical system
and does not exponentially influence the training processes.

##  VI Conclusion and Discussion

In this paper, we have presented the development and application of the
Quantum Sequential Scattering Model (QSSM) for quantum state learning. Our
model is inspired by the classical diffusion model, which the designing of it
involves quantum information theory and adaptive quantum machine learning
techniques. Our theoretical analysis and numerical experiments demonstrate the
superiority of the QSSM over conventional QNN approaches in terms of training
speed and learning accuracy. In particular, the QSSM addresses the barren
plateaus issues and provides an efficient solution to learning high-
dimensional unknown quantum states based on sequentially learning the reduced
target states.

Moreover, We have analyzed the impact of increasing entanglement, a key
property of quantum states, on the performance and efficiency of the QSSM. Our
results show that the model can effectively handle polynomially increased
entanglement, enabling us to learn complex quantum states accurately.
Numerical demonstrations have shown out-performances for learning physical and
algorithmic quantum states in terms of their rank-restricted approximations,
indicating the broad applicability of QSSM state learning and the deep
connection between state learning and quantum entanglement.

There are remaining issues of QSSM for future discussion. Different choices of
scattering layers would influence the learning performance, which has to be
exemplified. How to further improve the state fidelity provided the high
fidelity state from QSSM could become a significant open question.
Understanding and resolving the effect of over-parameterization from QSSM
should be explained. A theoretical performance guarantee and the connection
between scattering layer dilation and QSSM state learning information flow
should be established for a complete story of truncated state learning. We
also expect some extended applications of QSSM as a new quantum generative
model instead of only state learning on near-term quantum devices.

Acknowledgements.—M. J. and G. L. contributed equally to this work. Part of
this work was done when M. J., G. L., and X. W. were at Baidu Research.

## References

  * Anderson  _et al._ (1977) James A Anderson, Jack W Silverstein, Stephen A Ritz, and Randall S Jones, “Distinctive features, categorical perception, and probability learning: Some applications of a neural model.” Psychological review 84, 413 (1977).
  * Geng (2016) Xin Geng, “Label distribution learning,” IEEE Transactions on Knowledge and Data Engineering 28, 1734–1748 (2016).
  * Hansen  _et al._ (2015) Nikolaus Hansen, Dirk V. Arnold, and Anne Auger, “Evolution strategies,” in  _Springer Handbook of Computational Intelligence_ (Springer Berlin Heidelberg, Berlin, Heidelberg, 2015) pp. 871–898.
  * Kern  _et al._ (2004) Stefan Kern, Sibylle D. Müller, Nikolaus Hansen, Dirk Büche, Jiri Ocenasek, and Petros Koumoutsakos, “Learning probability distributions in continuous evolutionary algorithms – a comparative review,” Natural Computing 3, 77–112 (2004).
  * Baum and Wilczek (1987) Eric Baum and Frank Wilczek, “Supervised learning of probability distributions by neural networks,” in  _Neural information processing systems_ (1987).
  * Franceschi  _et al._ (2019) Luca Franceschi, Mathias Niepert, Massimiliano Pontil, and Xiao He, “Learning discrete structures for graph neural networks,” in  _International conference on machine learning_ (PMLR, 2019) pp. 1972–1982.
  * Hoogeboom  _et al._ (2021) Emiel Hoogeboom, Didrik Nielsen, Priyank Jaini, Patrick Forré, and Max Welling, “Argmax flows and multinomial diffusion: Learning categorical distributions,” Advances in Neural Information Processing Systems 34, 12454–12465 (2021).
  * LeCun  _et al._ (2015) Yann LeCun, Yoshua Bengio, and Geoffrey Hinton, “Deep learning,” nature 521, 436–444 (2015).
  * Serban  _et al._ (2016) Iulian Serban, Alessandro Sordoni, Yoshua Bengio, Aaron Courville, and Joelle Pineau, “Building end-to-end dialogue systems using generative hierarchical neural network models,” in  _Proceedings of the AAAI conference on artificial intelligence_ , Vol. 30 (2016).
  * Biamonte  _et al._ (2017) Jacob Biamonte, Peter Wittek, Nicola Pancotti, Patrick Rebentrost, Nathan Wiebe, and Seth Lloyd, “Quantum machine learning,” Nature 549, 195–202 (2017).
  * Schuld  _et al._ (2015) Maria Schuld, Ilya Sinayskiy, and Francesco Petruccione, “An introduction to quantum machine learning,” Contemporary Physics 56, 172–185 (2015).
  * Lloyd  _et al._ (2013) Seth Lloyd, Masoud Mohseni, and Patrick Rebentrost, “Quantum algorithms for supervised and unsupervised machine learning,” arXiv preprint arXiv:1307.0411 (2013).
  * Schuld  _et al._ (2014) Maria Schuld, Ilya Sinayskiy, and Francesco Petruccione, “The quest for a quantum neural network,” Quantum Information Processing 13, 2567–2586 (2014).
  * Cerezo  _et al._ (2022) M Cerezo, Guillaume Verdon, Hsin-Yuan Huang, Lukasz Cincio, and Patrick J Coles, “Challenges and opportunities in quantum machine learning,” Nature Computational Science 2, 567–576 (2022).
  * Abbas  _et al._ (2021) Amira Abbas, David Sutter, Christa Zoufal, Aurelien Lucchi, Alessio Figalli, and Stefan Woerner, “The power of quantum neural networks,” Nature Computational Science 1, 403–409 (2021), arXiv:2011.00027 .
  * Du  _et al._ (2023) Yuxuan Du, Yibo Yang, Dacheng Tao, and Min-Hsiu Hsieh, “Problem-Dependent Power of Quantum Neural Networks on Multiclass Classification,” Physical Review Letters 131, 140601 (2023).
  * Yu  _et al._ (2022) Zhan Yu, Hongshun Yao, Mujin Li, and Xin Wang, “Power and limitations of single-qubit native quantum neural networks,” in  _Advances in Neural Information Processing Systems_, Vol. 35, edited by S Koyejo, S Mohamed, A Agarwal, D Belgrave, K Cho, and A Oh (Curran Associates, Inc., 2022) pp. 27810–27823.
  * Chowdhury  _et al._ (2020) Anirban N Chowdhury, Guang Hao Low, and Nathan Wiebe, “A variational quantum algorithm for preparing quantum gibbs states,” arXiv preprint arXiv:2002.00055 (2020).
  * Ghosh  _et al._ (2019) Sanjib Ghosh, Tomasz Paterek, and Timothy CH Liew, “Quantum neuromorphic platform for quantum state preparation,” Physical Review Letters 123, 260404 (2019).
  * Wang  _et al._ (2021a) Samson Wang, Enrico Fontana, M. Cerezo, Kunal Sharma, Akira Sone, Lukasz Cincio, and Patrick J. Coles, “Noise-induced barren plateaus in variational quantum algorithms,” Nature Communications 12, 6961 (2021a), arXiv:2007.14384 .
  * Rebentrost  _et al._ (2018) Patrick Rebentrost, Thomas R Bromley, Christian Weedbrook, and Seth Lloyd, “Quantum hopfield neural network,” Physical Review A 98, 042308 (2018).
  * Zhao  _et al._ (2019) Jian Zhao, Yuan-Hang Zhang, Chang-Peng Shao, Yu-Chun Wu, Guang-Can Guo, and Guo-Ping Guo, “Building quantum neural networks based on a swap test,” Physical Review A 100, 012334 (2019).
  * Cong  _et al._ (2019) Iris Cong, Soonwon Choi, and Mikhail D Lukin, “Quantum convolutional neural networks,” Nature Physics 15, 1273–1278 (2019).
  * McClean  _et al._ (2018) Jarrod R. McClean, Sergio Boixo, Vadim N. Smelyanskiy, Ryan Babbush, and Hartmut Neven, “Barren plateaus in quantum neural network training landscapes,” Nature Communications 9, 1–7 (2018), arXiv:1803.11173 .
  * Cerezo  _et al._ (2021) M. Cerezo, Akira Sone, Tyler Volkoff, Lukasz Cincio, and Patrick J. Coles, “Cost function dependent barren plateaus in shallow parametrized quantum circuits,” Nature Communications 12, 1791 (2021), arXiv:2001.00550 .
  * Liu  _et al._ (2022a) Junyu Liu, Khadijeh Najafi, Kunal Sharma, Francesco Tacchino, Liang Jiang, and Antonio Mezzacapo, “An analytic theory for the dynamics of wide quantum neural networks,” Physical Review Letters , 1–26 (2022a), arXiv:2203.16711 .
  * Grant  _et al._ (2019) Edward Grant, Leonard Wossnig, Mateusz Ostaszewski, and Marcello Benedetti, “An initialization strategy for addressing barren plateaus in parametrized quantum circuits,” Quantum 3 (2019), 10.22331/q-2019-12-09-214, arXiv:1903.05076 .
  * Kulshrestha and Safro (2022) Ankit Kulshrestha and Ilya Safro, “Beinit: Avoiding barren plateaus in variational quantum algorithms,” arXiv preprint arXiv:2204.13751 (2022).
  * Volkoff and Coles (2021) Tyler Volkoff and Patrick J Coles, “Large gradients via correlation in random parameterized quantum circuits,” Quantum Science and Technology 6, 025008 (2021).
  * Friedrich and Maziero (2022) Lucas Friedrich and Jonas Maziero, “Avoiding barren plateaus with classical deep neural networks,” arXiv preprint arXiv:2205.13418 (2022).
  * Grimsley  _et al._ (2019) Harper R. Grimsley, Sophia E. Economou, Edwin Barnes, and Nicholas J. Mayhall, “An adaptive variational algorithm for exact molecular simulations on a quantum computer,” Nature Communications 10, 3007 (2019), arXiv:1812.11173 .
  * Zhang  _et al._ (2021) Feng Zhang, Niladri Gomes, Yongxin Yao, Peter P. Orth, and Thomas Iadecola, “Adaptive variational quantum eigensolvers for highly excited states,” Physical Review B 104, 1–10 (2021), arXiv:2104.12636 .
  * Skolik  _et al._ (2021) Andrea Skolik, Jarrod R. McClean, Masoud Mohseni, Patrick van der Smagt, and Martin Leib, “Layerwise learning for quantum neural networks,” Quantum Machine Intelligence 3, 5 (2021), arXiv:2006.14904 .
  * Grimsley  _et al._ (2022) Harper R. Grimsley, George S. Barron, Edwin Barnes, Sophia E. Economou, and Nicholas J. Mayhall, “ADAPT-VQE is insensitive to rough parameter landscapes and barren plateaus,” npj Quantum Information (2022), arXiv:2204.07179 .
  * Yang  _et al._ (2022) Ling Yang, Zhilong Zhang, Yang Song, Shenda Hong, Runsheng Xu, Yue Zhao, Yingxia Shao, Wentao Zhang, Bin Cui, and Ming-Hsuan Yang, “Diffusion models: A comprehensive survey of methods and applications,” arXiv preprint arXiv:2209.00796 (2022).
  * Quek  _et al._ (2021) Yihui Quek, Stanislav Fort, and Hui Khoon Ng, “Adaptive quantum state tomography with neural networks,” npj Quantum Information 7, 1–7 (2021).
  * Kearns  _et al._ (1994) Michael Kearns, Yishay Mansour, Dana Ron, Ronitt Rubinfeld, Robert E. Schapire, and Linda Sellie, “On the learnability of discrete distributions,” in  _Proceedings of the Twenty-Sixth Annual ACM Symposium on Theory of Computing_, STOC ’94 (Association for Computing Machinery, New York, NY, USA, 1994) p. 273–282.
  * Csiszar (1975) I. Csiszar, “$I$-Divergence Geometry of Probability Distributions and Minimization Problems,” The Annals of Probability 3, 146 – 158 (1975).
  * Vidal (2003) Guifré Vidal, “Efficient classical simulation of slightly entangled quantum computations,” Phys. Rev. Lett. 91, 147902 (2003).
  * Peruzzo  _et al._ (2014) Alberto Peruzzo, Jarrod McClean, Peter Shadbolt, Man-Hong Yung, Xiao-Qi Zhou, Peter J. Love, Alán Aspuru-Guzik, and Jeremy L. O’Brien, “A variational eigenvalue solver on a photonic quantum processor,” Nature Communications 5, 4213 (2014).
  * Kandala  _et al._ (2017) Abhinav Kandala, Antonio Mezzacapo, Kristan Temme, Maika Takita, Markus Brink, Jerry M Chow, and Jay M Gambetta, “Hardware-efficient variational quantum eigensolver for small molecules and quantum magnets,” Nature 549, 242–246 (2017).
  * Aaronson (2018) Scott Aaronson, “Shadow tomography of quantum states,” in  _Proceedings of the 50th annual ACM SIGACT symposium on theory of computing_ (2018) pp. 325–338.
  * Huang (2022) Hsin-Yuan Huang, “Learning quantum states from their classical shadows,” Nature Reviews Physics 4, 81–81 (2022).
  * Lloyd  _et al._ (2014) Seth Lloyd, Masoud Mohseni, and Patrick Rebentrost, “Quantum principal component analysis,” Nature Physics 10, 631–633 (2014).
  * Perez-Garcia  _et al._ (2006) David Perez-Garcia, Frank Verstraete, Michael M Wolf, and J Ignacio Cirac, “Matrix product state representations,” arXiv preprint quant-ph/0608197 (2006).
  * Carlen (2009) Eric A. Carlen, “Trace inequalities and quantum entropy: An introductory course,” (2009).
  * Barenco  _et al._ (1997) Adriano Barenco, Andre Berthiaume, David Deutsch, Artur Ekert, Richard Jozsa, and Chiara Macchiavello, “Stabilization of quantum computations by symmetrization,” SIAM Journal on Computing 26, 1541–1557 (1997).
  * Islam  _et al._ (2015) Rajibul Islam, Ruichao Ma, Philipp M. Preiss, M. Eric Tai, Alexander Lukin, Matthew Rispoli, and Markus Greiner, “Measuring entanglement entropy in a quantum many-body system,” Nature 528, 77–83 (2015).
  * Linke  _et al._ (2018) N. M. Linke, S. Johri, C. Figgatt, K. A. Landsman, A. Y. Matsuura, and C. Monroe, “Measuring the ré nyi entropy of a two-site fermi-hubbard model on a trapped ion quantum computer,” Physical Review A 98 (2018), 10.1103/physreva.98.052334.
  * Kingma and Ba (2014) Diederik P Kingma and Jimmy Ba, “Adam: A method for stochastic optimization,” arXiv preprint arXiv:1412.6980 (2014).
  * Powell (1994) Michael JD Powell,  _A direct search optimization method that models the objective and constraint functions by linear interpolation_ (Springer, 1994).
  * Schuld  _et al._ (2018) Maria Schuld, Ville Bergholm, Christian Gogolin, Josh Izaac, and Nathan Killoran, “Evaluating analytic gradients on quantum hardware,” Physical Review A 99, 032331 (2018), arXiv:1811.11184 .
  * Mitarai  _et al._ (2018) K. Mitarai, M. Negoro, M. Kitagawa, and K. Fujii, “Quantum circuit learning,” Physical Review A 98 (2018), 10.1103/physreva.98.032309.
  * Ostaszewski  _et al._ (2019) Mateusz Ostaszewski, Edward Grant, and Marcello Benedetti, “Structure optimization for parameterized quantum circuits,” Quantum 5, 1–13 (2019), arXiv:1905.09692 .
  * Wang  _et al._ (2021b) Youle Wang, Guangxi Li, and Xin Wang, “Variational Quantum Gibbs State Preparation with a Truncated Taylor Series,” Physical Review Applied 16, 054035 (2021b), arXiv:2005.08797 .
  * Gomez and Hennart (1994) Susana Gomez and Jean-Pierre Hennart, eds.,  _Advances in Optimization and Numerical Analysis_ (Springer Netherlands, 1994).
  * Takahashi (1971) Minoru Takahashi, “One-dimensional heisenberg model at finite temperature,” Progress of Theoretical Physics 46, 401–415 (1971).
  * McClean  _et al._ (2020) Jarrod R McClean, Nicholas C Rubin, Kevin J Sung, Ian D Kivlichan, Xavier Bonet-Monroig, Yudong Cao, Chengyu Dai, E Schuyler Fried, Craig Gidney, Brendan Gimby, _et al._ , “Openfermion: the electronic structure package for quantum computers,” Quantum Science and Technology 5, 034014 (2020).
  * Schuld (2021) Maria Schuld, “Supervised quantum machine learning models are kernel methods,” arXiv preprint arXiv:2101.11020 (2021).
  * Gisin and Bechmann-Pasquinucci (1998) Nicolas Gisin and Helle Bechmann-Pasquinucci, “Bell inequality, bell states and maximally entangled states for n qubits,” Physics Letters A 246, 1–6 (1998).
  * Liu  _et al._ (2022b) Xia Liu, Geng Liu, Jiaxin Huang, and Xin Wang, “Mitigating barren plateaus of variational quantum eigensolvers,”  (2022b), arXiv:2205.13539 .
  * Qiskit contributors (2023) Qiskit contributors, “Qiskit: An open-source framework for quantum computing,”  (2023).
  * Georgopoulos  _et al._ (2021) Konstantinos Georgopoulos, Clive Emary, and Paolo Zuliani, “Modeling and simulating the noisy behavior of near-term quantum computers,” Physical Review A 104, 062432 (2021).
  * Dankert  _et al._ (2009) Christoph Dankert, Richard Cleve, Joseph Emerson, and Etera Livine, “Exact and approximate unitary 2-designs and their application to fidelity estimation,” Physical Review A 80, 012304 (2009).
  * Nielsen and Chuang (2010) Michael A Nielsen and Isaac L Chuang,  _Quantum computation and quantum information_ (Cambridge university press, 2010).
  * Tóth  _et al._ (1996) Géza Tóth, Craig S Lent, P Douglas Tougaw, Yuriy Brazhnik, Weiwen Weng, Wolfgang Porod, Ruey-Wen Liu, and Yih-Fang Huang, “Quantum cellular neural networks,” Superlattices and Microstructures 20, 473–478 (1996).
  * Liu  _et al._ (2013) Cheng-Yi Liu, Chein Chen, Ching-Ter Chang, and Lun-Min Shih, “Single-hidden-layer feed-forward quantum neural network based on grover learning,” Neural Networks 45, 144–150 (2013).
  * Killoran  _et al._ (2019) Nathan Killoran, Thomas R Bromley, Juan Miguel Arrazola, Maria Schuld, Nicolás Quesada, and Seth Lloyd, “Continuous-variable quantum neural networks,” Physical Review Research 1, 033063 (2019).
  * Kieferova  _et al._ (2021) Maria Kieferova, Ortiz Marrero Carlos, and Nathan Wiebe, “Quantum Generative Training Using Rényi Divergences,”  (2021), arXiv:2106.09567 .
  * Greenberger  _et al._ (1989) Daniel M Greenberger, Michael A Horne, and Anton Zeilinger, “Going beyond bell’s theorem,” in  _Bell’s theorem, quantum theory and conceptions of the universe_ (Springer, 1989) pp. 69–72.
  * Fukuda  _et al._ (2019a) Motohisa Fukuda, Robert König, and Ion Nechita, “RTNI - A symbolic integrator for Haar-random tensor networks,” Journal of Physics A: Mathematical and Theoretical 52, 1–24 (2019a), arXiv:1902.08539 .
  * Fukuda  _et al._ (2019b) Motohisa Fukuda, Robert König, and Ion Nechita, “Rtni—a symbolic integrator for haar-random tensor networks,” Journal of Physics A: Mathematical and Theoretical 52, 425303 (2019b).

Supplementary Material for
Quantum sequential scattering model for quantum state learning

##  Appendix A Preliminaries in Quantum information

In this appendix, we write more details on quantum computation and quantum
information.

###  A.1 Quantum computation and quantum information basics

We use $\|\cdot\|_{p}$ to denote the $l_{p}$-norm for vectors and the
Schatten-$p$ norm for matrices. The common-used linear algebra notations
include complex conjugate transpose $A^{\dagger}$, the trace of matrix
$\operatorname{Tr}[A]$. The $\mu$-th component of the vector $\bm{\theta}$ is
denoted as $\theta_{\mu}$. The derivative with respect to $\theta_{\mu}$ is
then represented as $\partial_{\mu}\mathrel{\mathop{\mathchar
58\relax}}=\frac{\partial}{\partial\theta_{\mu}}$. The big-O notation ${\cal
O}$ implies the asymptotic notation of upper bounds.

Quantum information is encoded and processed via the fundamental cells,
namely, qubits, and described as quantum states. An $n$-qubit state can be
mathematically represented by a $2^{n}\times 2^{n}$ positive semi-definite
density matrix $\rho$, i.e., $\rho\succeq 0$ over the complex field and
$\operatorname{Tr}[\rho]=1$. A pure state, in this formulation, satisfy
$\operatorname{Rank}{(\rho)}=1$ and can be expressed in Dirac bra-ket notation
as $\rho=|\psi\rangle\\!\langle\psi|$ where
$|\psi\rangle\in{{\mathbb{C}}}^{2^{n}}$ denotes a Hilbert space unit column
vector with the corresponding dual vector
$\langle\psi|^{\dagger}=|\psi\rangle$ and $\dagger$ denoting the complex
conjugate transpose operation. A mixed state satisfies
$\operatorname{Rank}{(\rho)}>1$, and based on Spectral theorem, it has a
decomposition form $\rho=\sum_{j}p_{j}|\psi_{j}\rangle\\!\langle\psi_{j}|$
where $p_{j}>0$ denotes the probability of observing
$|\psi_{j}\rangle\\!\langle\psi_{j}|$ in $\rho$ and $\sum_{j}p_{j}=1$.

Based on Uhlmann’s theorem Nielsen and Chuang (2010) for every mixed state
$\rho$ acting as a linear operator on a Hilbert space $A$, there exists a
purified state $|AR\rangle$ (i.e, pure state) in the composite system $AR$
such that $\operatorname{Tr}_{R}[|AR\rangle\\!\langle AR|]=\rho$, where
$\operatorname{Tr}_{R}[\cdot]$ denotes the partial trace operation tracing out
the ancillary system $R$. The purification $|AR\rangle$ has a Schmidt
decomposition form
$|AR\rangle=\sum_{j}\sqrt{p_{j}}|\psi_{j}\rangle\otimes|j_{R}\rangle$ for some
orthonormal set $|j_{R}\rangle$ in $R$.

The partial trace operation in the above statement plays an important role in
quantum computation and information. Given a composite quantum system
described by a tensor product of Hilbert spaces,
$\mathcal{H}_{A}\otimes\mathcal{H}_{B}$, or simply denoted as $AB$, where
$\mathcal{H}_{A}$ and $\mathcal{H}_{B}$ represent the Hilbert spaces of
subsystems $A$ and $B$, respectively, the partial trace operation allows us to
focus on subsystem $A$ while tracing out the degrees of freedom associated
with subsystem $B$. The partial trace of an operator $\rho$ with respect to
subsystem B is denoted as $\text{Tr}_{B}[\rho]$ and is defined as follows:

$\text{Tr}_{B}[\rho]=\sum_{i}(I_{A}\otimes\langle
i|_{B})\cdot\rho\cdot(I_{A}\otimes|i\rangle_{B})$

Where $I_{A}$ is the identity operator on $\mathcal{H}_{A}$; $|i\rangle_{B}$
forms an orthonormal basis for $\mathcal{H}_{B}$ and $\langle i|_{B}$
represents the conjugate transpose of $|i\rangle_{B}$.

The evolution of a quantum state $\rho$ is realized by applying a series of
quantum gates, which are mathematically described as unitary operators. The
state $\rho^{\prime}$ that undergoes transformation via a quantum gate $U$ can
be obtained through direct matrix multiplication, expressed as
$\rho^{\prime}=U\rho U^{\dagger}$. Common single-qubit gates include the Pauli
rotations $\\{R_{P}(\theta)=e^{-i\frac{\theta}{2}P}|P\in\\{X,Y,Z\\}\\}$, which
are in the matrix exponential form of Pauli matrices

$X\mathrel{\mathop{\mathchar 58\relax}}=\begin{pmatrix}0&1\\\
1&0\end{pmatrix},Y\mathrel{\mathop{\mathchar 58\relax}}=\begin{pmatrix}0&-i\\\
i&0\end{pmatrix},Z\mathrel{\mathop{\mathchar 58\relax}}=\begin{pmatrix}1&0\\\
0&-1\end{pmatrix}.$

Common two-qubit gates include controlled-$X$ gate CX (or CNOT) $=I\oplus X$
and controlled-$Z$ gate CZ$=I\oplus Z$ where $\oplus$ denotes the direct sum
operation. An $n$-qubit operator generally lives in the linear operator space
${\cal L}({{\mathbb{C}}}^{2^{n}})$ over the complex field. Quantum
measurements are then applied at the end of the quantum circuits, extracting
classical information by projecting the quantum states onto its classical
shadow.

###  A.2 Fundamental of quantum neural networks

In quantum machine learning, quantum neural networks (QNNs) are usually
represented as parameterized unitaries consisting of a bunch of single-qubit
rotation gates and several two-qubit gates, denoted as
$\mathbf{U}(\bm{\theta})$ where $\bm{\theta}$ are the trainable parameters.
The model is trained using a classical optimizer according to a minimization
process on some cost function $C(\bm{\theta})$ based on the quantum
measurement results.

QNNs can be used to handle a variety of computational tasks, which is usually
seen as a quantum version of classical neural networks. In the most general
form, a QNN model can be expressed as
$\mathbf{U}(\bm{\theta})=\prod_{k=1}^{M}U_{k}(\bm{\theta}_{k})$ for some sub-
network layers $U_{k}(\bm{\theta}_{k})$ where each layer can also be seen as a
combination of parameterised circuits as
$U_{k}(\bm{\theta}_{k})=\prod_{j=1}^{d}U_{j}(\theta^{(k)}_{j})W_{j}$, where
$U_{j}(\theta^{(k)}_{j})=e^{-ig_{j}\theta^{(k)}_{j}}$ is a parameterised gate
with a Hermitian generator $g_{j}$. $W_{j}$ is usually non-parameterised, such
as the networks of CNOT and CZ gates. The product $\prod_{k}$ here is, by
default, in the increasing order from the right to the left in the above
representations.

The idea of quantum neural networks has obtained massive attention since its
birth Tóth  _et al._ (1996). Various QNN architectures have been introduced to
address a diverse range of computational challenges, spanning both classical
and quantum problem domains Rebentrost  _et al._ (2018); Zhao  _et al._
(2019); Liu  _et al._ (2013); Cong  _et al._ (2019); Killoran  _et al._
(2019), thereby pioneering an entirely novel realm of machine learning models.
Recent literature focusing on the trainability theory of QNNs indicates a
prospective direction for coping with barren plateaus by reducing the
expressibility of QNN architectures Cerezo  _et al._ (2021); Liu  _et al._
(2022a). Beyond that, some strategies have been proposed under certain
conditions, for example, adopting clever initialization strategy Grant  _et
al._ (2019); Kulshrestha and Safro (2022), using adaptive algorithms Grimsley
_et al._ (2019); Zhang  _et al._ (2021); Skolik  _et al._ (2021); Grimsley
_et al._ (2022), making parameterization generalization Volkoff and Coles
(2021); Friedrich and Maziero (2022) and choosing different cost forms and
circuit architectures Cerezo  _et al._ (2021); Kieferova  _et al._ (2021); Liu
_et al._ (2022b).

##  Appendix B Effectiveness of QSSM state learning

In this section, we give proof of the effectiveness of QSSM based on Schmidt
decomposition, Uhlmann’s theorem and the properties of purification.

###  B.1 Degrees of freedom in Purification

One of the implications of Uhlmann’s theorem is that it ensures the degrees of
freedom for quantum state purification Nielsen and Chuang (2010). Purification
is a commonly used mathematical procedure in quantum computing. For an
arbitrary quantum state, its purification is not unique. However, we could
bridge these purification states via unitary transformations, which we call
freedom in purification.

###### Lemma S1

Let $|\psi\rangle$ and $|\phi\rangle$ be two purifications of a state $\rho$
acting on a composite system $AE$. Then there exists a unitary $U_{E}$ locally
acting on $E$ s.t.,

$|\psi\rangle=(I_{A}\otimes U_{E})|\phi\rangle.$

The proof is simply inspired by the Schmidt decomposition. Let $|\psi\rangle$
and $|\phi\rangle$ be the purifications of $\rho$ acting on $AE$. Write the
Schmidt decomposition of these two states,

$|\psi\rangle=\sum_{j}\sqrt{\lambda_{j}}|j_{A}\rangle|j_{E}\rangle\quad|\phi\rangle=\sum_{k}\sqrt{\eta_{k}}|k_{A}\rangle|k_{E}\rangle.$

Notice $\operatorname{Tr}_{E}[\psi]=\rho=\operatorname{Tr}_{E}[\phi]$, which
then induces,

$\sum_{j}\lambda_{j}|j_{A}\rangle\langle
j_{A}|=\sum_{k}\eta_{k}|k_{A}\rangle\langle k_{A}|.$

By linear algebra, we could easily extend both $\\{|j_{A}\rangle\\}_{j}$ and
$\\{|k_{E}\rangle\\}_{k}$ to the basis set of ${\cal H}_{E}$, via Gram-Schmidt
method, and hence proves the existence of a unitary $U_{E}$ s.t,

$U_{E}|k_{E}\rangle=|j_{E}\rangle,$

which is then substituted into the above equations to prove the lemma. Based
on the freedom in purification, we could prove the lemma S2, and therefore
prove the effectiveness of our QSSM.

###### Lemma S2

Given a target state $\rho$ acting on system $A$ and $B$, we suppose it can be
purified on system $ABE$ where $E$ is an environment. For any pure state
$|\psi\rangle$ acting on $ABE$, s.t.,

$\operatorname{Tr}_{BE}[|\psi\rangle\\!\langle\psi|]=\operatorname{Tr}_{B}[\rho].$

There always exists a local unitary $U_{BE}$, s.t.,

$\operatorname{Tr}_{E}[(I_{A}\otimes
U_{BE})|\psi\rangle\\!\langle\psi|(I_{A}\otimes U_{BE}^{\dagger})]=\rho.$

From the definition, $|\psi\rangle\\!\langle\psi|$ and $\rho$ have the same
reduced state acting on $A$. Suppose the state $|\phi\rangle$ is the
purification of $\rho$ on system $ABE$. Thus, it is also a purification of
$\rho_{A}=\operatorname{Tr}_{B}[\rho]$. We have $|\phi\rangle$ and
$|\psi\rangle$ acting on the composite system $ABE$. By lemma S1, there exists
a $U_{BE}$ s.t.,

$|\phi\rangle\\!\langle\phi|=(I_{A}\otimes
U_{BE})|\psi\rangle\\!\langle\psi|(I_{A}\otimes U_{BE}^{\dagger}).$

Now since $|\phi\rangle$ is the purification of $\rho$ we have,

$\operatorname{Tr}_{E}[(I_{A}\otimes
U_{BE})|\psi\rangle\\!\langle\psi|(I_{A}\otimes U_{BE}^{\dagger})]=\rho,$

as required. Moreover, based on the Schmidt decomposition between $AB$ and
$E$, the dimensionality of system $E$ clearly determines the maximum rank of
the output states. For $\operatorname{Rank}[\rho]=r$. It is sufficient and
necessary to construct such a unitary $U_{BE}$ so that the last equation in
lemma S2 can hold when $\dim[E]\geq\log_{2}r$.

###  B.2 Effectiveness proposition of QSSM

Before we move to the effectiveness proposition of QSSM state learning, we
first define some symbols for a better layout of our demonstration of QSSM
effectiveness. A $k$-th partition of $\rho$ separates the state into bipartite
subsystems ${\cal A}_{k}$ and $\bar{{\cal A}}_{k}$ covering the first $k$
qubits and the remaining, respectively, where $1\leq k\leq n$. For $k=n$,
$\bar{{\cal A}}_{k}$ becomes trivial and ${\cal
A}_{k}={{\mathbb{C}}}^{2^{n}}$. We then could define the rank sequence of a
given target state $\rho$ in the following sense. A sketch of this has been
figured out in Fig. S1

Fig S1: The sketch for illustrating the rank sequence of a given quantum state
$\rho$.

###### Definition S1

Given an $n$-qubit quantum state $\rho$ represented by $n$ ordered quantum
registers labeled as $q_{1},q_{2},\cdots,q_{n}$, denoting $\rho_{k}$ as the
$k$-th reduced density matrix of the first $k$-register state, i.e.,
$\rho_{k}=\operatorname{Tr}_{q_{k+1}\mathrel{\mathop{\mathchar
58\relax}}q_{n}}[\rho]$ for $1\leq k\leq n$ where the operation
$\operatorname{Tr}_{q_{i}\mathrel{\mathop{\mathchar 58\relax}}q_{j}}[\cdot]$
representing a partial tracing over registers $q_{i}$ to $q_{j}$, the
(Schmidt) rank sequence of $\rho$ is an ordered list ${\cal R}_{\rho}$,

${\cal R}_{\rho}=\\{r_{1},r_{2},\cdots,r_{n-1},r_{n}\\},$

where $r_{k}$ indicates $\operatorname{Rank}[\rho_{k}]$. In particular, if
$\rho$ is pure, then $r_{n}=1$ since $\rho$ can be represented as
$|\phi\rangle\\!\langle\phi|$ for some pure state vector $|\phi\rangle$.

Here for clarification, by setting up the $k$-partition of $\rho$, ${\cal
A}_{k}$ contains the registers $q_{1}\mathrel{\mathop{\mathchar
58\relax}}q_{k}$ and $\bar{{\cal A}}_{k}$ contains the registers
$q_{k+1}\mathrel{\mathop{\mathchar 58\relax}}q_{n}$ which is the reason why we
use this notation to represent the corresponding partial trace operations. We
are now ready to prove the effectiveness proposition of the main results.

###### Proposition S3

[Effectiveness] For a given $n$-qubit pure target state $\rho$ represented by
$n$ ordered quantum registers $q_{1},q_{2},\cdots,q_{n}$, if the rank sequence
of $\rho$ is ${\cal R}_{\rho}=\\{r_{1},r_{2},\cdots r_{n-1},r_{n}\\}$. Then
there exists a quantum algorithm 1, based on QSSM, that could produce a state
$\sigma$ exactly satisfying $\sigma=\rho$, if and only if the $k$-th
scattering layer $U_{k}(\bm{\theta}_{k})$ of QSSM has a width $w_{k}$ scales
${\cal O}(\lceil\log_{2}r_{k}\rceil)$.

To prove the above Proposition, we first suppose an $n$-qubit pure target
$\rho=|\phi\rangle\\!\langle\phi|$, and at the $k$-th step,

$\displaystyle\sigma_{k}=\operatorname{Tr}_{\bar{{\cal
A}}_{k}}[|\psi_{k}\rangle\\!\langle\psi_{k}|]$
$\displaystyle=\operatorname{Tr}_{\bar{{\cal A}}_{k}}[\rho]=\rho_{k}$

We call this the $k$-th perfect learning condition of QSSM state learning.
Then, by lemma S2, there exists a local unitary such that,

$\displaystyle\operatorname{Tr}_{\bar{{\cal A}}_{k+1}}[(I_{k}\otimes
U_{k+1})|\psi_{k}\rangle\\!\langle\psi_{k}|(I_{k}\otimes U_{k+1}^{\dagger})]$
$\displaystyle=\operatorname{Tr}_{\bar{{\cal A}}_{k+1}}[\rho],$

where the existence of $U_{k+1}$ ensures the effectiveness of QSSM. We call it
a perfect learning assumption of QSSM state learning if all the $k$-th perfect
learning can be achieved.

Now, we are ready to deliver the proof of the effectiveness of QSSM. The proof
assumes sufficient computational resources, ensuring perfect learning for each
step’s reduced target. We divide the entire learning task into three main
stages based on the algorithm setup.

(1), in the beginning, a state $|0\rangle$ is initialized for the model. We
denote the step as $k=1$ for learning the reduced state acting on ${\cal
A}_{1}$ of a single qubit. Notice that for any single-qubit state $\rho_{1}$
has an eigendecomposition,

$\rho_{1}=\lambda_{1}^{(1)}|0^{(1)}\rangle\langle
0^{(1)}|+\lambda_{2}^{(1)}|1^{(1)}\rangle\langle 1^{(1)}|,$

where the states $|0^{(1)}\rangle$ and $|1^{(1)}\rangle$ are not necessary the
computational basis elements. There exists a purification unitary $U_{{\cal
A}_{1}{\cal A}_{2}}$,

$U_{{\cal A}_{1}{\cal
A}_{2}}|00\rangle=\sqrt{\lambda_{1}^{(1)}}|0^{(1)}\rangle|0^{(2)}\rangle+\sqrt{\lambda_{2}^{(1)}}|1^{(1)}\rangle|1^{(2)}\rangle.$

Such a unitary should have the following components. The rest of the matrix
can be extended using the Gram-Schmidt process. We could write out the
computational basis representation of $U_{{\cal A}_{1}{\cal A}_{2}}$,

$[U_{{\cal A}_{1}{\cal
A}_{2}}]_{mn}=\begin{pmatrix}\sqrt{\lambda_{1}^{(1)}}\langle
00|0^{(1)}0^{(2)}\rangle+\sqrt{\lambda_{2}^{(1)}}\langle
00|1^{(1)}1^{(2)}\rangle&\cdots\\\ \sqrt{\lambda_{1}^{(1)}}\langle
01|0^{(1)}0^{(2)}\rangle+\sqrt{\lambda_{2}^{(1)}}\langle
01|1^{(1)}1^{(2)}\rangle&\cdots\\\ \sqrt{\lambda_{1}^{(1)}}\langle
10|0^{(1)}0^{(2)}\rangle+\sqrt{\lambda_{2}^{(1)}}\langle
10|1^{(1)}1^{(2)}\rangle&\cdots\\\ \sqrt{\lambda_{1}^{(1)}}\langle
11|0^{(1)}0^{(2)}\rangle+\sqrt{\lambda_{2}^{(1)}}\langle
11|1^{(1)}1^{(2)}\rangle&\cdots\end{pmatrix}.$

(2), now for $1<k\leq\lceil n/2\rceil$, by the assumption of ideal learning of
state $\rho_{k-1}$, a purification, denoted as $|\psi_{k-1}\rangle$ of it
would be imported from the $(k-1)$-th step. The reduced state $\rho_{k}$ would
generally require at least $k$ extra ancillary qubits to be purified, which is
why a width control $w_{k}=k+1$ is settled in the worst case. Moreover, if the
${\cal R}_{\rho}$ is given as above, the rank values give better choices of
layer widths as $w_{k}=\min\\{k+1,\lceil\log_{2}r_{k}\rceil\\}$.

Now suppose a purification $|\phi_{k}\rangle$ of $\rho_{k}$. Since
$\operatorname{dim}(|\psi_{k-1}\rangle)\leq\operatorname{dim}(|\phi_{k}\rangle)$,
we could always extend $|\psi_{k}\rangle$ to
$|\tilde{\psi_{k}}\rangle=|\psi_{k}\rangle|0\rangle$ so that the result pure
state lives in the same dimensional Hilbert as $|\phi_{k}\rangle$. We could
observe $|\tilde{\psi_{k}}\rangle$ and $|\phi_{k}\rangle$ are both
purification of $\rho_{k-1}$. Based on the lemma S2, there exists $U_{k}$
acting on the qubits index from $k+1$ to $w_{k}+k$ s.t.,

$\operatorname{Tr}_{\bar{{\cal A}}_{k+1}}[(I_{{\cal A}_{k-1}}\otimes
U_{k})\tilde{\psi}_{k}(I_{{\cal A}_{k-1}}\otimes
U_{k}^{\dagger})]=\operatorname{Tr}_{\bar{{\cal
A}}_{k+1}}[\phi_{k}]=\rho_{k}.$

(3), at last, for $\lceil n/2\rceil<k\leq n$. $|\phi_{k}\rangle$ becomes the
pure state acting on the entire system of $n$ qubit registers. The imported
purification $|\psi_{k-1}\rangle$ of $\rho_{k-1}$ is also a pure state of $n$
qubits. The result follows by applying the lemma S2 again but with
$w_{k}=\min\\{n-k+1,\lceil\log_{2}r_{k}\rceil\\}$.

Above all, we have proven the effectiveness of QSSM. One important point to
note here is that the width of each scattering layer can be carefully settled
concerning the rank of $\rho_{k}$ for $1\leq k<n$ in order to obtain the
perfect learning. However, exactly constructing those purification unitaries
using scattering layers $U_{k}(\bm{\theta}_{k})$ is not possible. In reality,
if each scattering layer of QSSM forms an approximate local unitary $t$-design
for sufficient large positive integer $t$. Then, given enough time for
training, the scattering layers would approximate these purification unitaries
to arbitrarily high accuracy.

Further, the proposition identifies a group of quantum states that can be
learned more efficiently using QSSM. One notable exemplar within this
proposition is the $n$-qubit GHZ state.

Remark 1 An $n$-qubit GHZ state Greenberger  _et al._ (1989) has constant rank
$r_{k}=2$ for $1\leq k<n$. Hence, setting $w_{k}=2\ \forall k$ is sufficient
to obtain perfect learning of QSSM state learning on GHZ state.

The above phenomenon suggests a connection between the amount of entanglement
within a target state and the sufficient widths $w_{k}$ to achieve perfect
learning. The higher the ranks, the harder the target state could be learnt
via QSSM.

##  Appendix C Trainability and gradient analysis of QSSM

In this section, we give the proof for the proposition 2 stated about the
trainability of QSSM in this paper. We first recall some useful lemmas to make
the proof easy to read and emphasize important intermediate results. The
following lemmas were derived from the studies of unitary $t$-design. These
were originally computed in Cerezo  _et al._ (2021).

###### Definition S2

A unitary $t$-design of dimension $d$ Dankert  _et al._ (2009) with respect to
the Haar measure is defined as a finite set of unitaries
$\\{U_{k}\\}_{k=1}^{M}$ on a $d$-dimensional Hilbert space such that,

$\frac{1}{M}\cdot\sum_{k=1}^{M}P_{(t,t)}(U_{k})=\int_{{\cal
U}(d)}d\mu_{\text{Haar}}(U)P_{(t,t)}(U),$

where $P_{(t,t)}(U)$ denotes a homogeneous polynomial of degree at most $t$ on
the elements of $U$ and $U^{\dagger}$.

###### Lemma S4

Suppose $X\subset\mathcal{U}(d)$ is unitary t-design, and $A,B,C,D$ are
arbitrary linear operators. If $t\geq 1$, then we have

$\frac{1}{|X|}\sum_{U\in
X}\operatorname{Tr}[U^{\dagger}AUB]=\int_{\mathcal{U}(d)}\operatorname{Tr}[U^{\dagger}AUB]d\eta(U)=\frac{\operatorname{Tr}[A]\operatorname{Tr}[B]}{d}$
(C.1)

If $t\geq 2$, then we have

$\displaystyle\frac{1}{|X|}\sum_{U\in
X}\operatorname{Tr}[U^{\dagger}AUBU^{\dagger}CUD]=\int_{\mathcal{U}(d)}\operatorname{Tr}[U^{\dagger}AUBU^{\dagger}CUD]d\eta(U)$
(C.2)
$\displaystyle=\frac{\operatorname{Tr}[A]\operatorname{Tr}[C]\operatorname{Tr}[BD]+\operatorname{Tr}[AC]\operatorname{Tr}[B]\operatorname{Tr}[D]}{d^{2}-1}-\frac{\operatorname{Tr}[AC]\operatorname{Tr}[BD]+\operatorname{Tr}[A]\operatorname{Tr}[B]\operatorname{Tr}[C]\operatorname{Tr}[D]}{d(d^{2}-1)}$
(C.3)

###### Lemma S5

Suppose $A,B,C,D$ are arbitrary linear operators. Then,

$\displaystyle\int_{\mathcal{U}(d)}\operatorname{Tr}[UAU^{{\dagger}}B]\operatorname{Tr}[UCU^{{\dagger}}D]d\eta(U)$
$\displaystyle=\frac{1}{d^{2}-1}(\operatorname{Tr}[A]\operatorname{Tr}[B]\operatorname{Tr}[C]\operatorname{Tr}[D]+\operatorname{Tr}[AC]\operatorname{Tr}[BD])$
$\displaystyle-\frac{1}{d(d^{2}-1)}(\operatorname{Tr}[AC]\operatorname{Tr}[B]\operatorname{Tr}[D]+\operatorname{Tr}[A]\operatorname{Tr}[C]\operatorname{Tr}[BD])$

###### Lemma S6

Let $\mathcal{H}=\mathcal{H_{A}}\otimes\mathcal{H_{B}}$ be a bipartite Hilbert
space of dimension $d=d_{A}d_{B}$, and for arbitrary linear operators
$M,N\mathrel{\mathop{\mathchar 58\relax}}\mathcal{H}\rightarrow\mathcal{H}$,
we have

$\displaystyle\int_{\mathcal{U}(d_{B})}d\eta(U)(I_{A}\otimes U)M(I_{A}\otimes
U^{{\dagger}})N=\frac{\operatorname{Tr}_{B}[M]\otimes I_{B}}{d_{B}}N,$

and

$\displaystyle\int_{\mathcal{U}(d_{B})}d\eta(U)\operatorname{Tr}[(I_{A}\otimes
U)M(I_{A}\otimes
U^{{\dagger}})N]=\frac{\operatorname{Tr}[\operatorname{Tr}_{B}[M]\operatorname{Tr}_{B}[N]]}{d_{B}}.$

###### Lemma S7

Let $\mathcal{H}=\mathcal{H_{A}}\otimes\mathcal{H_{B}}$ be a bipartite Hilbert
space of dimension $d=d_{A}d_{B}$ $(d=2^{n},d_{A}=2^{n^{\prime}})$, and for
arbitrary linear operators $M,N,U\mathrel{\mathop{\mathchar
58\relax}}\mathcal{H}\rightarrow\mathcal{H}$, we have

$\displaystyle\operatorname{Tr}[(I_{A}\otimes U)M(I_{A}\otimes
U^{{\dagger}})N]=\sum_{p,q}\operatorname{Tr}[UM_{qp}U^{{\dagger}}N_{pq}],$

where the summation runs over all bitstrings of length $n^{\prime}$, and where

$\displaystyle M_{qp}$
$\displaystyle=\operatorname{Tr}_{A}[(|p\rangle\\!\langle q|\otimes I)M]$
$\displaystyle N_{pq}$
$\displaystyle=\operatorname{Tr}_{A}[(|q\rangle\\!\langle p|\otimes I)N].$

With these lemmas, we can now start our proof by directly calculating the
variance of gradients. The whole proof includes three parts indicating the
gradient magnitude of different stages in the algorithm.

###  C.1 Trainability of the last layer

###### Proposition S8

For a $n$-qubit target state $\rho$, assume we start from the $\hat{\sigma}$
such that $\operatorname{Tr}_{n}[\rho]=\operatorname{Tr}_{n}[\hat{\sigma}]$,
where $\operatorname{Tr}_{n}[\rho]$ denotes partial trace over the last qubit
of the state. And if the circuit is only acting on the last qubit and forms a
2-design, then ${{\mathbb{E}}}[\partial_{\mu}C_{n}]=0$ and the variance
${\operatorname{Var}}[\partial_{\mu}C_{n}]\in[\frac{16}{27},\frac{8}{9}]$.

The proof is given by the following, suppose the output state is $\sigma$,
then the cost function is

$C_{n}(\bm{\theta})=\operatorname{Tr}[(\rho-\sigma(\bm{\theta}))(\rho-\sigma(\bm{\theta}))^{\dagger}].$

With a similar notation used in McClean’s paper McClean  _et al._ (2018), we
can use $U$ to denote the unitary representation of circuits. And we can write
it as $U=U_{+}e^{-i\theta_{\mu}H}U_{-}$, where $H$ denotes the hermitian
operator and in most cases it will be the Pauli matrices, and they are
traceless. Since
$\operatorname{Tr}_{n}[\rho]=\operatorname{Tr}_{n}[\hat{\sigma}]$, we have

$\hat{\sigma}=(I_{A}\otimes V_{B})\rho(I_{A}\otimes V_{B}^{\dagger}).$

where $V$ is a fixed unitary and system $A$ denotes the first $n-1$ qubits and
the system $B$ denotes the last qubit. So $d_{A}=2^{n-1}$ and $d_{B}=2$. For
simplicity, we will hide the subscript in the following proof.

We then arrive at

$\sigma=(I\otimes UV)\rho(I\otimes V^{\dagger}U^{\dagger}).$

Next, we compute the partial derivative of $C_{n}$ w.r.t the $k$-th parameter.
Notice that the trace is linear, the derivative operation could pass through
the trace and hence we obtain,

$\partial_{\mu}C_{n}=\partial_{\mu}(\operatorname{Tr}(\rho^{2}+\sigma^{2}-2(\rho\sigma))=-2\operatorname{Tr}(\rho\partial_{\mu}(\sigma)),$

Now We start by calculating the mean of gradients, expanding the expression
for $\sigma$, we could find,

$\partial_{\mu}C_{n}=-2\operatorname{Tr}\left[\rho\left((I\otimes(\partial_{\mu}U)V)\rho(I\otimes
V^{{\dagger}}U^{\dagger})+(I\otimes UV)\rho(I\otimes
V^{{\dagger}}(\partial_{\mu}U^{\dagger}))\right)\right],$

by the chain rule of derivative. Since $U=U_{+}e^{-i\theta_{\mu}H}U_{-}$, we
could compute the derivatives as,

$\begin{cases}\partial_{\mu}U=-iU_{+}e^{-i\theta_{\mu}H}HU_{-}\\\
\partial_{\mu}U^{\dagger}=iU_{-}^{\dagger}He^{i\theta_{\mu}H}U_{+}^{\dagger}.\end{cases}$

For convenient, we define $\tilde{U}_{+}=U_{+}e^{-i\theta_{\mu}H}$.
Substituting the above into the expression of cost derivative to achieve,

$\partial_{\mu}C_{n}=2i\operatorname{Tr}\left[\rho\left((I\otimes\tilde{U}_{+}HU_{-}V)\rho(I\otimes
V^{{\dagger}}U^{\dagger})-(I\otimes UV)\rho(I\otimes
V^{{\dagger}}U_{-}^{\dagger}H\tilde{U}_{+}^{\dagger})\right)\right].$

Now we expand $U=\tilde{U}_{+}U_{-}$, and assume the $\tilde{U}_{-}=U_{-}V$

$\displaystyle\partial_{\mu}C_{n}$
$\displaystyle=2i\operatorname{Tr}\left[\rho\left((I\otimes\tilde{U}_{+}HU_{-}V)\rho(I\otimes
V^{{\dagger}}U_{-}^{\dagger}\tilde{U}_{+}^{{\dagger}})-(I\otimes\tilde{U}_{+}U_{-}V)\rho(I\otimes
V^{{\dagger}}U_{-}^{\dagger}H\tilde{U}_{+}^{\dagger})\right)\right]$
$\displaystyle=2i\operatorname{Tr}\left[\rho\left((I\otimes\tilde{U}_{+}H\tilde{U}_{-})\rho(I\otimes\tilde{U}_{-}^{{\dagger}}\tilde{U}_{+}^{{\dagger}})-(I\otimes\tilde{U}_{+}\tilde{U}_{-})\rho(I\otimes\tilde{U}_{-}^{{\dagger}}H\tilde{U}_{+}^{\dagger})\right)\right]$
$\displaystyle=2i\operatorname{Tr}\left[(I\otimes\tilde{U}_{+}^{{\dagger}})\rho(I\otimes\tilde{U}_{+})[I\otimes
H,(I\otimes\tilde{U}_{-})\rho(I\otimes\tilde{U}_{-}^{{\dagger}})]\right].$

where the $[A,B]=AB-BA$ denotes the commutator notation. Denote the commutator
$[I\otimes H,(I\otimes\tilde{U}_{-})\rho(I\otimes\tilde{U}_{-}^{{\dagger}})]$
by $T_{-}$, thus we have

$\displaystyle\partial_{\mu}C_{n}$
$\displaystyle=2i\operatorname{Tr}\left[(I\otimes\tilde{U}_{+}^{{\dagger}})\rho(I\otimes\tilde{U}_{+})T_{-}\right].$

Then we integrate over $\tilde{U}_{+}$ by using the lemma S6,

$\displaystyle\mathbb{E}[\partial_{\mu}C_{n}]$
$\displaystyle=2i\frac{\operatorname{Tr}[\operatorname{Tr}_{B}[\rho]\operatorname{Tr}_{B}[T_{-}]]}{d_{B}}$
$\displaystyle=i\operatorname{Tr}[\operatorname{Tr}_{B}[\rho]\operatorname{Tr}_{B}[T_{-}]].$

We can write the $\rho$ as

$\rho=\sum_{i,j}|i\rangle\\!\langle j|_{A}\otimes X_{i,j}.$

thus lead to

$\displaystyle\operatorname{Tr}_{B}[T_{-}]$
$\displaystyle=\operatorname{Tr}_{B}[[I\otimes
H,(I\otimes\tilde{U}_{-})\rho(I\otimes\tilde{U}_{-}^{{\dagger}})]]$
$\displaystyle=\sum_{i,j}\operatorname{Tr}_{B}[[I\otimes
H,(I\otimes\tilde{U}_{-})(|i\rangle\\!\langle j|_{A}\otimes
X_{i,j})(I\otimes\tilde{U}_{-}^{{\dagger}})]]$
$\displaystyle=\sum_{i,j}\operatorname{Tr}_{B}[|i\rangle\\!\langle j|\otimes
H\tilde{U}_{-}X_{i,j}\tilde{U}_{-}^{{\dagger}}-|i\rangle\\!\langle
j|\otimes\tilde{U}_{-}X_{i,j}\tilde{U}_{-}^{{\dagger}}H]$
$\displaystyle=\sum_{i,j}|i\rangle\\!\langle
j|(\operatorname{Tr}[H\tilde{U}_{-}X_{i,j}\tilde{U}_{-}^{{\dagger}}]-\operatorname{Tr}[\tilde{U}_{-}X_{i,j}\tilde{U}_{-}^{{\dagger}}H])$
$\displaystyle=0.$ (C.4)

Therefore, we have

$\displaystyle\mathbb{E}[\partial_{\mu}C_{n}]$ $\displaystyle=0.$

The mean of gradients is $0$. Based on the fact that the mean of gradients is
$0$, we then only need to consider the $\mathbb{E}[(\partial_{\mu}C_{n})^{2}]$
in order to determine the variance.

$\displaystyle{\operatorname{Var}}[\partial_{\mu}C_{n}]=\mathbb{E}[(\partial_{\mu}C_{n})^{2}]=-4\mathbb{E}_{\tilde{U}_{+},\tilde{U}_{-}}\left[(\operatorname{Tr}[(I\otimes\tilde{U}_{+}^{{\dagger}})\rho(I\otimes\tilde{U}_{+})T_{-}])^{2}\right].$

Using lemma S7, we have

$\displaystyle\mathbb{E}_{\tilde{U}_{+},\tilde{U}_{-}}\left[(\operatorname{Tr}[(I\otimes\tilde{U}_{+}^{{\dagger}})\rho(I\otimes\tilde{U}_{+})T_{-}])^{2}\right]$
$\displaystyle=\mathbb{E}_{\tilde{U}_{+},\tilde{U}_{-}}\left[(\sum_{p,q}\operatorname{Tr}[\tilde{U}_{+}\rho_{qp}\tilde{U}_{+}^{{\dagger}}T_{-pq}])(\sum_{m,n}\operatorname{Tr}[\tilde{U}_{+}\rho_{nm}\tilde{U}_{+}^{{\dagger}}T_{-mn}])\right]$
$\displaystyle=\mathbb{E}_{\tilde{U}_{+},\tilde{U}_{-}}\left[\sum_{p,q,m,n}\operatorname{Tr}[\tilde{U}_{+}\rho_{qp}\tilde{U}_{+}^{{\dagger}}T_{-pq}]\operatorname{Tr}[\tilde{U}_{+}\rho_{nm}\tilde{U}_{+}^{{\dagger}}T_{-mn}]\right]$
$\displaystyle=\sum_{p,q,m,n}\mathbb{E}_{\tilde{U}_{+},\tilde{U}_{-}}\left[\operatorname{Tr}[\tilde{U}_{+}\rho_{qp}\tilde{U}_{+}^{{\dagger}}T_{-pq}]\operatorname{Tr}[\tilde{U}_{+}\rho_{nm}\tilde{U}_{+}^{{\dagger}}T_{-mn}]\right].$

Then, according to lemma S5

$\displaystyle\sum_{p,q,m,n}\mathbb{E}_{\tilde{U}_{+},\tilde{U}_{-}}\left[\operatorname{Tr}[\tilde{U}_{+}\rho_{qp}\tilde{U}_{+}^{{\dagger}}T_{-pq}]\operatorname{Tr}[\tilde{U}_{+}\rho_{nm}\tilde{U}_{+}^{{\dagger}}T_{-mn}]\right]$
$\displaystyle=$
$\displaystyle\sum_{p,q,m,n}\mathbb{E}_{\tilde{U}_{-}}(\frac{1}{d_{B}^{2}-1}(\operatorname{Tr}[\rho_{qp}]\operatorname{Tr}[T_{-pq}]\operatorname{Tr}[\rho_{nm}]\operatorname{Tr}[T_{-mn}]+\operatorname{Tr}[\rho_{qp}\rho_{nm}]\operatorname{Tr}[T_{-pq}T_{-mn}])$
$\displaystyle-\frac{1}{d_{B}(d_{B}^{2}-1)}(\operatorname{Tr}[\rho_{qp}\rho_{nm}]\operatorname{Tr}[T_{-pq}]\operatorname{Tr}[T_{-mn}]+\operatorname{Tr}[\rho_{qp}]\operatorname{Tr}[\rho_{nm}]\operatorname{Tr}[T_{-pq}T_{-mn}])).$
(C.5)

Since

$\displaystyle\operatorname{Tr}[\rho_{qp}]$
$\displaystyle=\operatorname{Tr}[\operatorname{Tr}_{A}[(|p\rangle\\!\langle
q|\otimes I)\rho]]$ $\displaystyle=\operatorname{Tr}[(|p\rangle\\!\langle
q|\otimes I)\rho]$ $\displaystyle=\operatorname{Tr}[|p\rangle\\!\langle
q|\operatorname{Tr}_{B}[\rho]]$ $\displaystyle=\langle
q|\operatorname{Tr}_{B}[\rho]|p\rangle,$ (C.6)

and

$\displaystyle\operatorname{Tr}[T_{-pq}]$
$\displaystyle=\operatorname{Tr}[\operatorname{Tr}_{A}[(|q\rangle\\!\langle
p|\otimes I)T_{-}]]$ $\displaystyle=\operatorname{Tr}[(|q\rangle\\!\langle
p|\otimes I)T_{-}]$ $\displaystyle=\operatorname{Tr}[|q\rangle\\!\langle
p|\operatorname{Tr}_{B}[T_{-}]]$ $\displaystyle=0.$ (C.7)

where the Eq. C.7 holds because of Eq. C.4.

Thus the Eq. C.5 can be simplified as

$\displaystyle\sum_{p,q,m,n}\mathbb{E}_{\tilde{U}_{+},\tilde{U}_{-}}\left[\operatorname{Tr}[\tilde{U}_{+}\rho_{qp}\tilde{U}_{+}^{{\dagger}}T_{-pq}]\operatorname{Tr}[\tilde{U}_{+}\rho_{nm}\tilde{U}_{+}^{{\dagger}}T_{-mn}]\right]$
$\displaystyle=$
$\displaystyle\sum_{p,q,m,n}\mathbb{E}_{\tilde{U}_{-}}(\frac{1}{d_{B}^{2}-1}\operatorname{Tr}[\rho_{qp}\rho_{nm}]\operatorname{Tr}[T_{-pq}T_{-mn}]-\frac{1}{d_{B}(d_{B}^{2}-1)}\operatorname{Tr}[\rho_{qp}]\operatorname{Tr}[\rho_{nm}]\operatorname{Tr}[T_{-pq}T_{-mn}])$
$\displaystyle=$
$\displaystyle\sum_{p,q,m,n}\mathbb{E}_{\tilde{U}_{-}}\left(\frac{1}{d_{B}(d_{B}^{2}-1)}\operatorname{Tr}[T_{-pq}T_{-mn}](d_{B}\operatorname{Tr}[\rho_{qp}\rho_{nm}]-\operatorname{Tr}[\rho_{qp}]\operatorname{Tr}[\rho_{nm}])\right)$
$\displaystyle=$
$\displaystyle\sum_{p,q,m,n}\frac{1}{d_{B}(d_{B}^{2}-1)}(d_{B}\operatorname{Tr}[\rho_{qp}\rho_{nm}]-\operatorname{Tr}[\rho_{qp}]\operatorname{Tr}[\rho_{nm}])\mathbb{E}_{\tilde{U}_{-}}\left(\operatorname{Tr}[T_{-pq}T_{-mn}]\right).$

We now need to evaluate the other integral w.r.t $\tilde{U}_{-}$. A
simplification can be first done by noticing,

$\displaystyle T_{-pq}$
$\displaystyle=\operatorname{Tr}_{A}[(|q\rangle\\!\langle p|\otimes I)T_{-}]$
$\displaystyle=\operatorname{Tr}_{A}[I\otimes
H,(I\otimes\tilde{U}_{-})(|q\rangle\\!\langle p|\otimes
I)\rho(I\otimes\tilde{U}_{-}^{\dagger})]$
$\displaystyle=[H,\tilde{U}_{-}\operatorname{Tr}_{A}[|q\rangle\\!\langle
p|\otimes I)\rho]\tilde{U}_{-}^{\dagger}]$
$\displaystyle=[H,\tilde{U}_{-}\rho_{pq}\tilde{U}_{-}^{\dagger}],$

since $|p\rangle\\!\langle q|\otimes I$ commutes with other operators.
Therefore,

$\displaystyle\operatorname{Tr}[T_{-pq}T_{-mn}]$
$\displaystyle=\operatorname{Tr}[[H,\tilde{U}_{-}\rho_{pq}\tilde{U}_{-}^{\dagger}][H,\tilde{U}_{-}\rho_{mn}\tilde{U}_{-}^{\dagger}]]$
$\displaystyle=2\operatorname{Tr}[H\tilde{U}_{-}\rho_{pq}\tilde{U}_{-}^{\dagger}H\tilde{U}_{-}\rho_{mn}\tilde{U}_{-}^{\dagger}]-\operatorname{Tr}[\tilde{U}_{-}\rho_{pq}\rho_{mn}\tilde{U}_{-}^{\dagger}H^{2}]-\operatorname{Tr}[\tilde{U}_{-}\rho_{mn}\rho_{pq}\tilde{U}_{-}^{\dagger}H^{2}].$

So according to lemma S4,

$\displaystyle\mathbb{E}_{\tilde{U}_{-}}\left(\operatorname{Tr}[T_{-pq}T_{-mn}]\right)$
$\displaystyle=$
$\displaystyle\frac{2}{d_{B}^{2}-1}(\operatorname{Tr}[\rho_{pq}]\operatorname{Tr}[\rho_{mn}]\operatorname{Tr}[H^{2}]+\operatorname{Tr}[\rho_{pq}\rho_{mn}]\operatorname{Tr}^{2}[H])$
$\displaystyle-\frac{2}{d_{B}(d_{B}^{2}-1)}(\operatorname{Tr}[\rho_{pq}\rho_{mn}]\operatorname{Tr}[H^{2}]+\operatorname{Tr}[\rho_{pq}]\operatorname{Tr}[\rho_{mn}]\operatorname{Tr}^{2}[H])-\frac{2}{d_{B}}\operatorname{Tr}[\rho_{pq}\rho_{mn}]\operatorname{Tr}[H^{2}]$
$\displaystyle=$
$\displaystyle\frac{-2}{d_{B}(d_{B}^{2}-1)}(d_{B}\operatorname{Tr}[\rho_{pq}\rho_{mn}]-\operatorname{Tr}[\rho_{pq}]\operatorname{Tr}[\rho_{mn}])(d_{B}\operatorname{Tr}[H^{2}]-\operatorname{Tr}^{2}[H])$
$\displaystyle=$
$\displaystyle\frac{-2}{(d_{B}^{2}-1)}\operatorname{Tr}[H^{2}](d_{B}\operatorname{Tr}[\rho_{pq}\rho_{mn}]-\operatorname{Tr}[\rho_{pq}]\operatorname{Tr}[\rho_{mn}]).$

Then, we go back to Eq. C.1,

$\displaystyle\sum_{p,q,m,n}\mathbb{E}_{\tilde{U}_{+},\tilde{U}_{-}}\left[\operatorname{Tr}[\tilde{U}_{+}\rho_{qp}\tilde{U}_{+}^{{\dagger}}T_{-pq}]\operatorname{Tr}[\tilde{U}_{+}\rho_{nm}\tilde{U}_{+}^{{\dagger}}T_{-mn}]\right]$
$\displaystyle=$
$\displaystyle\sum_{p,q,m,n}\frac{-2}{d_{B}(d_{B}^{2}-1)^{2}}\operatorname{Tr}[H^{2}](d_{B}\operatorname{Tr}[\rho_{qp}\rho_{nm}]-\operatorname{Tr}[\rho_{qp}]\operatorname{Tr}[\rho_{nm}])(d_{B}\operatorname{Tr}[\rho_{pq}\rho_{mn}]-\operatorname{Tr}[\rho_{pq}]\operatorname{Tr}[\rho_{mn}]).$

First, we look at the $\operatorname{Tr}[\rho_{qp}\rho_{nm}]$

$\displaystyle\operatorname{Tr}[\rho_{qp}\rho_{nm}]$
$\displaystyle=\operatorname{Tr}[\operatorname{Tr}_{A}[(|p\rangle\\!\langle
q|\otimes I)\rho]\operatorname{Tr}_{A}[(|m\rangle\\!\langle n|\otimes
I)\rho]]$ $\displaystyle=\operatorname{Tr}[\sum_{i}\left(\langle i|\otimes
I\left((|p\rangle\\!\langle q|\otimes I)\rho\right)|i\rangle\otimes
I\right)\sum_{j}(\langle j|\otimes I(|p\rangle\\!\langle q|\otimes
I)\rho|j\rangle\otimes I)]$ $\displaystyle=\operatorname{Tr}[(\langle
q|\otimes I)\rho(|p\rangle\\!\langle n|\otimes I)\rho(|m\rangle\otimes I)]$
$\displaystyle=\operatorname{Tr}[\langle
q|\operatorname{Tr}_{B}[\rho(|p\rangle\\!\langle n|\otimes I)\rho]|m\rangle]$
$\displaystyle=\langle q|\operatorname{Tr}_{B}[\rho(|p\rangle\\!\langle
n|\otimes I)\rho]|m\rangle.$

Then,

$\displaystyle\sum_{p,q,m,n}\operatorname{Tr}[\rho_{qp}\rho_{nm}]\operatorname{Tr}[\rho_{pq}\rho_{mn}]$
$\displaystyle=$ $\displaystyle\sum_{p,q,m,n}\langle
q|\operatorname{Tr}_{B}[\rho(|p\rangle\\!\langle n|\otimes
I)\rho]|m\rangle\langle m|\operatorname{Tr}_{B}[\rho(|n\rangle\\!\langle
p|\otimes I)\rho]|q\rangle$ $\displaystyle=$
$\displaystyle\sum_{p,n}\operatorname{Tr}\left[\operatorname{Tr}_{B}[\rho(|p\rangle\\!\langle
n|\otimes I)\rho]\operatorname{Tr}_{B}[\rho(|n\rangle\\!\langle p|\otimes
I)\rho]\right].$

Suppose the Schmidt decomposition of $|\phi\rangle$ is

$\displaystyle|\phi\rangle=\sum_{k}\lambda_{k}|u_{k}\rangle_{A}|v_{k}\rangle_{B}.$
(C.8)

where $\\{|u_{k}\rangle\\}$ are orthogonal basis on the system A and
$\\{|v_{k}\rangle\\}$ are orthogonal basis on the system B. Therefore, we can
write the $\rho$ as

$\displaystyle\rho=\sum_{i,j}\lambda_{i}\lambda_{j}|u_{i}\rangle\\!\langle
u_{j}|\otimes|v_{i}\rangle\\!\langle v_{j}|.$ (C.9)

We can expand the $\rho$ in $\operatorname{Tr}_{B}[\rho(|p\rangle\\!\langle
n|\otimes I)\rho]$

$\displaystyle\operatorname{Tr}_{B}[\rho(|p\rangle\\!\langle n|\otimes
I)\rho]$ $\displaystyle=$
$\displaystyle\operatorname{Tr}_{B}[(\sum_{i,j}\lambda_{i}\lambda_{j}|u_{i}\rangle\\!\langle
u_{j}|\otimes|v_{i}\rangle\\!\langle v_{j}|)(|p\rangle\\!\langle n|\otimes
I)(\sum_{k,l}\lambda_{k}\lambda_{l}|u_{k}\rangle\\!\langle
u_{l}|\otimes|v_{k}\rangle\\!\langle v_{l}|)]$ $\displaystyle=$
$\displaystyle\sum_{i,j,k,l}\lambda_{i}\lambda_{j}\lambda_{k}\lambda_{l}\operatorname{Tr}_{B}[|u_{i}\rangle\\!\langle
u_{j}||p\rangle\\!\langle n||u_{k}\rangle\\!\langle
u_{l}|\otimes|v_{i}\rangle\\!\langle v_{j}||v_{k}\rangle\\!\langle v_{l}|]$
$\displaystyle=$
$\displaystyle\sum_{i,j}\lambda_{i}^{2}\lambda_{j}^{2}|u_{i}\rangle\\!\langle
u_{j}||p\rangle\\!\langle n||u_{j}\rangle\\!\langle u_{i}|.$

Thus, we arrive at

$\displaystyle\sum_{p,n}\operatorname{Tr}\left[\operatorname{Tr}_{B}[\rho(|p\rangle\\!\langle
n|\otimes I)\rho]\operatorname{Tr}_{B}[\rho(|n\rangle\\!\langle p|\otimes
I)\rho]\right]$ $\displaystyle=$
$\displaystyle\sum_{p,n}\operatorname{Tr}[(\sum_{i,j}\lambda_{i}^{2}\lambda_{j}^{2}|u_{i}\rangle\\!\langle
u_{j}||p\rangle\\!\langle n||u_{j}\rangle\\!\langle
u_{i}|)(\sum_{k,l}\lambda_{k}^{2}\lambda_{l}^{2}|u_{k}\rangle\\!\langle
u_{l}||p\rangle\\!\langle n||u_{k}\rangle\\!\langle u_{l}|)]$ $\displaystyle=$
$\displaystyle\sum_{p,n}\operatorname{Tr}[\sum_{i,j,k,l}]\lambda_{i}^{2}\lambda_{j}^{2}\lambda_{k}^{2}\lambda_{l}^{2}|u_{i}\rangle\\!\langle
u_{j}||p\rangle\\!\langle n||u_{j}\rangle\\!\langle
u_{i}||u_{k}\rangle\\!\langle u_{l}||n\rangle\\!\langle
p||u_{l}\rangle\\!\langle u_{k}|$ $\displaystyle=$
$\displaystyle\sum_{p,n}\sum_{i,j,l}\lambda_{i}^{4}\lambda_{j}^{2}\lambda_{l}^{2}\operatorname{Tr}[\langle
u_{j}||p\rangle\\!\langle n||u_{j}\rangle\\!\langle u_{l}||n\rangle\\!\langle
p||u_{l}\rangle]$ $\displaystyle=$
$\displaystyle\sum_{i,j,l}\lambda_{i}^{4}\lambda_{j}^{2}\lambda_{l}^{2}\operatorname{Tr}[\operatorname{Tr}[|u_{l}\rangle\\!\langle
u_{j}|]\operatorname{Tr}[|u_{j}\rangle\\!\langle u_{l}|]]$ $\displaystyle=$
$\displaystyle\sum_{i,j}\lambda_{i}^{4}\lambda_{j}^{4}$ $\displaystyle=$
$\displaystyle(\sum_{i}\lambda_{i}^{4})^{2}.$

Then we look at the
$\operatorname{Tr}[\rho_{qp}]\operatorname{Tr}[\rho_{pq}]\operatorname{Tr}[\rho_{mn}]\operatorname{Tr}[\rho_{nm}]$,

$\displaystyle\sum_{p,q,m,n}\operatorname{Tr}[\rho_{qp}]\operatorname{Tr}[\rho_{pq}]\operatorname{Tr}[\rho_{mn}]\operatorname{Tr}[\rho_{nm}]$
$\displaystyle=$ $\displaystyle\sum_{p,q,m,n}\langle
q|\operatorname{Tr}_{B}[\rho]|p\rangle\langle
p|\operatorname{Tr}_{B}[\rho]|q\rangle\langle
m|\operatorname{Tr}_{B}[\rho]|n\rangle\langle
n|\operatorname{Tr}_{B}[\rho]|m\rangle$ $\displaystyle=$
$\displaystyle\operatorname{Tr}[\operatorname{Tr}_{B}[\rho]\operatorname{Tr}_{B}[\rho]]\operatorname{Tr}[\operatorname{Tr}_{B}[\rho]\operatorname{Tr}_{B}[\rho]]$
$\displaystyle=$
$\displaystyle(\operatorname{Tr}[\operatorname{Tr}_{B}[\rho]\operatorname{Tr}_{B}[\rho]])^{2}$
$\displaystyle=$ $\displaystyle(\sum_{i}\lambda_{i}^{4})^{2}.$

Now, we look at the
$\operatorname{Tr}[\rho_{qp}\rho_{nm}]\operatorname{Tr}[\rho_{pq}]\operatorname{Tr}[\rho_{mn}]$

$\displaystyle\operatorname{Tr}[\rho_{qp}\rho_{nm}]$ $\displaystyle=\langle
n|\operatorname{Tr}_{B}[\rho(|m\rangle\\!\langle q|\otimes I)\rho]|p\rangle$
(C.10) $\displaystyle=\sum_{i,j}\lambda_{i}^{2}\lambda_{j}^{2}\langle
n||u_{i}\rangle\\!\langle u_{j}||m\rangle\\!\langle q||u_{j}\rangle\\!\langle
u_{i}||p\rangle.$ (C.11)

and

$\displaystyle\operatorname{Tr}[\rho_{pq}]\operatorname{Tr}[\rho_{mn}]$
$\displaystyle=\langle p|\operatorname{Tr}_{B}[\rho]|q\rangle\langle
m|\operatorname{Tr}_{B}[\rho]|n\rangle$
$\displaystyle=\sum_{i,j}\lambda_{i}^{2}\lambda_{j}^{2}\langle
p||u_{i}\rangle\\!\langle u_{i}||q\rangle\langle m||u_{j}\rangle\\!\langle
u_{j}||n\rangle.$

Thus,

$\displaystyle\sum_{p,q,m,n}\operatorname{Tr}[\rho_{qp}\rho_{nm}]\operatorname{Tr}[\rho_{pq}]\operatorname{Tr}[\rho_{mn}]$
$\displaystyle=$
$\displaystyle\sum_{p,q,m,n}(\sum_{k,l}\lambda_{k}^{2}\lambda_{l}^{2}\langle
n||u_{k}\rangle\\!\langle u_{l}||m\rangle\\!\langle q||u_{k}\rangle\\!\langle
u_{l}||p\rangle)(\sum_{i,j}\lambda_{i}^{2}\lambda_{j}^{2}\langle
p||u_{i}\rangle\\!\langle u_{i}||q\rangle\langle m||u_{j}\rangle\\!\langle
u_{j}||n\rangle)$ $\displaystyle=$
$\displaystyle\sum_{p,q,m,n}\sum_{i,j,k,l}\lambda_{i}^{2}\lambda_{j}^{2}\lambda_{k}^{2}\lambda_{l}^{2}(\langle
n||u_{k}\rangle\\!\langle u_{l}||m\rangle\\!\langle q||u_{k}\rangle\\!\langle
u_{l}||p\rangle\langle p||u_{i}\rangle\\!\langle u_{i}||q\rangle\langle
m||u_{j}\rangle\\!\langle u_{j}||n\rangle)$ $\displaystyle=$
$\displaystyle\sum_{q,m}\sum_{i,j,k,l}\lambda_{i}^{2}\lambda_{j}^{2}\lambda_{k}^{2}\lambda_{l}^{2}\operatorname{Tr}[|u_{k}\rangle\\!\langle
u_{l}||m\rangle\\!\langle q||u_{k}\rangle\\!\langle
u_{l}||u_{i}\rangle\\!\langle u_{i}||q\rangle\langle m||u_{j}\rangle\\!\langle
u_{j}|]$ $\displaystyle=$
$\displaystyle\sum_{i,j,k,l}\lambda_{i}^{2}\lambda_{j}^{2}\lambda_{k}^{2}\lambda_{l}^{2}\operatorname{Tr}[|u_{k}\rangle\\!\langle
u_{l}||u_{i}\rangle\\!\langle u_{i}|]\operatorname{Tr}[|u_{j}\rangle\\!\langle
u_{j}||u_{k}\rangle\\!\langle u_{l}|]$ $\displaystyle=$
$\displaystyle\sum_{i}\lambda_{i}^{8}.$

Therefore, we have,

$\displaystyle\sum_{p,q,m,n}(d_{B}\operatorname{Tr}[\rho_{pq}\rho_{mn}]-\operatorname{Tr}[\rho_{pq}]\operatorname{Tr}[\rho_{mn}])$
$\displaystyle=$
$\displaystyle(d_{B}^{2}+1)(\sum_{i}\lambda_{i}^{4})^{2}-2d_{B}(\sum_{i}\lambda_{i}^{8}).$

So,

$\displaystyle{\operatorname{Var}}[\partial_{\mu}C_{n}]=\frac{8}{d_{B}(d_{B}^{2}-1)^{2}}\operatorname{Tr}[H^{2}]((d_{B}^{2}+1)(\sum_{i}\lambda_{i}^{4})^{2}-2d_{B}(\sum_{i}\lambda_{i}^{8}))$
(C.12)

Since the $d_{B}$ is $2$, we can simplify the equation above as

$\displaystyle{\operatorname{Var}}[\partial_{\mu}C_{n}]$
$\displaystyle=\frac{4}{9}\operatorname{Tr}[H^{2}](\lambda_{1}^{8}+\lambda_{2}^{8}+10\lambda_{1}^{4}\lambda_{2}^{4})$
(C.13) $\displaystyle=\frac{8}{9}(c_{1}^{4}+c_{2}^{4}+10c_{1}^{2}c_{2}^{2}).$
(C.14)

where the $c_{1}=\lambda_{1}^{2}$, $c_{2}=\lambda_{2}^{2}$ such that
$c_{1}+c_{2}=1$, and $\operatorname{Tr}[H^{2}]=d_{B}=2$.

Therefore, we can simply get the range of the variance.

$\displaystyle\frac{16}{27}\leq{\operatorname{Var}}[\partial_{\mu}C_{n}]\leq\frac{8}{9}$
(C.15)

###  C.2 Trainability of the middle step

###### Lemma S9

For the target pure state $\rho_{ABC}$ on system $ABC$, suppose we start from
a initial state $\hat{\sigma}$ such that
$\operatorname{Tr}_{BC}[\rho]=\operatorname{Tr}_{BC}[\hat{\sigma}]$ and the
output state is $\sigma$. If the cost function is

$C=\operatorname{Tr}[(\operatorname{Tr}_{C}[\rho]-\operatorname{Tr}_{C}[\sigma])(\operatorname{Tr}_{C}[\rho]-\operatorname{Tr}_{C}[\sigma])]$
(C.16)

and the circuit is acting on system $BC$ while forming a local 4-design, then
${{\mathbb{E}}}[\partial_{\mu}C]=0$ and the variance of cost gradient scales
as
${\operatorname{Var}}[\partial_{\mu}C]\in\mathcal{O}(\frac{1}{d_{B}^{3}d_{C}})$,
where $d_{B},d_{C}$ denote the dimension of system $B$ and $C$ respectively.

Since $\operatorname{Tr}_{BC}[\rho]=\operatorname{Tr}_{BC}[\hat{\sigma}]$,
there exist a fixed unitary $V$ such that

$\hat{\sigma}=(I_{A}\otimes V_{BC})\rho(I_{A}\otimes V_{BC}^{\dagger}).$
(C.17)

Then

$\sigma=(I\otimes UV)\rho(I\otimes V^{\dagger}U^{\dagger}).$ (C.18)

Then, the cost gradient becomes,

$\displaystyle\partial_{\mu}C$
$\displaystyle=2\operatorname{Tr}[\operatorname{Tr}_{C}[\sigma]\partial_{\mu}\operatorname{Tr}_{C}[\sigma]-2\operatorname{Tr}[\operatorname{Tr}_{C}[\rho]\partial_{\mu}\operatorname{Tr}_{C}[\sigma]]$
$\displaystyle=2i\operatorname{Tr}[\operatorname{Tr}_{C}[(I\otimes
U_{+}U_{-}V)\rho(I\otimes
V^{\dagger}U_{-}^{\dagger}U_{+}^{\dagger})-\rho]\operatorname{Tr}_{C}[(I\otimes
U_{+}U_{-}V)\rho(I\otimes V^{\dagger}U_{-}^{\dagger}HU_{+}^{\dagger})$
$\displaystyle-(I\otimes U_{+}HU_{-}V)\rho(I\otimes
V^{\dagger}U_{-}^{\dagger}U_{+}^{\dagger})]]$

We exploit the RTNI package Fukuda  _et al._ (2019a) to calculate the mean of
the cost gradient. It turns out that the mean of the cost gradient is zero.

$\mathbb{E}[\partial_{\mu}C]=0$

Then we consider the variance

$\displaystyle\rm{Var}[\partial_{\mu}C]=-\mathbb{E}[(\partial_{\mu}C)^{2}]$

With the RTNI package Fukuda  _et al._ (2019b), it turns out that the exact
expression of the variance is dominant by

$\operatorname{Var}[\partial_{\mu}C]\xrightarrow{d\rightarrow\infty}\frac{\operatorname{Tr}[H^{2}]}{d_{B}^{2}(d_{B}^{2}d_{C}^{2}-1)}\cdot\left(\begin{array}[]{cc}\leavevmode\hbox
to114.21pt{\vbox to50.19pt{\pgfpicture\makeatletter\hbox{\hskip
21.53957pt\lower 10.46979pt\hbox to0.0pt{\pgfsys@beginscope\pgfsys@invoke{
}\definecolor{pgfstrokecolor}{rgb}{0,0,0}\pgfsys@color@rgb@stroke{0}{0}{0}\pgfsys@invoke{
}\pgfsys@color@rgb@fill{0}{0}{0}\pgfsys@invoke{
}\pgfsys@setlinewidth{0.4pt}\pgfsys@invoke{ }\nullfont\hbox
to0.0pt{\pgfsys@beginscope\pgfsys@invoke{ }{{}} ; ; ; ; ; ; ; ; ; ; ;
{}{{}}\hbox{\hbox{{\pgfsys@beginscope\pgfsys@invoke{ }{{}{{}}{}{}}
\pgfsys@invoke{\lxSVG@closescope }\pgfsys@endscope}}}
{}{{}}\hbox{\hbox{{\pgfsys@beginscope\pgfsys@invoke{ }{{}{{}}{}{}}
\pgfsys@invoke{\lxSVG@closescope }\pgfsys@endscope}}}
{}{{}}\hbox{\hbox{{\pgfsys@beginscope\pgfsys@invoke{ }{{}{{}}{}{}}
\pgfsys@invoke{\lxSVG@closescope }\pgfsys@endscope}}}
{}{{}}\hbox{\hbox{{\pgfsys@beginscope\pgfsys@invoke{ }{{}{{}}{}{}}
\pgfsys@invoke{\lxSVG@closescope }\pgfsys@endscope}}}
\par{}{{}}\hbox{\hbox{{\pgfsys@beginscope\pgfsys@invoke{ }{{}{{}}{}{}}
\pgfsys@invoke{\lxSVG@closescope }\pgfsys@endscope}}}
{}{{}}\hbox{\hbox{{\pgfsys@beginscope\pgfsys@invoke{ }{{}{{}}{}{}}
\pgfsys@invoke{\lxSVG@closescope }\pgfsys@endscope}}}
{}{{}}\hbox{\hbox{{\pgfsys@beginscope\pgfsys@invoke{ }{{}{{}}{}{}}
\pgfsys@invoke{\lxSVG@closescope }\pgfsys@endscope}}}
\par{}{{}}\hbox{\hbox{{\pgfsys@beginscope\pgfsys@invoke{ }{{}{{}}{}{}}
\pgfsys@invoke{\lxSVG@closescope }\pgfsys@endscope}}}
{}{{}}\hbox{\hbox{{\pgfsys@beginscope\pgfsys@invoke{ }{{}{{}}{}{}}
\pgfsys@invoke{\lxSVG@closescope }\pgfsys@endscope}}}
\par{}{{}}{}{{}}{}{{}}{}{}{}{}\pgfsys@moveto{-14.22638pt}{60.46211pt}\pgfsys@curveto{-21.33957pt}{60.46211pt}{-21.33957pt}{46.23573pt}{-14.22638pt}{46.23573pt}\pgfsys@stroke\pgfsys@invoke{
}
{}{{}}{}{{}}{}{{}}{}{}{}{}\pgfsys@moveto{28.45276pt}{60.46211pt}\pgfsys@curveto{35.56595pt}{60.46211pt}{35.56595pt}{46.23573pt}{28.45276pt}{46.23573pt}\pgfsys@stroke\pgfsys@invoke{
}
\par{}{{}}{}{{}}{}{{}}{}{}{}{}\pgfsys@moveto{42.67914pt}{60.46211pt}\pgfsys@curveto{35.56595pt}{60.46211pt}{35.56595pt}{46.23573pt}{42.67914pt}{46.23573pt}\pgfsys@stroke\pgfsys@invoke{
}
{}{{}}{}{{}}{}{{}}{}{}{}{}\pgfsys@moveto{85.35828pt}{60.46211pt}\pgfsys@curveto{92.47147pt}{60.46211pt}{92.47147pt}{46.23573pt}{85.35828pt}{46.23573pt}\pgfsys@stroke\pgfsys@invoke{
}
\par{}{{}}{}{{}}{}{{}}{}{}{}{}\pgfsys@moveto{-14.22638pt}{32.00935pt}\pgfsys@curveto{-17.78297pt}{32.00935pt}{-17.78297pt}{21.33957pt}{-14.22638pt}{21.33957pt}\pgfsys@stroke\pgfsys@invoke{
}
{}{{}}{}{{}}{}{{}}{}{}{}{}\pgfsys@moveto{71.1319pt}{32.00935pt}\pgfsys@curveto{67.5753pt}{32.00935pt}{67.5753pt}{21.33957pt}{71.1319pt}{21.33957pt}\pgfsys@stroke\pgfsys@invoke{
}
\par{}{{}}{}{{}}{}{{}}{}{}{}{}\pgfsys@moveto{0.0pt}{32.00935pt}\pgfsys@curveto{3.5566pt}{32.00935pt}{3.5566pt}{21.33957pt}{0.0pt}{21.33957pt}\pgfsys@stroke\pgfsys@invoke{
}
{}{{}}{}{{}}{}{{}}{}{}{}{}\pgfsys@moveto{85.35828pt}{32.00935pt}\pgfsys@curveto{88.91487pt}{32.00935pt}{88.91487pt}{21.33957pt}{85.35828pt}{21.33957pt}\pgfsys@stroke\pgfsys@invoke{
}
\par{}{{}}{}{{}}{}{{}}{}{}{}{}\pgfsys@moveto{14.22638pt}{32.00935pt}\pgfsys@curveto{10.66978pt}{32.00935pt}{10.66978pt}{24.89616pt}{14.22638pt}{24.89616pt}\pgfsys@stroke\pgfsys@invoke{
}
{}{{}}{}{{}}{}{{}}{}{}{}{}\pgfsys@moveto{56.90552pt}{32.00935pt}\pgfsys@curveto{60.46211pt}{32.00935pt}{60.46211pt}{24.89616pt}{56.90552pt}{24.89616pt}\pgfsys@stroke\pgfsys@invoke{
}
\par{}{{}}{}{{}}{}{{}}{}{}{}{}\pgfsys@moveto{14.22638pt}{39.12254pt}\pgfsys@curveto{7.11319pt}{39.12254pt}{7.11319pt}{17.78297pt}{14.22638pt}{17.78297pt}\pgfsys@stroke\pgfsys@invoke{
}
{}{{}}{}{{}}{}{{}}{}{}{}{}\pgfsys@moveto{56.90552pt}{39.12254pt}\pgfsys@curveto{64.0187pt}{39.12254pt}{64.0187pt}{17.78297pt}{56.90552pt}{17.78297pt}\pgfsys@stroke\pgfsys@invoke{
}
\par{}{{}}{}{{}}{}{{}}{}{}{}{}\pgfsys@moveto{-14.22638pt}{39.12254pt}\pgfsys@curveto{-21.33957pt}{39.12254pt}{-21.33957pt}{10.66978pt}{-14.22638pt}{10.66978pt}\pgfsys@stroke\pgfsys@invoke{
}
{}{{}}{}{{}}{}{{}}{}{}{}{}\pgfsys@moveto{85.35828pt}{39.12254pt}\pgfsys@curveto{92.47147pt}{39.12254pt}{92.47147pt}{10.66978pt}{85.35828pt}{10.66978pt}\pgfsys@stroke\pgfsys@invoke{
}
\par\par{}{{}}{}{{}}{}{{}}{}{}{}{}\pgfsys@moveto{0.0pt}{39.12254pt}\pgfsys@curveto{7.11319pt}{32.00935pt}{7.11319pt}{14.22638pt}{14.22638pt}{14.22638pt}\pgfsys@stroke\pgfsys@invoke{
}
\par{}{{}}{}{{}}{}{{}}{}{}{}{}\pgfsys@moveto{71.1319pt}{39.12254pt}\pgfsys@curveto{64.0187pt}{32.00935pt}{64.0187pt}{14.22638pt}{56.90552pt}{14.22638pt}\pgfsys@stroke\pgfsys@invoke{
} \par{}{{}}{}
{}{}{}\pgfsys@moveto{-14.22638pt}{60.46211pt}\pgfsys@lineto{28.45276pt}{60.46211pt}\pgfsys@stroke\pgfsys@invoke{
} {}{{}}{}
{}{}{}\pgfsys@moveto{-14.22638pt}{46.23573pt}\pgfsys@lineto{28.45276pt}{46.23573pt}\pgfsys@stroke\pgfsys@invoke{
} \par{}{{}}{}
{}{}{}\pgfsys@moveto{-14.22638pt}{21.33957pt}\pgfsys@lineto{0.0pt}{21.33957pt}\pgfsys@stroke\pgfsys@invoke{
} \par{}{{}}{}
{}{}{}\pgfsys@moveto{42.67914pt}{60.46211pt}\pgfsys@lineto{85.35828pt}{60.46211pt}\pgfsys@stroke\pgfsys@invoke{
} {}{{}}{}
{}{}{}\pgfsys@moveto{42.67914pt}{46.23573pt}\pgfsys@lineto{85.35828pt}{46.23573pt}\pgfsys@stroke\pgfsys@invoke{
} \par{}{{}}{}
{}{}{}\pgfsys@moveto{71.1319pt}{21.33957pt}\pgfsys@lineto{85.35828pt}{21.33957pt}\pgfsys@stroke\pgfsys@invoke{
} \par{}{{}}{}
{}{}{}\pgfsys@moveto{21.33957pt}{39.12254pt}\pgfsys@lineto{49.79233pt}{39.12254pt}\pgfsys@stroke\pgfsys@invoke{
} {}{{}}{}
{}{}{}\pgfsys@moveto{21.33957pt}{32.00935pt}\pgfsys@lineto{49.79233pt}{32.00935pt}\pgfsys@stroke\pgfsys@invoke{
} \par{}{{}}{}
{}{}{}\pgfsys@moveto{14.22638pt}{14.22638pt}\pgfsys@lineto{56.90552pt}{14.22638pt}\pgfsys@stroke\pgfsys@invoke{
} \par{}{{}}{}
{}{}{}\pgfsys@moveto{14.22638pt}{24.89616pt}\pgfsys@lineto{56.90552pt}{24.89616pt}\pgfsys@stroke\pgfsys@invoke{
} {}{{}}{}
{}{}{}\pgfsys@moveto{14.22638pt}{17.78297pt}\pgfsys@lineto{56.90552pt}{17.78297pt}\pgfsys@stroke\pgfsys@invoke{
} \par{}{{}}{}
{}{}{}\pgfsys@moveto{-14.22638pt}{10.66978pt}\pgfsys@lineto{85.35828pt}{10.66978pt}\pgfsys@stroke\pgfsys@invoke{
} \par{{}}{{}}{}{{}}{} {}{{}}{}{}{}{}{{}}{}\pgfsys@beginscope\pgfsys@invoke{
}\definecolor[named]{pgffillcolor}{rgb}{0.8,0.9,1}\pgfsys@color@rgb@fill{0.8}{0.9}{1}\pgfsys@invoke{
}{}\pgfsys@moveto{14.22638pt}{28.45276pt}\pgfsys@moveto{14.22638pt}{28.45276pt}\pgfsys@lineto{14.22638pt}{49.79233pt}\pgfsys@lineto{28.45276pt}{49.79233pt}\pgfsys@lineto{28.45276pt}{28.45276pt}\pgfsys@closepath\pgfsys@moveto{28.45276pt}{49.79233pt}\pgfsys@fillstroke\pgfsys@invoke{
} \pgfsys@invoke{\lxSVG@closescope
}\pgfsys@endscope{{}}\hbox{\hbox{{\pgfsys@beginscope\pgfsys@invoke{ }{{}{}{{
{}{}}}{ {}{}} {{}{{}}}{{}{}}{}{{}{}} {
}{{{{}}\pgfsys@beginscope\pgfsys@invoke{
}\pgfsys@transformcm{1.0}{0.0}{0.0}{1.0}{19.53003pt}{41.85274pt}\pgfsys@invoke{
}\hbox{{\definecolor{pgfstrokecolor}{rgb}{0,0,0}\pgfsys@color@rgb@stroke{0}{0}{0}\pgfsys@invoke{
}\pgfsys@color@rgb@fill{0}{0}{0}\pgfsys@invoke{ }\hbox{{\scriptsize$\rho$}}
}}\pgfsys@invoke{\lxSVG@closescope }\pgfsys@endscope}}}
\pgfsys@invoke{\lxSVG@closescope }\pgfsys@endscope}}} {{}}{{}}{}{{}}{}
{}{{}}{}{}{}{}{{}}{}\pgfsys@beginscope\pgfsys@invoke{
}\definecolor[named]{pgffillcolor}{rgb}{0.8,0.9,1}\pgfsys@color@rgb@fill{0.8}{0.9}{1}\pgfsys@invoke{
}{}\pgfsys@moveto{42.67914pt}{28.45276pt}\pgfsys@moveto{42.67914pt}{28.45276pt}\pgfsys@lineto{42.67914pt}{49.79233pt}\pgfsys@lineto{56.90552pt}{49.79233pt}\pgfsys@lineto{56.90552pt}{28.45276pt}\pgfsys@closepath\pgfsys@moveto{56.90552pt}{49.79233pt}\pgfsys@fillstroke\pgfsys@invoke{
} \pgfsys@invoke{\lxSVG@closescope
}\pgfsys@endscope{{}}{{}}\hbox{\hbox{{\pgfsys@beginscope\pgfsys@invoke{
}{{}{}{{ {}{}}}{ {}{}} {{}{{}}}{{}{}}{}{{}{}} {
}{{{{}}\pgfsys@beginscope\pgfsys@invoke{
}\pgfsys@transformcm{1.0}{0.0}{0.0}{1.0}{47.98279pt}{41.85274pt}\pgfsys@invoke{
}\hbox{{\definecolor{pgfstrokecolor}{rgb}{0,0,0}\pgfsys@color@rgb@stroke{0}{0}{0}\pgfsys@invoke{
}\pgfsys@color@rgb@fill{0}{0}{0}\pgfsys@invoke{ }\hbox{{\scriptsize$\rho$}}
}}\pgfsys@invoke{\lxSVG@closescope }\pgfsys@endscope}}}
\pgfsys@invoke{\lxSVG@closescope }\pgfsys@endscope}}} {{}}{{}}{}{{}}{}
{}{{}}{}{}{}{}{{}}{}\pgfsys@beginscope\pgfsys@invoke{
}\definecolor[named]{pgffillcolor}{rgb}{0.8,0.9,1}\pgfsys@color@rgb@fill{0.8}{0.9}{1}\pgfsys@invoke{
}{}\pgfsys@moveto{-14.22638pt}{28.45276pt}\pgfsys@moveto{-14.22638pt}{28.45276pt}\pgfsys@lineto{-14.22638pt}{49.79233pt}\pgfsys@lineto{0.0pt}{49.79233pt}\pgfsys@lineto{0.0pt}{28.45276pt}\pgfsys@closepath\pgfsys@moveto{0.0pt}{49.79233pt}\pgfsys@fillstroke\pgfsys@invoke{
} \pgfsys@invoke{\lxSVG@closescope
}\pgfsys@endscope{{}}{{}}\hbox{\hbox{{\pgfsys@beginscope\pgfsys@invoke{
}{{}{}{{ {}{}}}{ {}{}} {{}{{}}}{{}{}}{}{{}{}} {
}{{{{}}\pgfsys@beginscope\pgfsys@invoke{
}\pgfsys@transformcm{1.0}{0.0}{0.0}{1.0}{-8.92273pt}{41.85274pt}\pgfsys@invoke{
}\hbox{{\definecolor{pgfstrokecolor}{rgb}{0,0,0}\pgfsys@color@rgb@stroke{0}{0}{0}\pgfsys@invoke{
}\pgfsys@color@rgb@fill{0}{0}{0}\pgfsys@invoke{ }\hbox{{\scriptsize$\rho$}}
}}\pgfsys@invoke{\lxSVG@closescope }\pgfsys@endscope}}}
\pgfsys@invoke{\lxSVG@closescope }\pgfsys@endscope}}} {{}}{{}}{}{{}}{}
{}{{}}{}{}{}{}{{}}{}\pgfsys@beginscope\pgfsys@invoke{
}\definecolor[named]{pgffillcolor}{rgb}{0.8,0.9,1}\pgfsys@color@rgb@fill{0.8}{0.9}{1}\pgfsys@invoke{
}{}\pgfsys@moveto{71.1319pt}{28.45276pt}\pgfsys@moveto{71.1319pt}{28.45276pt}\pgfsys@lineto{71.1319pt}{49.79233pt}\pgfsys@lineto{85.35828pt}{49.79233pt}\pgfsys@lineto{85.35828pt}{28.45276pt}\pgfsys@closepath\pgfsys@moveto{85.35828pt}{49.79233pt}\pgfsys@fillstroke\pgfsys@invoke{
} \pgfsys@invoke{\lxSVG@closescope
}\pgfsys@endscope{{}}{{}}\hbox{\hbox{{\pgfsys@beginscope\pgfsys@invoke{
}{{}{}{{ {}{}}}{ {}{}} {{}{{}}}{{}{}}{}{{}{}} {
}{{{{}}\pgfsys@beginscope\pgfsys@invoke{
}\pgfsys@transformcm{1.0}{0.0}{0.0}{1.0}{76.43555pt}{41.85274pt}\pgfsys@invoke{
}\hbox{{\definecolor{pgfstrokecolor}{rgb}{0,0,0}\pgfsys@color@rgb@stroke{0}{0}{0}\pgfsys@invoke{
}\pgfsys@color@rgb@fill{0}{0}{0}\pgfsys@invoke{ }\hbox{{\scriptsize$\rho$}}
}}\pgfsys@invoke{\lxSVG@closescope }\pgfsys@endscope}}}
\pgfsys@invoke{\lxSVG@closescope }\pgfsys@endscope}}} \par
\pgfsys@invoke{\lxSVG@closescope }\pgfsys@endscope{{
{}{}{}{}{}}{{{}}{{}}}}{}{}\hss}\pgfsys@discardpath\pgfsys@invoke{\lxSVG@closescope
}\pgfsys@endscope\hss}}\lxSVG@closescope\endpgfpicture}}\end{array}\right)$

We know that $\operatorname{Tr}[H^{2}]=d_{B}d_{C}$, thus we have

${\operatorname{Var}}[\partial_{\mu}C]\in\mathcal{O}(\frac{g(\rho)}{d_{B}^{3}d_{C}}),$

where $g(\rho)$ denotes the dominant factor from the tensor product
illustrated above. Finally, we can conclude the following Proposition,

###### Proposition S10

For the $k$-th learning step ($k\leq n$) in QSSM, the mean of cost gradient is
0, and the variance of cost gradient scales as
${\operatorname{Var}}[\partial_{\mu}C_{k}]\in\mathcal{O}(2^{-n_{k}})$, where
$n_{k}$ is the circuit width of $k$-th learning step.

Suppose the target state is $\rho$ and the input state for $k$-the learning
step is $\hat{\sigma}$. We assume system $A$ denotes the first $k-1$ qubits,
system $B$ denotes the $k$-th qubit and system $C$ denotes the $(k+1)$-th
qubit to the $(k+n_{k}-1)$-th qubit. With the definition of $n_{k}$ claimed in
the text, there exists a purification $\hat{\rho}_{ABC}$ of $\rho_{A}$ on
system $ABC$. According to lemma S9, we can easily know that

${\operatorname{Var}}[\partial_{\mu}C_{k}]\in\mathcal{O}(\frac{1}{2^{n_{k}+2}})=\mathcal{O}(2^{-n_{k}})$

###### Proposition S11

[Trainability] Given the state learning algorithm stated in Proposition 1, for
an $n$-qubit pure target state $\rho$ represented by $n$ ordered quantum
registers $q_{1},q_{2},\cdots,q_{n}$ with a rank sequence ${\cal
R}_{\rho}=\\{r_{1},r_{2},\cdots r_{n-1},r_{n}\\}$, if one of the
$U_{\pm}^{(k)}$ in the $k$-th scattering layer $U_{k}$ forms at least local
unitary $4$-design, the expectation and the variance of $C_{k}$ with respect
to $\theta_{\mu}$ can be upper bounded by,

${{\mathbb{E}}}[\partial_{\mu}C_{k}]=0;\quad{\operatorname{Var}}[\partial_{\mu}C_{k}]\in{\cal
O}\left(\frac{g(\rho_{k})}{r_{k}}\right),$

where the expectation is computed regarding the Haar measure and the factor
$g(\rho_{k})$ scales polynomially in $\operatorname{Tr}[\rho_{k}^{2}]$ known
as the purity of $\rho_{k}$.

Since we know that $2^{n_{k}-1}\leq r_{k}\leq 2^{n_{k}}$, thus according to
Proposition S10, we can get the proof. Notice that the factor $g(\rho_{k})$
scales polynomially in $\operatorname{Tr}[\rho_{k}^{2}]$ due to the Cauchy-
Schwartz inequality of density matrices. We then finish the proof of the
Proposition.

##  Appendix D Analytic evaluation of cost function and gradient

In this appendix, we provide a detailed analysis of the analytic gradient of
our cost function $C_{k}$ (3). We take the 2-norm squared cost function as our
objective. At the $k$-th learning step, analyzing the exact form of
$\partial_{\mu}C_{k}$ is necessary for further designing the training strategy
of QSSM. Recalling the expression of $C_{k}$, we could derive the derivative
form with respect to the parameter $\theta_{\mu}=\theta_{k}^{\mu}$. From here,
we have concentrated on the $k$-th step and for convenience, we will omit the
subscript $k$ of the parameter in the following sections. The partial
derivative of $C_{k}$ with respect to $\theta_{\mu}$ is then expressed as,

$\partial_{\mu}C_{k}=2\operatorname{Tr}(2\sigma_{k}\partial_{\mu}(\sigma_{k}))-2\operatorname{Tr}(\rho_{k}\partial_{\mu}(\sigma_{k})),$
(D.1)

where $\sigma_{k}=\sigma_{k}(\bm{\theta})$ which is constructed via
paramterized circuit $U_{k}(\bm{\theta})$, and $\rho_{k}$ is the $k$-th step
reduced target. In a practical sense, our $U_{k}$ is composed of the quantum
gates satisfying the parameter-shift rule and
$U_{k}=U_{l}e^{-i\frac{\theta_{\mu}}{2}\Omega_{\mu}}U_{r}=\tilde{U}_{l}U_{r}$,
where $\Omega_{\mu}^{2}=I$. The $k$-th scattering layer has been shown in Fig.
S2. Then the following lemma holds,

Fig S2: The $k$-th learning step layer. Based on adaptive learning processes,
the previously learnt state $|\psi_{k-1}\rangle$ on system $ABE$ must be pure
where $E$ is the additional system acted by the $k$-th step layer $U_{k}$.
Under perfect learning situation, we have
$\sigma_{k-1}=\operatorname{Tr}_{BE}(\psi_{k-1})=\rho_{k-1}$.

###### Lemma S12

The $k$-th step cost function $C_{k}$ has the partial derivative form (w.r.t.
$\theta_{\mu}$ and evaluated at $\bm{\theta}=\bm{\theta}^{*}$),

$\partial_{\mu}C_{k}^{*}=\left\langle\Delta_{k}^{*}\otimes\frac{I_{E}}{d_{E}}\right\rangle_{\theta_{\mu}+\frac{\pi}{2}}-\left\langle\Delta_{k}^{*}\otimes\frac{I_{E}}{d_{E}}\right\rangle_{\theta_{\mu}-\frac{\pi}{2}}$

where $\Delta_{k}=\sigma_{k}-\rho_{k}$ with $*$ indicating the state
difference evaluated at $\bm{\theta}^{*}$. The other symbols all match the
settings in Fig. S2.

By observing $\sigma_{k}=\operatorname{Tr}_{E}((I_{A}\otimes
U_{k})P_{\psi_{k-1}}(I_{A}\otimes U_{k}^{\dagger}))$, where
$P_{\psi_{k-1}}=|\psi_{k-1}\rangle\\!\langle\psi_{k-1}|$, we could compute the
expression of $\partial_{\mu}\sigma_{k}$ based on the linearity of derivative
operation,

$\partial_{\mu}\sigma_{k}=\operatorname{Tr}_{E}((I_{A}\otimes\partial_{\mu}(U_{k}))P_{\psi_{k-1}}(I_{A}\otimes
U_{k}^{\dagger}))+\operatorname{Tr}_{E}((I_{A}\otimes
U_{k})P_{\psi_{k-1}}(I_{A}\otimes\partial_{\mu}(U_{k}^{\dagger}))).$

Recalling the expression of $\partial_{\mu}(U_{k})$ and
$\partial_{\mu}(U_{k}^{\dagger})$, we have,

$\begin{aligned}
\partial_{\mu}\sigma_{k}&=-\frac{i}{2}\operatorname{Tr}_{E}((I_{A}\otimes\tilde{U}_{l})[(I_{A}\otimes\Omega_{\mu}),(I_{A}\otimes
U_{r})P_{\psi_{k-1}}(I_{A}\otimes
U_{r}^{\dagger})](I_{A}\otimes\tilde{U}^{\dagger}_{l}))\\\
&=-\frac{i}{2}\operatorname{Tr}_{E}(\tilde{U}_{l}[\Omega_{\mu},U_{r}P_{\psi_{k-1}}U_{r}^{\dagger}]\tilde{U}^{\dagger}_{l})\end{aligned},$

where we have abbreviated the ‘$I_{A}\otimes$’ correspondence for simplicity,
which the subsystem $A$ would never join the optimizations during the $k$-th
step. Since $U_{\mu}(\theta_{\mu})=e^{-i\frac{\theta_{\mu}}{2}\Omega_{\mu}}$
satisfies the parameter-shift rule. we could use the gate identity,

$i[\Omega_{\mu},M]=U_{\mu}\left(-\frac{\pi}{2}\right)MU_{\mu}^{\dagger}\left(-\frac{\pi}{2}\right)-U_{\mu}\left(\frac{\pi}{2}\right)MU_{\mu}^{\dagger}\left(\frac{\pi}{2}\right)$

for any linear operator $M$, and then derive the exact value of
$\partial_{\mu}\sigma_{k}^{*}$ at $\bm{\theta}=\bm{\theta}^{*}$ as,

$\partial_{\mu}(\sigma_{k}^{*})=\frac{1}{2}\operatorname{Tr}_{E}\left(U_{k}(\theta_{\mu}^{*}+\frac{\pi}{2})P_{\psi_{k-1}}U^{\dagger}_{k}(\theta_{\mu}^{*}+\frac{\pi}{2})-U_{k}(\theta_{\mu}^{*}-\frac{\pi}{2})P_{\psi_{k-1}}U^{\dagger}_{k}(\theta_{\mu}^{*}-\frac{\pi}{2})\right).$

Here
$\partial_{\mu}(\sigma_{k}^{*})=\partial_{\mu}(\sigma_{k})|_{\bm{\theta}=\bm{\theta}^{*}}$,
and circuit $U_{k}(\theta_{\mu}^{*}+\alpha)$ intakes $\bm{\theta^{*}}$ and
modifies the parameter $\theta_{\mu}^{*}$ to $\theta_{\mu}^{*}+\frac{\pi}{2}$.
Now, recalling the fact that,

$\operatorname{Tr}(\operatorname{Tr}_{B}(\rho_{AB})\sigma_{A})=\operatorname{Tr}\left(\rho_{AB}(\sigma_{A}\otimes\frac{I_{B}}{d_{B}})\right),$

we have,

$\displaystyle\operatorname{Tr}(\rho_{k}\partial_{\mu}(\sigma_{k}^{*}))$
$\displaystyle=\left\langle\rho_{k}\otimes\frac{I_{E}}{d_{E}}\right\rangle_{\theta_{\mu}^{*}+\frac{\pi}{2}}-\left\langle\rho_{k}\otimes\frac{I_{E}}{d_{E}}\right\rangle_{\theta_{\mu}^{*}-\frac{\pi}{2}}$
$\displaystyle\operatorname{Tr}(\sigma^{*}_{k}\partial_{\mu}(\sigma_{k}^{*})),$
$\displaystyle=\left\langle\sigma^{*}_{k}\otimes\frac{I_{E}}{d_{E}}\right\rangle_{\theta_{\mu}^{*}+\frac{\pi}{2}}-\left\langle\sigma^{*}_{k}\otimes\frac{I_{E}}{d_{E}}\right\rangle_{\theta_{\mu}^{*}-\frac{\pi}{2}},$

where $\langle
M\rangle_{\theta}=\langle\psi_{k}(\theta)|M|\psi_{k}(\theta)\rangle$ and
$|\psi_{k}(\theta)\rangle$ is derived by applying $U_{k}(\theta)$ on
$|\psi_{k-1}\rangle$. Combining the above calculations to obtain the desired
result in lemma S12 taking $\Delta^{*}=\sigma_{k}(\bm{\theta}^{*})-\rho_{k}$.
Finally, by taking the actual dimensional factors, we could derive the
analytic form of the partial derivative as shown in Sec. IV.2.