Access to this full-text is provided by Springer Nature.
Content available from Social Network Analysis and Mining
This content is subject to copyright. Terms and conditions apply.
Vol.:(0123456789)
1 3
Social Network Analysis and Mining (2020) 10:50
https://doi.org/10.1007/s13278-020-00664-5
ORIGINAL ARTICLE
Comparing temporal graphs using dynamic time warping
VincentFroese1· BrijneshJain2· RolfNiedermeier1· MalteRenken1
Received: 27 February 2020 / Revised: 30 May 2020 / Accepted: 4 June 2020 / Published online: 29 June 2020
© The Author(s) 2020
Abstract
Within many real-world networks, the links between pairs of nodes change over time. Thus, there has been a recent boom
in studying temporal graphs. Recognizing patterns in temporal graphs requires a proximity measure to compare different
temporal graphs. To this end, we propose to study dynamic time warping on temporal graphs. We define the dynamic tem-
poral graph warping (dtgw) distance to determine the dissimilarity of two temporal graphs. Our novel measure is flexible
and can be applied in various application domains. We show that computing the dtgw-distance is a challenging (in general)
NP-hard optimization problem and identify some polynomial-time solvable special cases. Moreover, we develop a quadratic
programming formulation and an efficient heuristic. In experiments on real-world data, we show that the heuristic performs
very well and that our dtgw-distance performs favorably in de-anonymizing networks compared to other approaches.
Keywords Temporal graph matching· Vertex signatures· Heuristic optimization· Quadratic programming· Parameterized
algorithms
1 Introduction
A fundamental concept for pattern recognition is the notion
of proximity (i.e., (dis)similarity) between objects. For
objects that are represented by numerical feature vectors,
there exist a lot of well-known proximity measures such as
p-norms or positive semi-definite kernels. In structural pat-
tern recognition, objects are often more naturally represented
by complex (discrete) data structures such as graphs, strings,
or time series. For these representations, one can often not
simply use vector-based proximity measures. Instead, one
needs to define suitable domain-specific proximity measures
such as the edit distance on graphs or strings or the dynamic
time warping distance1 on time series.
The majority of graph proximity measures focus on static
graphs. This includes the graph edit distance (Riesen 2015),
graph kernels (Kriege etal. 2020), and geometric graph dis-
tances (Jain 2016). However, many complex systems are not
static as the links between entities dynamically change over
time. Thus, there is a steadily growing research interest in ana-
lyzing temporal graphs (we also use the term temporal network
interchangeably) (Rozenshtein and Gionis 2019; Holme and
Saramäki 2013, 2019). Such temporal graphs can be repre-
sented by a series of temporal edges between a fixed set of
vertices. Examples are social contact networks, disease spread-
ing networks, traffic networks, attack networks in computer
security, or protein–protein interaction networks in biology
(Kostakos 2009; Holme and Saramäki 2013, 2019; Li etal.
2017; Vijayan etal. 2017). Examples of data mining problems
on temporal social networks include community detection
(Dakiche etal. 2019), epidemics analysis (Rozenshtein etal.
2016), and influence spreading (Gayraud etal. 2015).
An extended abstract of this article appeared in the Proceedings of
the 8th International Conference on Complex Networks and their
Applications, Springer, SCI, vol 882, pp. 469–480, 2019 (Froese
etal. 2019). This article contains all proofs in full detail and
presents extended experimental results.
* Malte Renken
m.renken@tu-berlin.de
Vincent Froese
vincent.froese@tu-berlin.de
Brijnesh Jain
brijnesh.jain@dai-labor.de
Rolf Niedermeier
rolf.niedermeier@tu-berlin.de
1 Faculty IV, Algorithmics andComputational Complexity,
Technische Universität Berlin, Berlin, Germany
2 Faculty IV, Distributed Artificial Intelligence Laboratory,
Technische Universität Berlin, Berlin, Germany
1 Note that a distance function is not required to obey the triangle
inequality, in contrast to a metric.
Content courtesy of Springer Nature, terms of use apply. Rights reserved.
Social Network Analysis and Mining (2020) 10:50
1 3
50 Page 2 of 16
Many processes described by temporal graphs naturally
vary in duration and temporal dynamics (for example, chem-
ical reactions or the spread of a disease might proceed at
different speeds), which makes data mining tasks such as
classification challenging. Hence, one needs to find suitable
proximity measures, which has seemingly not been done
so far.
Our paper proposes such a measure. We introduce a novel
proximity measure on temporal graphs based on vertex sig-
nature graph distance and dynamic time warping, called
dynamic temporal graph warping (dtgw). Dynamic time
warping allows to cope with variations in temporal dynam-
ics. Thus, by combining established methods from graph-
based pattern recognition and time series data mining in a
nontrivial way, we obtain a suitable tool to analyze temporal
network data. We study the computational complexity of the
dtgw-distance, develop efficient algorithms and study their
behavior on real-world data, the latter indicating the strong
potential for future applications.
Related Work. Graph distance based on vertex mappings
using local vertex signatures was introduced byJouili and
Tabbone (2009). The idea of using vertex mappings can also
be found in optimal assignment kernels (Fröhlich etal. 2005;
Kriege etal. 2016; Bento and Ioannidis 2018).
Regarding proximity measures on temporal graphs, seem-
ingly little work has been done so far. In fact, we are not
aware of other approaches for numerically measuring the
proximity of two temporal graphs. Related concepts, how-
ever, have been investigated for temporal graphs. For exam-
ple, one approach is based on network embeddings where
nodes are mapped onto certain feature spaces incorporat-
ing the temporal behavior (Ahmed and Karypis 2015; Zuo
etal. 2018; Nguyen etal. 2018). Another approach is based
on network alignments (Vijayan etal. 2017; Elhesha etal.
2019) where a vertex mapping that optimizes some criteria
is computed. However, dynamic time warping has not been
used in this context so far.
Dynamic time warping (Sakoe and Chiba 1978) is an
established measure for mining time series data (Rakthan-
manon etal. 2012; Wang etal. 2013) which is specifically
designed to cope with temporal distortion in the data via
nonlinear alignment of time series. It can be applied to time
series of different lengths (in contrast to the Euclidean dis-
tance for example) which is a relevant aspect in time series
averaging. We lift this approved concept to the domain of
temporal graphs.
Our Contributions. We define the dynamic temporal
graph warping (dtgw) distance as a twofold discrete minimi-
zation problem involving computation of an optimal vertex
mapping and an optimal “warping path” (see Sect.3). As
a by-product, our approach does not only yield a distance
measure but also yields an interpretable mapping between
vertices of the two temporal graphs which can, for example,
be used for de-anonymization of individuals in social
networks.
We show that the dtgw-distance is NP-hard to compute
in general(Theorem1). In contrast, we point out several
polynomial-time solvable special cases. This includes the
case when either a vertex mapping or a temporal alignment
is fixed (Observation 1), the case of deciding whether the
dtgw-distance is zero (Theorem2), and the case when the
lifetimes of the two temporal graphs differ only by a constant
and the warping path length is restricted (Proposition 3).
Moreover, we give a quadratic programming formulation
(Sect.5.2) and propose an efficient and effective heuristic
approach (Sect.5.3).
We empirically evaluate the heuristic2 in preliminary
experiments on real-world temporal social networks (face-
to-face contact and spatial proximity networks) against the
quadratic program and some simple baseline methods to
show its efficiency and solution quality. Moreover, we dem-
onstrate that our concept can successfully be used for de-
anonymization of real-world temporal social networks and is
faster than other existing methods such as DynaMAGNA++
(Vijayan etal. 2017) or HTNE (Zuo etal. 2018) (Sect.6).
Compared to the conference version (Froese etal. 2019),
this version contains the NP-hardness proof of Theorem1,
the proof ofProposition 3, and the quadratic programming
formulation (Sect.5.2). Moreover, we present additional
experimental results including a comparison of the heuris-
tic with the quadratic program (Sect.6.2) and a clustering
experiment to demonstrate robustness with respect to noisy
data (Sect.6.3).
Organization. Section2 contains basic definitions. Sec-
tion3 presents our main definition of the dtgw-distance fol-
lowed by NP-hardness results in Sect.4 and positive algo-
rithmic results in Sect.5. Section6 presents experimental
results on some real-world data. We conclude in Sect.7 with
an outlook on future applications and challenges.
2 Preliminaries
For
T∈ℕ
, we define
[T] ∶= {1, 2, …,T}
.
Temporal Graphs. A temporal graph
G=(V,E1,E2,…,ET)
consists of a vertex setV and a
sequence of
T≥1
edge sets
Ei
, each being a set of unor-
dered vertex pairs. By
Gi=(V,Ei)
, we denote the
ith
layer
of
G
and we callT the lifetime of
G
. The underlying graph
of
G
is the graph
(
V,
⋃T
i=1
E
i)
. We remark that all definitions
and results in this work can easily be extended to labeled
temporal graphs (with vertex and/or edge labels).
2 An implementation is freely available at www.akt.tu-berli n.de/
menue /softw are.
Content courtesy of Springer Nature, terms of use apply. Rights reserved.
Social Network Analysis and Mining (2020) 10:50
1 3
Page 3 of 16 50
Vertex Mapping. A vertex mapping between two vertex
sets V and W is a set
M⊆V×W
containing
min(|V|,|W|)
tuples such that each
x∈V∪W
is contained in at most
one tuple ofM. We denote the set of all vertex mappings
betweenV andW by
M(V,W)
. Let
VM⊆V
be the subset of
vertices inV that are contained in some tuple ofM (
WM⊆W
is defined analogously). Note that
VM=V
or
WM=W
holds
since
|M|=min(|V|,|W|)
.
Assign ment Proble m
. Computing optimal vertex map-
pings between two temporal graphs can be solved via the
Assignment Problem
which is a fundamental problem in
combinatorial optimization. Given two setsA andB of equal
size and a cost function
c∶A×B
→
ℚ
, the goal is to find a
bijection
𝜋∶A→B
such that
∑a∈A
c
(
a,𝜋
(
a
))
is minimized.
It is well known that the
Assignment Prob lem
is solvable
in
O(|A|3)
time (Ahuja etal. 1993,Theorem12.2).
Dynamic Time Warping. The dynamic time warping dis-
tance (Sakoe and Chiba 1978) is a distance between time
series. It is based on the concept of a warping path. A warp-
ing path of order
n×m
is a set
p={p1,…,pL}
of
L≥1
pairs
p𝓁=(i𝓁,j𝓁)
such that
•
p1=(1, 1)
and
pL=(n,m)
, and
•
p
𝓁
+1∈ {(i
𝓁
+1, j
𝓁
+1),(i
𝓁
,j
𝓁
+1),(i
𝓁
+1, j
𝓁
)}
f o r
all
1≤𝓁<L
.
We denote the set of all warping paths of order
n×m
by
Pn,m
. For two temporal graphs
G=(V,E1,…,ET)
,
H=(W,F1,…,FU)
, every order-
(T×U)
warping pathp
defines a warping between
G
and
H
, that is, a pair
(i,j)∈p
warps layer
Gi
to layer
Hj
.
Parameterized Complexity. We assume the reader to be
familiar with basic concepts of computational complexity
theory such as NP-completeness (Garey and Johnson 1979).
In parameterized complexity theory (Downey and Fellows
2013; Cygan etal. 2015), one considers running times with
respect to two dimensions. One dimension is the size of the
input instancex, and the other dimension is a parameterk
(usually a numerical value). An instance of a parameterized
problem is a pair(x,k). The class XP contains all param-
eterized problems that can be solved in polynomial time for
every constant parameter value, that is, in
|x|f(k)
time for
some functionf only depending onk.
3 Dynamic temporal graph warping (DTGW)
In this section, we define our temporal graph distance
based on dynamic time warping using a vertex-signature-
based graph distance as cost function. We choose this graph
distance for the following reasons. First, in contrast to the
NP-hard edit distance, it is polynomial-time computable.
Second, it is based on a mapping between the two vertex
sets which allows to enforce a consistency over time. This
consistency assumption is useful in many temporal network
applications where the vertices in both networks correspond
to the same set of objects over time. This implicitly allows
to identify vertices within the two networks. Third, vertex
signatures allow for a high flexibility since they can be cho-
sen arbitrarily in order to incorporate essential information
(local or global) for the application at hand (e.g., one might
use feature vectors obtained via network embedding).
Graph Distance Based on Vertex Signatures.
The following approach is due to Jouili and Tabbone
(2009). For a (static) graph
G=(V,E)
, a vertex signature
function f
G
∶V→ℚ
k
encodes arbitrary information about
a vertex. Let
d∶ℚk×ℚk→ℚ
be a metric.
For two (static) graphs
G=(V,E)
and
H=(W,F)
with
vertex signatures
fG∶V
→ℚ
k
and
fH∶W
→ℚ
k
and a
given vertex mappingM betweenV andW, we define the
cost ofM as
where
𝛥G(v)∈ℚ
is the (predefined) cost of “deleting” ver-
texv fromG since it is not mapped byM to any vertex in the
other vertex set. The value
𝛥G(v)
might, for example, depend
on the vertex signature ofv. Note that “deleting” a vertex
does not affect the signatures of other vertices. Note also
that one of the last two sums on the right-hand side above
is always zero.
The vertex-signature-based distance betweenG andH is
then defined as
Depending on the application, one might normalize the
distanceD by some appropriate factor (typically depending
on|V| and|W|; e.g., Jouili and Tabbone (2009) normalized
by
min(|V|,|W|)−1
).
Throughout this work, we assume that vertex signature
functions
fG
are computable in polynomial time in the size
ofG and we assume all metrics
d
to be polynomial-time
computable. In the rest of the paper, we neglect the run-
ning times for computing the values of
fG
and
d
because we
assume that all vertex signatures are precomputed once in
polynomial time.
Dynamic Time Warping Distance for Temporal Graphs.
We transfer the concept of dynamic time warping to tem-
poral graphs in the following way. Let
G=(V,E1,…,ET)
and
H=(W,F1,…,FU)
be two temporal graphs, and let
f
G1
,…,f
GT
∶V→ℚ
k
and f
H1
,…,f
HU
∶W→ℚ
k
be the cor-
responding vertex signature functions.
We then define the vertex-signature-based dynamic tem-
poral graph warping distance (dtgw-distance) between
G
and
H
as
C
(G,H,M) ∶=
∑
(u,v)∈M
d
(
fG(u),fH(v)
)
+
∑
v∈V⧵V
M
𝛥G(v)+
∑
v∈W⧵W
M
𝛥H(v)
,
D(G,H) ∶= min
M∈M(V,W)
C(G,H,M).
Content courtesy of Springer Nature, terms of use apply. Rights reserved.
Social Network Analysis and Mining (2020) 10:50
1 3
50 Page 4 of 16
Figure1 depicts an example illustrating the dtgw-
distance of two temporal graphs. Intuitively, the vertex
mapping identifies vertices with similar behavior over
time and the warping path identifies the time layers with
similar vertex behavior. Note that (for
T=U)
if one fixes
p= {(1, 1),(2, 2),…,(T,T)}
, then we get a temporal graph
distance without time warping (similar to the Euclidean
distance).
The following results are easily observed and play a
central role for our subsequent algorithms.
Observation 1 Let
G=(V,E1,…,ET)
and
H=(W,F1,…,FU)
be two temporal graphs with
|V|≤|W|=∶ n
.
1. For a fixed vertex mapping
M∈M(V,W)
, a warping
path
p∈PT,U
which minimizes
∑(i,j)∈p
C
(
Gi,Hj,M
)
can
be computed in
O(T⋅U⋅n)
time.
2. For a fixed warping path
p∈PT,U
, a vertex map-
ping
M∈M(V,W)
which minimizes
∑(i,j)∈p
C(G
i
,H
j
,M
)
can be computed in
O(n2
⋅
|p|+n3)
time.
Proof i)For a given vertex mappingM, an optimal warp-
ing path can be computed by a well-known dynamic pro-
gram for dynamic time warping in
O(T
⋅
U
⋅
n)
time (Sakoe
and Chiba 1978). Here,
O(n)
is the time for computing the
costs
C(Gi,Hj,M)
. Note that faster dynamic time warping
algorithms for special cases are known (Abboud etal. 2015;
Gold and Sharir 2018; Kuszmaul 2019; Froese etal. 2020).
dtgw
(G,H) ∶= min
M∈M(V,W)min
p∈PT,U
∑
(i,j)∈p
C(Gi,Hj,M)
.
ii) Let
V�∶= V∪Q
, where Q is a set of
|W|−|V|
dummy vertices (that is,
|V�|=n
) with
Q∩V=�
. For
every
(u,v)∈V�×W
, let
Then, we need to find a vertex mapping
M∈
M
(V�
,W)
that minimizes
∑(u,v)∈M
𝜎
(
u,v
)
. Note thatM defines a bijec-
tion between
V′
andW. Hence, computingM is an
Assign
-
ment Problem
instance solvable in
O(n3)
time (Ahuja etal.
1993,Theorem12.2). Computing all
𝜎(u,v)
values can be
done in
O(n2
⋅
|p|)
time.
◻
Note that Observation 1i) implies that if we already know
the vertex mapping up to a constant number of vertices, then
dtgw
can be computed in polynomial time (since we can
try out all polynomially many possible vertex mappings).
Furthermore, Observation 1ii) implies that
dtgw
is poly-
nomial-time computable if the optimal temporal alignment
between
G
and
H
is known beforehand. In particular,
dtgw
can be computed in polynomial time if one temporal graph
has a constant lifetime or a constant number of vertices since
there are only polynomially many possible warping paths or
polynomially many vertex mappings.
Corollary 1 The dtgw-distance between two temporal
graphs can be computed in polynomial time if at least one
of the following applies:
1. The vertex mapping is known up to a constant number
of vertices.
2. The warping path is known.
𝜎
(u,v) ∶=
(i,j)∈pd
fGi(u),fHj(v)
,u∈V
(i,j)∈p𝛥Hj(v),u∈Q
.
G
1
G
2
G
3
G
5
G
6
H1H2H3H4
200224
H5
2
G
4
G
H
Fig. 1 Example of the dtgw-distance between two tempo-
ral graphs
G
and
H
on four vertices with lifetimes six and five.
The vertex coloring indicates an optimal vertex mapping M.
The connections between the boxes indicate an optimal warp-
ing path
p= {(1, 1),(2, 1),(3, 2),(3, 3),(4, 4),(5, 5),(6, 5)}
.
Their labels correspond to the costs
C(Gi,Hj,M)
where the ver-
tex signatures are the degrees and the metric is the absolute
value of the difference. For example, the cost of warping
G1
to
H1
is 2, as the green and yellow vertex each have degree two
in
G1
but only degree one in
H1
. The resulting dtgw-distance is
dtgw (G,H)=2+0+0+2+2+2+4=12
Content courtesy of Springer Nature, terms of use apply. Rights reserved.
Social Network Analysis and Mining (2020) 10:50
1 3
Page 5 of 16 50
3. At least one of the temporal graphs has a constant life-
time or a constant number of vertices.
For given vertex signature function and metric, we refer
to the decision problem of testing whether two temporal
graphs have dynamic temporal graph warping distance at
most some given valuec by DtgW .
4 Computational hardness
Even though the dynamic time warping distance and the
vertex-signature-based graph distance are both computable
in polynomial time, their combined application to temporal
graphs yields a distance measure that is generally NP-hard
to compute. Intuitively, this is due to the fact that the vertex
mapping has to be consistent for all layers. This introduces
non-trivial dependencies between the time warping and the
vertex mapping which render the problem computationally
hard. Indeed, this is not a singular case for temporal graph
problems where for many cases the temporal counterparts
of problems solvable in polynomial time turn NP-hard;
examples include the computation of matchings in graphs
(Heeger etal. 2019; Baste etal. 2020; Mertzios etal. 2020),
short path computations (Casteigts etal. 2019; Fluschnik
etal. 2020), or the computation of separators (Zschoche
etal. 2020).
Theorem1 DtgW is NP -complete for every metric when
the vertex signatures are vertex degrees.
Proof DtgW is clearly contained in NP since for a given
vertex mapping and warping path (both having polynomial
size), one can check in polynomial time whether the
dtgw
-distance is at mostc (also see Observation 1).
To show NP-hardness, we give a polynomial-time many-
one reduction from the NP-complete
3
-sAt problem. Let
d∶ℚ×ℚ→ℚ
be any metric, and let
𝜙=C1∧…∧Cm
be
an instance of
3
-sAt over the variables
x1,…,xn
. Each
clause
Cj
is then a disjunction of three literals
C
j=∶ 𝓁
1
j
∨𝓁
2
j
∨𝓁
3
j
, and there is a function
𝜈∶[m]×[3]
→
[n]
such that
𝓁i
j
∈{x𝜈(j,i)},x
𝜈(j,i)
holds for all
𝓁i
j
.
Without loss of generality, we assume
m>8
.
The idea is to represent each literal by a vertex which
can be mapped to either
⊤
(true) or
⊥
(false). We then
build, for each clause, a clause box gadget consisting of three
consecutive layers. The choice of a warping path will then,
for each clause, implicitly select one of its literals, and the
D
YNAMIC
T
EMPORAL
G
RAPH
W
ARPING
(DTGW)
𝐈𝐧𝐩𝐮𝐭 ∶Two temporal graphs Gand H,c∈ℚ
.
𝐐𝐮𝐞𝐬𝐭𝐢𝐨𝐧 ∶Is dtgw (
G
,
H
)≤c?
costs caused by each clause box will attain their minimum
value if and only if that particular literal is mapped to
⊤
.
Now, a detailed description of the reduction follows. Let
D and
D′
be two copies of the graph
∐22m
i=1
K
2
(consisting
of 22m disjoint edges), where for each vertex
v∈V(D)
we
denote its copy in
V(D�)
by
v′
. We construct two temporal
graphs
G
and
H
. Their vertex sets each contain
2n+47m+8
vertices as follows:
Both temporal graphs have
2n+26m
layers defined as fol-
lows. For each
i∈[n]
, we set
For
j∈[m]
, we set
and
Finally, for
j∈[22m]
, we set
We call the layers containing
|E(D)|
edges separation lay-
ers. Furthermore, for each
j∈[m]
we say that the layers
2n+4j−3
,
2n+4j−2
, and
2n+4j−1
form the clause
block corresponding to
Cj
(see Fig.2 for an example). Let
c∶= 42m⋅d(0, 1)
.
We claim that
dtgw (G,H)≤c
if and only if
𝜙
has a sat-
isfying truth assignment.
“
⇐
”: Given a satisfying assignment
𝛽∶{
x
1,…,
x
n}
→
{
𝚝𝚛𝚞𝚎
,
𝚏𝚊𝚕𝚜𝚎
}
of
𝜙
, we define the fol-
lowing vertex mapping:
V(G) ∶= {xi,xi;i∈[n]}∪{C
1
j,C
2
j,C
3
j∶j∈[m]} ∪ {Xi,Yi;i∈[4]}
∪V(D),
V
(H) ∶= {⊤i,⊥i∶i∈[n]} ∪ {C�1
j,C�2
j,C�3
j∶j∈[m]} ∪ {X�
i,Y�
i∶i∈[4
]}
∪V(D
�
).
E(G
2i−1
) ∶= {{x
i
,x
i
}},E(H
2i−1
) ∶= {{⊤
i
,⊥
i
}},
E(G2i) ∶= E(D),E(H2i) ∶= E(D
�
).
E(G
2n+4j−3
) ∶= {{X
i
,Y
i
};i∈[4]},
E
(G2n+4j−2) ∶= {{Ci
j,𝓁i
j};i∈[3]}
,
E
(G2n+4j−1) ∶= {{Xi,Yi};i∈[4]}
,
E(G
2n+4j
) ∶= E(D),
E
(H2n+4j−3) ∶= {{C
�1
j,⊤𝜈(j,1)},{⊤𝜈(j,2),⊥𝜈(j,2)},{⊤𝜈(j,3),⊥𝜈(j,3)},{C
�2
j,C
�3
j}}
,
E
(H2n+4j−2) ∶= {{C�2
j,⊤𝜈(j,2)},{⊤𝜈(j,1),⊥𝜈(j,1)},{⊤𝜈(j,3),⊥𝜈(j,3)},{C�1
j,C�3
j}}
∪ {{X�
i,Y�
i};i∈[4]},
E
(H2n+4j−1) ∶= {{C�3
j,⊤𝜈(j,3)},{⊤𝜈(j,1),⊥𝜈(j,1)},{⊤𝜈(j,2),⊥𝜈(j,2)},{C�1
j,C�2
j}}
,
E(H2
n+
4
j
)∶=E(D�).
E(G
2n+4m+j
) ∶= {{X
k
,Y
k
}∶k∈[4]},
E
(H
2n+4m+j
) ∶= {{X�
k
,Y�
k
}∶k∈[4]}
.
Content courtesy of Springer Nature, terms of use apply. Rights reserved.
Social Network Analysis and Mining (2020) 10:50
1 3
50 Page 6 of 16
Fig. 2 Clause block for
Cj=x𝛼∨x𝛽∨x𝛾
. Only relevant
vertices are shown in each layer
X1Y1
G2n+4j−3
G2n+4j−2
G2n+4j−1
H2n+4j−3
H2n+4j−2
H2n+4j−1
X2Y2
X3Y3
X4Y4
C1
j
C2
j
C3
j
xα
xβ
xγ
X
1Y
1
X
2Y
2
X
3Y
3
X
4Y
4
C1
j
C2
j
C3
j
α
β
γ
⊥α
⊥β
⊥γ
X1Y1
X2Y2
X3Y3
X4Y4
C1
j
C2
j
C3
j
xα
xβ
xγ
X1Y1
X2Y2
X3Y3
X4Y4
C1
j
C2
j
C3
j
xα
xβ
xγ
C1
j
C2
j
C3
j
α
β
γ
⊥α
⊥β
⊥γ
C1
j
C2
j
C3
j
α
β
γ
⊥α
⊥β
⊥γ
X
1Y
1
X
2Y
2
X
3Y
3
X
4Y
4
X
1Y
1
X
2Y
2
X
3Y
3
X
4Y
4
G2n+4j−3
G2n+4j−2
G2n+4j−1
H2n+4j−3
H2n+4j−2
H2n+4j−1
16 ·d(0,1)
16 ·d(0,1)
8·d(0,1)
2·d(0,1)
(
a
)
G2n+4j−3
G2n+4j−2
G2n+4j−1
H2n+4j−3
H2n+4j−2
H2n+4j−1
16 ·d(0,1)
16 ·d(0,1)
10 ·d(0,1)
(
b
)
G2n+4j−3
G2n+4j−2
G2n+4j−1
H2n+4j−3
H2n+4j−2
H2n+4j−1
16 ·d(0,1)
16 ·d(0,1)
8·d(0,1)
2·d(0,1)
(
c
)
Fig. 3 The three possible warpings between layers of a clause block. Each edge is labeled with the minimal cost it causes under the assumption
that the set
{Xi,Yi;i∈[4]}
is mapped to
{
X
�
i
,Y
�
i
;i∈[4
]}
Content courtesy of Springer Nature, terms of use apply. Rights reserved.
Social Network Analysis and Mining (2020) 10:50
1 3
Page 7 of 16 50
To construct a warping path, we begin by defining, for
each
j∈[m]
, the following three sub-paths (see also Fig.3):
For each clause
C
j=𝓁
1
j∨𝓁
2
j∨𝓁
3
j , pick
kj∈[3]
such that
𝓁kj
j
is true. We then build the warping pathp as the union of all
𝜋
kj
j
, using the trivial warping path for all remaining layers:
It is then not difficult to calculate that each clause block adds
cost of exactly
42 ⋅d(0, 1)
and there are no other costs. Thus,
dtgw (G,H)≤42m⋅d(0, 1)=c
.
“
⇒
”: Now suppose that
dtgw (G,H)≤c
and let (M,p)
be a pair of vertex mappingM and warping pathp with cost
∑(i,j)∈p
C(Gi,Hj,M)= dtgw (G,H
)
. Note that any non-sep-
aration layer contains at most eight edges. So if p warps any
separation layer to any non-separation layer, then the result-
ing cost would be at least
(44m−16)⋅d(0, 1)>c
. Thus, we
may assume that every separation layeri of
G
is only warped
to layeri of
H
and vice versa. Since the last 22m layers of
each temporal graph are all identical and M andp are chosen
to have minimal cost, we can conclude that
If M maps some vertex from
{Xk,Yk;k∈[4]}
to some
vertex that is not in
{
X
�
k
,Y
�
k
;k
∈[
4
]}
, then the 22m layers
2n+4m+1, …,2n+4m+22m
each would cause cost of
at least
2⋅d(0, 1)
, thus exceedingc in total. Hence, Mhas to
contain a bijection from
{Xk,Yk;k∈[4]}
to
{X�
k,Y�
k;k∈[4]}
.
Now, consider the clause block corresponding to
C
j=𝓁
1
j
∨𝓁
2
j
∨𝓁
3
j
. From the arguments above, it follows that
G2n+4j−3
and
G2n+4j−1
are warped to
H2n+4j−3
and
H2n+4j−1
,
respectively. This already costs
32 ⋅d(0, 1)
. We distinguish
three cases (corresponding to
𝜋1
j
through
𝜋3
j
above):
1.
G2n+4j−2
is warped to
H2n+4j−3
. This causes costs of
at least
2⋅d(0, 1)
. Then,
H2n+4j−2
must be warped to
G2n+4j−1
or p would not have minimal cost. Thus, there
are additional costs of at least
8⋅d(0, 1)
. This is the situ-
ation illustrated in Fig.3a.
M∶= {(x
i
,⊤
i
),(x
i
,⊥
i
)∶𝛽(x
i
)=
𝚝𝚛𝚞𝚎
}
∪ {(xi,⊥i),(xi,⊤i)∶𝛽(xi)=𝚏𝚊𝚕𝚜𝚎}
∪ {(Ci
j,C�i
j)∶i∈[3],j∈[m]}
∪ {(Xi,X�
i),(Yi,Y�
i)∶i∈[4]}
∪ {(v,v
�
)∶v∈V(D)}.
𝜋1
j∶=
{
(2n+4j−2, 2n+4j−3),(2n+4j−1, 2n+4j−2)
},
𝜋
2
j∶= {(2n+4j−2, 2n+4j−2)},
𝜋
3
j
∶=
{
(2n+4j−3, 2n+4j−2),(2n+4j−2, 2n+4j−1)
}.
p
∶= {(i,i)∶i∈[2n+4m+22m]⧵{2n+4j−2;j∈[m]}} ∪ ⋃
j∈[m]
𝜋
k
j
j
.
p⊃{(i,i);i∈[2n+4m+22m]⧵{2n+4j−2;j∈[m]}}.
2.
G2n+4j−2
is warped to
H2n+4j−2
. This causes costs of
at least
10 ⋅d(0, 1)
. This is the situation illustrated in
Fig.3b.
3.
G2n+4j−2
is warped to
H2n+4j−1
. This case is symmetric
to (1) and also causes costs of at least
10 ⋅d(0, 1)
. This
is the situation illustrated in Fig.3c.
In summary, the costs contributed by each clause block are
at least
42 ⋅d(0, 1)
. Hence, to meet the bound of c, all layers
outside of clause blocks must not cause any additional cost.
For each
i∈[n]
, since
G2i−1
is warped to
H2i−1
, this implies
that either
{(⊤i,xi),(⊥i,xi)} ⊂M
or
{(⊤i,xi),(⊥i,xi)} ⊂M
.
Furthermore, for each
j∈[m]
, the clause block corre-
sponding to
Cj
must have cost of exactly
42 ⋅d(0, 1)
. If we
are in Case(1) as above, then this is only possible ifM maps
each degree-1 vertex of
G2n+4j−2
to some degree-1 vertex
of
H2n+4j−3
. Thus,
(
𝓁2
j,⊤𝜈(j,2)
)
∈M . Otherwise, if we are in
Case(2), respectively, Case(3), then analogous arguments
yield that
(
𝓁1
j,⊤𝜈(j,1)
)
∈
M
, respectively,
(
𝓁3
j,⊤𝜈(j,3)
)
∈M .
Hence, in any case there is some
i∈[3]
for which
(
𝓁i
j,⊤𝜈(j,i)
)
∈
M
.
Consequently,
is a satisfying assignment for
𝜙
.
◻
Let us take a closer look at the reduction in the proof
of Theorem1. Note that the corresponding optimal warp-
ing path is always close to the diagonal (that is,
|i−j|≤1
holds for every pair(i,j)). Hence, it lies within the so-called
Sakoe–Chiba band (Sakoe and Chiba 1978) of widthone.
Moreover, the maximum degree in each layer is one. Finally,
the number of vertices and the number of layers of both
temporal graphs and the target costc are all upper-bounded
linearly in the size of the
3
- sAt formula, which allows to
conclude a running time lower bound based on the Expo-
nential Time Hypothesis3 Impagliazzo and Paturi (2001)
[together with the Sparsification Lemma (Impagliazzo etal.
2001)]. These observations are summarized in the following
corollary. (Recall that V, W are the vertex sets and T, U are
the lifetimes of
G
,
H
.)
Corollary 2 DtgW is NP -complete for every metric and
vertex degrees as vertex signatures even when the maxi-
mum degree of each layer is one and the warping path is
𝛽
(xi) ∶=
{
𝚝𝚛𝚞𝚎, if (xi,⊤i)∈M
𝚏𝚊𝚕𝚜𝚎, if (x
i
,⊤
i
)∈M
3 The Exponential Time Hypothesis asserts that
3
-sAt cannot be
solved in subexponential time, that is, there is no
2o(n)
⋅
poly(m)
-time
algorithm, where nis the number of variables andm is the number of
clauses of the input formula.
Content courtesy of Springer Nature, terms of use apply. Rights reserved.
Social Network Analysis and Mining (2020) 10:50
1 3
50 Page 8 of 16
restricted to the Sakoe–Chiba band of width one. Moreo-
ver, even this very restricted variant cannot be solved in
2o(|V|+|W|+T+U+c)
⋅
poly(|
G
|+|
H
|)
time unless the Exponen-
tial Time Hypothesis fails.
Furthermore, if the dtgw-distance is normalized (e.g.,
divided by the number of vertices), then we obtain NP-
hardness for a constant value ofc (by the reduction in the
proof of Theorem1).
Corollary 3 DtgW with normalized vertex-signature-
based distance is NP-complete for a constant value ofc.
Due to the proven worst-case hardness of DtgW , there is
little hope to solve the problem efficiently in general. Nev-
ertheless, in the next section we provide some methods to
cope with this intractability.
5 Algorithms
In this section, we first point out polynomial-time solvable
special cases. Then, we develop a mathematical program-
ming formulation as well as a heuristic approach to approxi-
mate the
dtgw
-distance in practice.
5.1 Exact polynomial‑time algorithms forspecial
cases
Our first algorithmic result is to show that one can determine
in polynomial time whether two temporal graphs with the
same number of vertices have
dtgw
-distance zero. This basic
case occurs when checking for duplicates within a data set.
In contrast, determining whether two (static) graphs have
graph edit distance zero is not known to be polynomial-time
solvable (as this is equivalent to the famous
grAPh isomor
-
Phism
problem).
Theorem2 Let
G=(V,E1,…,ET)
and
H=(W,F1,…,FU)
be two temporal graphs with
|V|=|W|=n
. For all vertex
signatures and all metrics, deciding whether
dtgw (G,H)=0
holds is possible in
O(n2
⋅
(T+U)+n3)
time.
Proof We will show that for distance zero, an optimal warp-
ing path can easily be determined. Polynomial-time solv-
ability then follows from Observation 1.
Let
G=(V,E1,…,ET)
and
H=(W,F1,…,FU)
be two
temporal graphs with
V=∶ {v1,…,vn}
and
W=∶ {w1,…,wn}
. For each
i∈[T]
, we define the
ith
layer signature of
G
as f(G
i
) ∶=
(
f
Gi
(v
1
),…,f
Gi
(v
n
)
)
(analo-
gously, f(Hj) ∶=
(
fH
j
(w1),…,fH
j
(wn)
)
for
j∈[U]
). Assum-
ing
dtgw (G,H)=0
, it follows that there exists a vertex map-
ping
M⊆V×W
and a warping path
p∈PT,U
such that
holds for every
(i,j)∈p
. Since
d
is a metric, this implies
that
f
G
i(u)=f
H
j(v)
holds for every
(u,v)∈M
. That is,
f(Hj)
is a permutation (determined by M) of
f(Gi)
. Let
1≤i1<i2…<iq<T
be the indices such that
and let
1
≤
j1<j2<…<jr<U
be the indices such that
Clearly, if
f(Gi)
≠
f(Gi
�
)
and layeri is warped to layerj and
layer
i′
is warped to layer
j′
, then
f(Hj)≠f(Hj
�
)
since other-
wise the cost will not be zero. By the definition of a warp-
ing path, it follows that the layers
1, …,i1
of
G
can only be
warped to layers
1, …,j1
of
H
and the layers
i1+1, …,i2
of
G
can only be warped to layers
j1+1, …,j2
of
H
and
so on. Note that this is only possible if
q=r
. If this is the
case, then we can assume that the warping pathp has the
following form:
By Observation 1, we can now check whether there exists
a vertex mapping that yields distance zero for the warping
pathp in
O(n2
⋅
(T+U)+n3)
time. Computingp can be
done in
O(n(T+U))
time.
◻
We remark that if the vertex signatures and the metric sat-
isfy the property that every pair of different vertex signatures
has distance at least
𝛿
for some constant
𝛿>0
, then DtgW
parameterized by the resulting costc is in XP . For exam-
ple, this is the case when the vertex signatures contain only
integers and
d
is any
𝓁p
-norm (for
p≥1
). Then, every pair
of different signatures has distance at least
𝛿=1
. The idea
of the algorithm is to “guess” the tuples of a warping path
which cause nonzero cost (at most
c∕𝛿
many) and to check
whether it is possible to complete the warping path with-
out further costs. The latter can be done in polynomial time
using similar arguments as for the case
c=0
(Theorem2).
Corollary 4 DtgW is in XP with respect toc if the vertex
signatures have a constant minimum pairwise distance
𝛿>0
.
∑
(u,v)∈M
d
(
fGi(u),fHj(v)
)
=
0
f(Gi)≠f(Gi+1)⟺i∈{ik;k∈[q]},
f(Hj)≠f(Hj+1)⟺j∈{jk;k∈[r]} .
p
=
{
(1, 1),(1, 2),…,(1, j1),(2, j1),…(i1,j1),
(i1+1, j1+1),…,(i1+1, j2),…(i2,j2),
…,
(i
q
+1, j
q
+1),…,(i
q
+1, U),…,(T,U)
}.
Content courtesy of Springer Nature, terms of use apply. Rights reserved.
Social Network Analysis and Mining (2020) 10:50
1 3
Page 9 of 16 50
In contrast, if the dtgw-distance is normalized, then
the differences between vertex signatures can be arbitrar-
ily small, in which case DtgW is NP-hard for constantc
(Corollary 3).
To overcome this hardness, in the following, we consider
special cases based on parameters regarding the warping
path length. We assume that the lifetimes of the inputs dif-
fer by at most a constant, that is,
T=U+t
for some
t≥0
(which might often be the case in practice). Note that, by
definition, every warping path of order
T×U
has length
at leastT. We define the parameter
𝜆
to be the difference
between the warping path length and the lower boundT, that
is, we consider only order-
(T×U)
warping paths of length at
most
T+𝜆
. (In practice, overly long warping paths might be
considered unnatural.) We prove that DtgW is in XP with
respect to the combined parameter
(𝜆,t)
.
Theorem3 For all vertex signatures and all metrics,
DtgW is solvable in
time if
n=max(|V|,|W|)
,
T=U+t
, and the warping paths
have length at most
T+𝜆
.
Proof Let
G=(V,E1,…,ET)
and
H=(W,F1,…,FT)
be
two temporal graphs, and
let
p={p1=(i1,j1),…,pL=(iL,jL)} ∈ PT,U
be a warping
path. The warping path p contains
L−1
steps
p𝓁+1−p𝓁=(i𝓁+1−i𝓁,j𝓁+1−j𝓁)∈{(1, 0),(0, 1),(1, 1)}
for
1≤𝓁<L
. We call a step
𝓁
horizontal if
p𝓁+1−p𝓁=(1, 0)
,
and we call it vertical if
p𝓁+1−p𝓁=(0, 1)
, and otherwise
we call it diagonal. Let
𝜈≤U−1
denote the number of ver-
tical steps inp. Then, pcontains also
𝜈+t
horizontal and
U−1−𝜈
diagonal steps, that is,
L−1=𝜈+𝜈+t+U−𝜈−1
, which implies that
𝜈=L−t−U
. Clearly, there are
(
L−1
𝜈
)
possible positions
for the vertical steps. For each of these possible choices,
there are again
(
L−1−𝜈
𝜈+t
)
possible positions for horizon-
tal steps. (The remaining steps are diagonal.) Therefore, the
overall number of warping paths of length at most
T+𝜆
is
For each of these possible warping paths, we can compute
dtgw (G,H)
in
time by Observation 1.
◻
O(
(T+𝜆)
𝜆
⋅T
𝜆+t(
n
2
⋅(T+𝜆)+n
3))
𝜆
l=0
T+l−1
l
T−1
l+t
∈O
(T+𝜆)𝜆
⋅T𝜆+t
.
O(max(|V|,|W|)2
⋅
(T+
𝜆
)+max(|V|,|W|)3)
Note that Proposition 3 implies polynomial-time solv-
ability of DtgW ift and
𝜆
are constants. For unboundedt,
however, we conjecture that DtgW is NP-hard even if the
warping paths are restricted to have length
max(T,U)
, which
is the minimum possible length (that is,
𝜆=0
).
5.2 Quadratic programming
We give a formalization of DtgW as a quadratic minimiza-
tion problem with linear constraints(QP). This is NP-hard
to solve in general but can be used to solve small instances
exactly with the state-of-the-art QP-solvers such as Gurobi4.
Let
G=(V,E1,…,ET)
and
H=(W,F1,…,FU)
be two
temporal graphs. Denote the vertices inV by
u1,…,u|V|
and
the vertices inW by
v1,…,v|W|
. To model “vertex deletion,”
we add two artificial vertices
u|V|+1,v|W|+1
.
We use the following variables:
• For every
(i,j)∈[|V|+1]×[|W|+1]
, we have a vertex
mapping variable
mi,j∈{0, 1}
, where
mi,j=1
if and only
if vertex
ui
is mapped to vertex
vj
.
• For every
(s,t)∈[T]×[U]
, we have a warping vari-
able
ws,t∈{0, 1}
, where
ws,t=1
if and only if
Gs
is
warped to
Ht
.
Moreover, for every
(s,t,i,j)∈[T]×[U]×[|V|+1]×[|W|+1]
, let
denote the cost of matching vertex i in layer s to vertex j in
layer t.
Computing
dtgw (G,H)
is the following quadratic5 mini-
mization problem.
d
s,t,i,j∶=
d
fGs(vi),fHt(wj)
,i∈[V],j∈[W]
𝛥Gs(vi),i∈[V],j=W+1
𝛥Ht(wj),i=
V
+1, j∈[
W
]
0, i=
V
+1, j=
W
+
1
(1)
minimize ∑
s∈[T]
∑
t∈[U]
∑
i∈[|V|+1]
∑
j∈[|W|+1]
ds,t,i,j⋅ws,t⋅mi,
j
(1a)
subject to
(1b)
∑
j∈[|W|+1]
mi,j=1∀i∈[
|
V
|]
4 www.gurob i.com
5 It is also possible to convert our formulation into a linear problem
by introducing further variables and constraints for replacing the
product
ws,t
⋅
mi,j
in the objective function. However, in our experi-
ments we found that the quadratic formulation can be solved faster.
Content courtesy of Springer Nature, terms of use apply. Rights reserved.
Social Network Analysis and Mining (2020) 10:50
1 3
50 Page 10 of 16
The constraints1b and 1c ensure that the vertex map-
ping variables define a correct vertex mapping, that is, every
vertex is mapped to exactly one other vertex (or is deleted).
Constraints1d to1g ensure that the warping variables
define a valid warping path. Here, the constraints1e to1g
imply that if the warping path contains a pair(s,t), then it
also contains at least one of the pairs
(s+1, t)
,
(s,t+1)
, or
(s+1, t+1).
(Since the objective is minimized, any solution
will actually select only one of these pairs.)
The number of variables is in
O(|V|
⋅
|W|+T
⋅
U)
, and
the number of constraints is in
O(|V|+|W|+T⋅U)
.
5.3 Heuristic approaches
In this section, we present a heuristic to compute the dtgw-
distance, which typically yields good (not necessarily opti-
mal) solutions in practice.
The approach is to simply start with an arbitrary initial
vertex mapping (or warping path) and to compute an optimal
warping path (vertex mapping) based on Observation 1 in
polynomial time. This process is then repeated by alternating
between optimal warping path and optimal vertex mapping
computation until the solution converges to a local minimum
(or some other criterion is reached).
Note that it is a convenient feature of our heuristic to be
able to stop the process after any number of iterations to
obtain some approximate solution (a so-called anytime algo-
rithm). It is further possible to incorporate prior knowledge,
for example, by fixing the mapping for some vertices. Note
also that convergence is guaranteed since we decrease the
objective in each alternation and the search space is finite.
We propose several initialization options.
Initial Warping Path. A first idea for initialization is to
choose a shortest warping path (that is, of length
max(T,U)
).
Note that for
T≠U
several such paths exist. Without further
(1c)
∑
i∈[|V|+1]
mi,j=1∀j∈[
|
W
|]
(1d)
w1,1 =1
(1e)
ws,t≤ws+1,t+1+ws,t+1+ws+1,t∀(s,t)∈[T−1]×[U−1]
(1f)
wT,t≤wT,t+1∀t∈[U−1]
(1g)
ws,U≤ws+1,U∀s∈[T−1].
knowledge about the instances, choosing a path within the
Sakoe–Chiba band of small width is a reasonable default.
This initialization is very simple and only requires
O(T+U)
time.
Another idea is to compute a warping path using
D(Gi,Hj)
as a cost for warping layeri to layerj. This is of course an
optimistic estimate since it allows to use a different vertex
mapping for each pair of layers. Then, a vertex mapping
can be computed by Observation 1. This initialization takes
O(T
⋅
U
⋅
n3)
time where
n∶= max(|V|,|W|)
.
Initial Vertex Mapping. The idea is to compute a vertex
mapping by solving an Assignment Problem instance for
approximate costs. Let
𝜎(u,v)
be some approximate cost for
mapping vertex
u∈V
to
v∈W
. For example, one could use
the following estimations:
The first option
𝜎∗
estimates the cost of mappingu tov over
all possible warpings between any two layers. (This is usu-
ally more than any warping path will incur.) The definition
of
𝜎opt
only considers for each layer of the first temporal
graph the minimal cost over all layers of the other tempo-
ral graph. (This estimate might be too low.) Both of these
options require
O(T
⋅
U
⋅
|V|
⋅
|W|)
time.
Based on the estimated costs, one computes a vertex map-
ping by solving an
Assignment Problem
instance and then
computes an optimal warping path for this vertex mapping
based onObservation 1.
The running time of one iteration (that is, comput-
ing a vertex mapping and an optimal warping path) is
O(
(T+U)⋅n2+n3+T⋅U⋅n
)
. While the number of itera-
tions might depend on the choice of initialization, in our
experiments the heuristic always converged after very few
iterations. Regarding the solution quality, while it is pos-
sible to construct adversarial examples where the heuristic
performs poorly, our experiments in Sect.6.2 indicate that
it performs well in practice.
6 Experiments
We conducted several experiments6 to demonstrate the merit
of our dtgw-distance in applications and to evaluate the per-
formance of the alternating minimization heuristic(Am) we
described in Sect.5.3. For computations, we used a 4.0GHz
i7-6700K processor (single-threaded).
𝜎
∗
(u,v) ∶=
∑
i∈[T]
∑
j∈[U]
d
(
fGi(u),fHj(v)
),
𝜎
opt(u,v) ∶=
∑
i∈[T]
min
j∈[U]d
(
fGi(u),fHj(v)
).
6 Source code available at www.akt.tu-berli n.de/menue /softw are.
Content courtesy of Springer Nature, terms of use apply. Rights reserved.
Social Network Analysis and Mining (2020) 10:50
1 3
Page 11 of 16 50
6.1 Data sets
We used three data sets from the SocioPatterns project
(Génois and Barrat 2018). Each of these consists of two
temporal social networks, both recorded simultaneously with
the same individuals as vertices. The first network is a face-
to-face contact network, whereas the second one is a co-
presence network where edges represent spatial proximity.
All six networks have a temporal resolution of 20 seconds.
For our experiments, only the first day of each network was
used and vertices without any edges were discarded. The
three different data sets were recorded at a primary school
(“LyonSchool,” 237 vertices, 1700 layers), a scientific con-
ference (“SFHH,” 403 vertices, 2300 layers), and a work-
place (“InVS15,” 180 vertices, 2100 layers).
6.2 Comparison ofheuristic andexact solutions
We compared the solutions of our Am heuristic under dif-
ferent initialization schemes against the optimal solutions
obtained from the QP formulation.
Due to long running times of the QP-solver, we were
restricted to very small temporal networks. We randomly
selected10 children from class1A of the primary school
face-to-face network and extracted225 consecutive layers
(during a high contact period) which we split into 15 tem-
poral subnetworks with15 consecutive layers each. We used
vertex degrees as signatures (with absolute value metric)
and computed all pairwise dtgw-distances between these 15
networks with the following algorithms:
• QP: exact QP-solver (Gurobi 8.0.1),
• Am
𝜎∗
: Am with
𝜎∗
initialization,
• Am
𝜎opt
: Am with
𝜎opt
initialization,
• Am
swp
: Am with shortest warping path initialization,
• Am
owp
: Am with optimistic warping path initialization.
We implemented the Am heuristic in Python, using a C++
implementation7 of the Jonker–Volgenant algorithm (Jonker
and Volgenant 1987) to solve the Assignment Problem.
Figure4 shows for each initialization variant the esti-
mated cumulative distribution function (ecdf) of the error
percentage
𝜀=100 ⋅(dAM −dQP)∕dQP ,
where
dAM
is the
approximate dtgw-distance obtained by an Am heuristic and
dQP
is the exact dtgw-distance obtained by the QP-solver.
A point
(𝜀,P)
on an ecdf-curve of an Am heuristic means
that the error percentage of Am is at most
𝜀
with estimated
probability P.
All Am variants found the correct solution for a majority of
samples(
P0>0.5
). The average error percentages are rather
small and vary between 3.0 by Am
owp
and 5.5 by Am
𝜎opt
. The
Am
owp
heuristic performed the best, having
P0≈0.71
and
maximum error percentage
max ≈36.4
. These findings indi-
cate that for small instances the approximations of the four
heuristics are close to the optimal solution on average but may
fail considerably in some cases with up to a maximum error
of
63.6%
. We remark that based on our experimental experience
the relative error becomes smaller on larger instances.
Regarding running times, the Am heuristic took less than
0.01 seconds per instance, usually converging after at most
three iterations (independently of the chosen initialization).
In comparison, the QP was slower by a factor of more than
10000, requiring 8 minutes on average (median 2 minutes)
with some instances approaching 2 hours.
6.3 Sensitivity ofDTGW tonoise
The goal of this experiment was to assess how sensitive the
dtgw-distance is to noise, that is, how well can original data
be reconstructed from noisy data. We compared our dtgw-
distance approach to the following two baseline methods.
Fig. 4 The plot (left) shows the
estimated cumulative distribu-
tion functions of the four Am
variants. The table (right)
presents the average error
percentage(avg), the standard
deviation(std), the fraction of
optimally solved instances(
P0
),
and the maximum error percent-
age(max) of every Am variant
heuristic avg std P0max
AMσ∗4.59.1 0.59 63.6
AMσopt 5.510.50.58 55.6
AMswp4.810.00.61 63.6
AMowp3.06.2 0.71 36.4
7 This code is available as a Python module at githu b.com/src-d/lapjv .
Content courtesy of Springer Nature, terms of use apply. Rights reserved.
Social Network Analysis and Mining (2020) 10:50
1 3
50 Page 12 of 16
• Non-consistent: Instead of using one consistent vertex
mapping for all layers, one can allow a different mapping
for each pair of layers. Note that the resulting distance
can be computed in
O(T
⋅
U
⋅
n3)
time, thus being faster
than an exact computation of the dtgw-distance but much
slower than a single iteration of the Am heuristic.
• Non-temporal: A naive approach is to ignore the time
information and solely compute an optimal vertex map-
ping between the underlying graphs. This requires
O(n3)
time plus the (usually linear) time to build the underlying
graphs.
We used the primary school face-to-face network from which
we extracted five reference temporal networks representing
the contacts between children of the same grade, each con-
taining 45–50 vertices and 3100 layers.
For each of the five reference networks, we generated nine
noisy copies as follows:
1. For every
i∈[T]
,
Ei
is deleted with probability
p∈{0.1, 0.2, 0.3}
, and if not, then each edge
e∈Ei
is
deleted with probability p.
2. For every
i∈[T]
, each edge
e∈Ei
was rewired with
probability
p∈{0.1, 0.2, 0.3}
.
3. Each edge of the underlying graph was rewired with
probability
p∈{0.1, 0.2, 0.3}
.
Rewiring an edge
e={u,v}∈Ei
of a tempo-
ral graph is defined as randomly picking a tuple
Fig. 5 Sensitivity of dtgw to noise. Shown are the dendrograms
obtained by agglomerative clustering using complete linkage. Differ-
ent colors represent different grades; the light gray edges connect ele-
ments of different grades. The top left dendrogram shows the result
obtained by the dtgw-distance. The top right dendrogram shows the
result obtained by the non-consistent benchmark. The bottom dendro-
gram shows the result obtained by using the non-temporal benchmark
Content courtesy of Springer Nature, terms of use apply. Rights reserved.
Social Network Analysis and Mining (2020) 10:50
1 3
Page 13 of 16 50
(
e�={u�,v�},t)∈
⋃T
s=1
(E
s
×{s
})
and then replacing e in
Ei
by
{u,v�}
and
e′
in
Et
by
{u�
,v}
.8 Rewiring of underlying
edges is done analogously (see Holme and Saramäki 2012
for details).
We used the Am heuristic to approximate the pairwise
dtgw-distances (using degrees as vertex signatures) between
all reference and noisy temporal networks. In all of these
instances, shortest warping path initialization (which is fast-
est) was used since preliminary tests showed that the other
initializations produce very similar results.
Figure5 shows the dendrogram obtained by hierarchical
clustering using complete linkage of the approximated pair-
wise dtgw-distances. Both the dtgw-distance and the non-
consistent baseline were able to partition the instances into
five clusters, each of which consists of a reference network
and its nine noisy copies. Hence, they successfully recovered
the original reference networks from noise. However, the
clusters produced by the dtgw-distance are more compact
than the ones of the non-consistent baseline. In contrast, the
non-temporal baseline was not able to separate the graphs
of different grades.
In all instances, the heuristic converged within at most
six iterations, taking less than 15 seconds. In comparison,
the non-consistent baseline required 4 minutes on average
for each instance, while the non-temporal baseline was the
fastest (below 1 second).
6.4 De‑anonymization
Besides measuring a distance between temporal graphs, the
dtgw-distance additionally provides a mapping between the
vertex sets which implicitly allows to identify vertices. This
allows the de-anonymization (Narayanan and Shmatikov
2009) of temporal social networks. Since the data sets used
contain the original mapping between the vertex sets, we
can employ this as an easy benchmark for the accuracy of
the dtgw-distance.
We used the Am heuristic (with shortest warping path
initialization) to compute the dtgw-distance (with degrees
as vertex signatures9) on the three data sets mentioned in
Sect.6.1. We counted how many vertices were correctly re-
identified (that is, mapped to their copies) in the resulting
vertex mapping. We compared our results to the following
alternative algorithms found in the literature:
• DynaMAGNA++ (Vijayan etal. 2017): A search-based
evolutionary algorithm computing a vertex mapping that
maximizes edge conservation and node conservation over
time.
• Temporal network embedding (Zuo etal. 2018): Hawkes
process-based temporal network embedding (HTNE)
computes a low-dimensional embedding of the vertices
of a temporal network. From this, we computed a vertex
mapping minimizing the Euclidean distances between the
vertex feature vectors.
• Fixed dtgw: Note that our dtgw-distance allows to fix the
warping path beforehand (Observation 1ii)). Since in our
Table 1 Percentages
(rounded) of vertices that were
re-identified by the tested
methods
Also, average running times (in seconds) over the three versions of each data set are given (fixed dtgw is
not applicable for shifted and randomized data sets)
Data set dtgw Fixed dtgw DynaMAGNA++ HTNE
School Original 2% 1% 1% 1%
Shifted 1% – 0% 1%
Randomized 1% – 1% 0%
Average running time 95s 65s 15,070s 250s
Conference Original 86% 90% 80% 0%
Shifted 86% – 27% 0%
Randomized 65% – 30% 1%
Average running time 200s 125s 20,320s 90s
Workplace Original 38% 43% 51% 1%
Shifted 38% – 19% 0%
Randomized 10% – 8% 1%
Average running time 45s 20s 1600s 50s
8 Since edges are undirected, it is understood that the choice of
which vertex to call u, respectively, v is to be made randomly. (The
same holds for
u′
and
v′
.)
9 We also tested other signatures such as size of the connected com-
ponent or betweenness centrality. However, the performance was
(slightly) worse.
Content courtesy of Springer Nature, terms of use apply. Rights reserved.
Social Network Analysis and Mining (2020) 10:50
1 3
50 Page 14 of 16
case each pair of temporal graphs was recorded using
synchronized clocks, it is natural to use a fixed warping
path that aligns layeri of the first graph with layeri of
the second graph.
To simulate a situation in which the temporal graphs repre-
sent processes which do not run synchronously in time, we
created two modified versions of each of the data sets. In the
first one, called “shifted,” all events of the first graph were
delayed by three minutes. In the second version, called “ran-
domized,” each layer of each of the graphs was randomly
and independently replaced by X layers where
X∈{1, 2, …}
is a random variable with
ℙ(X≥x)=x−3
. Since we pre-
tend that the nature of these modifications is unknown to
the tested algorithms, dtgw with fixed warping path is not
applicable to these variants.
For DynaMAGNA++, we used a population of
size15000 and a maximum of 10000 generations. With
HTNE, we computed 128-dimensional vertex embeddings
using a batch of size 10000, a learning rate of 0.1, a his-
tory length of 2, and 5 negative samples. Unlike dtgw, both
methods utilized all four processor cores.
The results and running times are listed in Table1. Most
notably, the re-identification rate of HTNE was poor on all
data sets, suggesting that these embeddings are ill-suited for
comparing vertices taken from different networks. Further-
more, all methods failed to re-identify any significant num-
ber of vertices on the primary school data set. This might be
explained by the fact that the co-presence network is very
different from the face-to-face contacts due to a low spatial
resolution (as was also noted by Génois and Barrat (2018)).
The overall performance was much better on the other
two data sets, especially on the conference data where up
to 90% of participants could be re-identified, whereas on
the workplace data set the best result was 51%. Unsurpris-
ingly, fixing the correct layer alignment on the unmodified
graphs sped up the dtgw computation significantly while
also yielding slightly better results. On these instances, dtgw
performed comparably to DynaMAGNA++, being better in
one case and worse in the other, although requiring much
less computational effort. In contrast, on the shifted and ran-
domized data sets dtgw always achieved the best results.
(Notably, the re-identification performance using dtgw did
not decrease on shifted data.)
In all cases, the Am heuristic converged after at most
six iterations and DynaMAGNA++ converged within 2000
generations.
7 Conclusion
We introduced a new proximity measure for comparing tem-
poral graphs by transferring dynamic time warping from
time series to temporal graphs. This yields a challenging
computational problem for which we proposed exact algo-
rithms and a heuristic approach to solve it. While exact solu-
tions can only be computed for very small instances, we
empirically showed that our heuristic runs fast in practice
and yields good approximations of optimal solutions. In our
experiments, it was also capable of de-anonymizing social
networks.
Our work opens several directions for future research.
We believe that the dtgw-distance is a promising tool,
for example, in biology and chemistry. Processes like
epidemic disease spreading or chemical reactions can
naturally be viewed as temporal graphs where the verti-
ces represent individuals or (macro) molecules. [Unfor-
tunately, we could not test this, as there is still a lack of
openly available temporal molecular data (Vijayan etal.
2017).] Since the exact timescales of these processes often
vary, the ability of dynamic time warping to compensate
for such differences would be especially helpful in this
context. One might also use the dtgw-distance to under-
stand the learning process of neural networks. The train-
ing phases of neural networks yield temporal networks
which can be analyzed to gain insight into how different
conditions influence the learning process. Another poten-
tial application is analyzing team sports data via temporal
graphs to reveal similar strategies or roles of individual
players. Depending on the application domain, there is a
wide range of possibilities to test the performance when
using different vertex signatures or even other graph
distances.
Besides experimenting with various application domains
and further definition variants, already the proven compu-
tational worst-case hardness of DtgW may trigger further
algorithmic research. A concrete open question is whether
DtgW is in XP (or even fixed-parameter tractable) with
respect to
𝜆
, when the warping path length is restricted to
be at most
max(T,U)+𝜆
where T, U are the respective life-
times. It is also interesting to further study the influence of
graph-specific parameters in the spirit of a multivariate com-
plexity analysis (Niedermeier 2010; Fellows etal. 2013).
Acknowledgement Open Access funding provided by Projekt DEAL.
Funding BJ: Supported by the DFG project JA2109/4-2, MR: Sup-
ported by the DFG project NI369/17-1.
Open Access This article is licensed under a Creative Commons Attri-
bution 4.0 International License, which permits use, sharing, adapta-
tion, distribution and reproduction in any medium or format, as long
as you give appropriate credit to the original author(s) and the source,
Content courtesy of Springer Nature, terms of use apply. Rights reserved.
Social Network Analysis and Mining (2020) 10:50
1 3
Page 15 of 16 50
provide a link to the Creative Commons licence, and indicate if changes
were made. The images or other third party material in this article are
included in the article’s Creative Commons licence, unless indicated
otherwise in a credit line to the material. If material is not included in
the article’s Creative Commons licence and your intended use is not
permitted by statutory regulation or exceeds the permitted use, you will
need to obtain permission directly from the copyright holder. To view a
copy of this licence, visit http://creat iveco mmons .org/licen ses/by/4.0/.
References
Abboud A, Backurs A, Williams VV (2015) Tight hardness results
for LCS and other sequence similarity measures. In: 2015 IEEE
56th annual symposium on foundations of computer science
(FOCS’15), pp 59–78. https ://doi.org/10.1109/FOCS.2015.14
Ahmed R, Karypis G (2015) Algorithms for mining the coevolving
relational motifs in dynamic networks. ACM Trans Knowl Discov
Data 10(1):4:1–4:31. https ://doi.org/10.1145/27333 80
Ahuja RK, Magnanti TL, Orlin JB (1993) Network flows: theory, algo-
rithms, and applications. Prentice-Hall, Upper Saddle River
Baste J, Bui-Xuan BM, Roux A (2020) Temporal matching.
Theor Comput Sci 806:184–196. https ://doi.org/10.1016/j.
tcs.2019.03.026
Bento J, Ioannidis S (2018) A family of tractable graph distances.
In: Proceedings of the 2018 SIAM international conference
on data mining (SDM’18). SIAM, pp 333–341. https ://doi.
org/10.1137/1.97816 11975 321.38
Casteigts A, Himmel A, Molter H, Zschoche P (2019) The computa-
tional complexity of finding temporal paths under waiting time
constraints. In: CoRR. arXiv :abs/1909.06437
Cygan M, Fomin FV, Kowalik L, Lokshtanov D, Marx D, Pilipczuk
M, Pilipczuk M, Saurabh S (2015) Parameterized algorithms.
Springer, New York. https ://doi.org/10.1007/978-3-319-21275
-3
Dakiche N, Tayeb FBS, Slimani Y, Benatchba K (2019) Tracking com-
munity evolution in social networks: a survey. Inf Process Manag
56(3):1084–1102. https ://doi.org/10.1016/j.ipm.2018.03.005
Downey R, Fellows MR (2013) Fundamentals of param-
eterized complexity. Springer, New York. https ://doi.
org/10.1007/978-1-4471-5559-1
Elhesha R, Sarkar A, Cinaglia P, Boucher C, Kahveci T (2019) Co-
evolving patterns in temporal networks of varying evolution.
In: Proceedings of the 10th ACM international conference on
bioinformatics, computational biology and health informatics
(BCB’19). ACM, pp 494–503. https ://doi.org/10.1145/33073
39.33421 52
Fellows MR, Jansen BMP, Rosamond F (2013) Towards fully multi-
variate algorithmics: parameter ecology and the deconstruction of
computational complexity. Eur J Combin 34(3):541–566. https ://
doi.org/10.1016/j.ejc.2012.04.008
Fluschnik T, Niedermeier R, Schubert C, Zschoche P (2020) Multi-
stage
s
-
t
path: confronting similarity with dissimilarity. In: CoRR.
arXiv :abs/2002.07569
Froese V, Jain B, Niedermeier R, Renken M (2019) Comparing tem-
poral graphs using dynamic time warping. In: Proceedings of
the 8th international conference on complex networks and their
applications, SCI, vol 882. Springer, pp 469–480. https ://doi.
org/10.1007/978-3-030-36683 -4_38
Froese V, Jain BJ, Rymar M (2020) Fast exact dynamic time warping on
run-length encoded time series. In: CoRR. arXiv :abs/1903.03003
Fröhlich H, Wegner JK, Sieker F, Zell A (2005) Optimal assignment
kernels for attributed molecular graphs. In: Proceedings of the
22nd international conference on machine learning (ICML’05).
ACM, pp 225–232. https ://doi.org/10.1145/11023 51.11023 80
Garey MR, Johnson DS (1979) Computers and intractability: a guide
to the theory of NP-completeness. W. H. Freeman and Company,
New York
Gayraud NT, Pitoura E, Tsaparas P (2015) Diffusion maximization
in evolving social networks. In: Proceedings of the 2015 ACM
conference on online social networks (COSN’15). ACM, pp
125–135. https ://doi.org/10.1145/28179 46
Génois M, Barrat A (2018) Can co-location be used as a proxy for face-
to-face contacts? EPJ Data Sci 7(1):11. https ://doi.org/10.1140/
epjds /s1368 8-018-0140-1
Gold O, Sharir M (2018) Dynamic time warping and geometric edit
distance: breaking the quadratic barrier. ACM Trans Algorithms
14(4):50:1–50:17. https ://doi.org/10.1145/32307 34
Heeger K, Himmel A, Kammer F, Niedermeier R, Renken M, Sajenko
A (2019) Multistage problems on a global budget. In: CoRR.
arXiv :abs/1912.04392
Holme P, Saramäki J (2012) Temporal networks. Phys Rep 519(3):97–
125. https ://doi.org/10.1016/j.physr ep.2012.03.001
Holme P, Saramäki J (2013) Temporal networks. Springer, New York.
https ://doi.org/10.1007/978-3-642-36461 -7
Holme P, Saramäki J (2019) Temporal network theory. Springer, New
York. https ://doi.org/10.1007/978-3-030-23495 -9
Impagliazzo R, Paturi R (2001) On the complexity of
k
-SAT. J Comput
Syst Sci 62(2):367–375. https ://doi.org/10.1006/jcss.2000.1727
Impagliazzo R, Paturi R, Zane F (2001) Which problems have strongly
exponential complexity? J Comput Syst Sci 63(4):512–530. https
://doi.org/10.1006/jcss.2001.1774
Jain BJ (2016) On the geometry of graph spaces. Discrete Appl Math
214:126–144. https ://doi.org/10.1016/j.dam.2016.06.027
Jonker R, Volgenant A (1987) A shortest augmenting path algorithm
for dense and sparse linear assignment problems. Computing
38(4):325–340. https ://doi.org/10.1007/BF022 78710
Jouili S, Tabbone S (2009) Graph matching based on node signatures.
In: Proceedings of the 7th IAPR-TC-15 international workshop
on graph-based representations in pattern recognition. LNCS, vol
5534. Springer, pp 154–163. https ://doi.org/10.1007/978-3-642-
02124 -4_16
Kostakos V (2009) Temporal graphs. Physica A 388(6):1007–1023.
https ://doi.org/10.1016/j.physa .2008.11.021
Kriege NM, Giscard PL, Wilson R (2016) On valid optimal assignment
kernels and applications to graph classification. In: Advances
in neural information processing systems 29 (NIPS’16). Cur-
ran Associates, Inc., pp 1623–1631. http://paper s.nips.cc/paper
/6166-on-valid -optim al-assig nment -kerne ls-and-appli catio ns-to-
graph -class ifica tion
Kriege NM, Johansson FD, Morris C (2020) A survey on graph kernels.
Appl Netw Sci 5(1):6. https ://doi.org/10.1007/s4110 9-019-0195-3
Kuszmaul W (2019) Dynamic time warping in strongly subquadratic
time: algorithms for the low-distance regime and approximate
evaluation. In: Proceedings of the 46th international colloquium
on automata, languages, and programming (ICALP’19), Schloss
Dagstuhl - Leibniz-Zentrum für Informatik, LIPIcs, vol 132, pp
80:1–80:15. https ://doi.org/10.4230/LIPIc s.ICALP .2019.80
Li A, Cornelius SP, Liu YY, Wang L, Barabási AL (2017) The
fundamental advantages of temporal networks. Science
358(6366):1042–1046. https ://doi.org/10.1126/scien ce.aai74 88
Mertzios GB, Molter H, Niedermeier R, Zamaraev V, Zschoche P
(2020) Computing maximum matchings in temporal graphs. In:
Proceedings of the 37th international symposium on theoretical
aspects of computer science (STACS’20), Schloss Dagstuhl -
Leibniz-Zentrum für Informatik, LIPIcs, pp 27:1–27:14. https ://
doi.org/10.4230/LIPIc s.STACS .2020.27
Content courtesy of Springer Nature, terms of use apply. Rights reserved.
Social Network Analysis and Mining (2020) 10:50
1 3
50 Page 16 of 16
Narayanan A, Shmatikov V (2009) De-anonymizing social networks.
In: Proceedings of the 30th IEEE symposium on security and
privacy, pp 173–187. https ://doi.org/10.1109/SP.2009.22
Nguyen GH, Lee JB, Rossi RA, Ahmed NK, Koh E, Kim S (2018)
Continuous-time dynamic network embeddings. In: Companion
proceedings of the web conference 2018(WWW ’18), Interna-
tional World Wide Web Conferences Steering Committee, pp
969–976. https ://doi.org/10.1145/31845 58.31915 26
Niedermeier R (2010) Reflections on multivariate algorithmics and
problem parameterization. In: Proceedings of the 27th interna-
tional symposium on theoretical aspects of computer science
(STACS’10), Schloss Dagstuhl–Leibniz-Zentrum fuer Infor-
matik, LIPIcs, vol5, pp 17–32. https ://doi.org/10.4230/LIPIc
s.STACS .2010.2495
Rakthanmanon T, Campana B, Mueen A, Batista G, Westover B, Zhu
Q, Zakaria J, Keogh E (2012) Searching and mining trillions of
time series subsequences under dynamic time warping. In: Pro-
ceedings of the 18th ACM SIGKDD international conference
on knowledge discovery and data mining(KDD ’12). ACM, pp
262–270. https ://doi.org/10.1145/23395 30.23395 76
Riesen K (2015) Structural pattern recognition with graph edit dis-
tance. Springer, New York. https ://doi.org/10.1007/978-3-319-
27252 -8
Rozenshtein P, Gionis A (2019) Mining temporal networks. In: Pro-
ceedings of the 25th ACM SIGKDD international conference
on knowledge discovery & data mining (KDD’19). ACM, pp
3225–3226. https ://doi.org/10.1145/32925 00.33322 95
Rozenshtein P, Gionis A, Prakash BA, Vreeken J (2016) Reconstruct-
ing an epidemic over time. In: Proceedings of the 22nd ACM
SIGKDD international conference on knowledge discovery
and data mining (KDD’16).ACM, pp 1835–1844. https ://doi.
org/10.1145/29396 72.29398 65
Sakoe H, Chiba S (1978) Dynamic programming algorithm optimi-
zation for spoken word recognition. IEEE Trans Acoust Speech
Signal Process 26(1):43–49. https ://doi.org/10.1109/TASSP
.1978.11630 55
Vijayan V, Critchlow D, Milenković T (2017) Alignment of dynamic
networks. Bioinformatics 33(14):i180–i189. https ://doi.
org/10.1093/bioin forma tics/btx24 6
Wang X, Mueen A, Ding H, Trajcevski G, Scheuermann P, Keogh
E (2013) Experimental comparison of representation methods
and distance measures for time series data. Data Min Knowl Disc
26(2):275–309. https ://doi.org/10.1007/s1061 8-012-0250-5
Zschoche P, Fluschnik T, Molter H, Niedermeier R (2020) The com-
plexity of finding small separators in temporal graphs. J Comput
Syst Sci 107:72–92. https ://doi.org/10.1016/j.jcss.2019.07.006
Zuo Y, Liu G, Lin H, Guo J, Hu X, Wu J (2018) Embedding temporal
network via neighborhood formation. In: Proceedings of the 24th
ACM SIGKDD international conference on knowledge discovery
and data mining(KDD ’18). ACM, pp 2857–2866. https ://doi.
org/10.1145/32198 19.32200 54
Publisher’s Note Springer Nature remains neutral with regard to
jurisdictional claims in published maps and institutional affiliations.
Content courtesy of Springer Nature, terms of use apply. Rights reserved.
1.
2.
3.
4.
5.
6.
Terms and Conditions
Springer Nature journal content, brought to you courtesy of Springer Nature Customer Service Center GmbH (“Springer Nature”).
Springer Nature supports a reasonable amount of sharing of research papers by authors, subscribers and authorised users (“Users”), for small-
scale personal, non-commercial use provided that all copyright, trade and service marks and other proprietary notices are maintained. By
accessing, sharing, receiving or otherwise using the Springer Nature journal content you agree to these terms of use (“Terms”). For these
purposes, Springer Nature considers academic use (by researchers and students) to be non-commercial.
These Terms are supplementary and will apply in addition to any applicable website terms and conditions, a relevant site licence or a personal
subscription. These Terms will prevail over any conflict or ambiguity with regards to the relevant terms, a site licence or a personal subscription
(to the extent of the conflict or ambiguity only). For Creative Commons-licensed articles, the terms of the Creative Commons license used will
apply.
We collect and use personal data to provide access to the Springer Nature journal content. We may also use these personal data internally within
ResearchGate and Springer Nature and as agreed share it, in an anonymised way, for purposes of tracking, analysis and reporting. We will not
otherwise disclose your personal data outside the ResearchGate or the Springer Nature group of companies unless we have your permission as
detailed in the Privacy Policy.
While Users may use the Springer Nature journal content for small scale, personal non-commercial use, it is important to note that Users may
not:
use such content for the purpose of providing other users with access on a regular or large scale basis or as a means to circumvent access
control;
use such content where to do so would be considered a criminal or statutory offence in any jurisdiction, or gives rise to civil liability, or is
otherwise unlawful;
falsely or misleadingly imply or suggest endorsement, approval , sponsorship, or association unless explicitly agreed to by Springer Nature in
writing;
use bots or other automated methods to access the content or redirect messages
override any security feature or exclusionary protocol; or
share the content in order to create substitute for Springer Nature products or services or a systematic database of Springer Nature journal
content.
In line with the restriction against commercial use, Springer Nature does not permit the creation of a product or service that creates revenue,
royalties, rent or income from our content or its inclusion as part of a paid for service or for other commercial gain. Springer Nature journal
content cannot be used for inter-library loans and librarians may not upload Springer Nature journal content on a large scale into their, or any
other, institutional repository.
These terms of use are reviewed regularly and may be amended at any time. Springer Nature is not obligated to publish any information or
content on this website and may remove it or features or functionality at our sole discretion, at any time with or without notice. Springer Nature
may revoke this licence to you at any time and remove access to any copies of the Springer Nature journal content which have been saved.
To the fullest extent permitted by law, Springer Nature makes no warranties, representations or guarantees to Users, either express or implied
with respect to the Springer nature journal content and all parties disclaim and waive any implied warranties or warranties imposed by law,
including merchantability or fitness for any particular purpose.
Please note that these rights do not automatically extend to content, data or other material published by Springer Nature that may be licensed
from third parties.
If you would like to use or distribute our Springer Nature journal content to a wider audience or on a regular basis or in any other manner not
expressly permitted by these Terms, please contact Springer Nature at
onlineservice@springernature.com
Available via license: CC BY 4.0
Content may be subject to copyright.