This paper was converted on www.awesomepapers.org from LaTeX by an anonymous user.
Want to know more? Visit the Converter page.

\stackMath

Hybrid Quantum Singular Spectrum Decomposition for Time Series Analysis

J.J. Postema j.j.postema@tue.nl Department of Applied Physics and Science Education, Eindhoven University of Technology, P. O. Box 513, 5600 MB Eindhoven, The Netherlands Eindhoven Hendrik Casimir Institute, Eindhoven University of Technology, P. O. Box 513, 5600 MB Eindhoven, The Netherlands    P. Bonizzi Department of Advanced Computing Sciences, Maastricht University, P. O.  Box 616, 6200 MD Maastricht, The Netherlands    G. Koekoek Department of Gravitational Waves and Fundamental Physics, Maastricht University, P. O.  Box 616, 6200 MD Maastricht, The Netherlands Nikhef, Science Park 105, 1098 XG Amsterdam, The Netherlands    R.L. Westra Department of Advanced Computing Sciences, Maastricht University, P. O.  Box 616, 6200 MD Maastricht, The Netherlands    S.J.J.M.F. Kokkelmans Department of Applied Physics and Science Education, Eindhoven University of Technology, P. O. Box 513, 5600 MB Eindhoven, The Netherlands Eindhoven Hendrik Casimir Institute, Eindhoven University of Technology, P. O. Box 513, 5600 MB Eindhoven, The Netherlands
(June 23, 2025)
Abstract

Classical data analysis requires computational efforts that become intractable in the age of Big Data. An essential task in time series analysis is the extraction of physically meaningful information from a noisy time series. One algorithm devised for this very purpose is singular spectrum decomposition (SSD), an adaptive method that allows for the extraction of narrow-banded components from non-stationary and non-linear time series. The main computational bottleneck of this algorithm is the singular value decomposition (SVD). Quantum computing could facilitate a speedup in this domain through superior scaling laws. We propose quantum SSD by assigning the SVD subroutine to a quantum computer. The viability for implementation and performance of this hybrid algorithm on a near term hybrid quantum computer is investigated. In this work we show that by employing randomised SVD, we can impose a qubit limit on one of the circuits to improve scalibility. Using this, we efficiently perform quantum SSD on simulations of local field potentials recorded in brain tissue, as well as GW150914, the first detected gravitational wave event.

I Introduction

A recently proposed approach to classical time series analysis is singular spectrum decomposition (SSD) Bonizzi et al. (2014). SSD aims to decompose non-linear and non-stationary time series into physically meaningful components. In stark contrast to a Fourier decomposition which employs a basis set of harmonic functions, SSD prepares an adaptive basis set of functions, whose elements depend uniquely on the time series. Applications include, but are not limited to, sleep apnea detection from an unprocessed ECG Bonizzi et al. (2015) and the processing and analysis of brain waves Lowet et al. (2017, 2016). In this work we will also cover application to gravitational wave analysis. The latter is interesting as real-time data analysis poses a challenge, and will be vital for next generations of gravitational wave detection technology. The main bottleneck for scaling this algorithm up for larger time series is the singular value decomposition (SVD) that is performed in each subroutine. For general m×nm\times n matrices, the classical SVD algorithm yields a computational complexity of 𝒪(mnmin(m,n))\mathcal{O}\left(mn\text{min}(m,n)\right) Cline and Dhillon (2006).

There exist clues that allude to quantum computing being able to provide a computational speedup for the computationally taxing SVD subroutine. Currently, quantum computing is in the Noisy Intermediate Scale Quantum (NISQ) era Preskill (2018). While some forms of error mitigation are proposed, noise still limits the amount of qubits and the fidelity of gate operations, such that their numbers are too little for full-fledged quantum computers running quantum error correction codes Kandala et al. (2018). Despite these shortcomings, hybrid quantum computers running variational quantum algorithms provide a useful platform for classically taxing calculations, one major example being the variational quantum eigensolver (VQE) for quantum chemistry O’Malley et al. (2016); Peruzzo et al. (2014); Colless et al. (2018). Hybrid algorithms complement the strengths of both processors: classically efficient tasks are performed on a classical computer, while unitary calculations such as quantum state preparation are handed to a quantum computer. Because of the iterative nature of variational algorithms, noise can be mitigated at every step, increasing robustness of the algorithm.

The SVD subroutine can be performed on a quantum computer through the variational quantum singular value decomposition (VQSVD) algorithm Wang et al. (2021). Besides its application to SSD, SVD forms a compelling application of hybrid quantum computing in general, because of its versatile utility. In a similar fashion to VQE, one can train two parameterisable quantum circuits (PQCs) to learn the left and right singular vectors of a matrix, and sample the singular values through Hadamard tests. In this work we explore both a gate-based paradigm Peruzzo et al. (2014), where the parameterisation is facilitated through rotational quantum gates, and a pulse-based paradigm de Keijzer et al. (2022), where we optimise laser pulse profiles on a neutral atom quantum computing platform. The latter is derived from quantum optimal control (QOC) theory, and is thought to be more NISQ efficient.
Our aim is to convert SSD into a variational hybrid quantum-classical algorithm called quantum singular spectrum decomposition (QSSD). Here, we pose the question whether quantum computing can provide an inherent computational speedup for SVD by surpassing the classical complexity. We employ randomised SVD to improve scalibility of the algorithm Halko et al. (2011). The classical theory behind SSD is introduced in Sec. II. The implementation of QSSD on a hybrid quantum computer is elaborated on in Sec. III, using a gate-based approach, while in Sec. IV we discuss a pulse-based approach. Simulation results for three different time series, among which the first observation of a gravitational wave, are presented in Sec. V. We conclude with a summary and discussion about the viability of QSSD in Sec. VI.

II Singular Spectrum Decomposition

The SSD algorithm is based on the singular spectrum analysis (SSA) method, whose basic ideas are presented in Appendix A Bonizzi et al. (2014); Vautard and Ghil (1989). SSA is designed to explore the presence of specific patterns within a time series, while SSD is designed to provide a decomposition into its constituents components. Let x(n)={x1,x2,,xN1,xN}x(n)=\{x_{1},x_{2},\cdots,x_{N-1},x_{N}\} be an NN-dimensional string of numbers, sampled at a uniform sampling frequency FSF_{S} from some time series. We are interested in extracting (physically) meaningful components from the signal. By embedding the signal in a matrix, correlation functions between pairs of sample points can be extracted through a singular value decomposition of said matrix. Several types of components can be found, among which trends, oscillations and noise for instance. In SSD, such identification is completely automated by focusing on extracting narrow frequency band components.

The time series is first embedded in a trajectory matrix, however, in comparison to SSA, the number of columns is extended to NN and the time series is wrapped around, yielding:

X=[x1x2xKxK+1xNx2x3xK+1xK+2x1xMxM+1xNx1xN+M1].X=\left[\begin{array}[]{cccc|ccc}x_{1}&x_{2}&\cdots&x_{K}&x_{K+1}&\cdots&x_{N}\\ x_{2}&x_{3}&\cdots&x_{K+1}&x_{K+2}&\cdots&x_{1}\\ \vdots&\smash{\vdots}&\smash{\ddots}&\smash{\vdots}&\smash{\vdots}&\smash{\ddots}&\smash{\vdots}\\ x_{M}&x_{M+1}&\cdots&x_{N}&x_{1}&\cdots&x_{N+M-1}\end{array}\right]. (1)

It is to be understood that every subscript is mod N\text{mod }N. The singular value decomposition (SVD) of such a matrix yields

X=iXi=defiσi𝒖i𝒗i,X=\sum_{i}X_{i}\mathrel{\stackrel{{\scriptstyle\makebox[0.0pt]{\mbox{\scriptsize def}}}}{{=}}}\sum_{i}\sigma_{i}\boldsymbol{u}_{i}\boldsymbol{v}^{\top}_{i}, (2)

where σi\sigma_{i} are the singular values, and 𝒖i\boldsymbol{u}_{i} and 𝒗i\boldsymbol{v}_{i} the left and right singular vectors. As explained above, SSD aims to find physically meaningful components gj(n)g_{j}(n) through a data-driven and iterative approach. Starting from the original signal x(n)x(n), at each iteration, a component g(j)(n)g^{(j)}(n) is extracted, such that a residue

v(j)(n)=v(j1)(n)g(j)(n)v^{(j)}(n)=v^{(j-1)}(n)-g^{(j)}(n) (3)

remains, where x(n)=defv(0)(n)x(n)\mathrel{\stackrel{{\scriptstyle\makebox[0.0pt]{\mbox{\scriptsize def}}}}{{=}}}v^{(0)}(n).

For iteration j=1j=1:

The power spectral density (PSD) of the signal is calculated. The frequency fmaxf_{\text{max}} associated with the dominant peak in the PSD is then estimated. If the ratio criterion fmaxFS<δ\frac{f_{\text{max}}}{F_{S}}<\delta is met, a trend is said to characterise the spectral contents of the residual. Ref. Bonizzi et al. (2014) sets δ=103\delta=10^{-3}. In such a case, the embedding dimension is set to M=N3M=\lfloor\frac{N}{3}\rfloor, as described in Ref. Vautard et al. (1992). The first component g(1)(n)g^{(1)}(n) is then extracted from Hankelisation of the matrix X1=σ1𝒖1𝒗1X_{1}=\sigma_{1}\boldsymbol{u}_{1}\boldsymbol{v}_{1}^{\top}. Since most of the energy must be contained within the trend component, only 1 singular value is required for its reconstruction. If the ratio criterion is not met, the window length is defined by M=1.2FSfmaxM=\lfloor 1.2\frac{F_{S}}{f_{\text{max}}}\rfloor Bonizzi et al. (2014).

For iterations j2j\geq 2:

For all iterations j2j\geq 2, the embedding dimension is always set equal to M=1.2FSfmaxM=\lfloor 1.2\frac{F_{S}}{f_{\text{max}}}\rfloor. To extract meaningful components, only principal components with a dominant frequency in the band [fmaxδf,fmax+δf][f_{\text{max}}-\delta f,f_{\text{max}}+\delta f] are selected. In order to estimate the value of the peak width δf\delta f, the Levenberg–Marquardt (LM) algorithm is used. First, the PSD of the residual is approximated with a sum of three Gaussian functions

γ(f,A,σ)=i=13Aie(fμi)22σi2,\gamma\left(f,\vec{A},\vec{\sigma}\right)=\sum_{i=1}^{3}A_{i}e^{-\frac{(f-\mu_{i})^{2}}{2\sigma_{i}^{2}}}, (4)

where A\vec{A} is the vector of amplitudes, σ\vec{\sigma} is the vector of Gaussian peak widths and μi\mu_{i} are the peak locations, given by

μ1=fmax,μ2=f2,μ3=12(fmax+f2)=deff3,\mu_{1}=f_{\text{max}},\quad\mu_{2}=f_{2},\quad\mu_{3}=\frac{1}{2}(f_{\text{max}}+f_{2})\mathrel{\stackrel{{\scriptstyle\makebox[0.0pt]{\mbox{\scriptsize def}}}}{{=}}}f_{3}, (5)

where f2f_{2} is the frequency at which the second most dominant peak is situated. Starting the algorithm from the initial state vector components

A=(12PSD(fmax),12PSD(f2),14PSD(f3)),\vec{A}=\left(\frac{1}{2}\text{PSD}(f_{\text{max}}),\,\frac{1}{2}\text{PSD}(f_{2}),\,\frac{1}{4}\text{PSD}(f_{3})\right), (6)
σ=(23PSD(fmax),23PSD(f2), 4|fmaxf2|),\vec{\sigma}=\left(\frac{2}{3}\text{PSD}(f_{\text{max}}),\,\frac{2}{3}\text{PSD}(f_{2}),\,4|f_{\text{max}}-f_{2}|\right), (7)

the algorithm will eventually converge towards optimal A,σ\vec{A}^{\star},\vec{\sigma}^{\star}. The peak width is then given by δf=2.5σ1\delta f=2.5\sigma_{1}^{\star}. Finally, the component g(j)(n)g^{(j)}(n) is rescaled with a factor aa, so that g~(j)(n)=ag(j)(n)\tilde{g}^{(j)}(n)=ag^{(j)}(n). Such rescaling makes sure the variance of the residue is minimised. Solving for

a=argminav(j1)(n)ag(j)(n)22a=\operatorname*{arg\,min}_{a}||v^{(j-1)}(n)-ag^{(j)}(n)||_{2}^{2} (8)

yields a=g(j),v(j1)g(j),g(j)a=\frac{g^{(j),\top}v^{(j-1)}}{g^{(j),\top}g^{(j)}} Bonizzi et al. (2014). The LM algorithm stops when the energy of the remainder has been reduced to a predefined threshold (default at 1%), ensuring proper convergence of SSD. This corresponds to the criterion

v(j+1)(n)22x(n)22<0.01,\frac{||v^{(j+1)}(n)||_{2}^{2}}{||x(n)||_{2}^{2}}<0.01, (9)

so that the reconstructed signal reads

x(n)=i=1mg~(i)(n)+𝒪(vm(n)).x(n)=\sum_{i=1}^{m}\tilde{g}^{(i)}(n)+\mathcal{O}(v_{m}(n)). (10)

III Hybrid gate-based Singular value decomposition

III.1 SVD quantum algorithm

The singular value decomposition (SVD) of a general m×nm\times n matrix Xm×nX\in\mathbb{C}^{m\times n} is given by

X=UΣV,X=U\Sigma V^{\dagger}, (11)

where Um×mU\in\mathbb{C}^{m\times m} and Vn×nV\in\mathbb{C}^{n\times n} are unitary square matrices, and Σ=diag(σ1,σ2,,σr)m×n\Sigma=\text{diag}(\sigma_{1},\sigma_{2},\cdots,\sigma_{r})\in\mathbb{R}^{m\times n} is a diagonal matrix with all r=rank(X)r=\text{rank}(X) singular values ordered from highest to lowest on the diagonal. Through a suitable loss function, Wang et al. Wang et al. (2021) have shown that this decomposition can be implemented on a quantum computer by training two quantum circuits to learn the unitary matrices U(𝜶)U(\boldsymbol{\alpha}) and V(𝜷)V(\boldsymbol{\beta}), parameterised by two sets of trainable parameters 𝜶\boldsymbol{\alpha} and 𝜷\boldsymbol{\beta}. For real matrices, UU and VV will be orthogonal, which can be efficiently prepared on a quantum computer since SO(N)SU(N)\text{SO}(N)\subset\text{SU}(N). We focus on this particular problem since data matrices are real. Through inversion of eq. (11), one finds that the singular values can be extracted from

σi=ui|X|vi,\sigma_{i}=\langle u_{i}|X|v_{i}\rangle, (12)

where ui|\langle u_{i}| is the Hermitian conjugate of the ii-th column of UU, and |vi|v_{i}\rangle is the ii-th column of VV. The singular values and their associated left and right orthonormal singular vectors allow for a reconstruction of the original matrix XX through

X=i=1rσi|uivi|.X=\sum_{i=1}^{r}\sigma_{i}|u_{i}\rangle\langle v_{i}|. (13)

It is desirable to keep only the first few TT eigentriples such that they approximate the matrix XX to precision ϵ\epsilon. Suppose that X(T)=i=1Tσi|uivi|X^{(T)}=\sum_{i=1}^{T}\sigma_{i}|u_{i}\rangle\langle v_{i}|, then we find through the Cauchy-Schwarz inequality that the Frobenius norm of the difference is bounded by the squared sum of neglected singular values according to

XX(T)F2i=T+1rσi2.||X-X^{(T)}||_{F}^{2}\leq\sum_{i=T+1}^{r}\sigma_{i}^{2}. (14)

More particularly, the Eckart-Young theorem states that this approximation minimises this error norm, and is therefore the optimal matrix approximation Eckart and Young (1936).

III.2 Trajectory matrix implementation

In order to prepare inner products of the form (12) on a quantum computer, we must perform a unitary decomposition, coined a linear combination of unitaries (LCU), of the trajectory matrix:

X=i=1KxieiX=\sum_{i=1}^{K}x_{i}e_{i} (15)

for KK\in\mathbb{N} unitaries eie_{i}. Because of the non-square nature of XX, we delay the discussion on the implementation of this decomposition to Sec. III.6. This set of unitaries is closely related to Pauli operator strings of the form σi1(i)σi2(i)\sigma_{i_{1}}^{(i)}\otimes\sigma_{i_{2}}^{(i)}\otimes\cdots, but different choices are possible. Throughout this paper we adopt the notation ij{0,1,2,3}={0,x,y,z}i_{j}\in\{0,1,2,3\}=\{0,x,y,z\} and

σ0=(1001),σx=(0110),σy=(0ii0),σz=(1001).\sigma^{0}=\begin{pmatrix}1&0\\ 0&1\end{pmatrix},\sigma^{x}=\begin{pmatrix}0&1\\ 1&0\end{pmatrix},\sigma^{y}=\begin{pmatrix}0&-i\\ i&0\end{pmatrix},\sigma^{z}=\begin{pmatrix}1&0\\ 0&-1\end{pmatrix}. (16)

Since mm-qubit states are elements of a 2m2^{m}-dimensional Hilbert space m=span{|0,|1}m2m\mathfrak{H}_{m}=\text{span}\{|0\rangle,|1\rangle\}^{\otimes m}\simeq\mathbb{C}^{2^{m}}, the dimensions of the trajectory matrix must be enforced to be equal to a power of 2. The optimal dimensions of the trajectory matrix XX, as dictated by SSD, do not necessarily satisfy these constraints, so that we slightly alter the trajectory matrix dimensions for a VQSVD implementation. First, the optimal embedding dimension is rounded to the nearest power of two. Then, the number of columns is increased to the first power of two through periodic continuation, where the signal is artificially extended through a wrap-around. Defining

qm=argmina|M2a|,q_{m}=\operatorname*{arg\,min}_{a\in\mathbb{N}}|M-2^{a}|, (17)

the qubit numbers of the U(𝜶)U(\boldsymbol{\alpha}) and V(𝜷)V(\boldsymbol{\beta}) circuits are given by qmq_{m} and qn=log2(N)q_{n}=\lceil\log_{2}(N)\rceil respectively. The trajectory matrix then takes the form

Refer to caption
Figure 1: Flowchart representation of the hybrid VQSVD algorithm. As an input, we choose the trajectory matrix XX, decomposed into a non-square basis provided in Sec. III.6. Two parameterisable quantum circuits U(𝜶)U(\boldsymbol{\alpha}) and V(𝜷)V(\boldsymbol{\beta}) are initiated, and subsequently trained to learn the set of left and right singular vectors (blue block). To achieve this, a hybrid loop is initiated (orange block): on a quantum processing unit, Hadamard tests approximate the singular values, while a classical loss function optimisation routine updates the variational parameters. Once the optimisation procedure has hit a threshold convergence condition, all relevant singular vectors are read out by sending in computational basis states through U(𝜶)U(\boldsymbol{\alpha}) and V(𝜷)V(\boldsymbol{\beta}) to extract all columns, and all estimated singular values σj\sigma_{j} are given by the final set of Hadamard tests. In Sec. IV, we employ a pulse-based approach to approximate the left and right singular matrices (blue block).
X=[x1x2xNx1x2qnNx2x3x1x2x2qnN+1x2qmx2qm+1xN+2qm1xN+2qmx2qn+2qmN1].X=\left[\begin{array}[]{ccccccc}x_{1}&x_{2}&\cdots&x_{N}&x_{1}&\cdots&x_{2^{qn}-N}\\ x_{2}&x_{3}&\cdots&x_{1}&x_{2}&\cdots&x_{2^{qn}-N+1}\\ \vdots&\smash{\vdots}&\smash{\ddots}&\smash{\vdots}&\smash{\vdots}&\smash{\ddots}&\smash{\vdots}\\ x_{2^{q_{m}}}&x_{2^{q_{m}}+1}&\cdots&x_{N+2^{q_{m}}-1}&x_{N+2^{q_{m}}}&\cdots&x_{2^{q_{n}}+2^{q_{m}}-N-1}\\ \end{array}\right]. (18)

Again, it is to be understood that every index is mod NN. While not obeying optimal SSD dimensions, this definition makes the most use of the space constrained by the dimensionality restrictions. Additionally, this definition reduces the number of unitaries UiU_{i} required for the LCU in eq. (15), compared to embedding the trajectory matrix in a large null matrix.

III.3 Randomised QSSD

To obtain a more economic SVD routine, we approximate the SVD of the m×nm\times n trajectory matrix XX in a low-rank fashion, such that we maintain only the first kk singular values:

X=UkΣkVk,X=U_{k}\Sigma_{k}V_{k}^{\dagger}, (19)

where Σk\Sigma_{k} is the singular value matrix, with σp=0\sigma_{p}=0 for all p>kp>k. The computational complexity yields 𝒪(mnk)\mathcal{O}(mnk), which is a ’lower’ complexity than the conventional 𝒪(mnmin(m,n))\mathcal{O}(mn\text{min}(m,n)) for knk\ll n. By performing this low-rank approximation, we hope to improve the scaling laws of the QSSD algorithm and mitigate the two major problems which persist within the theory laid out by Ref. Wang et al. (2021): the input problem and the output problem. The former refers to the fact that the decomposition of a matrix in a Pauli basis requires us to have a basis set that grows exponentially in the number of qubits. The latter refers to the read-out of the quantum circuits to obtain the matrices UU and VV, which is also an operation whose computation time is exponential in the number of qubits.

First, we aim to find an optimal basis 𝑸\boldsymbol{Q} with as few columns as possible, such that Erichson et al. (2016)

X𝑸𝑸Xminrank(x)=kXx.||X-\boldsymbol{Q}\boldsymbol{Q}^{\top}X||\to\min_{\text{rank}(x)=k}||X-x||. (20)

This optimal basis can be approximated through a randomised matrix decomposition. Multiplication of the trajectory matrix by a random matrix

Ω=(ω1ω2ωk1ωk),\Omega=\begin{pmatrix}\vdots&\vdots&&\vdots&\vdots\\ \omega_{1}&\omega_{2}&\cdots&\omega_{k-1}&\omega_{k}\\ \vdots&\vdots&&\vdots&\vdots\end{pmatrix}, (21)

where the vectors ωi\omega_{i} are drawn from the standard distribution 𝒩(μ=0,σ=1)\mathcal{N}(\mu=0,\sigma=1), yields Y=XΩY=X^{\top}\Omega. This allows for a random sampling of range(X)\text{range}(X^{\top}). Performing a QR-decomposition on YY, and trimming the QQ-matrix to a size Qmax(m,n)×kQ_{\text{max}(m,n)\times k}, gives the optimal basis 𝑸\boldsymbol{Q}. This matrix encompasses a basis transformation that lifts XX to a lower-dimensional space where the SVD is approximated up to the kk-th value. Constructing this transformation gives B=𝑸XB=\boldsymbol{Q}^{\top}X, whose SVD yields

B=UkΣkVk.B=U_{k}\Sigma_{k}V_{k}^{\top}. (22)

We can establish a natural qubit cut-off number that defines a low-dimensional space onto which our trajectory matrix is projected. Because we focus on narrow frequency bands in the PSD, we can predict that we do not need plenty of singular values to reconstruct a signal. Every dominant frequency component yields 2 singular values, and simulations have shown that to obtain a faithful reconstruction of the corresponding signal, we need at most a number of singular values close to 1012\sim 10-12. Therefore, we establish a dimensional cut-off kkΛ=16k\leq k_{\Lambda}=16 with associated qubit cut-off q=4q=4. Henceforth, we shall denote the reduced trajectory matrix as XX.

III.4 The parameterisable quantum circuits

We prepare two quantum circuits that learn to approximate the matrices of left (U(𝜶)U(\boldsymbol{\alpha})) and right (V(𝜷)V(\boldsymbol{\beta})) singular vectors of the randomised trajectory matrix XX simultaneously. Let NN and 𝒰(𝜽)\mathcal{U}(\boldsymbol{\theta}) represent the qubit number and the unitary circuit representation of one circuit, agnostic to which one we refer to. For both circuits, we initialise the qubits in the vacuum state: |ψ0=|vac=def|0N|\psi_{0}\rangle=|\text{vac}\rangle\mathrel{\stackrel{{\scriptstyle\makebox[0.0pt]{\mbox{\scriptsize def}}}}{{=}}}|0\rangle^{\otimes N}, and employ the hardware efficient ansatz:

𝒰(𝜽)=d=0D1(𝒰ent×n=1NRY(θn+Nd)),\mathcal{U}(\boldsymbol{\theta})=\prod_{d=0}^{D-1}\left(\mathcal{U}_{\text{ent}}\times\bigotimes_{n=1}^{N}R_{Y}(\theta_{n+Nd})\right), (23)

where DD represents the depth of the circuit, 𝒰entSU(2N)\mathcal{U}_{\text{ent}}\in\text{SU}(2^{N}) is a general entanglement operator over at most NN qubits, and RY(θ)R_{Y}(\theta) is a rotational operator generated by the σy\sigma^{y} Pauli operator:

RY(θ)=exp(iθ2σy).R_{Y}(\theta)=\exp{\left(-i\frac{\theta}{2}\sigma^{y}\right)}. (24)

We opt for this ansatz rather than a set of Euler rotations around the Bloch sphere, since this approach generates real amplitudes which are sufficient for the construction of orthonormal matrices, while simultaneously requiring a lower-dimensional parameter space. We choose a CNOT chain as our entanglement operation:

𝒰ent=i=1N1CNOTi,i+1.\mathcal{U}_{\text{ent}}=\prod_{i=1}^{N-1}\text{CNOT}_{i,i+1}. (25)

III.5 The loss function

Knowing the columns of UU and VV, the maximum singular value is retrieved from

σ1=max|u𝒮m,|v𝒮nu|Xv,\sigma_{1}=\max_{|u\rangle\in\mathcal{S}_{m},|v\rangle\in\mathcal{S}_{n}}\langle u|X|v\rangle, (26)

where 𝒮i,i{m,n}\mathcal{S}_{i},\;i\in\{m,n\} is the set of normalised vectors of length mm and nn respectively. Other singular values are retrieved through a similar fashion, where the vectors |u|u\rangle and |v|v\rangle are restricted to be orthogonal to previous ones. This yields

σk=max|u𝒮m,|v𝒮nu|Xv,u𝔬k1(u),v𝔬k1(v),\sigma_{k}=\max_{|u\rangle\in\mathcal{S}_{m},|v\rangle\in\mathcal{S}_{n}}\langle u|X|v\rangle,\quad u\perp\mathfrak{o}^{(u)}_{k-1},\quad v\perp\mathfrak{o}^{(v)}_{k-1}, (27)

where

𝔬k1(u)=span(|u1,,|uk1).\mathfrak{o}^{(u)}_{k-1}=\text{span}\left(|u_{1}\rangle,\cdots,|u_{k-1}\rangle\right). (28)

Through the Ky Fan theorem Fan (1951), we arrive at a suitable loss function for VQSVD, given by a linear combination of the measured singular values:

(𝜶,𝜷)=j=1Twj𝔢ψj(U)|U(𝜶)XV(𝜷)|ψj(V),\mathcal{L}(\boldsymbol{\alpha},\boldsymbol{\beta})=\sum_{j=1}^{T}w_{j}\cdot\mathfrak{Re}\langle\psi_{j}^{(U)}|U^{\dagger}(\boldsymbol{\alpha})XV(\boldsymbol{\beta})|\psi_{j}^{(V)}\rangle, (29)

where w1>w2>>wT>0w_{1}>w_{2}>\cdots>w_{T}>0 form a set of ordered real-valued weights and {|ψj(U)}j=1T\{|\psi_{j}^{(U)}\rangle\}_{j=1}^{T} and {|ψj(V)}j=1T\{|\psi_{j}^{(V)}\rangle\}_{j=1}^{T} are sets of orthonormal vectors that select the right columns and vectors from UU and VV, respectively. Here, Wang et al.’s linear parameterisation wj=T+1jw_{j}=T+1-j is adopted Wang et al. (2021). Naturally, optimisation aims to find optimal 𝜶,𝜷\boldsymbol{\alpha}^{\star},\boldsymbol{\beta}^{\star} such that

𝜶,𝜷=argmin𝜶,𝜷(𝜶,𝜷).\boldsymbol{\alpha}^{\star},\boldsymbol{\beta}^{\star}=\operatorname*{arg\,min}_{\boldsymbol{\alpha},\boldsymbol{\beta}}\mathcal{L}(\boldsymbol{\alpha},\boldsymbol{\beta}). (30)

The terms 𝔢{ψj(U)|U(𝜶)XV(𝜷)|ψj(V)}\mathfrak{Re}\bigg{\{}\langle\psi_{j}^{(U)}|U^{\dagger}(\boldsymbol{\alpha})XV(\boldsymbol{\beta})|\psi_{j}^{(V)}\rangle\bigg{\}} can be measured on a quantum computer through a Hadamard test, if the matrix XX is decomposed into a basis of unitary operators {ei}i\{e_{i}\}_{i} such that X=ixieiX=\sum_{i}x_{i}e_{i}.

III.6 Pseudo-unitary Hadamard Tests

Quantum computing usually deals with square matrices, since they are natural dimensions of operators in a Hilbert space. Decomposition of the trajectory matrix requires us to find a decomposition in a non-square basis, however. We can do so, if we relax the condition of unitarity of UU to

U+=UwhereU+=(UU)1U,U^{+}=U^{\dagger}\quad\text{where}\quad U^{+}=(U^{\dagger}U)^{-1}U^{\dagger}, (31)
Refer to caption
(a)
Refer to caption
(b)
Figure 2: The circuit to perform a Hadamard test as given in Ref. Wang et al. (2021) ((a)) versus the Hadamard test circuit we employed for non-square matrix decompositions ((b)). HH represents the Hadamard gate, and the number of qubits in the bottom register equals qnq_{n}. ejconte_{j}^{\text{cont}} is the pseudo-unitary continuation of the basis element eje_{j}, as given in Appendix B.

so that we find a non-square pseudo-unitary basis decomposition. Because we adapted new optimal dimensions for the trajectory matrix to conform to quantum computing, we can construct a pseudo-Pauli basis:

{ei}={(Pi|O||O),(O|Pi||O),,(O|O||Pi)},\{e_{i}\}=\{(P_{i}|O|\cdots|O),(O|P_{i}|\cdots|O),\cdots,(O|O|\cdots|P_{i})\}, (32)

where PiP_{i} is the set of all possible Pauli operators of string length qmq_{m}, and OO is the 2qm×2qm2^{q_{m}}\times 2^{q_{m}} null matrix. It is readily shown that every eie_{i} is pseudo-unitary and that together, they form a complete basis for any 2qm×2qn2^{q_{m}}\times 2^{q_{n}} trajectory matrix, so that we can decompose XX according to

X=ixiei,X=\sum_{i}x_{i}e_{i}, (33)

where the expansion coefficients read

xi=12qmTr(Xei).x_{i}=\frac{1}{2^{q_{m}}}\text{Tr}(X^{\dagger}e_{i}). (34)

Implementation of these basis elements in a Hadamard test still requires square matrices. We employ pseudo-unitary continuation to easily implement these elements by extending them to square matrices that have an easy tensor decomposition in a square Pauli basis, a protocol which is provided in Appendix B. Because the pseudo-Hadamard tests employ matrices UU and VV of different size, operating on different numbers of qubits, we must alter the controlled circuit subroutine of the Hadamard test as well. This is displayed in Fig. 2. UU must be altered through

U~=𝕀qnqmqubitsU,\tilde{U}=\mathbb{I}_{q_{n}-q_{m}\text{qubits}}\otimes U, (35)

because it only acts on the last qmq_{m} qubits.

III.7 Analytical Gradient Optimiser

For the classical optimisation routine, we employ an optimiser based on analytical gradients with adaptive Armijo conditions. Such optimisers circumvent finite difference inaccuracies by directly sampling the loss function at a point in parameter space through a parameter shift Schuld et al. (2019). The gradient of the loss function \nabla\mathcal{L} is given by its entries:

αμ=12(𝜶+π𝒆μ,𝜷),\frac{\partial\mathcal{L}}{\partial\alpha_{\mu}}=\frac{1}{2}\mathcal{L}\left(\boldsymbol{\alpha}+\pi\boldsymbol{e}_{\mu},\boldsymbol{\beta}\right), (36)
βν=12(𝜶,𝜷π𝒆ν),\frac{\partial\mathcal{L}}{\partial\beta_{\nu}}=\frac{1}{2}\mathcal{L}\left(\boldsymbol{\alpha},\boldsymbol{\beta}-\pi\boldsymbol{e}_{\nu}\right), (37)

where 𝒆μ,𝒆ν\boldsymbol{e}_{\mu},\boldsymbol{e}_{\nu} are unit vectors along the αμ/βν\alpha_{\mu}/\beta_{\nu} direction in parameter space. A brief proof is provided in Appendix C. At every iteration kk, we update the variational parameters along its gradient. The step size η(0,1)\eta\in(0,1) is determined at every iteration and adapts to the loss function evaluation as well as past iterations. Generally, the parameter update reads

θ(k+1)=θ(k)+η(θ(k)).\theta^{(k+1)}=\theta^{(k)}+\eta\nabla\mathcal{L}(\theta^{(k)}). (38)

At every iteration, we check for the first Wolfe condition, given by

(θ(k+1))(θ(k))+μη(θ(k))2\mathcal{L}(\theta^{(k+1)})\geq\mathcal{L}(\theta^{(k)})+\mu\eta||\nabla\mathcal{L}(\theta^{(k)})||^{2} (39)

for some control parameter μ(0,1)\mu\in(0,1). If the condition is satisfied, we keep the step size equal to η\eta, otherwise the step size is halved and the condition is checked again. Additionally, we introduce a tracker mechanism τ\tau that can rescale the step size dependent on past steps. Initially set to 0, we update the tracker through ττ+1\tau\to\tau+1 if the Wolfe condition is met, otherwise, we set ττ1\tau\to\tau-1. If the tracker hits a threshold ±τ\pm\tau^{\star}, it is reset to 0, and the step size is doubled or halved. Throughout our work, we adopt an initial step size of η0=106\eta_{0}=10^{-6}, a control parameter μ=104\mu=10^{-4} and a threshold of τ=3\tau^{\star}=3.

III.8 Orthonormal Matrix Reconstruction

In order to reconstruct Hankel matrices from iσi|uivi|\sum_{i}\sigma_{i}|u_{i}\rangle\langle v_{i}|, we must perform qubit state tomography over both circuits. Each column of the circuit matrix representation can be read out by sending the orthonormal set {|ψi}i\{|\psi_{i}\rangle\}_{i} through the circuits, and sampling all Pauli moments. Such approach is known to require an exponential number of samplings in the number of qubits. Matrix elements of the form (12) are unprotected against global phase invariance, though. In contrast, the expectation value of an Hermitian operator HH

ψ|H|ψ,\langle\psi|H|\psi\rangle, (40)

are invariant under |ψeiφ|ψ|\psi\rangle\to e^{i\varphi}|\psi\rangle for arbitrary phases φ\varphi. The columns of UU and VV allow relative phase differences of kπk\cdot\pi for kk\in\mathbb{Z}, so that VQSVD finds local maxima where the singular values can be measured to be

σi=±σi(true).\sigma_{i}=\pm\sigma_{i}^{(\text{true})}. (41)

If the ii-th singular value is measured to be negative, the sign needs to flipped, and the ii-th column of UU gains an additional minus sign as well.

IV Pulse-based implementation for QSSD

Besides the gate paradigm, variational quantum optimal control (VQOC) de Keijzer et al. (2022) offers an alternative approach to searching through a Hilbert space \mathfrak{H} (see Ref. Koch et al. (2022) for a review on QOC in general). Rather than optimising parameterised gates, we directly optimise the physical controls through which quantum operations are implemented. It is believed that for highly entangled systems, VQOC is able to outperform VQE in terms of accuracy, when resources are comparible. This is a result of the higher expressibility of optimal control, which one can prove by showing that a set of randomly initialised pulses produces unitary operations that resemble the Haar distribution more closely than a set of randomly initialised gates in the hardware efficient ansatz Hubregtsen et al. (2021).

In this paper, we consider application to a neutral atom quantum computer that is realised on a lattice of trapped Rydberg atoms, whose electronic state manifold offers an embedding of qubit states |0|0\rangle and |1|1\rangle. Consider 2 linear arrays of respectively qmq_{m} and qnq_{n} atoms, which are treated as 2-level systems where the |0|0\rangle-state is mapped to a hyperfine electronic ground state, and the |1|1\rangle-state is mapped to a Rydberg state. Qubit states are addressed by monochromatic laser pulses, which we aim to optimise in order to find an optimal pulse that approximates the target state through propagators U(t)𝔏(qm)U(t)\in\mathfrak{L}(\mathfrak{H}_{q_{m}}) and V(t)𝔏(qn)V(t)\in\mathfrak{L}(\mathfrak{H}_{q_{n}}). For a total evolution time TT and t(0,T)t\in(0,T), the circuit unitaries are subject to the propagator Schrödinger equation

itU(t)HU(t)U(t)=0withU(0)=𝕀,i\partial_{t}U(t)-H_{U}(t)U(t)=0\quad\text{with}\quad U(0)=\mathbb{I}, (42)
itV(t)HV(t)V(t)=0withV(0)=𝕀.i\partial_{t}V(t)-H_{V}(t)V(t)=0\quad\text{with}\quad V(0)=\mathbb{I}. (43)

Here, HiH_{i}, i{U,V}i\in\{U,V\} are the total Hamiltonians that drive the evolution of the qubit states. On a neutral atom quantum computing platform, the native qubit Hamiltonian reads

H(t)=Hd+Hc[Z(t)],H(t)=H_{d}+H_{c}[Z(t)], (44)

where HdH_{d} is the drift Hamiltonian, which represents ’always-on’ interactions in the system, and Hc[Z(t)]H_{c}[Z(t)] is the control Hamiltonian, parameterised by the controls Z(t)Z(t) we impose on our system. For a linear array of NN qubits and LL\in\mathbb{N} controls, we find the van der Waals interaction

Hd=i<jNC6R6|ij|6|1111|ijH_{d}=\sum_{i<j}^{N}\frac{C_{6}}{R^{6}|i-j|^{6}}|11\rangle\langle 11|_{ij} (45)

and the control Hamiltonian

Hc[Z(t)]=l=1L(QlZl(t)+QlZl(t)¯).H_{c}[Z(t)]=\sum_{l=1}^{L}\left(Q_{l}Z_{l}(t)+Q_{l}^{\dagger}\overline{Z_{l}(t)}\right). (46)

Here, C6C_{6} characterises the Rydberg-Rydberg interaction strength, RR is the interatomic distance between neighbouring qubits, and QlQ_{l} are control operators associated with our control parameters. In this work, we control the Rabi frequency and laser phase |Ω(t)|eiφ(t)|\Omega(t)|e^{i\varphi(t)}, and the detuning Δ\Delta of the |1|1\rangle-state, so that their controls are given by

QΩ=|01|+h.c.,QΔ=|11|.Q_{\Omega}=|0\rangle\langle 1|+\text{h.c.},\quad Q_{\Delta}=|1\rangle\langle 1|. (47)

These controls parameterise both circuits by modeling pulses as a set of T/δtT/\delta t\in\mathbb{N} time-discretised control pulses with duration δt\delta t. The physical implementation is a result from smoothing out the piecewise constant equidistant pulses at a minor loss of fidelity. We aim to optimise a new loss function

QOC=𝔢{Tr[U(T)MV(T)ρ]}λ2l=1L0T(|ZU,l(t)|2+|ZV,l(t)|2)𝑑t,\mathcal{L}_{\text{QOC}}=\mathfrak{Re}\bigg{\{}\text{Tr}\left[U^{\dagger}(T)MV(T)\rho\right]\bigg{\}}\\ -\frac{\lambda}{2}\sum_{l=1}^{L}\int_{0}^{T}\left(|Z_{U,l}(t)|^{2}+|Z_{V,l}(t)|^{2}\right)dt, (48)

by adjusting (29) to penalise strong controls for λ>0\lambda>0. We enforce these constraints by adding time-dependent Lagrange multiplier terms to QOC\mathcal{L}_{\text{QOC}}:

J3(U,ZU,ηU)=itU(t)HU(t)U(t),ηU(t)Ωqm,J_{3}(U,Z_{U},\eta_{U})=\langle i\partial_{t}U(t)-H_{U}(t)U(t),\eta_{U}(t)\rangle_{\Omega_{q_{m}}}, (49)
J4(V,ZV,ηV)=itV(t)HV(t)V(t),ηV(t)Ωqn,J_{4}(V,Z_{V},\eta_{V})=\langle i\partial_{t}V(t)-H_{V}(t)V(t),\eta_{V}(t)\rangle_{\Omega_{q_{n}}}, (50)

where the multipliers are called adjoints, the inner product is given by

A,BΩN=𝔢{0TTr[AB]𝑑t},\langle A,B\rangle_{\Omega_{N}}=\mathfrak{Re}\bigg{\{}\int_{0}^{T}\text{Tr}\left[A^{\dagger}B\right]dt\bigg{\}}, (51)

and ΩN=L2([0,T],N)\Omega_{N}=L^{2}([0,T],\mathfrak{H}_{N}). To ensure a realistic implementation, we restrict our controls to the space 𝒵ad\mathcal{Z}_{\text{ad}} of admissible pulses

𝒵ad={Z(t)L2([0,T],L)|||Z||Zmax}.\mathcal{Z}_{\text{ad}}=\big{\{}Z(t)\in L^{2}([0,T],\mathbb{C}^{L})\quad\big{|}\quad||Z||_{\infty}\leq Z_{\text{max}}\big{\}}. (52)

In Appendix D, we prove that it is possible to optimise this Lagrangian under these constraints by sampling the necessary quantities on a quantum computer, where we have omitted the proof of existence and uniqueness of the solutions. Our update scheme at iteration kk becomes

ZU,lk+1(t)=ZU,lk(t)+η(λZU,lk(t)Tr[Ql(ηU(t)U(t)+U(t)ηU(t))])Z_{U,l}^{k+1}(t)=Z_{U,l}^{k}(t)+\eta\big{(}\lambda Z_{U,l}^{k}(t)\\ -\text{Tr}\left[Q_{l}^{\dagger}\left(\eta_{U}(t)U^{\dagger}(t)+U(t)\eta_{U}^{\dagger}(t)\right)\right]\big{)} (53)

for the UU-controls, and idem dito for VV. For optimisation, we adopt the same Armijo optimiser protocol where we check for the first Wolfe condition at every step. In Appendix D we also explicitly solve for the adjoints. In conclusion, the VQOC paradigm requires to solve the propagator Schrödinger equations (42), (43), the adjoint equations (80) and (81), and the analytical gradient (53).

V Analyses and Results

To benchmark the performance of QSSD, several simulations have been run, using a classical emulator of a noise-free quantum circuit. For efficiency purposes we assume full access to all relevant matrix elements, without resorting to sampling amplitudes through measurements. We compare gate-based and pulse-based results to the retrieved classical SSD components for a variety of applications, though we stress that because of the inherent inefficiency of the algorithm, we have not attempted to make a fair comparison between the two implementations. In order to draw a fair contrast, either implementation needs to be run on equivalent evolution circuits, where both the gate-based and pulse-based have equivalent resources. This alludes to a similar circuit evolution time TT, equivalent controls such as Bloch sphere rotational control only, and the number of quantum evaluations #\#QEVQOC{}_{\text{VQOC}} should scale linearly in the quantum resources compared to the number of quantum evaluations #\#QEVQE{}_{\text{VQE}}.

In this work, we adopted the hardware efficient ansatz for the gate-based circuits, with depth D=10D=10 and an iteration number it = 1000, and we assumed full control for the pulse-based circuits, in natural units where =1\hbar=1 and C6=1C_{6}=1, for a total evolution time T=10T=10, a step size discretisation T/δt=100T/\delta t=100 and an iteration number it = 150. We aim to show that with general resources, one can approximate the function space of the SVD reasonably well on a quantum computer, without employing equivalent evolution circuits. Note that the VQOC parameters are not fine-tuned for any implementation in particular. For a more realistic implementation on a neutral atom quantum computer, the parameters should lie in experimental bounds, and the space 𝒵ad\mathcal{Z}_{\text{ad}} should be adjusted accordingly.

We first apply QSSD to a simple toy example to showcase that properties of the SSD algorithm, such as pinpointing non-stationarity of a signal, carry over to the quantum algorithm. Then we apply QSSD to simulated cortical local field potentials (LFPs), electric potentials originating from the extracellular space in brain tissue, as well as GW150914 data, resulting from the first observation of a gravitational wave event. As a figure of merit we introduce the error measure

ϵ=1|Λω|Λω|p(ω)pSSD(ω)|2𝑑ω,\epsilon=\sqrt{\frac{1}{|\Lambda_{\omega}|}\int_{\Lambda_{\omega}}|p(\omega)-p_{\text{SSD}}(\omega)|^{2}d\omega}, (54)

where p(ω)p(\omega) is the PSD of the simulated individual band components, and where pSSD(ω)p_{\text{SSD}}(\omega) is the PSD of the SSD-recovered component. Λω\Lambda_{\omega} is the relevant frequency band of the PSD over which we integrate, and |Λω||\Lambda_{\omega}| is its measure. This error focuses more closely on the frequency content of the retrieved components than an l2l_{2}-norm would, and is not cumulative over time due to small displacements.

V.1 Non-stationary signal

As a first proof of principle, we applied SSD to the following non-stationary toy signal, composed of two harmonic sinusoidal functions:

s(t)=sin(10πt)+14sin(50πt)θ(t12),s(t)=\sin(10\pi t)+\frac{1}{4}\sin(50\pi t)\cdot\theta\left(t-\frac{1}{2}\right), (55)

where θ()\theta(\cdot) is the Heaviside function, for t[0,1]t\in[0,1]. The classical SSD and QSSD results are presented and compared, in Fig. 3. The figure shows a clear separation of harmonic functions, while also pinpointing the moment when the non-stationary harmonic function begins. In Fig. 6, the error ϵ\epsilon is graphed for both components, for all SSD variations.

V.2 Local Field Potential signal

Next we applied SSD to simulated local field potentials (LFPs), which represent the relatively slow varying temporal components of the neural signal, picked up from within a few hundreds of microns of a recording electrode. Brain waves can be separated into separate characteristic frequency bands called alpha [8-12 Hz], beta [13-30 Hz], gamma [30-90 Hz] and theta [4-7 Hz] bands, corresponding to the frequency range in which their dominant frequency lies Bonizzi et al. (2014). We simulated these LFPs by superimposing four components, each in every aforementioned band Liang et al. (2005). Because the alpha and theta components have overlapping frequency contents, we grouped them together as

Refer to caption
(a)
Refer to caption
(b)
Refer to caption
(c)
Refer to caption
(d)
Figure 3: An example of a non-stationary function s(t)s(t) comprised of two sinusoidal components, in arbitrary units (a.u.), for t[0,1]t\in[0,1]. The two original components are shown in (a), and the SSD components are found using classical SSD (b), gate-based QSSD (c) and pulse-based QSSD (d). A sampling frequency FS=256F_{S}=256 Hz was chosen. The non-stationary character of the function is picked up upon by the algorithm in all variations of SSD.

SSD cannot distinguish them. In Fig. 4, we show that SSD is capable of unentangling the superimposed signal into its characteristic components within reasonable accuracy bounds. The corresponding errors are graphed in Fig. 6 for all SSD variations.

V.3 Gravitational wave event GW150914

Black holes and gravitational waves are characteristic predictions of general relativity, and are therefore favourable probes of the theory. The waveforms of such gravitational waves are constrained by the underlying mechanisms such as their generation and propagation. The analysis of such waves is crucial to the understanding of relativistic gravitational physics, and may provide useful insights in black hole physics, the structure of neutron stars, supernovae and the cosmic gravitational wave background. Gravitational wave analysis will likely become classically intractable in the age of Big Data and third generation detectors such as the Einstein Telescope Punturo et al. (2010), and can greatly benefit from quantum data analysis algorithms. We applied SSD to gravitational wave analysis since it serves as an interesting addition to the classical gravitational wave data analysis pipeline. Not only is it capable of providing waveforms with a more crisp quality, it is also able to filter out glitches, lowering the risk of a wrong signal-to-noise ratio (SNR) threshold exceedance.

To showcase the applicability of SSD, we applied it to the the first measured gravitational wave event GW150914, eminent from a black hole binary merger, consistent of a pair of black holes with inferred source masses M1=29.14.4+3.7MM_{1}=29.1_{-4.4}^{+3.7}M_{\odot} and M2=36.23.8+5.2MM_{2}=36.2_{-3.8}^{+5.2}M_{\odot} Abbott (2016); LIGO-Virgo collaboration (2019). We have taken the raw data as measured by the LIGO Hanford detector around the merger time, after which we applied noise whitening, band-passing and notching to obtain an approximate gravitational waveform Center (2017). Through SSD we hope to separate the relevant information about the binary merger from any other unwanted component or noise, thus obtaining a subset of SSD components that can provide a more crisp waveform. The results of SSD filtering are presented in Fig. 5, as well as their respective time-frequency spectrograms. Since we are analysing a real signal rather than a simulated one, we cannot fairly compare the quality of a components to any original benchmark, because we do not know a priori what the true gravitational wave signal should look like, given the right physical parameters. For this reason, we can only provide a figure of merit of the QSSD components with respect to the classical SSD components. The errors are given in Fig. 6, where the comparison with classical SSD is missing for GW150914 because of the aforementioned argument.

Refer to caption
(a)
Refer to caption
(b)
Refer to caption
(c)
Refer to caption
(d)
Refer to caption
(e)
Refer to caption
(f)
Refer to caption
(g)
Refer to caption
(h)
Refer to caption
(i)
Refer to caption
(j)
Refer to caption
(k)
Refer to caption
(l)
Refer to caption
(m)

(b)

(c)

(d)

(e)

Figure 4: (a) The simulated LFP data, where the potential field strength (in arbitrary units) is plotted as a function of time for t[0,1]t\in[0,1], at a sampling frequency of FS=256F_{S}=256 Hz. The signal consists of 4 components, where the alpha and theta components are grouped together because their frequency ranges show strong overlap. The beta, gamma and alpha-theta components are shown in (b). Every column is colour coded to represent a different frequency component: beta (blue), gamma (red) and alpha-theta (green). The SSD recovered components are shown for classical SSD (c), gate-based QSSD (d) and pulse-based QSSD (e). The field strength units are arbitrary in (b-e), and time runs from t=0t=0 to t=1t=1 sec, omitted for clarity.

(a)

Refer to caption
(a)
Refer to caption
(b)
Refer to caption
(c)
Refer to caption
(d)
Refer to caption
(e)
Refer to caption
(f)
Refer to caption
(g)
Refer to caption
(h)

(b)

(c)

(d)

Figure 5: (a) The GW150914 event gravitational wave strain amplitude, measured at the LIGO Hanford Observatory, after noise whitening, band-passing and notching (left) Center (2017), presented with its corresponding time-frequency spectrogram (right). Time is relative to the event time, on September 14, 2015 at 09:50:45 UTC. (b-d) The extracted gravitational wave components (left column) with their respective spectrograms (right column), obtained through classical SSD (b), gate-based QSSD (c) and pulse-based QSSD (d). For SSD calculations, the detector sampling frequency FS=4096F_{S}=4096 Hz was chosen. The spectrograms were obtained by shifting Blackman windows of size 256 with a mutual overlap of 240 points. Results show that through SSD, we can obtain a signal with a higher quality chirp. The spectrogram amplitude is normalised with respect to the strongest amplitude present.

Refer to caption
Figure 6: The error ϵ\epsilon, given by Eq. (54) of the retrieved SSD components for all application examples. The error of the components of the non-stationary signal and the LFPs are with respect to the simulated signal. For GW150914, the error is taken with respect to the classical SSD components. Results are shown for classical SSD (light green), gate-based QSSD (green) and pulse-based QSSD (dark green). For general problem-agnostic quantum circuit resources, gate-based QSSD seems to provide more accurate signals than pulse-based QSSD, when the component closely resembles a simple harmonic function.

VI Conclusion and discussion

In this work we have established a unified framework that combines the promising method of singular spectrum decomposition for classical time series analysis with the variational quantum singular value decomposition algorithm into quantum singular spectrum decomposition (QSSD). The singular value decomposition subroutine is designed to be performed on quantum hardware, while the retrieval of the SSD components is done classically. Using analytical gradient optimisers, we circumvent finite difference errors, and we guarantee optimisation at every iteration. QSSD could find interesting applications to near-term gravitational wave analysis because of the variational formulation. Here, we demonstrated this algorithm for providing a more crisp waveform for matched filtering.

QSSD translates a classical algorithm into a hybrid quantum-classical framework. In contrast to the classical algorithm, the quantum formulation does not have efficient access to all matrix elements of UU and VV. Unpacking the dense trajectory matrix into its unitary basis elements and reading out all the columns of UU and VV are two processes that required us to perform an exponential number of quantum circuit runs, in the number of qubits qmq_{m}. An efficient quantum algorithm would rely on knowing only few parameters that are readily measured on a quantum device, while employing few resources. To mitigate the effects of the exponential scaling laws, we have adopted randomised SVD. While rendering QSSD more economic, the same trick can be applied to the classical algorithm, providing no inherent quantum speedup. An efficient rendition of SSD would circumvent measuring |ui|u_{i}\rangle and |vi|v_{i}\rangle, and instead use a different pipeline to read out SSD components. For further research, we pose the question whether this is possible within this variational framework.

The quality of SSD is related to the quality of the singular vectors, not the singular values, as dictated by Eq. (8), since a rescaling is performed after every iteration to ensure optimal energy extraction. It is therefore crucial for the convergence of the quantum routine to select a circuit ansatz that can approximate the solution space well. For the gate-based approach we have adopted the hardware efficient ansatz (HEA), and for the pulse-based approach we have assumed full control. Despite the HEA being often invoked as a standard method for quantum state preparation, there is a lack of understanding on its capabilities. Since data analysis does not know an effective design or model, we pose the question if an effective model can be established for specific time series applications, and if certain ansätze, either gate-based and pulse-based, can improve convergence for finding the orthonormal matrices.

In conclusion, it remains an open problem whether a true quantum speedup can be achieved through the method of QSSD. The variational formulation of this quantum algorithm does not allow for polynomial scaling laws in the number of qubits, and requires measuring exponentially many quantum amplitudes. At the same time, as mentioned above, several aspects of the theory can be improved upon, which are not necessarily restricted to QSSD applications only. For quantum state preparation purposes, it is interesting to investigate if one could apply quantum natural gradient (QNG) theory to the optimiser routine to improve convergence Stokes et al. (2020), or quantify the geometry of the search space to find better initial states Katabarwa et al. (2022). Overall, results from this preliminary attempt to translate SSD to a quantum computing framework show that this should be likely achievable with proper improvements in the theory and methods employed. In turn, this may pave the way to a true quantum speedup of QSSD over classical SSD. We leave the adaptations of all these ideas to future studies of QSSD and alternative approaches to time series analysis on a quantum computer.

Acknowledgements

We thank Robert de Keijzer, Madhav Mohan and Menica Dibenedetto for discussions. This research is financially supported by the Dutch Ministry of Economic Affairs and Climate Policy (EZK), as part of the Quantum Delta NL programme, and by the Netherlands Organisation for Scientific Research (NWO) under Grant No. 680.92.18.05.

Data Availability

The data that support the findings of this study are available from the corresponding author upon request. The GW150914 gravitational wave event data is publicly available LIGO-Virgo collaboration (2019). Simulations were performed using QuTiP Johansson et al. (2012).

Appendix A Preliminaries - Singular Spectrum Analysis

Suppose a time series is sampled NN times at a steady rate FSF_{S} to obtain the string x(n)={x1,x2,,xN}x(n)=\{x_{1},x_{2},\cdots,x_{N}\}. Then, the SSA algorithm works as follows:

  1. 1.

    The time series is turned into an M×KM\times K Hankel matrix, where MM is the embedding dimension and K=N+1MK=N+1-M. This gives the trajectory matrix

    X=[x1x2xKx2x3xK+1xMxM+1xN].X=\begin{bmatrix}x_{1}&x_{2}&\cdots&x_{K}\\ x_{2}&x_{3}&\cdots&x_{K+1}\\ \vdots&\vdots&\ddots&\smash{\vdots}\\ x_{M}&x_{M+1}&\cdots&x_{N}\end{bmatrix}. (56)

    Such a matrix encapsulates correlations between the data points. By tuning the embedding dimension just right, SSA can faithfully extract sub-components. If MM is too low, not enough correlation can be captured through the trajectory matrix. If MM is too large, however, ghost oscillations called spurious components will be captured.

  2. 2.

    An SVD is performed on the trajectory matrix, yielding X=UΣVX=U\Sigma V^{\top}, with all relevant notation defined in eq. (11). One can further decompose a rectangular matrix XX of rank nn into a sum of rank-1 matrices according to

    X=i=1rXi=defi=1rσi𝒖i𝒗i.X=\sum_{i=1}^{r}X_{i}\mathrel{\stackrel{{\scriptstyle\makebox[0.0pt]{\mbox{\scriptsize def}}}}{{=}}}\sum_{i=1}^{r}\sigma_{i}\boldsymbol{u}_{i}\boldsymbol{v}^{\top}_{i}. (57)

    The set {σi,𝒖i,𝒗i}\{\sigma_{i},\boldsymbol{u}_{i},\boldsymbol{v}_{i}\} is referred to as the ii-th eigentriple for fixed ii.

  3. 3.

    The index set {1,,r}\{1,\cdots,r\} is partitioned into 𝔯r\mathfrak{r}\leq r disjoint subsets {I1,,I𝔯}\{I_{1},\cdots,I_{\mathfrak{r}}\}. Each element IiI_{i} contains a set of principal components that capture a specific component in a time series (like trend, oscillations, noise, etc.) The original trajectory matrix is then decomposed into

    X=i=1𝔯XIi,X=\sum_{i=1}^{\mathfrak{r}}X_{I_{i}}, (58)

    where each matrix on the right hand side represents a specific component series gc(n)g_{c}(n).

  4. 4.

    Sub-components are reconstructed by Hankelisation of each XIiX_{I_{i}}, where the matrix components of each cross-diagonal are averaged over. Reverse engineering those Hankel matrices gives the embedded sub-signals gc(n)g_{c}(n).

Appendix B Pseudo-unitary continuation

In this Appendix, we provide a protocol for the most economic extension of a pseudo-unitary matrix to a square unitary matrix that can be readily prepared for a Hadamard test. Let

ej=(O|O||O|P|O||O|O)e_{j}=(O|O|\cdots|O|P|O|\cdots|O|O) (59)

be a 2qm×2qn2^{q_{m}}\times 2^{q_{n}} pseudo-unitary, with qn>qmq_{n}>q_{m}. The location of the PP operator inside the string, starting from 0 to 2qnqm12^{q_{n}-q_{m}}-1 can be turned into a binary string i0i1iqnqm2iqnqm1i_{0}i_{1}\cdots i_{q_{n}-q_{m}-2}i_{q_{n}-q_{m}-1}. Using the definition of the Pauli operators (16), we can find the continuation of the pseudo-unitaries as

(O|O||O|P|O||O|O)(j=0qnqm1σij)P=defejcont(O|O|\cdots|O|P|O|\cdots|O|O)\mapsto\left(\bigotimes_{j=0}^{q_{n}-q_{m}-1}\sigma^{i_{j}}\right)\otimes P\mathrel{\stackrel{{\scriptstyle\makebox[0.0pt]{\mbox{\scriptsize def}}}}{{=}}}e_{j}^{\text{cont}} (60)

for σ0=𝕀,σ1=σx\sigma^{0}=\mathbb{I},\sigma^{1}=\sigma^{x}. Such qnq_{n}-qubit operators are readily prepared on a quantum computer, while preserving the structure of the original pseudo-unitary. Such protocol works equally well for transpose structures. Then, the evaluated singular values yield:

xi=jajψi|U(𝜶)ejV(𝜷)|ψijajψi|(𝕀U)(𝜶)ejcontV(𝜷)|ψi.x_{i}=\sum_{j}a_{j}\langle\psi_{i}|U^{\dagger}(\boldsymbol{\alpha})e_{j}V(\boldsymbol{\beta})|\psi_{i}\rangle\mapsto\sum_{j}a_{j}\langle\psi_{i}|(\mathbb{I}\otimes U)^{\dagger}(\boldsymbol{\alpha})e_{j}^{\text{cont}}V(\boldsymbol{\beta})|\psi_{i}\rangle. (61)

Appendix C Analytic gradients

Because the constituent gates of the quantum circuits are generated by Hermitian generators, analytical gradients are readily calculated. The loss function is given by

(𝜶,𝜷)=i=1Twiψi|U(𝜶)XV(𝜷)|ψi,\mathcal{L}(\boldsymbol{\alpha},\boldsymbol{\beta})=\sum_{i=1}^{T}w_{i}\cdot\langle\psi_{i}|U^{\dagger}(\boldsymbol{\alpha})XV(\boldsymbol{\beta})|\psi_{i}\rangle, (62)

and both circuits are parameterised by the hardware efficient ansatz

𝒰(𝜽)=d=0D1(𝒰ent×n=1NRY(θn+Nd)).\mathcal{U}(\boldsymbol{\theta})=\prod_{d=0}^{D-1}\left(\mathcal{U}_{\text{ent}}\times\bigotimes_{n=1}^{N}R_{Y}(\theta_{n+Nd})\right). (63)

Loss function gradients can therefore directly be related to derivatives of the circuit representation with respect to the variational parameters according to

αμ=i=1Twiψi(U)|U(𝜶)αμXV(𝜷)|ψi(V).\frac{\partial\mathcal{L}}{\partial\alpha_{\mu}}=\sum_{i=1}^{T}w_{i}\cdot\langle\psi_{i}^{(U)}|\frac{\partial U^{\dagger}(\boldsymbol{\alpha})}{\partial\alpha_{\mu}}XV(\boldsymbol{\beta})|\psi_{i}^{(V)}\rangle. (64)

Because the entanglement operations are unparameterised, we can relate this derivative to a shift in the αμ\alpha_{\mu} parameter:

U(𝜶)αμ=d=0D1(n=1qmRY(αn+qmd)αμ×𝒰ent)=d=0D1(n=1qmi2Yδn+qmd,μRY(αn+qmd)×𝒰ent)=12d=0D1(n=1qmRY(αn+qmd+πδn+qmd,μ)×𝒰ent)=12U(𝜶+π𝒆μ).{\frac{\partial U^{\dagger}(\boldsymbol{\alpha})}{\partial\alpha_{\mu}}=\prod_{d=0}^{D-1}\left(\bigotimes_{n=1}^{q_{m}}\frac{\partial R_{Y}^{\dagger}(\alpha_{n+q_{m}d})}{\partial\alpha_{\mu}}\times\mathcal{U}_{\text{ent}}\right)}=\\ \prod_{d=0}^{D-1}\left(\bigotimes_{n=1}^{q_{m}}\frac{i}{2}Y\delta_{n+q_{m}d,\mu}R_{Y}^{\dagger}(\alpha_{n+q_{m}d})\times\mathcal{U}_{\text{ent}}\right)=\\ \frac{1}{2}\prod_{d=0}^{D-1}\left(\bigotimes_{n=1}^{q_{m}}R_{Y}^{\dagger}(\alpha_{n+q_{m}d}+\pi\delta_{n+q_{m}d,\mu})\times\mathcal{U}_{\text{ent}}\right)=\frac{1}{2}U^{\dagger}(\boldsymbol{\alpha}+\pi\boldsymbol{e}_{\mu}). (65)

In a similar spirit, we find

V(𝜷)βν=d=0D1(n=1qnRY(βn+qnd)βμ×𝒰ent)=d=0D1(n=1qni2Yδn+qnd,νRY(βn+qnd)×𝒰ent)=12d=0D1(n=1qnRY(βn+qndπδn+qnd,ν)×𝒰ent)=12V(𝜷π𝒆ν).{\frac{\partial V(\boldsymbol{\beta})}{\partial\beta_{\nu}}=\prod_{d=0}^{D-1}\left(\bigotimes_{n=1}^{q_{n}}\frac{\partial R_{Y}(\beta_{n+q_{n}d})}{\partial\beta_{\mu}}\times\mathcal{U}_{\text{ent}}\right)}=\\ \prod_{d=0}^{D-1}\left(\bigotimes_{n=1}^{q_{n}}-\frac{i}{2}Y\delta_{n+q_{n}d,\nu}R_{Y}(\beta_{n+q_{n}d})\times\mathcal{U}_{\text{ent}}\right)=\\ \frac{1}{2}\prod_{d=0}^{D-1}\left(\bigotimes_{n=1}^{q_{n}}R_{Y}(\beta_{n+q_{n}d}-\pi\delta_{n+q_{n}d,\nu})\times\mathcal{U}_{\text{ent}}\right)=\frac{1}{2}V(\boldsymbol{\beta}-\pi\boldsymbol{e}_{\nu}). (66)

This completes the proof.

Appendix D Quantum Optimal Control for SVD

In this Appendix, we prove that QOC finds a suitable application in performing SVD on a quantum computer, by showing that the quantities we must measure for optimisation can be prepared on a quantum computer. Additionally, we formally lay out some of the QOC theory laid out in Ref. de Keijzer et al. (2022) and tweak it to describe an SVD application. The Lagrangian QOC\mathcal{L}_{\text{QOC}} for SVD applications is given by

QOC=J1(U,V)+J2(ZU,ZV)+J3(U,ZU,ηU)+J4(V,ZV,ηV),\mathcal{L}_{\text{QOC}}=J_{1}(U,V)+J_{2}(Z_{U},Z_{V})+J_{3}(U,Z_{U},\eta_{U})+J_{4}(V,Z_{V},\eta_{V}), (67)

where UU and VV are the unitary representations of the pulses on circuit UU and VV respectively, ZUZ_{U} and ZVZ_{V} represent the controls over the circuits, and ηU\eta_{U} and ηV\eta_{V} are the adjoints. The first term represents the loss function we want to minimise regardless of optimal control:

J1(U,V)=i=1swi𝔢{Tr[U(T)XV(T)|ψi(V)ψi(U)|]}=𝔢{Tr[U(T)XV(T)ρ]},J_{1}(U,V)=\sum_{i=1}^{s}w_{i}\cdot\mathfrak{Re}\bigg{\{}\text{Tr}\left[U^{\dagger}(T)XV(T)|\psi_{i}^{(V)}\rangle\langle\psi_{i}^{(U)}|\right]\bigg{\}}=\mathfrak{Re}\bigg{\{}\text{Tr}\left[U^{\dagger}(T)XV(T)\rho\right]\bigg{\}}, (68)

where we defined the artificial density matrix

ρ=i=1swi|ψi(V)ψi(U)|.\rho=\sum_{i=1}^{s}w_{i}\cdot|\psi_{i}^{(V)}\rangle\langle\psi_{i}^{(U)}|. (69)

Furthermore, we include the regularisation of the pulse norms

J2(ZU,ZV)=λ20Tl=1L(|ZU,l(t)|2+|ZV,l(t)|2)dtJ_{2}(Z_{U},Z_{V})=\frac{\lambda}{2}\int_{0}^{T}\sum_{l=1}^{L}\left(|Z_{U,l}(t)|^{2}+|Z_{V,l}(t)|^{2}\right)dt (70)

for some regularisation parameter λ\lambda, which we will fix at λ=104.\lambda=10^{-4}. We also add two Lagrange multiplier terms that makes sure that the unitaries that are generated by the pulses are constrained to satisfy the Schrödinger equation. These are given by

J3(U,ZU,ηU)=𝔢{0TηU,tU(t)+iHU(t)U(t)L2([0,T];2qm×2qm)𝑑t},J_{3}(U,Z_{U},\eta_{U})=\mathfrak{Re}\bigg{\{}\int_{0}^{T}\langle\eta_{U},\partial_{t}U(t)+iH_{U}(t)U(t)\rangle_{L^{2}([0,T];\mathbb{C}^{2^{q_{m}}\times 2^{q_{m}}})}dt\bigg{\}}, (71)
J4(V,ZV,ηV)=𝔢{0TηV,tV(t)+iHV(t)V(t)L2([0,T];2qn×2qn)𝑑t},J_{4}(V,Z_{V},\eta_{V})=\mathfrak{Re}\bigg{\{}\int_{0}^{T}\langle\eta_{V},\partial_{t}V(t)+iH_{V}(t)V(t)\rangle_{L^{2}([0,T];\mathbb{C}^{2^{q_{n}}\times 2^{q_{n}}})}dt\bigg{\}}, (72)

where HU/V(t)=Hd+l=1L(Zl,U/V(t)Ql+Zl,U/V(t)¯Ql)H_{U/V}(t)=H_{d}+\sum_{l=1}^{L}\left(Z_{l,U/V}(t)Q_{l}+\overline{Z_{l,U/V}(t)}Q_{l}^{\dagger}\right) denotes the Hamiltonian that drives the circuit UU and VV respectively, and where the inner product L2([0,T];2m×2m)\langle\cdot\rangle_{L^{2}([0,T];\mathbb{C}^{2^{m}\times 2^{m}})} is given by

A,BL2([0,T];2m×2m)=𝔢{0TTr[AB]𝑑t}.\langle A,B\rangle_{L^{2}([0,T];\mathbb{C}^{2^{m}\times 2^{m}})}=\mathfrak{Re}\bigg{\{}\int_{0}^{T}\text{Tr}\left[A^{\dagger}B\right]dt\bigg{\}}. (73)

First we show how adjoints are calculated. This follows from the Fréchet derivates S\frac{\partial}{\partial S} of the Lagrangian with respect to the quantity SS, be it the circuit unitary representation, the pulses or the adjoints. If we vary a Lagrangian JJ with respect to a certain quantity SS with ϵδS\epsilon\delta S with |ϵ|1|\epsilon|\ll 1, and if we obtain

J(S+ϵδS)J(S)=ϵf(S),δSL2([0,T];2m×2m),J(S+\epsilon\delta S)-J(S)=\epsilon\langle f(S),\delta S\rangle_{L^{2}([0,T];\mathbb{C}^{2^{m}\times 2^{m}})}, (74)

then f(S)f(S) is said to be the Fréchet derivative. In our next calculation, we omit ϵ\epsilon by making it implicit in the variation, and we sloppily write JS\frac{\partial J}{\partial S} as f(S),δSL2([0,T];2m×2m)\langle f(S),\delta S\rangle_{L^{2}([0,T];\mathbb{C}^{2^{m}\times 2^{m}})}. We find

J1U=J1(U+δU,V)J1(U,V)=𝔢{Tr[δU(T)XV(T)ρ]}=𝔢{Tr[XV(T)ρδU(T)]},\frac{\partial J_{1}}{\partial U}=J_{1}(U+\delta U,V)-J_{1}(U,V)=\mathfrak{Re}\bigg{\{}\text{Tr}\left[\delta U^{\dagger}(T)XV(T)\rho\right]\bigg{\}}=\mathfrak{Re}\bigg{\{}\text{Tr}\left[XV(T)\rho\delta U^{\dagger}(T)\right]\bigg{\}}, (75)
J1V=J1(U,V+δV)J1(U,V)=𝔢{Tr[U(T)XδV(T)ρ]}=𝔢{Tr[ρU(T)XδV(T)]},\frac{\partial J_{1}}{\partial V}=J_{1}(U,V+\delta V)-J_{1}(U,V)=\mathfrak{Re}\bigg{\{}\text{Tr}\left[U^{\dagger}(T)X\delta V(T)\rho\right]\bigg{\}}=\mathfrak{Re}\bigg{\{}\text{Tr}\left[\rho U^{\dagger}(T)X\delta V(T)\right]\bigg{\}}, (76)
J3U=J3(U+δU,ZU,ηU)J3(U,ZU,ηU)=𝔢{0TTr[ηU(t)(tδU(t)+iHU(t)δU(t))]𝑑t}=𝔢{Tr[ηU(T)δU(T)]+0TTr[(tηU(t)+iηU(t)HU(t))δU(t)]},\frac{\partial J_{3}}{\partial U}=J_{3}(U+\delta U,Z_{U},\eta_{U})-J_{3}(U,Z_{U},\eta_{U})=\mathfrak{Re}\bigg{\{}\int_{0}^{T}\text{Tr}\left[\eta_{U}(t)\left(\partial_{t}\delta U(t)+iH_{U}(t)\delta U(t)\right)\right]dt\bigg{\}}\\ =\mathfrak{Re}\bigg{\{}\text{Tr}\left[\eta_{U}(T)\delta U(T)\right]+\int_{0}^{T}\text{Tr}\left[(-\partial_{t}\eta_{U}^{\dagger}(t)+i\eta_{U}^{\dagger}(t)H_{U}(t))\delta U(t)\right]\bigg{\}}, (77)
J4V=J4(V+δV,ZV,ηV)J4(V,ZV,ηV)=𝔢{0TTr[ηV(t)(tδV(t)+iHV(t)δV(t))]𝑑t}=𝔢{Tr[ηV(T)δV(T)]+0TTr[(tηV(t)+iηV(t)HV(t))δV(t)]}.\frac{\partial J_{4}}{\partial V}=J_{4}(V+\delta V,Z_{V},\eta_{V})-J_{4}(V,Z_{V},\eta_{V})=\mathfrak{Re}\bigg{\{}\int_{0}^{T}\text{Tr}\left[\eta_{V}(t)\left(\partial_{t}\delta V(t)+iH_{V}(t)\delta V(t)\right)\right]dt\bigg{\}}\\ =\mathfrak{Re}\bigg{\{}\text{Tr}\left[\eta_{V}(T)\delta V(T)\right]+\int_{0}^{T}\text{Tr}\left[(-\partial_{t}\eta_{V}^{\dagger}(t)+i\eta_{V}^{\dagger}(t)H_{V}(t))\delta V(t)\right]\bigg{\}}. (78)

Stationary of the action under the Lagrangian QOC\mathcal{L}_{\text{QOC}} requires all its Fréchet derivatives to vanish. This gives us

QOCU=J1U+J3U=𝔢{Tr[(XV(T)ρ+ηU(T))δU(T)]+0TTr[tηU(t)+iηU(t)HU(t)]𝑑t}=0.\frac{\partial\mathcal{L}_{\text{QOC}}}{\partial U}=\frac{\partial J_{1}}{\partial U}+\frac{\partial J_{3}}{\partial U}=\mathfrak{Re}\bigg{\{}\text{Tr}[\left(XV(T)\rho+\eta_{U}(T)\right)\delta U^{\dagger}(T)]+\int_{0}^{T}\text{Tr}\left[-\partial_{t}\eta_{U}^{\dagger}(t)+i\eta_{U}^{\dagger}(t)H_{U}(t)\right]dt\bigg{\}}=0. (79)

where we have used the property 𝔢{Tr[AB]}=𝔢{Tr[BA]}\mathfrak{Re}\bigg{\{}\text{Tr}\left[AB^{\dagger}\right]\bigg{\}}=\mathfrak{Re}\bigg{\{}\text{Tr}\left[BA^{\dagger}\right]\bigg{\}}. This gives us the propagator equation for the adjoint

itηU(t)HU(t)ηU(t)=0with boundary conditionηU(T)=iXV(T)ρ.i\partial_{t}\eta_{U}(t)-H_{U}(t)^{\dagger}\eta_{U}(t)=0\quad\text{with boundary condition}\quad\eta_{U}(T)=-iXV(T)\rho. (80)

In a similar fashion we find

itηV(t)HV(t)ηV(t)=0with boundary conditionηV(T)=iρU(T)X.i\partial_{t}\eta_{V}(t)-H_{V}(t)^{\dagger}\eta_{V}(t)=0\quad\text{with boundary condition}\quad\eta_{V}(T)=-i\rho U^{\dagger}(T)X^{\dagger}. (81)

The derivatives with respect to the pulse controls yield

J3ZU=J3(U,ZU+δZU,ηU)J3(U,ZU,ηU)=𝔢{0TTr[iηU(t)l=1L(QlδZU,l(t)+QlδZU,l(t)¯)U(t)]𝑑t}=𝔢{0TTr[iU(t)ηU(t)QliηU(t)U(t)Ql]δZU,l(t)¯𝑑t},\frac{\partial J_{3}}{\partial Z_{U}}=J_{3}(U,Z_{U}+\delta Z_{U},\eta_{U})-J_{3}(U,Z_{U},\eta_{U})=\mathfrak{Re}\bigg{\{}\int_{0}^{T}\text{Tr}\left[i\eta_{U}^{\dagger}(t)\sum_{l=1}^{L}\left(Q_{l}\delta Z_{U,l}(t)+Q_{l}^{\dagger}\overline{\delta Z_{U,l}(t)}\right)U(t)\right]dt\bigg{\}}\\ =\mathfrak{Re}\bigg{\{}\int_{0}^{T}\text{Tr}\left[iU(t)\eta_{U}^{\dagger}(t)Q_{l}^{\dagger}-i\eta_{U}(t)U^{\dagger}(t)Q_{l}^{\dagger}\right]\overline{\delta Z_{U,l}(t)}dt\bigg{\}}, (82)
J4ZV=J4(V,ZV+δZV,ηV)J4(V,ZV,ηV)=𝔢{0TTr[iηV(t)l=1L(QlδZV,l(t)+QlδZV,l(t)¯)V(t)]𝑑t}=𝔢{0TTr[iV(t)ηV(t)QliηV(t)V(t)Ql]δZV,l(t)¯𝑑t}.\frac{\partial J_{4}}{\partial Z_{V}}=J_{4}(V,Z_{V}+\delta Z_{V},\eta_{V})-J_{4}(V,Z_{V},\eta_{V})=\mathfrak{Re}\bigg{\{}\int_{0}^{T}\text{Tr}\left[i\eta_{V}^{\dagger}(t)\sum_{l=1}^{L}\left(Q_{l}\delta Z_{V,l}(t)+Q_{l}^{\dagger}\overline{\delta Z_{V,l}(t)}\right)V(t)\right]dt\bigg{\}}\\ =\mathfrak{Re}\bigg{\{}\int_{0}^{T}\text{Tr}\left[iV(t)\eta_{V}^{\dagger}(t)Q_{l}^{\dagger}-i\eta_{V}(t)V^{\dagger}(t)Q_{l}^{\dagger}\right]\overline{\delta Z_{V,l}(t)}dt\bigg{\}}. (83)

If QOC is to implemented for a quantum SVD application, we need to be able to measure quantities 𝒬\mathcal{Q} defined by

𝒬=Tr[iV(t)ηV(t)Ql]=Tr[iV(t)ρU(T)XV(T)V(t)Ql]=iTr[ρU(T)XV(T)V(t)QlV(t)]\mathcal{Q}=\text{Tr}\left[iV(t)\eta_{V}^{\dagger}(t)Q_{l}^{\dagger}\right]=\text{Tr}\left[-iV(t)\rho U^{\dagger}(T)XV(T)V^{\dagger}(t)Q_{l}^{\dagger}\right]=-i\text{Tr}\left[\rho U^{\dagger}(T)XV(T)V^{\dagger}(t)Q_{l}^{\dagger}V(t)\right] (84)

on a quantum computer. Defining ΥV,l=V(t)QlV(t)\Upsilon_{V,l}=V^{\dagger}(t)Q_{l}^{\dagger}V(t), we find that we need to measure quantities of the form

𝒬=ii=1swiψi|U(T)XV(T)ΥV,l|ψi,\mathcal{Q}=-i\sum_{i=1}^{s}w_{i}\cdot\langle\psi_{i}|U^{\dagger}(T)XV(T)\Upsilon_{V,l}|\psi_{i}\rangle, (85)

which we can sample through Hadamard tests. A similar calculation for the other circuit yields a similar conclusion. Therefore, a QOC implementation of quantum SVD is possible. With this implementation, we can analytically calculate gradients too, to find the update for the pulses at iteration kk:

Zlk+1(t)=Zlk(t)+ηZQOC.Z_{l}^{k+1}(t)=Z_{l}^{k}(t)+\eta\frac{\partial}{\partial Z}\mathcal{L}_{\text{QOC}}. (86)

We find that

QOCZU=J2ZU+J3ZU=λZlTr[Ql(ηU(t)U(t)+U(t)ηU(t))],\frac{\partial\mathcal{L}_{\text{QOC}}}{\partial Z_{U}}=\frac{\partial J_{2}}{\partial Z_{U}}+\frac{\partial J_{3}}{\partial Z_{U}}=\lambda Z_{l}-\text{Tr}\left[Q_{l}^{\dagger}(\eta_{U}(t)U^{\dagger}(t)+U(t)\eta_{U}^{\dagger}(t))\right], (87)
QOCZV=J2ZV+J4ZV=λZlTr[Ql(ηV(t)V(t)+V(t)ηV(t))].\frac{\partial\mathcal{L}_{\text{QOC}}}{\partial Z_{V}}=\frac{\partial J_{2}}{\partial Z_{V}}+\frac{\partial J_{4}}{\partial Z_{V}}=\lambda Z_{l}-\text{Tr}\left[Q_{l}^{\dagger}(\eta_{V}(t)V^{\dagger}(t)+V(t)\eta_{V}^{\dagger}(t))\right]. (88)

Because of the dependence of UU-adjoints on V(t)V(t) and vice versa, this allows for a coupled gradient calculation on a quantum computer for SVD applications.

References

  • Bonizzi et al. (2014) P. Bonizzi, J. M. Karel, O. Meste,  and R. L. Peeters, Advances in Adaptive Data Analysis 6, 1450011 (2014).
  • Bonizzi et al. (2015) P. Bonizzi, J. Karel, S. Zeemering,  and R. Peeters, in 2015 Computing in Cardiology Conference (CinC) (2015) pp. 309–312.
  • Lowet et al. (2017) E. Lowet, M. J. Roberts, A. Peter, B. Gips,  and P. De Weerd, Elife 6, e26642 (2017).
  • Lowet et al. (2016) E. Lowet, M. J. Roberts, P. Bonizzi, J. Karel,  and P. De Weerd, PloS one 11, e0146443 (2016).
  • Cline and Dhillon (2006) A. K. Cline and I. S. Dhillon, Handbook of Linear Algebra (CRC Press, 2006).
  • Preskill (2018) J. Preskill, Quantum 2, 79 (2018).
  • Kandala et al. (2018) A. Kandala, K. Temme, A. D. Corcoles, A. Mezzacapo, J. M. Chow,  and J. M. Gambetta, arXiv preprint arXiv:1805.04492  (2018).
  • O’Malley et al. (2016) P. J. J. O’Malley, R. Babbush, I. D. Kivlichan, J. Romero, J. R. McClean, R. Barends, J. Kelly, P. Roushan, A. Tranter, N. Ding, B. Campbell, Y. Chen, Z. Chen, B. Chiaro, A. Dunsworth, A. G. Fowler, E. Jeffrey, E. Lucero, A. Megrant, J. Y. Mutus, M. Neeley, C. Neill, C. Quintana, D. Sank, A. Vainsencher, J. Wenner, T. C. White, P. V. Coveney, P. J. Love, H. Neven, A. Aspuru-Guzik,  and J. M. Martinis, Phys. Rev. X 6, 031007 (2016).
  • Peruzzo et al. (2014) A. Peruzzo, J. McClean, P. Shadbolt, M.-H. Yung, X.-Q. Zhou, P. J. Love, A. Aspuru-Guzik,  and J. L. O’brien, Nature communications 5, 1 (2014).
  • Colless et al. (2018) J. I. Colless, V. V. Ramasesh, D. Dahlen, M. S. Blok, M. E. Kimchi-Schwartz, J. R. McClean, J. Carter, W. A. de Jong,  and I. Siddiqi, Physical Review X 8, 011021 (2018).
  • Wang et al. (2021) X. Wang, Z. Song,  and Y. Wang, Quantum 5, 483 (2021).
  • de Keijzer et al. (2022) R. de Keijzer, O. Tse,  and S. Kokkelmans, arXiv preprint arXiv:2202.08908  (2022).
  • Halko et al. (2011) N. Halko, P.-G. Martinsson,  and J. A. Tropp, SIAM review 53, 217 (2011).
  • Vautard and Ghil (1989) R. Vautard and M. Ghil, Physica D: Nonlinear Phenomena 35, 395 (1989).
  • Vautard et al. (1992) R. Vautard, P. Yiou,  and M. Ghil, Physica D: Nonlinear Phenomena 58, 95 (1992).
  • Eckart and Young (1936) C. Eckart and G. Young, Psychometrika 1, 211 (1936).
  • Erichson et al. (2016) N. B. Erichson, S. Voronin, S. L. Brunton,  and J. N. Kutz, arXiv preprint arXiv:1608.02148  (2016).
  • Fan (1951) K. Fan, Proceedings of the National Academy of Sciences of the United States of America 37, 760 (1951).
  • Schuld et al. (2019) M. Schuld, V. Bergholm, C. Gogolin, J. Izaac,  and N. Killoran, Phys. Rev. A 99, 032331 (2019).
  • Koch et al. (2022) C. P. Koch, U. Boscain, T. Calarco, G. Dirr, S. Filipp, S. J. Glaser, R. Kosloff, S. Montangero, T. Schulte-Herbrüggen, D. Sugny, et al., arXiv preprint arXiv:2205.12110  (2022).
  • Hubregtsen et al. (2021) T. Hubregtsen, J. Pichlmeier, P. Stecher,  and K. Bertels, Quantum Machine Intelligence 3, 1 (2021).
  • Liang et al. (2005) H. Liang, S. L. Bressler, E. A. Buffalo, R. Desimone,  and P. Fries, Biological cybernetics 92, 380 (2005).
  • Punturo et al. (2010) M. Punturo, M. Abernathy, F. Acernese, B. Allen, N. Andersson, K. Arun, F. Barone, B. Barr, M. Barsuglia, M. Beker, et al., Classical and Quantum Gravity 27, 194002 (2010).
  • Abbott (2016) B. P. Abbott (LIGO Scientific Collaboration and Virgo Collaboration), Phys. Rev. Lett. 116, 061102 (2016).
  • LIGO-Virgo collaboration (2019) LIGO-Virgo collaboration, “Data release for event GW150914,” https://www.gw-openscience.org/events/GW150914/ (2019).
  • Center (2017) G. W. O. S. Center, “Signal processing with GW150914 open data,” https://www.gw-openscience.org/s/events/GW150914/GW150914_tutorial.html (2017).
  • Stokes et al. (2020) J. Stokes, J. Izaac, N. Killoran,  and G. Carleo, Quantum 4, 269 (2020).
  • Katabarwa et al. (2022) A. Katabarwa, S. Sim, D. E. Koh,  and P.-L. Dallaire-Demers, Quantum 6, 782 (2022).
  • Johansson et al. (2012) J. R. Johansson, P. D. Nation,  and F. Nori, Computer Physics Communications 183, 1760 (2012).