# Time-Series Forecasting for Out-of-Distribution Generalization
Using Invariant Learning

Haoxin Liu  Harshavardhan Kamarthi  Lingkai Kong  Zhiyuan Zhao  Chao Zhang  B.
Aditya Prakash

###### Abstract

Time-series forecasting (TSF) finds broad applications in real-world
scenarios. Due to the dynamic nature of time-series data, it is crucial to
equip TSF models with out-of-distribution (OOD) generalization abilities, as
historical training data and future test data can have different
distributions. In this paper, we aim to alleviate the inherent OOD problem in
TSF via invariant learning. We identify fundamental challenges of invariant
learning for TSF. First, the target variables in TSF may not be sufficiently
determined by the input due to unobserved core variables in TSF, breaking the
conventional assumption of invariant learning. Second, time-series datasets
lack adequate environment labels, while existing environmental inference
methods are not suitable for TSF.

To address these challenges, we propose FOIL, a model-agnostic framework that
enables time-series Forecasting for Out-of-distribution generalization via
Invariant Learning. FOIL employs a novel surrogate loss to mitigate the impact
of unobserved variables. Further, FOIL implements a joint optimization by
alternately inferring environments effectively with a multi-head network while
preserving the temporal adjacency structure, and learning invariant
representations across inferred environments for OOD generalized TSF. We
demonstrate that the proposed FOIL significantly improves the performance of
various TSF models, achieving gains of up to 85%.

Machine Learning, ICML

##  1 Introduction

Time-series (TS) data are ubiquitous across various domains, including public
health (Kamarthi et al., 2021b; Rodriguez et al., 2021), finance (Sezer et
al., 2020), and urban computing (Tabassum et al., 2021). Time-series
forecasting (TSF), a foundational task in analyzing TS data, involving
predicting future events or trends based on historical TS data, has received a
longstanding research focus. TSF faces certain challenges due to the dynamic
and complex nature of TS data: First, distributions of TS data change over
time. Second, the inherent complexity of TSF is compounded by unforeseen
exogenous factors, such as policy interventions and climate changes in the
context of influenza forecasting.

Given the dynamic nature of TS data, where unforeseen distribution shifts can
occur between historical training and future testing data, the TSF task asks
for robust out-of-distribution (OOD) generalization abilities. Instead,
existing TSF models employ empirical risk minimization to greedily incorporate
all correlations within the data to minimize average training errors. However,
as not all correlations persist in unknown test distributions, these models
may lack OOD generalization abilities. Note that existing works on temporal
distribution shifts (Du et al., 2021; Kim et al., 2021; Liu et al., 2022; Fan
et al., 2023) merely focus on mitigating the marginal distribution shifts of
the input. These methods are not generalizable enough for the OOD problem,
which consists of various types of distribution shifts (Liu et al., 2021c),
such as conditional distribution shifts, etc.

In this paper, we propose to alleviate the OOD generalization problem of TSF
via invariant learning (IL). IL seeks to identify and utilize invariant
features that maintain stable relationships with targets across different
environments while discarding unstable correlations introduced by variant
features. Although IL has witnessed wide theoretical and empirical success in
various domains (Koyama & Yamaguchi, 2020; Ye et al., 2023; Weber et al.,
2022), it remains unexplored yet non-trivial to apply IL for TSF because of
the following challenges: First, TS data breaks IL’s conventional assumption.
In TS data, there are always variables that directly affect targets but remain
unobserved, such as the outbreak of an epidemic, sudden temperature changes,
policy adjustments, etc. IL fails to consider these unobserved core variables,
leading to poor OOD generalization in TSF. Second, TS data are usually
collected without explicit environment labels. Although some general IL with
environment inference methods have been proposed, their neglect of TS data
characteristics results in suboptimal inferred time-series environments.

Thus, we propose a novel TSF approach for out-of-distribution generalization,
namely FOIL (Forecasting for Out-of-distribution TS generalization via
Invariant Learning). Our contributions are summarized as follows:

  * •

We investigate the out-of-distribution generalization problem of time-series
forecasting. To the best of our knowledge, we are the first to introduce
invariant learning to TSF and identify two essential gaps, including the non-
compliance of IL’s conventional assumption and the lack of environment labels.

  * •

We propose FOIL, a practical and model-agnostic invariant learning framework
for TSF. FOIL leverages a simple surrogate loss to ensure the applicability of
IL and designs an efficient environment inference module tailored for time-
series data.

  * •

We conduct extensive experiments on diverse datasets along with three advanced
forecasting models (‘backbones’). FOIL proves effectiveness by uniformly
outperforming all baselines in better forecasting accuracy.

##  2 Preliminaries and Problem Definition

We formally introduce the TSF task and discuss why it is an OOD generalization
problem. We then introduce the problem OOD-TSF, formulating TSF as an OOD
problem.

We denote slanted upper-cased letters such as $\bm{X}$ as random variables and
calligraphic font letters $\mathcal{X}$ as its sample space. Upright bold
upper-cased letters such as $\mathbf{X}$, bold lower-cased letters such as
$\bm{x}$ and regular lower-cased letters such as $x$ denote deterministic
matrices, vectors and scalars, respectively.

###  2.1 Time-Series Forecasting: An Out-of-Distribution Generalization View

TSF models take a time series as input and output future values of some or all
of its features. Let the input time-series variable be denoted as
$\bm{X}\in\mathbb{R}^{l\times d_{\mathrm{in}}}$, where $l$ is the length of
the lookback window decided by domain experts and $d_{\mathrm{in}}$ is the
feature dimension at each time step. The output variable of the forecasts
generated of horizon window length $h$ is denoted as
$\bm{Y}\in\mathbb{R}^{h\times d_{\mathrm{out}}}$, where $d_{\mathrm{out}}$ is
the dimension of targets at each time step. For the sample at time step $t$,
denoted as $(\mathbf{X}_{t},\mathbf{Y}_{t})$,
$\mathbf{X}_{t}\in\bm{X}=\left[\mathbf{x}_{t-l+1},\mathbf{x}_{t-l+2},\ldots,\mathbf{x}_{t}\right]$
and
$\mathbf{Y}_{t}\in\bm{Y}=\left[\mathbf{y}_{t+1},\mathbf{y}_{t+2},\ldots,\mathbf{y}_{t+h}\right]$.
Thus, the TSF model parameterized by $\theta$ is denoted as
$f_{\theta}:\mathcal{X}\rightarrow\mathcal{Y}$.

In this paper, we focus on univariate forecasting with covariates, i.e.,
$d_{\text{out}}=1$ and $d_{\text{in}}\geq 1$, but our method can be easily
generalized to the multivariate forecasting setting by using multiple
univariate forecasting (Gruver et al., 2023; Lim & Zohren, 2021).

Existing TSF models usually assume the training distribution is the same as
the test distribution and use empirical risk minimization (ERM) for model
training. However, training and test sets of TSF represent historical and
future data, respectively. Given the dynamic nature of time series, the test
distribution may diverge from the training distribution. In this paper, we
consider TSF under the more realistic situation where
$P^{\mathrm{train}}(\boldsymbol{X},\boldsymbol{Y})\neq
P^{\mathrm{test}}(\boldsymbol{X},\boldsymbol{Y})$, i.e., unknown
$P^{\mathrm{test}}(\boldsymbol{X},\boldsymbol{Y})$, which can be defined as
follows:

######  Problem 1.

Out-of-Distribution Generalization for Time-Series Forecasting (OOD-TSF):
Given a time-series training dataset
$\mathcal{D}^{\mathrm{train}}=\\{(\mathbf{X}_{t},\mathbf{Y}_{t})\\}_{t=1}^{T}$,
the task is to learn an out-of-distribution generalized forecasting model
$f_{\theta}^{*}:\mathcal{X}\rightarrow\mathcal{Y}$ parameterized by $\theta$
which achieves minimum error on testing set
$\mathbf{\mathcal{D}}^{\mathrm{test}}$ with unknown distribution
$P^{\mathrm{test}}(\bm{X},\bm{Y})$.

###  2.2 Invariant Learning: Out-of-Distribution Generalization with
Environments

Environment Labels. Invariant learning (IL), backed by the invariance
principle (Arjovsky et al., 2019) from causality, is a popular solution for
OOD generalization. IL assumes heterogeneity in observed data: dataset is
collected from multiple environments, formulated as
$\mathbf{\mathcal{D}}=\cup_{e}\mathbf{\mathcal{D}}^{e}=\cup_{e}\\{(\mathbf{X}^{e}_{i},\mathbf{Y}^{e}_{i})\\}_{i=1}^{|\mathbf{\mathcal{D}}^{e}|}$;
each environment $e$ has a distinct distribution
$P^{e}(\boldsymbol{X},\boldsymbol{Y})$, termed heterogeneous environments. In
time-series data, temporal environments can be seasons, temperatures,
policies, etc. Let $\mathrm{supp}(\bm{E})$ denote all environments, the
objective function is formulated as:

$\bm{\mathcal{R}}_{\mathrm{IL}}(f_{\theta})=\max_{e\in\mathrm{supp}(\bm{E})}\mathbb{E}_{P(\bm{X},\bm{Y}|e)}\left[\ell(f_{\theta}(\mathbf{X}),\mathbf{Y}))|e\right],$
(1)

where OOD generalization is achieved by minimizing the empirical risk under
the worst-performing environment.

Invariant Features. To optimize Eq. 1, IL proposes to identify and utilize
invariant features that maintain stable relationships with target variables
across different environments. For instance, in forecasting the number of flu
cases, temperature changes belong to invariant features (Mourtzoukou &
Falagas, 2007; Mäkinen et al., 2009), while hospital records are variant
features since the proportion of influenza cases over all records may vary
across different seasons.

Sufficiency and Invariance Assumption. Most IL methods are proposed based on
the following conventional assumption (Gong et al., 2016; Rojas-Carulla et
al., 2018; Chang et al., 2020; Arjovsky et al., 2019; Liu et al., 2021a; Lin
et al., 2022):

######  Assumption 2.1 (Conventional Assumption of Invariant Learning).

The input features $\bm{X}$ is a mixture of invariant features
$\bm{X}_{\mathrm{I}}$ and variant features $\bm{X}_{\mathrm{V}}$.
$\bm{X}_{\mathrm{I}}$ possesses the following properties:

  * a.

Sufficiency property: $\bm{Y}=g(\bm{X}_{\mathrm{I}})+\epsilon,$ where
$g(\cdot)$ can be any mapping function, and $\epsilon$ is random noise.

  * b.

Invariance property: for all $e_{i},e_{j}\in\mathrm{supp}(\bm{E})$, we have
$P^{e_{i}}(\bm{Y}|\bm{X}_{\mathrm{I}})=P^{e_{j}}(\bm{Y}|\bm{X}_{\mathrm{I}})$
holds.

Thus, $\bm{X}_{\mathrm{I}}$ is assumed to provide sufficient and invariant
predictive power for $\bm{Y}$ and is theoretically proven to guarantee optimal
OOD performance for Eq. 1 (Liu et al., 2021a).

To better understand the above, we employ the structural causal model (SCM)
(Pearl et al., 2000) shown in Figure LABEL:fig:CG_A. We define invariant
features $\bm{X}_{\mathrm{I}}$ as the subset of input features $\bm{X}$ that
directly cause $\bm{Y}$, following (Arjovsky et al., 2019; Peters et al.,
2016; Lin et al., 2022). Environment $\bm{E}$ can be interpreted as the
confounder between $\bm{X}_{\mathrm{I}}$ and $\bm{X}_{\mathrm{V}}$.
Specifically, the correlation between $\bm{X}_{\mathrm{V}}$ and $\bm{Y}$ is
spurious, mediated through
$\bm{X}_{\mathrm{V}}\leftarrow\bm{E}\rightarrow\bm{X}_{\mathrm{I}}\rightarrow\bm{Y}$.
Conversely, the causal relationship $\bm{X}_{\mathrm{I}}\rightarrow\bm{Y}$ is
invariant. Generally, IL aims to achieve OOD generalization using such
$\bm{X}_{\mathrm{I}}$ to predict $\bm{Y}$.

##  3 Challenges

Considering the theoretical and empirical successes of invariant learning
(Arjovsky et al., 2019; Koyama & Yamaguchi, 2020; Krueger et al., 2021; Ye et
al., 2023), a natural question arises: Can we directly apply invariant
learning (IL) to OOD-TSF? Unfortunately, there are two main reasons rendering
a direct application problematic. Firstly, the existence of unobserved
variables in time-series (TS) data breaks the conventional Assumption 2.1 of
IL. Secondly, TS datasets usually lack adequate environment labels.

TS data break IL’s conventional assumption. Recall Assumption 2.1, where
invariant features $\bm{X}_{\mathrm{I}}$ are assumed to provide sufficient and
invariant predictive power for $\bm{Y}$ in IL. However, in TSF tasks, there
are always variables that directly affect $\bm{Y}$ but are not included in the
input features $\bm{X}$, such as the outbreak of a novel epidemic, sudden
temperature changes, policy adjustments, etc. These unobserved core variables,
denoted as $\bm{Z}$, exist due to their absence from the whole dataset or the
lookback window.

In the SCM shown in Figure LABEL:fig:CG_A, we use $\bm{Z}\rightarrow\bm{Y}$
and the dash circle to describe the core effect of $\bm{Z}$ on $\bm{Y}$ and
the unobserved issue of $\bm{Z}$ respectively. Clearly, there exists a gap
between the SCM modeled by the existing IL methods and the SCM underlying TS
data , due to the existence of $\bm{Z}$.

The existence of unobserved $\bm{Z}$ breaks both two parts of the IL’s
conventional assumption 2.1: First, $\bm{Z}$ breaks the sufficiency property
part, obviously. Thus, existing IL methods actually absorb the influence of
$\bm{Z}$ on $\bm{Y}$, leading to the overfitting issue, especially with deep
models. Second, $\bm{Z}$ breaks the invariance property part when $\bm{Z}$ and
$\bm{E}$ are not independent, for example, influenza outbreaks occur more
frequently in winter. Formally, if there exists
$e_{i},e_{j}\in\mathrm{supp}(\bm{E})$ such that
$P^{e_{i}}(\bm{Z}|\bm{X}_{\mathrm{I}})\neq
P^{e_{j}}(\bm{Z}|\bm{X}_{\mathrm{I}})$, then we have
$P^{e_{i}}(\bm{Y}|\bm{X}_{\mathrm{I}})=\sum_{\mathbf{Z}}P(\bm{Y}|\bm{X}_{\mathrm{I}},\mathbf{Z})P^{e_{i}}(\mathbf{Z}|\bm{X}_{\mathrm{I}})\neq
P^{e_{j}}(\bm{Y}|\bm{X}_{\mathrm{I}})$. Thus, existing IL methods lacks
reliable OOD generalization ability for TSF.

TS datasets usually lack environment labels. Firstly, most IL methods
(Arjovsky et al., 2019; Ahuja et al., 2021; Krueger et al., 2021; Pezeshki et
al., 2021; Sagawa et al., 2019) require explicit environment labels as input,
which are often unavailable in TSF datasets. Due to the complexity of temporal
environments, manual annotation is often difficult, expensive, and sometimes
suboptimal. Secondly, existing IL with environment inference methods are
fundamentally not applicable for TSF: (1) Existing IL methods show certain
limitations when applying to TSF tasks: HRM (Liu et al., 2021a) and KernelHRM
(Liu et al., 2021b) are based on low-dimensional raw features, while TS data
are typically high-dimensional; EIIL (Creager et al., 2021) needs delicate
initialization; ZIN (Lin et al., 2022) requires additional information
satisfying specific conditions; and EDNIL (Huang et al., 2022) is designed for
classification tasks. (2) Existing IL methods primarily cater to static data
and thus overlook the characteristics of time-series data, leading to
suboptimal inferred environments.

##  4 Our Methodology

We propose FOIL (Forcasting for-Out-of-distribution generalization via
Invariant Learning), a model-agnostic environment-aware invariant learning
framework, serving as a practical solution for the OOD-TSF problem.

###  4.1 Overview

High-level Idea. Our main idea is to use IL with environment inference
targeting at the sufficiently predictable part of the target (we call it
$\bm{Y}^{\text{suf}}$), see Figure LABEL:fig:CG_B. Specifically, inspired by
the Wold’s decomposition theorem (Anderson, 2011; Nerlove et al., 2014), we
assume that $\bm{Y}$ can be decomposed into deterministic and uncertain parts
relative to the input $\bm{X}$. Formally,
$\bm{Y}=q(\bm{Y}^{\text{suf}},\bm{Z})$, with $q(\cdot,\cdot)$ as any mapping
function. Here, $\bm{Y}^{\text{suf}}\in\mathcal{Y}$, determined by the input
$\bm{X}$, is deterministic, i.e., sufficiently predictable. Thus, targeting at
$\bm{Y}^{\text{suf}}$, the Assumption 2.1 of sufficiency and invariance
property holds, making invariant learning feasible. Additionally, considering
the unpredictability of unobserved $\bm{Z}$, the optimal OOD prediction can be
achieved if we are able to uncover $\bm{Y}^{\text{suf}}$ via invariant
features $\bm{X}_{\mathrm{I}}$. To this end, we propose FOIL, which serves as
a practical solution for applying IL to the OOD-TSF problem.

Overall Framework. As shown in Figure 2, FOIL consists of three parts:

(1) Label Decomposing Component ($\bm{\mathcal{C}}_{\mathrm{LD}}$), which
decomposes sufficiently predictable $\bm{Y}^{\text{suf}}$ from observed
$\bm{Y}$.

(2) Time-Series Environment Inference Module
($\bm{\mathcal{M}}_{\mathrm{TEI}}$), which infers temporal environments based
on learned representations from $\bm{\mathcal{M}}_{\mathrm{TIL}}$.

(3) Time-Series Invariant Learning Module ($\bm{\mathcal{M}}_{\mathrm{TIL}}$),
which learns invariant representations across inferred environments from
$\bm{\mathcal{M}}_{\mathrm{TEI}}$.

In FOIL, $\bm{\mathcal{C}}_{\mathrm{LD}}$ is the preliminary step for
$\bm{\mathcal{M}}_{\mathrm{TIL}}$ and $\bm{\mathcal{M}}_{\mathrm{TEI}}$;
$\bm{\mathcal{M}}_{\mathrm{TIL}}$ and $\bm{\mathcal{M}}_{\mathrm{TEI}}$ are
then jointly optimized via alternating updates. During the testing phase, only
$\bm{\mathcal{M}}_{\mathrm{TIL}}$ is utilized for prediction.

As the first work of IL for TSF, FOIL is designed as a model-agnostic
framework that seamlessly incorporates various off-the-shelf deep TSF models.
Specifically, the backbone model can be any deep TSF model, denoted
$\phi(\boldsymbol{X})$. We append a regressor $\rho(\cdot)$, typically a fully
connected layer, on top of the learned output representations from the
backbone model $\phi(\cdot)$. We denote the combined model succinctly as as
$f_{\theta}(\bm{X})=\rho\left(\phi(\boldsymbol{X})\right)$.
$\bm{\mathcal{M}}_{\mathrm{TIL}}$ and $\bm{\mathcal{M}}_{\mathrm{TEI}}$
leverage the output representation $\phi(\boldsymbol{X})$, both for achieving
model-agnostic and for accommodating high-dimensional inputs of TSF. We will
next introduce each part.

Figure 2: The overall framework of our proposed FOIL.

###  4.2 The Label Decomposing Component

$\bm{\mathcal{C}}_{\mathrm{LD}}$ is used to decompose the sufficiently
predictable $\bm{Y}^{\text{suf}}$ from the observed $\bm{Y}$. However,
accurately obtaining $\bm{Y}^{\text{suf}}$ is nearly unfeasible, owing to the
lack of information about the underlying generation function and unobserved
variables $\bm{Z}$. Instead of introducing additional data, such as external
datasets as the agent for $\bm{Z}$, we aim to alleviate this problem more
practically via a surrogate loss to mitigate the effect of $\bm{Z}$. Firstly,
we add the following assumption:

$\bm{Y}=q(\bm{Y}^{\text{suf}},\bm{Z})=\alpha(\bm{Z})(\bm{Y}^{\text{suf}})+\beta(\bm{Z})\mathbf{1},$
(2)

where $\alpha(\cdot):\mathbb{R}^{d_{Z}}\to\mathbb{R}$ and
$\beta(\cdot):\mathbb{R}^{d_{Z}}\to\mathbb{R}$ could be any mapping function,
and $\mathbf{1}\in\mathbb{R}^{h\times d_{\mathrm{out}}}$ is an all-one matrix.
This assumption follows the dynamic nature of observed $\bm{Y}$’s distribution
(Cheng et al., 2015). Specifically, this assumption encompasses two aspects:

(1) The relationships between $\bm{Z}$ and $\bm{Y}^{\text{suf}}$ are additive
and multiplicative, which is a widely adopted assumption about unobserved
variables (Hoyer et al., 2008; Maeda & Shimizu, 2021; Sancho et al., 1982;
Wooldridge, 1997). (2) $\bm{Z}$ exerts a consistent influence in one horizon
window, which can be readily extended by partitioning the horizon window into
multiple segments. Thus, the residual $\bm{Res}$ between ground truth $\bm{Y}$
and predicted $\hat{\bm{Y}}$, i.e., $\bm{Res}=\bm{Y}-\hat{\bm{Y}}$, absorb the
effect of $\bm{Z}$ on $\bm{Y}$ via values of mean $\mu(\bm{Res})$ and standard
deviation $\sigma(\bm{Res})$. Thus, we propose an Instance Residual
Normalization (IRN) method to mitigate the effect of $\bm{Z}$. For the
residual $\bm{Res}_{t}$ of instance $t$, IRN method can be formulated as:

$\tilde{\mathbf{Res}}_{t}=\frac{\mathbf{Y}_{t}-\mu\left(\mathbf{Y}_{t}\right)}{\sigma(\mathbf{Y}_{t})}-\frac{\hat{\mathbf{Y}}_{t}-\mu\left(\hat{\mathbf{Y}}_{t}\right)}{\sigma(\hat{\mathbf{Y}}_{t})}=\tilde{\mathbf{Y}}_{t}-\tilde{\hat{\mathbf{Y}}}_{t}$
(3)

IRN in Eq. 3 ensures the residuals to have a mean of 0 and a variance of
$2-2\mathrm{cov}(\hat{\mathbf{Y}},\mathbf{Y})$, where $\mathrm{cov}$ denotes
the covariance.

Finally, we derive the following simple and effective surrogate loss to
mitigate the effect of $\bm{Z}$, instead of directly decoupling
$\bm{Y}^{\text{suf}}$ in $\bm{\mathcal{C}}_{\mathrm{LD}}$:

$\ell_{\text{suf}}(\hat{\bm{Y}},\bm{Y})=\mathrm{MSE}(\tilde{\bm{Res}},\bm{0})=\ell(\tilde{\hat{\bm{Y}}},\tilde{\bm{Y}}),$
(4)

where
$\mathrm{MSE}(\tilde{\bm{Res}},\bm{0})=\frac{1}{h}\sum_{j=1}^{h}(\tilde{\mathbf{Res}}_{t+j})^{2}$.
Note that our IRN fundamentally differs from the existing instance
normalization (IN) methods. Existing methods adopt IN to $\bm{X}$, and reverse
IN to $\hat{\bm{Y}}$ based on $\mu(\bm{X})$ and $\sigma(\bm{X})$, aiming to
address non-stationary problem of $\bm{X}$ (Kim et al., 2021; Liu et al.,
2022). While, our IRN method directly aligns the mean and variance between
$\hat{\bm{Y}}=f(\bm{X})$ and $\bm{Y}$, thus removing error caused by $\bm{Z}$
under the introduced assumption. Since $\bm{Z}$ is not contained in $\bm{X}$,
existing methods usually fail to achieve our goal.

###  4.3 The Time-Series Environment Inference Module

$\bm{\mathcal{M}}_{\mathrm{TEI}}$ aims to infer environments
$\bm{E}_{\mathrm{infer}}$, thereby providing environment labels for the time-
series invariant learning module $\bm{\mathcal{M}}_{\mathrm{TIL}}$. We
consider inferring effective and reasonable temporal environments with two
goals:

(1) Sensitive to the encoded invariant features. In FOIL,
$\bm{\mathcal{M}}_{\mathrm{TEI}}$ and $\bm{\mathcal{M}}_{\mathrm{TIL}}$ are
adversarial: $\bm{\mathcal{M}}_{\mathrm{TEI}}$ infers environments based on
the variant features not discarded by $\bm{\mathcal{M}}_{\mathrm{TIL}}$;
$\bm{\mathcal{M}}_{\mathrm{TIL}}$ discards variant features based on inferred
environments from $\bm{\mathcal{M}}_{\mathrm{TEI}}$. Ultimately, when
$\bm{\mathcal{M}}_{\mathrm{TIL}}$ only utilizes invariant features,
$\bm{\mathcal{M}}_{\mathrm{TEI}}$ is unable to infer effective environments.
Thus, we propose to infer informative environments that are sensitive to the
variant features encoded in the currently learned representations, formulated
as:

$\min_{\bm{E}_{\mathrm{infer}}}H\left(\bm{Y}^{\text{suf}}|\phi^{*}(\bm{X}),\bm{E}_{\mathrm{infer}}\right)-H\left(\bm{Y}^{\text{suf}}|\phi^{*}(\bm{X})\right),$
(5)

where $H$ is Shannon conditional entropy, $\phi^{*}(\bm{X})$ are learned
representations from $\bm{\mathcal{M}}_{\mathrm{TIL}}$ and frozen in
$\bm{\mathcal{M}}_{\mathrm{TEI}}$.

(2) Preserving the temporal adjacency structures. To ensure that the inferred
environments are reasonable in the context of TSF, we consider preserving the
inherent characteristic of time-series data, i.e., the temporal adjacency
structure. Specifically, instances that are temporally adjacent should possess
similar temporal environments. This can also be viewed as a type of
regularization to prevent inferred environments from overfitting to random
noises.

Intuitively, the approach to infer environments is to optimize Eq. 5, with a
plugin for preserving the temporal adjacency structure. To this end, we
present an EM-based clustering solution in the representation space,
implemented through a multi-head neural network. Each head is an environment-
specific regressor, playing the role of each cluster’s center. Specifically,
the regressor $\rho^{(e)}$ is specific for environment $e$. And the
representation $\phi^{*}(\bm{X})$ is shared and frozen in
$\bm{\mathcal{M}}_{\mathrm{TEI}}$. We describe the M step and E step next.

#### M Step: Optimizing Environment-Specific Regressors

In the M step, we optimize $\\{\rho^{(e)}\\}$ to better fit the data from
current environment partition $\bm{E}_{\mathrm{infer}}$ of E step as:

$\displaystyle\min_{\\{\rho^{(e)}\\}}\bm{\mathcal{L}}_{\mathrm{TEI}}=\mathbb{E}_{e\in\bm{E}_{\mathrm{infer}}}\bm{\mathcal{R}}^{(e)}_{\mathrm{suf}}(\rho^{(e)},\phi^{*})$
(6)
$\displaystyle=\sum_{e\in\bm{E}_{\mathrm{infer}}}\frac{1}{|\mathcal{D}_{e}|}\sum_{(\mathbf{X},\mathbf{Y})\in\mathcal{D}_{e}}\ell_{\text{suf}}\left(\rho^{(e)}\left(\phi^{*}(\mathbf{X})\right),\mathbf{Y}\right)$

#### E Step: Estimating Environment Labels

Next, in the E step, we reallocate the environment partitions. For instance
$(\mathbf{X}_{t},\mathbf{Y}_{t})$, we reassign its environment label
$\bm{E}_{\mathrm{infer}}(t)$ via the following two steps:

  * •

Step 1: Reallocating based on the distances with the center of each cluster
(environment). We use the loss with respect to regressor $\rho^{(e)}$ to
describe the distance with the center of cluster $e$. Thus, we reassign
$\bm{E}_{\mathrm{infer}}(t)$ according to the shortest distance, as follows:

$\bm{E}_{\mathrm{infer}}(t)\leftarrow\arg\underset{e\in\bm{E}_{\mathrm{infer}}}{\min}\left\\{\ell_{\text{suf}}\left(\rho^{(e)}\left(\phi^{*}(\mathbf{X}_{t})\right),\mathbf{Y}_{t}\right)\right\\}$
(7)

  * •

Step 2: Reallocating to preserve temporal adjacency structure. We propose an
environment label propagation solution to achieve this goal, as follows:

$\bm{E}_{\mathrm{infer}}(t)\leftarrow\mathrm{mode}\left\\{\bm{E}_{\mathrm{infer}}(t+j)\right\\}_{j=-r}^{r},$
(8)

where mode implements majority voting by considered temporal neighbors
selected via the radius $r\in\mathbb{Z}^{+}$.

In summary, we iteratively execute M step and E step to obtain the inferred
environments $\bm{E}^{*}_{\mathrm{infer}}$. Due to the fixed second term of
Eq. 5, our solution represents a practical instantiation of Eq. 5.

###  4.4 The Time-Series Invariant Learning Module

$\bm{\mathcal{M}}_{\mathrm{TIL}}$ is used to learn invariant representations
$\phi^{*}(\bm{X})$ across inferred environments
$\bm{E}^{*}_{\mathrm{{infer}}}$ from $\bm{\mathcal{M}}_{\mathrm{TEI}}$.
Specifically, $\bm{\mathcal{M}}_{\mathrm{TIL}}$ aims to learn the
$\phi^{*}({\bm{X}})$ which encode and solely encode all the information of
invariant features $\bm{X}_{\mathrm{I}}$ thus achieving both invariant and
sufficient predictive capability targeting at $\bm{Y}^{\text{suf}}$. Such
$\phi^{*}(X)$ has been theoretically proven (Liu et al., 2021a) to be obtained
by optimizing the following objective function:

$\phi^{*}=\arg\max_{\phi}I(\mathbf{Y}^{\mathrm{suf}};\phi(\mathbf{X})-I(\mathbf{Y}^{\mathrm{suf}};\bm{E}^{*}_{\mathrm{learn}}|\phi(\mathbf{X})),$
(9)

where $I(\cdot;\cdot)$ measures Shannon mutual information. The first and
second terms correspond to ensure sufficiency and invariance property of
$\phi(\bm{X})$, respectively.

Considering the unavailability of $\bm{Y}^{\text{suf}}$, we present the
following practical loss function as the instantiation of Eq. 9 via our
surrogate loss in Eq. 4:

$\displaystyle\min_{\rho,\phi}\mathcal{L}_{\mathrm{TIL}}=$
$\displaystyle\mathbb{E}_{e\in\bm{E}^{*}_{\mathrm{infer}}}\bm{\mathcal{R}}^{(e)}_{\mathrm{suf}}(\rho,\phi)+\lambda_{1}\bm{\mathcal{R}}_{\mathrm{ERM}}(\rho,\phi)$
(10)
$\displaystyle+\lambda_{2}\mathrm{Var}_{e\in{\bm{E}^{*}}_{\mathrm{infer}}}\left[\bm{\mathcal{R}}^{(e)}_{\mathrm{suf}}(\rho,\phi)\right],$

where $\lambda_{1},\lambda_{2}$ are hyper-parameters,
$\bm{\mathcal{R}}_{\mathrm{ERM}}(\rho,\phi)=\mathbb{E}_{\mathbf{X},\mathbf{Y}}\left[\ell(\rho(\phi(\mathbf{X})),\mathbf{Y})\right]$
is the ERM loss on raw $\bm{Y}$,
$\bm{\mathcal{R}}^{e}_{\mathrm{suf}}(\rho,\phi)$ defined in Eq. 10 is the loss
of inferred environment $e$ on $\bm{Y}^{\text{suf}}$, and
$\mathrm{Var}_{e\in\bm{E}^{*}_{\mathrm{infer}}}\left[\bm{\mathcal{R}}^{(e)}_{\mathrm{suf}}(\rho,\phi)\right]$
implies the variance of loss across inferred environments. The first and
second terms are jointly used to ensure the sufficient predictive power of
$\phi(\bm{X})$ for $\bm{Y}^{\text{suf}}$, where $\lambda_{1}$ controls the
trade-off between introducing information of
$\mu(\bm{Y}^{\text{suf}}),\sigma(\bm{Y}^{\text{suf}})$ and the influence of
$\bm{Z}$. The third term further balanced by $\lambda_{2}$ ensures the
invariance property and is robust to marginal distribution shifts of input,
theoretically guaranteed by (Krueger et al., 2021) and further balanced by
$\lambda_{2}$.

The overall algorithm is summarized in Appendix A. Compared to the backbone,
FOIL slightly increases the parameter count due to additional multiple
regressors.

Method | Informer(AAAI’21) | with FOIL | Crossformer(ICLR’23) | with FOIL | PatchTST(ICLR’23) | with FOIL
---|---|---|---|---|---|---
Metric | MSE | MAE | MSE | MAE | MSE | MAE | MSE | MAE | MSE | MAE | MSE | MAE
Exchange | 24 | 0.812 | 0.736 | 0.036 | 0.146 | 0.083 | 0.233 | 0.029 | 0.129 | 0.092 | 0.229 | 0.031 | 0.136
48 | 0.715 | 0.682 | 0.063 | 0.191 | 0.164 | 0.328 | 0.054 | 0.175 | 0.090 | 0.243 | 0.052 | 0.171
96 | 0.782 | 0.710 | 0.142 | 0.274 | 0.214 | 0.381 | 0.111 | 0.240 | 0.142 | 0.291 | 0.107 | 0.235
192 | 0.708 | 0.701 | 0.236 | 0.369 | 0.709 | 0.716 | 0.213 | 0.349 | 0.364 | 0.468 | 0.226 | 0.351
336 | 1.587 | 1.063 | 0.546 | 0.591 | 2.158 | 1.231 | 0.471 | 0.500 | 0.512 | 0.540 | 0.465 | 0.486
720 | 3.922 | 1.793 | 0.712 | 0.679 | 2.093 | 1.215 | 1.193 | 0.833 | 0.957 | 0.738 | 0.925 | 0.722
IMP. |  |  | 80.58% | 61.24% |  |  | 61.90% | 45.06% |  |  | 30.60% | 21.11%
ILI | 4 | 3.212 | 1.530 | 0.736 | 0.593 | 2.147 | 1.232 | 0.332 | 0.400 | 1.043 | 0.587 | 0.616 | 0.507
8 | 3.668 | 1.642 | 0.881 | 0.667 | 2.678 | 1.403 | 0.569 | 0.512 | 0.638 | 0.557 | 0.586 | 0.546
12 | 3.974 | 1.722 | 1.069 | 0.768 | 2.914 | 1.476 | 0.706 | 0.575 | 0.959 | 0.795 | 0.560 | 0.519
16 | 4.187 | 1.773 | 1.047 | 0.779 | 3.496 | 1.628 | 0.701 | 0.568 | 0.726 | 0.563 | 0.696 | 0.555
20 | 4.296 | 1.806 | 1.011 | 0.797 | 3.589 | 1.653 | 0.702 | 0.596 | 0.807 | 0.705 | 0.571 | 0.541
24 | 4.445 | 1.844 | 1.014 | 0.806 | 3.513 | 1.633 | 0.686 | 0.604 | 1.072 | 0.850 | 0.663 | 0.625
IMP. |  |  | 75.80% | 57.37% |  |  | 79.99% | 64.03% |  |  | 27.04% | 16.91%
ETTh1 | 24 | 0.219 | 0.392 | 0.038 | 0.146 | 0.194 | 0.400 | 0.028 | 0.126 | 0.031 | 0.136 | 0.027 | 0.126
48 | 0.474 | 0.638 | 0.065 | 0.190 | 0.270 | 0.465 | 0.042 | 0.156 | 0.044 | 0.160 | 0.041 | 0.154
96 | 0.965 | 0.892 | 0.088 | 0.224 | 0.146 | 0.312 | 0.056 | 0.181 | 0.061 | 0.190 | 0.056 | 0.182
192 | 1.029 | 0.967 | 0.148 | 0.299 | 0.241 | 0.420 | 0.075 | 0.209 | 0.082 | 0.223 | 0.078 | 0.215
336 | 0.677 | 0.769 | 0.136 | 0.296 | 0.246 | 0.425 | 0.088 | 0.233 | 0.100 | 0.246 | 0.092 | 0.237
720 | 1.086 | 0.973 | 0.132 | 0.288 | 0.392 | 0.554 | 0.104 | 0.254 | 0.154 | 0.310 | 0.120 | 0.272
IMP. |  |  | 85.38% | 68.14% |  |  | 73.04% | 54.43% |  |  | 10.48% | 5.80%
ETTh2 | 24 | 0.668 | 0.705 | 0.121 | 0.275 | 0.136 | 0.299 | 0.071 | 0.198 | 0.080 | 0.215 | 0.071 | 0.197
48 | 0.999 | 0.866 | 0.258 | 0.407 | 0.122 | 0.274 | 0.106 | 0.248 | 0.106 | 0.248 | 0.103 | 0.241
96 | 3.070 | 1.628 | 0.222 | 0.369 | 0.256 | 0.408 | 0.137 | 0.286 | 0.156 | 0.309 | 0.140 | 0.289
192 | 3.548 | 1.768 | 0.699 | 0.682 | 1.257 | 1.034 | 0.198 | 0.352 | 0.217 | 0.374 | 0.201 | 0.356
336 | 2.663 | 1.526 | 0.801 | 0.756 | 1.305 | 1.027 | 0.234 | 0.389 | 0.233 | 0.390 | 0.216 | 0.372
720 | 2.335 | 1.422 | 0.730 | 0.725 | 1.579 | 1.158 | 0.253 | 0.402 | 0.317 | 0.448 | 0.238 | 0.391
IMP. |  |  | 78.03% | 58.82% |  |  | 59.61% | 44.42% |  |  | 10.65% | 6.64%

Table 1: Performance comparison between original and FOIL equipped versions of
backbones. The top-performing version is marked in bold. IMP. is the average
percentage improvement across lengths of horizon window compared to the
original version. FOIL consistently and significantly enhances the performance
of various TSF backbones on all datasets and metrics across horizon window
lengths.

##  5 Experiments

###  5.1 Setup

Datasets. We conduct experiments on four popular real-world datasets commonly
used as benchmarks: the daily reported exchange rates dataset (Exchange) (Lai
et al., 2018), the weekly reported ratios of patients seen with influenza-like
illness dataset (ILI) (Kamarthi et al., 2021a), and two hourly reported
electricity transformer temperature datasets (ETTh1 and ETTh2) (Zhou et al.,
2021). We adhere to the general setups and target variables selections,
following previous literatures (Wu et al., 2021, 2022; Nie et al., 2022).

Backbones. As previously mentioned, our proposed FOIL is a model-agnostic
framework. We select three different types of TSF models as backbones.
Informer (Zhou et al., 2021) proposes an efficient transformer for long-term
TSF. Crossformer (Zhang & Yan, 2022) better utilizes cross-dimension
dependency, making it more sensitive to spuriouse correlations. PatchTST (Nie
et al., 2022) employs channel-independent and patching strategies to achieve
state-of-the-art performance.

Baselines. We comprehensively compare the following twelve distribution shifts
baselines: (1) Two advanced methods for handling temporal distribution shifts
in TSF: NST (Liu et al., 2022) and RevIN (Kim et al., 2021). (2) Six well-
acknowledged general OOD methods following (Gagnon-Audet et al., 2022),
adopted due to the lack of OOD methods for TSF: (a) Methods requiring
environment labels: GroupDRO (Sagawa et al., 2019), IRM (Arjovsky et al.,
2019), IB-ERM (Ahuja et al., 2021), VREx (Krueger et al., 2021) and SD
(Pezeshki et al., 2021). (b) Methods not requiring environment labels: EIIL
(Creager et al., 2021). (3) Two hybrid methods: IRM+RevIN and EIIL+RevIN.

Implementation. Regarding the horizon window length, we considered a range
from short to long-term TSF tasks. For ETTh1, ETTh2, and Exchange, the lengths
are [24, 48, 96, 168, 336, 720] with a fixed lookback window size of 96 and a
consistent label window size of 48 for the decoder. For the weekly reported
ILI, the lengths are [4, 8, 12, 16, 20, 24], representing the next one month
to six months, with a fixed lookback window size of 36 and a consistent label
window size of 18 for the decoder.. Note that, we lack the availability of
suitable environment labels. We address this by dividing the training set into
$k$, tuned from 2 to 10, equal-length time segments to serve as predefined
environment labels. When the backbone is equipped with our FOIL, the model
architecture of the backbone remains unchanged.

Evaluation. We employ the widely-adopted evaluation metrics: mean squared
error (MSE) and mean absolute error (MAE). We report average performance over
three independent runs for each model.

Reproducibility. All training data, testing data and code are available at:
https://github.com/AdityaLab/FOIL. More experimental details are revealed in
Appendix B.

###  5.2 Results

As shown in Table 1, we present results for both original versions and
corresponding FOIL equipped versions of backbones, yielding the following
observations:

(1) Overall, FOIL consistently and significantly improves the performance of
various TSF backbones across all datasets and forecasting lengths with
improvements reaching up to 85% on MSE, thereby demonstrating FOIL’s
effectiveness. For the state-of-the-art PatchTST, FOIL consistently enhances
performance, achieving up to 30% improvement. For the lower-performing
Informer, FOIL shows more significant improvements, frequently by an order of
magnitude, yielding competitive results.

(2) FOIL excels in short-term forecasting compared to long-term forecasting,
as the higher uncertainty of the latter hinders learning invariant features.
Moreover, FOIL’s most significant improvement in the ILI dataset is attributed
to the serious OOD shifts in its test data, particularly during the unseen
COVID-19 period.

###  5.3 Comparison with Distribution Shifts Methods

In this section, we conduct a comparative analysis of the performance
disparities between FOIL and existing distribution shifts methods. We employ
the Informer as the forecasting backbone. The forecasting length is set as 16
for ILI and 96 for others. Similar observations are found in other settings.
We measure the relative improvement compared to the best-performing baseline
on each metric and dataset.

As shown in Table 2, our observations include:

(1) FOIL achieves the best performance across all datasets. The average
improvements on MSE and MAE are more than 10% and 5.5% respectively, showing
the benefits of FOIL over existing distribution shift methods. Notably, though
hybrid models additionally alleviate the temporal distribution shift problem
and exhibit better performance than general OOD baselines, FOIL still
outperforms hybrid models by over 11%. Therefore, our proposed surrogate loss
in Eq. 4 is irreplaceable by current instance normalization methods as
discussed in Section 4.2 and exhibits important benefits for alleviating
unobserved core covariates issues in the TSF task.

(2) General OOD methods exhibit poor performances. This verifies that directly
applying existing invariant learning methods for the TSF task is
inappropriate, as discussed in Section 3.

(3) Among the existing general OOD methods, EIIL exhibits better performance
than other baselines, due to their capability to infer proper environments
from the data. Besides, the performances of EIIL also suggest the advantages
of inferring environments at representation spaces as opposed to raw feature
spaces for TSF’s high-dimensional input. These observed advantages align with
the considerations made in FOIL.

Dataset | Exchange | ILI | ETTh1 | ETTh2
---|---|---|---|---
Type | Env. Known? | Method | MSE | MAE | MSE | MAE | MSE | MAE | MSE | MAE
Base | No | ERM | 0.782 | 0.710 | 3.974 | 1.722 | 0.965 | 0.892 | 3.070 | 1.628
General OOD (Invariant Learning) | Yes | GroupDRO | 0.781 | 0.715 | 3.721 | 1.888 | 0.880 | 0.863 | 3.192 | 1.647
IRM | 0.716 | 0.688 | 3.608 | 1.732 | 0.495 | 0.646 | 2.910 | 1.581
VREx | 0.781 | 0.715 | 3.671 | 1.875 | 0.874 | 0.859 | 3.238 | 1.662
SD | 0.782 | 0.716 | 3.674 | 1.677 | 0.891 | 0.870 | 3.246 | 1.664
IB-ERM | 0.787 | 0.719 | 3.673 | 1.677 | 0.883 | 0.865 | 3.209 | 1.654
No | EIIL | 0.540 | 0.630 | 3.251 | 1.648 | 0.673 | 0.783 | 1.252 | 1.013
Temporal Shifts | NA | RevIN | 0.169 | 0.296 | 1.350 | 0.867 | 0.108 | 0.248 | 0.236 | 0.387
NST | 0.151 | 0.281 | 1.351 | 0.871 | 0.118 | 0.260 | 0.258 | 0.406
Hybrid | Yes | IRM+RevIN | 0.160 | 0.291 | 1.328 | 0.863 | 0.105 | 0.244 | 0.234 | 0.381
No | EIIL+RevIN | 0.170 | 0.309 | 1.205 | 0.820 | 0.097 | 0.241 | 0.343 | 0.483
Ours | No | FOIL | 0.136 | 0.274 | 1.047 | 0.768 | 0.088 | 0.224 | 0.210 | 0.358
Improvement(%) | +9.93 | +2.50 | +12.94 | +5.00 | +9.27 | +7.05 | +10.26 | +6.04

Table 2: Comparison with existing distribution shifts methods across four
datasets using Informer backbone. The best results are in bold. NA means not
considering environments. Our FOIL outperforms all existing distribution shift
methods on all datasets and both metrics.

###  5.4 Ablation Study

To demonstrate the effectiveness of each module or loss in FOIL, we conduct an
ablation study that introduces three ablated versions of FOIL: (1) FOIL
$\backslash$Suf: remove the surrogate loss in Eq. 4 for decomposing
Sufficiently predictable $\bm{Y}^{\text{suf}}$ (2) FOIL $\backslash$TEI:
remove the whole Time-series Environment Inference module detailed in Section
4.3,i.e. set the number of environment as 1.(3) FOIL $\backslash$LP: removed
the Label Propagation approach in $\bm{\mathcal{M}}_{\mathrm{TEI}}$ in Eq. 8.
All other experiment setups follow Section 5.3. The ablation study results are
shown in Figure LABEL:fig:ablation.

Though FOIL outperforms all ablated versions in forecasting accuracy, all
designed modules and loss in FOIL show individual effectiveness through the
ablation study. Specifically, the performance FOIL $\backslash$Suf drops
significantly more than other ablated versions, which indicates the necessity
of mitigating unobserved covariate issues when applying invariant learning for
TSF. Moreover, FOIL $\backslash$TEI consistently outperforms FOIL
$\backslash$LP across all datasets, which validates the effectiveness of
preserving the temporal adjacency structure for Time Series Forecasting (TSF).

###  5.5 Case Study: Analysis of Inferred Environments

To justify the reasonableness of the environments inferred by FOIL, we conduct
a case study on the ILI dataset by demonstrating the contribution disparities
among three major components (Summer, i.e., June to August annually; Winter,
i.e., December to February annually; and the H1N1-09 period, i.e., April 2009
to August 2010) when the total number of inferred environments is set to 2.
The visualization of contributions from each component is shown in Figure
LABEL:fig:showcase. The visualization results align with public health
perspectives in two ways: First, the major components of Environment 1 and 2
are distinguished by Winter and Summer, as influenza is a seasonal disease and
typically spreads during the winter and ends before the summer. Second, the
H1N1-09 period has more contributions in Environment 1 than 2, which aligns
with the fact that the H1N1-09 period and winter flu seasons exhibit
similarities. These observations support the ability of FOIL to infer
meaningful environments in real-world TSF applications.

##  6 Additional Related Works

###  6.1 Time Series Forecasting

Classical TSF models (Tsay, 2000; Ariyo et al., 2014; Zhang, 2003) often face
limitations in capturing complex patterns due to their inherent model
constraints. Recent advancements in deep learning methods, such as Recurrent
Neural Networks (RNN) and Transformer (Rumelhart et al., 1986; Hochreiter &
Schmidhuber, 1997; Vaswani et al., 2017), have led to sophisticated deep TSF
models including Informer, Reformer, Autoformer, Fedformer, and PatchTST (Zhou
et al., 2021; Kitaev et al., 2020; Wu et al., 2021; Zhou et al., 2022; Nie et
al., 2022), significantly improving forecasting accuracy. However, these
advanced models primarily rely on ERM with simple IID assumptions.
Consequently, they exhibit shortcomings in OOD generalization when faced with
potential distribution shifts in TS data.

###  6.2 Distribution Shifts in Time-Series Forecasting.

In addition to the aforementioned TSF methods in handling marginal
distribution shifts (Passalis et al., 2019; Kim et al., 2021; Liu et al.,
2022; Fan et al., 2023; Du et al., 2021), there are some efforts that have
tackled OOD challenges in TSF. However, all have certain limitations. For
example, DIVERSITY (Lu et al., 2022, 2023) is specifically designed for time
series classification and detection tasks. OneNet (Zhang et al., 2023) is
tailored for online forecasting scenarios by online ensembling. Pets (Zhao et
al., 2023) focuses on distribution shifts induced by the specific phenomenon
of performativity. This highlights the need for a general OOD method
applicable across diverse TSF scenarios and models.

Despite the existing benchmark WOODS (Gagnon-Audet et al., 2022) that
evaluates IL methods combined with TSF models with a focus on TS
classification tasks, our proposed approach addresses diverse datasets under
realistic TSF scenarios, offering different and comprehensive problem
formulation, methodology, and evaluations.

##  7 Conclusion and Discussion

In this paper, we formally study the fundamental out-of-distribution
challenges in time-series forecasting tasks (OOD-TSF). We identify specific
gaps when applying existing invariant learning methods to OOD-TSF, including
theoretical violations of sufficiency and invariance assumptions and the
empirical absence of environment labels in time-series datasets. To address
these challenges, we introduce a model-agnostic framework named FOIL, which
employs an innovative surrogate loss to alleviate the impact of unobserved
variables. FOIL features a joint optimization strategy, which learns invariant
representations and preserves temporal adjacency structure. Empirical
evaluations demonstrate the effectiveness of FOIL by consistently improving
the performances of different TSF models and outperforming other OOD
solutions.

Beyond the scope of FOIL, it is important to recognize that invariant learning
is not the only solution to enhance OOD generalization in TSF tasks.
Alternative approaches or interpretations can require advanced causal
analysis, feature selections, or learning dynamic temporal patterns. The using
of additional information to enhance the sufficiency of predictions also
deserves to be explored. We also emphasize the need for conscientious
evaluations on underrepresented subgroups when implementing our approach in
real-world scenarios for promoting fairness among subgroups. We expect that
future research will delve into these open questions, contributing both
theoretically and practically to advance the understanding of OOD-TSF
challenges and achieve more reliable TSF models.

## Impact Statement

Our work introduces a new methodology to improve the out-of-distribution
generalization of time-series forecasting models and is applicable across wide
range of domains and real-world applications including sensitive applications
in public health, economics, etc. Therefore, care should be taken in
alleviating biases and disparities in dataset as well as making sure the
predictions of model do not pose ethical risks or lead to inequitable outcomes
across various stakeholders relevant to specific applications our methods are
used.

## Acknowledgements

We thank the anonymous reviewers for their helpful comments. This paper was
supported in part by the NSF (Expeditions CCF-1918770, CAREER IIS-2028586,
Medium IIS-1955883, Medium IIS-2106961, PIPP CCF-2200269, IIS-2008334, CAREER
IIS-2144338), CDC MInD program, Meta faculty gifts, and funds/computing
resources from Georgia Tech.

## References

  * Ahuja et al. (2021) Ahuja, K., Caballero, E., Zhang, D., Gagnon-Audet, J.-C., Bengio, Y., Mitliagkas, I., and Rish, I.  Invariance principle meets information bottleneck for out-of-distribution generalization.  _Advances in Neural Information Processing Systems_ , 34:3438–3450, 2021.
  * Anderson (2011) Anderson, T. W.  _The statistical analysis of time series_.  John Wiley & Sons, 2011.
  * Ariyo et al. (2014) Ariyo, A. A., Adewumi, A. O., and Ayo, C. K.  Stock price prediction using the arima model.  In _2014 UKSim-AMSS 16th international conference on computer modelling and simulation_ , pp. 106–112. IEEE, 2014.
  * Arjovsky et al. (2019) Arjovsky, M., Bottou, L., Gulrajani, I., and Lopez-Paz, D.  Invariant risk minimization.  _arXiv preprint arXiv:1907.02893_ , 2019.
  * Chang et al. (2020) Chang, S., Zhang, Y., Yu, M., and Jaakkola, T.  Invariant rationalization.  In _International Conference on Machine Learning_ , pp. 1448–1458. PMLR, 2020.
  * Cheng et al. (2015) Cheng, C., Sa-Ngasoongsong, A., Beyca, O., Le, T., Yang, H., Kong, Z., and Bukkapatnam, S. T.  Time series forecasting for nonlinear and non-stationary processes: a review and comparative study.  _Iie Transactions_ , 47(10):1053–1071, 2015.
  * Creager et al. (2021) Creager, E., Jacobsen, J.-H., and Zemel, R.  Environment inference for invariant learning.  In _International Conference on Machine Learning_ , pp. 2189–2200. PMLR, 2021.
  * Du et al. (2021) Du, Y., Wang, J., Feng, W., Pan, S., Qin, T., Xu, R., and Wang, C.  Adarnn: Adaptive learning and forecasting of time series.  In _Proceedings of the 30th ACM international conference on information & knowledge management_, pp. 402–411, 2021.
  * Fan et al. (2023) Fan, W., Wang, P., Wang, D., Wang, D., Zhou, Y., and Fu, Y.  Dish-ts: a general paradigm for alleviating distribution shift in time series forecasting.  In _Proceedings of the AAAI Conference on Artificial Intelligence_ , volume 37, pp. 7522–7529, 2023.
  * Gagnon-Audet et al. (2022) Gagnon-Audet, J.-C., Ahuja, K., Darvishi-Bayazi, M.-J., Mousavi, P., Dumas, G., and Rish, I.  Woods: Benchmarks for out-of-distribution generalization in time series.  _arXiv preprint arXiv:2203.09978_ , 2022.
  * Gong et al. (2016) Gong, M., Zhang, K., Liu, T., Tao, D., Glymour, C., and Schölkopf, B.  Domain adaptation with conditional transferable components.  In _International conference on machine learning_ , pp. 2839–2848. PMLR, 2016.
  * Gruver et al. (2023) Gruver, N., Finzi, M., Qiu, S., and Wilson, A. G.  Large language models are zero-shot time series forecasters.  _arXiv preprint arXiv:2310.07820_ , 2023.
  * Hochreiter & Schmidhuber (1997) Hochreiter, S. and Schmidhuber, J.  Long short-term memory.  _Neural computation_ , 9(8):1735–1780, 1997.
  * Hoyer et al. (2008) Hoyer, P., Janzing, D., Mooij, J. M., Peters, J., and Schölkopf, B.  Nonlinear causal discovery with additive noise models.  _Advances in neural information processing systems_ , 21, 2008.
  * Huang et al. (2022) Huang, B.-W., Liao, K.-T., Kao, C.-S., and Lin, S.-D.  Environment diversification with multi-head neural network for invariant learning.  _Advances in Neural Information Processing Systems_ , 35:915–927, 2022.
  * Kamarthi et al. (2021a) Kamarthi, H., Kong, L., Rodriguez, A., Zhang, C., and Prakash, B. A.  When in doubt: Neural non-parametric uncertainty quantification for epidemic forecasting.  _Advances in Neural Information Processing Systems_ , 34:19796–19807, 2021a.
  * Kamarthi et al. (2021b) Kamarthi, H., Kong, L., Rodriguez, A., Zhang, C., and Prakash, B. A.  When in doubt: Neural non-parametric uncertainty quantification for epidemic forecasting.  _Advances in Neural Information Processing Systems_ , 34:19796–19807, 2021b.
  * Kamarthi et al. (2022) Kamarthi, H., Kong, L., Rodríguez, A., Zhang, C., and Prakash, B. A.  Camul: Calibrated and accurate multi-view time-series forecasting.  In _Proceedings of the ACM Web Conference 2022_ , pp. 3174–3185, 2022.
  * Kim et al. (2021) Kim, T., Kim, J., Tae, Y., Park, C., Choi, J.-H., and Choo, J.  Reversible instance normalization for accurate time-series forecasting against distribution shift.  In _International Conference on Learning Representations_ , 2021.
  * Kitaev et al. (2020) Kitaev, N., Kaiser, Ł., and Levskaya, A.  Reformer: The efficient transformer.  _arXiv preprint arXiv:2001.04451_ , 2020.
  * Koyama & Yamaguchi (2020) Koyama, M. and Yamaguchi, S.  When is invariance useful in an out-of-distribution generalization problem?  _arXiv preprint arXiv:2008.01883_ , 2020.
  * Krueger et al. (2021) Krueger, D., Caballero, E., Jacobsen, J.-H., Zhang, A., Binas, J., Zhang, D., Le Priol, R., and Courville, A.  Out-of-distribution generalization via risk extrapolation (rex).  In _International Conference on Machine Learning_ , pp. 5815–5826. PMLR, 2021.
  * Lai et al. (2018) Lai, G., Chang, W.-C., Yang, Y., and Liu, H.  Modeling long-and short-term temporal patterns with deep neural networks.  In _The 41st international ACM SIGIR conference on research & development in information retrieval_, pp. 95–104, 2018.
  * Lim & Zohren (2021) Lim, B. and Zohren, S.  Time-series forecasting with deep learning: a survey.  _Philosophical Transactions of the Royal Society A_ , 379(2194):20200209, 2021.
  * Lin et al. (2022) Lin, Y., Zhu, S., Tan, L., and Cui, P.  Zin: When and how to learn invariance without environment partition?  _Advances in Neural Information Processing Systems_ , 35:24529–24542, 2022.
  * Liu et al. (2021a) Liu, J., Hu, Z., Cui, P., Li, B., and Shen, Z.  Heterogeneous risk minimization.  In _International Conference on Machine Learning_ , pp. 6804–6814. PMLR, 2021a.
  * Liu et al. (2021b) Liu, J., Hu, Z., Cui, P., Li, B., and Shen, Z.  Integrated latent heterogeneity and invariance learning in kernel space.  _Advances in Neural Information Processing Systems_ , 34:21720–21731, 2021b.
  * Liu et al. (2021c) Liu, J., Shen, Z., He, Y., Zhang, X., Xu, R., Yu, H., and Cui, P.  Towards out-of-distribution generalization: A survey.  _arXiv preprint arXiv:2108.13624_ , 2021c.
  * Liu et al. (2022) Liu, Y., Wu, H., Wang, J., and Long, M.  Non-stationary transformers: Exploring the stationarity in time series forecasting.  _Advances in Neural Information Processing Systems_ , 35:9881–9893, 2022.
  * Lu et al. (2022) Lu, W., Wang, J., Sun, X., Chen, Y., and Xie, X.  Out-of-distribution representation learning for time series classification.  In _The Eleventh International Conference on Learning Representations_ , 2022.
  * Lu et al. (2023) Lu, W., Wang, J., Sun, X., Chen, Y., Ji, X., Yang, Q., and Xie, X.  Diversify: A general framework for time series out-of-distribution detection and generalization.  _arXiv preprint arXiv:2308.02282_ , 2023.
  * Maeda & Shimizu (2021) Maeda, T. N. and Shimizu, S.  Causal additive models with unobserved variables.  In _Uncertainty in Artificial Intelligence_ , pp. 97–106. PMLR, 2021.
  * Mäkinen et al. (2009) Mäkinen, T. M., Juvonen, R., Jokelainen, J., Harju, T. H., Peitso, A., Bloigu, A., Silvennoinen-Kassinen, S., Leinonen, M., and Hassi, J.  Cold temperature and low humidity are associated with increased occurrence of respiratory tract infections.  _Respiratory medicine_ , 103(3):456–462, 2009.
  * Mourtzoukou & Falagas (2007) Mourtzoukou, E. and Falagas, M. E.  Exposure to cold and respiratory tract infections.  _The International Journal of Tuberculosis and Lung Disease_ , 11(9):938–943, 2007.
  * Nerlove et al. (2014) Nerlove, M., Grether, D. M., and Carvalho, J. L.  _Analysis of economic time series: a synthesis_.  Academic Press, 2014.
  * Nie et al. (2022) Nie, Y., Nguyen, N. H., Sinthong, P., and Kalagnanam, J.  A time series is worth 64 words: Long-term forecasting with transformers.  In _The Eleventh International Conference on Learning Representations_ , 2022.
  * Passalis et al. (2019) Passalis, N., Tefas, A., Kanniainen, J., Gabbouj, M., and Iosifidis, A.  Deep adaptive input normalization for time series forecasting.  _IEEE transactions on neural networks and learning systems_ , 31(9):3760–3765, 2019.
  * Pearl et al. (2000) Pearl, J. et al.  Causality: Models, reasoning and inference.  _Cambridge, UK: CambridgeUniversityPress_ , 19(2):3, 2000.
  * Peters et al. (2016) Peters, J., Bühlmann, P., and Meinshausen, N.  Causal inference by using invariant prediction: identification and confidence intervals.  _Journal of the Royal Statistical Society Series B: Statistical Methodology_ , 78(5):947–1012, 2016.
  * Pezeshki et al. (2021) Pezeshki, M., Kaba, O., Bengio, Y., Courville, A. C., Precup, D., and Lajoie, G.  Gradient starvation: A learning proclivity in neural networks.  _Advances in Neural Information Processing Systems_ , 34:1256–1272, 2021.
  * Rodriguez et al. (2021) Rodriguez, A., Tabassum, A., Cui, J., Xie, J., Ho, J., Agarwal, P., Adhikari, B., and Prakash, B. A.  Deepcovid: An operational deep learning-driven framework for explainable real-time covid-19 forecasting.  In _Proceedings of the AAAI Conference on Artificial Intelligence_ , volume 35, pp. 15393–15400, 2021.
  * Rojas-Carulla et al. (2018) Rojas-Carulla, M., Schölkopf, B., Turner, R., and Peters, J.  Invariant models for causal transfer learning.  _The Journal of Machine Learning Research_ , 19(1):1309–1342, 2018.
  * Rumelhart et al. (1986) Rumelhart, D. E., Hinton, G. E., and Williams, R. J.  Learning representations by back-propagating errors.  _nature_ , 323(6088):533–536, 1986.
  * Sagawa et al. (2019) Sagawa, S., Koh, P. W., Hashimoto, T. B., and Liang, P.  Distributionally robust neural networks for group shifts: On the importance of regularization for worst-case generalization.  _arXiv preprint arXiv:1911.08731_ , 2019.
  * Sancho et al. (1982) Sancho, J. M., San Miguel, M., Katz, S., and Gunton, J.  Analytical and numerical studies of multiplicative noise.  _Physical Review A_ , 26(3):1589, 1982.
  * Sezer et al. (2020) Sezer, O. B., Gudelek, M. U., and Ozbayoglu, A. M.  Financial time series forecasting with deep learning: A systematic literature review: 2005–2019.  _Applied soft computing_ , 90:106181, 2020.
  * Tabassum et al. (2021) Tabassum, A., Chinthavali, S., Tansakul, V., and Prakash, B. A.  Actionable insights in multivariate time-series for urban analytics.  2021\.
  * Tsay (2000) Tsay, R. S.  Time series and forecasting: Brief history and future research.  _Journal of the American Statistical Association_ , 95(450):638–643, 2000.
  * Vaswani et al. (2017) Vaswani, A., Shazeer, N., Parmar, N., Uszkoreit, J., Jones, L., Gomez, A. N., Kaiser, Ł., and Polosukhin, I.  Attention is all you need.  _Advances in neural information processing systems_ , 30, 2017.
  * Weber et al. (2022) Weber, M. G., Li, L., Wang, B., Zhao, Z., Li, B., and Zhang, C.  Certifying out-of-domain generalization for blackbox functions.  In _International Conference on Machine Learning_ , pp. 23527–23548. PMLR, 2022.
  * Wooldridge (1997) Wooldridge, J. M.  Multiplicative panel data models without the strict exogeneity assumption.  _Econometric Theory_ , 13(5):667–678, 1997.
  * Wu et al. (2021) Wu, H., Xu, J., Wang, J., and Long, M.  Autoformer: Decomposition transformers with auto-correlation for long-term series forecasting.  _Advances in Neural Information Processing Systems_ , 34:22419–22430, 2021.
  * Wu et al. (2022) Wu, H., Hu, T., Liu, Y., Zhou, H., Wang, J., and Long, M.  Timesnet: Temporal 2d-variation modeling for general time series analysis.  _arXiv preprint arXiv:2210.02186_ , 2022.
  * Ye et al. (2023) Ye, N., Zhu, L., Wang, J., Zeng, Z., Shao, J., Peng, C., Pan, B., Li, K., and Zhu, J.  Certifiable out-of-distribution generalization.  In _Proceedings of the AAAI Conference on Artificial Intelligence_ , volume 37, pp. 10927–10935, 2023.
  * Zhang (2003) Zhang, G. P.  Time series forecasting using a hybrid arima and neural network model.  _Neurocomputing_ , 50:159–175, 2003.
  * Zhang & Yan (2022) Zhang, Y. and Yan, J.  Crossformer: Transformer utilizing cross-dimension dependency for multivariate time series forecasting.  In _The Eleventh International Conference on Learning Representations_ , 2022.
  * Zhang et al. (2023) Zhang, Y.-F., Wen, Q., Wang, X., Chen, W., Sun, L., Zhang, Z., Wang, L., Jin, R., and Tan, T.  Onenet: Enhancing time series forecasting models under concept drift by online ensembling.  _arXiv preprint arXiv:2309.12659_ , 2023.
  * Zhao et al. (2023) Zhao, Z., Rodriguez, A., and Prakash, B. A.  Performative time-series forecasting.  _arXiv preprint arXiv:2310.06077_ , 2023.
  * Zhou et al. (2021) Zhou, H., Zhang, S., Peng, J., Zhang, S., Li, J., Xiong, H., and Zhang, W.  Informer: Beyond efficient transformer for long sequence time-series forecasting.  In _Proceedings of the AAAI conference on artificial intelligence_ , volume 35, pp. 11106–11115, 2021.
  * Zhou et al. (2022) Zhou, T., Ma, Z., Wen, Q., Wang, X., Sun, L., and Jin, R.  Fedformer: Frequency enhanced decomposed transformer for long-term series forecasting.  In _International Conference on Machine Learning_ , pp. 27268–27286. PMLR, 2022.

##  Appendix A Algorithm

Algorithm 1 The training procedure of our FOIL.

Require: Time-series dataset
$\mathcal{D}=\\{(\mathbf{X}_{i},\mathbf{Y}_{i})\\}^{N}_{i=1}$

Ensure: An optimized predictor
$\rho(\phi(\cdot)):\mathcal{X}\rightarrow\mathcal{Y}$

Initialize $\rho(\cdot)$, $\\{\rho^{(e)}(\cdot)\\}$, $\phi(\cdot)$

Random assign environment label for each $(\mathbf{X}_{i},\mathbf{Y}_{i})$.

while not converged do

Stage 1: Time-series Invariant Learning: Update $\phi(\cdot)$, $\rho(\cdot)$
according to Equation 10.

Stage 2: Time-series Environment Inference:

M Step: Fit models according to Equation 6, update $\\{\rho^{(e)}\\}$.

E Step: Reallocate environment labels according to Equation 7 and Equation 8.

end while

return $\rho(\cdot)$ and $\phi(\cdot)$.

##  Appendix B Additional Experimental Details

###  B.1 Datasets

We conduct experiments on four real-world datasets, commonly used as benchmark
datasets:

  * •

Exchange dataset records the daily exchange rates of eight currencies.

  * •

ETTh1 and ETTh2 datasets record the hourly electricity transformer
temperature, comprising two years of data collected from two separate counties
in China. They include seven variables. We omitted ETTm1 and ETTm2 as they
share the same data source as ETTh1 and ETTh2, but with different sampling
frequencies.

  * •

ILI dataset collects data on influenza-like illness patients weekly, with
eight variables. We mainly follow (Wu et al., 2022) to preprocess data, split
datasets into train/validation/test sets and select the target variables. All
datasets are preprocessed using the zero-mean normalization method.

###  B.2 Backbones

As aforementioned, our proposed FOIL is a model-agnostic framework. We select
three different types of TSF models as backbones. Informer (Zhou et al., 2021)
proposes an efficient transformer for long-term TSF. Crossformer (Zhang & Yan,
2022) better utilizes cross-dimension dependency, making it more sensitive to
spuriouse correlations. PatchTST (Nie et al., 2022) employs channel-
independent and patching strategies to achieve state-of-the-art performance.

###  B.3 Baselines: General OOD Methods

  * •

Methods with Environment Labels: IRM (Arjovsky et al., 2019) introduces a
penalty to learn invariant predictors across different environments. On the
basis of the invariance principle of IRM, IB-ERM (Ahuja et al., 2021)
incorporates the information bottleneck constraint. VREx (Krueger et al.,
2021) propose a penalty on the variance of training risks between environments
as a simple agent of risk extrapolation. SD (Pezeshki et al., 2021) proposes a
regularization method aimed at decoupling feature learning dynamics to achieve
better OOD generalization.GroupDRO (Sagawa et al., 2019), a regularizer for
worst-case group generalization, often considered to have general OOD
generalization capabilities.

  * •

Methods without Environment Labels: EIIL (Creager et al., 2021) infers the
most informative environments for downstream learning invariant predictors by
maximizing the penalty in IRM.

We omit AdaRNN (Du et al., 2021) for not being model-agnostic; DIVERSITY (Lu
et al., 2022, 2023), as it’s specific to time series classification and
detection tasks; and multi-view TSF methods (Kamarthi et al., 2022), which
treat each covariate as one view and inflate the parameter count, leading to
unfair comparison.

###  B.4 Implementation

For the backbones, we utilize implementations and hyperparameter settings from
the Time Series Library111https://github.com/thuml/Time-Series-Library. For
general OOD methods, we employ the implementations and tune hyperparameter
suggested by DomainBed222https://github.com/facebookresearch/DomainBed. For
TSF methods, we use the implementations and hyperparameter settings from their
corresponding papers. We have added an MLP to the end of PatchTST to utilize
covariates effectively. For our proposed framework FOIL, we also incorporate
RevIN like PatchTST to address the issue of non-stationarity. We perform
affine transformation on each dimension of the raw covariate through learnable
weight variables to better find invariant features and improve out-of-
distribution generalization capabilities.


# Parameterization-Free Observer Design for Nonlinear Systems: Application to
the State Estimation of Networked SIR Epidemics ††thanks: This work is
supported by the European Union’s Horizon Research and Innovation Programme
under Marie Skłodowska-Curie grant agreement No. 101062523. It has also
received funding from the Swedish Research Council and the Knut and Alice
Wallenberg Foundation, Sweden.

Muhammad Umar B. Niazi &Karl H. Johansson Laboratory for Information &
Decision Systems, Massachusetts Institute of Technology, Cambridge, MA 02139,
USA. Email<EMAIL_ADDRESS>of Decision and Control Systems, Digital
Futures, KTH Royal Institute of Technology, SE-100 44 Stockholm, Sweden.
Email<EMAIL_ADDRESS>
###### Abstract

Traditional observer design methods rely on certain properties of the system’s
nonlinearity, such as Lipschitz continuity, one-sided Lipschitzness, a bounded
Jacobian, or quadratic boundedness. These properties are described by
parameterized inequalities. However, enforcing these inequalities globally can
lead to very large parameters, resulting in overly conservative observer
design criteria. These criteria become infeasible for highly nonlinear
applications, such as networked epidemic processes. In this paper, we present
an observer design approach for estimating the state of nonlinear systems,
without requiring any parameterization of the system’s nonlinearities. The
proposed observer design depends only on systems’ matrices and applies to
systems with any nonlinearity. We establish different design criteria for
ensuring both asymptotic and exponential convergence of the estimation error
to zero. To demonstrate the efficacy of our approach, we employ it for
estimating the state of a networked SIR epidemic model. We show that, even in
the presence of measurement noise, the observer can accurately estimate the
epidemic state of each node in the network. To the best of our knowledge, the
proposed observer is the first that is capable of estimating the state of
networked SIR models.

##  1 Introduction

Nonlinear systems are ubiquitous in engineering, physics, and biology.
Accurately estimating their states is critical for many applications, such as
output feedback control, fault diagnosis, and prediction. Observers, typically
used for these purposes, have been extensively studied over the past few
decades in the control systems community.

Traditional methods for observer design rely on the assumption that the
nonlinearity of the system satisfies certain properties, which are defined
through parameterized inequalities. For example, Luenberger-like observers,
proposed by Thau in [1], have been designed using such parameterization-based
techniques. Various observer design criteria have been proposed in the
literature, such as Lipschitz continuity [2, 3, 4, 5], one-sided Lipschitz and
quadratic inner-boundedness [6, 7, 8], bounded Jacobian [9, 10], quadratic
boundedness [11], passivity [12], and dissipativity [13]. However, to ensure
the global convergence of the observer, these parameterizations have to be
enforced globally, which results in very large parameters [14]. Because of
this, parameterization-based techniques lead to unnecessarily conservative
observer design criteria, limiting their applicability to highly nonlinear
systems.

To overcome this challenge, we propose a novel observer design approach that
does not require any assumptions about the system’s nonlinearity, making it
parameterization-free. The proposed approach essentially treats the
nonlinearity as an unknown disturbance in the estimation error dynamics.
Therefore, the goal of the observer is to not only track the state but also
the nonlinearity of the system. We establish observer design criteria that
guarantee both asymptotic and exponential convergence of the estimation error
to zero.

We demonstrate the effectiveness of our approach through the state estimation
of a networked SIR epidemic model. State estimation of epidemic models is
critical because the infectious population is usually difficult to measure
directly and needs to be estimated. Moreover, parameterization-based design
becomes infeasible for epidemic models because their nonlinearity, i.e., the
mass action law, is quadratic in nature, rendering the Lipschitz constant and
other parameterizations to be very large. Through simulations, we show that
the observer can effectively estimate the epidemic state in every node even in
the presence of measurement noise.

The main contributions of this paper include a parameterization-free observer
design approach and its application to networked SIR epidemic processes.
Notably, this work is the first to propose an observer capable of estimating
the state of a networked SIR epidemic model, to the best of our knowledge. Our
previous work on the parameterization-based observer design [5] can estimate
the state of population models of epidemic processes. Additionally, [15]
demonstrated that their parameterization-based observer can estimate the state
of a networked SIS epidemic model. However, neither of these approaches can
estimate the state of networked SIR models. Therefore, our proposed
parameterization-free approach not only offers a promising alternative to
traditional observer design methods but also has the potential to be applied
to a wide range of nonlinear systems.

The paper is organized as follows. Section 2 outlines the problem statement,
while Section 3 introduces the observer form utilized in this paper. In
Section 4, we briefly review the parameterization-based designs of this
observer and highlight their limitations. Next, in Section 5, we present our
parameterization-free observer design. The effectiveness of our approach is
demonstrated in Section 6, where we apply it to a networked SIR epidemic
model. Finally, we conclude in Section 7 with our closing remarks.

##  2 Problem Statement

We consider nonlinear systems that can be described as

$\displaystyle\dot{x}$ $\displaystyle=Ax+Gf(Hx)$ (1a) $\displaystyle y$
$\displaystyle=Cx$ (1b)

where $x(t)\in\mathcal{X}\subseteq\mathbb{R}^{n_{x}}$ is the state and
$y(t)\in\mathbb{R}^{n_{y}}$ is the measured output. The nonlinear function
$f:H\mathcal{X}\rightarrow\mathbb{R}^{n_{f}}$ and matrices
$A\in\mathbb{R}^{n_{x}\times n_{x}}$, $G\in\mathbb{R}^{n_{x}\times n_{f}}$,
$H\in\mathbb{R}^{n_{h}\times n_{x}}$, and $C\in\mathbb{R}^{n_{y}\times n_{x}}$
are known. Notice that the control input is omitted in (1) only for brevity
and without loss of generality.

We assume that the system (1) is asymptotically detectable. That is, for any
pair of solution trajectories $t\mapsto x(t;x_{a})$ and $t\mapsto x(t;x_{b})$
initialized from $x_{a},x_{b}\in\mathcal{X}$ and defined on $t\in[0,\infty)$,
it holds that $y(t;x_{a})=y(t;x_{b})$ implies
$\lim_{t\rightarrow\infty}\|x(t;x_{a})-x(t;x_{b})\|=0$. This assumption is a
necessary condition for the existence of an asymptotic state observer [16]. In
addition, we also assume that $(A,C)$ is a detectable pair, i.e.,

$\mathrm{rank}\left[\begin{array}[]{c}sI-A\\\
C\end{array}\right]=n,\quad\forall s\in\mathbb{C}_{\geq 0}.$

It is important to remark that, if the above condition is not satisfied for
$(A,C)$, one can always add and subtract $\Delta$ so that $(A+\Delta,C)$
satisfies the above condition. In this case, we can either choose

$\bar{G}\bar{f}(\bar{H}x)=\underbrace{\left[\begin{array}[]{cc}G&-\Delta\end{array}\right]}_{\bar{G}}\underbrace{\left[\begin{array}[]{c}f(Hx)\\\
x\end{array}\right]}_{\bar{f}}$

where $\bar{H}=I_{n_{x}}$, or

$\bar{G}\bar{f}(\bar{H}x)=\underbrace{Gf(Hx)-\Delta x}_{\bar{f}}$

where $\bar{G}=I_{n_{x}}$ and $\bar{H}=I_{n_{x}}$.

Subject to the above assumptions, our goal is to design an observer

$\dot{z}=\phi(z,y),\quad\hat{x}=\theta(z,y)$

such that the estimation error $\xi(t)=\hat{x}(t)-x(t)$ satisfies

$\|\xi(t)\|\leq\beta(\|\xi(0)\|,t)$ (2)

where $\beta:\mathbb{R}_{\geq 0}\times\mathbb{R}\rightarrow\mathbb{R}_{\geq
0}$ is some class-$\mathcal{KL}$ function. In other words, we want
$\lim_{t\rightarrow+\infty}\|\xi(t)\|=0$ irrespective of the initial error
$\xi(0)\in\mathbb{R}^{n_{x}}$.

##  3 Proposed Form of the Observer

We consider the observer form proposed in [5]

$\displaystyle\dot{z}$ $\displaystyle=Mz+(ML+J)y+Nf(\eta)$ (3a)
$\displaystyle\eta$ $\displaystyle=H\hat{x}+K(y-C\hat{x})$ (3b)
$\displaystyle\hat{x}$ $\displaystyle=z+Ly$ (3c)

where $z(t)\in\mathbb{R}^{n_{x}}$ is the observer’s state and
$\hat{x}(t)\in\mathbb{R}^{n_{x}}$ is its output. The matrices
$M\in\mathbb{R}^{n_{x}\times n_{x}}$ and $N\in\mathbb{R}^{n_{x}\times n_{f}}$
are chosen as

$M=A-LCA-JC,\quad N=I-LC$ (4)

whereas $J,L\in\mathbb{R}^{n_{x}\times n_{y}}$ and
$K\in\mathbb{R}^{n_{h}\times n_{y}}$ are gain matrices that need to be
designed.

Define the estimation error $\xi(t)\doteq\hat{x}(t)-x(t)$, then the error
equation is given by

$\dot{\xi}=M\xi+NG\tilde{f}(\eta,Hx)$ (5)

where

$\tilde{f}(\eta,Hx)\doteq f(\eta)-f(Hx).$ (6)

Thus, our design objective is to find the gain matrices $J,K,L$ such that the
estimation error satisfies (2).

Although the observer (3) has a different form than traditional Luenberger-
like observers [17], it is inspired by the observer form developed by
Luenberger [18]. This form of the observer offers additional degrees of
freedom for designing $L$ in a way that minimizes the impact of $\tilde{f}$ in
the error dynamics (5). Also, the innovation term $K(y(t)-C\hat{x}(t))$ in the
function $f(\eta(t))$ in (3a)-(3b) allows for designing $K$ such that the
observer can effectively track the nonlinear signal $f(Hx(t))$ in (1a).
Furthermore, an additional gain matrix $J$ can be utilized to achieve
stability of the matrix $M=A-LCA-JC$.

The following lemma will be used in our analysis. It is quite standard in the
Lyapunov stability theory, and the reader is referred to [19, Chapter 5] for
more details and the proof.

######  Lemma 1.

If there is a function $V:\mathbb{R}^{n_{x}}\rightarrow\mathbb{R}_{\geq 0}$
that, for every $\xi(t)\in\mathbb{R}^{n_{x}}$, satisfies

  1. (i)

$\gamma_{1}\|\xi(t)\|^{2}\leq V(\xi(t))\leq\gamma_{2}\|\xi\|^{2}$, for some
$\gamma_{2}>\gamma_{1}>0$

  2. (ii)

$\dot{V}(\xi(t))<0$

then (5) is uniformly, globally asymptotically stable. In other words,
irrespective of the signal $\tilde{f}(\eta(t),x(t))$ in the error equation
(5), there exists a class-$\mathcal{KL}$ function $\beta$ such that (2) holds.

Moreover, if, instead of (ii), $\dot{V}(\xi(t))<-\alpha V$, for some
$\alpha>0$, then (5) is uniformly, globally exponentially stable. In other
words, irrespective of the signal $\tilde{f}(\eta(t),x(t))$ (defined in (6)),
there exist constants $c\doteq c(\|\xi(0)\|)>0$ and $\lambda>0$ such that (2)
holds with $\beta(\|\xi(0)\|,t)=c(\|\xi(0)\|)e^{-\lambda t}$. $\Box$

The next section introduces observer design criteria that rely on the
Lipschitz continuity and quadratic boundedness of the nonlinear function $f$.
This approach is known as parameterization-based design. Then, in the
subsequent section, we will propose a parameterization-free design, which does
not rely on any specific parameterization of $f$.

##  4 Review of Parameterization-based Observer Design and its Limitations

In this section, we briefly review existing results related to the
parameterization-based design of observers, with a particular focus on two
commonly used parameterizations: Lipschitz continuity and quadratic
boundedness. However, it is important to note that enforcing these
parameterizations globally can have limitations, which will also be discussed.

######  Assumption 1.

The function $f$ is Lipschitz continuous on $\mathcal{X}$. That is, there
exists $\ell\in\mathbb{R}_{\geq 0}$ such that, for every
$x,\hat{x}\in\mathcal{X}$,

$\|f(H\hat{x})-f(Hx)\|\leq\ell\|H(\hat{x}-x)\|.$ (7)

It is well-known that if $f$ is continuously differentiable, then $\ell$ can
be computed by solving the following nonlinear optimization problem

$\ell=\sup_{x\in\mathcal{X}}\left\|\frac{\partial f}{\partial x}(Hx)\right\|.$
(8)

######  Theorem 2 (Niazi & Johansson [5]).

Let Assumption 1 hold. If there exist a positive definite matrix
$P=P^{\intercal}\in\mathbb{R}^{n_{x}}$ and gain matrices
$J,L\in\mathbb{R}^{n_{x}\times n_{y}}$ and $K\in\mathbb{R}^{n_{h}\times
n_{y}}$ such that

$M^{\intercal}P+PM+PNGG^{\intercal}N^{\intercal}P+\ell^{2}(H-KC)^{\intercal}(H-KC)<0$
(9)

where $M,N$ are given in (4), then the estimation error $\xi(t)$ globally
asymptotically converges to zero, i.e.,
$\lim_{t\rightarrow\infty}\|\xi(t)\|=0$.

The algebraic Riccati inequality (ARI) (9) guarantees global asymptotic
stability of the error dynamics (5). To guarantee global exponential stability
under Lipschitz property, one can adapt (9) to

$(M+\alpha I_{n_{x}})^{\intercal}P+P(M+\alpha
I_{n_{x}})+PNGG^{\intercal}N^{\intercal}P+\ell^{2}(H-KC)^{\intercal}(H-KC)<0.$
(10)

for some $\alpha>0$. Moreover, note that both (9) and, given $\alpha>0$, (10)
can be equivalently represented as linear matrix inequalities using Schur
complement lemma.

######  Assumption 2.

The function $f$ is quadratically bounded on $\mathcal{X}$. That is, there
exists a positive definite matrix $Q\in\mathbb{R}^{n_{x}\times n_{x}}$ such
that, for every $x,\hat{x}\in\mathcal{X}$,

$\|f(H\hat{x})-f(Hx)\|^{2}\leq(\hat{x}-x)H^{\intercal}QH(\hat{x}-x).$ (11)

For general nonlinear functions $f$, finding a matrix $Q$ such that (11) holds
is a difficult problem. However, if $f$ is continuously differentiable, then
we can employ a method proposed by [14] to compute a diagonal
$Q=\mathrm{diag}(q_{1},\dots,q_{n_{x}})$ by solving the following nonlinear
optimization problem:

$q_{i}=\sup_{x\in\mathcal{X}}n_{x}\sum_{j=1}^{n_{x}}\left(\frac{\partial
f_{j}}{\partial x_{i}}(Hx)\right)^{2}.$ (12)

######  Theorem 3.

Let Assumption 2 hold. If there exist a positive definite matrix
$P=P^{\intercal}\in\mathbb{R}^{n_{x}}$ and gain matrices
$J,L\in\mathbb{R}^{n_{x}\times n_{y}}$ and $K\in\mathbb{R}^{n_{h}\times
n_{y}}$ such that

$M^{\intercal}P+PM+PNGG^{\intercal}N^{\intercal}P+(H-KC)^{\intercal}Q(H-KC)<0$
(13)

where $M,N$ are given in (4), then the estimation error $\xi(t)$ globally
asymptotically converges to zero, i.e.,
$\lim_{t\rightarrow\infty}\|\xi(t)\|=0$.

###### Proof.

The proof is similar to that of Theorem 2 in [5]. ∎

The Lipschitz continuity (7) and quadratic boundedness (11) parameterizations
bound the incremental change in the nonlinear function $f$ from above in terms
of the incremental change in its arguments. By enforcing these inequalities
over the whole state space $\mathcal{X}$, it turns out that the Lipschitz
constant $\ell$ and/or quadratic boundedness parameter $Q$ are very large.
This restricts the possibility to choose the gain matrices such that they
satisfy ARIs (9) and/or (13). For instance, in the case of (13), the
equivalent LMI feasibility problem is

$\displaystyle\left[\begin{array}[]{cc}\mathrm{sym}(PA-RCA-SC)+T&(P-RC)G\\\
&-I_{n_{x}}\end{array}\right]$ $\displaystyle<0$
$\displaystyle\left[\begin{array}[]{cc}-T&(H-KC)^{\intercal}\\\
&-Q^{-1}\end{array}\right]$ $\displaystyle\leq 0$

where $J=P^{-1}S$ and $L=P^{-1}R$. Notice that when the diagonal elements of
$Q$ computed by (12) are very large, $Q^{-1}$ will have very small values.
This will be compensated by having $T$ with very large eigenvalues in the
second inequality, which will result in the violation of the first inequality.

In [6], [20], and [9], other parameterization-based designs, such as the one-
sided Lipschitz property, quadratic inner boundedness, and bounded Jacobian,
are presented in the context of Luenberger-like observers. However, the design
criteria for one-sided Lipschitz and quadratic inner boundedness are found to
be quite conservative; see [5] for more details about these limitations.
Moreover, the design in [9] that uses a bounded Jacobian property of $f$ is
technically incorrect, as explained in [5]. Although [21] also uses a bounded
Jacobian property for designing a Luenberger-like observer with switching
observer gain, designing a switching signal remains an open problem. Finally,
the design using the dissipativity properties of $\tilde{f}(\eta,Hx)$ in [13]
results in nonlinear matrix inequality, which is difficult to solve
computationally.

In addition to the conservativeness of the parameterization-based observer
design criteria, finding parameterizations is also a difficult task for
general nonlinear functions, especially for non-differentiable functions.
Therefore, it is important to have observer design criteria that does not rely
on any specific parameterization of the system’s nonlinearity.

##  5 Parameterization-free Observer Design

In this section, we introduce an observer design that does not rely on any
parameterization of the nonlinearity $f$. This parameterization-free approach
allows us to establish design criteria without requiring any global properties
of $f$. Using this approach, we essentially treat the nonlinearity as an
external disturbance in the error equation (5). As a result, the goal of the
observer design is to stabilize the estimation error by effectively filtering
out the nonlinearity by tracking it.

######  Theorem 4.

If there exist positive definite matrices $P,Q\in\mathbb{R}^{n_{x}\times
n_{x}}$, a scalar $\rho\geq 0$, and gain matrices
$J,L\in\mathbb{R}^{n_{x}\times n_{y}}$ and $K\in\mathbb{R}^{n_{h}\times
n_{y}}$ such that

$\displaystyle\Phi+\Gamma^{\intercal}\Lambda\Gamma$ $\displaystyle\leq 0$
(14a) $\displaystyle\Lambda$ $\displaystyle\geq\rho I$ (14b)

where

$\displaystyle\Phi$
$\displaystyle=\left[\begin{array}[]{cc}M^{\intercal}P+PM+Q&PNG\\\
G^{\intercal}N^{\intercal}P&-\rho I_{n_{f}}\end{array}\right]$ (17)
$\displaystyle\Gamma$
$\displaystyle=\left[\begin{array}[]{cc}H-KC&0_{n_{h}\times n_{f}}\\\
0_{n_{f}\times n_{x}}&I_{n_{f}}\end{array}\right]$ (20)

with $M,N$ given in (4), then the estimation error $\xi(t)$ globally
asymptotically converges to zero.

###### Proof.

Note that $\eta(t)-Hx(t)=(H-KC)\xi(t)$ and, for every $\eta,Hx$ and every
$\Lambda\geq 0$, it holds that

$\left[\begin{array}[]{c}\eta-Hx\\\
\tilde{f}(\eta,Hx)\end{array}\right]^{\intercal}\Lambda\left[\begin{array}[]{c}\eta-
Hx\\\ \tilde{f}(\eta,Hx)\end{array}\right]=\left[\begin{array}[]{c}\xi\\\
\tilde{f}(\eta,Hx)\end{array}\right]^{\intercal}\Gamma^{\intercal}\Lambda\Gamma\left[\begin{array}[]{c}\xi\\\
\tilde{f}(\eta,Hx)\end{array}\right]\geq 0$ (21)

where $\xi(t)=\hat{x}(t)-x(t)$ is the estimation error, $\eta(t)$ is given in
(3b), $\tilde{f}(\eta,Hx)$ in (6), and $\Gamma$ in (20).

Let $V=\xi^{\intercal}P\xi$ be a candidate Lyapunov function. It satisfies
Lemma 1(i) because

$\lambda_{\min}(P)\|\xi(t)\|^{2}\leq\xi^{\intercal}(t)P\xi(t)\leq\lambda_{\max}(P)\|\xi(t)\|^{2}.$

To show Lemma 1(ii), we take its time derivative and add and subtract certain
terms on the right hand side

$\displaystyle\dot{V}$
$\displaystyle=(\xi^{\intercal}M+\tilde{f}^{\intercal}G^{\intercal}N^{\intercal})P\xi+\xi^{\intercal}P(M\xi+NG\tilde{f})$
$\displaystyle=\left[\begin{array}[]{c}\xi\\\
\tilde{f}\end{array}\right]^{\intercal}\left[\begin{array}[]{cc}M^{\intercal}P+PM&PNG\\\
G^{\intercal}N^{\intercal}P&0_{n_{f}\times
n_{f}}\end{array}\right]\left[\begin{array}[]{c}\xi\\\
\tilde{f}\end{array}\right]^{\intercal}\pm\xi^{\intercal}Q\xi\pm\rho\tilde{f}^{\intercal}\tilde{f}\pm\left[\begin{array}[]{c}\eta-
Hx\\\
\tilde{f}\end{array}\right]^{\intercal}\Lambda\left[\begin{array}[]{c}\eta-
Hx\\\ \tilde{f}\end{array}\right].$

Using (21), we obtain

$\displaystyle\dot{V}$
$\displaystyle=-\xi^{\intercal}Q\xi+\left[\begin{array}[]{c}\xi\\\
\tilde{f}\end{array}\right]^{\intercal}(\Phi+\Gamma^{\intercal}\Lambda\Gamma)\left[\begin{array}[]{c}\xi\\\
\tilde{f}\end{array}\right]+\left[\begin{array}[]{c}\eta-Hx\\\
\tilde{f}\end{array}\right]^{\intercal}(-\Lambda+\rho\mathcal{I})\left[\begin{array}[]{c}\eta-
Hx\\\ \tilde{f}\end{array}\right]$ (30)

where $\Phi$ is given in (17), $\Gamma$ in (20), and

$\mathcal{I}=\left[\begin{array}[]{cc}0&0\\\ 0&I_{n_{f}}\end{array}\right].$

Notice that if (14b) holds, then $-\Lambda+\rho\mathcal{I}\leq 0$ because
$\rho I\geq\rho\mathcal{I}$ for $\rho\geq 0$. Moreover, if (14a) holds as
well, then $\dot{V}\leq-\xi^{\intercal}Q\xi$. Since $Q>0$, we have
$\dot{V}<0$. Hence, by Lemma 1, the error equation (5) is (uniformly) globally
asymptotically stable, which concludes the proof. ∎

Note that by choosing some $\rho\geq 0$, substituting $R=PL$ and $S=PJ$, and
using Schur complement lemma we can obtain an LMI feasibility problem
equivalent to (14) as

$\boxed{P>0,\;Q>0,\;\left[\begin{array}[]{cc}\Phi&\Gamma^{\intercal}\\\
\Gamma&-\tilde{\Lambda}\end{array}\right]\leq
0,\;\tilde{\Lambda}\leq\frac{1}{\rho}I}$ (31)

where $\tilde{\Lambda}=\Lambda^{-1}$. In (17), $PM=PA-RCA-SC$ and $PN=P-RC$.
Then, the gain matrices are obtained as $J=P^{-1}S$ and $L=P^{-1}R$.

For the global exponential stability of (5), we can have the following
modifications to Theorem 4.

######  Corollary 4.1.

If the condition (14) is satisfied with $Q\geq\alpha P>0$, for some
$\alpha>0$, then the estimation error $\xi(t)$ globally exponentially
converges to zero.

###### Proof.

Assume (14) is satisfied, then (30) implies $\dot{V}\leq-\xi^{\intercal}Q\xi$.
If $Q\geq\alpha P$, then $\dot{V}\leq-\alpha V$. The result then follows from
Lemma 1. ∎

For a given $\alpha>0$, the LMI condition (31) can be obtained with
$Q\geq\alpha P$ instead of $Q>0$. However, $\alpha>0$ can be made a decision
variable in (31).

######  Corollary 4.2.

If the condition (14) is satisfied with $Q\geq\alpha I_{n_{x}}$ and $P\leq
I_{n_{x}}$, for some $\alpha>0$, then the estimation error $\xi(t)$ globally
exponentially converges to zero.

###### Proof.

Assume (14) is satisfied, then (30) implies $\dot{V}\leq-\xi^{\intercal}Q\xi$.
If $Q\geq\alpha I_{n_{x}}\geq P$, then
$\dot{V}\leq-\alpha\xi^{\intercal}\xi\leq-\alpha V$. Then, the proof is
concluded by Lemma 1. ∎

Using Corollary 4.2, the LMI condition (31) is modified by adding $\alpha>0$,
$Q\geq\alpha I$, and $0<P\leq I$.

In the next section, we demonstrate the effectiveness of parameterization-free
approach for the state estimation of networked SIR epidemic processes.

##  6 Application to a Networked SIR Epidemic Model

Consider a set of nodes $\mathcal{V}=\\{1,\dots,n\\}$ connected over a digraph
$\mathcal{G}=(\mathcal{V},\mathcal{E})$, where
$\mathcal{E}\subseteq\mathcal{V}\times\mathcal{V}$ is the set of edges. Every
node $i$ possesses a state
$(x_{\mathtt{S}}^{i}(t),x_{\mathtt{I}}^{i}(t),x_{\mathtt{R}}^{i}(t))$ that
represents the fraction of susceptible, infectious, and recovered individuals
in its population. An edge $(i,j)\in\mathcal{E}$ implies that the susceptible
population of node $i$ can be infected by the infectious population of node
$j$, where the weight of such a connection is determined by the infection rate
$\beta_{i}w_{ij}$, where $\beta_{i}>0$ is the infection susceptibility of $i$
and $w_{ij}>0$ is the contact rate of $i$ with $j$. The infectious population
of each node $i$ recovers with a recovery rate $\delta_{i}>0$.

Mathematically, the deterministic SIR epidemic process over $\mathcal{G}$ is
described by

$\displaystyle\dot{x}_{\mathtt{I}}^{i}$
$\displaystyle=(1-x_{\mathtt{I}}^{i}-x_{\mathtt{R}}^{i})\sum_{j=1}^{n}\beta_{i}w_{ij}x_{\mathtt{I}}^{j}-\delta_{i}x_{\mathtt{I}}^{i}$
(32a) $\displaystyle\dot{x}_{\mathtt{R}}^{i}$
$\displaystyle=\delta_{i}x_{\mathtt{I}}^{i}$ (32b)

where $x_{\mathtt{S}}^{i}(t)=1-x_{\mathtt{I}}^{i}(t)-x_{\mathtt{R}}^{i}(t)$.

Assume that $x_{\mathtt{R}}^{i}(t)$ is available through measurements at each
node $i$. Define $W=[w_{ij}]$ to be the weighted adjacency matrix of the
digraph $\mathcal{G}$, and let $B=\mathrm{diag}(\beta_{1},\dots,\beta_{n})$
and $D=\mathrm{diag}(\delta_{1},\dots,\delta_{n})$. Let
$x(t)=[\begin{array}[]{cc}x_{\mathtt{I}}(t)^{\intercal}&x_{\mathtt{R}}(t)^{\intercal}\end{array}]^{\intercal}$
with
$x_{\mathtt{I}}(t)=[\begin{array}[]{ccc}x_{\mathtt{I}}^{1}(t)&\dots&x_{\mathtt{I}}^{n}(t)\end{array}]^{\intercal}$
and
$x_{\mathtt{R}}(t)=[\begin{array}[]{ccc}x_{\mathtt{R}}^{1}(t)&\dots&x_{\mathtt{R}}^{n}(t)\end{array}]^{\intercal}$,
then (32) can be written as (1) with

$\displaystyle A$ $\displaystyle=\left[\begin{array}[]{cc}BW-D&0_{n\times
n}\\\ D&0_{n\times n}\end{array}\right],\;G=\left[\begin{array}[]{c}-I_{n}\\\
0_{n\times n}\end{array}\right],\;H=I_{2n}$ $\displaystyle C$
$\displaystyle=\left[\begin{array}[]{cc}0_{n\times n}&I_{n}\end{array}\right]$

and
$f(Hx)=\mathrm{diag}(x_{\mathtt{I}}(t)+x_{\mathtt{R}}(t))BWx_{\mathtt{I}}(t)$.
The pair $(A,C)$ is observable if the recovery rates $\delta_{i}$ are
distinct.

Figure 1: Bidirected graph $\mathcal{G}$ considered for the simulation
example.

We consider the number of nodes to be $n=10$. We generate a random bidirected
graph $\mathcal{G}$ hown in Fig. 1 with the probability of edge between each
pair of nodes equal to $0.5$, where the edge weight $w_{ij}$ is chosen in the
interval $(0,2)$ uniformly randomly. Each node has a self-loop indicating
infection spread within its population. The parameters $\beta_{i}$ and
$\delta_{i}$ are also chosen uniformly randomly from $(0,1)$ for each
$i=1,\dots,n$. For 100 realizations of random bidirected graphs, we found that
the Lipschitz constant $\ell$ of nonlinearity $f(Hx)$ ranges from $7.5$ to
$25.6$, which makes the Lipschitz-based design criterion (9) infeasible given
that $\ell^{2}$ would be very large. Therefore, in this case, the
parameterization-free design criterion (14) is preferable.

Choosing $\rho=1$, we use SeDuMi [22] in MATLAB to solve the LMI (31) and
obtain the observer gain matrices $J,K,L$. Then, after using (4) to obtain
matrices $M$ and $N$, the observer (3) is initialized as $z(0)=-Ly(0)$. The
measurement output $y(t)$ is assumed to be corrupted by a noise
$v(t)\sim\mathcal{N}(0_{n_{y}},0.001I_{n_{y}})$. The state estimation of each
node is illustrated in Fig. 3, where it is important to point out that our
observer is capable of handling the noise effectively in the estimation. The
norm of the estimation error is plotted in Fig. 2.

Figure 2: Norm of the estimation error. Figure 3: Epidemic state estimation in
each node of the bidirected graph $\mathcal{G}$ depicted in Fig. 1.

##  7 Concluding Remarks

We proposed a novel parameterization-free observer design approach for state
estimation of nonlinear systems. We demonstrated that traditional methods
relying on parameterized inequalities of the nonlinearity can lead to
unnecessarily conservative observer design criteria when the parameterization
is enforced globally. In contrast, our proposed approach makes no assumptions
about the system’s nonlinearity, rendering it parameterization-free.

We established observer design criteria that guarantee both asymptotic and
exponential convergence of the estimation error to zero by treating the
nonlinearity as an unknown disturbance in the estimation error dynamics, where
the goal of the observer is to track not only the state but also the
nonlinearity of the system. We also demonstrated the effectiveness of our
approach by using it for the state estimation of a networked SIR epidemic
model. This application is particularly important, as state estimation of
epidemic models is crucial, and traditional parameterized methods become
infeasible due to the quadratic nature of the nonlinearity.

Our proposed parameterization-free approach offers a promising alternative to
traditional observer design methods and has the potential to be applied to a
wide range of nonlinear systems. In conclusion, this work presents a
significant contribution to the field of observer design for nonlinear systems
and opens up new possibilities for state estimation in various applications.
The future work includes a systematic method to handle process and measurement
noises in the nonlinear system.

## References

  * [1] F. Thau, “Observing the state of non-linear dynamic systems,” _International Journal of Control_ , vol. 17, no. 3, pp. 471–479, 1973.
  * [2] R. Rajamani, “Observers for Lipschitz nonlinear systems,” _IEEE Transactions on Automatic Control_ , vol. 43, no. 3, pp. 397–401, 1998.
  * [3] A. Zemouche and M. Boutayeb, “On LMI conditions to design observers for Lipschitz nonlinear systems,” _Automatica_ , vol. 49, no. 2, pp. 585–591, 2013.
  * [4] A. Alessandri and F. Boem, “State observers for systems subject to bounded disturbances using quadratic boundedness,” _IEEE Transactions on Automatic Control_ , vol. 65, no. 12, pp. 5352–5359, 2020.
  * [5] M. U. B. Niazi and K. H. Johansson, “Observer design for the state estimation of epidemic processes,” in _2022 IEEE 61st Conference on Decision and Control (CDC)_ , 2022, pp. 4325–4332.
  * [6] M. Abbaszadeh and H. J. Marquez, “Nonlinear observer design for one-sided Lipschitz systems,” in _Proceedings of the 2010 American Control Conference_ , 2010, pp. 5284–5289.
  * [7] Y. Zhao, J. Tao, and N.-Z. Shi, “A note on observer design for one-sided Lipschitz nonlinear systems,” _Systems & Control Letters_, vol. 59, no. 1, pp. 66–71, 2010.
  * [8] M. Benallouch, M. Boutayeb, and M. Zasadzinski, “Observer design for one-sided Lipschitz discrete-time systems,” _Systems & Control Letters_, vol. 61, no. 9, pp. 879–886, 2012.
  * [9] G. Phanomchoeng, R. Rajamani, and D. Piyabongkarn, “Nonlinear observer for bounded Jacobian systems, with applications to automotive slip angle estimation,” _IEEE Transactions on Automatic Control_ , vol. 56, no. 5, pp. 1163–1170, 2011.
  * [10] A. M. Tahir and B. Açıkmeşe, “Synthesis of interval observers for bounded Jacobian nonlinear discrete-time systems,” _IEEE Control Systems Letters_ , vol. 6, pp. 764–769, 2021.
  * [11] D. Šiljak and D. M. Stipanovic, “Robust stabilization of nonlinear systems: The LMI approach,” _Mathematical Problems in Engineering_ , vol. 6, no. 5, pp. 461–493, 2000.
  * [12] M. Arcak and P. Kokotović, “Nonlinear observers: A circle criterion design and robustness analysis,” _Automatica_ , vol. 37, no. 12, pp. 1923–1930, 2001.
  * [13] J. A. Moreno, “Observer design for nonlinear systems: A dissipative approach,” in _IFAC Proceedings Volumes_ , vol. 37, no. 21, 2004, pp. 681–686, 2nd IFAC Symposium on System Structure and Control, Oaxaca, Mexico, December 8-10, 2004.
  * [14] S. A. Nugroho, A. Taha, and V. Hoang, “Nonlinear dynamic systems parameterization using interval-based global optimization: Computing Lipschitz constants and beyond,” _IEEE Transactions on Automatic Control_ , vol. 67, no. 8, pp. 3836–3850, 2021.
  * [15] W. Mei, R. Ushirobira, and D. Efimov, “On nonlinear robust state estimation for generalized Persidskii systems,” _Automatica_ , vol. 142, p. 110411, 2022.
  * [16] P. Bernard, V. Andrieu, and D. Astolfi, “Observer design for continuous-time dynamical systems,” _Annual Reviews in Control_ , vol. 53, pp. 224–248, 2022\.
  * [17] D. Boutat and G. Zheng, _Observer Design for Nonlinear Dynamical Systems_. Springer, 2021.
  * [18] D. G. Luenberger, “An introduction to observers,” _IEEE Transactions on Automatic Control_ , vol. 16, no. 6, pp. 596–602, 1971.
  * [19] S. Sastry, _Nonlinear Systems: Analysis, Stability, and Control_. Springer New York, NY, 1999.
  * [20] W. Zhang, H. Su, H. Wang, and Z. Han, “Full-order and reduced-order observers for one-sided Lipschitz nonlinear systems using Riccati equations,” _Communications in Nonlinear Science and Numerical Simulation_ , vol. 17, no. 12, pp. 4968–4977, 2012.
  * [21] R. Rajamani, W. Jeon, H. Movahedi, and A. Zemouche, “On the need for switched-gain observers for non-monotonic nonlinear systems,” _Automatica_ , vol. 114, p. 108814, 2020.
  * [22] J. F. Sturm, “Using SeDuMi 1.02: A MATLAB toolbox for optimization over symmetric cones,” _Optimization Methods and Software_ , vol. 11, no. 1-4, pp. 625–653, 1999.