1 Introduction

Analytic continuation is well known to be ill-posed. To be precise, suppose a function f is analytic in a connected open region \(\varOmega \) of the complex plane and we know its values in a set \(E\subset \overline{\varOmega }\) to an accuracy of \(\varepsilon >0\). (We assume E is a bounded nonempty continuum whose closure does not enclose any points of \(\varOmega \backslash \overline{E}\), and that f extends analytically to E.) This implies no bounds whatsoever on the value of f at any point \(z\in \varOmega \backslash \overline{E}\) (see Theorem 5.1). And yet if we knew f exactly in E, this would determine its values in \(\varOmega \) exactly.

In practice, nevertheless, analytic continuation from inexact data is carried out all the time, and what makes this possible is regularization, the introduction of additional smoothness assumptions. Often an extrapolation technique is applied without such assumptions being made explicit—and this is understandable, for in applications, often one has a sense of certain features of one’s function without being able to pin them down precisely. In this paper, however, we wish to be completely explicit and show how certain natural regularizing assumptions lead to upper and lower bounds on the accuracy of analytic continuation.

Our regularizing assumption will be that f is not only analytic in \(\varOmega \), but bounded. For example, we can take the bound to be \({\textstyle {1\over 2}}\) and consider the set of functions that are analytic in \(\varOmega \) and satisfy \(\Vert f\Vert _\varOmega ^{} \le {\textstyle {1\over 2}}\). (The symbol \(\Vert \cdot \Vert _A^{}\) always denotes the supremum norm over the set A.) If \(f,{\tilde{f}}\) are two such functions, then \(\Vert {\tilde{f}}-f\Vert _\varOmega ^{} \le 1\). We shall show (Theorem 5.2) that if in addition \(\Vert {\tilde{f}}-f\Vert _E^{}\le \varepsilon \), then for each \(z\in \varOmega \backslash \overline{E}\),

$$\begin{aligned} |{\tilde{f}}(z) -f(z)| \le \varepsilon ^{\alpha (z)} \end{aligned}$$
(1.1)

for some \(\alpha (z)\in (0,1)\) that depends on \(\varOmega \), E, and z but not on f and \({\tilde{f}}\) or \(\varepsilon \). Another way to say the same thing is

$$\begin{aligned} \log |{\tilde{f}}(z) -f(z)| \le \alpha (z) \log \varepsilon . \end{aligned}$$
(1.2)

We may interpret (1.2) as follows: if we know a function f satisfying \(\Vert f\Vert _\varOmega \le {\textstyle {1\over 2}}\) to d digits on E, then it is determined to \(\alpha (z) d\) digits at z. Even though our theorems are, of course, mathematical rather than computational results, we shall use the terminology of digits a good deal in discussing them, for this is an easy way to talk about logarithmic quantities.

This general framework may sound rather abstract. It becomes concrete when we consider the dependence of \(\alpha (z)\) on z for particular choices of \(\varOmega \) and E, and after stating a basic lemma in Sect. 2, we shall focus on two choices that are particularly fundamental. The first is radial geometry, with analytic continuation outward from the unit disk E into a disk \(\varOmega \) of radius \(R>1\) (Sect. 3). In this setting analytic continuation is reasonably well-conditioned, with digits of accuracy being lost only linearly as |z| increases. This observation possibly goes back to Hadamard himself, and its numerical implications have been considered by various authors including Franklin [12] and especially Miller [6, 20, 21]. An intuitive way to understand the effect is to note that in the limiting case \(R\rightarrow \infty \), Liouville’s theorem implies that f must be constant, so if we know f to accuracy \(\varepsilon \) on E, we know it to the same accuracy everywhere. The result for finite R (Theorem 3.1) can be derived from the Hadamard three-circles theorem [18]. The essence of the matter is that analyticity and boundedness at a large radius imply rapid exponential decrease of Taylor coefficients, hence good behavior at smaller radii.

Analytic continuation is much more difficult in the other geometry we focus on, which is linear (Sect. 4). Here we take \(\varOmega \) to be an infinite half-strip of half-width 1 (without loss of generality), and E as the end segment of the half-strip. As z moves away from E along the centerline of the strip, digits are lost exponentially as a function of distance, and we prove this (Theorem 4.1) by reducing the problem to the configuration of Lemma 2.1. At a point z that is \(2\pi \) units away from the end, for example, the number of accurate digits has shrunk by a factor \((\pi /4)\exp (\pi ^2)\approx \)15,000, so if you want to have 3 digits of accuracy at such a point, you’ll need to start with 45,000 digits.

Our formulations are conformally invariant, and thus different regions \(\varOmega \ne {\mathbf{C}}\) can be transplanted from one to another. In particular, analytic continuation in a disk and a half-strip are essentially equivalent problems, and the reason the half-strip is exponentially more difficult than the disk is that the conformal map that relates them is an exponential. Section 5 explores results for general regions (not necessarily simply connected) that follow from these observations, presenting theorems establishing the behavior asserted in the opening paragraphs of this introduction.

Along the way, we shall relate our results to numerical algorithms. Section 3 presents a simple method for numerical analytic continuation in a disk that approximately achieves the bounds indicated in Theorem 3.1, based on Taylor series on the disk, and in Sect. 6 we show that this method is implicit in Chebfun [9, 26]. An algorithm of this kind was proposed by Franklin [12], and there is recent related work by Demanet and coauthors [4, 7], among others. Further numerical algorithms and associated mathematical estimates for analytic continuation can be found in [6, 8, 13,14,15,16,17, 20, 22, 23, 25, 27]. More generally, there is a large literature of numerical methods for ill-posed problems, which are often defined by partial differential or integral equations. One paper that speaks of the connection between analytic continuation and more general ill-posed problems defined by PDEs is [20]. It is worth noting that both Theorems 3.1 and 4.1 include “Conversely” assertions, which establish that in the disk and strip geometries, analytic continuation is algebraically and exponentially ill-conditioned, respectively. This implies that no numerical algorithm can de better than indicated for all functions satisfying the assumptions of the theorems, although an algorithm (such a Padé approximation and its relatives) may do better when applied to particular functions with larger regions of analyticity.

In Sect. 7 we turn to the most famous algorithm of analytic continuation, which goes back to Weierstrass: marching Taylor expansions from one overlapping disk to another in a chain. We show that this method, if carried out numerically in the half-strip with a certain optimal choice of parameters, suffers exponential loss of accuracy at a rate \(2e/\pi \) times faster than the optimal rate in a half-strip, so that if one marches \(2\pi \) units down the half-strip, the number of accurate digits is divided by \(\exp (2\pi e) \approx {26{,}000{,}000}\).

Before turning to the details, we comment on the relationship between approximation methods based on multiple derivative values at a single point, such as chain-of-disks continuation of Taylor series or Padé approximation [3], and methods based just on function values but at multiple points. Our formulations are of the latter form, but the two contexts are close. Thanks to the standard lemma of complex analysis known as Cauchy’s estimate, knowing a function f on the unit disk to accuracy \(\varepsilon \) is approximately the same as knowing its Taylor coefficients \(c_k\) to accuracy \(\varepsilon \), and more generally, if f is known to accuracy \(\varepsilon \) on the closed disk of radius r, this is approximately the same as knowing its Taylor coefficients \(c_k\) to accuracy \(\varepsilon r^{-k}\).

Also on the theme of extrapolation from function values, we note that in practice, an algorithm will make use of a set of discrete samples rather than information on a continuum, and this could lead to further inaccuracy if the points are ill-chosen. This issue is not addressed here but is related to the contributions of [4, 7, 20].

2 A lemma

Our results are based on the following lemma, the Hadamard three-lines theorem, a more general form of which can be found in [24, Thm. 12.8]. Numerical algorithms for this geometry are discussed in [14].

Lemma 2.1

Let h be an analytic function in the infinite strip \(S = \{ w: \, 0< \hbox {Re }w < 1\}\) with \(\Vert h\Vert _S^{}\le 1\) and \(\lim _{u\downarrow 0}^{} \sup _v|h(u+iv)| \le \varepsilon \) for some \(\varepsilon \in (0,1)\). Then for all \(w\in S\),

$$\begin{aligned} \log |h(w)| \le (1-\hbox {Re }w)\log \varepsilon , \quad \hbox {i.e.,} \quad |h(w)| \le \varepsilon ^{1-\hbox {Re }w}. \end{aligned}$$
(2.1)

Conversely, for any \(\varepsilon \in (0,1)\), there is a function h satisfying the given conditions for which the inequalities (2.1) hold as equalities for all z with \(0< \hbox {Re }z < 1\).

Proof

We begin by noting that without loss of generality, we may suppose that h is analytic on the closed set \(\overline{S}\). If not, we could restrict attention to a smaller domain \(\delta \le \hbox {Re }w \le 1-\delta \) for \(\delta <0\) and then take the limit \(\delta \rightarrow 0\).

Set \(\nu = -\log \varepsilon \), implying \(e^{-\nu } = \varepsilon \). The function \(e^{-\nu w} h(w)\) is analytic in \(\overline{S}\) and bounded in absolute value by \(\varepsilon \) for \(\hbox {Re }w = 0\) and also for \(\hbox {Re }w = 1\). Therefore, by the maximum modulus principle as qualified in the next paragraph, it is bounded by \(\varepsilon \) for all \(w\in \overline{S}\). Thus \(|h(w)| \le \varepsilon e^{\nu \hbox {Re }w} = e^{(1-\hbox {Re }w)\log \varepsilon }\), as required.

The qualification just mentioned is that the maximum modulus principle does not apply to arbitrary functions on an unbounded domain with a gap in the boundary at \(\infty \). However, this function is known to be bounded in an infinite strip, and in such a situation, according to a Phragmén–Lindelöf theorem [18, Thm. 18.1.4], the maximum modulus principle applies after all.

For the converse, it is enough to consider the function \(h(w) = \varepsilon e^{\nu w}\). \(\square \)

3 Analytic continuation in a disk

Figure 1 shows our first fundamental geometry, one that has been considered by a number of authors. We take E to be the closed unit disk and \(\varOmega \) as the open disk of radius \(R>1\). As always, our concern is obtaining bounds on |g(z)|,  \(z \in \varOmega \backslash E\), for an analytic function g (\(= {\tilde{f}}- f\)) satisfying \(\Vert g\Vert _\varOmega ^{} \le 1\) and \(\Vert g\Vert _E^{}\le \varepsilon \). Here is the result, essentially the Hadamard three-circles theorem, with \(\Vert \cdot \Vert _r^{}\) denoting the supremum norm over \(\{z:\, |z|< r\}\).

Fig. 1
figure 1

Analytic continuation of a function f from the unit disk E to a larger disk \(\varOmega \) where it is bounded. If f is known to d digits on E, the number of digits determined in \(\varOmega \) falls off smoothly to 0 at the outer boundary

Theorem 3.1

Given \(R>1\), let g be analytic in \(\varOmega = \{z\in {\mathbf{C}}: \, |z|< R\}\) with \(\Vert g\Vert _R^{}\le 1\) and \(\Vert g\Vert _1^{}\le \varepsilon \in (0,1)\). Then for any z with \(1< |z|< R\),

$$\begin{aligned} \log |g(z)| \le \alpha (z) \log \varepsilon , \quad \hbox {i.e.,}\quad |g(z)| \le \varepsilon ^{\alpha (z)}, \end{aligned}$$
(3.1)

where

$$\begin{aligned} \alpha (z) = 1 - {\log |z|\over \log R}. \end{aligned}$$
(3.2)

Conversely, for an infinite sequence of values \(\varepsilon \) converging to 0, there are functions g satisfying the given conditions for which the inequalities (3.1) hold as equalities for all z with \(1<|z|<R\).

Proof

As in the proof of Lemma 2.1, we begin by noting that without loss of generality, we may suppose that g is analytic in the closed domain \(|z| \le R\). We transplant the problem to the infinite strip \(\overline{S}\) of the last section by defining \(h(w) = g(z)\) for \(z = R^{ w} = e^{w\log R}\), hence \( w = \log z / \log R\) (it doesn’t matter which branch of \(\log z\) is used, as they all lead to the same estimate). By the lemma, we have \(\log |g(z)|\le (1- \hbox {Re }w)\log \varepsilon = (1-\log |z|/\log R)\log \varepsilon \), as claimed.

For the converse result, consider \(g(z) = (z/R)^n\) with \(n = -\log \varepsilon / \log R\). For an infinite sequence of values \(\varepsilon \rightarrow 0\), n is an integer, and in these cases g is an analytic function with the required properties. \(\square \)

In words, we can describe Theorem 3.1 as follows. If f is known to d digits for \(|z|\le 1\), the number of digits determined for \(|z|=r\) diminishes to 0 as \(r\rightarrow R\); as a function of \(\log r\), the loss of digits is linear. At \(r=\sqrt{R}\), for example, f is determined to d/2 digits.

It is easy to outline an algorithm for analytic continuation, based on a finite Taylor series of length \(n \approx -\log \varepsilon /\log R\), that achieves approximately the accuracy promised in Theorem 3.1. From approximate values for \(|z|=1\) with error at most \(\varepsilon \) of a function f with \(\Vert f\Vert _\varOmega ^{}\le {\textstyle {1\over 2}}\), we compute approximations \({\tilde{c}}_k\approx c_k\) to the Taylor coefficients \(\{c_k\}\) of f for \(0\le k \le n\) with \(|{\tilde{c}}_k-c_k|\le \varepsilon \). That this is possible follows from Cauchy’s estimate applied on the circle \(|z|=1\); in practice, we sample f on a grid of \(N\gg n\) roots of unity and use the Fast Fourier Transform [2]. By Cauchy’s estimate applied now for \(|z|=R\), the Taylor coefficients of f satisfy \(|c_k| \le {\textstyle {1\over 2}}R^{-k}\). If we define

$$\begin{aligned} {\tilde{f}}(z) = \sum _{k=0}^n {\tilde{c}}_k z^k, \end{aligned}$$
(3.3)

then we have

$$\begin{aligned} {\tilde{f}}(z)-f(z) = \sum _{k=0}^n ({\tilde{c}}_k-c_k) z^k - \sum _{k=n+1}^\infty c_kz^k, \end{aligned}$$

implying

$$\begin{aligned} |{\tilde{f}}(z)-f(z)| \le \sum _{k=0}^n \varepsilon |z|^k + {\textstyle {1\over 2}}\sum _{k=n+1}^\infty (|z|/R)^k. \end{aligned}$$

Our choice \(n \approx -\log \varepsilon /\log R\) implies \(\varepsilon \approx R^{-n}\), and thus these two sums are both of size on the order of \((|z|/R)^n\). We therefore achieve, as required,

$$\begin{aligned} |{\tilde{f}}(z)-f(z)| \approx (R/|z|)^{-n} = R^{-\alpha (z)n} \approx \varepsilon ^{\alpha (z)}, \end{aligned}$$

with the equality in the middle holding since the definition (3.2) implies \(R^{\alpha (z)} = R/|z|\).

In the algorithm just described, the regularization occurred when we took the series (3.3) to be finite rather than infinite. In this geometry, the ill-posedness of analytic continuation resides in the fact that as \(k\rightarrow \infty \), powers \(z^k\) have unbounded discrepancies of absolute value between one radius |z| and another. For a fascinating analysis of the implications of such behavior in the context of computation of Taylor coefficients, see [5]. The importance of truncating a series for numerical analytic continuation was recognized at least as early as [19], and a detailed error analysis of an algorithm with this flavor can be found in [12].

We have described the algorithm as a process for working with a function known to accuracy \(\varepsilon \) on the unit disk. One way to obtain such data is to take Taylor polynomials of f of successively higher degrees (in exact arithmetic), in which case (3.1) amounts to the statement that the convergence of Taylor polynomials to f(z) for \(|z|<R\) is exponential at a rate of order \((|z|/R)^n\).

4 Analytic continuation in a half-strip

Our second fundamental geometry is shown in Fig. 2. Now E is the complex interval \((-i,i)\) and \(\varOmega \) is the half-strip H of points \(z=x+iy\) with \(x> 0\), \(-1<y<1\). Our aim is to analytically continue a function f from the end segment of the strip to real positive values x.

Fig. 2
figure 2

Analytic continuation of a bounded function f along the centerline of an infinite half-strip H of half-width 1. The number of digits determined falls off exponentially with distance from the data, reducing by a factor of 10 each time x increases by \((2/\pi )\log 10 \approx 1.47\)

To apply Lemma 2.1 in this geometry, we need to map H conformally to the infinite strip S of Sect. 2 in such a way that the corner points \(z = \pm i\) map to the infinite vertices \(w = \pm i \infty \) and \(z=\infty \) maps to \(w=1\). We can construct such a map by composing three simpler maps. First, \(u = \sinh (\pi z/2)\) maps H to the right half-plane with distinguished points \(\pm i\) and \(\infty \). Next, \(v = {(i-u)/(i+u)}\) maps the right half-plane to the upper half-plane with distinguished points 0, \(\infty \), and \(-1\). Finally, \(w = (-i/\pi )\log v\) maps the upper half-plane to S as required. Combining these steps, we find that the map from the half-strip H in the z-plane to the infinite strip S in the w-plane is given by

$$\begin{aligned} w = -{i\over \pi } \log \left( {i - \sinh (\pi z/2)\over i + \sinh (\pi z/2)} \right) = {2i\over \pi }\log \left( {1-i\exp (\pi z/2)\over -i + \exp (\pi z/2)} \right) . \end{aligned}$$
(4.1)

The properties of this map are such as to reveal that analytic continuation into a half-strip where a function is known to be bounded, while possible in principle, is so ill-conditioned as to be generally infeasible in practice. Instead of digits of accuracy being lost linearly, they are lost exponentially, as emphasized in Fig. 2. To see how this comes about, consider the situation in which z is a real number \(x>0\). The leading terms in the asymptotics for u, v, and w for large x give us

$$\begin{aligned} u \sim {\textstyle {1\over 2}}e^{\pi x / 2}, \quad v \sim -1 + 4i e^{-\pi x/2}, \quad w \sim 1 - {4\over \pi } e^{-\pi x/2}. \end{aligned}$$
(4.2)

Since w is exponentially close to 1, Lemma 2.1 implies that the number of digits of accuracy will be multiplied by an exponentially small factor \({\sim } (4/\pi ) \exp (-\pi x /2)\). A more careful analysis sharpens (4.2) to

$$\begin{aligned} {4\over \pi } e^{-\pi x/2} - \left( {4\over \pi } - 1\right) e^{-\pi x} \,\le \, 1- w \,\le \, {4\over \pi } e^{-\pi x/2} \quad (x \ge 0), \end{aligned}$$
(4.3)

from which we get the following theorem:

Theorem 4.1

Let g be analytic in the half-strip H with \(\Vert g\Vert _H^{}\le 1\) and \(\Vert g\Vert _E^{}\le \varepsilon \) for some \(\varepsilon \in (0,1)\). Then for any \(x > 0\),

$$\begin{aligned} \log |g(x)| \le \alpha (x) \log \varepsilon , \quad \hbox {i.e.,} \quad |g(x)| \le \varepsilon ^{\alpha (x)}, \end{aligned}$$
(4.4)

where

$$\begin{aligned} \alpha (x) = {4\over \pi } e^{-\pi x/2} - \left( {4\over \pi } - 1\right) e^{-\pi x}. \end{aligned}$$
(4.5)

Conversely, for any \(\varepsilon \in (0,1)\), there is a function g satisfying the given conditions for which, for all \(x\ge 0\),

$$\begin{aligned} \log |g(x)| \ge \beta (x) \log \varepsilon , \quad \hbox {i.e.,}\quad |g(x)| \ge \varepsilon ^{\beta (x)}, \end{aligned}$$
(4.6)

with

$$\begin{aligned} \beta (x) = {4\over \pi } e^{-\pi x/2}. \end{aligned}$$
(4.7)

Proof

This follows from Lemma 2.1 by the conformal transplantation (4.1), using the bounds (4.3). \(\square \)

5 General geometries

For more general geometries than the disk or the half-strip, let us now justify the claims made in the introduction. First is the ill-posedness statement of the opening paragraph, which as usual we formulate as an assertion about an analytic function \(g = {\tilde{f}}- f\). Essentially this result is stated in words on p. 348 of [21].

Theorem 5.1

Let \(\varOmega \) be a connected open region of the complex plane \({\mathbf{C}}\) and let E be a bounded nonempty continuum in \(\overline{\varOmega }\) whose closure \(\overline{E}\) does not enclose any points of \(\varOmega \backslash \overline{E}\). Let g be an analytic function in \(\varOmega \cup E\) satisfying \(\Vert g\Vert _E^{} \le \varepsilon \) for some \(\varepsilon > 0\). This condition implies no bounds whatsoever on the value of g at any point \(z\in \varOmega \backslash \overline{E}\).

Proof

Given \(z\in \varOmega \backslash \overline{E}\) and a complex number M, we shall show there is a polynomial p such that \(\Vert p\Vert _E^{}\le \varepsilon \) and \(p(z) = M\). Let \({\tilde{E}}\) denote the compact set consisting of \(\overline{E}\) together with all points enclosed by this set; thus the complement of \({\tilde{E}}\) in the complex plane is connected. By assumption, \(z \not \in {\tilde{E}}\). According to Runge’s theorem [24, Thm. 13.7], there is a polynomial q such that \(\Vert q\Vert _{{\tilde{E}}}^{} \le \varepsilon /2\) and \(|q(z)-M| \le \varepsilon /2\). Now define \(p(\zeta ) = q(\zeta ) + M - q(z)\). We readily verify \(p(z) = M\) and \(| p(\zeta )| \le |q(\zeta )| + |M-q(z)| \le \varepsilon \) for all \(\zeta \in E\). \(\square \)

The well-posedness statement of the introduction is (1.1), which we formulate as follows. A similar result can be found as Lemma 1 of [21].

Theorem 5.2

Let \(\varOmega \), E, \(\varepsilon \), and g be as in Theorem 5.1, but now with g additionally satisfying \(\Vert g\Vert _\varOmega ^{}\le 1\), and let z be a point in \(\varOmega \backslash \overline{E}\). Assume that the boundary of E is piecewise smooth (a finite union of smooth Jordan arcs). Then there is a number \(\alpha \in (0,1)\), independent of g though not of z, such that for all \(\varepsilon >0\),

$$\begin{aligned} |g(z)| \le \varepsilon ^{\alpha (z)}. \end{aligned}$$
(5.1)

Proof

Let \(\varGamma \) be a smooth open arc in \(\varOmega \) connecting a point e in the boundary of E, which will necessarily belong to \(\overline{\varOmega }\), to z. For a sufficiently small \(\delta >0\), the intersection of the open \(\delta \)-neighborhood of \(\varGamma \) with \(\varOmega \) is a simply-connected region J in \(\varOmega \) with z in its interior and a piecewise smooth boundary, a portion of E making up part of this boundary. By a conformal map, we may transplant J to the domain of Fig. 2, whereupon Theorem 4.1 provides a suitable (if typically very pessimistic) value of \(\alpha \).    \(\square \)

Theorem 5.2 asserts that analytic continuation in the presence of a boundedness condition is a well-posed problem in the sense that there is a unique solution depending continuously on the data, but this does not mean that its condition number is finite. A finite condition number would correspond to |g(z)| shrinking linearly with \(\varepsilon \), that is, to a value \(\alpha = 1\) in (5.1), or more generally to the bound

$$\begin{aligned} |g(z)| \le C\varepsilon \end{aligned}$$
(5.2)

as \(\varepsilon \rightarrow 0\) for some constant C depending on z but not g. But Theorem 5.2 only gives \(\alpha < 1\), and in fact, we now show that \(\alpha = 1\) cannot occur except in trivial cases with \(\overline{\varOmega }= {\mathbf{C}}\).

Theorem 5.3

Under the circumstances of Theorem 5.2, a bound of the form (5.2) can never hold unless \(\overline{\varOmega }\) is the whole complex plane \({\mathbf{C}}\).

Proof

If \(\overline{\varOmega }\) is all of \({\mathbf{C}}\), we may be in the trivial situation mentioned in the introduction, where Liouville’s theorem implies that g is constant. (This will be true, for example, if \(\varOmega \) consists of \({\mathbf{C}}\) with a finite set of points removed. It won’t be true if \(\varOmega \) consists of \({\mathbf{C}}\) with some arcs removed.) On the other hand suppose there is a point \(z_0^{}\in {\mathbf{C}}\) disjoint from \(\overline{\varOmega }\). Then there is a closed disk \(\varDelta \) about \(z_0^{}\) that is disjoint from \(\overline{\varOmega }\). By the conformal map \(1/(z-z_0^{})\), we may transplant the problem so that \(\varOmega \) and E are bounded. For any \(z \in \varOmega \backslash \overline{E}\), as in the proof of Theorem 5.1, Runge’s theorem ensures that there is a polynomial p such that \(p(z) = 0\) and \(\hbox {Re }p(\zeta ) \le -1\) for all \(\zeta \in E\). Choose \(M>0\) such that \(\hbox {Re }p(\zeta ) \le M\) for all \(\zeta \in \varOmega \). Then \(q(z) = p(z)-M\) has real parts \(\le -(1+M)\) for \(\zeta \in E\), \(-M\) at z, and \(\le 0\) for \(\zeta \in \varOmega \). Given \(\varepsilon \in (0,1)\), define \(g(\zeta ) = \exp [\log (\varepsilon )(-q(\zeta ))/(1+M)]\). Then \(\Vert g\Vert _\varOmega ^{}\le 1\) and \(\Vert g\Vert _E^{} \le \varepsilon \), but \(|g(z)| = \varepsilon ^{M/(M+1)}\). This contradicts (5.2). \(\square \)

Together, Theorems 5.2 and 5.3 assert that analytic continuation with a boundedness condition in a nontrivial region is always well-posed but always has an infinite condition number. These observations echo the results of Miller in [21], though he did not express them in terms of the condition number.

6 Analytic continuation in Chebfun

This project sprang from work with Chebfun, a software system for numerical computing with functions [9]. In its basic mode of operation, Chebfun works with smooth functions on an interval that without loss of generality we may take to be \([-1,1]\). Chebfun represents each function to \({\approx } 16\) digit precision by a polynomial in the form of a finite Chebyshev series, and early in the project, it was realized that the same series could be used for evaluation at complex points off the interval.

Fig. 3
figure 3

Chebfun implicitly carries out analytic continuation within a Bernstein ellipse bounded approximately by the nearest complex singularity of a function f defined on a real interval. For the function \(f(x) = \log (1+x^2)\) defined on \([-1,1]\), the thick outer curve shows the “Chebfun ellipse” estimate of the region of analyticity plotted by plotregion and the inner curves are contour lines corresponding to errors \(|f(x) - p(x)| = 10^{-2}, 10^{-4}, \dots , 10^{-14}\) (from the outside in), where p is the Chebfun approximation, a polynomial of degree 38. The dots mark the actual branch points of f

Figure 3 illustrates this effect for the function \(f(x) = \log (1+x^2)\), which has branch points at \(x = \pm i\). By an adaptive process described in [1], the Chebfun command p = chebfun(’log(1+x\(^{\hat{}}\) 2)’) constructs a polynomial p that matches f on \([-1,1]\) with a maximal error of about \(2^{-51} \approx 4.44\times 10^{-16}\); the degree of p for this example is 38. Typing p(0) to evaluate the polynomial at \(x=0\), for example, returns the value \(5.5\times 10^{-17}\), accurate to more than 16 digits. What is interesting is that typing p(i/2) also gives an accurate value: \(-0.2876820630\), as compared with the true value \(\log (0.75) \approx -0.2876820725\). How can we explain this?

In fact, Chebfun is carrying out the Chebyshev analogue of the algorithm of Sect. 3: it computes a finite sequence of Chebyshev series coefficients, then uses these coefficients to define an approximation \(p = {\tilde{f}}\). Instead of working outward from the unit disk E to larger disks, it is working outward from the unit interval E to so-called Bernstein ellipses, whose algebra is defined by a transplantation of the results of Sect. 3 by the Joukowski map \((z+z^{-1})/2\). For details, see [26], particularly the discussions of the “Chebfun ellipse” and the command plotregion. According to Theorem 3.1 as transplanted from disks to ellipses, we can expect the number of accurate digits to fall off smoothly, and Fig. 3 shows that this is just what is observed.

In this example it is interesting to note that the accuracy achieved by Chebfun matches the prediction based on the assumption that the function is analytic only in the Bernstein ellipse, even though \(\log (1+x^2)\) can in fact be extended analytically to the whole complex plane minus two slits. The explanation is that polynomial expansions on an interval truly have their limitations. To take advantage of analyticity in different domains one must move beyond algorithms based on polynomials.

Analytic continuation in a region bounded by an ellipse is mentioned as Example 3 of [12], and a detailed analysis of algorithms in this geometry is presented in [7]. Results for ellipses analogous to those of [5] for disks can be found in [28].

7 Analytic continuation by a chain of disks

The classic idea for analytic continuation, going back to Weierstrass, involves a succession of Taylor expansions, each with its own disk of convergence. In principle, this procedure enables one to track a function along any path where it is analytic, and we recommend the beautifully illustrated discussion in Section 3.6 of Wegert’s Visual Complex Functions [29]. For inexact function data, however, the method is far from promising. There is a small literature on numerical realizations, and a memorable contribution is a 1966 paper by Henrici in which the necessary transformations of series coefficients are formulated in terms of matrix multiplications; see [16] or [17, sec. 3.6].

To analyze this idea quantitatively, the simplest setting is a channel, essentially the same as the half-strip of Sect. 4. Specifically, consider the finite-length “stadium” G shown in Fig. 4. Given \(L>0\), this is the strip of half-width 1 extending from \(x=0\) to \(x=L\) together with half-disks of radius 1 at each end. For some \(n>0\) and \(r\in (0,1),\) we define \(h=L/n\) and

$$\begin{aligned} x_{k}^{}= kh, ~~D_{k}^{}= \{z: \, |z-x_k|< 1\}, ~~ D_{k}^{(r)}= \{z: \, |z-x_k|< r\} \end{aligned}$$
(7.1)

for \(0 \le k \le n\). We assume n is large enough so that \(h < 1-r\).

Theorem 7.1

With the definitions of the last paragraph, let f be analytic in G with \(\Vert f\Vert _G^{}\le 1\) and let \(f_{k}^{}\) be analytic in \(D_k^{}\) with \(\Vert f_{k}^{}\Vert _{D_k^{}}^{}\le 1\), \(0\le k \le n-1\). Assume \(r\le 1/2\) and \(h\le 1/4\). Given \(\varepsilon \in (0,1)\), define

$$\begin{aligned} \varepsilon _{k}^{}= \varepsilon ^{ \exp (-{\tilde{e}}x_{k}^{})}, \quad {\tilde{e}}= {1+2h\over r\log (1/r)}. \end{aligned}$$
(7.2)

If

$$\begin{aligned} \Vert f_0^{}-f\Vert _{D_0^{(r)}} \le \varepsilon _0^{} \end{aligned}$$
(7.3)

and

$$\begin{aligned} \Vert f_{k}^{}-f_{k-1}^{}\Vert _{D_k^{(r)}} \le \varepsilon _{k}^{}, \quad 1\le k \le n-1, \end{aligned}$$
(7.4)

then for all sufficiently small choices of \(\varepsilon \),

$$\begin{aligned} \Vert f_{k-1}^{}- f\Vert _{D_k^{(r)}}^{} \le \varepsilon _{k}^{}, \quad 1 \le k \le n. \end{aligned}$$
(7.5)
Fig. 4
figure 4

Chain-of-disks analytic continuation of a function f along a channel G of half-width 1 where it is assumed to be bounded and analytic. One starts with f known to accuracy \(\varepsilon _0^{}=\varepsilon \) in the shaded disk \(D_0^{(r)}\) of radius r about \(x_0 = 0\); this is then used to construct an expansion to accuracy \(\varepsilon _1^{}\) in the next shaded disk about \(x_1^{}=h\), and so on. The best accuracy is achieved with \(r = 1/e\) and \(h\rightarrow 0\), with the number of accurate digits diminishing at the rate \(\exp (-ex)\)

Proof

We proceed by induction on k in (7.5). The case \(k=1\) follows from (7.3) by Theorem 3.1 (rescaled by a factor \(R=1/r\)). Consider step \(k+1\), assuming (7.5) has been established for previous steps. Combining (7.4) and (7.5) gives

$$\begin{aligned} \Vert f_{k}^{}- f\Vert _{D_{k}^{(r)}}^{} \le 2 \varepsilon _{k}^{}. \end{aligned}$$
(7.6)

By Theorem 3.1 (with the same rescaling as before), (7.6) implies

$$\begin{aligned} \Vert f_{k}^{}- f\Vert _{D_{k+1}^{(r)}}^{} \le (2 \varepsilon _{k}^{})^\alpha , \quad \alpha = 1 - {\log (1+h/r)\over \log (1/r)}. \end{aligned}$$
(7.7)

(We avoid replacing \(\log (1/r)\) by \(-\log r\) since it can be confusing to have to remember that \(\log r\) is negative.) We are done if we can show

$$\begin{aligned} (2\varepsilon _{k}^{})^\alpha \le \varepsilon _{k+1}^{}. \end{aligned}$$

or by taking logarithms,

$$\begin{aligned} \left( 1 - {\log (1+h/r)\over \log (1/r)}\right) (\log 2 + \log (\varepsilon _{k}^{})) \le \log (\varepsilon _{k+1}^{}). \end{aligned}$$

By (7.2), if we divide both sides by the negative quantity \(\log (\varepsilon _{k}^{})\), this becomes

$$\begin{aligned} \left( 1 - {\log (1+h/r)\over \log (1/r)}\right) \left( {\log 2 \over \log (\varepsilon _{k}^{})} + 1\right) \ge \exp \left( {-h-2h^2\over r \log (1/r)}\right) . \end{aligned}$$
(7.8)

Now suppose for a moment that \(\varepsilon _{k}^{}\) is negligible. Then the \(\log 2 /\log (\varepsilon _{k}^{})\) term goes away and the condition we must verify reduces to

$$\begin{aligned} 1 - {\log (1+h/r)\over \log (1/r)} \ge \exp \left( {-h-2h^2\over r \log (1/r)}\right) . \end{aligned}$$

A numerical search readily confirms that this holds with a strict inequality over the indicated region \(r\in (0,1/2)\), \(h\in (0,1/4)\) (the coefficient of the term \(-2h^2\) was introduced to ensure this). Because of the assumption in the theorem statement that \(\varepsilon \) is sufficiently small, this establishes (7.8). \(\square \)

The conclusion of Theorem 7.1 becomes memorable in the limit \(\varepsilon ,h\rightarrow 0\). The parameter \({\tilde{e}}\) of (7.2) is then minimized with the choice \(r=1/e\), for which it takes the value \({\tilde{e}}= e\). We conclude that with this optimal choice of r,

The number of accurate digits in chain-of-disks continuation

along a channel of half-width 1 decays at the rate \(\exp (-ex)\).

A comparison with Theorem 4.1 shows that the chain-of-disks method loses digits at a rate \(e/(\pi /2) \approx 1.73\) times faster than optimal.

In a field as established as complex analysis, it is hard to be sure that anything is entirely new, but I am not aware of a previous estimation of loss of digits at the rate \(\exp (-e x)\) for chain-of-disks continuation. The general observation of exponential loss of information is more than a century old. Henrici [16] writes (his italics)

The early vectors \(\dots \) must be computed more accurately than the late ones

and he gives credit for related work to Mittag-Leffler, Painlevé, Zeller, and Lewis [19].

It is interesting to note what our estimates suggest for what might be considered a very natural test problem for analytic continuation. Suppose we have a function like \(f(z) = \sqrt{z}\) that is known to be bounded and analytically continuable along any curve in the punctured disk \(0< |z|<2\). If we start near \(z=1\) with a certain accuracy \(\varepsilon \) and go around the origin and back to \(z=1\) again, how much accuracy will remain? We will not attempt to give a sharp solution to this problem, but it is the example that motivated our choice of a strip of length \(2\pi \) for the numbers quoted in the introduction. Our estimates suggest that the number of accurate digits may be reduced by a factor as great as \((\pi /4)\exp (\pi ^2) \approx \hbox {15,000}\), or \(\exp (2 \pi e) \approx \hbox {26,000,000}\) for the chain-of-disks method.

8 Conclusion

A compelling presentation of the practical side of analytic continuation can be found in the book to appear by Fornberg and Piret [11]. In the case of exactly known functions, although one could use the chain-of-disks idea in principle, Taylor series play little role in practice. A far more powerful approach is to find an analytical method to transform one formula defining a function (a formula being after all a finite object, unlike an infinite set of Taylor coefficients) into another formula with a new region of validity. For the most famous of all examples, the Dirichlet series for the Riemann zeta function converges only for \(\hbox {Re }z > 1\), but other representations extend \(\zeta (z)\) to the whole complex plane.

The present paper has concerned the case of inexactly known functions. Here, for continuation of functions from a disk to a larger disk, or from an interval to an ellipse, algorithms related to Taylor or Chebyshev series are effective, as has been discovered by various authors and we have illustrated by Fig. 3 from Chebfun. A third equivalent context would be analytic continuation of a periodic function into a strip by Fourier series. The question is, what can one do to continue a function beyond the disk/ellipse/strip of convergence of its Taylor/Chebyshev/Fourier series? Our theorems show that if all one knows is analyticity and boundedness along certain channels, then accuracy may be lost at a precipitous exponential rate, better than the chain-of-disks but only by a constant. However, the assumption of analyticity just in a channel is more pessimistic than necessary in many applications. Functions arising in applications rarely have natural boundaries or other beautiful pathologies of analytic function theory, however generic such structures may be from a certain abstract point of view; they are far more likely to be analytic everywhere apart from certain poles and branch points. In practice, rational functions are the crucial tool for analytic continuation in such cases, and when they work, their convergence is typically exponential, just as we have found for series-based methods in a disk [3, 10, 26]. It would be an interesting challenge to develop theorems for meromorphic functions analogous to what we have established here in the analytic case, and a discussion with some of this flavor can be found in [21].