1 Introduction

Overview on prior work

The matrix exponential and associated φ-functions play a crucial role in some numerical methods for solving systems of differential equations. In practice, this means that the vector etAv for a time step t, for a given matrix A and a given vector v, representing the time propagation for a linear initial value problem, is to be approximated. Similarly, the associated φ-functions (see (2.2) below) conform to solutions of certain inhomogeneous differential equations. In particular, evaluation of φ-functions is used in exponential integrators [27].

If the matrix A is sparse and large, approximation of the action of these matrix functions in the class of Krylov subspaces is a general and well-established technique. For the matrix exponential and φ-functions, this goes back to early works in the field of chemical physics [39, 44], parabolic problems [20], some nonlinear problems [18], etc. The case of a symmetric or skew-Hermitian matrix A is the most prominent one. Krylov approximations of the matrix exponential were early studied for the symmetric case in [12, 13, 46], and together with φ-functions in a more general setting [26, 28].

Concerning different approaches for the numerical approximation of the matrix exponential see [36]. In [46] it is shown for the symmetric case that the Krylov approximation is equivalent to interpolation of the exponential function at associated Ritz values. This automatically results in a near-best approximation among other choices of interpolation nodes, see also [12, 52] and further works [3] with similar results for the non-symmetric case and general functions including φ-functions. For other polynomial approaches approximating the matrix exponential, we mention truncated Taylor series [2] (and many works well in advance), Chebychev interpolation [54], or the Leja method [8], where [2] also covers φ-functions.

In general, Krylov approximations (or other polynomial approximations) result in an accurate approximation if the time step t in etAv is sufficiently small or the dimension of the Krylov subspace (i.e., the degree of the approximating matrix polynomial) is sufficiently large, see for instance [26]. The dimension of the Krylov subspace is limited in practice, and large time steps require a restart of the iteration generating the Krylov basis. A larger time step t can be split into smaller substeps for which the Krylov approximation can be applied in a nested way. Such a restarting strategy in the sense of a time integrator was already exploited in [44]. In particular we refer to the EXPOKIT package [49]. Similar ideas can be applied for the evaluation of φ-functions [28, 41, 49].

In practice, a posteriori error estimates are used to choose a proper Krylov dimension or proper (adaptive) substeps if the method is restarted as a time integrator. Different approaches for a posteriori error estimation concerning the exponential function make use of a series expansion for the error given [46] or use a formulation via the defect (also called residual) of the Krylov approximation [5, 9, 11, 28]. A prominent error estimate concerning φ-functions is the generalized residual estimate introduced in [28], which is based on the residual of a matrix inverse. Furthermore, a series expansion of the error concerning φ-functions is given in [49] (similar to the series expansion concerning the exponential in [46]) and leading terms of this series are used for a posteriori error estimation in [41, 49]. Further a priori as well as a posteriori error estimates for the exponential function are are given in [3, 10, 30, 31, 34, 37, 56], where [10, 30] also consider φ-functions. Restarting via substeps based on different choices of error estimates is further discussed in [30]. A restart with substeps together with a strategy to choose the Krylov dimension in terms of computational cost was presented in [6, 41]. For various other approaches for restarting (without adapting the time step) we refer to [1, 5, 9, 15, 16, 40, 48, 53].

The influence of round-off errors on the construction of the Krylov basis in floating point arithmetic was early studied for the symmetric case in [43, 45]. The orthogonalization procedure can behave numerically unstable, typically due to a loss of orthogonality. Nevertheless, the near-best approximation property and related a priori convergence results are not critically affected [11, 13]. Following [11], in the symmetric case the defect obtained in floating point arithmetic results in numerically stable error estimates.

Beside the polynomial Krylov method, further studies are devoted to the approximation of matrix functions using so called extended Krylov subspaces [14, 21, 32], rational Krylov subspaces [17, 22, 38], or polynomial Krylov subspaces with a harmonic Ritz approach [25, 48, 57].

Overview on results presented here

In Section 2, we introduce the problem setting and recapitulate basic properties of Krylov subspaces.

In Section 3, we introduce the defect associated with Krylov approximations to φ-functions, including the exponential function as the basic case. Our approach for the defect is different from [57] and is based on an inhomogeneous differential equation for the approximation error. This is used in Theorem 1 to obtain an integral representation of the error, also taking effects of floating point arithmetic into account.Footnote 1 In contrast to previous works ([11, 30]), this result is extended to φ-functions here.

This upper bound is further analyzed in Section 4 to obtain computable a posteriori bounds, in particular a new a posteriori bound (Theorem 4). We also study the accuracy of our and other existing defect-based bounds [30] with respect to spectral properties of the Krylov Hessenberg matrix (the representation of A in the orthogonal Krylov basis). To this end we use properties of divided differences including a new asymptotic expansion for these given in Appendix C. In Section 4.1, we consider error estimates based on a quadrature estimate of the defect norm integral: The generalized residual estimate [28] for the approximation of φ-functions which conforms to a quadrature of the defect norm integral (namely, the right-endpoint rectangle rule), and the effective order estimate, which was introduced for the approximation of the matrix exponential in [30] and is extended to φ-functions in the present work. We also discuss cases for which the defect norm behaves oscillatory and reliable quadrature estimates may be difficult to obtain. In Section 4.2, we specify a stopping criterion for the so-called lucky breakdown in floating point arithmetic which is justified by our a posteriori error bounds.

In Section 5, we illustrate our results via numerical experiments. This includes further remarks on previously known error estimates for the Krylov approximation of φ-functions.

2 Problem statement and Krylov approximation

We discuss the approximation via Krylov techniques for evaluation of the matrix exponential, and in particular of the associated φ-functions, for a step size t > 0 and matrix \(A\in {\mathbb {C}}^{n\times n}\) applied to an initial vector \(v\in {\mathbb {C}}^{n}\). Here,

$$ \mathrm{e}^{tA} v = \sum\limits_{k=0}^{\infty} \frac{(tA)^{k}}{k!} v. $$
(2.1)

The matrix exponential u(t) = etAv is the solution of the differential equation

$$ u^{\prime}(t)=Au(t),~~~u(0)=v. $$

The associated φ-functions are given by

$$ \varphi_{p}(tA)v = \sum\limits_{k=0}^{\infty} \frac{(tA)^{k}}{(k+p)!} v,~~~ p \in \mathbb{N}_{0}. $$
(2.2)

This includes the case \(\varphi _{0} = \exp \). The matrix functions (2.1) and (2.2) are defined according to their scalar counterparts. The following definitions of φp are equivalent to (2.2): For \(z\in {\mathbb {C}}\) we have \( \varphi _{0}(z) = {\mathrm {e}}^{z} \), and

$$ \varphi_{p}(z) = \frac{1}{(p-1)!} {{\int}_{0}^{1}} \mathrm{e}^{(1-\theta) z} \theta^{p-1} \mathrm{d}\theta, \quad p \in \mathbb{N}. $$
(2.3)

(See also [24, Section 10.7.4].) The function wp(t) = tpφp(tA)v (\( p \in \mathbb {N} \)) is the solution of an inhomogeneous differential equation of the form

$$ w_{p}^{\prime}(t) = A w_{p}(t) + \frac{t^{p-1}}{(p-1)!} v,~~~w_{p}(0)=0, $$
(2.4)

see for instance [41]. This follows from (2.2),

$$ \begin{array}{@{}rcl@{}} \frac{\mathrm{d}}{\mathrm{d} t}\big(t^{p}\varphi_{p}(t A)v\big) &=& \frac{\mathrm{d}}{\mathrm{d} t}\Big(\sum\limits_{k=0}^{\infty} \frac{t^{k+p}A^{k}v}{(k+p)!} \Big) = A \sum\limits_{k=0}^{\infty} \frac{t^{k+p}A^{k}v}{(k+p)!} +\frac{t^{p-1}v}{(p-1)!}\\ &=& A (t^{p}\varphi_{p}(t A)v) + \frac{t^{p-1}v}{(p-1)!}. \end{array} $$

The φ-functions appear for instance in the field of exponential integrators, see for instance [27].

For the case of A being a large and sparse matrix, e.g., the spatial discretization of a partial differential operator using a localized basis, Krylov subspace techniques are commonly used to approximate (2.2) in an efficient way.

Notation and properties of Krylov subspaces

Footnote 2 We briefly recapitulate the usual notation and properties of standard Krylov subspaces, see for instance [47]. For a given matrix \(A\in \mathbb {C}^{n\times n} \), a starting vector \(v\in {\mathbb {C}}^{n}\) and Krylov dimension 0 < mn, the Krylov subspace is given by

$$ \mathscr{K}_{m}(A,v) = {\text{span}}(v,Av,\ldots,A^{m-1}v). $$

Let \( V_{m} \in \mathbb {C}^{n\times m} \) represent the orthonormal basis of \({\mathscr{K}}_{m}(A,v)\) with respect to the Hermitian inner product, constructed by the Arnoldi method and satisfying \(V_{m}^{\ast } V_{m} = I_{m\times m}\). Its first column is given by \(V_{m}^{\ast } v = \beta e_{1} \) with β = ∥v2. Here, the matrix

$$ H_{m} = V_{m}^{\ast} A V_{m} \in \mathbb{C}^{m\times m} $$

is upper Hessenberg. We further use the notation \(h_{m+1,m}=(H_{m+1})_{m+1,m}\in \mathbb {R}\), and \(v_{m+1}\in \mathbb {C}^{n}\) for the (m + 1)th column of Vm+ 1, with \(V_{m}^{\ast } v_{m+1}=0\) and ∥vm+ 12 = 1.

The Arnoldi decomposition (in exact arithmetic) can be expressed in matrix form,

$$ AV_{m} = V_{m}H_{m} + h_{m+1,m} v_{m+1} e_{m}^{\ast} . $$
(2.5)

Remark 1

The numerical range \(\text {W}(A)=\{y^{\ast } A y/y^{\ast } y, 0 \not = y \in \mathbb {C}^{n}\} \) plays a role in our analysis. Note that \( \text {W}(H_{m}) \subseteq \text {W}(A) \) (see (A.1)).

Remark 2

The case (Hm)k+ 1, k = 0 occurs if \({\mathscr{K}}_{k}(A,v)\) is an invariant subspace of A, whence the Krylov approximation given in (2.9) below is exact. This exceptional case is referred to as a lucky breakdown. In general, we assume that no lucky breakdown occurs, whence the lower subdiagonal entries of Hm are real and positive, 0 < (Hm)j+ 1, j for j = 1,…, m − 1, and \(0<h_{m+1,m}\in \mathbb {R}\).

For the special case of a Hermitian or skew-Hermitian matrix A the Arnoldi iteration simplifies to a three-term recurrence, the so-called Lanczos iteration. This case will be addressed in Remark 4 below.

Krylov subspaces in floating point arithmetic

We proceed with some results for the Arnoldi decomposition in computer arithmetic, assuming complex floating point arithmetic with a relative machine precision ε, see also [23]. For practical implementation different variants of the Arnoldi procedure exist, using different ways for the orthogonalization of the Krylov basis. These are based on classical Gram-Schmidt, modified Gram-Schmidt, the Householder algorithm, the Givens algorithm, or variants of Gram-Schmidt with reorthogonalization (see also [47, Algorithm 6.1–6.3] and others). We refer to [7] and references therein for an overview on the stability properties of these different variants.

In the sequel, the notation Vm, Hm, etc., will again be used for the result of the Arnoldi method in floating point arithmetic. We now accordingly adapt some statements formulated in the previous paragraph. By construction, Hm remains to be upper Hessenberg with positive lower subdiagonal entries. Assuming floating point arithmetic, we use the notation \(U_{m}\in \mathbb {C}^{n\times m}\) for a perturbation of the Arnoldi decomposition (2.5) caused by round-off, i.e.,

$$ AV_{m} = V_{m}H_{m} + h_{m+1,m} v_{m+1} e_{m}^{\ast} + U_{m}. $$
(2.6)

An upper norm bound for Um was first introduced in [43] for the Lanczos iteration in real arithmetic. For different variants of the Arnoldi or Lanczos iteration, this is discussed in [58] and others. We assume ∥Um2 is bounded by a constant C1 which can depend on m and n in a moderate way and is sufficiently small in a typical setting,

$$ \|U_{m}\|_{2} \leq C_{1} \varepsilon \|A\|_{2}. $$
(2.7a)

We further assume that the normalization of the columns of Vm is accurate, in particular that the (m + 1)th basis vector vm+ 1 is normalized correctly up round-off with a sufficiently small constant C2 (see e.g., [43, (14)]),

$$ |\|v_{m+1}\|_{2}-1|\leq C_{2} \varepsilon. $$
(2.7b)

Concerning Vm+ 1 which represents an orthogonal basis in exact arithmetic, numerical loss of orthogonality has been well-studied. Loss of orthogonality can be significant (see for instance [7, 45] and others), depending on the starting vector v. Reorthogonalization schemes or orthogonalization via Householder or Givens algorithm can be used to obtain orthogonality of Vm+ 1 on a sufficiently accurate level.

The numerical range of Hm obtained in floating point arithmetic (see (2.6)) can be characterized as

$$ \text{W}(H_{m}) \subseteq U_{C_{3}\varepsilon}(\text{W}(A)), $$
(2.7c)

with \(U_{C_{3}\varepsilon }(\text {W}(A))\) being the neighborhood of W(A) in \(\mathbb {C}\) with a distance C3ε. With the assumption that Vm+ 1 is sufficiently close to orthogonal (e.g., semiorthogonal [50]), the constant C3 in (2.7c) (which also depends on C1 and problem sizes) can be shown to be moderate-sized. Further details on this aspect are given in Appendix A.

Krylov approximation of φ-functions

Footnote 3 Let \(V_{m}\in \mathbb {C}^{n\times m}\), \(H_{m}\in \mathbb {C}^{m\times m}\) and \(\beta \in \mathbb {R}\) be the result of the Arnoldi method in floating point arithmetic for \({\mathscr{K}}_{m}(A,v)\) as described above. For a time-step \(0<t\in {\mathbb {R}}\) and p ≥ 0, the vector φp(tA)v can be approximated in the Krylov subspace \({{\mathscr{K}}}_{m}(A,v)\) by the Krylov propagator

$$ u_{p,m}(t):= V_{m} \varphi_{p}(tV_{m}^{\ast} AV_{m})V_{m}^{\ast} v = \beta V_{m} \varphi_{p}(tH_{m}) e_{1} ,~~~p\in\mathbb{N}. $$
(2.8a)

The special case p = 0 reads

$$ u_{0,m}(t) = \beta V_{m} \mathrm{e}^{tH_{m}} e_{1}. $$
(2.8b)

We remark that the small-dimensional problem \(\varphi _{p}(tH_{m})e_{1}\in \mathbb {C}^{m}\), typically with mn, can be evaluated cheaply by standard methods. In the sequel, we denote

$$ y_{p,m}(t)=\beta \varphi_{p}(tH_{m}) e_{1}\in\mathbb{C}^{m}, \quad \text{i.e.,} \quad u_{p,m}(t) = V_{m} y_{p,m}(t). $$
(2.9)

For p = 0, the small dimensional problem \(y_{0,m}(t) = \beta \mathrm {e}^{t H_{m}} e_{1}\) solves the differential equation

$$ {y}^{\prime}_{0,m}(t) = H_{m} {y}_{0,m}(t),~~~{y}_{0,m}(0)=\beta e_{1}. $$
(2.10)

For later use, we introduce the notation

$$ \widehat{y}_{p,m}(t) = t^{p} y_{p,m}(t), $$
(2.11a)

which for \(p\in \mathbb {N}\) and according to (2.4) satisfies the differential equation

$$ \widehat{y}^{\prime}_{p,m}(t) = H_{m} \widehat{y}_{p,m}(t) + \frac{t^{p-1}}{(p-1)!} \beta e_{1},~~~\widehat{y}_{p,m}(0)=0. $$
(2.11b)

Remark 3

Although we take rounding effects in the Arnoldi decomposition into account, we do not give a full study of round-off errors at this point. Round-off errors in substeps such as the evaluation of yp, m(t) or the matrix-vector multiplication Vmyp, m(t) will be ignored. We refer to [23] for a more general study of these effects.

Remark 4

In the special cases A = B or A = iB for a Hermitian matrix \(B\in \mathbb {C}^{n\times n}\) (with A being skew-Hermitian in the latter case) the orthogonalization of the Krylov basis of \({\mathscr{K}}_{m}(B,v)\) simplifies to a three-term recursion, the so-called Lanczos method. In the skew-Hermitian case (A = iB) the Krylov propagator (2.8a) can be evaluated by βVmφp(itHm)e1, i.e., we approximate the function λφp(itλ) in the Krylov subspace \({{\mathscr{K}}}_{m}(B,v)\). The advantage is a cheaper computation of the Krylov subspace in terms of computational cost and better conservation of geometric properties. For details we refer to the notation eσtB as introduced in [30], with σ = ±i and a Hermitian matrix B for the skew-Hermitian case.

The error of the Krylov propagator

We denote the error of the Krylov propagator given in (2.9) by

$$ l_{p,m}(t) = \beta V_{m}\varphi_{p}(tH_{m})e_{1} - \varphi_{p}(tA)v,~~~p\in\mathbb{N}_{0}. $$
(2.12)

We are further interested in computable a posteriori estimates for the error norm, ζp, m(t) ≈∥lp, m(t)∥2, which in the best case can be proven to be upper bounds on the error norm ∥lp, m(t)∥2ζp, m(t). Norm estimates of the error (2.12) can be used in practice to stop the Krylov iteration after k steps if ∥lp, k(t)∥2 satisfies (2.13) below, or to restrict the time-step t to obtain an accurate approximation and restart the method with the remaining time. For details on the total error with this restarting approach, see also [30, 49].

A prominent task is to test if the error norm per unit step is bounded by a tolerance tol,

$$ \zeta_{p,m}(t) \leq t \cdot \text{tol},~~~\text{which should entail}~~~\|l_{p,m}(t)\|_{2} \leq t \cdot \text{tol}. $$
(2.13)

In case of ζp, m(t) being an upper bound on the error norm, this results in a reliable bound.

3 An integral representation for the error of the Krylov propagator

We proceed with discussing the error lp, m of the Krylov propagator. To this end, we first define its scalar defect by

$$ \delta_{p,m}(t) = \beta e_{m}^{\ast} t^{p} \varphi_{p}(t H_{m}) e_{1} = t^{p} \big(y_{p,m}(t)\big)_{m}\in\mathbb{C}, $$
(3.1a)

and the defect integral byFootnote 4

$$ L_{p,m}(t) = \frac{h_{m+1,m}}{t^{p}}{{\int}_{0}^{t}} |\delta_{p,m}(s)| \mathrm{d} s\in\mathbb{R}. $$
(3.1b)

Theorem 1

Let \(\delta _{p,m}(t)\in \mathbb {C}\) be the defect defined in (3.1a). For \(y_{p,m}(t)\in \mathbb {C}^{m}\) defined in (2.9) and a numerical perturbation \(U_{m}\in \mathbb {C}^{n\times m}\) of the Arnoldi decomposition (see (2.6)), we have:

  1. (a)

    The error lp, m(t) of the Krylov propagator (see (2.12)) enjoys the integral representation

    $$ l_{p,m}(t) = -\frac{h_{m+1,m}}{t^{p}}{{\int}_{0}^{t}} \mathrm{e}^{(t-s)A}v_{m+1} \delta_{p,m}(s) \mathrm{d} s - \frac{1}{t^{p}}{{\int}_{0}^{t}} \mathrm{e}^{(t-s)A} U_{m} s^{p} y_{p,m}(s) \mathrm{d} s. $$
    (3.2a)
  2. (b)

    For given machine precision ε and constants C1, C2 representing round-off effects (see (2.7a),(2.7b)), and with \(\kappa _{1} = \max \limits _{s\in [0,t]}\|\mathrm {e}^{sA}\|_{2} \) and \(\kappa _{2} = \max \limits _{s\in [0,t]}\|\mathrm {e}^{sH_{m}}\|_{2} \) the error norm is bounded by

    $$ \|l_{p,m}(t)\|_{2} \leq (1+C_{2} \varepsilon ) \kappa_{1} L_{p,m}(t) + C_{1}\varepsilon \|A\|_{2} \frac{\beta \kappa_{1}\kappa_{2} t}{(p+1)!}, $$
    (3.2b)

    with the defect integral Lp, m(t) defined in (3.1b).

Proof

  1. (a)

    For the exact matrix function, we use the notation

    $$ u_{p}(t)=\varphi_{p}(tA)v, \quad \text{and} \quad w_{p}(t)=t^{p} u_{p}(t). $$

    For the Krylov propagator, we denote

    $$ u_{p,m}(t)=V_{m} y_{p,m}(t) ~~~\text{with}~~ y_{p,m}(t)=\beta \varphi_{p}(tH_{m})e_{1} $$

    (see (2.9)), and we also define

    $$ w_{p,m}(t) = t^{p} u_{p,m}(t) = V_{m} \widehat{y}_{p,m}(t), ~~~\text{with}~~ \widehat{y}_{p,m}(t)=t^{p}{y}_{p,m}(t)~ \text{defined in~(2.11a).--} $$
    • For \( p \in \mathbb {N} \), the functions wp(t) and wp, m(t) satisfy the differential equations (see (2.4), (2.11b))

      $$ \begin{array}{@{}rcl@{}} &&w^{\prime}_{p,m}(t) = V_{m} \widehat{y}^{\prime}_{p,m}(t) = V_{m}\left( H_{m} \widehat{y}_{p,m}(t) + \frac{t^{p-1}}{(p-1)!} \beta e_{1}\right),\\ &&w^{\prime}_{p}(t) = A w_{p}(t) + \frac{t^{p-1}}{(p-1)!} v, \quad \text{and}~~~{w}_{p}(0)={w}_{p,m}(0)=0. \end{array} $$
      (3.3)
    • For p = 0, i.e., w0(t) = u0(t) and w0, m(t) = Vmy0, m(t), according to (2.10), we have

      $$ \begin{array}{@{}rcl@{}} &&w^{\prime}_{0}(t) = A w_{0}(t), \quad w^{\prime}_{0,m}(t) = V_{m} H_{m} {y}_{0,m}(t), \\ &&\text{and}~~~w_{0}(0)=v,~~~w_{0,m}(0)=\beta V_{m} e_{1} =v. \end{array} $$

    Local error representation in terms of the defect We defined the re-scaled error

    $$ \widehat{l}_{p,m}(t) = w_{p,m}(t) - w_{p}(t) = t^{p} l_{p,m}(t). $$
    • For \( p \in \mathbb {N} \), this satisfies

      $$ \widehat{l}^{~'}_{p,m}(t) = w^{\prime}_{p,m}(t) - w^{\prime}_{p}(t) = A \widehat{l}_{p,m}(t) + d_{p,m}(t),~~~\widehat{l}_{p,m}(0)=0, $$
      (3.4)

      with the defect of wp, m(t) with respect to the differential (3.3),

      $$ \begin{array}{@{}rcl@{}} d_{p,m}(t) &=& w^{\prime}_{p,m}(t) - A w_{p,m}(t) - \frac{t^{p-1}}{(p-1)!} v \\ &=& V_{m}\big(H_{m} \widehat{y}_{p,m}(t) + \frac{t^{p-1}}{(p-1)!} \beta e_{1}\big) - A V_{m} \widehat{y}_{p,m}(t) - \frac{t^{p-1}}{(p-1)!} v \\ &=& \big(V_{m} H_{m} - A V_{m} \big) \widehat{y}_{p,m}(t) + \frac{t^{p-1}}{(p-1)!}(\beta V_{m} e_{1} - v). \end{array} $$

      Together with (2.6) and using of βVme1 = v, the defect can be written as

      $$ d_{p,m}(t) = - h_{m+1,m} (e_{m}^{\ast} \widehat{y}_{p,m}(t)) v_{m+1} - U_{m} \widehat{y}_{p,m}(t). $$
    • For p = 0, in an analogous way, we obtain

      $$ d_{0,m}(t) = - h_{m+1,m} (e_{m}^{\ast} {y}_{0,m}(t)) v_{m+1} - U_{m} {y}_{0,m}(t). $$

    We conclude

    $$ d_{p,m}(t) = -h_{m+1,m} \delta_{p,m}(t) v_{m+1} - t^{p} U_{m} y_{p,m}(t),~~~p\in\mathbb{N}_{0}, $$
    (3.5)

    with the scalar defect defined in (3.1a). Due to (3.4), we have

    $$ \widehat{l}_{p,m}(t) = {{\int}_{0}^{t}} \mathrm{e}^{(t-s) A} d_{p,m}(s) \mathrm{d} s,~~~p\in\mathbb{N}_{0}, $$

    and for \({l}_{p,m}(t) = t^{-p} \widehat {l}_{p,m}(t)\) together with (3.5) this implies (3.2a).

  2. (b)

    With \(\kappa _{1} =\max \limits _{s\in [0,t]} \|\mathrm {e}^{sA}\|_{2}\), ∥Um2C1εA2 and ∥vm+ 12 ≤ 1 + C2ε, the representation (3.2a) implies the upper bound

    $$ \begin{array}{@{}rcl@{}} \|l_{p,m}(t)\|_{2} &&\leq (1+C_{2}\varepsilon) \kappa_{1} \frac{ h_{m+1,m} }{t^{p}} {{\int}_{0}^{t}} |\delta_{p,m}(s)| \mathrm{d} s\\ &&~~~~~~~~~~+ C_{1}\varepsilon \|A\|_{2} \frac{\kappa_{1}}{t^{p}} {{\int}_{0}^{t}} s^{p} \| y_{p,m}(s)\|_{2} \mathrm{d} s . \end{array} $$
    (3.6)

    With the defect integral Lp, m(t) defined in (3.1b) we obtain the first term in (3.2b). For the second integral term (with yp, m(t) = βφp(tHm)e1), we use the upper bound

    $$ {{\int}_{0}^{t}} s^{p} \| \varphi_{p}(sH_{m})e_{1}\|_{2} \mathrm{d} s \leq \max_{s\in[0,t]}\| \varphi_{p}(sH_{m})e_{1}\|_{2} \frac{t^{p+1}}{p+1}. $$
    (3.7)
    • For \(p \in \mathbb {N}\) we apply the integral representation due to (2.3) for φp(tHm)e1 to obtain the norm bound

      $$ \max_{s\in[0,t]} \|\varphi_{p}(s H_{m}) e_{1}\|_{2} \leq \frac{\max_{s\in[0,t]} \|\mathrm{e}^{s H_{m}}\|_{2}}{(p-1)!} {{\int}_{0}^{1}}\theta^{p-1} \mathrm{d}\theta = \frac{\max_{s\in[0,t]} \|\mathrm{e}^{s H_{m}}\|_{2} }{p!}. $$
      (3.8)
    • For p = 0, we obtain (3.8) in a direct way.

    Combining (3.7) with (3.8) and denoting \(\kappa _{2} = \max \limits _{s\in [0,t]}\|\mathrm {e}^{sH_{m}}\|_{2}\), we obtain

    $$ \frac{\kappa_{1}}{t^{p}} {{\int}_{0}^{t}} s^{p} \| y_{p,m}(s)\|_{2} \mathrm{d} s \leq \frac{\beta \kappa_{1}\kappa_{2} t}{(p+1)!}. $$

    Combining these estimates with (3.6), we conclude (3.2b).

Remark 5

The error norm of the Krylov propagator scales with \(\kappa _{1} = \max \limits _{s\in [0,t]}\|\mathrm {e}^{sA}\|_{2} \) and \(\kappa _{2} = \max \limits _{s\in [0,t]}\|\mathrm {e}^{sH_{m}}\|_{2} \) in a natural way. Footnote 5 It is well known that

$$ \begin{array}{@{}rcl@{}} \|\mathrm{e}^{tA}\|_{2} \leq &&\mathrm{e}^{t \mu_{2}(A)}~~\text{with the logarithmic norm}\\ &&\mu_{2}(A) = \max\{\text{Re}(\text{W}(A))\} = \max \{ \text{spec}(A+A^{\ast})/2\}, \end{array} $$

see for instance [24, Theorem 10.11]. Problems with μ2(A) > 0 can be arbitrary ill-conditioned and difficult to solve with proper accuracy. (For further results on the stability of the matrix exponential see also [36, 55].). We will not further discuss problems with μ2(A) > 0 and assume μ2(A) ≤ 0. We refer to the case μ2(A) ≤ 0 as the dissipative case, with κ1 = 1.

For the dissipative case with μ2(A) ≤ 0, the error bound (3.2b) from Theorem 1 reads

$$ \|l_{p,m}(t)\|_{2} \leq (1+C_{2} \varepsilon ) L_{p,m}(t) + C_{1}\varepsilon \|A\|_{2} \frac{\beta \kappa_{2} t}{(p+1)!}. $$
(3.9)

The dissipative behavior of etA carries over to the Krylov propagator up to a perturbation which depends on round-off errors, including the loss of orthogonality of Vm. In terms of the numerical range W(Hm), with \({\text {W}}(H_{m})\subseteq U_{C_{3}\varepsilon }({\text {W}}(A))\), we have μ2(Hm) ≤ μ2(A) + C3ε, for a constant C3ε depending on round-off effects (2.7c). Thus, μ2(Hm) ≤ C3ε and \(\kappa _{2} \leq {\mathrm {e}}^{t C_{3} \varepsilon }\).

Our aim is to construct an upper norm bound for the error per unit step (2.13) via (3.9). Let the tolerance tol be given and t be a respective time step for (2.13). Then the round-off error terms in (3.9) are negligible if

$$ C_{2} \varepsilon\ll 1,~~~\text{and}~~ C_{1} \varepsilon \|A\|_{2} \beta \mathrm{e}^{t C_{3} \varepsilon} /(p+1)! \ll \text{tol}. $$
(3.10)

Concerning the constants C1, C2 and C3 see (2.7). We recapitulate that C1 and C2 given in (2.7a) and (2.7b) can be considered to be small enough in a standard Krylov setting. The constant C3 can be larger in the case of a loss of orthogonality of the Krylov subspace, which can however be avoided at the cost of additional computational effort. The constant C3 only appears as an exponential prefactor for the round-off term in (3.10) and is less critical compared to C1 and C2.

With the previous observation on the round-off errors taken into account in (3.9) we consider the following upper bound to be stable in computer arithmetic in accordance to a proper value of tol, see (3.10).

Corollary 1

For the case μ2(A) ≤ 0 and with the assumption that round-off error is negligible, the error of the Krylov propagator is bounded by the defect integral Lp, m(t),

$$ \|l_{p,m}(t)\|_{2} \leq \frac{h_{m+1,m}}{t^{p}}{{\int}_{0}^{t}} |\delta_{p,m}(s)| \mathrm{d} s = L_{p,m}(t),~~~p\in\mathbb{N}_{0}. $$

Note that the defect norm |δp, m(s)| cannot be integrated exactly in general. This point will further be studied in the sequel.

Representing the defect in terms of divided differences

Divided differences play an essential role in this work. We use the notation

$$ f[\lambda_{1},\ldots,\lambda_{m}] $$

for the divided differences of a function f over the nodes λ1,…, λm. (This is to be understood in the confluent sense for the case of multiple nodes λj, see for instance [24, Section B.16].)

Theorem 2 (see for instance 9)

Let \(H_{m}\in \mathbb {C}^{m\times m}\) be an upper Hessenberg matrix with positive secondary diagonal entries, \(0<(H_{m})_{j+1,j}\in \mathbb {R}\) for j = 1,…, m − 1, and eigenvalues λ1,…, λm. Let f be an analytic function for which f(Hm) is well defined. Then,

$$ e_{m}^{\ast} f(H_{m})e_{1} = \gamma_{m} f[\lambda_{1},\ldots,\lambda_{m}], $$

with \(\gamma _{m}={\prod }_{j=1}^{m-1} (H_{m})_{j+1,j}\).

For f = (φp)t : λφp(tλ), we will also make use of the following result. Footnote 6

Theorem 3 (Corollary 1 in 49)

(Expressing φ-functions via dilated \( \exp \)-functions.) For \( t \in \mathbb {R} \),

$$ t^{p} e_{m}^{\ast} \varphi_{p}(t H_{m})e_{1} = e_{m+p}^{\ast} \exp(t\widetilde{H}_{p,m}) e_{1} $$

with

$$ \widetilde{H}_{p,m} = \begin{pmatrix} H_{m} & 0_{m\times p}\\ e_{1} e_{m}^{\ast} & J_{p\times p} \end{pmatrix} \in\mathbb{C}^{(m+p)\times(m+p)}~~~\text{and}~~~ J_{p\times p} = \begin{pmatrix} 0& &&\\ 1 & 0 &&\\ & {\ddots} &\ddots& \\ && 1&0 \end{pmatrix}\in\mathbb{C}^{p\times p}. $$

The matrix \(\widetilde {H}_{p,m}\) in Theorem 3 is block triangular with eigenvalues equal to those of Hm and Jp×p. Therefore, \( \text {spec}(\widetilde {H}_{m}) = \{\lambda _{1},\ldots ,\lambda _{m},0,\ldots ,0\}\), with 0 as an eigenvalue of multiplicity p (at least). In our context, \(\widetilde {H}_{m}\) is upper Hessenberg with a positive lower secondary diagonal and \(\gamma _{m}={\prod }_{j=1}^{m-1} (H_{m})_{j+1,j} = {\prod }_{j=1}^{m+p-1} (\widetilde {H}_{m})_{j+1,j}\). In accordance with Theorem 2, the result of Theorem 3 holds for divided differences in a similar manner,

$$ t^{p} (\varphi_{p})_{t}[\lambda_{1},\ldots,\lambda_{m}] = \exp_{t} [ \lambda_{1},\ldots,\lambda_{m},\underbrace{0,\ldots,0}_{\text{\textit{p} times}} ]. $$

With Theorem 2 and 3 the following equivalent formulations can be used to rewrite the scalar defect δp, m(t) defined in (3.1a).

Corollary 2

Let δp, m(t) be the scalar defect given in (3.1a) for the upper Hessenberg matrix \(H_{m}\in \mathbb {C}^{m\times m}\) with positive secondary diagonal entries. Denote \(0<\gamma _{m} = {\prod }_{j=1}^{m-1} (H_{m})_{j+1,j}\). Let \(\widetilde {H}_{p,m}\in {\mathbb {C}}^{m+p}\) be given as in Theorem 3. For the scalar defect, we obtain the following equivalent formulations:

  1. (i)

    \(\delta _{p,m}(t) = \beta e_{m}^{\ast } t^{p} \varphi _{p}(t H_{m}) e_{1}\)

  2. (ii)

    = βγmtp(φp)t[λ1,…, λm]

  3. (iii)

    \( = \beta e_{m+p}^{\ast } \exp (t \widetilde {H}_{p,m}) e_{1}\)

  4. (iv)

    \( = \beta \gamma _{m} \exp _{t}[\lambda _{1},\ldots ,\lambda _{m},0_{p}]\)Footnote 7

We remark that the eigenvalues λ1,…, λm of the Krylov Hessenberg matrix Hm are also referred to as Ritz values (of A) in the literature.

4 Computable a posteriori error bounds for the Krylov propagator

The following two propositions are used for the proof of Theorem 4 below.Footnote 8

Proposition 1

For arbitrary nodes \(\lambda _{j}\in \mathbb {C}\) and \(p\in \mathbb {N}_{0}\),

$$ {{\int}_{0}^{t}} s^{p} (\varphi_{p})_{s}[\lambda_{1},\ldots,\lambda_{k}] \mathrm{d} s = t^{p+1} (\varphi_{p+1})_{t}[\lambda_{1},\ldots,\lambda_{k}]. $$

Proof

See Appendix B. □

Proposition 2 (Lemma including (5.1.1) in 35)

For arbitrary nodes \(\lambda _{j}=\xi _{j}+\mathrm {i}\eta _{j} \in \mathbb {C}\),

$$ |\exp_{t}[\lambda_{1},\ldots,\lambda_{k}]| \leq \exp_{t}[\xi_{1},\ldots,\xi_{k}]. $$

Proof

See Appendix B. □

We now derive upper bounds for the error via its representation by the defect integral (3.1b).

Theorem 4

Let \(p\in \mathbb {N}_{0}\), μ2(A) ≤ 0, and assume that round-off errors are sufficiently small (see Corollary 1). For the eigenvalues of Hm, we write λj = ξj + iηj, j = 1,…, m. An upper bound on the error norm is given by

$$ \|l_{p,m}(t)\|_{2} \leq \beta h_{m+1,m} \gamma_{m} t (\varphi_{p+1})_{t}[\xi_{1},\ldots,\xi_{m}]. $$
(4.1)

Proof

Due to Corollary 2, (iv),

$$ \delta_{p,m}(t) = \beta \gamma_{m} \exp_{t} [\lambda_{1},\ldots,\lambda_{m},0_{p}]. $$
(4.2a)

The divided differences in (4.2a) span over complex nodes λ1,…, λm and \( 0_{p}\in \mathbb {C}^{p}\), with real parts ξ1,…, ξm. Propositions 2 and 1 imply

$$ {{\int}_{0}^{t}} |\exp_{s} [\lambda_{1},\ldots,\lambda_{m},0_{p}]| \mathrm{d} s \!\leq\! {{\int}_{0}^{t}} \exp_{s}[\xi_{1},\ldots,\xi_{m},0_{p}] \mathrm{d} s = t (\varphi_{1})_{t} [\xi_{1},\ldots,\xi_{m},0_{p}]. $$
(4.2b)

From Corollary 2, we obtain

$$ t (\varphi_{1})_{t}[\xi_{1},\ldots,\xi_{m},0_{p}] = \exp_{t}[\xi_{1},\ldots,\xi_{m},0_{p+1}] = t^{p+1} (\varphi_{p+1})_{t}[\xi_{1},\ldots,\xi_{m}]. $$
(4.2c)

Equations (4.2a)–(4.2c) together with Corollary 1 imply (4.1).

For the case of Hm having real eigenvalues, the assertion of Theorem 4 can be reformulated in the following way (see [30, Proposition 6]).

Corollary 3

Assume μ2(A) ≤ 0 and that round-off errors are sufficiently small (see Corollary 1). For the case of Hm having real eigenvalues \(\lambda _{1},\ldots ,\lambda _{m}\in \mathbb {R} \), the upper bound on the error norm in Theorem 4 yields an exact evaluation of the defect integral. Hence,

$$ \|l_{p,m}(t)\|_{2} \leq L_{p,m}(t) = \beta h_{m+1,m} t \big(e_{m}^{\ast} \varphi_{p+1}(tH_{m}) e_{1} \big). $$

As a further corollary we formulate an upper bound on the error norm which is cheaper to evaluate compared to the bound from Theorem 4 but may be less tight. Using the Mean Value Theorem, [24, (B.26)] or [4, (44)], for the divided differences in Theorem 4 (4.1), we obtain the following result which corresponds to [30, Theorem 1 and 2]. For the exponential of a skew-Hermitian matrix, a similar error estimate has been used in [33] and is based on ideas of [44] with some lack of theory.

Corollary 4

Let \(p\in \mathbb {N}_{0}\), μ2(A) ≤ 0, and assume that round-off errors are sufficiently small (see Corollary 1). Let \({\xi }_{\max \limits } = 0 \) for \(p\in \mathbb {N}\) and \({\xi }_{\max \limits } = \max \limits _{j=1,\ldots ,m} \xi _{j} \leq 0\) for p = 0 and eigenvalues \(\lambda _{j}=\xi _{j}+{\mathrm {i}}\mu _{j}\in {\mathbb {C}}\) of Hm. An upper bound on the error norm is given by

$$ \|l_{p,m}(t)\|_{2} \leq \beta h_{m+1,m} \frac{ \gamma_{m} t^{m} \mathrm{e}^{t{\xi}_{\max}} }{(m+p)!} \leq \beta h_{m+1,m} \frac{ \gamma_{m} t^{m} }{(m+p)!}. $$

For the case of Hm having purely imaginary eigenvalues, the divided differences in Theorem 4 (see (4.1)) can be evaluated directly via [24, (B.27)],

$$ t (\varphi_{p+1})_{t}[0_{m}] = t^{-p} \exp_{t}[0_{m+p+1}] = \frac{ t^{m} }{(m+p)!}; $$

hence, the assertions of Theorem 4 and Corollary 4 coincide in this case.

Accuracy of the previously specified upper bounds on the error norm

In the following, we again denote \(\lambda _{1},\ldots ,\lambda _{m}\in \mathbb {C}\) for the eigenvalues of Hm, with λj = ξj + iηj. For the scalar defect δp, m(t) (see (3.1a)) we recapitulate Corollary 2, in particular

$$ \delta_{p,m}(t) = \beta \gamma_{m} t^{p} (\varphi_{p})_{t}[\lambda_{1},\ldots,\lambda_{m}] = \beta \gamma_{m} \exp_{t}[\lambda_{1},\ldots,\lambda_{m},0_{p}]. $$
(4.3)

Theorem 4 and its corollaries make use of the error bound given in Corollary 1 and computable upper bounds on the defect integral Lp, m(t). A refinement of the upper bound from Corollary 1 would require further applications of the large-dimensional matrix-vector product with \(A\in {\mathbb {C}}^{n\times n}\) and has been shown to be inefficient in terms of computational cost, see also [30, Remark 7]. The computable upper bounds on the defect integral Lp, m(t) will be further discussed. We recapitulate the upper bound of the divided differences given in Proposition 2,

$$ |\exp_{t}[\lambda_{1},\ldots,\lambda_{m},0_{p}]|\leq \exp_{t}[\xi_{1},\ldots,\xi_{m},0_{p}]. $$
(4.4)

Thus, in the case of Hm having eigenvalues with a sufficiently small imaginary part, the upper bound in Proposition 2, is tight. In the following proposition, this statement is made more precise.

Proposition 3 (Part of a proof in 35, (5.2.3))

For nodes \(\lambda _{j}=\xi _{j}+\mathrm {i}\eta _{j} \in \mathbb {C}\) and t ≥ 0 with \(\max \limits _{j} t|\eta _{j}| \leq \widetilde {\eta }_{t} < \pi /2\),

$$ 0<\cos(\widetilde{\eta}_{t}) \exp_{t}[\xi_{1},\ldots,\xi_{k}] \leq |\exp_{t}[\lambda_{1},\ldots,\lambda_{k}]|. $$

Proof

See Appendix B. □

Under the assumptions of Proposition 3, we conclude

$$ 0<\cos(\widetilde{\eta}_{t}) \exp_{t}[\xi_{1},\ldots,\xi_{m},0_{p}] \leq |\exp_{t}[\lambda_{1},\ldots,\lambda_{m},0_{p}]|. $$
(4.5)

With (4.3), (4.4), (4.5), and following the proof of Theorem 4, the defect integral in (3.1b) can be enclosed by

$$ \begin{array}{@{}rcl@{}} &&0<\cos(\widetilde{\eta}_{t}) \cdot \beta \gamma_{m} h_{m+1,m} t (\varphi_{p+1})_{t}[\xi_{1},\ldots,\xi_{m}]\\ &&~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\leq L_{p,m}(t) \leq \beta \gamma_{m} h_{m+1,m} t (\varphi_{p+1})_{t}[\xi_{1},\ldots,\xi_{m}]. \end{array} $$
(4.6)

Hence,

$$ L_{p,m}(t) = \big(1 - \mathscr{O}(|t\eta|^{2}) \big) \beta \gamma_{m} h_{m+1,m} t (\varphi_{p+1})_{t}[\xi_{1},\ldots,\xi_{m}], $$
(4.7)

using the notation \({\mathscr{O}}(|t\eta |^{2})\) in the sense of \({\mathscr{O}}(|t\eta |)= {\mathscr{O}}(\max \limits _{j} t|\eta _{j}|)\) for t|ηj|→ 0. Following Proposition 3 the choice of \(\widetilde {\eta }_{t}\) is independent of ξ1,…, ξm, and this carries over to the constant in (4.7).

Summarizing, we see that the defect integral can be computed exactly for the case of Hm having real eigenvalues (Corollary 3), and a computable upper bound can be given which is tight for the case of Hm having eigenvalues sufficiently close to the real axis (Theorem 4 and (4.7)).

The approach underlying Theorem 4 does not enable us to specify the asymptotic constant in (4.7). Therefore, we use the asymptotic expansion of the divided differences, \(|\exp _{t}[\lambda _{1},\ldots ,\lambda _{m},0_{p}]|\) in (4.3), derived in Appendix C, to discuss the asymptotic behavior of the defect norm |δp, m(t)| for t → 0. Theorem 5 from Appendix C implies

$$ \begin{array}{@{}rcl@{}} &&| \exp_{t}[\lambda_{1},\ldots,\lambda_{m},0_{p}] | = \frac{t^{m+p-1}}{(m+p-1)!} \exp\big(\rho_{1} t + \rho_{2} t^{2}/2 + \mathscr{O}(t^{3}) \big),\\ &&\text{with}~~~ \rho_{1} = \text{avg}_{p}(\xi) ~~~\text{and}~~~ \rho_{2} = \frac{\text{var}_{p}(\xi) - \text{var}_{p}(\eta)}{m+p+1}. \end{array} $$
(4.8)

Here, the asymptotics holds for t → 0, \( \text {avg}_{p}(\xi ) = {\sum }_{j=1}^{m} \xi _{j} /(m+p)\) is the average, and \( \text {var}_{p}(\xi ) = \big ({\sum }_{j=1}^{m} (\xi _{j} - \text {avg}_{p}(\xi ))^{2} + p\ \text {avg}_{p}(\xi )^{2} \big )/ (m+p) \) is the variance of the sequence {ξ1,…, ξm,0p} and varp(η) is the variance of the sequence {η1,…, ηm,0p}.

Remark 6

For Hm with purely imaginary eigenvalues (\(\lambda _{j}\in \mathrm {i}\mathbb {R}\)), e.g., in the skew-Hermitian case, the following asymptotic expansion for the defect is obtained from (4.8), Footnote 9

$$ |\delta_{p,m}(t)| =\beta \gamma_{m} \frac{t^{m+p-1}}{(m+p-1)!} \exp\Big(-\frac{\text{var}_{p}(\eta)}{2(m+p+1)}t^{2} + \mathscr{O}(t^{3}) \Big) ~~~\text{for}~~ t\to 0. $$
(4.9)

We use the expansion from (4.8) for \(| \exp _{t}[\lambda _{1},\ldots ,\lambda _{m},0_{p}] |\) and \( \exp _{t}[\xi _{1},\ldots ,\xi _{m},0_{p}] \) to obtain

$$ |\delta_{p,m}(t)| = \exp\Big(-\frac{\text{var}_{p}(\eta)}{2(m+p+1)}t^{2} +\mathscr{O}(t^{3})\Big) \cdot \beta \gamma_{m} t^{p} (\varphi_{p})_{t}[\xi_{1},\ldots,\xi_{m}]. $$
(4.10)

Termwise integration of (4.10) and the proper prefactor gives an asymptotic expansion for the defect integral Lp, m(t), similar to (4.7),

$$ L_{p,m}(t) = \Big(1-\frac{\text{var}_{p}(\eta) (m+p)t^{2}}{2(m + p + 1)(m + p + 2)} +\mathscr{O}(t^{3}) \Big) \cdot \beta h_{m+1,m}\gamma_{m} t(\varphi_{p+1})_{t}[\xi_{1},\ldots,\xi_{m}]. $$
(4.11)

Omitting further details we state that (4.11) is to be understood in an asymptotic sense with an remainder of \({\mathscr{O}}(t^{3}|\xi ||\eta |^{2}+t^{4}|\eta |^{4})\). In contrast to (4.7) the remainder is depending on ξ terms but (4.11) reveals further constants which can be relevant for practical applications.

Remark 7

With (4.11) we obtain a computable estimate for the relative deviation from the defect integral to the upper bound in (4.6). The criterion

$$ \text{ac.est.}1(t):=\frac{\text{var}_{p}(\eta) (m+p)t^{2}}{2(m+p+1)(m+p+2)} > 0.1, $$

can indicate that a tighter estimate on the defect integral could improve the error bound given in Theorem 4 in terms of accuracy. A possible choice are quadrature estimates on the defect integral, see Section 4.1 below.

A similar criterion can be given for the accuracy of the upper bound,

$$ L_{p,m}(t) \leq \beta h_{m+1,m}\gamma_{m} \frac{t^{m}}{(m+p)!}, $$
(4.12)

which appears in Corollary 4 (with \(\xi _{\max \limits }=0\)) and [30, Theorem 1 and 2]. With (4.8), and ρ1 and ρ2 given therein, the defect integral can be written as

$$ L_{p,m}(t) = \beta h_{m+1,m}\gamma_{m} \frac{t^{m}}{(m+p)!} \Big(1+\rho_{1}\frac{(m+p)t}{m+p+1} + ({\rho_{1}^{2}}+\rho_{2})\frac{(m+p)t^{2}}{2(m+p+2)} +\mathscr{O}(t^{3})\Big) $$
(4.13)

for t → 0. In contrast to the error bound in Corollary 4, the formulas for ρ1 and ρ2 in (4.8) require the evaluation of the eigenvalues of Hm. The following Proposition gives a formula for ρ1 and ρ2 which does not require computation of the eigenvalues of Hm and can be evaluated on the fly.

Proposition 4 (Evaluation of ρ 1 and ρ 2 in terms of entries of H m)

The coefficients ρ1 and ρ2 in (4.8) can be rewritten as

$$ \begin{array}{@{}rcl@{}} &&\rho_{1} = \frac{\text{Re}(S_{1})}{m+p},~~~\rho_{2}= \frac{\text{Im}(S_{1})^{2}-\text{Re}(S_{1})^{2}}{(m+p)^{2}}+ \frac{\text{Re}({S_{1}^{2}}+S_{2}) }{(m+p)(m+p+1)},~~~\text{with}\\ &&S_{1}=\sum\limits_{j=1}^{m} (H_{m})_{j,j} ~~~\text{and}~~ S_{2}=\sum\limits_{j=1}^{m} (H_{m})^{2}_{j,j} + 2\sum\limits_{j=1}^{m-1} (H_{m})_{j+1,j}(H_{m})_{j,j+1}. \end{array} $$

Proof

For the coefficients ρ1 and ρ2 we use (C.17) with \( m \leftarrow m + p \) and S1 and S2 from (C.3). For the nodes λ1,…, λm,0p (with λ1,…, λm eigenvalues of Hm) we obtain

$$ \begin{array}{@{}rcl@{}} &&{}S_{1} = \sum\limits_{j=1}^{m} \lambda_{j} = \text{Trace}(H_{m}) = \sum\limits_{j=1}^{m} (H_{m})_{j,j}~~~\text{and}\\ &&{}S_{2} = \sum\limits_{j=1}^{m} {\lambda_{j}^{2}} = \text{Trace}({H_{m}^{2}}) = \sum\limits_{j=1}^{m} (H_{m})^{2}_{j,j} + 2\sum\limits_{j=1}^{m-1} (H_{m})_{j+1,j}(H_{m})_{j,j+1}. \end{array} $$
(4.14)

The identity for \(\text {Trace}({H_{m}^{2}})\) in (4.14) holds true due to the upper Hessenberg structure of Hm.

Following the proof of Theorem 5 we observe that the case ρ1 = 0 is possible but results in ρ2≠ 0.

Remark 8

With (4.13) and Proposition 4 we obtain a computable estimate for the relative deviation from the defect integral to the upper bound in (4.12). The criterion

$$ \text{ac.est.}2(t):=\Big| \rho_{1}\frac{(m+p)t}{m+p+1} + ({\rho_{1}^{2}}+\rho_{2})\frac{(m+p)t^{2}}{2(m+p+2)} \Big| > 0.1 $$

can indicate that a tighter estimate on the defect integral could improve the error bound given in Corollary 4 in terms of accuracy. We refer to the error bound in Theorem 4 in case the eigenvalues of Hm have a significant real part (which can be observed via ρ1).

4.1 Quadrature-based error estimates

First we recapitulate some prior results. In the dissipative case the integral formulation of the error from Theorem 1 can be bounded via the defect integral via Corollary 1 up to round-off. We conclude that the defect integral can be computed exactly for the case of Hm having real eigenvalues (Corollary 3), and a computable upper bound exists which is tight for the case of Hm having eigenvalues sufficiently close to the real axis (Theorem 4 and (4.6)).

For the case of Hm having eigenvalues with a significant imaginary part, tight estimates are more difficult to obtain. It can be favorable to approximate the defect integral (3.1b) by quadrature to obtain an error estimate via Corollary 1. The aim of using quadrature is to obtain an error estimate which is tighter compared to previous upper norm bounds on the error. In contrast to the proven upper error bounds given in Theorem 4, Corollary 3, and Corollary 4, the following quadrature estimates do not result in upper error bounds in general. However, in many practical cases, such quadrature estimates turn out to be still reliable.

Here, some remarks on the defect are in order to explain some subtleties with quadrature estimates for the defect integral Lp, m(t). We discuss a test problem with a skew-Hermitian matrix \(A\in \mathbb {C}^{n\times n}\). Following Remark 4 we choose A = iB with a Hermitian matrix B, in particularly, \(B=\text {tridiag}(-1,2,-1)\in {\mathbb {R}}^{n\times n}\) with n = 1000. The matrix B is related to a finite difference discretization of the one-dimensional negative Laplacian operator and A corresponds to a free Schrödinger type problem. The eigenvalues σj, for j = 1,…, n, of B are given by

$$ \sigma_{j}=4\sin(j\pi/(2(n+1)))^{2} ~~\text{with respective eigenvector} \psi_{j}\in\mathbb{R}^{n}. $$
(4.15)

Here, μ2(A) = 0, and the conditions of Corollary 1 hold. For a given starting vector \(v\in \mathbb {C}^{n}\) the time propagation for the discretized free Schrödinger equation is given by \(\exp (tA)v\) and can be approximated by the Krylov propagator with p = 0. The following different cases for the starting vector v will be discussed.

  1. (a)

    Choose a random starting vector \(v\in \mathbb {R}^{n}\).

  2. (b)

    Start close to a linear combination of eigenvectors, \(v = 10^{6} {\sum }_{j=1}^{25} \psi _{j} + {\sum }_{j=26}^{n} \psi _{j}\) for eigenvectors ψj of the discretized negative Laplacian operator, (4.15).

  3. (c)

    Start close to a linear combination of eigenvectors which are more spread on the spectrum, \(v = 10^{5} {\sum }_{j=1}^{20} \psi _{j} + 10^{5} {\sum }_{j=n-19}^{n} \psi _{j} \) for eigenvectors ψj of the discretized negative Laplacian operator, (4.15).

In addition to the setting from (a)–(c) we normalize v, ∥v2 = 1. The defect δp, m(t) for p = 0 is computed in Matlab, using expm to evaluate the matrix exponential of Hm and divided differences for a fixed Krylov dimension m = 20.

In Fig. 1 we observe \(|\delta _{p,m}(t)|={\mathscr{O}}(t^{m-1})\) (for t → 0) up to t ≈ 101 for the case (a)–(c). The values of |δp, m(t)| in this time regime vary strongly among these cases. We further remark that in the case (b) for t ≥ 4 ⋅ 101 the defect |δp, m(t)| behaves similar to the divided differences of the exponential over the first eigenvalues \(\lambda _{1}^{(b)},\ldots ,\lambda _{4}^{(b)}\) of Hm with a proper prefactor. This behavior occurs if eigenvalues of Hm are clustered, in this case \(\lambda _{1}^{(b)},\ldots ,\lambda _{4}^{(b)}\approx 0\), and will be further discussed below, see Fig. 2. For the case (c) the eigenvalues of Hm are clustered at ≈ 0 and ≈ 4. Also in this case, there is a time regime for which the defect behaves similar to a lower order function in t with some additional oscillations (This may be explained by the existence of different eigenvalue clusters of the same size.).

Fig. 1
figure 1

The defect norm |δp, m(t)| (p = 0, m = 20) for the free Schrödinger example with different choices of starting vector case (a) (×), case (b) (∘) and case (c) (\(\Box \)). The table on the right-hand side shows eigenvalues \(\lambda ^{(\ast )}_{1},\ldots ,\lambda ^{(\ast )}_{m}\) of Hm for the different starting vectors, case (a)–(c). For the case (b), the divided differences over the clustered eigenvalues \( \gamma _{m} \big ({\prod }_{j=5}^{20} \lambda _{j}^{(b)}\big )^{-1} |\exp _{t}[\mathrm {i} \lambda ^{(b)}_{1},\ldots ,\mathrm {i} \lambda ^{(b)}_{4}]| \) is illustrated by (+ ). The asymptotic expansion of the divided differences for t → 0 given in (4.9) is illustrated using dashed lines. The dash-dotted line is \({{\mathscr{O}}}(t^{6})\)

Fig. 2
figure 2

The divided differences \(| \exp _{t}[\mathrm {i} a_{1},\mathrm {i} a_{2},\mathrm {i} a_{3}] |\) (∘) and \(| \exp _{t}[\mathrm {i} a_{1},\mathrm {i} a_{2}] |/|a_{3}-a_{1}| \) (+ ) for the choice of a1, a2, a3 given in the text. The asymptotic expansion of the divided differences for t → 0 given in (4.9) is illustrated using dashed lines

As a conclusion from the example illustrated in Fig. 1, we observe that quadrature of the defect can be relevant up to a time t for which the quadrature based estimate of ∥lp, m(t)∥2 (via the defect integral) is equal to a given tolerance, see (2.13). This regime of t would depend on the choice of tol and additional factors such as β, hm+ 1, m etc. which appear in the error bound from Corollary 1. Depending on parameters and the starting vector v the defect can be highly oscillatory for relevant times t and, respectively, a quadrature estimate of the defect integral can be difficult to obtain. Such effects seem to be relevant for special choices of starting vectors v, for example case (b) and (c). The effect of Hm having clustered eigenvalues and the prefactor used in Fig. 1 (+ ) are explained in the following model problem, see Fig. 2.

Divided differences with clustered nodes: an example

Choose m = 3 with nodes a1 = 1.123, a2 = 1.231, a3 = 5.43. With this choice, we obtain cluster of nodes, a1a2. For the given example, we obtain \( | \exp _{t}[\mathrm {i} a_{2},{\mathrm {i}} a_{3}] | \ll | \exp _{t}[{\mathrm {i}} a_{1},{\mathrm {i}} a_{2}] | \) for t large enough; hence, using the recursive definition of the divided differences (see [24, (B.24)] or others), we obtain

$$ | \exp_{t}[\mathrm{i} a_{1},\mathrm{i} a_{2},\mathrm{i} a_{3}] | = \Big| \frac{ \exp_{t}[\mathrm{i} a_{2},\mathrm{i} a_{3}] - \exp_{t}[\mathrm{i} a_{1},\mathrm{i} a_{2}] }{a_{3} - a_{1}}\Big| \!\approx\! \Big| \frac{ \exp_{t}[\mathrm{i} a_{1},\mathrm{i} a_{2}] }{a_{3} - a_{1}}\Big|,~~\text{for larger \textit{t}.} $$

This example is illustrated in Fig. 2. This behavior can be generalized for a larger number of nodes and is also observed in Fig. 1.

Quadrature estimates for the defect integral

With the previous observations on the defect we now discuss different quadrature-based estimates.

The generalized residual estimate, which was introduced in [28] and appeared in a similar manner in [5, 11, 34, 46], conforms to a quadrature on the defect norm integral which is related to the error norm via Corollary 1.

Remark 9 (Generalized residual estimate, see also 28)

Applying the right-endpoint rectangle rule we have

$$ {{\int}_{0}^{t}} |\delta_{p,m}(s)| \mathrm{d} s \approx t|\delta_{p,m}(t)|, $$

and with Corollary 1 (and δp, m(t) given in (3.1a)) we obtain the error estimate

$$ \|l_{p,m}(t)\|_{2} \approx h_{m+1,m} t^{1-p} |\delta_{p,m}(t)| = \beta h_{m+1,m} t |e_{m}^{\ast} \varphi_{p}(t H_{m}) e_{1}| . $$

Assume that \(\max \limits _{s\in [0,t]} |\delta _{p,m}(s)|=|\delta _{p,m}(t)|\), e.g., |δp, m(t)| is monotonically increasing in t. Then,

$$ {{\int}_{0}^{t}} |\delta_{p,m}(s)| \mathrm{d} s \leq t \max_{s\in[0,t]} |\delta_{p,m}(s)| = t |\delta_{p,m}(t)|. $$

In this case, the generalized residual estimate from Remark 9 results in an upper bound on the error norm.

In the most general case, the defect is of high order for t → 0 and in a relevant time regime, see also Fig. 1 case (a) and previous remarks. Then, the defect is a higher order function and the right-endpoint quadrature does result in an upper bound but is not tight. In this case, we can improve the estimate by a prefactor depending on the effective order defined in Appendix C. If the defect is sufficiently smooth in a relevant time regime, this results in a tight upper bound on the error norm.

Remark 10 (Effective order estimate, see also 30)

Denote \(f(t) = | \exp _{t}[\lambda _{1},\ldots ,\lambda _{m},0_{p}] |\) for the time-dependent part of the defect with eigenvalues λ1,…, λm of Hm. Assume f(t) > 0 for a sufficiently small time regime t > 0. We consider the effective order ρ(t) defined in (C.4a). With the following estimate for the integral of the defect,

$$ {{\int}_{0}^{t}} |\delta_{p,m}(s)| \mathrm{d} s \approx \frac{t}{\rho(t)+1}|\delta_{p,m}(t)|, $$

and from Corollary 1 (with δp, m(t) given in (3.1a)), we obtain

$$ \|l_{p,m}(t)\|_{2} \approx h_{m+1,m} \frac{ t^{1-p} }{ \rho(t)+1 } |\delta_{p,m}(t)| = \beta h_{m+1,m} \frac{ t }{ \rho(t)+1 } |e_{m}^{\ast} \varphi_{p}(t H_{m}) e_{1}| . $$

In [30], the effective order is defined for \(|e_{m}^{\ast } \mathrm {e}^{tH_{m}} e_{1}|\) (p = 0) which is equivalent to the definition via the divided differences of f(t). (This follows from Corollary 2 and the definition of the effective order which is independent of a constant prefactor.)

Some of the following observations already appeared in [30]. The quadrature scheme in Remark 10 is motivated by the following relation of the effective order and the integral of the divided differences f(t). From (C.4a),

$$ f(t)=\frac{f^{\prime}(t) t}{\rho(t)}. $$

Integration and application of the mean value theorem shows the existence of t∈ [0, t] with

$$ {{\int}_{0}^{t}} f(s) \mathrm{d} s= \frac{1}{\rho(t^{\ast})} {{\int}_{0}^{t}} f^{\prime}(s) s \mathrm{d} s, $$

and integration by parts gives

$$ {{\int}_{0}^{t}} f(s) \mathrm{d} s = \frac{t f(t)}{1+\rho(t^{\ast})}. $$
(4.16)

This result can passed over to the integral of the defect.

Assume the effective order is monotonically decreasing for t small enough, with \(\min \limits _{s\in (0,t]}\rho (s) = \rho (t) \geq 0\). This holds in an asymptotic regime for the dissipative case up to round-off, see also Theorem 5 with the real parts ξ1,…, ξm of the eigenvalues of Hm being non-positive. With (4.16) and the assumption 0 ≤ ρ(t) ≤ ρ(s) ≤ m + p − 1 = ρ(0+) for s ∈ [0, t], we inclose the integral of the defect by

$$ \frac{t}{m} |\delta_{p,m}(t)| \leq {{\int}_{0}^{t}} |\delta_{p,m}(s)| \mathrm{d} s \leq \frac{t}{\rho(t)+1} |\delta_{p,m}(t)| \leq t |\delta_{p,m}(t)|. $$
(4.17)

Combining (4.17) and Corollary 1, we obtain the upper bound

$$ \|l_{p,m}(t)\|_{2}\leq \frac{ h_{m+1,m} t^{1-p} }{\rho(t)+1}\cdot|\delta_{p,m}(t)| \leq h_{m+1,m} t^{1-p} \cdot|\delta_{p,m}(t)|. $$

A computable expression for the effective order was given in [30, (6.10)]. This result can be generalized to the case \(p\in \mathbb {N}_{0}\),

$$ \begin{array}{@{}rcl@{}} \rho(t) = \left\{ \begin{array}{ll} t \text{Re}\big((H_{m})_{m,m} + (H_{m})_{m,m-1} (y_{p,m}(t))_{m-1}/(y_{p,m}(t))_{m} \big)~~&\text{for}~ p=0,~~\text{and}\\ \text{Re}((y_{p-1,m}(t))_{m}/(y_{p,m}(t))_{m} )~~&\text{for}~ p\in\mathbb{N}, \end{array}\right. \end{array} $$

with \(y_{p,m}(t)\in \mathbb {C}^{m}\) from (2.9). The expression for the case \(p\in \mathbb {N}\) can be obtained by [30, (6.10)] applied on the representation \(|e_{m+p}^{\ast } \mathrm {e}^{t\widetilde {H}_{m}} e_{1}|\) for the defect ((iii). in Corollary 2) and making use of the special structure of \(\widetilde {H}_{m}\), \(\beta e_{m+p}^{\ast } \mathrm {e}^{t\widetilde {H}_{m}} e_{1} = t^{p} (y_{p,m}(t))_{m}\) (see Corollary 2) and \(\beta e_{m+p-1}^{\ast } \mathrm {e}^{t\widetilde {H}_{m}} e_{1} = t^{p-1} (y_{p-1,m}(t))_{m}\) (see [49, Corollary 1]).

As illustrated in Fig. 1 the defect can be highly oscillatory in a relevant time regime, especially for specific starting vectors, and in this case the quadrature estimates should be handled with care.

4.2 A stopping criterion for the lucky breakdown

The special case hk+ 1, k = 0 during the construction of the Krylov subspace is considered to be a lucky breakdown, a breakdown of the Arnoldi or Lanczos iteration with the benefit of an exact approximation of φp(tA)v for any t > 0 via the Krylov subspace \({\mathscr{K}}_{k}(A,v)\). In floating point arithmetic, the lucky breakdown results in hk+ 1, k ≈ 0 and can lead to stability issues if the Arnoldi or Lanczos method is not stopped properly. The condition that the Krylov propagator is exact is not exactly determinable in floating point arithmetic but can be weakened to the error condition in (2.13) for a given tolerance tol per unit step. With this approach, we introduce a stopping criterion which can be applied on the fly to detect a lucky breakdown and satisfies an error bound. This does not depend on any a priori information as long the tolerance tol is chosen properly so that round-off errors can be neglected, see remarks before Corollary 1.

Proposition 5

Let μ2(A) ≤ 0 and assume that round-off errors are sufficiently small, see Corollary 1. Let tol be a given tolerance and

$$ \frac{\beta h_{k+1,k}}{(p+1)!}\leq \text{tol} $$
(4.18)

be satisfied at the k th step of the Arnoldi or Lanczos iteration. Then, the iteration can be stopped and the Krylov subspace \({\mathscr{K}}_{k}(A,v)\) can be used to approximate the vector φp(tA)v with a respective error per unit step ∥lp, k(t)∥2t ⋅tol.

Proof

We use the upper bound on the error norm from Corollary 1,

$$ \|l_{p,k}(t)\|_{2} \leq \frac{ h_{k+1,k}}{t^{p}}{{\int}_{0}^{t}} |\delta_{p,k}(s)| \mathrm{d} s. $$
(4.19)

To obtain a uniform bound on the defect integral, we use

$$ |\delta_{p,k}(t)| \leq \beta t^{p} \|e_{k}\|_{2} \|\varphi_{p}(t H_{k}) e_{1}\|_{2} = \beta t^{p} \|\varphi_{p}(t H_{k}) e_{1}\|_{2}. $$
(4.20)
  • For p > 0, we apply the integral representation (2.3) on φp(tHm)e1 to obtain the upper bound

    $$ \|\varphi_{p}(t H_{m}) e_{1}\|_{2} \leq \frac{\max_{s\in[0,t]} \|\mathrm{e}^{s H_{m}}\|_{2}}{(p-1)!} {{\int}_{0}^{1}}\theta^{p-1} \mathrm{d}\theta = \frac{\max_{s\in[0,t]} \|\mathrm{e}^{s H_{m}}\|_{2} }{p!}. $$
    (4.21)
  • For p = 0, the analogous result is directly obtained: Combine (4.20) and (4.21) with \(\|\mathrm {e}^{sH_{k}}\|_{2} \leq \mathrm {e}^{t\mu _{2}(H_{k})} \leq {\mathrm {e}}^{t\mu _{2}(A)}\) up to round-off and μ2(A) ≤ 0, giving

    $$ |\delta_{p,k}(t)| \leq \beta \frac{t^{p} }{p!},~~~\text{and}~~{{\int}_{0}^{t}} |\delta_{p,k}(s)| \mathrm{d} s \leq \beta \frac{t^{p+1} }{(p+1)!}. $$

Together with (4.19) and (4.18), we conclude ∥lp, k(t)∥2t ⋅tol.

5 Numerical experiments

The notation for the error lp, m(t), the estimate of the error norm ζp, m(t) and the tolerance tol have been introduced in (2.12) and (2.13). The notation ζp, m will be used for different choices of error estimates discussed in the previous section. Theorem 4 and Corollary 4 result in upper bounds on the error norm, ∥lp, m(t)∥2ζp, m(t). The quadrature-based error estimates given in Remark 9 and 10 result in estimates for the error norm, ∥lp, m(t)∥2ζp, m(t), and with additional conditions also give upper bounds.

For a fixed tolerance tol, we use the notation t(m) for the smallest time t with ζp, m(t) = t ⋅tol, see (2.13). This choice of t(m) helps us to verify the tested error estimates for a time t which is of the most practical interest. With the help of a reference solution, the true error norm per unit step can be tested by ∥lp, m(t(m))∥2/t(m).

We also consider the following previously known error estimates in our numerical experiments. The generalized residual estimate [28] was recapitulated in Remark 9 and will be discussed in the numerical experiments. Furthermore, we test the performance of the error bound given in [10, Proposition 6]. This upper bound on the error norm applies to the Krylov approximation of φp(−tA)v for \(p\in {\mathbb {N}}_{0}\), a matrix \(A\in {\mathbb {R}}^{n\times n}\) with a numerical range in the right complex half-plane (up to a potential shift), and \(v\in \mathbb {R}^{n}\). In this case, the matrix A can have real and complex eigenvalues, where the latter come in complex conjugate pairs. Concerning the skew-Hermitian case, a similar error bound for the Krylov approximation to φp(−itB)v for a Hermitian matrix \(B\in {\mathbb {R}}^{n\times n}\) and \(p\in {\mathbb {N}}_{0}\) is given separately in [10, Proposition 8]. To evaluate these error bounds the eigenvalues of Hm and the terms hm+ 1, m and γm are used.

A series expansion for the error concerning φ-functions is given in [49, Theorem 2] and the leading terms of this expansion can be used for error estimation, cf. [41, 49]. In general [49] suggests to evaluate more than one term of this series to ensure reliability of the obtained error estimate, which requires further matrix-vector multiplications in the given large dimensional space. This can often be inefficient in terms of computational cost, cf. [30, Remark 7], and we avoid this series expansion in the general case. However, when the Ritz values are real-valued, the error bound in Corollary 3 (corresponding to the bound in Theorem 4) coincides with the leading term of the error series in [49, Theorem 2]. Thus, the first term of the error series in [49, Theorem 2] yields a reliable error bound in this case. For the convection-diffusion equation with parameter ν = 100 in Section 5.1 below (the Ritz values have negligible imaginary parts in this case), the error bound of Theorem 4 performs well (comparable to the effective order estimate and better than the other error estimates considered, e.g., the generalized residual estimate), and this potentially carries over to the error estimates in [41, 49].

5.1 Convection-diffusion equation

Consider the following two-dimensional convection-diffusion equation with t ≥ 0 and x ∈ [0,1]2,

$$ \partial_{t} u = L u,~~~\text{with}~~L= {\Delta} + \nu (\partial_{x_{1}} + \partial_{x_{2}} ) ,~~~u=u(t,x),~\nu\in\mathbb{R}. $$
(5.1)

Let \(A\in \mathbb {R}^{n\times n}\) be obtained by the two-dimensional finite difference discretization of the operator L in (5.1) with zero Dirichlet boundary conditions and N = 500 inner mesh points in each spatial direction, hence, n = N2. This test problem is similar to other convection-diffusion equations appearing in the study of Krylov subspace methods, see also [6, 15, 19, 30] and others.

For the convection parameter we choose ν = 100,500 which results in a non-normal matrix A. Considering the spectrum of A the case ν = 100 is closer to the Hermitian case and ν = 500 is closer to the skew-Hermitian case. In both cases, the numerical range of A is contained in the left complex plane, μ2(A) ≤ 0.

We discuss error estimates for the Krylov approximation of the matrix exponential (p = 0) and a φ-function (for which we choose p = 2). For the case p = 0, the action of the matrix exponential etAv is approximated in the Krylov subspace \({{\mathscr{K}}}_{m}(A,v)\), see (2.8b). Analogously, for the case p = 2 we approximate φp(tA)v as given in (2.8a). As a starting vector we choose the normalized vector \(v=(1/N,\ldots ,1/N)^{\ast }\in {\mathbb {R}}^{n}\). In Fig. 3, we compare the error bounds given in Theorem 4, Corollary 4 and [10, Proposition 6], and the generalized residual estimate (Remark 9) and the effective order estimate (Remark 10), for the convection-diffusion equation. The error bound of Corollary 4 is applied with \(\xi _{\max \limits }=0\) (the effect of \(\xi _{\max \limits }\) is negligible for the current examples). Concerning the error bound given in [10, Proposition 8], we choose the parameter ε by minimizing [10, (39)], and a = 0.

Fig. 3
figure 3

Convection-diffusion problem (5.1) for the parameter ν = 100 (top) and ν = 500 (bottom). For each choice of ν we consider p = 0 (left) and p = 2 (right). Three rows of plots are addressed to each choice of ν: The first row shows the time t(m) which is the smallest t such that ζp, m(t) = t ⋅tol for tol = 10− 6 and ζp, m corresponding to the error bound given in Theorem 4 (×), Corollary 4 (∘), the generalized residual estimate given in Remark 9 (+ ), the effective order estimate given in Remark 10 (\(\Box \)), and the error bound given in [10, Proposition 6] (△). For the second row we choose t(m) as the largest time step t(m) given by the currently discussed error estimate, and we show t(m)/t(m) for t(m) as chosen above. The third row shows the true error per unit step, ∥lp, m(t(m))∥2/t(m), for the time t(m) as chosen above

For the case ν = 100 the eigenvalues of Hm have a negligible imaginary part and the upper bound given in Theorem 4 constitutes a tight upper bound on the exact evaluation of the scaled defect integral, which yields a tight error bound. This error bound and the effective order estimate (Remark 10), which is based on a quadrature estimate on the defect integral, yield approximately the same results for the case ν = 100. The performance of the generalized residual estimate (Remark 9) is similar to the performance of the error bound in [10, Proposition 6], especially for larger choices of m. The error bound in Corollary 4 is only accurate for small m in the current example. The high accuracy of the error bound in Theorem 4 and the effective order estimates results in time steps t(m) which are larger than the time steps suggested by generalized residual estimate and the error bound in [10, Proposition 6], and significantly larger compared to the time steps given by Corollary 4. Comparing the cases p = 0 and p = 2, the time steps suggested by the error bounds of Corollary 4 and [10, Proposition 6] are slightly smaller in relation to the time step prescribed by the effective order estimate for p = 2. Considering the true error for the time steps computed by the error bound in Theorem 4, the effective order estimate and the generalized residual estimate, the performance of these estimates only differs slightly between the cases p = 0 and p = 2.

For the case ν = 500, the matrix Hm has eigenvalues with larger imaginary parts (especially for larger m). In this case the error bound in Theorem 4, is less tight, and the effective order estimate (Remark 10) performs best comparing to the other error estimates. Comparing the cases p = 0 and p = 2, we observe that the time steps suggested by the error bounds of Theorem 4, Corollary 4 and [10, Proposition 6] are slightly smaller in relation to the time step of the effective order estimate for p = 2.

The criterion ac.est.1(t) given in Remark 7 is evaluated for ν = 100,500 and p = 0,2 with t(m) corresponding to Theorem 4 (see caption of Fig. 3). For ν = 100 we obtain ac.est.1(t(m)) < 0.1 for any m tested and p = 0,2. For ν = 500 the smallest m with ac.est.1(t(m)) > 0.1 is m = 40 and m = 36 for p = 0 and p = 2, respectively. The error bound in Theorem 4 conforms to an upper bound of the scaled defect integral, and in the case of ac.est.1(t(m)) > 0.1 a more accurate estimate on the defect integral is likely to perform better. For ν = 500 and m = 40 (p = 0) and m = 36 (p = 2), we observe that this is the case for the effective order estimate. Similar to the criterion ac.est.1(t), we test ac.est.2(t) given in Remark 8 for t(m) according to Corollary 4. For ν = 100 the smallest m with ac.est.2(t(m)) > 0.1 is m = 7 for p = 0,2 individually. Otherwise, for ν = 500 the smallest m with ac.est.2(t(m)) > 0.1 is m = 8 and m = 7 for p = 0 and p = 2, respectively.

5.2 Free Schrödinger equation, a skew-Hermitian problem

For the free Schrödinger equation, we let A be a finite difference discretization of the Laplace operator, precisely, we choose A corresponding to L in (5.1) with ν = 0 and N = 500. With A corresponding to a discretized Laplace operator, the vector eitAv yields a solution to a discretized free Schrödinger equation with starting vector v. The free Schrödinger equation represents a skew-Hermitian problem, and following Remark 4 we approximate eitAv in the Krylov subspace \({\mathscr{K}}_{m}(A,v)\) by \(\beta V_{m} \mathrm {e}^{\mathrm {i} t H_{m}}e_{1}\). Analogously to the previous subsection, we choose the normalized starting vector \(v=(1/N,\ldots ,1/N)^{\ast }\in {\mathbb {R}}^{n}\), and we also consider the Krylov approximation to φp(itA)v for p = 2, i.e., βVmφp(itHm)e1.

In Fig. 4, the error bounds given in Corollary 4 (which coincides with the error bound given in Theorem 4 in the skew-Hermitian case) and [10, Proposition 8] (the counterpart to [10, Proposition 6] for the skew-Hermitian case), the effective order estimate (Remark 10), and the generalized residual estimate (Remark 9) are evaluated for the current example. For the parameter ε in [10, Proposition 8], we choose ε = m/t as suggested in the numerical experiments therein.

Fig. 4
figure 4

The skew-Hermitian problem φp(iA)v where A corresponds to the Laplace operator ((5.1) with ν = 0) and v = (1/N,…,1/N). Results are shown for p = 0 (left) and p = 2 (right). For p = 0 this problem is related to the free Schrödinger equation. The top row shows the time t(m) which is the smallest t such that ζp, m(t) = t ⋅tol for tol = 10− 6 and ζp, m corresponding to the error bound given in Theorem 4 (×), Corollary 4 (∘), the generalized residual estimate given in Remark 9 (+ ), the effective order estimate given in Remark 10 (\(\Box \)), and the error bound given in [10, Proposition 8] (△). The error bounds in Theorem 4 (×) and Corollary 4 (∘) coincide in the skew-Hermitian case. For the middle row we choose t(m) as the largest time step t(m) given by the currently discussed error estimate, and we show t(m)/t(m) for t(m) as chosen above. The bottom row shows the true error per unit step, ∥lp, m(t(m))∥2/t(m), for the time t(m) as chosen above

For the skew-Hermitian case, the effective order estimate (Remark 10) yields the largest time steps compared to the other error estimates. The error bound of Corollary 4 performs well for moderate m and better than the error bound in [10, Proposition 8] for any of the tested m here. For larger m the generalized residual estimate performs better than the error bound of Corollary 4. Similar to examples of the previous subsection, the error bound of Corollary 4 performs better for the case p = 0 compared to p = 2. Similar results can be observed for the error bound of [10, Proposition 8]. The performance of the effective order estimate and the generalized residual estimate only differs slightly between the cases p = 0 and p = 2.

We test ac.est.2(t) given in Remark 8 for t(m) according to Corollary 4. The smallest m with ac.est.2(t(m)) > 0.1 is m = 15 and m = 13 for p = 0 and p = 2, respectively. Following Remark 8, the error bound given in Corollary 4 overestimates the error by a factor 1.1 (in an asymptotic sense) for these values of m, which fits to the results shown in Fig. 4.

5.3 Free Schrödinger equation with a double well potential and a Gaussian wave packet as an initial state

In the following numerical experiment, we choose a special starting vector which results in the matrix Hm having clustered eigenvalues, and we observe effects which were previously discussed in Section 4.1. Typically, this is related to regularity properties of the underlying initial state.

We consider the one-dimensional free Schrödinger equation with a double well potential,

$$ \partial_{t} \psi= -\mathrm{i} H\psi,~~~\text{with}~~H = -{\Delta} + V,~~~\psi=\psi(t,x)\in\mathbb{C},~V=V(x)\in\mathbb{R}, $$
(5.2)

for t ≥ 0, x ∈ [− 10,10] and V (x) = x4 − 15x2. Let \(B\in \mathbb {C}^{n\times n}\) be the discretized version of the Hamiltonian operator H in (5.2) with periodic boundary conditions using a finite difference scheme with a mesh of size n = 10000. With B Hermitian, the full problem A = −iB is skew-Hermitian (see Remark 4) with μ2(A) = 0. For the initial state of (5.2) we choose a Gaussian wave packet,

$$ \psi(t=0,x)=(0.2\pi)^{-1/4}\exp(-(x+2.5)^{2}/(0.4)), $$
(5.3)

which is evaluated on the mesh and normalized to obtain a discrete starting vector \(v\in \mathbb {R}^{n}\). This problem also appears in [29, 51].

We discuss error estimates for the case p = 0 (Krylov approximation of e−itBv). The implementation of the skew-Hermitian problem is described in Remark 4. In Fig. 5 the upper bound given in Corollary 4 (which coincides with the error bound given in Theorem 4 for the skew-Hermitian case) and the error estimates given in Remark 9 and 10 are compared. Additionally, we consider the error bound given in [10, Proposition 8] with the parameter choice ε = m/t.

Fig. 5
figure 5

Results for the free Schrödinger problem with a double well potential and the starting vector given by (5.3). This figure shows the time t(m) (bottom left), which is the smallest t so that zeta0, m(t) = ttol for tol = 10− 6, the true error per unit step (top) |l0, m(t(m))|2/t(m) and the defect norm |deltam,0(t)| (bottom right) for min10,20,30,40,50. The results for t(m) and ∥l0, m(t(m))∥2/t(m) are given for ζ0, m being the upper norm bound given in Theorem 4 (×), Corollary 4 (∘), the generalized residual estimate given in Remark 9 (+ ), the effective order estimate given in Remark 10 (\(\Box \)) and the error bound given in [10, Proposition 8] (△). The results for Theorem 4 (×) and Corollary 4 (∘) coincidence in the skew-Hermitian case

The error bounds given in Corollary 4 and [10, Proposition 8] are reliable but not tight for the current example. Thus, the time steps t(m) which are suggested by these error bounds are significantly smaller than the time steps suggested by the quadrature-based error estimates (Remarks 9 and 10), and comparing with the numerical experiments of the previous subsection, this seems to be highly affected by the choice of the starting vector. For the error bound in Corollary 4, this can be explained by the loss of order of the defect. However, the error bound in Corollary 4 shows a better performance compared to the error bound in [10, Proposition 8].

In terms of accuracy, the effective order estimate (Remark 10) performs significantly better compared to the error bounds in Corollary 4 and [10, Proposition 8], and better compared to the generalized residual estimate (Remark 9). In terms of reliability, we have argued that the effective order estimate and the generalized residual estimate constitute upper bounds on the error norm when the defect norm behaves sufficiently smooth. The defect norm |δm,0(t)|, which is presented in the lower right corner of Fig. 5, does have an oscillatory behavior in a specific time regime which can be related to the starting vector, cf. Section 4.1. For the time steps which are relevant for the current example, this does not critically affect the quadrature estimates on the defect integral related to Remark 9 and 10. Under certain conditions, e.g., a different choice for the tolerance tol, this oscillatory behavior of the defect can lead to failure of the error estimates given in Remark 9 and 10. However, the quadrature of the defect integral can be further improved in such cases to ensure a reliable error estimate.

6 Conclusions and outlook

In this work, various a posteriori bounds and estimates on the error norm, which have their origin in an integral representation of the error using the defect (residual), are studied. We have characterized the accuracy of these error bounds by the positioning of Ritz values (i.e., eigenvalues of Hm) on the complex plane. The case of real Ritz values is the most favorable one to obtain a tight error bound via an integral on the defect norm (Corollary 3). A new error bound (Theorem 4) has shown to be tight if Ritz values are close to the real axis and in this case favorably compares with existing error bounds. We further recapitulate an existing error bound (Corollary 4) which remains relevant, especially for the case of Ritz values with a significant imaginary part. In addition for the error bound in Theorem 4 and Corollary 4, we have provided a criterion to quantify the achieved accuracy on the fly. For an illustration of the claims concerning the new error bound, we primary refer to the numerical example given in Section 5.1. The quadrature-based error estimates in Section 4.1 (e.g., the generalized residual estimate) do not yield proven upper bounds on the error norm and we addressed special cases (e.g., the numerical example in Section 5.3) for which the reliability of these estimates can be problematic. These cases are also analyzed in terms of Ritz values in Section 4.1 and this relation can be of further interest for a numerical implementation. Nevertheless, in most cases, the quadrature-based estimates remain valid, whereat the effective order quadrature stands out in terms of performance.

We also remark that the theory provided in our work gives the possibility to adapt the choice of the error estimate on the fly to obtain an estimate which is as reliable, accurate and economic as possible. This is the topic of further work.