Computing the Interleaving Distance is NP-Hard

We show that computing the interleaving distance between two multi-graded persistence modules is NP-hard. More precisely, we show that deciding whether two modules are 1-interleaved is NP-complete, already for bigraded, interval decomposable modules. Our proof is based on previous work showing that a constrained matrix invertibility problem can be reduced to the interleaving distance computation of a special type of persistence modules. We show that this matrix invertibility problem is NP-complete. We also give a slight improvement in the above reduction, showing that also the approximation of the interleaving distance is NP-hard for any approximation factor smaller than 3. Additionally, we obtain corresponding hardness results for the case that the modules are indecomposable, and in the setting of one-sided stability. Furthermore, we show that checking for injections (resp. surjections) between persistence modules is NP-hard. In conjunction with earlier results from computational algebra this gives a complete characterization of the computational complexity of one-sided stability. Lastly, we show that it is in general NP-hard to approximate distances induced by noise systems within a factor of 2.


Introduction
Motivation and problem statement.A persistence module M over R d is a collection of vector spaces {M p } p∈R d and linear maps M p→q : M p → M q whenever p ≤ q, with the property that M p→p is the identity map and the linear maps are composable in the obvious way.For d = 1, we will talk about single-parameter persistence, and for d ≥ 2, we will use the term multi-parameter persistence.
Persistence, particularly in its single-parameter version, has recently gained a lot of attention in applied fields, because one of its instantiations is persistent homology, which studies the evolution of homology groups when varying a real scale parameter.The observation that topological features in real data sets carry important information to analyze and reason about the contained data has given rise to the term topological data analysis (TDA) for this research field, with various connections to application areas, e.g.[17,9,2,16,18].
A recurring task in TDA is the comparison of two persistence modules.The natural notion in terms of algebra is by interleavings of two persistence modules: given two persistence modules M and N as above and some ǫ > 0, an ǫ-interleaving is the assignment of maps φ p : M p → N p+ǫ and ψ i : M p → N p+ǫ which commute with each other and the internal maps of M and N .The interleaving distance is then just the infimum over all ǫ for which an interleaving exists.
A desirable property for any distance on persistence modules is stability, meaning informally that a small change in the input data set should only lead to a small distortion of the distance.At the same time, we aim for a sensitive measure, meaning that the distance between modules should be generally as large as possible without violating stability.As an extreme example, the distance measure that assigns 0 to all pairs of modules is maximally stable, but also maximally insensitive.Lesnick [14] proved that among all stable distances for single-or multi-parameter persistence, the interleaving distance is the most sensitive one over prime fields.This makes the interleaving distance an interesting measure to be used in applications, and raises the question of how costly it is to compute the distance.Of course, for the sake of computation, a suitable finiteness condition must be imposed on the modules to ensure that they can be represented in finite form; we postpone the discussion to Section 3, and simply call such modules of finite type.
The complexity of computing the interleaving distance is well understood for the single parameter case.The isometry theorem [8,14] states the equivalence of the interleaving distance and the bottleneck distance, which is defined in terms of the persistence diagrams of the persistence modules and can be reduced to the computation of a min cost bottleneck matching in a complete bipartite graph [11].That matching, in turn, can be computed in O(n 1.5 log n) time, and efficient implementations have been developed recently [13].
The described strategy, however, fails in the multi-parameter case, simply because the two distances do not match for more than one parameter: even if the multi-parameter persistence module admits a decomposition into intervals (which are "nice" indecomposable elements, see Section 3), it has been proved that the interleaving distance and the multi-parameter extension of the bottleneck distance are arbitrarily far from each other [5,Example 9.1].Another example where the interleaving and bottleneck distances differ is given in [3,Example 4.2]; moreover, in this example the pair of persistence modules has the property that potential interleavings can be written on a particular matrix form, later formalized by the introduction of CI problems in [4].A consequence is that the strategy of computing interleaving distance by computing the bottleneck distance fails also in this special case.
Our contributions.We show that, for d = 2, the computation of the interleaving distance of two persistence modules of finite type is NP-hard, even if the modules are assumed to be decomposable into intervals.In [4], it is proved that the problem is CI-hard, where CI is a combinatorial problem related to the invertibility of a matrix with a prescribed set of zero elements.This is done by associating a pair of modules to each CI problem such that the modules are 1-interleaved if and only if the CI problem has a solution.We "finish" this proof by showing that CI is NP-complete, hence proving the main result.The hardness result on CI is independent of all topological concepts required for the rest of the paper and potentially of independent interest in other algorithmic areas.
Moreover, we slightly improve the reduction from [4] that asserts the CI-hardness of the interleaving distance, showing that also obtaining a (3 − ǫ)-approximation of the interleaving distance is NP-hard to obtain for every ǫ > 0. This result follows from the fact that our improved construction takes an instance of a CI problem and returns a pair of persistence modules which are 1-interleaved if the instance has a solution and are 3-interleaved if no solution exists.We mention that for rectangle decomposable modules in d = 2, a subclass of interval decomposable modules, it is known that the bottleneck distance 3-approximates the interleaving distance [3, Theorem 3.2], and can be computed in polynomial time.While this result does not directly extend to all interval decomposable modules, it gives reason to hope that a 3-approximation of the interleaving distance exists for a larger class of modules.
We also extend our hardness result to related problems: we show that it is NP-complete to compute the interleaving distance of two indecomposable persistence modules (for d = 2).We obtain this result by "stitching" together the interval decomposables from our main result into two indecomposable modules without affecting their interleaving distance.We remark that the restriction of computing the interleaving distance of indecomposable interval modules has recently been shown to be in P [10].
Bauer and Lesnick [1] showed that the existence of an interleaving pair, for modules indexed over R, is equivalent to the existence of a single morphism with kernel and cokernel of a corresponding "size".While the equivalence does not hold in general, the two concepts are still closely related for d > 1.Using this, we obtain as a corollary to the aforementioned results that it is in general NP-complete to decide if there exists a morphism whose kernel and cokernel have size bounded by a given parameter.We also show that it is NP-complete to decide if there exists a surjection (dually, an injection) from one persistence module to another.Together with the result of [6], this gives a complete characterization of the computational complexity of "one-sided stability".Furthermore, we remark that this gives a new proof of the fact that checking for injections (resp.surjections) between modules over a finite-dimensional algebra (over a finite field) is NP-hard.This was first shown in [12,Theorem 1.2].
Outline.We begin with the hardness proof for CI in Section 2. In Section 3, we discuss the representationtheoretic concepts needed in the paper.In Section 4, we describe our improved reduction scheme from interleaving distance to CI.In Section 5, we prove the hardness for indecomposable modules.In Section 6, we prove our hardness result for one-sided stability.We conclude in Section 7.

The CI problem
Throughout the paper, we set F to be any finite field with a constant number of elements.We write F n×n for the set of n × n-matrices over F, and P ij ∈ F for the entry of P at the position at row i and column j.We write I n for the n × n-unit matrix.The constrained invertibility problem asks for a solution of the equation AB = I n , when certain entries of A and of B are constrained to be zero.Formally, using the notation [n] := {1, . . ., n}, we define the language We can write CI instances in a more visual form, for instance writing . Indeed, the CI problem asks whether in the above matrices, we can fill the * -entries with field elements to satisfy the equation.In the above example, this is indeed possible, for instance by choosing We sometimes also call A and B a satisfying assignment.In contrast, the instance has no solution, because the (1, 1) entry of the product on the left is always 0, no matter what values are chosen.Note that the existence of a solution also depends on the characteristic of the base field.For an example, see Chapter 4, page 13 in [4].
The CI problem is of interest to us, because we will see in Section 4 that CI reduces to the problem of computing the interleaving distance, that is, a polynomial time algorithm for computing the interleaving distance will allow us to decide whether a triple (n, P, Q) is in CI, also in polynomial time.Although the definition of CI is rather elementary and appears to be useful in different contexts, we are not aware of any previous work studying this problem (apart from [4]).
It is clear that CI is in NP because a valid choice of the matrices A and B can be checked in polynomial time.We want to show that CI is NP-hard as well.It will be convenient to do so in two steps.First, we define a slightly more general problem, called generalized constrained invertibility (GCI), and show that GCI reduces to CI.Then, we proceed by showing that 3SAT reduces to CI, proving the NP-hardness of CI.
Generalized constrained invertibility.We generalize from the above problem in two ways: first, instead of square matrices, we allow that A ∈ F n×m and B ∈ F m×n (where m is an additional input).Second, instead of forcing AB = I n , we only require that AB coincides with I n in a fixed subset of entries over [n] × [n].Formally, we define Again, we use the following notation * * * 0 0 0 for the GCI instance (2, 3, {(2, 1), (2, 2), (2, 3)}, {(1, 2), (2, 1), (3, 1), (3, 2)}, {(1, 1), (1, 2)}).This instance is indeed in GCI, as for instance, GCI is indeed generalizing CI, as we can encode any CI instance by setting m = n and R = [n] × [n].Hence, CI trivially reduces to GCI.We show, however, that also the converse is true, meaning that the problems are computationally equivalent.We will need the following lemma which follows from linear algebra: Proof.Pick M ′′ ∈ F (m−n)×m so that M M ′′ has full rank.This is possible, as the row vectors of M are linearly independent, so we can pick the rows in M ′′ iteratively such that they are linearly independent of each other and those in M .Let M ′ = M ′′ − M ′′ N M , which gives M ′ also has full rank, which means that it has an inverse.Let N ′ be the last m − n columns of this inverse matrix.We get Lemma 2. GCI is polynomial-time reducible to CI.
Proof.Fix a GCI instance (n, m, P, Q, R).We have to define a polynomial time algorithm to compute a CI instance (n Write the GCI instance as AB = C, where A and B are matrices with 0 and * entries (of dimensions n × m and m × n, respectively), and C is an n × n-matrix with 1 or * entries on the diagonal, and 0 or * entries away from the diagonal (as in the example above).
Define the matrix I * n as the matrix with 0 away from the diagonal and * on the diagonal.Moreover, let C denote the matrix C with all 1-entries replaced by 0-entries.Now, consider the GCI instance which can be formally written as (n, n + m, P ′ , Q ′ , [n] × [n]) for some choices We claim that the original instance is in GCI if and only if the extended instance is in GCI.First, assume that AB = C has a solution (that is, an assignment of field elements to * entries that satisfies the equation).Then, we pick all diagonal entries in I * n as 1, so that the matrix becomes I n .Also, we pick C to be I n − AB; this is indeed possible, as an entry in C is fixed only if the corresponding positions of I n and AB coincide.With these choices, we have that Conversely, if there is a solution for the extended instance, write X for the assignment of I * n and Y for the assignment of C. Then AB + XY = I n .Now fix any index (i, j) ∈ R and consider the equation in that entry.By construction Y i,j = 0, and multiplication by the diagonal matrix X does not change this property.It follows that (AB) (i,j) = (I n ) i,j , which means that AB = C has a solution.Hence, the two instances are indeed equivalent.
To finish the proof, we observe that (1) ) is in GCI.The latter, however, is equivalent to the CI instance (n + m, P ′ , Q ′ ).The conversion can clearly be performed in polynomial time, and the statement follows.
Hardness of GCI.We describe now how a algorithm for how deciding GCI can be used to decide satisfiability of 3SAT formulas.Let φ be a 3CNF formula with n variables and m clauses.We construct a GCI instance that is satisfiable if and only if φ is satisfiable.
In what follows, we will often label some * entries in matrices with variables when we want to talk about the possible assignments of the corresponding entries.
The first step is to build a "gadget" that allows us to encode the truth value of a variable in the matrix.Consider the instance * 0 * 0 * * In any solution to this equation, not both x and y can be zero because otherwise, the right matrix would have rank at most 1.Furthermore, when extending the instance by one row/column we see that both ax = 0 and by = 0 must hold, which is then only possible if at least one entry a or b is equal to 0. In fact, there is a solution with a = 0, and a solution with b = 0, for instance The intuition is that for a variable x i appearing in φ, we interpret x i to be true if a = 0, and to be false if b = 0. We build such a gadget for each variable.A crucial observation is that we can do so with all variable entries placed in the same row.This works essentially by concatenating the variable gadgets, in a block-like fashion.We show the construction for three variables as an example.
Lemma 3.For any n ≥ 1, there exists a GCI instance A ′ B ′ = I 2n+1 with A ′ having 3n + 1 columns, such that in each solution for the problem, A ′ 1,3n+1 is not zero, and for each k = 0, . . ., n − 1, the entries A ′

1,3k+1
and A ′ 1,3k+2 are not both non-zero.Moreover, for any choice of v 1 , . . ., v n ∈ {1, 2}, there exists a solution of the instance in which A ′ 1,3k+vi = 0 for all k = 0, . . ., n − 1. Next, we extend the instance from Lemma 3 with respect to the clauses.We refer to the clauses as c 1 , . . ., c m .For each clause we append one further row to A ′ , each of them identical of the form 0 . . .0 * .
We also append one column to B ′ for each clause, each of length 3n + 1.For each clause, the entry at row 3n + 1 is set to * .If a clause contains a literal of the form x i (in positive form), we set the entry at row 3i + 1 to * .If it contains a literal ¬x i , we set the entry at row 3i + 2 to * .In this way, at most 4 entries in the column are fixed to * , and we fix all other entries to be 0. Continuing the above example, for the clause x 0 ∨ ¬x 1 ∨ x 2 , we obtain a column of the form * 0 0 0 * 0 * 0 0 * Let A and B denote the matrices extended from A ′ and B ′ with the above procedure.We next define C as a square matrix of dimension 2n + 1 + m as follows: The upper left (2n + 1) × (2n + 1) submatrix is set to I 2n+1 .The rest of the first row is set to 0, and the rest of the diagonal is set to 1.All other entries are set to * .This concludes the description of a GCI instance AB = C out of a 3CNF formula φ.We exemplify the construction for the formula ( , where the lines mark the boundary of A ′ and B ′ , respectively.
Lemma 4. AB = C admits a solution if and only if φ is satisfiable.
Proof."⇒": Let us assume that AB = C has a solution, which also implies a solution A ′ B ′ = I 2n+1 being a subproblem encoded in the instance.Fixing a solution, we assign an assignment of the variables of φ as follows: If the entry A 3i+1 is non-zero, we set x i to true.If the entry A 3i+2 is non-zero, we set x i to false.If neither is non-zero, we set x i to false as well (the choice is irrelevant).Note that by Lemma 3, not both A 3i+1 and A 3i+2 can be non-zero, so the assignment is well-defined.First of all, let γ be the entry in the rightmost entry of the first row of A. Because the (1, 1)-entry of C is set to 1, it follows that γδ = 1, where δ is the lowest entry of the first column of B. Hence, in the assumed solution, γ = 0. Now fix a clause c in φ and let v denote the column of B assigned to this clause, with column index i.Recall that v consists of (up to) three * entries chosen according to the literals of c, and a * entry at the lowest position.Let λ denote the value of that lowest entry in the assumed solution of AB = C.We see that λ = 0, with a similar argument as for γ above, using the (i, i)-entry of C. Now, the (1, i) entry of C is set to 0 by construction which yields a constraint of the form where v 1 , v 2 , v 3 are entries of v at the * positions, and µ 1 , µ 2 , µ 3 the corresponding entries of the first row of A. We observe that at least one term µ j v j must be non-zero, hence both entries are non-zero.This implies that the chosen assignment satisfies the clause: if v j is at index 3k + 1 for some k, the clause contains the literal x k by construction and since µ j = 0, our assignment sets x k to true.The same argument applies to v j of the form 3k + 2. It follows that the assignment satisfies all clauses and hence, φ is satisfiable.
"⇐": We pick a satisfying assignment for φ and fill the first row of A as follows: if x i is true, we set (A 1,3i+1 , A 1,3i+2 ) to (1, 0) if x i is false, we set it it (0, 1).By Lemma 3, there exists a solution for A ′ B ′ = I 2n+1 with this initial values and we choose such a solution, filling the upper (2n + 1) rows of A and the left (2n + 1) columns of B. Note that similar as above, the value γ at A 1,3n+1 must be non-zero in such a solution.In the remaining m rows of A, by construction, we only need to pick the rightmost entry, and we set it to γ in each of these rows.That determines all entries of A.
To complete B ′ to B, we need to fix values in the columns of B associated to clauses.In each such column, we pick the lowest entry to be 1 γ , satisfying the constraints of C along the diagonal.Fixing a column i of B, the (1, i)-constraint of C reads as where v 1 , v 2 , v 3 are the remaining non-zero entries in i-th column.Because we encoded a satisfying assignment of φ in the first row of A, at least one µ j entry is 1.We set the corresponding entry v j to −1, and the remaining v k 's to 0. In this way, all constraints is satisfied, and the GCI instance has a solution.
Clearly, the GCI instance of the preceding proof can be computed from φ in polynomial time.It follows: Proof.Lemma 4 shows the reduction of 3SAT to GCI, proving that GCI is NP-complete.As shown in Lemma 2, GCI reduces to CI, proving the claim.

Modules and Interleavings
In what follows, all vector spaces are understood to be F-vector spaces for the fixed base field F. Also, for points p = (p x , p y ), q = (q x , q y ) in R 2 , we write p ≤ q if p x ≤ q x and p y ≤ q y .Persistence modules.A (two-parameter) persistence module M is a collection of F-vector spaces V p , indexed over p ∈ R 2 together with linear maps M p→q whenever p ≤ q.These maps must have the property that M p→p is the identity map on M p and M q→r • M p→q = M p→r for p ≤ q ≤ r.Much more succinctly, a persistence module is a functor from the poset category R 2 to the category of vector spaces.A morphism between M and N is a collection of linear maps {f p : We say that f is an isomorphism if f p is an isomorphism for all p, and denote this by M ∼ = N .If we view persistence modules as functors, a morphism is simply a natural transformation between the functors.The simplest example is the 0-module where M p is the trivial vector space for all p ∈ R 2 .For a more interesting example, define an interval in the poset (R 2 , ≤) to be a non-empty subset S ⊂ R 2 such that whenever a, c ∈ S and a ≤ b ≤ c, then b ∈ S, and moreover, if a, c ∈ S, there exists a sequence of elements We associate an interval module I S to S as follows: for p ∈ S, we set I S p := F, and I S p := 0 otherwise.As map I S p→q with p ≤ q, we attach the identity map if p, q ∈ S, and the 0-map otherwise.
For a ∈ R 2 , let a := {x ∈ R 2 | a ≤ x} be the infinite rectangle with a as lower-left corner.Given k elements a 1 , . . ., a k ∈ R 2 , the set S := i=1,...,k a i is called the staircase with elements a 1 , . . ., a k .We call k the size of the staircase.See Figure 1 for an illustration.It is easy to verify that S is an interval for k ≥ 1.Clearly, if a i ≤ a j , we can remove a j without changing the staircase, so we assume that the elements forming the staircase are pairwise incomparable.The staircase module is the interval module associated to the staircase.Given two persistence modules M and N , the direct sum M ⊕ N is the persistence module where (M ⊕ N ) p := M p ⊕ N p , and the linear maps are defined componentwise in the obvious way.We call a persistence module M indecomposable, if in any decomposition M = M 1 ⊕ M 2 , M 1 or M 2 is the 0module.For example, it is not difficult to see that interval modules are indecomposable.We call M interval decomposable if M admits a decomposition M ∼ = M 1 ⊕ . . .⊕ M ℓ into (finitely many) interval modules.The decomposition of any persistence module into interval modules is unique up to rearrangement and isomorphism of the summands; see [5, Section 2.1] and the references therein.This implies that there is a well-defined multiset of intervals B(M ) given by the decomposition of M into interval modules.The multiset B(M ) is called the barcode of M .Not every module is interval decomposable; we remark that already rather simple geometric constructions can give rise to complicated indecomposable elements [7].
Interleavings.Let ǫ ∈ R. For a persistence module M , the ǫ-shift of M is the module M ǫ defined by M ǫ p = M p+ǫ (where p + ǫ = (p x + ǫ, p y + ǫ)) and M ǫ p→q = M p+ǫ→q+ǫ .Note that (M ǫ ) δ = M ǫ+δ .As an example, staircase modules are closed under shift: the ǫ-shift of the staircase module associated to a i is the staircase module associated to a i − ǫ .We can also define shift on morphisms: for f : M → N , f ǫ : M ǫ → N ǫ is given by f ǫ p = f p+ǫ .For ǫ ≥ 0, there is an obvious morphism Sh M (ǫ) : M → M ǫ given by the internal morphisms of M , that is, we have Sh M (ǫ) p = M p→p+ǫ .In practice we will often suppress notation and simply write M → M ǫ for this morphism.
With this in mind, we define an ǫ-interleaving between M and N for ǫ ≥ 0 as a pair (f, g) of morphisms f : M → N ǫ and g : N → M ǫ such that g ǫ • f = Sh M (2ǫ) and f ǫ • g = Sh N (2ǫ).Concretely, an ǫ-interleaving between two persistence modules M and N is a collection of maps such that all diagrams that can be composed out of the maps f * , g * , and the linear maps of M and N commute.Note that a 0-interleaving simply means that the persistence modules are isomorphic.Also, an ǫ-interleaving induces a δ-interleaving for ǫ < δ directly by a suitable composition with the linear maps of the modules.We say that two modules are ǫ-interleaved if there exists an ǫ-interleaving between them.We define the interleaving distance of two modules M and N as Note that d I defines a metric on the space of persistence modules modulo isomorphisms.The triangle inequality follows from the simple observation that an ǫ-interleaving between M 1 and M 2 and a δ-interleaving between M 2 and M 3 can be composed to an (ǫ + δ)-interleaving between M 1 and M 3 .
Representation of persistence modules.For studying the computational complexity of the interleaving distance, we need to specify a finite representation of persistence modules that allows us to pass such modules as an input to an algorithm.
A graded matrix representation of a module M is a 3-tuple (G, R, A), where G = {g 1 , . . ., g n } is a list of n points in R 2 , R = {r 1 , . . ., r m } is a list of m points in R 2 , (with repetitions allowed), and A is an (m × n)-matrix over the base field F. Equivalently, we can simply think of a matrix A where each row and column is annotated with a grading in R 2 .
The algebraic explanation for this representation is as follows: it is known that a persistence module M over R 2 can be equivalently described as a graded R-module over a suitably chosen ring R. Assuming that M is finitely presented, we can consider the free resolution of M A graded matrix representation is simply a way to encode the map ∂ in this resolution.
Let us describe for concreteness how a representation (G, R, M ) gives rise to a persistence module.First, let F 1 , . . ., F n be copies of F, and let e i be the 1-element of F i .For p ∈ R 2 , we define Gen p as the direct sum of all F i such that g i ≤ p.Moreover, every row of M gives rise to a linear combination of the entries e 1 , . . ., e n .Let c i denote the linear combination in row i.We define Rel p to be the span of all linear combinations c i for which r i ≤ p.Then, we set which is a F-vector space.For p ≤ q, writing [x] p for an element of M p with x ∈ Gen p , we define It is easy to check that that [x] q is well-defined (since Gen p ⊆ Gen q ) and independent of the chosen representative in Gen p (since Rel p ⊆ Rel q ).Moreover, it is straightforward to verify that these maps satisfy the properties of a persistence module.
In short, every persistence module that can be expressed by finitely many generators and relations can be brought into graded matrix representation.For instance, a staircase module for a 1 , . . ., a n of size n where the a i are ordered by increasing first coordinate can be represented by a matrix with n columns graded by a 1 , . . ., a n , and n − 1 rows, where every row corresponds to a pair (i, i + 1) with 1 ≤ i ≤ n − 1.In this row, we encode the relation e i = e i+1 and grade it by p ij , which is the (unique) minimal element q in R 2 such that a i ≤ q and a i+1 ≤ q.Hence, the graded matrix representation of a staircase of size n has a size that is polynomial in n.
We also remark that a graded matrix representation is equivalent to free implicit representations [15, Sec 5.1] for the special case of m 0 = 0.

Hardness of interleaving distance
We consider the following computational problems: 1-Interleaving: Given two persistence modules M , N in graded matrix representation, decide whether they are 1-interleaved.c-Approx-Interleaving-Distance: Given two persistence modules M , N in graded matrix representation, return a real number r such that Obviously, the problem of computing d I (M, N ) exactly is equivalent to the above definition with c = 1.The main result of this section is the following theorem: Theorem 6.Given a CI-instance (n, P, Q), we can compute in polynomial time in n a pair of persistence modules (M, N ) in graded matrix representation such that Moreover, both M and N are direct sums of staircase modules and hence interval decomposable.
We will postpone the proof of Theorem 6 to the end of the section and first discuss its consequences.
Proof.We first argue that 1-Interleaving is in NP.First, note that to specify a 1-interleaving, it suffices to specify the maps at the points in S, where S is a finite set whose size is polynomial in the size of the graded matrix representation.More precisely, S contains the critical grades of the two modules (that is, the grades specified by G and R), as well as the least common successors of such elements.That ensures that every vector space (in both modules) can be isomorphically pulled back to one of the elements of S, and the interleaving map can be defined using this pull-back.It is enough to consider the points in S to check if this set of pointwise maps is a valid morphism.We can furthermore argue that verifying that a pair of such maps yields a 1-interleaving can be checked in a polynomial number of steps.Again, this involves mostly the maps specified above, as well as the corresponding maps shifted by (1,1), in order to check the compatibility of the two interleaving maps.We omit further details of this step.
Finally, 1-Interleaving is NP-hard: Assuming a polynomial time algorithm A to decide the problem, we can design a polynomial time algorithm for CI just by transforming (n, P, Q) into a pair of modules (M, N ) using the algorithm from Theorem 6.If A applied on (M, N ) returns true, we return that (n, P, Q) is in CI.Otherwise, we return that (n, P, Q) is not in CI.Correctness follows from Theorem 6, and the algorithm runs in polynomial time, establishing a polynomial time reduction.By Theorem 5, CI is NPhard, hence, so is 1-Interleaving.

Theorem 8. c-Approx-Interleaving-Distance is NP-hard for every c < 3 (i.e., a polynomial time algorithm for the problem implies P=NP).
Proof.Fixing c < 3, assuming a polynomial time algorithm A for c-Approx-Interleaving-Distance yields a polynomial time algorithm for CI: Given the input (n, P, Q), we transform it into (M, N ) with Theorem 6.Then, we apply A on (M, N ).If the result is less than 3, we return that (n, P, Q) is in CI.Otherwise, we return that (n, P, Q) is not in CI.Correctness follows from Theorem 6, noting that if (n, P, Q) is in CI, algorithm A must return a number in the interval [1, c] and c < 3 is assumed.If (n, P, Q) is not in CI, it returns a number ≥ 3. Also, the algorithm runs in polynomial time in n.Therefore, the existence of A yields a polynomial time algorithm for CI, implying P=NP with Theorem 5.
Since the modules in Theorem 6 are direct sums of staircases, both Theorem 7 and Theorem 8 hold already for the restricted case that the modules are interval decomposable.
Interleavings of staircases.The persistence modules constructed for the proof of Theorem 6 will be direct sums of staircases.Before defining them, we establish some properties of interleaving map between staircases and their direct sums which reveal the connection to the CI problems.
Recall from Section 3 that a morphism M → N can be described more concretely as a collection of maps M p → N p that are compatible with the linear maps in M and N , that M ǫ is defined by M ǫ p = M p+ǫ , and that an ǫ-interleaving is a pair of morphisms φ : M → N ǫ , ψ : N → M ǫ satisfying certain conditions.For staircase modules, the set of morphisms is quite limited.
For M and N staircase modules and λ ∈ F, we denote by 1 → λ the collection of linear maps φ p such that φ p (1) = λ for all p such that M p = F. Lemma 9. Let M and N be staircase modules.Every morphism from M to N is of the form 1 → λ for some λ ∈ F.
Proof.Assume first that p ≤ q and M p = F. Write λ := φ p (1).Then, also M q = F, and φ p (1) = λ as well, since the linear maps from p to q for M and N are injective maps.
For incomparable p and q ∈ R 2 , we consider the least common successor r of p and q.Using the above property twice, we see at once that φ p (1) = φ r (1) = φ q (1).
We examine next which values of λ are possible for a concrete pair of staircases.For a staircase S, let S ǫ denote the staircase where each point is shifted by (ǫ, ǫ).This way, if M is the module associated to S, M ǫ is the module associated to S ǫ .As we noted before, the shift of a staircase module is also a staircase module.Define the directed shift distance from the staircase S to the staircase T as One can show that the set on the right-hand side has a minimum value by using the fact that a staircase are generated by a finite set of elements, so d s is in fact well defined.Proof.In the first case, by construction, there exists some p such that M p = F, but N p+ǫ = 0. Hence, 0 is the only choice for λ.
In the second case, M p = F implies N p+ǫ = F as well.It is easy to check that any choice of λ yields a compatible collection of maps, hence a morphism.
In particular, there are morphisms M → N given by arbitrary elements of F if and only if S ⊆ T .As a consequence, we can characterize morphisms of direct sums of staircase modules.Lemma 11.Let M = ⊕ n i=1 M i and N = ⊕ n j=1 N j be direct sums of staircase modules.Then a collection of maps φ p : M p → N p is a morphism if and only if the restriction to M i and N j is a morphism for any i, j ∈ {1, . . ., n}.Therefore, a morphism φ is determined by an (n × n)-matrix with entries in F.
Proof.Let p ≤ q, and consider the following diagram: We have M p = ⊕ n i=1 (M i ) p and N q = ⊕ n j=1 (N j ) q .Thus the diagram above commutes if and only if for all i and j, the restrictions of the two compositions to (M i ) p and (N j ) q the same, since a linear transformation is determined by what happens on basis elements.This is again equivalent to the following diagram commuting for all i and j, where (φ j i ) p is the restriction of φ p to M i and N j : But the collection of φ p forms a morphism if and only if the first diagram commutes for all p ≤ q, and the restriction of φ p to M i and N j form a morphism if and only if the second diagram commutes for all p ≤ q.
Thus we have proved the desired equivalence.
Observe that the matrix described in Lemma 10 is simply φ p : ⊕ n i=1 (M i ) p → ⊕ n j=1 (N j ) p written as a matrix in the natural way for any p contained in the support of M i for all i.
Lemma 12. Let M , N be direct sums of staircase modules as above and φ : M → N ǫ and ψ : N → M ǫ be morphisms.Then φ and ψ form an ǫ-interleaving and only if their associated (n × n)-matrices are inverse to each other.
Proof.The composition ψ ǫ • φ : M → M 2ǫ is represented by the matrix BA, as one can see by restricting to a single point contained in all relevant staircases as in the observation above.The morphism Sh M (2ǫ) : M → M 2ǫ is represented by the identity matrix.By definition, (φ, ψ) is an interleaving if and only if these are equal and the corresponding statement holds for φ ǫ • ψ, so the statement follows.
As a consequence, we obtain the following intermediate result Theorem 13.Let (n, P, Q) be a CI-instance and let S 1 , . . ., S n , T 1 , . . ., T n be staircases such that Write M i , N j for the modules associated to S i , T j , respectively, and M := ⊕M i and N := ⊕N j .Then Proof.Assume first that (n, P, Q) ∈ CI.Let A, B be a solution.We show that A and B define morphisms from M to N 1 and from N to M 1 .We restrict to the map from M to N 1 , as the other case is symmetric.By Lemma 11, it suffices to show that the map from M i to N 1 j is a morphism.This map is represented by the entry A ij .If (i, j) ∈ P , A ij = 0 by assumption, and the 0-map is always a morphism.If (i, j) / ∈ P , d S (S i , T j ) = 1 by construction.Hence, by Lemma 10 any field element yields a morphism.This argument shows that M and N are 1-interleaved.Also with Lemma 10, it can easily be proved that the only morphism M → N ǫ with ǫ < 1 is the 0-map.Hence, d I (M, N ) = 1 in this case.Now assume that (n, P, Q) / ∈ CI.It is clear that M and N as constructed are 3-interleaved: the matrix I n yields a valid morphism from M to N 3 and from N to M 3 with Lemma 10.Assume for a contradiction that there exists an ǫ-interleaving between M and N represented by matrices A, B, with ǫ < 3.For (i, j) ∈ P , since d s (M i , N j ) = 3 > ǫ, Lemma 10 implies that the entry A i,j must be equal to 0. Likewise, B j,i = 0 whenever (j, i) ∈ Q.Since AB = I n , it follows that A and B constitute a solution to the CI-instance (n, P, Q), a contradiction.
Construction of the staircases.To prove Theorem 6, it suffices to construct staircases S 1 , . . ., S n , T 1 , . . ., T n with the properties from Theorem 13, in polynomial time.
To describe our construction, we consider to two "base staircases" which we depict in Figure 2. The base staircase S is formed by the points (−t, t) for t = −2n 2 , . . ., 2n 2 , but with the right side (i.e., the points with negative t) shifted down by (1,1).Likewise, the base staircase T consists of the same points, but with the left side shifted down by (1,1).We observe immediately that the staircase distance of the two base staircases is equal to 1 in either direction.We call the points defining the staircases corners from now on.Now we associate to every entry in P a corner in the left side of T (that is, some (−t, t) with t > 0. We also associate with the entry a corner in S, namely the shifted point (−t − 1, t − 1).We do this in a way that between two associated corners of S, there is at least one corner of the staircase that is not associated.Note that this is always possible because |P | ≤ n 2 and we have 2n 2 corners on the left side.We associate corners to entries of Q in the symmetric way, using the right side of the base staircases.
We construct the staircases S i and T j out of the base staircases S and T , only shifting associated corners by (2, 2) or (−2, −2) according to P and Q.Specifically, for the staircase S i , we start with S and for any entry (i, j) in P , we shift the associated corner of S by (−2, −2).For every entry (j, i) in Q, we shift the associated corner by (2,2).The resulting (partially) shifted version of S defines S i .
We next analyze the staircase distance of S i and T j .We observe that, because there is an unassociated corner in-between any two associated corners, the ±(2, 2) shifts of distinct corners do not interfere with each other.Hence, it suffices to consider the distance of one associated corner of S i to T j .Fix the corner c S of S associated to some entry (k, ℓ) ∈ P .Let c T denote the associated corner of T , that is, c T = c S − (1, 1).See Figure 3 (left) for an illustration.If k = i and ℓ = j, neither c S nor c T gets shifted, and since c T ≤ c S , the shift required from c S to reach T j is 0. If k = i and ℓ = j, then c S gets shifted by (−2, −2), and the required shift is 1 (see second picture of Figure 3).If k = i and ℓ = j, c T gets shifted by (2, 2), the required shift is also 1 (see 3rd picture of Figure 3).If k = i and ℓ = j, both c S and c T get shifted, and the distance of the shifted c S to reach T j increases to 3 (see 4th picture of Figure 3).This argument implies that the (directed) staircase distance from S i to T j is 3 if (i, j) ∈ P , and 1 otherwise.A completely symmetric argument works for d S (T j , S i ), inspecting the corners associated to Q.
Finally, it is clear that the size and construction time of each S i and each T j is polynomial in n.As remarked at the end of Section 3, the staircase module can be brought in graded matrix representation in polynomial time in n, and the same holds for the direct sum of these modules.This finishes the proof of Theorem 6.

Indecomposable modules
Fix a CI-problem (n, P, Q) as in the previous section and let M and N be the associated persistence modules.We shall now construct two indecomposable persistence modules M and N such that M and N The two neighboring corners on both staircases (marked with x) are not associated and hence not shifted in the construction.Second and third picture: the cases (i, ℓ) with ℓ = j and (k, j) with k = i.In both cases, the directed staircase distance is 1, as illustrated by the dashed line.Right: The case (i, j).In that case, a shift of 3 is necessary to move the corner of S on T .
are ǫ-interleaved if and only if M and N are ǫ-interleaved.In what follows we construct M ; the construction of N is completely analogous.
Recall that a staircase module can be described by a set of generators, or corners.Let u = (x, x) be a point larger than all the corners defining the staircases making up M and N .Observe the following: dim M u = n, M u→p is the identity morphism for any p ≥ u, and if p is any point such that 0 < dim M p < n, then p < u. Let Trivially, M p→q is the 0 morphism if M p = 0 or M q = 0.For p ≤ q such that M p = M p and M q = M q , let M p→q = M p→q , and for p, q ∈ [s i , s i+1 ) × [s n−i , s n−i+1 ) let M p→q = 1 F .It remains to consider the case that M p = M p and q ∈ [s i , s i+1 ) × [s n−i , s n−i+1 ) for some i.Observe that all the internal morphisms are fully specified once we define M u→q .Indeed, if p ≥ u, then M u→p is the identity, which forces M p→q = M u→q .For any other p we can always choose an r ≥ p such that r ≥ u and M r = M r .The morphism M p→q is then given by M p→q = M r→q • M p→r = M u→q • M p→r .We conclude by specifying the following morphism Observe that we have an morphism π M : M → M given by The persistence module M is indecomposable.
Proof.We recall the following useful trick: if M is not indecomposable, say M ∼ = M ′ ⊕ M ′′ , then the projections M → M ′ and M → M ′′ define morphisms which are not given by multiplication with a scalar.Hence, it suffices to show that any endomorphism φ : M → M is multiplication by a scalar.Furthermore, observe that any endomorphism φ of M is completely determined by φ u .Let e i ∈ F n denote the vector (0, . . ., 0, 1, 0, . . ., 0) where the non-zero entry appears at the i-th index.For 0 ≤ i ≤ n, φ must be such 1 7 can be replaced with any δ > 6.
(s 1 , s 5 ) For 1 ≤ i ≤ n this yields that In particular, we see that φ u (e i ) = λ i e i .For i = 0 we get We conclude that λ i = λ 0 and that φ u = λ 0 • id.
We will show that these two morphisms constitute an ǫ-interleaving pair.Let p ∈ R 2 and consider the following two cases: 1. Assume that N p+ǫ = N p+ǫ .Under this assumption we have that π N p+ǫ = id, and thus φ p = φ p .Using that ψ and φ form an ǫ-interleaving pair, and that π M p = id, we get: 2. Assume that N p+ǫ = N p+ǫ .Since ǫ ≥ 1, it follows by construction that M p+2ǫ = 0. Hence, the interleaving condition is trivially satisfied.
Conversely, assume that φ and ψ define an interleaving pair between M and N .Define φ : M → N ǫ and ψ : N → M ǫ by By construction, M p = M p and N p = N p for all p < u + (7,7).This implies that φ p = φ u and ψ p = ψ u for all p < u + (7 − ǫ, 7 − ǫ).Hence, for any p ≤ u we must have that Similarly we get that φ p+ǫ • ψ p = N p→p+2ǫ for all such p.In particular, by considering the case p = u, we see that φ u and ψ u are mutually inverse matrices.It follows readily that the interleaving condition is satisfied for all p ≤ u.
With the two previous results at hand, we can state the following corollary of Theorem 8.
Corollary 16. 1-interleaving is NP-complete and c-Approx-Interleaving-Distance is NP-hard for c < 3, even if the input modules are restricted to indecomposable modules.
Proof.We only prove hardness of 1-interleaving, the remaining statements follow with the same methods.Given a CI-instance (n, P, Q), we use the construction from Section 4 to construct two persistence modules M and N .Then we transform them into the indecomposable modules M and N as above.Note that this transformation can be performed in polynomial time in n by introducing up to n relations at the lower-left corners of the (n + 1) rectangles in Figure 4. Hence, an algorithm to decide 1-interleaving for the case of indecomposable modules would solve CI in polynomial time.
6 One-sided stability The results of the previous sections also apply in the setting of one-sided stability.Here we give a brief introduction to the topic; see [1] for a thorough introduction.
Let f : M → N be a morphism.The linear map M p→q induces a linear map ker(f p ) → ker(f q ) by restriction, and N p→q induces a linear map coker(f p ) → coker(f q ) by taking a quotient, as one can readily verify.We say that f has ǫ-trivial kernel if the map ker(f p ) → ker(f p+ǫ ) is the 0-map for all p ∈ R 2 .Likewise, we say that f has ǫ-trivial cokernel if coker(f p ) → coker(f p+ǫ ) is the 0-map for all p ∈ R 2 .If f has 0-trivial kernel (cokernel), then we say that f is injective (surjective).The following lemma follows readily from the definition of an ǫ-interleaving.
Lemma 17.If f : M → N ǫ is an ǫ-interleaving morphism, then f has 2ǫ-trivial kernel and cokernel.
In fact, Bauer and Lesnick [1] show that in the case of persistence modules over R, M and N are ǫinterleaved if and only if there exists a morphism f : M → N ǫ with 2ǫ-trivial kernel and cokernel.They also observe that this equivalence does not generalize to two parameters.However, it is true (and the proof is very similar to the one given below) that if there exists a morphism f : M → N ǫ with ǫ-trivial kernel and cokernel, then M and N are ǫ-interleaved.Hence, there is a close connection between interleavings and morphisms with kernels and cokernels of bounded size also in the multi-parameter landscape.
Lemma 18.For any injective f : M → N ǫ with 2ǫ-trivial cokernel, there exists a morphism g : N → M ǫ such that f and g constitute an ǫ-interleaving pair.
Proof.We have the following commutative square for all p ∈ R 2 : Let n ∈ N p+ǫ .Since f has 2ǫ-trivial cokernel and f is injective, there exists a unique m ∈ M p+2ǫ such that f p+2ǫ (m) = N p+ǫ→p+3ǫ (n).Define g p : N p+ǫ → M p+2ǫ by g p (n) = m.Doing this for all p ∈ R 2 defines a morphism g : N ǫ → M 2ǫ and we leave it to the reader to verify that f and g −ǫ define an ǫ-interleaving pair.
For fixed parameters s, t ∈ [0, ∞], we consider the following computational problem: s-t-trivial-morphism: Given two persistence modules M , N in graded matrix representation, decide whether there exists a morphism f : M → N with s-trivial kernel and t-trivial cokernel.
Choosing s = t = 0 simply asks whether the modules are isomorphic, which can be decided in polynomial time [6].On the other extreme, s = t = ∞ imposes no conditions on the morphism, which turns the decision problem to be trivially true, using the 0-morphism.We show Theorem 19.s-t-trivial-morphism is NP-complete for every (s, t) / ∈ {(0, 0), (∞, ∞)}.
The case (s, t) is computationally equivalent to the case (cs, ct) with c > 0, since we can scale all grades occurring in M and N by a factor of c.So, it suffices to prove hardness of 2-t-trivial morphism, s-2trivial morphism (we will see that the choice of 2 will be convenient in the argument), ∞-0-trivial morphism and 0-∞-trivial morphism.
Note that for any choice of s and t, s-t-trivial-morphism is in NP.The argument is similar to the first part of the proof of Theorem 7: a morphism can be specified in polynomial size with respect to the module sizes, and we can check the triviality conditions of the kernel and cokernel by considering ranks of matrices.
For the hardness, we first focus on the case (s, 2), hence we want to decide the existence of a morphism with s-trivial kernel and 2-trivial cokernel.The following simple observation is the key insight of the proof.
Lemma 20.Let M , N be as in Theorem 6.Any morphism f : M → N 1 with 2-trivial cokernel is injective.
Proof.Recall that both M and N are direct sums of n staircase modules.Let p be any point such that dim M p = dim N p = n, and observe that M p→q = id F , N p→q = id F and f p = f q for all q ≥ p.In particular, if q = p + (2, 2), the induced map coker(f p ) → coker(f q ) is the identity, and since f has a 2-trivial cokernel by assumption, the map is also the 0-map.Hence coker(f p ) is trivial, implying that the map f p is surjective, and hence also injective, and the same holds for f q with q ≥ p.Now consider f r for an arbitrary r ∈ R 2 .Let q ≥ r be a point satisfying q ≥ p.Since the internal morphisms of M are all injective and f p is injective, so is f r .
In other words, for M and N 1 as above, the answer to s-2-trivial-morphism is independent of s.Moreover, it follows: Corollary 21.With M, N as above, there exists a morphism f : M → N 1 with 2-trivial cokernel and s-trivial kernel if and only if M and N are 1-interleaved.
Proof.If such a morphism exists, Lemma 20 guarantees that the morphism is in fact injective with 2-trivial cokernel.Lemma 18 with ǫ = 1 guarantees that the modules are 1-interleaved.
Vice versa, if M and N are 1-interleaved, there is a morphism f with 2-trivial kernel and cokernel by Lemma 17. Again using Lemma 20 guarantees that f is injective, hence has a 0-trivial kernel.This can be seen as follows: since a and b are incomparable, and that a ∈ A while a / ∈ N 2 , we must have that N 2 A. Lemma 10 allows us to conclude that the only morphism from A → N 2 is the trivial one.Similarly we see that the morphism B → N 1 must be the trivial one.Furthermore, since M a = A a and N a = (N 2 ) a , surjectivity at a implies that A → N 1 must be nonzero, which gives the nonzero entry in the first column.We can multiply any column in the matrix with a nonzero element without changing the validity or surjectivity of the morphism, so we can assume that this element is 1.Similarly we get a 1 in the second row of the second column.
We proceed our inductive step by defining G(g r i ) = {A, M r i , N 1 , N 2 } for all 1 ≤ i ≤ n and 1 ≤ r ≤ q.Restricting the matrix to the columns corresponding to A and M r i we get 1 * 0 * .
For the morphism to be surjective at the point g r i , this matrix must be of full rank.Therefore we can write it as where we again have used the fact that we can scale columns by nonzero constants.In other words, any surjection M → N must be of the form Continuing, let G(g r,s i ) = {M r i , M s i , N 1 , N 2 }, for all 1 ≤ i ≤ n and 1 ≤ r < s ≤ q.Restricting the matrix to the columns corresponding to M r i and M s i yields the matrix .
For the matrix to be surjective at g r,s i , also this matrix must be of full rank.In particular, it must be the case that d r i = d s i , and therefore exactly one of d 1 i , . . ., d q i equals 0. We will interpret d 1 i = 0 as choosing x i to be false, and d 1 i = 0 as choosing x i to be true.What remains is to encode the clauses of φ.For a clause c j , let x αj,1 , x αj,2 , x αj,3 be the variables such that either the variable itself or its negation occurs in c j , with α j,1 < α j,2 < α j,3 .For 1 ≤ i ≤ 3, let X i j = {1} if x αj,i occurs in c j ; if instead its negation occurs, let X i j = {2, . . ., q}.For example, if c j = x 1 ∨ ¬x 2 ∨ ¬x 4 , then α j,1 = 1, α j,2 = 2 and α j,3 = 4, and X 1 j = {1}, X 2 j = {2, . . ., q} and X 3 j = {2, . . ., q}.Define G(h y,z,w j ) = {B, M r αj,1 , M s αj,2 , M t αj,3 , N 1 , N 2 }, for all 1 ≤ j ≤ m and y ∈ X 1 j , z ∈ X 2 j , w ∈ X 3 j .This time, the following submatrix must have rank 2 for all h y,z,w j with j, y, z, w as above.
At this stage we have concluded the construction of the modules and no further restrictions will be imposed on the matrix.In particular, the above shows that there exists a surjection M → N if and only if there is an assignment d r i ∈ F such that the following is satisfied: • F = {d 1 i , . . ., d q i } for all 1 ≤ i ≤ n. • The matrix of Eq. ( 5) has full rank for every h y,z,w j .We show that this is equivalent to φ being satisfiable.
"⇒": Assume that φ is satisfiable and pick a satisfying assignment.If x i is set to false, then define d 1 i = 0.If x i is set to true, then define d 2 i = 0.In both cases we assign the remaining variables values such that F = {d 1 i , . . ., d q i } for all 1 ≤ i ≤ n.Consider the clause c j as above, and assume that x α j,l is assigned a truth value such that the literal associated to x α j,l in c j evaluates to true.Then d y α j,l = 0 for all y ∈ X l j , implying that the matrix of Eq. ( 5) has rank 2 for all h y,z,w j ."⇐": Assume an assignment of the variables d r i satisfying the two bullet points above, and set x i to be false if d 1 i = 0, and true otherwise.Consider the clause c j as above, and observe that there exists an index y ∈ X l j such that d y α j,l = 0 if and only if the literal in c j associated to x α j,l evaluates to false.In particular, c j evaluates to true if and only if at least one of d y αj,1 , d z αj,2 and d w αj,3 is non-zero for every (x, y, z) ∈ X 1 j × X 2 j × X 3 j .This is equivalent to the matrix of Eq. ( 5) having full rank for every h y,z,w j .In the end, we have a reduction from 3SAT to ∞-0-trivial-morphism. To complete the proof, we must show that the instance of ∞-0-trivial-morphism can be constructed in polynomial time in the input size of the instance of 3SAT.As we have assumed q to be fixed and finite, it suffices to observe that M is defined by nq + 2 staircase modules, while N is a sum of 2 staircase modules, and that each of these are generated by at most 2 + nq + n q 2 + m(q − 1) 3 generators.We remark that the generators can be chosen along the antidiagonal x = −y in R 2 .
An interesting point is that the number of generators of the staircases in the proof increases with the size of F. Hence, the proof strategy only applies in the setting of a finite field.
We conclude this section by remarking that 0-∞-trivial-morphism is equivalent to the problem of deciding if a module M ′ is a submodule of another persistence module M .Interestingly, it can be checked in polynomial time if M ′ is a summand of M [6, Theorem 3.5].

Conclusion
We settled the computational complexity of interleaving distance computation for persistence modules indexed over R 2 .Clearly, our results readily extend to modules indexed over R d with d ≥ 2.
We also show hardness of approximating the interleaving distance to any constant factor < 3, even for the special cases of staircase decomposable modules and indecomposable modules.However, the question remains open of whether a 3-approximation for either of these special cases can be computed in polynomial time.To our knowledge, there is currently no polynomial time approximation algorithm known for any constant factor.This is related to the questions of stability, more precisely of whether d B (B(M ), B(N )) ≤ 3d I (M, N ) is true for staircase decomposable modules, where d B is the bottleneck distance.If the inequality holds, computing the bottleneck distance gives a polynomial time 3-approximation, and it seems likely that such an algorithm can be generalized to more general interval decomposable modules, or any other set of modules one can relate to (G)CI problems.Another consequence of the inequality would be that even if c-approximation is NP-hard for general modules for c ≥ 3, our method probably cannot be used to prove this.If d B 3d I for staircase decomposable modules in general, however, it is plausible that NP-hardness of c-approximation for some c ≥ 3 can be proved with our method.
Lastly, we investigated the problem of deciding one-sided stability.Except for checking isomorphism, which is known to be polynomial, we we show that all non-trivial cases are NP-hard.This includes checking whether a module is a submodule of another.While our assumption that we are working over a finite field stays in the background for most of the paper, we rely heavily on this assumption for proving the submodule problem.
Clearly, d s (M, N ) = d s (N, M ) in general.The following simple observation is crucial for our arguments.Let M , N denote the staircase modules induced by S and T .Lemma 10.If ǫ < d s (S, T ), the only morphism from M to N ǫ is 1 → 0. If ǫ ≥ d s (S, T ), every choice of λ ∈ F yields a morphism 1 → λ from M to N ǫ .

Figure 2 :
Figure 2: The base staircases S and T .

Figure 3 :
Figure3: Left: The associated corners c S (on staircase S) and C T (on staircase T ) are marked by black circles.The two neighboring corners on both staircases (marked with x) are not associated and hence not shifted in the construction.Second and third picture: the cases (i, ℓ) with ℓ = j and (k, j) with k = i.In both cases, the directed staircase distance is 1, as illustrated by the dashed line.Right: The case (i, j).In that case, a shift of 3 is necessary to move the corner of S on T .

Figure 4 :
Figure 4: Left: M coincides with M on the restriction to the shaded subset of R 2 .Right: this shows the modification done to M in order to obtain an indecomposable persistence module M in the case n = 4.