# Determining the ability for universal quantum computing: Testing
controllability via dimensional expressivity

Fernando Gago-Encinas  Fachbereich Physik and Dahlem Center for Complex
Quantum Systems, Freie Universität Berlin, Arnimallee 14, 14195 Berlin,
Germany  Tobias Hartung  Northeastern University London, Devon House, St
Katharine Docks, London, E1W 1LP, United Kingdom  Khoury College of Computer
Sciences, Northeastern University, 440 Huntington Avenue, 202 West Village H
Boston, MA 02115, USA  Daniel M. Reich  Fachbereich Physik and Dahlem Center
for Complex Quantum Systems, Freie Universität Berlin, Arnimallee 14, 14195
Berlin, Germany  Karl Jansen  NIC, DESY Zeuthen, Platanenallee 6, 15738
Zeuthen, Germany  Christiane P. Koch  Fachbereich Physik and Dahlem Center for
Complex Quantum Systems, Freie Universität Berlin, Arnimallee 14, 14195
Berlin, Germany

###### Abstract

Operator controllability refers to the ability to implement an arbitrary
unitary in $SU(N)$ and is a prerequisite for universal quantum computing.
Controllability tests can be used in the design of quantum devices to reduce
the number of external controls. Their practical use is hampered, however, by
the exponential scaling of their numerical effort with the number of qubits.
Here, we devise a hybrid quantum-classical algorithm based on a parametrized
quantum circuit. We show that controllability is linked to the number of
independent parameters, which can be obtained by dimensional expressivity
analysis. We exemplify the application of the algorithm to qubit arrays with
nearest-neighbour couplings and local controls. Our work provides a systematic
approach to the resource-efficient design of quantum chips.

##  I Introduction

Universal quantum computing [1] requires controllability on the quantum
processing unit, so that every quantum logic gate can be implemented. A common
layout in hardware platforms such as those based on superconducting circuits
achieves this by combining two-qubit couplings with local drives for each
qubit of the array [2, 3]. While effective, this approach becomes demanding
for larger arrays, due to both the physical space needed for each control as
well as the associated calibration. Controllability tests can help identify
less resource-intensive architectures that are still capable of performing the
same quantum gates [4].

Controllability in general studies the dynamics that can be implemented in a
quantum system driven by a set of controls [5, 6, 7]. In particular, a system
is pure-state controllable if it can reach all final states. Alternatively, an
(evolution) operator controllable system is capable of implementing every
unitary gate, a necessary feature for universal quantum computing. Tests for
these two different types of controllability rely on computing the rank of the
dynamical Lie algebra of the Hamiltonian [5] or utilize methods based graph
theory [8, 9, 10, 4]. For small system sizes, the tests can be carried out
analytically [11, 12, 13, 14]. For some high- and infinite-dimensional
systems, controllability can be determined using induction arguments [15, 16,
9, 17]. Beyond these special cases, a numerical approach is possible in
principle [4], but is limited by the exponential scaling of the Hilbert space
dimension with respect to the number of qubits. In other words, the accuracy
and feasibility of controllability tests for increasing system size suffer
from the curse of dimensionality.

Here, we present a hybrid quantum-classical controllability test, for both
pure-state and operator controllability of qubit arrays. The hybrid method we
propose evaluates the controllability of the qubit array by measurements on a
quantum device, either the system to be studied with an extra ancilla qubit or
one that mimics the dynamics of the original system. This opens up a new way
of designing controllable qubit arrays with fewer resources, helping to
address the issue of scalability. To do so, we harness the computational power
of quantum circuits to extract information directly from the qubit array under
study.

Parametric quantum circuits constitute the basis of many algorithms, for
example variational algorithms for solving computationally hard optimization
problems [18, 19]. The circuits consist of a set of parametric gates that can
be used to measure a cost function. After a classical optimization, the
parameters are updated to give a new cost value, continuing the feedback loop
of the algorithm. It is necessary to include enough independent optimization
parameters to reach the best possible solution. However, minimizing the number
of parametric gates and circuit depth is also key in the era of noisy quantum
devices [20]. In order to reduce the noise of the circuit while maintaining
its optimization capability, every redundant parameter should be identified
and removed from the circuit. This goal is related to the dimensional
expressivity of the circuit and can be achieved with dimensional expressivity
analysis [21, 22], a hybrid quantum-classical algorithm to systematically find
redundant parameters.

In order to leverage dimensional expressivity analysis to test for
controllability, we define a parametric quantum circuit based on the
architecture of a given qubit array with local controls and qubit couplings.
We then use dimensional expressivity analysis to quantify the number of
independent parameters which is related to the controllability of the original
qubit array. We provide a complete description of how to carry out the hybrid
controllability test on a quantum circuit, opening the possibility of
obtaining information of the controllability of a quantum device before it is
built.

The manuscript is organized as follows. The basic concepts of controllability
analysis and parametric quantum circuits are briefly reviewed in section II.
The pure-state controllability test is presented in section III, including its
derivation, definition and showcase examples. Section IV extends the test to
operator controllability, making use of the Choi-Jamiołkowski isomorphism.
Section V concludes.

##  II Theoretical background

To define controllability tests for qubit arrays, we combine the notions of
system controllability and circuit expressivity. For the sake of a self-
contained presentation, we briefly recap the basic concepts in this section.

###  II.1 Controllability

We consider quantum systems linearly coupled to external controls. They are
described by traceless Hamiltonians of the form

$\hat{H}(t)=\hat{H}(t;u_{1},...u_{m})=\hat{H}_{0}+\sum_{j=1}^{m}u_{j}(t)\hat{H}_{j},$
(1)

where $u_{j}(t)$ are the controls and $\hat{H}_{j}$ are the control operators.
The Hamiltonian (1) generates the time evolution operator $\hat{U}(t)$ such
that for any state $\ket{\psi(0)}$ in the Hilbert space $\mathcal{H}$,
$\ket{\psi(t)}=\hat{U}(t)\ket{\psi(0)}.$ Given an initial state
$\ket{\psi_{0}}$, the set of all final states $\ket{\psi(T)}$ that can be
reached in finite time $0<T<\infty$ with controls $u_{j}(t)$ is called the
reachable set $\mathcal{R}_{\ket{\psi_{0}}}$ of the system. The system is said
to be pure-state controllable if
$\mathcal{R}_{\ket{\psi_{0}}}=\mathcal{S}^{\mathcal{H}}$ (with
$\mathcal{S}^{\mathcal{H}}$ the unit sphere on $\mathcal{H}$), i.e., if every
normalized state is reachable from any initial state $\ket{\psi_{0}}$ [5]. For
physical systems this condition is not dependent on the initial state, which
means that pure-state controllability is also independent of the state in
which the system is initialized. Indeed, the evolution operators $\hat{U}$
that can be implemented on such systems form a group. This implies that for
every evolution $\hat{U}$ in the group, $\hat{U}^{-1}$ must also be contained
in the group of feasible evolutions. If we assume that every state
$\ket{\phi}\in\mathcal{H}$ can be reached from a certain initial state
$\ket{\psi_{0}}$, then for every state $\ket{\phi}$ there exists an evolution
$\hat{U}_{\ket{\psi_{0}},\ket{\phi}}$ such that
$\ket{\phi}=\hat{U}_{\ket{\psi_{0}},\ket{\phi}}\ket{\psi_{0}}$. Therefore
given any initial state $\ket{\phi_{i}}$ and final state $\ket{\phi_{f}}$ we
can always generate an evolution

$\ket{\phi_{f}}=\hat{U}_{\ket{\psi_{0}},\ket{\phi_{f}}}\hat{U}^{-1}_{\ket{\psi_{0}},\ket{\phi_{i}}}\ket{\phi_{i}}$
(2)

In particular this proves that if all states are reachable from a certain
initial state in a closed system, every state is reachable from any other
state.

Pure-state controllability is the relevant type of controllability when we are
interested in are state transfers, i.e., evolving the system from an initial
state to a certain target state. It is equivalent to proving that all state
transfers are possible in a system. This, however, is not the strongest type
of controllability that can be defined. Pure-state controllability is
sufficient to guarantee that there will always be evolution operators
$\hat{U}_{\ket{\psi_{0}},\ket{\psi_{f}}}$ to connect any two states
$\ket{\psi_{0}}$ and $\ket{\psi_{f}}$, yet not enough to ensure that it is
possible to generate every operation $\hat{U}$ in the special unitary group
$SU\left(d\right)$, where $d=\dim(\mathcal{H})$. Pure-state controllability
does not guarantee that simultaneous state-to-state transfers are always
possible. To study this property we consider the so-called operator
controllability. A system with controls as defined in (1) and Hilbert space
dimension $d$ is operator controllable if for every unitary evolution
$\hat{U}_{target}\in SU(d)$ there exist a final time $T\geq 0$, a phase angle
$\varphi\in[0,2\pi)$ and a set of controls $\\{u_{j}\\}_{j=1}^{m}$ such that
$\hat{U}_{target}=e^{i\varphi}\hat{U}(T;u_{1},...u_{m})$.

Note that for both types of controllability there are no restrictions on the
final time $T\leq\infty$ at which state transfers, respectively unitary
operations, are implemented. Consequently, this time $T$, while always finite,
can be arbitrarily large. The question of controllability only inquires
whether it is possible at all to perform the desired dynamics. Similarly, it
does not impose any restrictions on the maximum amplitude that the controls
$u_{j}(t)$ from (1) can take. Finite amplitude is a physical restriction that
impacts the final time required to perform the different operations, but does
not mathematically change the controllability of the system.

If the Hamiltonian of the system is known, there exist algebraic and numerical
tests tailored for both types of controllability [23, 24, 25, 5, 4].

###  II.2 Dimensional expressivity

Parametric quantum circuits have multiple applications, as they constitute the
base for variational quantum algorithms [26]. Their design and study are
pivotal factors in the efficiency of the algorithms. In particular, parameter
dependence and the set of final states that can be produced are two key topics
that determine the capability of the algorithms. Lacking some necessary
parametric gates leads to unsuccessful algorithms, whereas including too many
dependent parameters is detrimental for the purpose of optimization. We
introduce here notions and definitions related to these issues that are
relevant for the controllability tests.

A parametric quantum circuit is a protocol implemented on a set of qubits that
are initialized in a state $\ket{\psi_{0}}$. It consists of a sequence of
logic gates $\hat{G}_{j}$, some of which depend on real parameters
$\vartheta_{k}$. We consider a parametric quantum circuit as the map
$C(\vec{\vartheta})$ that identifies an array of parameters $\vec{\vartheta}$
in the parameter space $\mathcal{P}\ni\vec{\vartheta}$ with

$C(\vec{\vartheta})=\hat{G}_{m}(\vec{\vartheta})...\hat{G}_{0}(\vec{\vartheta})\ket{\psi_{0}}.$
(3)

$C(\vec{\vartheta})$ implicitly depends on the circuit’s initial state
$\ket{\psi_{0}}$111This is in contrast to many commonly used definitions of a
circuit that only consider the gate sequence and not the device
initialization. . An example of a parametric quantum circuit is found in
Figure 1. Note that the amount of parameters on which each gate
$\hat{G}_{j}(\vec{\vartheta})$ depends may vary from zero to the total number
of parameters, e.g.

$\hat{G}_{0}(\vartheta_{1},\vartheta_{2})=\hat{P}(\vartheta_{1})\exp\left(-i\frac{\vartheta_{2}}{2}\hat{X}\right)\hat{H}\hat{P}(-\vartheta_{1}),$
(4)

with the phase gate $\hat{P}$ and the Hadamard gate $\hat{H}$. For the sake of
simplicity, we have chosen units such that $\hbar=1$.

The expressivity of a parametric quantum circuit is its ability to produce
states that are representative of the full Hilbert space of the system [28,
29]. Here, we focus on the dimensional expressivity $expr_{dim}$, i.e. the
dimension of $C\left(\mathcal{P}\right)$ as a real differentiable manifold
[21]. As such, the maximal dimensional expressivity for a circuit with complex
Hilbert space dimension $d$ is $\max(expr_{dim})=2d-1$, which accounts for the
real variables of the complex $d$-dimensional Hilbert space minus the
normalization constraint.

Another important point is the concept of redundant parameters. In a quantum
circuit $C(\vec{\vartheta})$, a parameter $\vartheta_{j}$ is considered
redundant if small perturbations on $\vartheta_{j}$ produce final states on
$C(\vec{\vartheta})$ that can also be achieved by keeping $\vartheta_{j}$
constant and varying the rest of the parameters $\vartheta_{k}$ as needed
[22]. Minimizing the number of redundant parameters is therefore a relevant
matter in the design of parametric quantum circuits. Fewer redundant
parameters may result in more resource-efficient circuits that can produce the
same manifold of states. If a parameter $\vartheta_{1}$ is redundant with
another parameter $\vartheta_{2}$, then the converse is also true. We are free
to choose one of the two parameters to remain constant while varying the other
one at will. The latter is then called independent. Mathematically, the
dimensional expressivity of a circuit $C(\vec{\vartheta})$ is also equal to
the number of elements in the maximal set of independent parameters in the
circuit. While the cardinality of the maximal set for a certain circuit
$C(\vec{\vartheta})$ is fixed, there may exist multiple maximal sets. Locating
and eliminating redundant parameters results in a minimal circuit with the
same local dimension in the manifold of reachable states.

Redundant parameters and dimensional expressivity are studied through the real
Jacobian $J_{C}$ of $C(\vec{\vartheta})$. Assuming a total of $N$ parameters,
it takes the form

$J_{C}(\vec{\vartheta})=\left(\begin{array}[]{ccc}|&&|\\\
\mathfrak{R}\partial_{1}C(\vec{\vartheta})&\cdots&\mathfrak{R}\partial_{N}C(\vec{\vartheta})\\\
|&&|\\\ &&\\\ |&&|\\\
\mathfrak{I}\partial_{1}C(\vec{\vartheta})&\cdots&\mathfrak{I}\partial_{N}C(\vec{\vartheta})\\\
|&&|\end{array}\right),$ (5)

where the elements $\partial_{k}C$ represent the partial derivatives of $C$
with respect to $\vartheta_{k}$. By definition, the dimensional expressivity
is equal to the rank of $J_{C}(\vec{\vartheta})$. In terms of $J_{C}$, a
parameter $\vartheta_{j}$ is redundant with respect to the other parameters
$\\{\vartheta_{i}\\}_{i\neq j}$ at a point $\vec{\vartheta}$ if the $j$-th
column of $J_{C}(\vec{\vartheta})$ is linearly dependent with respect to the
set of all the other columns of $J_{C}(\vec{\vartheta})$, i.e. if the rank of
$J_{C}(\vec{\vartheta})$ as a matrix remains the same after removing the
$j$-th column.

A systematic approach, for an ordered array of parameters $\vec{\vartheta}$,
relies on the partial real Jacobians $J_{C,n}(\vec{\vartheta})$

$J_{C,n}(\vec{\vartheta})=\left(\begin{array}[]{ccc}|&&|\\\
\mathfrak{R}\partial_{1}C(\vec{\vartheta})&\cdots&\mathfrak{R}\partial_{n}C(\vec{\vartheta})\\\
|&&|\\\ &&\\\ |&&|\\\
\mathfrak{I}\partial_{1}C(\vec{\vartheta})&\cdots&\mathfrak{I}\partial_{n}C(\vec{\vartheta})\\\
|&&|\end{array}\right),$ (6)

containing only the first $n$ columns of $J_{C}(\vec{\vartheta})$. If
$\partial_{1}C(\vec{\vartheta})\neq 0$ then $\vartheta_{1}$ is independent and
we initialize the set of independent parameters as
$\mathcal{N}_{1}:=\\{\vartheta_{1}\\}$; otherwise,
$\mathcal{N}_{1}:=\emptyset$. Then we can iterate over the following step. If
$\rank(J_{C,k+1}(\vec{\vartheta}))>\rank(J_{C,k}(\vec{\vartheta}))$, then
$\vartheta_{k+1}$ is independent and we update the set of independent
parameters $\mathcal{N}_{k+1}=\mathcal{N}_{k}\cup\\{\vartheta_{k}\\}$. Else,
$\vartheta_{k+1}$ is redundant and $\mathcal{N}_{k+1}=\mathcal{N}_{k}$. After
all $N$ parameters have been checked, the set $\mathcal{N}_{N}$ is a maximal
set of independent parameters and its cardinality is the dimensional
expressivity of the circuit. The redundant parameters can be then removed from
the circuit by setting them to a suitably chosen constant value.

The dimensional expressivity analysis follows this approach and provides an
efficient method to find a maximal set of independent parameters on a quantum
circuit [21, 22]. As a hybrid quantum-classical algorithm, it mixes
measurements on the actual circuit and classical computations for the ranks.
Instead of calculating the ranks of $J_{C,n}$, this method retrieves the
entries of the matrices

$S_{C,n}(\vec{\vartheta})=J_{C,n}^{T}(\vec{\vartheta})J_{C,n}(\vec{\vartheta}),$
(7)

which are $n\times n$ matrices whose rank equals the one of
$J_{C,n}(\vec{\vartheta})$. The elements of $S_{C,n}(\vec{\vartheta})$ can be
determined via measurements on the circuit with the inclusion of a single
ancilla qubit, no matter the number of qubits in the original circuit [21].

Figure 1:  Three-qubit example of the parametric circuit
$C_{PSC}(\vec{\vartheta})$ (14) for testing pure-state controllability with
initial state $\ket{000}$ in the qubits’ logical basis. Each layer (only two
displayed in the diagram) includes an entangling gate $\hat{R}_{0}$ and a
sequence of local gates $\hat{R}_{j}$ (with $j\geq 1$), one for every control
present in the qubit array.

##  III Pure-state controllability test using dimensional expressivity

This section introduces the novel connection between the dimensional
expressivity of quantum circuits and the pure-state controllability of quantum
systems. We present the design of a circuit associated to a controlled system
that allows us to check its pure-state controllability. We include two
examples to showcase its functionality.

###  III.1 Circuit expressivity and pure-state controllability

We consider a qubit array with Hamiltonian (1). We identify the drift
$\hat{H}_{0}$ as the time-independent part, which includes the local free-
qubit Hamiltonians and some time-independent couplings between them.
Similarly, the operators $\hat{H}_{j}$ with $1\leq j\leq m$ are coupled to the
$m$ different external controls acting on the system. In order to use
dimensional expressivity analysis to determine controllability of a qubit
array, it is necessary to define a parametric quantum circuit that can be run
on the system, according to the different controls at disposal. If we can show
that all normalized states in the Hilbert space are reachable from a certain
initial state using only gates generated by the system’s controls, we have
proven pure-state controllability.

A straightforward choice for the possible parametric gates in the circuit is

$\hat{R}_{j}(\alpha):=\exp\left(-i\,\frac{\alpha}{2}\hat{H}_{j}\right),\qquad
0\leq j\leq m,$ (8)

i.e. rotations around either the drift $\hat{H}_{0}$ or the control operators
$\hat{H}_{j}$ (1). The gates $\hat{R}_{0}(\alpha)$ can be implemented by
letting the system evolve under its time-independent drift Hamiltonian
$\hat{H}_{0}$ for a certain time $t=\frac{\alpha}{2}$. For the other gates,
$\hat{R}_{j}(\alpha)$ with $j\geq 1$, we make use of the local controls. In
these gates the $\hat{H}_{0}$ contribution can be neglected by assuming that
the controls can be chosen such that $\lVert
u_{j}(t)\hat{H}_{j}\rVert\gg\lVert\hat{H}_{0}\rVert$. A realistic approach to
the $\hat{R}_{j}(\alpha)$ implementation is to consider short rotations with
intense controls $u_{j}(t)$, so that the $\hat{H}_{0}$ contribution is
insignificant in comparison. The amplitude of $u_{j}(t)$ is usually adjusted
externally and it has no imposed restriction.

We want to design a parametric quantum circuit $C_{PSC}(\vec{\vartheta})$,
starting with an arbitrary initial state $\ket{\psi_{0}}\in\mathcal{H}$ and
exclusively composed of the rotation gates $\hat{R}_{j}(\vartheta_{k})$. We
then use dimensional expressivity analysis to measure the dimensional
expressivity of the system. If it is maximal, i.e. $expr_{dim}=2d-1$ for
$\dim(\mathcal{H})=d$, we have a manifold of reachable states with local real
dimension $2d-1$. This manifold is a subset of $\mathcal{H}$. We now prove
that it is in fact the whole unit sphere of $\mathcal{H}$. If we assume that
the gates $\hat{R}_{j}(\alpha)$ are cyclic and that every parameter
$\vartheta_{k}$ is used in a single rotation gate in the circuit, we can treat
each $\vartheta_{k}$ as if it had periodic boundaries, i.e.
$\vartheta_{k}\in\mathbb{S}^{1}$. For an array of $n$ parameters
$\vec{\vartheta}$ the parameter space verifies

$\mathcal{P}\cong\underbrace{\mathbb{S}^{1}\times\cdots\times\mathbb{S}^{1}}_{n}\cong\mathbb{T}^{n}.$
(9)

This implies that $\mathcal{P}$ is a connected, compact set without boundary.
Assume a circuit $C_{PSC}(\vec{\vartheta})$ that has maximal dimensional
expressivity. Then, the manifold of reachable states
$C_{PSC}(\mathcal{P})\subseteq\mathcal{H}$ is a connected, compact manifold
without boundary and with maximal local real dimension. Consequently
$C_{PSC}(\mathcal{P})=\mathcal{S}^{\mathcal{H}}\subset\mathcal{H}$. Thus, the
system is pure-state controllable.

So far, we have found a sufficient condition for pure-state controllability.
We now want to identify a condition for non-controllable systems. To this end,
we need to prove that there are some states that are not reachable by any of
the possible dynamics that we can implement with the different operators
$\hat{H}_{j}$ and their nested commutators. Hypothetically, we could do a
sequence of the rotation gates (8) around the drift, the control operators and
their nested commutators and test if all of them are linearly independent.
However, generating the exponential of the commutator of two control operators
(or one control operator and the drift)
$\exp{i\,\beta[\hat{H}_{j},\hat{H}_{k}]}$ is no trivial task. It may require
optimal control to generate a specific rotation for the exact angle $\beta$
and the chosen commutator $[\hat{H}_{j},\hat{H}_{k}]$. Instead, we access the
different commutators by concatenating a series of multiplications, as in the
Baker-Campbell-Hausdorff formula:

$\displaystyle\exp\left(i\,\alpha\hat{A}\right)\exp\left(i\,\beta\hat{B}\right)=$
$\displaystyle\exp\left(i\alpha\hat{A}+i\beta\hat{B}-\frac{1}{2}\alpha\beta[\hat{A},\hat{B}]\right.$
$\displaystyle-\frac{i\,\alpha^{2}\beta}{12}[\hat{A},[\hat{A},\hat{B}]]$ (10)
$\displaystyle+\left.\frac{i\,\alpha\beta^{2}}{12}[\hat{B},[\hat{A},\hat{B}]]\cdots\right).$

Assume that we have a parametric quantum circuit consisting of a sequence of
$n$ rotations,

$C_{seq}^{n}(\vec{\vartheta}):=\exp\left(-i\,\vartheta_{n}\hat{A}_{n}\right)\cdots\exp\left(-i\,\vartheta_{1}\hat{A}_{1}\right)\ket{\psi_{0}}$
(11)

with $\hat{A}_{j}\in\\{\hat{H}_{k}\\}_{k=0}^{m}\,\forall 1\leq j\leq n$. We
can use Eq. (III.1) multiple times on the exponential sequence on the right-
hand side of Eq. (11) to express it as a single exponential dependent on
$\vec{\vartheta}$, the different operators ${A}_{j}$ and their nested
commutators. Assume as well that the dimensional expressivity in the circuit
$expr_{\dim}(C_{seq}^{n}(\vec{\vartheta}))=d_{n}$ is less than the maximum
possible. We define a new parametric circuit by adding one more rotation to
the chain of operations,

$C_{seq}^{n+1}(\vec{\vartheta},\vartheta_{n+1}):=\exp\left(-i\,\vartheta_{n+1}\hat{A}_{n+1}\right)C_{seq}^{n}(\vec{\vartheta}).$
(12)

If the dimensional expressivity of $C_{seq}^{n+1}$ and $C_{seq}^{n}$ are the
same for every $\vartheta_{n+1}\in\mathbb{R}$ and every
$\hat{A}_{n+1}\in\\{\hat{H}_{k}\\}_{k=0}^{m}$, then the number of linearly
independent $\partial_{j}C(\vec{\vartheta})$ remains the same. In other words,
we are not able to find more linearly independent operators and thus, the
dimensional expressivity of the system cannot be increased. This means that
the manifold of reachable states does not have a maximal local dimension and
hence there will be some states to which our initial state cannot evolve.
Therefore the system is not pure-state controllable.

There may be cases where, for given $C_{seq}^{n}(\vec{\vartheta})$ and
$\hat{A}_{n+1}$, there exist two different parameters $\vartheta_{n+1}$ and
$\tilde{\vartheta}_{n+1}$ such that

$expr_{\dim}\left(C_{seq}^{n+1}(\vec{\vartheta},\vartheta_{n+1})\right)>expr_{\dim}\left(C_{seq}^{n+1}(\vec{\vartheta},\tilde{\vartheta}_{n+1})\right).$
(13)

This is common in cases where $\tilde{\vartheta}_{j}=0$ for every $1\leq j\leq
n+1$. Looking at Eq. (III.1), note that using repeated parameters (e.g.
$\alpha=\beta$) will make the coefficients preceding the commutators have the
same absolute value (e.g. $\alpha^{2}\beta=\alpha\beta^{2}$). This is
evidently unfavorable to generate more linearly independent
$\partial_{j}C(\vec{\vartheta})$ due to the symmetries created.

In principle, it would be necessary to prove that the expressivity of
$C_{seq}^{n+1}$ does not increase for any $\vartheta_{n+1}\in\mathbb{R}$.
However, as long as there exists one $\vartheta_{n+1}$ that increases the
dimensional expressivity for an operator $\hat{A}_{n}$, the set of
$\\{\tilde{\vartheta}_{n+1}\\}\subset\mathbb{R}$ that would not raise the
expressivity will have measure zero. This can be justified as follows. Assume
that the first $n$ parameters are independent (i.e.
$\det\left(S_{n}\right)\neq 0$), with $n$ less than the maximal dimensional
expressivity, and that there exist some parameters that can increase the
expressivity. This implies that the analytic function
$f(\vec{\vartheta}):=\det\left(S_{n+1}\right)$ is not constant 0. The set of
parameters that would not increase the expressivity belong to $f^{-1}(0)$.
With the regular level set theorem [30], $f^{-1}(0)$ is an $n$-dimensional
manifold in the $(n+1)$-dimensional parameter space $\mathcal{P}$. Thus, the
set of parameters that would not increase the expressivity has Lebesgue
measure zero in $\mathcal{P}$. In other words, by choosing $\vartheta_{n+1}$
randomly we increase the dimensional expressivity with probability 1.

The next section uses these ideas to systematically design quantum circuits
that can be used to determine for a controlled quantum system whether it is
pure-state controllable or not.

###  III.2 Controllability test

Given a system with operators $\hat{H}_{j}$ with $0\leq j\leq m$ (cf. Eq.
(1)), we define the parametric quantum circuit

$\displaystyle C_{PSC}(\vec{\vartheta})=$
$\displaystyle\Biggl{(}\prod_{j=0}^{n_{l}-1}\hat{R}_{m}(\vartheta_{j(m+1)+m})...$
(14)
$\displaystyle\hat{R}_{1}(\vartheta_{j(m+1)+1})\hat{R}_{0}(\vartheta_{j(m+1)})\Biggr{)}\ket{\psi_{0}},$

where $\ket{\psi_{0}}$ is the initial state of the circuit, $m$ the total
number of controls in the system and $n_{l}$ the number of layers in the
circuit. A diagram of this circuit is shown in Figure 1 for a three-qubit
example. The initial state $\ket{\psi_{0}}$, chosen and fixed at the start of
the circuit, can be any pure state. The number of layers $n_{l}$ should be
decided at the start of the algorithm. All gates in $C_{PSC}(\vec{\vartheta})$
are parametric with different parameters $\vartheta_{k}$, ranging from
$\vartheta_{0}$ to $\vartheta_{n_{l}m-1}$. Each of the $n_{l}$ layers in the
circuit has a similar architecture: It starts with the rotation $\hat{R}_{0}$
around the drift Hamiltonian, an entangling gate if it includes time-
independent qubit couplings, and then a sequence of local gates, from
$\hat{R}_{1}$ to $\hat{R}_{m}$, that use all the different controls sorted by
a chosen order.

Figure 2:  Flowchart for the pure-state controllability algorithm. The yellow
rhomboids show the initial inputs necessary to define the circuit
$C_{PSC}(\vec{\vartheta})$.

The pure-state controllability test for a system evolving under the
Hamiltonian (1) is then defined as follows: If the circuit (14) reaches
maximal expressivity, the system is controllable. A schematic flowchart of the
pure-state controllability test is shown in Figure 2. If the maximum
expressivity of $2d-1$ for a Hilbert space with $\text{dim}(\mathcal{H})=d$
has not been met with $n_{l}$ layers, another layer can be added (encompassing
a full set of rotation gates with their respective new parameters) and the
test can be repeated for the new circuit with $n_{l}+1$ layers. By definition,
the dimensional expressivity can only augment at the rate of one per parameter
$\vartheta_{j}$ at maximum. For a system with $m$ controls, there are a total
of $m+1$ parameters per layer. Therefore, the minimum number of layers needed
to reach maximum expressivity for $m$ controls is

$n_{l,\,\text{min}}=\left\lceil\frac{2d-1}{m+1}\right\rceil.$ (15)

Since layers may have some redundant parameters, the dimensional expressivity
may not necessarily rise at the maximum rate and more layers may have to be
included. Consequently, the algorithm is best started with the minimum number
of layers required to achieve maximum expressivity and additional layers shall
be concatenated as needed.

It may as well happen that the dimensional expressivity remains the same even
with the inclusion of a new layer. In this case the test stops, as the
dimensional expressivity will not further increase. In instances where the
dimensional expressivity reaches a plateau, it is necessary to double-check
using a different array of random parameters $\vec{\vartheta}$ and repeat this
comparison with the $n_{l}$\- and $n_{l}+1$-layered circuits, following the
reasoning explained in section III.1. Using a random set of parameters will
yield an answer on whether the expressivity can be increased or not with
probability 1. If the dimensional expressivity remains at a value less than
$2d-1$ for a sufficiently large set of different random parameters, then the
system is labelled not pure-state controllable and the test concludes.

The algorithm will always end with an affirmative or negative result regarding
pure-state controllability. The loop in Figure 2 will be exited under one of
the following conditions: Either maximal dimensional expressivity is reached
or a last layer exclusively composed of redundant parameters is found. In
other words, the method ends when the finite upper bound of the dimensional
expressivity has been reached or when the expressivity before and after the
addition of a new layer remains the same. Since the dimensional expressivity
is always an integer, the loop must conclude in a finite number of iterations.

Parameters with repeated values in the same rotation gates (e.g.
$\vartheta_{p}=\vartheta_{q}$ on gates $\hat{R}_{j}(\vartheta_{p})$ and
$\hat{R}_{j}(\vartheta_{q})$ for a certain $j$) are usually detrimental to
reach maximum expressivity. A trivial example is the case of
$\vec{\vartheta}=\vec{0}$, where the maximum possible dimensional expressivity
of $C_{PSC}(\vec{0})$ is always $m+1$, with $m$ the number of local controls.

###  III.3 Examples

To illustrate the described algorithm, we consider a four-qubit array with the
following Hamiltonian:

$\hat{H}_{4q}(t)=\sum_{j=0}^{3}-\frac{\omega_{j}}{2}\hat{\sigma}_{z}^{j}+\sum_{k=0}^{2}J_{k,k+1}\hat{\sigma}_{x}^{k}\hat{\sigma}_{x}^{k+1}+\hat{H}_{ctrl}(t)$
(16)

The first term encompasses the free-qubit Hamiltonians and the second one
contains the time-independent couplings. The qubit frequencies $\omega_{j}$
and the coupling strengths $J_{k,k+1}$ have been chosen to fit the ones
normally used in superconducting circuits [31] and their exact value can be
found in Table 1. The last operator, $\hat{H}_{ctrl}(t)$, contains all the
relevant information about the controls, including their number and type. We
choose two configurations of controls to study two separate systems with
Hamiltonian (16), one that is pure-state controllable and one that is not.

Coupling strengths (MHz)
---
|  | $J_{0,1}$ | $J_{1,2}$ | $J_{2,3}$ |
|  | $170$ | $220$ | $150$ |
Qubit frequencies (GHz)
| $\omega_{0}$ | $\omega_{1}$ | $\omega_{2}$ | $\omega_{3}$ |
. . | $5.40$ | $5.30$ | $5.42$ | $5.37$ |
Table 1: Parameters for the Hamiltonian (16). The frequencies and the coupling
strengths have been chosen in a range that is common for superconducting
circuits.

First, we assume the controls from Eq. (16) to be

$\hat{H}_{ctrl}(t)=u_{1}(t)\hat{\sigma}_{x}^{1}+u_{2}(t)\hat{\sigma}_{x}^{2}.$
(17)

This system is operator controllable, as proven by the Lie algebra rank
condition [5] and the graph method [4]. This in particular implies that it is
also pure-state controllable. A diagram of the system may be found in Figure
3.

Since the system only has two controls, each layer of the circuit will have
exactly 3 gates—the entangling gate involving the drift and the two related to
the local controls coupling to $\hat{\sigma}_{x}^{1}$ and
$\hat{\sigma}_{x}^{2}$, respectively. We have chosen
$\ket{\psi_{0}}=\ket{0000}$ (in the logical basis of the free qubits) as the
initial state of the circuit and $n_{l}=11$, matching the minimal number of
layers to obtain maximum dimensional expressivity (cf. Eq. (15)). For a
circuit acting on a four-qubit array, it has a value of $expr_{dim}=31$. We
have generated a random set of parameters $\vec{\vartheta}\in[0,2\pi]^{33}$
(since in this case $(m+1)\cdot n_{l}=33$). We have classically simulated the
parametric quantum circuit and calculated the $S_{C_{PSC},n}(\vec{\vartheta})$
matrices from Eq. (7). We have both determined the redundant parameters in the
circuit and estimated the dimensional expressivity.

In these simulations, the maximum dimensional expressivity is steadily
reached, with every layer raising it by 3. The maximum value of
$expr_{dim}=31$ is achieved with the first parameter of the last layer,
proving that the system is pure-state controllable. In this example the
minimum number of layers that we had chosen was enough to reach maximum
expressivity. The same behaviour has been observed for all the different
random sets of parameters $\vec{\vartheta}$ tested. The same configuration of
gates was further tested using different random initial states
$\ket{\psi_{0}}$, yielding similar results.

Figure 3:  Four-qubit system that is pure-state controllable, cf. Eqs. (16)
and (17).

Second, we present a system that is not pure-state controllable, whose control
operators are

$\hat{H}_{ctrl}(t)=u_{1}(t)\hat{\sigma}_{x}^{0}+u_{2}(t)\hat{\sigma}_{y}^{2}+u_{3}(t)\hat{\sigma}_{z}^{3},$
(18)

cf. Figure 4. Its dynamical Lie algebra has a dimension of
$\dim(\mathcal{L})=120<\dim(\mathfrak{su}(16))=255$, which only proves that
the system is not operator controllable. The system would be pure-state
controllable if and only if

$\dim\left(Lie\left([\rho_{0},\mathcal{L}]\right)\right)=2\dim(\mathcal{H})-2$
(19)

with $\rho_{0}=\ket{0000}\bra{0000}$ [5]. We confirm that the system is not
pure-state controllable since
$\dim\left(Lie\left([\rho_{0},\mathcal{L}]\right)\right)=28<30$ for the
current system. Even though there are more local controls than in the first
example, the system is not controllable due to their positions. Similarly as
before, we create a circuit with four gates (related to the drift and the
three local controls) per layer. We choose a minimum number of layers
$n_{l}=8$ (different to the one before due to the different number of
controls), $\ket{\psi_{0}}=\ket{0000}$ and a set of random parameters
$\vec{\vartheta}\in[0,2\pi]^{32}$.

At the end of the last layer the dimensional expressivity yields a total of 29
out of the 31 that would imply pure-state controllability. Following the
flowchart depicted in Figure 2 we have added a new layer ($n_{l}=9$) with a
new set of random parameters and repeated the dimensional expressivity
analysis. According to our simulation, the new layer contains only redundant
parameters (i.e. the expressivity remains at 29), which stops the algorithm
and means that the system is not pure-state controllable. To verify the
validity of this outcome, we have repeated the test for multiple different
random sets of parameters. In every instance the same result is reached, which
leads to the conclusion that the system is indeed not pure-state controllable,
as discussed in section III.1.

Figure 4:  Four-qubit system that is not pure-state controllable, cf.
equations (16) and (18).

##  IV Operator controllability test using dimensional expressivity analysis

Operator controllability is the relevant type of controllability for a qubit
array in order to perform all quantum logic gates. Its connection to the
dimensional expressivity of a circuit is less evident, since dimensional
expressivity is related to the different states that can be reached. The Choi-
Jamiołkowski isomorphism [32, 33] allows to bridge the gap with a map between
operators on a Hilbert space $\mathcal{H}$ and states in
$\mathcal{H}\otimes\mathcal{H}$. It is used, for example, in quantum process
tomography, allowing to employ techniques from state tomography to operators
[34]. Similarly, by doubling the number of qubits, we can exploit the channel-
state duality between operators in the original system and states in the
bipartite extended system for controllability analysis.

###  IV.1 Lifting pure-state to operator controllability via the Choi-
Jamiołkowski isomorphism

Let us assume a qubit array with Hamiltonian (1) for which we seek to
determine operator controllability. This system with Hilbert space
$\mathcal{H}$ and dimension $dim(\mathcal{H})=d$ will henceforth be referred
to as the original system. We then define a bipartite extended system in
$\mathcal{H}\otimes\mathcal{H}$ composed of the original system and the same
number of auxiliary qubits. To simplify the argument, we first assume no
dynamics over the ancilla qubits. Later we extend our discussion to include
some local Hamiltonians on the auxiliary qubits. Given any operator
$\hat{O}\in L(\mathcal{H}\otimes\mathcal{H})$, we write $\hat{O}^{A}$ to
indicate that the operator only acts non-trivially on the partition of the
original system ($A$), i.e.

$\hat{O}^{A}=\hat{Q}\otimes\mathds{1}_{d}$ (20)

for some operator $\hat{Q}$. Analogously, we write $\hat{O}^{AB}$ for
operators that act non-trivially on both partitions (the original system and
the auxiliary qubits). Neglecting the local contributions of the ancilla
qubits, the Hamiltonian of the extended system is given by

$\hat{H}^{A}(t)=\hat{H}(t;u_{1},...u_{m})\otimes\mathds{1}_{2}^{\otimes q}$
(21)

where $q$ is the number of qubits in the original system.

We assume that the extended system can be prepared in a maximally entangled
state,

$\ket{\psi_{ME}}=\sum_{i=0}^{d-1}\frac{1}{\sqrt{d}}\ket{e_{i}}\otimes\ket{e_{i}},$
(22)

where $\\{\ket{e_{i}}\\}_{0}^{d-1}$ is an orthonormal basis of $\mathcal{H}$.

We define the circuit on the extended system

$\displaystyle C_{OC}^{A}(\vec{\vartheta}):=$
$\displaystyle\prod_{j=0}^{k}\left(\hat{R}^{A}_{m}(\vartheta_{j(m+1)+m})...\right.$
(23)
$\displaystyle\left.\hat{R}^{A}_{1}(\vartheta_{j(m+1)+1})\hat{R}^{A}_{0}(\vartheta_{j(m+1)})\right)\ket{\psi_{ME}}.$

The rotations $\hat{R}_{k}^{A}(\alpha)$ are given by the drift ($k=0$) and the
control operators ($1\leq k\leq m$) of the original subsystem:

$\hat{R}^{A}_{k}(\alpha):=\exp\left(-i\,\frac{\alpha}{2}\hat{H}_{k}\otimes\mathds{1}_{2}^{\otimes
q}\right),\qquad 0\leq k\leq m,$ (24)

with $\hat{H}_{k}$ given in Eq. (1).

A visual representation of the circuit is found in Figure 5. The parameter
space $\mathcal{P}\ni\vec{\vartheta}$ is assumed to be connected and compact
without boundary (e.g. with every coordinate $\vartheta_{i}$ being cyclic).
The final state of the circuit will always be of the form

$C_{OC}^{A}(\vec{\vartheta})=\frac{1}{\sqrt{d}}\sum_{i=0}^{d-1}\ket{e_{i}}\otimes\left(\hat{U}(\vec{\vartheta})\ket{e_{i}}\right),$
(25)

with $\hat{U}(\vec{\vartheta})$ a unitary operator depending on the circuit’s
parameters.

Our goal is to prove that dimensional expressivity of the extended system is
enough to determine operator controllability of the original system. To this
end, we make use of the Choi-Jamiołkowski isomorphism [32, 33, 35]. The map it
describes is written as

$\displaystyle\Lambda(\hat{A})\,:=$
$\displaystyle\,\left(\mathds{1}_{\mathcal{L}_{\mathcal{H}}}\otimes\hat{A}\right)\left(\ket{\phi}\bra{\phi}\right)$
(26) $\displaystyle\,=$
$\displaystyle\,\sum_{i,j}\ket{\psi_{i}}\bra{\psi_{j}}\otimes\hat{A}\Bigl{(}\ket{\psi_{i}}\bra{\psi_{j}}\Bigr{)}$

for any operator $\hat{A}$ in the Hilbert space of linear operators on the
Liouville space and the unnormalized state
$\ket{\phi}=\sum_{i}\ket{\psi_{i}}\otimes\ket{\psi_{i}}$, with
$\\{\ket{\psi_{i}}\\}_{i=0}^{d-1}$ an orthonormal basis of $\mathcal{H}$.

Figure 5:  Parametric circuit for the extended system required to perform the
operator controllability test (23) for a three-qubit system. The qubits
$q_{i}$ with $i=0,1,2$ constitute the original system, whereas $q_{j}$ with
$j=3,4,5$ are the ancilla qubits.

Identifying $\hat{A}$ in Eq. (26) with $\hat{U}(\vec{\vartheta})$ in Eq. (25),
we know that

$\displaystyle\hat{U}(\mathcal{P})\,\cong$ $\displaystyle\,\Lambda(\hat{A})$
(27) $\displaystyle=$
$\displaystyle\,\sum_{i,j=0}^{d-1}\ket{e_{i}}\bra{e_{j}}\otimes\left(\hat{U}(\mathcal{P})\ket{e_{i}}\bra{e_{i}}\hat{U}(\mathcal{P})^{\dagger}\right).$

The operators $\hat{U}(\mathcal{\vec{\vartheta}})$ are unitary for every
$\vec{\vartheta}\in\mathcal{P}$, hence purity-preserving. We transform the
density matrix representation from Eq. (27) into a pure-state representation,
resulting in

$\hat{U}(\mathcal{P})\cong\sum_{i=0}^{d-1}\ket{e_{i}}\otimes\hat{U}(\mathcal{P})\ket{e_{i}}\cong
C_{OC}^{A}(\mathcal{P}).$ (28)

Therefore, there exists an embedding between the evolutions
$\hat{U}(\mathcal{P})$ that are generated using a combination of rotations
given by the controls and the final states of the circuit
$C_{OC}^{A}(\mathcal{P})$. A system with traceless operators as in Eq. (1) and
$\dim(\mathcal{H})=d$ is operator-controllable if and only if the manifold of
the unitary evolutions that can be generated $\hat{U}_{\hat{H}}$ is isomorphic
to $SU(d)$. Evidently,
$\hat{U}(\mathcal{P})\subseteq\hat{U}_{\hat{H}}\subseteq SU(d)$. Since the
parameter space $\mathcal{P}$ is connected and compact without boundary,
$\hat{U}(\mathcal{P})=SU(d)$ if and only if
$\dim(\hat{U}(\mathcal{P}))=\dim(SU(d))$. Thus, using Eq. (28), the system
will be operator-controllable if $\dim(C_{OC}^{A}(\mathcal{P}))=\dim(SU(d))$,
i.e., if the dimensional expressivity of the circuit
$C_{OC}^{A}(\vec{\vartheta})$ is $d^{2}-1$.

From here we proceed analogously as the pure-state controllability test from
section III.1. We present the outline of the operator controllability test in
Figure 7. If the dimensional expressivity is less than $d^{2}-1$, we inspect
the parameters in the last circuit layer. If they all are redundant, the test
ends and the system is deemed not controllable. Indeed, if all parameters in
the last layer are redundant, we are unable to find more linearly independent
operators in the dynamical Lie algebra of the system. If the number of
linearly independent elements of the algebra (i.e. number of independent
parameters) is less than $\dim(SU(d))$, there exist some unitary operations
that cannot be implemented. Therefore, the system is not operator
controllable. This step must be checked with multiple arrays of random
parameters $\vec{\vartheta}$, as there may be a set of arrays of parameters
with measure zero over $\mathcal{P}$ that yield a lower value for the
dimensional expressivity. The same arguments we used in section III.1 apply
here, as $C_{OC}^{A}(\mathcal{P})$ is a manifold of states in
$\mathcal{H}\otimes\mathcal{H}$.

If at least one parameter in the last circuit layer is independent, the test
continues. We iterate by adding a new layer and calculating the circuit’s
expressivity. The algorithm will eventually come to an end, either with
maximal value for the dimensional expressivity or with a layer of redundant
parameters at the end of the circuit.

We now move to a more realistic setting that incorporates dynamics in the
ancilla qubits. We undertake this by including the drift of the auxiliary
partition. The new Hamiltonian of the bipartite system is then

$\hat{H}^{AB}(t)=\hat{H}(t;u_{1},...u_{m})\otimes\mathds{1}_{2}^{\otimes
q}+\sum_{j=0}^{q-1}-\frac{\omega_{j}}{2}\hat{\sigma}_{z}^{j+q},$ (29)

with

$\hat{\sigma}_{z}^{k}:=\mathds{1}\otimes...\otimes\mathds{1}\\!\otimes\underbrace{\hat{\sigma}_{z}}_{\text{{\hbox{k}}
position}}\\!\otimes\mathds{1}\otimes...\mathds{1}.$ (30)

It results in the following circuit to test operator controllability

$\displaystyle C_{OC}^{AB}(\vec{\vartheta}):=$
$\displaystyle\prod_{j=0}^{k}\left(\hat{R}^{A}_{m}(\vartheta_{j(m+1)+m})...\hat{R}^{A}_{1}(\vartheta_{j(m+1)+1})\right.$
(31)
$\displaystyle\left.\hat{R}^{B}_{0}(\vartheta_{j(m+1)})\hat{R}^{A}_{0}(\vartheta_{j(m+1)})\right)\ket{\psi_{ME}},$

where

$\hat{R}^{B}_{0}(\alpha):=\exp\left(i\,\frac{\alpha}{2}\,\sum_{j=0}^{q-1}\frac{\omega_{j}}{2}\hat{\sigma}_{z}^{j+q}\right).$
(32)

Note that the parameters $\vartheta_{j(m+1)}$ of the gates $\hat{R}^{A}_{0}$
and $\hat{R}^{B}_{0}$ in the same layer $j$ are always the same because there
is no active control over these operators—they are due to the time-independent
part of the Hamiltonian. In other words, these gates are implemented by
letting the system evolve a certain amount of time $t=\vartheta_{j(m+1)}/2$.
The number of parameters per layer for a system with $m$ controls remains
equal to $m+1$, despite having an extra rotation gate per layer. A diagram of
the new circuit is found in Figure 6.

Figure 6:  Circuit on the extended system required to perform the operator
controllability test (31) for a three-qubit system. The qubits $q_{i}$ with
$i=0,1,2$ constitute the original system, whereas $q_{j}$ with $j=3,4,5$ are
the ancilla qubits. The rotations $\hat{R}_{0}^{B}$ (cf. Eq. (32)) include the
free-qubit dynamics of the ancilla qubits.

If we choose an orthonormal basis for the $B$ partition consisting of the
eigenstates of the ancilla qubits, then

$C_{OC}^{AB}(\mathcal{P})\cong\sum_{i=0}^{d-1}\left(\hat{U}(\mathcal{P})e^{\varphi_{i}(\vec{\vartheta})}\ket{e_{i}}\right)\otimes\ket{e_{i}}..$
(33)

The only difference between equations (28) and (33) is the local phases
$\varphi_{i}(\vec{\vartheta})$, which are uniquely determined for any array of
parameters $\vec{\vartheta}$. These do not change the value of the dimensional
expressivity since for any array $\vec{\vartheta}$ there exists a neighborhood
in which

$C_{OC}^{A}(\vec{\vartheta})\cong C_{OC}^{AB}(\vec{\vartheta}).$ (34)

This implies the local dimension of the manifold of reachable states to be
identical, i.e., the dimensional expressivity to be the same. Therefore, we
can include the local Hamiltonians of the ancilla qubits in our calculations
to describe a more realistic model and still use the Choi-Jamiołkovski
isomorphism to design the parametric quantum circuit (31).

###  IV.2 Controllability test

Figure 7:  Flowchart for the algorithm testing operator controllability. The
yellow rhomboids show the initial inputs necessary to define the circuit
$C_{OC}^{AB}(\vec{\vartheta})$.

Once again we consider a qubit array with traceless Hamiltonian (1) and the
corresponding extended system, composed of the original $q$-qubit array and
$q$ more auxiliary qubits. We assume the extra qubits to have arbitrary
natural frequencies $\omega_{j}$, such that the Hamiltonian of the extended
system is given by Eq. (29) and the parametric quantum circuit by Eq. (31). As
shown in Figure 6 for a three-qubit example, for a system with $m$ controls
the circuit has exactly $m+1$ parameters per layer. As for pure-state
controllability, it is encouraged to choose a number of layers $n_{l}$ that
would a priori be sufficient to reach the maximum dimensional expressivity. In
the case of operator controllability, it is $\dim(\mathfrak{su}(d))=d^{2}-1$,
with $d$ the Hilbert space dimension of the original system, $d=2^{q}$ 222We
only claim that the value for the maximal dimensional expressivity is
$d^{2}-1$ (with $d=2^{q}$) for the circuits $C^{AB}_{OC}$ (31). Other
parametric quantum circuits acting on $\mathcal{H}\otimes\mathcal{H}$ could in
principle reach higher values of expressivity, up to $2^{2q+1}-1$ . Thus, the
condition for the minimum number of layers to obtain the maximal dimensional
expressivity is

$n_{l,\,\text{min}}=\left\lceil\frac{d^{2}-1}{m+1}\right\rceil.$ (35)

With the dimensional expressivity we find the maximum number of linearly
independent states in $\mathcal{H}\otimes\mathcal{H}$ that can be generated in
a neighborhood of $C_{OC}^{AB}(\vec{\vartheta})$. This in turn yields
information about the maximum number of linearly independent operators on
$\mathcal{H}$ that can be generated by the original system around the
identity. Since we know that these operators belong to the Lie algebra
$\mathfrak{su}(d)$ we simply want to determine if we can span all the
$d^{2}-1$ dimensions in the algebra, i.e. having operator controllability, or
not.

The operator controllability of a system evolving under the Hamiltonian (1) is
determined as follows: If the circuit (31) has dimensional expressivity equal
to $d^{2}-1$, then the system is operator controllable. Analogously to the
pure-state controllability test, if this value for the dimensional
expressivity is not reached, another layer should be concatenated at the end
of the circuit. If all the new parameters in the last layer are redundant,
then the system is not operator controllable (with a probability of measure
1); otherwise, the process of concatenating layers shall be repeated. The main
steps of the algorithm is displayed in Figure 7. Similarly to section III.1,
it is important to to ensure the validity of a result of ”not operator
controllable” by repeating the test for different arrays of random parameters.

###  IV.3 Examples

In the following we consider a three-qubit array with Hamiltonian

$\hat{H}_{3q}(t)=\sum_{j=0}^{2}-\frac{\omega_{j}}{2}\hat{\sigma}_{z}^{j}+\sum_{k=0}^{1}J_{k,k+1}\hat{\sigma}_{z}^{k}\hat{\sigma}_{z}^{k+1}+\hat{H}_{ctrl}(t).$
(36)

The second term, containing the time-independent two-qubit couplings, has been
modified to $\hat{\sigma}_{z}^{k}\hat{\sigma}_{z}^{k+1}$ simply to showcase a
qubit interaction different from the one in the previous examples. The qubit
frequencies $\omega_{j}$ and the coupling strengths $J_{k,k+1}$ are listed in
Table 2. We take two different $\hat{H}_{ctrl}(t)$ to study an example that is
operator controllable and one that is not.

| Coupling strengths (MHz) |
---|---|---
|  | $J_{0,1}$ | $J_{1,2}$ |  |
|  | $170$ | $220$ |  |
Qubit frequencies (GHz)
Original | Auxiliary
$\omega_{0}$ | $\omega_{1}$ | $\omega_{2}$ | $\omega_{3}$ | $\omega_{4}$ | $\omega_{5}$
$5.40$ | $5.30$ | $5.42$ | $5.37$ | $5.29$ | $5.34$
Table 2: Parameters for the Hamiltonian (36) and the ancilla qubits necessary
for the circuit (31).  Figure 8:  Example of a three-qubit system that is
operator-controllable, cf. Eq. (37)

The first one is given by

$\hat{H}_{ctrl}(t)=u_{1}(t)\hat{\sigma}_{x}^{0}+u_{2}(t)\hat{\sigma}_{y}^{1}+u_{3}(t)\hat{\sigma}_{x}^{2},$
(37)

see Figure 8. It is operator controllable as can easily be proven by the Lie
algebra rank condition [5] and the graph method [4].

Since we have 3 controls in the original three-qubit system, the minimum
number of layers needed to reach the maximum value of dimensional expressivity
for the bipartite system, $expr_{dim}=63$, is $n_{l}=16$ according to Eq.
(35). The orthonormal basis used to define the maximally entangled state
$\ket{\psi_{ME}}$ is the logical basis of the free qubits. Last, we generate a
random set of parameters $\vec{\vartheta}\in[0,2\pi]^{64}$. Maximum
dimensional expressivity of 63 is found for the last parameter of the last
layer, confirming that the system is operator controllable.

Figure 9:  Example of a three-qubit system that is not operator-controllable,
cf. Eq. (38).

For the second example, we choose a different set of controls,

$\hat{H}_{ctrl}(t)=u_{1}(t)\hat{\sigma}_{x}^{0}+u_{2}(t)\hat{\sigma}_{y}^{1}+u_{3}(t)\hat{\sigma}_{z}^{2},$
(38)

see Figure 9, making the system not controllable. We repeat the same procedure
as before, since the number of controls is again $m=3$. At the end of 16
layers the circuit only reaches $expr_{dim}=31$, which is less than the 63
needed for operator controllability. We could add another layer to verify that
every new rotation gate will have a redundant parameter. However, in this case
it is sufficient to inspect the rank of the matrices $S_{n}$ from Eq. (7) in
the last layers. We find that the last independent parameter appears at the
end of the tenth layer, with all the remaining ones being exclusively formed
by redundant parameters. This is a sufficient condition to determine that the
system is not operator controllable (as long as it is verified with multiple
sets of random parameters).

We emphasize that it is important to corroborate every “not controllable”
result with different arrays $\vec{\vartheta}$ chosen at random. Selecting
$\vec{\vartheta}$ in a non-randomized fashion may lead to cases where the
dimensional expressivity is lower than the maximum value reached with other
different parameters. This would yield wrong results in terms of
controllability. It is easily rationalized in terms of symmetries of the
commutators $[\hat{H}_{i},\hat{R}^{A}_{k}(\vartheta_{j})]$. These are linked
to the partial derivatives of the circuit
$\partial_{i}C_{OC}^{AB}(\vec{\vartheta})$ and to the dimensional expressivity
of the circuit. Performing further numerical tests on the previously discussed
examples, we have experimented with selecting parameters instead of choosing
them at random. Wrong results with lower dimensional expressivity arose when
all the parameters were chosen to be the same, e.g. $\vartheta_{j}=1$ for
every $j$. In every instance, these problems vanished as soon as we generated
a new set of random parameters.

Another important issue concerns the minimum tolerance $\tau$ used to
determine the rank of the $S_{n}$ matrices. More precisely, $\tau$ represents
the threshold at which the values of the singular value decomposition of
$S_{n}$ are considered zero. $\tau$ is crucial to determine the different
redundant parameters and the expressivity of the circuit. If $\tau$ is too
high, then some linearly independent vectors might be deemed dependent by
mistake, which would revert on a wrong lower value of the circuit
expressivity, potentially turning a controllable system into a fake non-
controllable one. Conversely, if $\tau$ is too small some errors might start
to add up to make linearly dependent vectors look as if they were independent,
falsely showing some parameters as independent. This would in turn raise the
dimensional expressivity, usually above the $d^{2}-1$ threshold that we know
to be valid for the case of the operator controllability test. To avoid these
cases, it is advisable to use operators with similar orders of magnitude and
try different ranges for $\tau$ depending on the order of magnitude of the
operators $\hat{H}_{j}$ from Eq. (1). If the dimensional expressivity analysis
is performed on quantum hardware, the tolerance $\tau$ will also depend on the
device noise. Indeed, the accuracy of the measurements and the circuit
dynamics will take a toll on the accuracy of the rank of the matrices $S_{n}$.
Inevitably, noisier devices will require higher tolerances to determine
whether there are redundant parameters (i.e. whether $\det(S_{n})=0$) or not.

##  V Discussion and Conclusions

We have introduced two hybrid quantum-classical algorithms to test pure-state
and operator controllability of qubit arrays. As opposed to usual Lie rank and
graph methods, the presented algorithms are run directly on a quantum circuit
designed to mimic the dynamics of the quantum system to be studied. We have
showcased the capabilities of the procedure with four paradigmatic examples
that cover all scenarios for pure-state and operator controllability.

A useful application of these tests is the resource-efficient design of
quantum chips. Our algorithm provides a systematic way to deduce the minimal
number of local controls and qubit couplings required to maintain
controllability, as a prerequisite of universal quantum computation. In other
words, it allows one to identify redundant controls and thus to ease scaling
up the quantum chip size. Importantly, the tests allow to obtain this
information before the devices are built, as long as the associated quantum
circuit can be implemented on a different device. Note that while the rank
analysis of the $S_{n}$ matrices scales with the size of the system Hilbert
space, this does not pose a fundamental limitation. It can be overcome by
mapping the rank computation to a quantum device. More precisely, the quantum
device would then be used to find the lowest eigenvalue of $S_{n}$ in order to
determine whether a parameter is redundant or not. This permits the efficient
identification of redundant parameters and the removal of their parametric
gates in the circuit. Noise in the device running our hybrid algorithm will
limit the accuracy of the lowest eigenvalue and thus determine the minimum
threshold for an eigenvalue to be considered zero.

In addition to its practical aspects, at the conceptual level, our work has
revealed the close connection between the controllability of quantum systems
and the dimensional expressivity of quantum circuits. In particular, this
insight arises from the relation between the states that can be reached in a
controllable system and the final states that can be produced in a parametric
quantum circuit. The dimensional expressivity analysis allowed us to
efficiently quantify the circuit expressivity. Its search for redundant
parameters was essential in determining which controls contributed to reach
more states in the Hilbert space. The link between the pure-state and operator
controllability test is the inclusion of the Choi-Jamiołkovski isomorphism
that creates a map between operators in a Hilbert space and the states of the
extended bipartite space.

Variational quantum algorithms have previously been used to improve the design
of optimal pulses in quantum systems [37]. Quantum optimal control theory in
general [7, 6] encompassses both the design of the pulse shapes, i.e., control
synthesis, and controllability analysis. The controllability tests described
here thus extend the use of parametric quantum circuits to the second pillar
of quantum optimal control. Quantum optimal control is also closely related to
system characterization where controls can be interleaved with free evolutions
[38, 39] or applied continuously [40].

In future work, it will be interesting to study systems with non-local
controls, e.g. tunable two-qubit couplings. Moreover, it may be possible to
expand our approach to systems other than qubit arrays. To this end, the key
task will be to find a mapping from the non-qubit system to the associated
quantum circuit that runs on a qubit array. The problem of mapping certain
dynamics to a quantum circuit has already been a subject of extensive
research, for example, when using parametric variational algorithms for
calculating the electronic structure of molecules [41, 42] or their quantum
dynamics [43]. Finally, an intriguing question is how the removal of redundant
controls affects the minimum time at which certain dynamics can be
implemented, i.e., the quantum speed limit of the system. A controllable
system with a new control added can have the same or a lower minimum time for
a state transfer or unitary gate. Conversely, removing redundant controls
might incur a higher minimum time. Most likely, quantum device design will
have to balance the requirements for controllability and operation speed.

## Acknowledgments

We gratefully acknowledge financial support from the Einstein Research
Foundation (Einstein Research Unit on Near-Term Quantum Devices) and CRC 183
(project C05).

## References

  * Nielsen and Chuang [2010] M. A. Nielsen and I. L. Chuang,  _Quantum computation and quantum information_ (Cambridge university press, 2010).
  * Krantz  _et al._ [2019] P. Krantz, M. Kjaergaard, F. Yan, T. P. Orlando, S. Gustavsson, and W. D. Oliver, Applied physics reviews 6, 10.1063/1.5089550 (2019).
  * García-Ripoll [2022] J. J. García-Ripoll,  _Quantum Information and Quantum Optics with Superconducting Circuits_ (Cambridge University Press, 2022).
  * Gago-Encinas  _et al._ [2023] F. Gago-Encinas, M. Leibscher, and C. Koch, Quantum Science and Technology 8, 045002 (2023).
  * d’Alessandro [2021] D. d’Alessandro,  _Introduction to quantum control and dynamics_ (CRC press, 2021).
  * 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, and F. K. Wilhelm, EPJ Quantum Technol. 9, 19 (2022).
  * Glaser  _et al._ [2015] S. J. Glaser, U. Boscain, T. Calarco, C. P. Koch, W. Köckenberger, R. Kosloff, I. Kuprov, B. Luy, S. Schirmer, T. Schulte-Herbrüggen, D. Sugny, and F. K. Wilhelm, EPJ D 69, 279 (2015).
  * Albertini and D’Alessandro [2002] F. Albertini and D. D’Alessandro, Linear Algebra and its Applications 350, 213 (2002).
  * Boscain  _et al._ [2012] U. Boscain, M. Caponigro, T. Chambrion, and M. Sigalotti, Comm. Math. Phys. 311, 423 (2012).
  * Boscain  _et al._ [2014] U. Boscain, M. Caponigro, and M. Sigalotti, Journal of Differential Equations 256, 3524 (2014).
  * Schirmer  _et al._ [2001] S. G. Schirmer, H. Fu, and A. I. Solomon, Phys. Rev. A 63, 063410 (2001).
  * Fu  _et al._ [2001] H. Fu, S. G. Schirmer, and A. I. Solomon, Journal of Physics A: Mathematical and General 34, 1679 (2001).
  * Altafini [2002a] C. Altafini, Journal of Mathematical Physics 43, 2051 (2002a).
  * Pozzoli  _et al._ [2022] E. Pozzoli, M. Leibscher, M. Sigalotti, U. Boscain, and C. P. Koch, J. Phys. A: Math. Theor. 55, 215301 (2022).
  * Chambrion  _et al._ [2009] T. Chambrion, P. Mason, M. Sigalotti, and U. Boscain, Annales de l’Institut Henri Poincaré C 26, 329 (2009).
  * Boussaïd  _et al._ [2013] N. Boussaïd, M. Caponigro, and T. Chambrion, IEEE Trans. Automat. Control 58, 2205 (2013).
  * Leibscher  _et al._ [2022] M. Leibscher, E. Pozzoli, C. Pérez, M. Schnell, M. Sigalotti, U. Boscain, and C. P. Koch, Communications Physics 5, 1 (2022).
  * 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, 4213 (2014).
  * McClean  _et al._ [2016] J. R. McClean, J. Romero, R. Babbush, and A. Aspuru-Guzik, New Journal of Physics 18, 023023 (2016).
  * Preskill [2018] J. Preskill, Quantum 2, 79 (2018).
  * Funcke  _et al._ [2021a] L. Funcke, T. Hartung, K. Jansen, S. Kühn, and P. Stornati, Quantum 5, 422 (2021a).
  * Funcke  _et al._ [2021b] L. Funcke, T. Hartung, K. Jansen, S. Kühn, M. Schneider, and P. Stornati, arXiv preprint arXiv:2111.11489 10.48550/arXiv.2111.11489 (2021b).
  * Altafini [2002b] C. Altafini, Journal of Mathematical Physics 43, 2051 (2002b).
  * Albertini and D’Alessandro [2003] F. Albertini and D. D’Alessandro, IEEE Transactions on Automatic Control 48, 1399 (2003).
  * Schirmer  _et al._ [2002] S. Schirmer, I. Pullen, and A. Solomon, Journal of Physics A: Mathematical and General 35, 2327 (2002).
  * Cerezo  _et al._ [2021] M. Cerezo, A. Arrasmith, R. Babbush, S. C. Benjamin, S. Endo, K. Fujii, J. R. McClean, K. Mitarai, X. Yuan, L. Cincio, _et al._ , Nature Reviews Physics 3, 625 (2021).
  * Note [1] This is in contrast to many commonly used definitions of a circuit that only consider the gate sequence and not the device initialization.
  * Sim  _et al._ [2019] S. Sim, P. D. Johnson, and A. Aspuru-Guzik, Advanced Quantum Technologies 2, 1900070 (2019).
  * Friedrich and Maziero [2023] L. Friedrich and J. Maziero, arXiv preprint arXiv:2301.06883 10.48550/arXiv.2301.06883 (2023).
  * Lee and Lee [2012] J. M. Lee and J. M. Lee,  _Smooth manifolds_ (Springer, 2012).
  * Kjaergaard  _et al._ [2020] M. Kjaergaard, M. E. Schwartz, J. Braumüller, P. Krantz, J. I.-J. Wang, S. Gustavsson, and W. D. Oliver, Annual Review of Condensed Matter Physics 11, 369 (2020).
  * Choi [1975] M.-D. Choi, Linear algebra and its applications 10, 285 (1975).
  * Jamiołkowski [1972] A. Jamiołkowski, Reports on Mathematical Physics 3, 275 (1972).
  * Lloyd  _et al._ [2014] S. Lloyd, M. Mohseni, and P. Rebentrost, Nature Physics 10, 631 (2014).
  * Jiang  _et al._ [2013] M. Jiang, S. Luo, and S. Fu, Physical Review A 87, 022310 (2013).
  * Note [2] We only claim that the value for the maximal dimensional expressivity is $d^{2}-1$ (with $d=2^{q}$) for the circuits $C^{AB}_{OC}$ (31). Other parametric quantum circuits acting on $\mathcal{H}\otimes\mathcal{H}$ could in principle reach higher values of expressivity, up to $2^{2q+1}-1$.
  * Magann  _et al._ [2021] A. B. Magann, C. Arenz, M. D. Grace, T.-S. Ho, R. L. Kosut, J. R. McClean, H. A. Rabitz, and M. Sarovar, PRX Quantum 2, 010101 (2021).
  * Wittler  _et al._ [2021] N. Wittler, F. Roy, K. Pack, M. Werninghaus, A. S. Roy, D. J. Egger, S. Filipp, F. K. Wilhelm, and S. Machnes, Phys. Rev. Appl. 15, 034080 (2021).
  * Lu  _et al._ [2023] J. Z. Lu, R. A. Bravo, K. Hou, G. A. Dagnew, S. F. Yelin, and K. Najafi, arXiv preprint arXiv:2206.11970 10.48550/arXiv.2206.11970 (2023).
  * Dutkiewicz  _et al._ [2023] A. Dutkiewicz, T. E. O’Brien, and T. Schuster, arXiv preprint arXiv:2304.07172 10.48550/arXiv.2304.07172 (2023).
  * Xia and Kais [2020] R. Xia and S. Kais, Quantum Science and Technology 6, 015001 (2020).
  * Kandala  _et al._ [2017] A. Kandala, A. Mezzacapo, K. Temme, M. Takita, M. Brink, J. M. Chow, and J. M. Gambetta, Nature 549, 242 (2017).
  * Ollitrault  _et al._ [2021] P. J. Ollitrault, A. Miessen, and I. Tavernelli, Accounts of Chemical Research 54, 4229 (2021).