1 s2.0 S2405896320322795 Main

Download as pdf or txt
Download as pdf or txt
You are on page 1of 7

Available online at www.sciencedirect.

com

ScienceDirect
IFAC PapersOnLine 53-2 (2020) 6062–6068
Data-Driven
Data-Driven quasi-LPV
quasi-LPV Model
Model Predictive
Predictive Control
Control
Data-Driven
Data-Driven
Using quasi-LPV
quasi-LPV
Koopman Model
Model
OperatorPredictive
Predictive
TechniquesControl
Control
Data-Driven quasi-LPV
Using Koopman Model Predictive
Operator TechniquesControl
Using
Using Koopman
Koopman Operator
Operator Techniques
Techniques
Using Koopman
Pablo. S.∗ Operator∗Techniques ∗
G. Cisneros ∗∗ Adwait
Pablo.
Pablo. S.
S. G.
G. Cisneros
Cisneros Adwait Datar
∗∗ Adwait
Datar
Datar
∗∗ Patrick Göttsch
∗ ∗ Patrick
Patrick Göttsch

Göttsch ∗
Pablo. S. G. Herbert
Cisneros
Herbert Werner
Adwait Datar
Werner ∗∗ ∗ Patrick Göttsch ∗∗
Pablo.
Pablo. S.
S. G.
G. Cisneros ∗ Adwait
Herbert
Cisneros Datar
Datar∗∗ ∗ Patrick
Werner
Adwait Patrick Göttsch
Göttsch ∗
Herbert
Herbert Werner
Werner
Herbert
∗ Institute of Control Systems,
∗∗ Institute of Control Systems, HamburgWerner ∗
University of Technology, Germany
∗∗ Institute Control Systems, Hamburg
[email protected] University
University of of Technology,
[email protected], Germany
Germany
Institute
∗ Institute
of Control Systems, Hamburg University of Technology, Germany
Institute of Control Systems, Hamburg University of Technology, Germany
[email protected] [email protected]
[email protected]
Hamburg
[email protected] [email protected]
[email protected] [email protected] Germany
Control Systems, University of Technology,
[email protected]
[email protected]
[email protected] [email protected]
[email protected]
[email protected] [email protected]
[email protected] [email protected]
[email protected] [email protected]
[email protected] [email protected]
[email protected] [email protected]
Abstract:
Abstract:
Abstract:
A fast data-driven extension of the velocity-based quasi-linear parameter-varying model predictive
Abstract:
A
A fast
Abstract: data-driven
fast (qLMPC)
data-drivenapproach extension
extension of
of the
the velocity-based
velocity-based quasi-linear
quasi-linear parameter-varying
parameter-varying model
model predictive
predictive
Abstract:
control is proposed for scenarios where first principles models are not available or
A
A fast
control
fast
control data-driven
(qLMPC)
data-driven
(qLMPC) extension
approach
extension
approach is of
is proposed
of the
proposed
the velocity-based
for scenarios
scenarios where
velocity-based
for wherequasi-linear
first principles
quasi-linear
first parameter-varying
principles models are
parameter-varying
models are not model
not available
model
available or are
predictive
predictive
or are
are
A fast (qLMPC)
control data-driven
computationally too extension
expensive.
approach is ofWetheusevelocity-based
proposed tools
for from
scenarios the
wherequasi-linear
recently
first parameter-varying
proposed
principles Koopman
models are model
operator
not available predictive
framework or are
computationally
control (qLMPC)
computationally too
too expensive.
approach is
expensive. We
proposed
We use
use tools
for
tools from
scenarios
from the
where
the recently
first
recently proposed
principles
proposed Koopman
models
Koopman are operator
not available
operator framework
framework or are
control
to identify(qLMPC)
computationally a approach
quasi-linear
too is proposed
parameter-varying
expensive. We use for scenarios
tools model
from (inwhere
theinput/outputfirst principles
recently and
proposed models are
state-space
Koopman form)notbyavailable
operator choosing
framework or the
are
to
to identify
computationally
identify aa quasi-linear
too
quasi-linear parameter-varying
expensive. We
parameter-varyinguse tools model
from
model (in
the
(in input/output
recently
input/output and
proposed
and state-space
Koopman
state-space form) by
operator
form) by choosing
framework
choosing the
the
computationally
observables
to identify a from too
quasi-linear expensive.
physical insight. WeAn
parameter-varyinguseonline
tools from
update
model thestrategy
(in recentlytoproposed
input/output adapt
and to Koopmanform)
changes
state-space in operator
the plant
by framework
dynamics
choosing the
observables
to identify from physical
aa quasi-linear insight.
parameter-varyingAn
An online update
model (in strategy
input/output to adapt
and to changes in the plant dynamics
observables
to
is identify
also
observables proposed. fromThe
from
physical
quasi-linear insight.
parameter-varying
approach
physical insight.is online
validated
An online
update
model (in strategy
experimentally
update input/output
strategy on to and state-space
adapt
aa strongly
to adapt to
changes form)
to nonlinear
state-space
changes in
the by
the plant
choosing
in3-degree-of-freedom
form) plant
by dynamics
choosing
dynamics
the
the
is
is also
observables
also proposed.
proposed. from The
The approach
physical insight.
approach is
is validated
An online
validated experimentally
update
experimentallystrategy on
on toa strongly
adapt
strongly to nonlinear
changes
nonlinear in3-degree-of-freedom
the plant
3-degree-of-freedom dynamics
observables
Control
is also Moment
proposed. fromThe physical
Gyroscope, insight.
approach showing
is An remarkable
online
validated update strategy
tracking
experimentally to
performance.
on a adapt to nonlinear
strongly changes in3-degree-of-freedom
the plant dynamics
Control
is also Moment Gyroscope, showing remarkable tracking performance.
is also proposed.
Control
Control
Copyright
Moment
proposed.
Moment © 2020The
The approach
Gyroscope,
Theapproach
Gyroscope,
Authors.
is
showing
is
showing
validated
validated
This
experimentally
remarkable tracking
experimentally
is remarkable
an open tracking
access
on
articleon
aa strongly
performance.
strongly
performance.
under
nonlinear 3-degree-of-freedom
the CCnonlinear
BY-NC-ND 3-degree-of-freedom
license
Control
Control Moment
Moment Gyroscope,
Gyroscope, showing
showing remarkable
remarkable tracking
tracking performance.
performance.
(http://creativecommons.org/
Keywords: Nonlinear predictivelicenses/by-nc-nd/4.0)
control, linear parameter-varying systems, data-driven
Keywords: Nonlinear
Keywords: Nonlinear predictive
predictive control,
control, linear
linear parameter-varying
parameter-varying systems, data-driven control,
systems, data-driven control,
control,
Koopman
Keywords:
Koopman operator,
Nonlinear
operator, adaptive
predictive
adaptive control
control,
control linear parameter-varying systems, data-driven control,
Keywords:
Koopman
Keywords: Nonlinear
operator,
Nonlinear predictive
adaptive
predictive control,
control, linear parameter-varying systems, data-driven control,
control linear parameter-varying systems, data-driven control,
Koopman
Koopman operator,
operator, adaptive
adaptive control
Koopman 1. operator,
INTRODUCTION adaptive control
control at the core of most of these works is to approximate aa nonlinear
1. INTRODUCTION
1. INTRODUCTION at
at the
the core
core of
ofamost
most of these
these works
of dimensional works is is to
to approximate
approximate nonlinear
1.
1. INTRODUCTION
INTRODUCTION
system
at the
system
at the
with
core
with
core of
of
higher
most
aamost
higher of
of these
dimensional
these works
works
lifted
is to
lifted
is to
linear
approximate
linear
approximate
system
system aa nonlinear
a
nonlinear
such
nonlinear
such that
that
Model Predictive 1. INTRODUCTION
Control (MPC) is one of the most widely used system
at
thethe
system with
core
state with ofamosthigher
predictions
higher dimensional
of can
thesebeworks
dimensional obtainedlifted
is to by
lifted linear
approximate system
propagating
linear system such
a nonlinear
a
such that
higher
that
Model
Model Predictive
Predictive Control
Control (MPC)
(MPC) is
is one
one of
of the
the most
most widely
widely used
used the
system
the state
state with predictions
a higher
predictions can
can be
dimensional
be obtained
obtainedlifted by
by propagating
linear system
propagating a
such
a higher
that
higher
control strategies thanks to its versatility, easy extension to mul- system
the statewith
dimensional alinear
higher
predictions dimensional
system
can beforward
obtainedlifted
in bylinear
time. As system
propagating such
a consequence, that
Model
control
Model
control
Model
Predictive
strategies thanks
Predictive
strategies
Predictive
Control
thanks
Control
Control
to(MPC)
to(MPC)
its
(MPC)
is
is one
its versatility,
versatility,
is one
one
of the
the most
easy extension
ofcapability
ofeasy
the most
extension
most
widely
widely
widely to used
to mul-
mul-
used the
used
dimensional
state
stateofpredictions
dimensional
the
instead
linear
linear system
predictions
a non-convex can
system be forward
obtained
forward
canoptimization
beforward
obtained
in time.
by
inproblem,
time. As
As aaaquadratic
by propagating
propagating aaa higher
consequence,
consequence, higher
higher
pro-
tiple
control
tiple input-multiple
strategies
input-multiple output
thanks
output to systems,
its and
versatility,
systems, easy
and capabilityextension
capability to explicitly
to mul-
to explicitly
explicitly dimensional
instead of linear
aa non-convex system optimization in time.
problem, As a consequence,
aaaquadratic pro-
control
tiple strategies
input-multiple thanks
output tothe
its versatility,
systems, and easy extensionto to mul-
mul- dimensional
instead
dimensional ofbe linear
non-convex
linear for system
system forward
optimization
forward in time.
time. As
problem,
inproblem, Aslinear consequence,
quadratic pro-
control
consider
tiple
consider
strategies
constraints.
input-multiple thanks
constraints.output On
On the
to its versatility,
other
systems,
the hand,
other hand,and
hand,
easy
its extension
main
capability
its main drawback
to
main drawback
to
explicitly
drawback is
is instead
gram
instead
gram can
can of
of be
a
posed
a non-convex
non-convex
posed for the
the higher
optimization
higher
optimization
dimensional
dimensional
problem, aaquadratic
linear
a
consequence,
system.
quadratic
system. To
pro-
To
pro-
tiple
consider
tiple
the input-multiple
constraints.
input-multiple
complex computationsoutput
On
output systems,
other
systems,
(when and capability
its
and capability
compared to other to explicitly
tostrategies)
explicitly is gram
instead
keep can
the ofsizebe posed
a non-convex
of thefor the higher
optimization
optimization dimensional
problemproblem, linear
from system.
a quadratic
growing To
pro-
with
consider
the complex constraints.
computations On the other
(when hand,
compared its main
to other drawback
strategies) is gram
keep
gram can
the
can be
size
be posed
of
posed thefor
for the higher
optimization
the higher dimensional
problem
dimensional linear
from
linear system.
growing
system. To
with
To
theconsider
complex
consider constraints.
computations
constraints. On
On the
the other
(when
other hand,
compared
hand, its main
to
its to other
main drawback
strategies)
drawback is
is keep keep
gram
the the
can
dimension size
be of
posed theforoptimization
the higher problem
dimensional from
linear growing
system. with
To
entailed
the
the complex
entailed
entailedcomplex
by
by the
by
the
the online
computations solution
online solution
computations
online solution (when
(when
of an
of an
of an optimization
compared
optimization
compared
optimization to
problem.
other
problem.
other
This
strategies)
This keep
strategies)
problem. This the the size
the dimension
the
dimension size of ofof
of
ofthe
the
the
the lifted
optimization
lifted
theoptimization
lifted(for
space,
space,
space,
it
problem
it
it is
problem
is often
is often
often from
from
posed
posed
posed
in
growing
in
in the
growing
thewith
the
so-
so-
with
so-
the
becomescomplex
entailed bya thecomputations
problem online for (when
complex
solution of compared
annonlinear
optimization to other
systems, strategies)
problem.in which
This keep
called
the thedense
dimension size formulation
ofof the
the optimization
lifted space, problem
exampleit is in
often from
(Korda
posed growing
andin the with
Mezić,
so-
becomes
entailed
becomes bya the
a problem
problem online for
for complex
solution
complex of annonlinear
optimization
nonlinear systems,
systems,problem.in which
in which
This called
the
called dense
dimension
dense formulation
of the
formulation lifted (for
(for example
space,
exampleit is in
often
in (Korda
posed
(Korda and
andin Mezić,
the so-
Mezić,
entailed
case
becomes byaa the
a non-convex
problem online solution ofproblem
optimization
for annonlinear
optimization
needs to problem.
be solved. This
To the
2018a)).
calleddimension
denseExtensions of theusing
formulation lifted(for space,
reproducing
exampleit is kernel
often
in (Korda posed
methods
(Korda andin the can so-
Mezić,be
case
case
becomes
tackle aaa non-convex
becomes non-convex
this problem
a issue,
problem for complex
optimization
optimization
for
several complex
complex
algorithms
problem
nonlinear
problem
nonlinear
have
needs
needs
been
systems,
to be
systems,
to
systems,
proposed
in
in which
be solved.
solved.
in which
which
To 2018a)).
To called
2018a)).
called in
found dense
dense
Extensions
Extensions
(Williamsformulation
formulation
using
using
et al.,
reproducing
(for
(for
2014). example
reproducing
example
Other
kernel
in
kernel
in (Korda
data-driven
methods
methods and
and
approaches
can
can be
Mezić,
Mezić,be
case
tackle
case a non-convex
this issue,
issue, several
non-convex optimization
several
optimization algorithms problem
problem needs
haveneeds to
been proposed be
proposed
to be solved.
solved.whichTo
To 2018a)).
found
2018a)). in Extensions
(Williams
Extensions using
et al.,
using reproducing
2014). Other
reproducing kernel
data-driven
kernel methods
methods approaches can
can be
be
tackle
case a this
non-convex optimization algorithms problemhave been
needs to be solved.whichTo found
2018a)).
are e.g.in (Williams
Extensions et al.,
using 2014). Other
reproducing data-driven
kernel methods approaches can be
solve
tackle
solve
tacklean
solve
an
this
an
this
approximate
issue,
approximate
issue,
approximate several
several
problem,
algorithms
problem,
algorithms
problem,
enabling
enabling
enablinghave its
been
its implementation
proposed
implementation
havealgorithm,
been
its proposed
implementation which
which
for
for found
for found
are e.g.in (Kadali
e.g.in
arederived (Williams
(Kadali
(Williams
(Kadali
et
et
et et
al.,
et
al., 2001),
al.,
al.,al., 2014).
2001),
2014).
2001),
where
Otheraaa data-driven
where
Other
where
predictive
data-driven
predictive
predictive control
control
approaches
approaches
control
law
law
law
tackle
system
solve this
an with issue,
fast
approximate several
dynamics. algorithms
problem, One have
such
enabling been
its proposed
implementationreferredwhich to
for found
is
are e.g.in (Kadali
(Williams
by et et
data-driven
al., al., 2014).
2001), subspace Otheridentification,
where a data-driven
predictive approaches
making
control lawit
system
solve
system an with fast dynamics.
approximate
with fast dynamics.
problem, One
One such algorithm,
enabling
such algorithm,
its implementationreferred for
referred to are
to isis derived
e.g.
derived (Kadaliby
by data-driven
et al.,
data-driven 2001), subspace
where
subspace identification,
a predictive
identification, making
control
making lawit
it
solve
as
system anwith
approximate
quasi-Linear fast Model problem,
dynamics. Predictive
Oneenabling
Control
such its (qLMPC)
implementation
algorithm, has
referred beenfor
to are
suitable
is e.g. only
derived (Kadaliby for et al., systems.
linear
data-driven 2001), where identification,
subspace a predictive control making lawit
as
as quasi-Linear
system with
quasi-Linear fast Model
dynamics.
Model Predictive
One
Predictive Control
such
Control (qLMPC)referred
algorithm,
(qLMPC) has been
has been to issuitable
derived
suitable only
only by for
for linear
data-driven
linear systems.
systems. subspace identification, making it
system
proposed within fastModel
(Cisneros dynamics.
et al., One such
2016), where algorithm, referred to is derived byfordata-driven subspace identification, making it
asas quasi-Linear
proposed in (Cisneros
(Cisneros etPredictive
al., 2016), where aaa (qLMPC)
2016), Control nonlinear
nonlinear systemsystem
has
system been is suitable
is suitable
We only
propose
only an linear
alternativesystems. approach in this paper, building
as quasi-Linear
proposed
quasi-Linear
modeled
proposed
in
as
in a Modelet
Model
quasi-Linear
(Cisneros et
Predictive
al.,
Predictive
al., Parameter
2016),
Control
where
Control
Varying
where a
(qLMPC)
nonlinear
(qLMPC)
(qLPV)
nonlinear
has
has been
been
system.
system
is
is suitable
WeWe only for
propose
propose for
an
an
linear
linear
alternative
alternative
systems.
systems. approach
approach in
in this
this paper,
paper, building
building
modeled
proposed
modeled as
in
as a(Cisneros
a quasi-Linear
quasi-Linear et al., Parameter
2016),
Parameter Varying
where a
Varying (qLPV)system
nonlinear
(qLPV) system.
system. is on
We the results
propose an in (Cisneros
alternative et al.,
approach 2016) in and
this (Cisneros
paper, and
building
proposed
When
modeled in a(Cisneros
compared
as to other
quasi-Linear et al.,state-of-the-art
2016), where
Parameter amethods,
Varying nonlinear
(qLPV) system
e.g. Diehl
system. is We onon the results
propose
the results an in
in (Cisneros
alternative
(Cisneros et al.,
approach
et al., 2016)
2016) in and
this
and (Cisneros
paper,
(Cisneros and
building
and
When
modeled
When compared
as
compared a to other
other state-of-the-art
quasi-Linear
to state-of-the-art
Parameter methods,
Varying
methods,(qLPV) e.g.system.
e.g. Diehl on
Diehl We
Werner, propose
the 2020),
results anin alternative
and using
(Cisneros approach
Koopman-based
et al., 2016) in this and paper,
identification
(Cisneros building
tech-
and
modeled
et
When al. as a quasi-Linear
(2005),
compared qLMPCto other shows Parameter
to have
state-of-the-art Varying
comparable
methods,(qLPV) e.g.system.
numerical
Diehl onWerner,the
Werner, 2020),
results
2020), and
in
and using
(Cisneros
using Koopman-based
et al.,
Koopman-based 2016) identification
and (Cisneros
identification tech-
and
tech-
et
et al.
When
al. (2005),
compared
(2005), qLMPC
qLMPCto other
other shows
shows to have
state-of-the-art
to have and comparable
methods,
comparable numerical
e.g. Diehl
numerical on
niques
Werner,the results
simply
2020), to in (Cisneros
andobtain et
using aaaKoopman-basedal.,
velocity-based
Koopman-based 2016) and
qLPV (Cisneros
model.
identification and
The
tech-
When
and compared
closed-loop to
performance state-of-the-art
(Cisneros methods,
Werner e.g.
(2017)). Diehl
An niques
niques simply to obtain velocity-based qLPV model. The
et
and
andet al.
al. (2005),
closed-loop
(2005),
closed-loop qLMPC
performance
qLMPC
performance shows
shows to
to have
(Cisneros
have
(Cisneros comparable
and Werner (2017)).
comparable
and Werner numerical
(2017)).
numerical An Werner,
An Werner,
identification
niques
2020),
simply
2020),process
simply
to
to
and using
obtain
andobtain
usingcan a
velocity-based
Koopman-based
be seen
velocity-based as identification
qLPVthe model.
identification
applyingqLPV model.extendedtech-
The
tech-
The
et
and al.
extension (2005),
closed-loop of theqLMPCqLMPC
performance shows to
approach have
(Cisneros to comparable
plant
and models
Werner numerical
in
(2017)). input-
An identification
niques simply
identification process
to
process obtain can
can a be seen
velocity-based
be seen as
as applying
applyingqLPV the
model.
the extended
extended The
extension
and closed-loop
closed-loop
extension of the
of theperformance
qLMPC approach
qLMPC approach
(Cisneros to and
to plant
plant models
Werner
models in input-
(2017)).
in input-
An niques Dynamic
identificationsimplyModeprocess to obtain cana be
Decomposition velocity-based
be (eDMD,
seen qLPVthe
Williams
as applying
applying model.
et al. The
(2015))
extended
and
output form was performance
presented in (Cisneros
(Cisneros and
and Werner
Werner, (2017)).
2019). An Dynamic
Dynamic Mode Decomposition (eDMD, Williams et al. (2015))
extension
output
extension
output form
form of
of the
was
the
was qLMPC
presented
qLMPC
presented approach
in (Cisneros
(Cisneros
approach
in to
to plant
plant
and models
and Werner,
Werner,
models in
2019).
in
2019). An identification
input-
input-
An identification
algorithm
Dynamic
Mode
with
Mode
process
process
the can
Decomposition
can be
addition
Decomposition of seen
(eDMD,
seen
recovering
(eDMD,
as Williams
as applyinga qLPV
Williams
the
et
the al.extended
model
et al.
(2015))
extended
at
(2015))the
extension
efficient ofwas
method the presented
qLMPC
for obtaining approachaa qLPV to plant
model models
via invelocity
input- algorithm with
with the addition of
of recovering aa qLPV model at
at the
output
efficient
output
efficient
form
formmethod
methodwas for obtaining
presented
for obtaining in
in (Cisneros
qLPVand
(Cisneros
a qLPV model
and
model
Werner,
Werner,via aaa2019).
via velocity
2019).
velocity
An
An
Dynamic
algorithm
Dynamic
end.
algorithmWe Mode
Mode
presentwith
Decomposition
the
our
the
addition
Decomposition
results
addition both
of
(eDMD,
recovering
(eDMD,
for the
recovering
Williams
case a
qLPV
Williams
when
qLPV
et
the al.
model
et al.
model
(2015))
(2015))
identified
at
the
the
output
algorithm
efficient form is
methodwas
proposed presented
for in
obtaining in (Cisneros
(Cisneros a and
qLPV and
Werner,
modelWerner,
2020).
via 2019).
a velocityAn algorithm
end.
end. WeWe present
presentwith our
the
our results
results both
addition of
both for the
recovering
for as thewellcase
case when
aaasqLPV
when the
model
the identified
at
identified the
algorithm
efficient
algorithm is
methodproposed
is proposed for in (Cisneros
obtaining
in (Cisneros a and
qLPV Werner,
model
and Werner, 2020).
via a velocity algorithm
qLPV model with is the
in addition
state-space of recovering
form, qLPV
for the model
case at
wherethe
efficient
algorithm method
is for obtaining a qLPV model 2020).via a velocity end. end.
qLPV
qLPV We
We present
model
present
model is
is in our
inour results both
state-space
results
state-space both for as
form,
for
form, asthewell
the caseas
case
well when
for
for the
aswhen thecase
the
the identified
where
identified
case where
For scenarios
algorithm
algorithm
For scenarios is proposed
is where
proposed
proposed
where
in
in (Cisneros
first
in
first principles
(Cisneros
(Cisneros
principles
and
and
Werner,
andmodels
Werner,cannot
Werner,
models
2020).
2020).be
2020).
cannot be com-
com-
end.
it
qLPV
it is
is
We
in
in
present
input-output
model
input-output is inour results
form.
state-space
form.
both
We
We
for as
present
form,
present
thewellcase as when
experimental
for
experimental
thecase
the identified
results
results where on
on
For scenarios where first principles models cannot be com- qLPVit
qLPV is in
aa complex model
input-output
model is in state-space
form.
is in state-space
nonlinear MIMO We form,
present
form,
plant as
as- awell
well
Controlas for
experimental the
as forMoment case
the caseresults where
where
Gyro-on
puted
For
puted in
scenarios
in a
a practical
practicalwhere manner,
first
manner, or are
principles
or are otherwise
models
otherwise too
cannot
too complex
be
complex com-for
for it is in
complex input-output
nonlinear form.
MIMO We present
plant - a experimental
Control Moment results Gyro-on
For
puted scenarios
in a practical where first
manner, principles
orofarethe models
otherwise cannot
too complex be com-for it it a is
is in
complex
in input-output
nonlinear
input-output form.
MIMO
form. We
We present
plant
present - a experimental
Control
experimental Moment results
results Gyro-on
on
aFor scenarios
meaningful where
implementationfirst principles models
control cannot
law, be com-
data-driven scope (CMG) - to demonstrate the practicality of the proposed
aputed
aputed in
in aaa practical
meaningful
meaningful
puted in
manner,
implementation
practical manner,
implementation
practical manner,
or ofare
orof
or
theotherwise
control law,
arealternative.
aretheotherwise
control
otherwise
too
too complex
law,
too
data-driven
complex
data-driven
complex
for
for
for aascopecomplex
scope
aapproach.
(CMG)
complex
(CMG)
complex
nonlinear
-- to
nonlinear
nonlinear
By choosing
MIMO plant
to demonstrate
MIMO
demonstrate
MIMOappropriate
plant
the
plant ---observables
aaa Control
Control of
the practicality
practicality
Control of
Moment
of the
Moment
the
Moment
aa the
proposed
proposed
priori
Gyro-
Gyro-
Gyro-
based
techniques
atechniques
meaningful
techniques represent
represent aa promising
implementation promising of the control
alternative. One
law,
One such line
data-driven
such line of
of scope
approach.(CMG) By - to
choosing demonstrate
appropriate the practicality
observables proposed
priori based
a meaningful
meaningful
aresearch, implementation
represent aathis
implementation promising ofisalternative.
of the
the control
control law,
One
law, data-driven
such line
data-driven of scope
approach.
scope
on (CMG)
(CMG)
physical By -- to
insight, to demonstrate
choosing appropriate
demonstrate
we show thatthe
the practicality
observables
practicality
excellent controlof
ofaa the
the proposed
priori
proposed
performance based
techniques
research, relevant
represent
relevant for
for this paper,
promising
paper, is based
based on
alternative.
on the
theOne work
worksuch of
of Koop-
line
Koop- of approach.
on physical By choosing
insight, we appropriate
show that observables
excellent control priori
performance based
techniques
research,
techniques represent
relevant
represent for a promising
this
athis paper,
promising is alternative.
based on
alternative. theOne
One worksuch
such of line
Koop- of
line of on approach.
on physical
approach.
can be achieved By
By choosing
insight,
choosing
with we appropriate
show that
appropriate observables
excellent
observables control a priori
performance
a performance
priori based based
man
man
man (Koopman,
research, relevant
(Koopman,
research, relevant
(Koopman,
1931).
for
1931).
for the
1931). this
These
paper,
These
paper,
These
techniques
is based
based on
techniques
is
techniques
are
arethe
on
are
gaining
work
gaining
the work
gaining
consider-
of
of Koop-
consider-
Koop- on
consider- can physical
be
be achieved
canphysicalachieved insight,
insight, with
with weaaa show
we
relatively
show
relatively
relatively that
small
that excellent
excellent
small
small number
number
number control
control
of
of observables.
observables.
of performance
observables.
research,
able
man attentionrelevant
(Koopman, within for
1931). this paper,
control
These is based
(especially
techniques on
are the
MPC) work
gaining of Koop-
community,
consider- on
can physical
Motivated
be achieved insight,
by the with wea show
ideas behind
relatively thatrecursive
excellent
small number control
least performance
squares
of estima-
observables.
able attention within theThese control (especially MPC) community, can Motivated
be achieved by the
thewith ideas behind
aa relatively recursive
small least
number squares
of estima-
man attention
able
man
evident
able
(Koopman,
(Koopman,
from
attention a 1931).
within
1931).
number
within the
the ofcontrol
Theserecent
control
techniques
(especially
techniques
results
(especially
areMPC)
are
such gaining
gaining
as
MPC) in consider-
community,
consider-
(Korda
community, and Motivated
can
tion be achieved
(Hsia,
Motivated by
1977),
by the ideas
with
applied
ideas behind
relatively
behindto therecursive
small
Dynamic
recursive least
number
least Mode of observables.
squares
Decomposi-
squares estima-
observables.
estima-
evident
able
evident from aawithin
attention
from number
number the ofcontrol
of recent(especially
recent results such
results suchMPC) as in
as in community,
(Korda and
(Korda and Motivatedtion
tion (Hsia,
(Hsia, 1977),
by the
1977), applied
ideas
applied behindto
to the
the Dynamic
recursive
Dynamic least Mode
Mode Decomposi-
squares
Decomposi-estima-
able attention
Mezić,
evident 2018a),
from aawithin theofcontrol
(Abraham
number et al., (especially
2017), MPC)
(Kaiser etcommunity,
al., 2018), Motivated
tion (DMD)
(Hsia, by the ideas
algorithm
1977), applied behind
in (Zhangtherecursive
to the et
Dynamic least
al., 2019) Mode squares
and (Peitz
Decomposi-estima-
and
Mezić,
evident et
Mezić,
evident
(Korda
2018a),
from
2018a),
fromal., 2018),
(Abraham
number
(Abraham
a number (Arbabi of recent
of et al., results
et al.,
recent
recent
et al.,
2017), such
results
2017),
results
2018),
(Kaiser
such
(Kaiser
such
as
as in
as
(Proctor in
et(Korda
inet
et
al., 2018),
(Korda
al.,
(Korda
al.,
and
2018),
and tion
and
2016),
tion (Hsia,
tion
Klus,
(DMD)
(DMD)
(Hsia,
2018),
algorithm
1977),
algorithm
1977),
we applied
applied
propose
in (Zhang
to et
et al.,
to the Dynamic
ina slightly
(Zhang Dynamic
modifiedal., 2019)
2019) Mode
Mode
and
approach
(Peitz
andDecomposi-
(Peitz
Decomposi-
where
and
and
the
Mezić,
(Korda
Mezić,
(Korda 2018a),
et al., 2018),
2018a),
et al., 2018),(Abraham
(Arbabietet
(Abraham
(Arbabi et al.,
etal., 2017),
al.,2017),
al., (Kaiser
2018), (Kaiser
2018), (Proctoretet
(Proctor et al.,
et al., 2018),
al., 2016),
al., 2016), tion
2018), tion
Klus,
Klus, (DMD)
2018),
(DMD)
2018), algorithm
we propose
algorithm
we propose in
in (Zhang
aa slightly
(Zhang
slightly et
modified
et
modifiedal.,
al., 2019)
2019) and
approach
and
approach (Peitz
where
(Peitz
where and
the
and
the
Mezić,
(Hanke
(Korda 2018a),
et
et al.,
al., 2018)
2018),(Abraham
and
(Arbabi et
others.etal.,
A
al., 2017),
survey
2018), (Kaiser
on Koopman
(Proctor et
et al., 2018),
operator
al., 2016), tion
model
Klus, (DMD)
is
2018), updatedalgorithm
we whenever
propose ina (Zhang
novel
slightly et
modifiedal.,
dynamics 2019) are and
approach (Peitz
encountered.
where and
the
(Hanke et
(Korda
(Hanke et al.,
et al., 2018),
al., 2018) and
2018) and
(Arbabi others.
others.et A survey
al.,
A survey
2018), on Koopman
(Proctor
on Koopman et operator
al., 2016),
operator model
Klus,
model is
2018),
is updated
we
updated whenever
propose
whenever a novel
slightly
novel dynamics
modified
dynamics are
approach
are encountered.
where
encountered. the
(Kordacan
theory
(Hanke et
et al.,
be
al., 2018),
found
2018) (Arbabi
in
and (Budišić
others.et al.,
et
A 2018),
al., 2012).
survey (Proctor
on A et al.,
survey
Koopman 2016), model
oriented
operator Klus,
This 2018),
differs
is updated we propose
from
updated the
whenever a slightly
approach of
novel modified
online
dynamics approach
learning where the
presented
are encountered.
encountered. in
theory can
(Hanke can
et be 2018)
al., found andin (Budišić
(Budišić
others. et survey
al., 2012).
2012). A survey
survey operator
oriented model This
This differs
is from
from the approach
whenever of
novel online
dynamics learningare presented
presented in
theory
(Hanke
towards
theory can be
etcontrol
al.,
be found
2018)can
found in
and
be
in others.inA
found
(Budišić et
A al.,
survey
(Kaiser
et al.,
on
et
2012).
Koopman
onal.,A
Koopman
A 2020).
survey oriented
operator
The idea
oriented model
This
differs
is updated
differs from
the
the
approach
whenever
approach
of online
novel
of dynamics
online learning
learningare encountered.
presented
in
in
towardscan
theory
towards control
be
control can in
found
can be (Budišić
be found in
found inet(Kaiser
(Kaiser
al., et al.,
2012).
et al.,A2020).
2020).
survey The idea This differs from the approach of online learning presented in
oriented
The idea
theory can
towards control be
control can found in
can be (Budišić
be found
found in et al.,
in (Kaiser 2012).
(Kaiser et et al.,A survey
al., 2020).
2020). The oriented
The ideaidea This differs from the approach of online learning presented in
towards
towards
2405-8963control
Copyright can©be 2020 found The in (Kaiser
Authors. et isal.,
This an2020). The article
open access idea under the CC BY-NC-ND license.
Peer review under responsibility of International Federation of Automatic Control.
10.1016/j.ifacol.2020.12.1676
Pablo S.G. Cisneros et al. / IFAC PapersOnLine 53-2 (2020) 6062–6068 6063

(Li et al., 2017) where the library of observables is updated Let us stack the observables to obtain Ψ ∈ Hnψ as a map
online. Ψ : Z → Rnψ defined as Ψ(z) = [ψ1 (z) ψ2 (z) · · · ψnψ (z)]T . Note
that the finite dimensional approximation K asymptotically
This paper is organized as follows: Section 2 gives a brief
approaches the exact infinite dimensional operator K as the
overview of the Koopman operator theory. In Section 3 the
dimension nψ of the image space of Ψ approaches infinity by
algorithm for computing an approximate Koopman operator
stacking more and more linearly independent observables (in
is derived. Section 4 presents how to obtain a velocity-based
the sense of the inner product on H) ψi to Ψ (Korda and Mezić,
state space and input-output model, respectively, that can be
2018b).
used in an qLMPC scheme, given an approximate Koopman
operator. Section 5 briefly introduces the qLMPC scheme. Consider equation (4) as a prediction equation for the observ-
Section 6 details the experimental implementation and presents ables. We can, by an appropriate choice of basis functions, ob-
the results of the controller applied to a Control Moment tain an expression for the prediction of the state itself. Recalling
 T
Gyroscope. We end in section 7 with conclusions and outlook. that z = xT uT , define the observable vector
Notation
 T
Ψ(z) = xT uT ψn+m+1 (z) ... ψnψ (z) . (5)
The notation Co(a, b) with a, b ∈ Rn is used to denote the
convex hull obtained from a convex combination of a, b, i.e. Using equation (4), an approximation of the model (1) is given
Co(a, b) = λ a + (1 − λ )b, λ ∈ [0, 1]. The backward time-shift by (Williams et al. (2015))
operator is denoted by q−1 .
 
2. KOOPMAN BASED IDENTIFICATION OF xk
xk+1 ≈ K̂Ψ , (6)
DYNAMICAL SYSTEMS uk
where K̂ = [In 0] K. Note that, as expected, the system dynam-
Consider a system whose dynamics are governed by the
ics are linear in a lifted space spanned by the basis functions.
discrete-time non-linear model
In this way, non-linearities can be captured by an appropriate
xk+1 = f (xk , uk ) (1) choice of Ψ(·). This means that these functions play a cru-
n m n
where xk ∈ R , uk ∈ R and the map f : R × R → R propa-m n
cial role in the accuracy of the approximated model, so their
gates the state forward in time. The discrete-time dynamics can choice must be made with care. We select the basis functions
be embedded in a lifted system by defining a new state zk ∈ Rnz by picking some or all of the nonlinear functions that appear
with nz = n + m as zk = [xkT uTk ]T This new extended system is in the underlying dynamical model, i.e. the R.H.S of (1). Even
defined by though this usually does not lead to an exact finite dimensional
   
xk+1 f (xk , uk ) representation of the Koopman operator, we use a finite dimen-
zk+1 = = = F(zk ) (2) sional approximation and show in experiments that this leads
uk+1 g(xk , uk )
to excellent results. Alternatively, polynomial, Fourier, radial
where F : Rnz → Rnz . or any other standard basis functions could be used, keeping
Remark: As is elaborated in Proctor et al. (2018), g(xk , uk ) in mind that the number of necessary basis functions using
is defined depending on the particular application. We wish these bases might be considerably higher and it may not yield
to discover the dynamics in (1) which is characterized by the satisfactory results.
projected map F̂ : Rnz → Rn defined by F̂ = [I 0]F. The choice
of g(xk , uk ) is therefore irrelevant for our purpose, since we are
not interested in discovering a model of the control law being 3. ONLINE COMPUTATION OF APPROXIMATE
applied. KOOPMAN OPERATORS
Let H denote the infinite dimensional Hilbert space of ob-
servables chosen here as the space of locally square integrable Assume that a data-set Z = {zi , z+
i }i=0,1,···P is collected, where
functions. So, for a compact Z ⊂ Rnz , an element ψ ∈ H is a zi and z+
i are consecutive data points. Note that the data-set Z
map ψ : Z → R. needs not correspond to a single trajectory, i.e. the data pairs
The Koopman operator K : H → H is then defined for the need not be consecutive to one another. The collected data can
dynamical system (1) by the relation be stacked column-wise in data matrices D, D+ ∈ Rnψ ×P as
K(ψ) = ψ ◦ F ∀ψ ∈ H. (3) D = [Ψ(z0 ) Ψ(z1 ) · · · Ψ(zP )], D+ = [Ψ(z+
0 ) Ψ(z1 ) · · · Ψ(zP )]
+ +

We will be interested in the finite dimensional approximation note that D+ is just the time-shifted version of D. The opti-
of the Koopman operator by choosing a finite set of observables mization problem is thus

{ψi }i=1 . With a view on approximating (3), we want to find a 1 +
matrix K ∈ Rnψ ×nψ as an approximation of the the Koopman min ||D − KD||2F (7)
K 2
operator K such that ∀zk ∈ Rnz : 
where ||X||F = Trace(X T X) is the Frobenius norm. The
  K  problem can be solved analytically by solving
ψ1 (zk+1 ) 11 K12 . . . K1nψ  ψ1 (zk ) 
 ψ2 (zk+1 )   KDDT = D+ DT
 
K21 K22 . . . K2nψ    ψ2 (zk ) 
 .
.. 
  .. .. .. ..    ... 
 (4) K = AG†
. . . . 
ψnψ (zk+1 ) Knψ 1 Knψ 2 . . . Knψ nψ ψnψ (zk ) where we have defined (as introduced by Williams et al. (2015))
6064 Pablo S.G. Cisneros et al. / IFAC PapersOnLine 53-2 (2020) 6062–6068

  
1 1 P  K̂Ψ(zk−h−1 )  
G = DDT = ∑ Ψ(z p )Ψ(z p )T 
 




P P p=1  xk−h   K̂Ψ K̂Ψ(zk−h−1 ) 
  u k−h  
xk−h+1   
1 + T 1 P   .  
A= D D = ∑ Ψ(z p+1 )Ψ(z p )T  ..  − ..  ≥ ν (9)
P P p=1 
 . 

  

 xk  K̂Ψ(...) 
 K̂Ψ K̂Ψ uk−2 
 
 uk−1 
3.1 Recursive computation ∞
where  · ∞ is the vector infinity norm 1 . Note that any other
Based on the well known recursive least squares algorithm norm may be used instead, however this choice offers the
(Hsia, 1977), we use an online update similar to the one pro- advantage that it is independent of h and it enables the use of
posed in (Peitz and Klus, 2018). However, an online solution physical insight to determine a suitable ν (i.e. an admissible
of (7) using the definition above would require the storage and error tolerance in physical units).
update of the data vectors D+ , D which could result in mem-
ory management issues. Furthermore, the computation would 4. OBTAINING A QUASI-LPV MODEL FROM
become increasingly demanding with the growing number of KOOPMAN OPERATOR
stored data points P. Alternatively, only G, A and P can be
stored and adding a data point at time step k can be done In the discussion that follows, the Multivariable Mean Value
according to Theorem (MMVT) as formulated in Zemouche et al. (2005), is
used; this result can be regarded as a discrete-time version of
P+ = P + 1 the velocity-based linearization (Leith and Leithead (1998)).
1  
Lemma 1. (Multivariable Mean Value Theorem). Let g : Rn →
G+ = + (P+ − 1)G + Ψ(zk )Ψ(zk )T (8)
P Rq , assume that g is differentiable on Co(a, b), then there exist
1  T
 constant vectors ci ∈ Co(a, b), ci = a, ci = b i = 1, ..., q such
A+ = + (P+ − 1)A + Ψ(z+ k )Ψ(zk )
P that:
where + denotes the updated variables. Using these definitions, q,n
T ∂ gi
the Koopman operator can be updated online with consistent g(a) − g(b) = ∑ eq (i)en ( j) (ci ) (a − b)
i, j=1 ∂xj
and relatively low computational complexity, regardless of the
number of data points that have been added to the data set Z. In where es (i) is the ith column of Is .
comparison to the online update proposed in (Peitz and Klus,
2018), we perform the update step only when the current model Given the approximate dynamic equations with truncated
fails to match with observed data; this is discussed next. Koopman operator (6), using Lemma 1 (assuming the basis
functions are differentiable) yields a velocity-based linearized
dynamic equation:

3.2 Koopman operator update ∂ Ψ

∂ Ψ

∆xk+1 ≈ K̂ ∆x k + K̂ ∆uk
∂x
∂u

x̃,ũ x̃,ũ
Although as seen in the previous section, adding new informa-
where x̃ ∈ Co(xk , xk+1 ), ũ ∈ Co(uk , uk+1 ) which can in practice
tion to the model (in the form of data pairs {zk−1 , zk }) involves
not be computed, therefore an approximation is made so that
only little computational burden, doing so at every time step

is not advisable, as adding e.g. steady-state data-points would ∂ Ψ

∂ Ψ

∆xk+1 ≈ K̂ ∆xk + K̂ ∆uk (10)


result in significant new information having little influence on ∂ x
xk ,uk ∂ u
xk ,uk
updating the model (the weight 1/P of any new data point    
would make the effect negligible for large values of P). For A(ρk ) B(ρk )
this reason, incoming state and input data need to be analyzed where ρ = H[xT uT ]T
and H is a selection matrix. Finally
in some way to determine if they represent new information not (10) is augmented with the (non-incremental) state giving the
included in the model. There are several ways to do this, the dynamic equation
one chosen here is motivated by the one presented in Slavakis       
xk+1 I A(ρk ) xk B(ρk )
and Theodoridis (2008) in the context of kernel based learning ≈ + ∆uk (11)
∆xk+1 0 A(ρk ) ∆xk B(ρk )
with projections. The principle at the core is to ”learn” only if
the current model disagrees (more than a certain threshold) with
the observation. 4.1 Input-Output Koopman-based model

Assume that state and input at the previous h + 1 time instants Even though the goal of this framework is to obtain a data-
are stored in a vector driven model with as little a priori knowledge of the system
 T  as possible, in practice one strong assumption is made, namely
φ = xk−1 uTk−1 ... xk−h−2
T uk−h−2
that the state is known and measurable (given that the state is
a decision whether to add the data pair {zk−1 , zk } to the model part of the observable functions, cf. (5)). This imposition might
is made by comparing the maximum prediction error of the prove prohibitive for high order systems where it is impractical
approximated system (6) within this time window; if this value to assume even knowledge of the number of states, let alone
is greater than a threshold, the data point is added, i.e. add data being able to measure them. In this section we propose to tackle
point if 1 If the states have different physical units, they can be normalized; otherwise

a different bound ν, one for each physical unit can be used


Pablo S.G. Cisneros et al. / IFAC PapersOnLine 53-2 (2020) 6062–6068 6065

this issue using the input-output framework, and a new relaxed qLMPC algorithm [11], or MPC for quasi-LPV systems. This
assumption is made that the order of the system is known. is an algorithm which solves, at each sampling time, typically a
Assume the input-output behavior of the system is given by single quadratic program by  freezing the scheduling trajectory
yk+1 = f˜(yk , uk , q−1 ). (12) Pk = ρkT ρk+1T T
. . . ρk+N−1 to the forward shifted previous one,
essentially turning the quasi-LPV model (11) into a Linear
Note that (12) is a general discrete-time input-output model for Time-Varying (LTV) model. The procedure is shown as Algo-
a system governed by differential-algebraic equations. In this rithm 1
case, a state can be defined by using time-shifted outputs and
inputs as
  Algorithm 1 qLMPC
xk = yTk yTk−1 . . . yk−ny uk−1 . . . uk−nu (13)
Given: plant model, Q̂, R̂, N
where y ∈ Rl and n = ny +nu is the assumed order of the system. 1: k ← 0
This approach is commonly used in the input-output literature 2: Define P0 = 1N ⊗ H[xkT uT T
in order to use Lyapunov-like arguments to establish stability of k−1 ]
3: repeat
input-output models (see e.g. Ali et al. (2010)). Using the state 4: l←0
vector (13), the same definition of the basis functions (5) can 5: repeat
be used and the Koopman operator can equally be computed 6: Solve (18) using Plk to obtain Ukl
recursively via (8). Analogous to Eq.(6), an approximation of
system (12) is given by 7: Predict state sequence given Plk and Ukl
yk+1 = K̂IO Ψ(xk , uk ) (14) 8: Define Pl+1
k = Ĥ(X l ,U l )
9: l ← l +1
where K̂IO = [Il 0]K. A velocity-based model, following the 10: until stop criterion
discussion on the previous section is readily obtained by 11: Apply uk to the system
      
yk+1 I Â(ρk ) yk B̂(ρk ) 12: Define P0k+1 = Ĥ(Xkl ,Ukl )
≈ + ∆uk (15) k ← k+1
∆xk+1 0 A(ρk ) ∆xk B(ρk ) 13:
14: until end
where in contrast to the previously presented state-space for-
mulation (11), the new definitions are used
 
∂ Ψ  ∂ Ψ 
Â(ρk ) = K̂IO B̂(ρk ) = K̂IO .
∂x  xk ,uk ∂u  xk ,uk
6. EXPERIMENTAL RESULT: KOOPMAN-QLMPC FOR A
Remark 1. In the input-output case, the same prediction equa- CONTROL MOMENT GYROSCOPE
tion (11) can be used in order to predict the full state (13).
However, that would entail carrying out pointless computations
to predict future values of backward-shifted inputs and outputs. A Control Moment Gyroscope (CMG) is a mechanical device
which consists of a flywheel mounted on a 3-degree-of-freedom
gimbal. The flywheel and the first gimbal, bodies A and B in
5. PREDICTIVE CONTROLLER
Figure 1, are actuated whereas the two outermost gimbals (C
and D) are not, they can however be controlled by exploiting the
We consider a finite horizon optimal controller which, at each gyroscopic effect. The goal is thus to track reference trajectories
sampling instant k minimizes the cost function for the outer two gimbals, using the torque of the flywheel
N−1 and the torque of the motor actuating the innermost gimbal as
Jk = ∑ (ek+i , ∆uk+i ) + ζ (xk+N ) (16) control variables. The state vector is
i=0
T Tx
where ζ (xk+N ) = xk+N x = [θ2 θ3 θ4 θ̇1 θ̇2 θ̇3 θ̇4 ].
x+N is the terminal cost function, here
chosen quadratic, and the usual stage cost in tracking MPC is where the state of the flywheel’s position, θ1 , is neglected as it
used has no impact on the dynamic behavior of the system, and is
(e, ũ) = eT Qe + ∆uT R∆u (17) furthermore a diverging free integrator (given that the flywheel
with e = x − r representing the deviation of the state from the is perpetually spinning during operation).
reference. The matrices T, Q ∈ Rl×l are positive semi-definite
This plant has strong nonlinear dynamics and a full model is
and R ∈ Rm×m is positive-definite.
considerably complex, see e.g. Hoffmann and Werner (2015),
The optimization problem can thus be defined as making it a good candidate for the Koopman framework. The
min Jk (e, ∆u) CMG used for the experiments presented in this paper is the
u Model 750 from Educational Control Products (ECP).
s.t.
eq.(11)
j−1
(18) 6.1 Selection of basis functions
uk+ j = uk−1 + ∑ ∆uk+i ∈ U j = [0 N − 1]
i=0
Given that a model for the CMG is available, a first meaningful
xk+ j ∈ X j = [0 N − 1] approach is to select a few of the nonlinearities directly from
where U and X are the sets of admissible inputs and states, the equations of motion to be used as basis functions. For
respectively. this, all Coriolis terms (before inverting the inertia matrix) are
considered i.e.
Given a parameter (in this case state/input) dependent state
space model in the form of (11) we can make use of the
6066 Pablo S.G. Cisneros et al. / IFAC PapersOnLine 53-2 (2020) 6062–6068

6.3 Predictive Controller

B A predictive controller according to Algorithm 1, using a model


q3 w1 t 1 in the form of (11) determined as described in Section 5 is used
A
z to control the CMG. For this, a sampling time of Ts = 0.01s is
C used. This sampling time is also used for the sampling/update
y
x
of the Koopman operator, so that both tasks (model up-
date/control) are performed sequentially. For the predictive
t2
q2 controller, a horizon of N = 30 is chosen and the tuning pa-
rameters are Q = diag(1, 120, 120, 0.01, 5, 2, 2, 0, 0, 0, 0, 0, 0, 0),
D T = 10Q, R = diag(3000, 750) and the constraints on the inputs
q4 are |τ1 | < 0.5Nm, |τ2 | < 2Nm.
Closed-loop results are shown in Figures 2 and 3, for the case
Fig. 1. 3-DOF Control Moment Gyroscope plant(left) and its where Ψ1 and Ψ2 are used, respectively. Each plot shows two
CAD model(right)) experiments: one performed starting with the model after the
 training experiment (deemed first iteration), and a second one
Ψ1 = xT uT c2 c3 θ̇2 θ̇4 s2 θ̇2 θ̇3 s2 s3 θ̇3 θ̇4 s2 θ̇1 θ̇3 starting with the model after the first closed-loop experiment
c2 c3 θ̇1 θ̇4 c2 c23 s2 θ̇42 c2 s2 θ̇32 c3 θ̇3 θ̇4 s22 c3 θ̇3 θ̇4 c22 c3 θ̇3 θ̇4 (deemed second iteration), in order to evaluate if performance
improves after each iteration of a repetitive task. As expected, in
s2 s3 θ̇1 θ̇4 s2 θ̇1 θ̇2 c3 θ̇2 θ̇4 s3 c3 θ̇42 c22 c3 θ̇2 θ̇4 s2 c2 θ̇2 θ̇3 (19) both cases this is indeed the case, showing also that the second
s3 c22 c3 θ̇42 c2 c3 θ̇1 θ̇2 s2 s3 θ̇1 θ̇3 s2 s3 c2 θ̇32 s3 c3 θ̇3 θ̇4 experiment needs to add fewer data points to the model, as there
T is less new information.
c22 c3 θ̇2 θ̇3 s2 c2 c23 θ̇2 θ̇4 s3 c22 c3 θ̇3 θ̇4 c3 θ̇2 θ̇3

where the short-hand notations ci = cos(θi ) and si = sin(θi ), 45


i = 2, 3 are used. This yields a truncated Koopman operator of
θ3[°]

dimension K1 ∈ R34×34 , where the subindex is used to denote its 0


correspondence to Ψ1 . In order to explore the potential of the
approach in cases when the nonlinear model is not available, −45
a second set of basis functions is proposed, in which physical 180
intuition is used: as it is expected that the contribution of the
flywheel dominates the other Coriolis terms, only products of 60
θ4[°]

θ̇1 with the rest of the velocities are considered; these products
are then multiplied by trigonometric functions of the angles θ2 −60
and θ3 (since, again from physical intuition it is clear that the
rotations θ1 and θ4 do not have an effect on the dynamics) so −180
that
updated
model


Ψ2 = xT uT c2 θ̇1 θ̇2 c2 θ̇1 θ̇3 c2 θ̇1 θ̇4 c3 θ̇1 θ̇2 c3 θ̇1 θ̇3 20 30 40 50 60 70 80
T
c3 θ̇1 θ̇4 s2 θ̇1 θ̇2 s2 θ̇1 θ̇3 s2 θ̇1 θ̇4 s3 θ̇1 θ̇2 s3 θ̇1 θ̇3 s3 θ̇1 θ̇4 .
Fig. 2. Closed-loop experiment using K1 . Reference ( ),
(20) first iteration ( ), second iteration ( ). The bottom
yielding K2 ∈ R21×21 . plot shows when data is added to the model for both
iterations.
6.2 Computation and update of the Koopman operator Comparing both controllers, the one based on K1 has better per-
formance, particularly regarding cross-coupling at t = 27s and
The Koopman operator is computed recursively using the pro- t = 37s, which is again expected given that the basis functions
cedure described in Section 3. Before starting the predictive more closely resemble the equations of motion. It is however
controller, a short open-loop experiment 2 is performed using worth mentioning that both reference and tuning were selected
chirp test signals to start the Koopman algorithm and give a to encourage an aggressive response as can be seen by the fact
meaningful initial model to the MPC algorithm. For this train- that inputs are driven into saturation (Figure 4); it is therefore
ing experiment, the parameter ν from (9) is set to ν = 0.001 to remarkable that even with relatively simple basis functions,
encourage extracting information from it. When the controller namely Ψ2 , the controller displays exceptional tracking perfor-
is active, the factor is set to ν = 0.0025 to avoid adding too mance.
many data points, which could render the model resistant to
future updates.
6.4 Input-Output Controller
2 Before every experiment, both open- and closed-loop, a PI controller is used
for 15s to bring the flywheel up to speed, with brakes applied on all DOF to Results of the Input-Output version of the presented approach
give an initial condition for the closed-loop experiments of ω1 (15) = 40rad/s, (Section 4.1) are presented next. For this, the output is defined
θi (15), ωi (15) = 0, i = 2, 3, 4. At t = 15s control authority is switched to the as y(k) = [θ2 (k) θ3 (k) θ4 (k) ω1 (k)] where ω1 = θ̇1 , and
proposed controller. the state vector as xk = [yk yk−1 ]. The basis function used are
Pablo S.G. Cisneros et al. / IFAC PapersOnLine 53-2 (2020) 6062–6068 6067

converting it into a qLPV model of typically much lower


45
order via velocity linearization. Furthermore, we propose to
exploit a priori knowledge about the plant when constructing
θ3[°]

0 the observables.

−45
REFERENCES
180
Abraham, I., De La Torre, G., and Murphey, T.D. (2017).
60
θ4[°]

Model-based control using koopman operators. arXiv


−60 preprint arXiv:1709.01568.
Ali, M., Abbas, H., and Werner, H. (2010). Controller synthesis
−180 for input-output LPV models. In 49th IEEE Conference
on Decision and Control (CDC), 7694–7699. doi:10.1109/
updated
model

CDC.2010.5717576.
Arbabi, H., Korda, M., and Mezić, I. (2018). A data-driven
20 30 40 50 60 70 80
koopman model predictive control framework for nonlinear
partial differential equations. In 2018 IEEE Conference on
Fig. 3. Closed-loop experiment using K2 . Reference ( ), Decision and Control (CDC), 6409–6414. IEEE.
first iteration ( ), second iteration ( ). The bottom Budišić, M., Mohr, R., and Mezić, I. (2012). Applied koop-
plot shows when data is added to the model for both manism. Chaos: An Interdisciplinary Journal of Nonlinear
iterations. Science, 22(4), 047510.
Cisneros, P.S.G. and Werner, H. (2017). Parameter-dependent
the discretized version of Ψ2 using finite differences by replac-
stability conditions for quasi-lpv model predictive control. In
ing ω1 (k)θ̇i (k) with [ω1 (k)θi (k) ω1 θi (k − 1)], i = 2, 3 result-
2017 American Control Conference (ACC), 5032–5037. doi:
ing in KIO ∈ R33×33 , clearly a disadvantage of this approach is 10.23919/ACC.2017.7963735.
that it often leads to more basis functions. The tuning matri- Cisneros, P.S.G., Voss, S., and Werner, H. (2016). Efficient non-
ces corresponding to the outputs are discretized so that Q = linear model predictive control via quasi-LPV representation.
diag(1, 120, 120, 0.01, 50000, 20000, 20000, 0, 0, 0, 0, 0) (using 55th IEEE Conference in Decision and Control.
the approximation θ̇ 2 = ∆θ 2 /Ts2 with Ts = 0.01). The result Cisneros, P.S. and Werner, H. (2019). Stabilizing
of the experiment is shown in Figure 5, where compared to Model Predictive Control for Nonlinear Systems
its state-space counterpart in Figure 3 it can be seen that the in Input-Output quasi-LPV form. In American
performance is comparable, with comparatively slower rise- Control Conference, 2019. Philadelphia, PA. Avail-
time but noticeably less cross-coupling. able online: https://www.tuhh.de/t3resources/ics/
Video footage of an experiment can be seen in https: user upload/CiWe19b.pdf.
//youtu.be/rDsuW6lncBY, a comparison with a gain- Cisneros, P.S. and Werner, H. (2020). A velocity algorithm for
scheduled LPV controller in https://youtu.be/4a_ nonlinear model predictive control. IEEE Transactions on
dvWiBX0c. Control Systems Technology.
Diehl, M., Bock, H.G., and Schlöder, J.P. (2005). A real-
7. CONCLUSIONS & OUTLOOK time iteration scheme for nonlinear optimization in optimal
feedback control. SIAM Journal on control and optimization,
A data-driven nonlinear model predictive control approach is 43(5), 1714–1736.
proposed based on the Koopman operator framework. The
model used in the qLMPC algorithm can be updated online 45
with low computational burden. The proposed scheme has been
θ3[°]

validated experimentally on a highly nonlinear MIMO system - 0


a Control Moment Gyroscope with three degrees of freedom
with satisfactory results. In contrast to other approaches in
the literature, the method presented here extends the idea of −45
180
using Koopman operators in conjunction with MPC by not
using the identified linear Koopman model directly, but by 60
θ4[°]

0.5
−60
τ1 [Nm]

0
−180
-0.5
updated
model

2
[Nm]

1
0
τ2

-1 20 30 40 50 60 70 80
-2
20 30 40 50 60 70 80 Fig. 5. Closed-loop experiment using KIO . Reference ( ),
first iteration ( ), second iteration ( ). The bottom
Fig. 4. Control inputs for the first iteration experiment using K1 . plot shows when data is added to the model for both
All experiments look qualitatively the same. iterations.
6068 Pablo S.G. Cisneros et al. / IFAC PapersOnLine 53-2 (2020) 6062–6068

Hanke, S., Peitz, S., Wallscheid, O., Klus, S., Böcker, J., and Williams, M.O., Rowley, C.W., and Kevrekidis, I.G. (2014).
Dellnitz, M. (2018). Koopman operator based finite-set A kernel-based approach to data-driven koopman spectral
model predictive control for electrical drives. arXiv preprint analysis. arXiv preprint arXiv:1411.2260.
arXiv:1804.00854. Zemouche, A., Boutayeb, M., and Bara, G.I. (2005). Observer
Hoffmann, C. and Werner, H. (2015). LFT-LPV modeling design for nonlinear systems: An approach based on the
and control of a control moment gyroscope. In 2015 54th differential mean value theorem. In Proceedings of the 44th
IEEE Conference on Decision and Control (CDC), 5328– IEEE Conference on Decision and Control, 6353–6358.
5333. doi:10.1109/CDC.2015.7403053. Zhang, H., Rowley, C.W., Deem, E.A., and Cattafesta, L.N.
Hsia, T. (1977). System identification: Least-squares methods. (2019). Online dynamic mode decomposition for time-
Lexington, Mass.: Lexington Books. varying systems. SIAM Journal on Applied Dynamical
Kadali, R., Huang, B., and Rossiter, A. (2001). A data driven Systems, 18(3), 1586–1609.
subspace approach to predictive controller design. IFAC Pro-
ceedings Volumes, 34(25), 365 – 370. 6th IFAC Symposium
on Dynamics and Control of Process Systems 2001, Jejudo
Island, Korea, 4-6 June 2001.
Kaiser, E., Kutz, J.N., and Brunton, S.L. (2018). Sparse
identification of nonlinear dynamics for model predictive
control in the low-data limit. Proceedings of the Royal
Society A, 474(2219), 20180335.
Kaiser, E., Kutz, J.N., and Brunton, S.L. (2020). Data-driven
approximations of dynamical systems operators for control.
In The Koopman Operator in Systems and Control, 197–234.
Springer.
Koopman, B.O. (1931). Hamiltonian systems and transforma-
tion in hilbert space. Proceedings of the National Academy
of Sciences, 17(5), 315–318.
Korda, M. and Mezić, I. (2018a). Linear predictors for non-
linear dynamical systems: Koopman operator meets model
predictive control. Automatica, 93, 149–160.
Korda, M. and Mezić, I. (2018b). On convergence of ex-
tended dynamic mode decomposition to the koopman opera-
tor. Journal of Nonlinear Science, 28(2), 687–710.
Korda, M., Susuki, Y., and Mezić, I. (2018). Power grid tran-
sient stabilization using koopman model predictive control.
IFAC-PapersOnLine, 51(28), 297–302.
Leith, D.J. and Leithead, W.E. (1998). Gain-scheduled and
nonlinear systems: dynamic analysis by velocity-based lin-
earization families. International Journal of Control, 70(2),
289–317.
Li, Q., Dietrich, F., Bollt, E.M., and Kevrekidis, I.G. (2017).
Extended dynamic mode decomposition with dictionary
learning: A data-driven adaptive spectral decomposition of
the koopman operator. Chaos: An Interdisciplinary Journal
of Nonlinear Science, 27(10), 103111.
Peitz, S. and Klus, S. (2018). Feedback control of nonlinear
pdes using data-efficient reduced order models based on the
koopman operator. arXiv preprint arXiv:1806.09898.
Proctor, J.L., Brunton, S.L., and Kutz, J.N. (2016). Dynamic
mode decomposition with control. SIAM Journal on Applied
Dynamical Systems, 15(1), 142–161.
Proctor, J.L., Brunton, S.L., and Kutz, J.N. (2018). Generaliz-
ing koopman theory to allow for inputs and control. SIAM
Journal on Applied Dynamical Systems, 17(1), 909–930.
Slavakis, K. and Theodoridis, S. (2008). Sliding window gen-
eralized kernel affine projection algorithm using projection
mappings. EURASIP Journal on Advances in Signal Pro-
cessing, 2008(1), 735351. doi:10.1155/2008/735351. URL
https://doi.org/10.1155/2008/735351.
Williams, M.O., Kevrekidis, I.G., and Rowley, C.W. (2015).
A data–driven approximation of the koopman operator: Ex-
tending dynamic mode decomposition. Journal of Nonlinear
Science, 25(6), 1307–1346.

You might also like