Notebooks
http://bactra.org/notebooks
Cosma's NotebooksenKoopman Operators for Modeling Dynamical Systems and Time Series
http://bactra.org/notebooks/2024/02/24#koopman-operator-modeling
<P>Start with your favorite deterministic <a href="chaos.html">dynamical system</a>, say (in
discrete time to make things easy) \( x_{t+1} = f(x_t) \),
where \( x_t \) is the <a href="prediction-process.html">state</a>. Ordinarily
we think of time evolving by repeatedly applying the mapping \( f \), so
\( x_{t+2} = f(f(x_t)) = f^{(2)}(x_t) \), and so forth. In general
\( x_t = f^{(t)}(x_0) \). The state evolves,
according to repeated applications of the map. In general, this mapping
is extremely nonlinear, and it only becomes harder to parse out after
multiple time steps.
<P>Now consider any nice function \( h \) of the state, which gives us an
observable \( y_t = h(x_t) \). How does this observable evolve? Well,
obviously \( y_{t+1} = h(f(x_t)) \), and in general \( y_t = h(f^{(t)}(x_0) \).
So far so trivial. The trick comes from realizing that what we have actually
done is define an operator on the space of observables, canonically called \( K
\) or \( \mathcal{K} \), where \( h(f^{(t)}(x_) = (K^t h)(x_0) \). (I'm being
pedantic about parentheses to make the order of operations very clear. Also,
this is a good place to say that "nice function" means "measurable function,
plus any other regularity properties we might happen to find useful", e.g.,
sometimes we just care about square-integrable observables.) Instead of
thinking about time evolution in the state space, we can just leave the state
alone, and have the \( K \) operator transform the observables. The advantage
of doing this is that \( K \) is a linear operator on the space of observables;
it's really easy to convince yourself that \(K (h_1+h_2) = K h_1 + K h_2 \).
And linear operators are easy! It's true we've gone from a finite-dimensional
state space to an infinite-dimensional function space, but linearity is still
a really powerful simplification.
If the gods were very kind, \( K \) would
have a countable basis in eigenfunctions, \( K \phi_i = \lambda_i \phi_i \),
and \( h(x) = \sum_{i=1}^{\infty}{c_i \phi_i(x)} \) for some coefficients \( c_i \). Then the dynamics of any observable would be really simple:
\[
K^t h(x_0) = \sum_{i=1}^{\infty}{K^t c_i \phi_i(x_0)} = \sum_{i=1}^{\infty}{\lambda_i^t c_i \phi_i(x_0)}
\]
If we want the dynamics of a <em>different</em> observable, \( z_t = g(x(t))
\), then we'd have \( g(x) = \sum_{i=1}^{\infty}{d_i \phi_i(x)} \), and the
dynamics would be \( g(x_t) = K^t g(x_0) = \sum_{i=1}^{\infty}{\lambda^i_t d_i
\phi_i(x_0)} \). That is, only the coefficients going into the observable
would change. We could think of \( \phi_i(x_0) \) as an (infinite) set of
coordinates in which the dynamics are linear (and governed by the eigenvalues
\( \lambda_i \)), and the observations are also linear (and given by the
coefficients defining the observables). Even if the gods are not quite so
kind, and we have to learn some actual spectral theory, linear dynamics, even
on an infinite-dimensional space, is still a lot nicer to have to deal with
than nonlinearity...
<P>(For a <a href="stochastic-process.html">stochastic process</a>, or at least
a <a href="markov.html">Markov</a> process, we'd have the contrast between the
"transition kernel" which gives the conditional distribution for the next
state, \( \kappa(x, A) \equiv \mathbb{P}\left( X_{t+1} \in A| X_t =x \right)
\), versus the conditional expectation of an observable, \( \mathbb{E}\left(
h(X_{t+1}) | X_t =x \right) \). Now, rather than looking at the conditional
distribution directly through the kernel, we can define the <strong>Markov
operator</strong> which takes probability measures to probability measures, \(
M\nu(A) = \int{\kappa(x, A) d\nu(x)} \). (If we're dealing with a
deterministic dynamical system, which is after all a special case of a Markov
process, the equivalent of the Markov operator is called a Perron-Frobenius or
Frobenius-Perron operator.) This is a linear operator on probability measures
(and every linear operator on probability measures likewise defines a kernel.)
The adjoint operator to the Markov operator, which acts on observables, is
called, in the literature, the transition operator. So lots of Koopman
operator theory generalizes very directly to the theory of Markov operators.)
<P>The first person to clearly realize all this was, indeed, Koopman in the
1930s. (I haven't read his original papers so I won't cite them, but the
references I do give below agree on this history and I trust them.*) For a long
time this was just a bit of a neat technical trick. (That's certainly how I
learned it in graduate school, as part of <a href="ergodic-theory.html">ergodic
theory</a>, and how I used it in a 2004 paper on the arrow of time.) What's
intriguing to me, and why I have begun this notebook, is that since then, and
especially over the last decade, people have begun trying
to <em>practically</em> use this idea, by learning or estimating \( K \) from
observations. In particular,
<a href="control.html">control theorists</a> seem to be very taken with this.
Of course this involves some sort of finite-dimensional truncation of the
infinite-dimensional operator, sometimes, it seems to me, an extremely crude
one**.
<P>I don't have any immediate plans to do anything with or in this literature,
but I do want to keep track of it. In particular, at some point I want to
really wrap my head around whether learning the infinite-dimensional but linear
operator \( K \) is really any easier
than <a href="equations-of-motion-from-a-time-series.html">learning the
finite-dimensional but nonlinear map \( f \) directly</a>. Also, the
truncations involved in work with "data-driven" Koopman operators make me
wonder about using <a href="random-features.html">random features</a> somehow.
In particular, I offer a conjecture, with the disclaimer that I have thought
about it for, literally, five minutes: Say the underlying state \( x_0 \) lives
on a \( d \)-dimensional manifold. Pick \( m \geq 2d+1 \) real-valued
observables \( h_1, \ldots h_{m} \) from a probability distribution supported
on some set of nice functions \( H \). (E.g,, \( H \) might consist of
finite-frequency sine waves with random phase offsets.) <em>Conjecture</em>:
An operator which linearly evolves \( h_1, \ldots h_m \) can be extended
(somehow) to an operator which linearly evolves any function in the span of \(
H \). (E.g., the span of random sine waves is all functions with nice Fourier
transforms.)
<P>*: The difference between the state-evolution viewpoint and the
observable-evolution viewpoint corresponds to the difference between the
Schrodinger and the Heisenberg "pictures"
of <a href="quantum-mechanics.html">quantum mechanics</a>. ("Recall" that in
time-indepenent QM, if the system has wave-function \( \psi \), the expected value of an observable, represented by an operator \( A \), is \( \langle \psi | A | \psi \rangle \equiv \int{\psi^*(x) A \psi(x) dx} \). In the Schrodinger
picture, we time-evolve the wave function, so \( \psi \) at time 0 evolves to \( e^{iHt} \psi \) at time \( t \), \( H \) being the Hamiltonian operator. In the Heisenberg picture, wave functions are static,
but the operators representing observables evolve, so \( A(t) = e^{-iHt} A e^{iHt} \). Either way we get the same expression for the expectation of the observable at time \( t \), namely \( \int{\psi(x) e^{-iHt} A e^{iHt} \psi(x) dx} \).
This distinction goes back to
the 1920s, so I imagine if we were to read back into the history of operator
theory before 1926 we'd find someone (Hilbert?) stating the idea as
what <a href="http://bactra.org/reviews/tao-structure-and-randomness/">Terence
Tao would call a "trick"</a> (or however you said that in German a century
ago). --- Incidentally, before you start wondering whether quantum mechanics,
which is linear and infinite-dimensional, mightn't just be the result of
looking at the Koopman (or Frobenius-Perron) operators of a finite-dimensional
nonlinear dynamical system, I remember hearing my nonlinear dynamics teachers
idly batting around the same notion back in the 1990s. They didn't think it
was worth pursuing, for a whole host of reasons (starting with Bell's
inequalities), and I do not presume to be wiser than them.
<P>**: In particular, "dynamical mode decomposition" seems to mean just "fit a
<a href=time-series.html">VAR(1)</a> to successive observations and then
prophesy upon the eigenvectors", but perhaps I am missing some subtleties.
<P>See also:
<a href="equations-of-motion-from-a-time-series.html">Equations of Motion from a Time Series</a>
<ul>Recommended:
<li>Steven L. Brunton, Marko Budišić, Eurika Kaiser and J. Nathan Kutz, "Modern Koopman Theory for Dynamical Systems", <a href="https://doi.org/10.1137/21M1401243"><cite>SIAM Review</cite> <strong>64</strong> (2022): 229--340</a> [With apologies to the second author for my ignorant inability to reproduce the accent symbols in his family name in HTML; and with thanks to one of my neighbors for leaving this copy of <cite>SIAM Review</cite> in the local little free library!]
<li>Andrzej Lasota and Michael C. Mackey, <cite><a href="https://doi.org/10.1007/978-1-4612-4286-4">Chaos, Fractals, and Noise: Stochastic Aspects of Dynamics</a></cite> [Though this focuses more on the Frobenius-Perron operator
that linearly evolves distributions over states than on the Koopman operator
that linearly evolves observables]
</ul>
<ul>Modesty forbids me to recommend:
<li>CRS, <cite><a href="http://www.stat.cmu.edu/~cshalizi/almost-none/">Almost None of the Theory of Stochastic Processes</a></cite> [Where I tried to explain what I knew about Markov and transition operators, when I knew something about Markov and transition operators]
<li>CRS, "The Backwards Arrow of Time of the Consistently Bayesian
Statistical Mechanic", <a
href="http://arxiv.org/abs/cond-mat/0410063">cond-mat/0410063</a> [<a href="http://bactra.org/weblog/270.html">Self-exposition</a>]
</ul>
<ul>To read:
<li>Craig Bakker, Steven Rosenthal, Kathleen E. Nowak, "Koopman Representations of Dynamic Systems with Control", <a href="http://arxiv.org/abs/1908.02233">arxiv:1908.02233</a>
<li>Marko Budišić, Ryan M. Mohr and Igor Mezić, "Applied Koopmanism",
<a href="https://doi.org/10.1063/1.4772195"><cite>Chaos</cite> <strong>22</strong> (2012): 047510</a>, <a href="http://arxiv.org/abs/1206.3164">arxiv:1206.3164</a>
<li>Ido Cohen and Guy Gilboa, <cite><a href="https://doi.org/10.1017/9781009323826">Latent Modes of Nonlinear Flows: a Koopman Theory Analysis</a></cite>
<li>Stefan Klus, Ingmar Schuster, Krikamol Muandet, "Eigendecompositions of Transfer Operators in Reproducing Kernel Hilbert Spaces",
<a href="https://doi.org/10.1007/s00332-019-09574-z"><cite>Journal of Nonlinear Science</cite> <strong>30</strong> (2020): 283--315</a>, <a href="http://arxiv.org/abs/1712.01572">arxiv:1712.01572</a>
<li>Vladimir Kostic, Pietro Novelli, Andreas Maurer, Carlo Ciliberto, Lorenzo Rosasco, Massimiliano Pontil, "Learning Dynamical Systems via Koopman Operator Regression in Reproducing Kernel Hilbert Spaces", <a href="http://arxiv.org/abs/2205.14027">arxiv:2205.14027</a>
<li>Matthew D. Kvalheim, Philip Arathoon, "Linearizability of flows by embeddings", <a href="http://arxiv.org/abs/2305.18288">arxiv:2305.18288</a>
<li>Ilan Naiman, N. Benjamin Erichson, Pu Ren, Michael W. Mahoney, Omri Azencot, "Generative Modeling of Regular and Irregular Time Series Data via Koopman VAEs", <a href="http://arxiv.org/abs/2310.02619">arxiv:2310.02619</a>
<li>Samuel E. Otto and Clarence W. Rowley, "Koopman Operators for Estimation and Control of Dynamical Systems", <a href="https://doi.org/10.1146/annurev-control-071020-010108"><cite>Annual Review of Control, Robotics, and Autonomous Systems</cite> <strong>4</strong> (2021): 59--87</a>
<li>Yen Ting Lin, Yifeng Tian, Daniel Livescu, Marian Anghel, "Data-driven learning for the Mori--Zwanzig formalism: a generalization of the Koopman learning framework", <a href="http://arxiv.org/abs/2101.05873">arxiv:2101.05873</a>
<li>Manuel Santos Gutiérrez, Valerio Lucarini, MickaĆ«l D. Chekroun, Michael Ghil, "Reduced-Order Models for Coupled Dynamical Systems: Data-driven Methods and the Koopman Operator", <a href="https://doi.org/10.1063/5.0039496"><cite>Chaos</cite> <strong>31</strong> (2021): 053116</a>, <a href="http://arxiv.org/abs/2012.01068">arxiv:2012.01068</a>
<li>Ali Tavasoli, Teague Henry, Heman Shakeri, "A purely data-driven framework for prediction, optimization, and control of networked processes: application to networked SIS epidemic model", <a href="http://arxiv.org/abs/2108.02005">arxiv:2108.02005</a>
</ul>