betaFeedback

WorksMathematics

A fast automatically adaptive integral equation solver for nonlinear two-point boundary value systems

Abstract

We present a fast, high-order, automatically adaptive integral-equation solver for nonlinear two-point boundary value systems. The method builds on the fast direct solver for linear second-kind integral equations and completes the mathematical formulation needed for general boundary conditions, including cases in which the simplest background Green's function is singular and cases with genuinely rank-deficient boundary conditions. Nonlinear problems are written as nonlinear second-kind integral equations and are solved by combining this fast adaptive linear solver with Newton iteration and user-specified continuation. In this way the nonlinear solver inherits the full strengths of the linear integral-equation method: a fast direct solver, arbitrary order accuracy, and automatic adaptive resolution with only a small overhead over a solve on the final mesh. The resulting algorithm is particularly effective for problems with localized or multiscale structure, including boundary layers, dense oscillations, transition regions, hypersensitive optimal-control systems, and singular perturbations. The same framework also provides a computational foundation for future studies of bifurcation and solution-branch exploration.

Introduction

Many problems in science and engineering require the numerical solution of two-point boundary value problems for systems of ordinary differential equations, which take the form of

Φ′(x)=F(Φ(x),x),A⋅Φ(a)+C⋅Φ(c)=γ,(1)\Phi'(x) = F(\Phi(x),x), \qquad A\cdot\Phi(a)+C\cdot\Phi(c)=\gamma, \tag*{(1)}

where Φ:[a,c]→Rn\Phi:[a,c]\to\mathbb{R}^{n} is in C1[a,c]C^{1}[a,c], F:Rn×[a,c]→RnF:\mathbb{R}^{n}\times[a,c]\to\mathbb{R}^{n} is smooth, A,C∈Rn×nA,C\in\mathbb{R}^{n\times n}, and γ∈Rn\gamma\in\mathbb{R}^{n}. Such systems arise after rewriting high-order scalar equations, singular perturbation problems, optimal-control problems, and travelling-wave or bifurcation equations. We focus on linear boundary conditions, which already cover a large class of applications. More general nonlinear boundary conditions can in principle be handled by applying the same linearization idea to the boundary equations, but this extension is not pursued here.

The difficult regimes for two-point BVPs are often governed by local structure: boundary layers, internal transition regions, dense oscillations, and hypersensitive dynamics may occupy only a small part of the interval. Direct discretization of the differential operator must then resolve these small scales while also solving the resulting linear systems inside Newton or continuation iterations. Moreover, discretized differential operators inherit mesh-dependent conditioning; refining the mesh to resolve a layer can make the algebraic problem substantially more ill-conditioned than

Integral formulation and boundary preprocessing

the underlying continuous BVP. Continuation methods encounter the same issue repeatedly: as a parameter varies, layers and transition regions may appear or move, forcing standard differential-discretization approaches to combine path following with careful mesh adaptation and, in difficult regimes, problem-specific treatment [2, 7, 1].

Integral-equation formulations address this issue at its source. By using a background Green’s function, the BVP is converted to a second-kind integral equation, so the conditioning of the discrete system respects the conditioning of the underlying continuous problem rather than the mesh spacing. Greengard and Rokhlin developed this idea for scalar two-point BVPs [6], Lee and Greengard built an automatic adaptive solver for stiff scalar problems [8], and Leeb and Rokhlin later treated fourth-order scalar equations [9]. Starr and Rokhlin formulated and solved the first-order system case [11]: Special structure of the Green’s function gives a hierarchically off-diagonal low-rank representation, and the resulting continuous-level fast solver has linear complexity. This can be viewed as a special case of fast direct solvers, where a compressed representation of the system’s matrix is constructed once and then applied efficiently to one or many right-hand sides [10].

The system formulation of Starr and Rokhlin, however, imposed an artificial restriction in order to use the simplest background Green’s function: the matrix A+CA+C had to be nonsingular. This is not a solvability condition for the original BVP. The authors proposed using a manually constructed linear transform to convert a user’s boundary conditions into this form, but that requirement limits the black-box use of the algorithm. More importantly, an arbitrary manual transform may introduce artificial ill conditioning and thereby compromise the principal advantage of the integral-equation formulation.

Our first contribution is to complete the mathematical formulation for general linear boundary conditions. We give an explicit, well-conditioned-by-construction boundary transform whenever the boundary conditions are nondegenerate. When the boundary conditions themselves are truly rank deficient, we first test compatibility and then complete the boundary conditions, reducing the problem to a family of full-rank problems. In the linear case this yields the full affine solution space: a particular solution together with basis solutions for the missing boundary data. Because the Starr–Rokhlin algorithm is a fast direct solver, this solution-space computation is naturally organized as a multiple-right-hand-side solve; the expensive factorization is shared and the extra basis functions are obtained at marginal cost.

Our second contribution is to extend this completed linear solver to nonlinear systems. We formulate the nonlinear BVP as a nonlinear second-kind integral equation and use the fast adaptive linear solver as the computational kernel for Newton corrections and user-specified continuation. In this way we have coupled the fast direct solver, boundary-condition preprocessing, Newton iteration, continuation, and automatic adaptivity into a nonlinear BVP solver which inherits the essential advantages of the linear integral-equation method: well-conditioned discretizations, arbitrary order accuracy, linear complexity, and automatic adaptivity. These properties are especially valuable for nonlinear problems with localized or multiscale structure, where continuation and Newton iterations repeatedly require reliable linearized solves on evolving meshes.

The rest of the paper is organized as follows. § 2 develops the integral-equation formulation and gives the explicit boundary-condition preprocessing, including the treatment of truly degenerate boundary conditions. § 2.5 summarizes the fast direct solver and high-order Nyström discretization used for the linearized problems. § 3 and § 4 describe Newton iteration and user-specified continuation for the nonlinear integral equation, and Section 6 gives the adaptive strategy. Section 7 presents a sequence of challenging numerical examples designed to test the formulation, accuracy, scaling, adaptive efficiency, behavior on nonlinear problems with multiple solutions, and performance on singularly perturbed systems. Section 8 concludes with the role of the method in future bifurcation computations.

Integral formulation and boundary preprocessing

In this section, we develop the second-kind integral-equation formulation for two-point boundary value systems. The linear formulation serves as the computational kernel for the nonlinear solver of later sections.

Linear equations

We start with definitions and notation.

Definition 2.1 (Linear TPBVP). A linear TPBVP has the form

Φ′(x)+p(x)⋅Φ(x)=f(x),(2)\Phi'(x) + p(x) \cdot\Phi(x) = f(x), \tag*{(2)}
A⋅Φ(a)+C⋅Φ(c)=γ.(3)A \cdot\Phi(a) + C \cdot\Phi(c) = \gamma. \tag*{(3)}

The equation is referred to as homogeneous if f=0f = 0:

Φ′(x)+p(x)⋅Φ(x)=0,(4)\Phi'(x) + p(x) \cdot\Phi(x) = 0, \tag*{(4)}

and the boundary condition is referred to as homogeneous if γ=0\gamma= 0.

A⋅Φ(a)+C⋅Φ(c)=0.(5)A \cdot\Phi(a) + C \cdot\Phi(c) = 0. \tag*{(5)}

Definition 2.2 (Green’s function). A continuous function G(x,t):[a,c]×[a,c]→L(Rn×n)G(x,t): [a,c] \times[a,c] \to L(\mathbb{R}^{n \times n}) is referred to as the Green’s function for the BVP problem (5)(4) if:

  • ∂G(x,t)∂x\frac{\partial G(x,t)}{\partial x} is continuous except at x=tx=t.

  • G(x+0,x)−G(x−0,x)=InG(x+0,x)-G(x-0,x)=I_n for all x∈[a,c]x \in[a,c].

  • ∂∂xG(x,t)+p(x)⋅G(x,t)=0\frac{\partial}{\partial x}G(x,t)+p(x)\cdot G(x,t)=0 for all x,t∈[a,c]x,t \in[a,c], x≠tx \ne t.

  • A⋅G(a,t)+C⋅G(c,t)=0A\cdot G(a,t)+C\cdot G(c,t)=0 for all t∈[a,c]t \in[a,c].

Remark 2.3. Assume that Γ(x)\Gamma(x) is the fundamental matrix of (5)(4). If D=A⋅Γ(a)+C⋅Γ(c)D=A\cdot\Gamma(a)+C\cdot\Gamma(c) is nonsingular, then the Green’s function exists and is unique [3]. Moreover, there is an unique solution Φ(x)\Phi(x) for the inhomogeneous problem (5)(2):

Φ(x)=∫acG(x,t)f(t) dt.(6)\Phi(x)=\int_a^c G(x,t)f(t)\,\mathrm{d}t. \tag*{(6)}

For most variable-coefficient boundary value problems, the exact Green’s function is unavailable. We instead introduce a background problem for which the fundamental matrix and Green’s function are known. This converts the original equation with homogeneous boundary conditions into a second-kind integral equation. The construction follows [6, 11].

Definition 2.4. The background equation is a homogeneous equation with homogeneous boundary equations

Φ′(x)+p0(x)⋅Φ(x)=0A⋅Φ(a)+C⋅Φ(c)=0,(7)\begin{aligned} \Phi'(x)+p_0(x)\cdot\Phi(x)&=0 \\ A\cdot\Phi(a)+C\cdot\Phi(c)&=0, \tag*{(7)} \end{aligned}

with the fundamental matrix Γ0(x)\Gamma_0(x) and Green’s function G0G_0, satisfying D0=A⋅Γ0(a)+C⋅Γ0(c)D_0=A\cdot\Gamma_0(a)+C\cdot\Gamma_0(c) is nonsingular.

Theorem 2.5. Consider the BVP

Φ′(x)+p(x)⋅Φ(x)=f(x),A⋅Φ(a)+C⋅Φ(c)=0.(8)\Phi'(x) + p(x)\cdot\Phi(x) = f(x), \qquad A\cdot\Phi(a) + C\cdot\Phi(c) = 0. \tag*{(8)}

If it has a fundamental matrix Γ(x)\Gamma(x) such that D:=A⋅Γ(a)+C⋅Γ(c)D := A\cdot\Gamma(a)+C\cdot\Gamma(c) is nonsingular, then the unique solution can be represented as

Φ(x)=∫acG‾0(x,t)σ(t) dt,(9)\Phi(x)=\int_{a}^{c} \overline{G}_0(x,t)\sigma(t)\,\mathrm{d}t, \tag*{(9)}

where σ\sigma is the solution of the second-kind integral equation

σ(x)+(p(x)−p0(x))⋅∫acG‾0(x,t)⋅σ(t) dt=f(x).(10)\sigma(x)+(p(x)-p_0(x))\cdot\int_{a}^{c} \overline{G}_0(x,t)\cdot\sigma(t)\,\mathrm{d}t=f(x). \tag*{(10)}

The reduction of inhomogeneous boundary data to homogeneous form depends on the processed boundary condition matrices; it is deferred to § 2.4 after the boundary-condition preprocessing.

Background equations and the artificial restriction in the simplest formulation

The simplest background equation is obtained by taking p0=0p_0=0. Then the Green’s function is

G‾0(x,t)={In−(A+C)−1⋅C(t≤x),−(A+C)−1⋅C(t≥x).(11)\overline{G}_0(x,t)= \begin{cases} I_n-(A+C)^{-1}\cdot C & (t\leq x),\\ -(A+C)^{-1}\cdot C & (t\geq x). \end{cases} \tag*{(11)}

and Theorem 2.5 reduces to the following corollary.

Corollary 2.6. If D0=A+CD_0=A+C and D=A⋅Γ(a)+C⋅Γ(c)D=A\cdot\Gamma(a)+C\cdot\Gamma(c) is nonsingular, where Γ(x)\Gamma(x) is the fundamental matrix of (4) (5). Then the unique solution of (2) (5) is

Φ(x)=∫acG‾0(x,t)σ(t) dt,(12)\Phi(x)=\int_{a}^{c}\overline{G}_0(x,t)\sigma(t)\,\mathrm{d}t, \tag*{(12)}

where σ\sigma is the solution of the integral equation

σ(x)+p(x)⋅∫acG‾0(x,t)⋅σ(t) dt=f(x),(13)\sigma(x)+p(x)\cdot\int_{a}^{c}\overline{G}_0(x,t)\cdot\sigma(t)\,\mathrm{d}t=f(x), \tag*{(13)}

Two different issues must be separated. The condition det⁡(A+C)≠0\det(A+C)\ne0 is only the condition that makes the particular background Green’s function (11) well defined; it is not a solvability condition for the original BVP. Thus an otherwise well-posed problem may be excluded for a purely artificial reason. This occurs, for example, when a second-order scalar equation with separated Dirichlet data is rewritten as a first-order system: the boundary matrices select the first component at opposite endpoints and A+CA+C is singular. Higher-order scalar equations with separated boundary data lead to the same phenomenon. In contrast, the condition R(A)+R(C)≠RnR(A)+R(C)\ne\mathbb{R}^{n} means that the boundary conditions themselves are rank deficient. The former difficulty should be removed by a well-conditioned transform; the latter requires a compatibility check and a completion of the missing boundary data.

This distinction is essential for nonlinear problems. Newton and continuation methods repeatedly solve linearized boundary value systems with the same boundary matrices. A nonlinear solver built on the integral formulation is therefore only as general as its linear correction solver. Completing the boundary-condition formulation is what makes the fast direct linear solver a reliable kernel for the nonlinear method.

Automatic preprocessing for the case det⁡(A+C)=0\det(A+C)=0

We now give a constructive treatment of the case det⁡(A+C)=0\det(A+C)=0. This is not merely an implementation device; it completes the integral-equation formulation for general nondegenerate boundary conditions. The background problem with p0=0p_0=0 is attractive because its Green’s function is explicit, cheap to evaluate and leads to a well conditioned integral equation, but it is usable only when the transformed boundary matrix is invertible. The following change of variables supplies this missing ingredient.

Let

Φ(x)=T(x)Φ^(x),T(x)∈GLn(R),x∈[a,c].(14)\Phi(x)=T(x)\hat{\Phi}(x), \qquad T(x)\in GL_n(\mathbb{R}), \qquad x\in[a,c]. \tag*{(14)}

The transformed equation and boundary condition are

Φ^′(x)+T(x)−1⋅(T′(x)+p(x)⋅T(x))⋅Φ^(x)=T(x)−1f(x),(15)\hat{\Phi}'(x)+T(x)^{-1}\cdot\left(T'(x)+p(x)\cdot T(x)\right)\cdot\hat{\Phi}(x)=T(x)^{-1}f(x), \tag*{(15)}
A⋅T(a)⋅Φ^(a)+C⋅T(c)⋅Φ^(c)=0.(16)A\cdot T(a)\cdot\hat{\Phi}(a)+C\cdot T(c)\cdot\hat{\Phi}(c)=0. \tag*{(16)}

Thus the transformed problem can be paired with the simplest background Green’s function (11) as soon as

det⁡(AT(a)+CT(c))≠0.(17)\det(AT(a)+CT(c))\ne0. \tag*{(17)}

The following theorem shows that, except for the genuinely rank-deficient boundary conditions discussed in the next subsection, such a transformation always exists and can be constructed explicitly.

Theorem 2.7 (construction of an admissible boundary transform). Let A,C∈Rn×nA,C\in\mathbb{R}^{n\times n}. There exists a function T∈C1([a,c];Rn×n)T\in C^1([a,c];\mathbb{R}^{n\times n}) such that

T(x)∈GLn(R)for all x∈[a,c],det⁡(AT(a)+CT(c))≠0,(18)T(x)\in GL_n(\mathbb{R}) \quad\text{for all } x\in[a,c], \qquad\det(AT(a)+CT(c))\ne0, \tag*{(18)}

if and only if

R(A)+R(C)=Rn,(19)R(A)+R(C)=\mathbb{R}^n, \tag*{(19)}

or equivalently

N(AT)∩N(CT)={0}.(20)N(A^T)\cap N(C^T)=\{0\}. \tag*{(20)}

Moreover, TT may be chosen as a smooth path from the identity matrix to the product of a signed permutation matrix and a nonsingular diagonal matrix.

Proof. We first prove necessity. If there exists a nonzero vector z∈N(AT)∩N(CT)z\in N(A^T)\cap N(C^T), then

zT(AT(a)+CT(c))=0(21)z^T\left(AT(a)+CT(c)\right)=0 \tag*{(21)}

for every choice of T(a)T(a) and T(c)T(c). Hence AT(a)+CT(c)AT(a)+CT(c) cannot be nonsingular. Therefore an admissible transform implies (20), which is equivalent to (19) by elementary linear algebra.

For sufficiency, write the columns of AA and CC as

A=(a1,…,an),C=(c1,…,cn).(22)A=(a_1,\ldots,a_n), \qquad C=(c_1,\ldots,c_n). \tag*{(22)}

Condition (19) means that the 2n2n columns a1,…,an,c1,…,cna_1,\ldots,a_n,c_1,\ldots,c_n span Rn\mathbb{R}^n. Therefore there are index sets

{i1,…,ir},{j1,…,jn−r}(23)\{i_1,\ldots,i_r\}, \qquad\{j_1,\ldots,j_{n-r}\} \tag*{(23)}

such that

ai1,…,air,cj1,…,cjn−r(24)a_{i_1},\ldots,a_{i_r},c_{j_1},\ldots,c_{j_{n-r}} \tag*{(24)}

are linearly independent. Choose a permutation σ∈Sn\sigma\in S_n such that

{i1,…,ir}∪{σ(j1),…,σ(jn−r)}={1,…,n}.(25)\{i_1,\ldots,i_r\}\cup\{\sigma(j_1),\ldots,\sigma(j_{n-r})\}=\{1,\ldots,n\}. \tag*{(25)}

We look for a transform satisfying T(a)=IT(a)=I and T(c)=PσΛT(c)=P_\sigma\Lambda, where PσP_\sigma is the permutation matrix associated with σ\sigma and Λ=diag⁡(λ1,…,λn)\Lambda=\operatorname{diag}(\lambda_1,\ldots,\lambda_n) is diagonal. Then

AT(a)+CT(c)=A+CPσΛ.(26)AT(a)+CT(c)=A+CP_\sigma\Lambda. \tag*{(26)}

Choose a scalar λ>1\lambda>1 and set

{∣λk∣=λ,k=σ(jl),l=1,…,n−r,∣λk∣=λ−1,k=il,l=1,…,r.(27)\begin{cases} |\lambda_k|=\lambda, & k=\sigma(j_l),\quad l=1,\ldots,n-r,\\ |\lambda_k|=\lambda^{-1}, & k=i_l,\quad l=1,\ldots,r. \tag*{(27)} \end{cases}

The signs of the λk\lambda_k may be chosen arbitrarily, or chosen to improve the conditioning of the resulting matrix. With this convention,

A+CPσΛ=(a1+β1cσ(1),…,an+βncσ(n)),(28)A+CP_\sigma\Lambda=(a_1+\beta_1c_{\sigma(1)},\ldots,a_n+\beta_nc_{\sigma(n)}), \tag*{(28)}

where βk\beta_k is the kkth diagonal entry of Λ\Lambda. After scaling the columns indexed by σ(J)\sigma(J) by λ−1\lambda^{-1} and the columns indexed by II by λ\lambda, the limit as λ→∞\lambda\to\infty is a matrix whose columns are, up to signs, the independent set

ai1,…,air,cj1,…,cjn−r.(29)a_{i_1},\ldots,a_{i_r},c_{j_1},\ldots,c_{j_{n-r}}. \tag*{(29)}

Therefore det⁡(A+CPσΛ)\det(A+CP_\sigma\Lambda) is not identically zero as a function of λ\lambda, and there exists a finite value of λ\lambda for which (17) holds. It remains to connect II to PσΛP_\sigma\Lambda inside GLn(R)GL_n(\mathbb{R}). Decompose PσP_\sigma into transpositions,

Pσ=PmPm−1⋯P1.(30)P_\sigma=P_mP_{m-1}\cdots P_1. \tag*{(30)}

If PlP_l swaps the coordinate directions sls_l and klk_l, replace it by a smooth rotation path P~l(x)\widetilde{P}_l(x) that is the identity on all other coordinates and has the two-dimensional block

\begin{pmatrix} \cos\theta(x)&-\sin\theta(x)\\ \sin\theta(x)&\cos\theta(x) \end{pmatrix}, \qquad \theta(x)=\frac{\pi(x-a)}{2(c-a)}. \tag*{(31)}\end{pmatrix}

At x=cx=c, this realizes the transposition up to a sign change, which can be absorbed into the diagonal matrix. Let

P~σ(x)=P~m(x)P~m−1(x)⋯P~1(x).(32)\widetilde{P}_\sigma(x)=\widetilde{P}_m(x)\widetilde{P}_{m-1}(x)\cdots\widetilde{P}_1(x). \tag*{(32)}

For the diagonal part, choose a path

Λ(x)=diag⁡(ℓ1(x),…,ℓn(x)),(33)\Lambda(x)=\operatorname{diag}(\ell_1(x),\ldots,\ell_n(x)), \tag*{(33)}

where ℓk(a)=1\ell_k(a)=1, ℓk(c)=λk\ell_k(c)=\lambda_k, and ℓk(x)\ell_k(x) never crosses zero. For positive λk\lambda_k, one may simply take

ℓk(x)=1+x−ac−a(λk−1).(34)\ell_k(x)=1+\frac{x-a}{c-a}(\lambda_k-1). \tag*{(34)}

For negative λk\lambda_k, the sign can first be moved into the signed permutation part, leaving a positive diagonal path. Finally set

T(x)=P~σ(x)Λ(x).(35)T(x)=\widetilde{P}_{\sigma}(x)\Lambda(x). \tag*{(35)}

Then T(a)=IT(a)=I, T(c)=PσΛT(c)=P_{\sigma}\Lambda up to the prescribed signs, T(x)T(x) is nonsingular for every xx, and (17) holds.

Remark 2.8. The theorem separates two issues that are often conflated. The condition det⁡(A+C)=0\det(A+C)=0 means only that the particular background Green’s function (11) is not directly available. It does not indicate a defect in the boundary value problem. In contrast, failure of (19) means that the boundary condition itself is rank deficient for arbitrary boundary data. That genuinely degenerate case is treated separately in § 2.3.

Remark 2.9. The construction of Λ\Lambda in (27) uses a limiting argument. Numerically, it is unnecessary to take λ\lambda large in advance. We start from λ=1\lambda=1 and double it until A+CPσΛA+CP_{\sigma}\Lambda is nonsingular and has acceptable conditioning. In practice boundary conditions arising from physical problems are far from arbitrary, and the procedure above terminates with moderate values of λ\lambda in all cases we have examined; a fully general bounded construction of Λ\Lambda is straightforward should it ever be needed.

The proof is constructive and gives the preprocessing algorithm below. This step is performed once for a given pair (A,C)(A,C) and then reused throughout Newton iteration and continuation.

Algorithm 2.1 Boundary-condition preprocessing for det⁡(A+C)=0\det(A+C)=0
Require: Boundary matrices A=(a1,…,an)A=(a_1,\ldots,a_n) and C=(c1,…,cn)C=(c_1,\ldots,c_n) satisfying R(A)+R(C)=RnR(A)+R(C)=\mathbb{R}^n; interval endpoints a,ca,c; conditioning threshold κmax⁡\kappa_{\max}.
Ensure: ACAC path T:[a,c]→GLn(R)T:[a,c]\to GL_n(\mathbb{R}) such that det⁡(AT(a)+CT(c))≠0\det(AT(a)+CT(c))\ne0.
1: Select index sets I={i1,…,ir}I=\{i_1,\ldots,i_r\} and J={j1,…,jn−r}J=\{j_1,\ldots,j_{n-r}\} such that {ai:i∈I}∪{cj:j∈J}\{a_i:i\in I\}\cup\{c_j:j\in J\} is a basis of Rn\mathbb{R}^n.
2: Choose σ∈Sn\sigma\in S_n such that I∪σ(J)={1,…,n}I\cup\sigma(J)=\{1,\ldots,n\}.
3: Decompose PσP_\sigma into transpositions PmPm−1⋯P1P_mP_{m-1}\cdots P_1.
4: Replace each transposition PlP_l by the rotation path (31), absorbing endpoint signs into the diagonal matrix to obtain P~σ(x)\widetilde{P}_{\sigma}(x).
5: Set λ←1\lambda\leftarrow1.
6: repeat
7: Form Λ=diag⁡(λ1,…,λn)\Lambda=\operatorname{diag}(\lambda_1,\ldots,\lambda_n) according to (27).
8: Set D←A+CPσΛD\leftarrow A+CP_\sigma\Lambda.
9: If DD is singular or κ2(D)>κmax⁡\kappa_2(D)>\kappa_{\max}, set λ←2λ\lambda\leftarrow2\lambda.
10: until DD is nonsingular and κ2(D)≤κmax⁡\kappa_2(D)\le\kappa_{\max}
11: Construct Λ(x)\Lambda(x) by (33) and set T(x)=P~σ(x)Λ(x)T(x)=\widetilde{P}_{\sigma}(x)\Lambda(x).
12: return TT.

Table 2.1.

After Algorithm 2.1, the transformed problem (15)–(16) satisfies the nondegeneracy condition for the simplest background Green’s function. The integral equation formulation (12)–(13) then readily applies.

Remark 2.10. The transform not only restores the black-box property, it also preserves conditioning. Writing the linearized operator as L=L0+E\mathcal{L}=\mathcal{L}_0+\mathcal{E}, the second-kind equation contains I+EL0−1I+\mathcal{E}\mathcal{L}_0^{-1}, so a poor transform or background Green’s function

Truly degenerate boundary conditions

can by itself degrade conditioning. Since TT, T−1T^{-1}, and T′T' are uniformly bounded, the original and transformed operators differ only by bounded pre- and post-composition; their condition numbers therefore differ by a constant depending on these bounds, which the construction keeps moderate.

Truly degenerate boundary conditions

The discussion above assumes R(A)+R(C)=RnR(A)+R(C)=\mathbb{R}^{n}. This is the regime in which arbitrary boundary data are consistent and the boundary-condition defect is only the artificial singularity of A+CA+C in the background Green’s function. There is also the genuinely rank-deficient case in which

R(A)+R(C)≠Rn.(36)R(A)+R(C)\ne\mathbb{R}^{n}. \tag*{(36)}

In that case the boundary condition itself does not impose nn independent conditions on arbitrary boundary data. The original problem may be inconsistent, or it may possess a family of solutions. Examples of this category include incompletely specified endpoint data in optimal-control problems and certain free-boundary reductions. We describe a boundary-completion procedure that reduces this case to the full-rank case treated above.

Let

B=[A C]∈Rn×2n,k=rank⁡(B)=dim⁡(R(A)+R(C))<n.(37)\mathcal{B}=[A\ C]\in\mathbb{R}^{n\times2n},\qquad k=\operatorname{rank}(\mathcal{B})=\dim(R(A)+R(C))<n. \tag*{(37)}

The boundary condition AΦ(a)+CΦ(c)=γA\Phi(a)+C\Phi(c)=\gamma is consistent only if

γ∈R(B)=R(A)+R(C).(38)\gamma\in R(\mathcal{B})=R(A)+R(C). \tag*{(38)}

Equivalently, if Q0∈Rn×(n−k)Q_0\in\mathbb{R}^{n\times(n-k)} is an orthonormal basis of R(B)⊥R(\mathcal{B})^\perp, then

Q0Tγ=0.(39)Q_0^T\gamma=0. \tag*{(39)}

Let Q1∈Rn×kQ_1\in\mathbb{R}^{n\times k} be an orthonormal basis of R(B)R(\mathcal{B}). Then the effective boundary conditions are precisely

Q1TAΦ(a)+Q1TCΦ(c)=Q1Tγ.(40)Q_1^TA\Phi(a)+Q_1^TC\Phi(c)=Q_1^T\gamma. \tag*{(40)}

The missing n−kn-k boundary constraints may be supplied by an artificial completion. Choose matrices Ea,Ec∈R(n−k)×nE_a,E_c\in\mathbb{R}^{(n-k)\times n} such that

B‾:=[Q1TAQ1TCEaEc]∈Rn×2n(41)\overline{\mathcal{B}}:=\begin{bmatrix}Q_1^TA & Q_1^TC\\ E_a & E_c\end{bmatrix}\in\mathbb{R}^{n\times2n} \tag*{(41)}

has rank nn. Define

A‾=[Q1TAEa],C‾=[Q1TCEc],γ‾(η)=[Q1Tγη],η∈Rn−k.(42)\overline{A}=\begin{bmatrix}Q_1^TA\\ E_a\end{bmatrix},\qquad\overline{C}=\begin{bmatrix}Q_1^TC\\ E_c\end{bmatrix},\qquad\overline{\gamma}(\eta)=\begin{bmatrix}Q_1^T\gamma\\ \eta\end{bmatrix},\qquad\eta\in\mathbb{R}^{n-k}. \tag*{(42)}

Then R(A‾)+R(C‾)=RnR(\overline{A})+R(\overline{C})=\mathbb{R}^{n}, and for each fixed artificial boundary datum η\eta, the completed boundary condition

A‾Φ(a)+C‾Φ(c)=γ‾(η)(43)\overline{A}\Phi(a)+\overline{C}\Phi(c)=\overline{\gamma}(\eta) \tag*{(43)}

falls into the full-rank framework of the previous subsection.

Theorem 2.11 (boundary completion for rank-deficient boundary conditions). Assume rank⁡[A C]=k<n\operatorname{rank}[A\ C]=k<n and γ∈R(A)+R(C)\gamma\in R(A)+R(C). Let Q1,Q0Q_1,Q_0 and (Aˉ,Cˉ,γˉ(η))(\bar{A},\bar{C},\bar{\gamma}(\eta)) be defined as above, with rank⁡Bˉ=n\operatorname{rank}\bar{B}=n. Then a function Φ\Phi satisfies the original boundary condition

AΦ(a)+CΦ(c)=γ(44)A\Phi(a)+C\Phi(c)=\gamma \tag*{(44)}

if and only if there exists an artificial datum η∈Rn−k\eta\in\mathbb{R}^{n-k} such that

AˉΦ(a)+CˉΦ(c)=γˉ(η).(45)\bar{A}\Phi(a)+\bar{C}\Phi(c)=\bar{\gamma}(\eta). \tag*{(45)}

Consequently, if SS denotes the solution set of the original boundary value problem and SηS_\eta denotes the solution set of the completed problem with artificial datum η\eta, then

S=⋃η∈Rn−kSη.(46)S=\bigcup_{\eta\in\mathbb{R}^{n-k}}S_\eta. \tag*{(46)}

In particular, choosing one value of η\eta selects one representative problem from the family, while varying η\eta parametrizes the boundary degrees of freedom left unspecified by the original rank-deficient boundary condition.

Corollary 2.12 (multiple right-hand sides for the completed problem). Consider the linear boundary value problem

Φ′(x)+p(x)Φ(x)=f(x),AΦ(a)+CΦ(c)=γ,(47)\Phi'(x)+p(x)\Phi(x)=f(x),\qquad A\Phi(a)+C\Phi(c)=\gamma, \tag*{(47)}

and assume that the compatibility condition (38) holds. Let r=n−kr=n-k be the number of missing boundary conditions and assume that, for the completed boundary condition (Aˉ,Cˉ)(\bar{A},\bar{C}), the completed BVP is uniquely solvable for each artificial datum η∈Rr\eta\in\mathbb{R}^{r}. Let Φ0\Phi_0 solve

Φ0′(x)+p(x)Φ0(x)=f(x),AˉΦ0(a)+CˉΦ0(c)=[Q1Tγ0],(48)\Phi'_0(x)+p(x)\Phi_0(x)=f(x),\qquad\bar{A}\Phi_0(a)+\bar{C}\Phi_0(c)=\begin{bmatrix}Q_1^T\gamma\\0\end{bmatrix}, \tag*{(48)}

and, for j=1,…,rj=1,\ldots,r, let Φj\Phi_j solve

Φj′(x)+p(x)Φj(x)=0,AˉΦj(a)+CˉΦj(c)=[0ej],(49)\Phi'_j(x)+p(x)\Phi_j(x)=0,\qquad\bar{A}\Phi_j(a)+\bar{C}\Phi_j(c)=\begin{bmatrix}0\\e_j\end{bmatrix}, \tag*{(49)}

where {ej}j=1r\{e_j\}_{j=1}^r is the standard basis of Rr\mathbb{R}^r. Then the solution family of the original rank-deficient boundary condition is

Φη(x)=Φ0(x)+∑j=1rηjΦj(x),η=(η1,…,ηr)T∈Rr.(50)\Phi_\eta(x)=\Phi_0(x)+\sum_{j=1}^{r}\eta_j\Phi_j(x),\qquad\eta=(\eta_1,\ldots,\eta_r)^T\in\mathbb{R}^r. \tag*{(50)}

Equivalently, after one fast direct factorization for the completed boundary condition, the whole family is obtained by applying the solver to r+1r+1 right-hand sides.

The multiple-right-hand-side form is not only a convenient mathematical description; it is also the fast version of the algorithm. The direct solver constructs an operator-dependent compressed representation on the adaptive tree. This representation depends on the coefficient matrix and on the completed boundary condition, but not on the particular boundary-data right-hand side. Thus the particular solve and the auxiliary homogeneous solves in Corollary 2.12 can share the same factorized operator. The additional right-hand sides are applied as a standard multiple-right-hand-side direct solve, so the dominant factorization cost is paid once and the marginal cost of the missing-boundary-data basis functions is small. The implementation of this multiple-right-hand-side solve inside the fast algorithm is described in § 2.5.

Remark 2.13. The artificial rows (Ea,Ec)(E_a,E_c) are not unique. A stable default is obtained by an SVD row completion. Let

Beff=[Q1TAQ1TC]∈Rk×2n(51)B_{\mathrm{eff}}=\begin{bmatrix}Q_1^{T}A & Q_1^{T}C\end{bmatrix}\in\mathbb{R}^{k\times2n} \tag*{(51)}

and compute an orthonormal basis W∈R2n×(2n−k)W\in\mathbb{R}^{2n\times(2n-k)} for the orthogonal complement of the row space of BeffB_{\mathrm{eff}}. Choose r=n−kr=n-k rows from WTW^{T} to form E∈Rr×2nE\in\mathbb{R}^{r\times2n}, preferably so that Bˉ\bar{B} is well conditioned, and split E=[Ea Ec]E=[E_a\ E_c]. This guarantees full boundary rank, although the completed BVP conditioning still depends on the differential equation through AˉΓ(a)+CˉΓ(c)\bar{A}\Gamma(a)+\bar{C}\Gamma(c). The completed problem may still have det⁡(Aˉ+Cˉ)=0\det(\bar{A}+\bar{C})=0, but it satisfies R(Aˉ)+R(Cˉ)=RnR(\bar{A})+R(\bar{C})=\mathbb{R}^{n} and can therefore be handled by Theorem 2.7.

Remark 2.14 (nonlinear rank-deficient boundary conditions). For each fixed artificial datum η\eta, the completed boundary condition defines an ordinary full-rank nonlinear BVP, and the Newton–fast-solver machinery described below applies without change. The present implementation solves a selected completed representative, by default the case η=0\eta=0, and reports the rank defect. At any fixed nonlinear iterate, however, the linearized correction problem is a linear BVP, so the affine correction space associated with the missing boundary data can be computed by the same multiple-right-hand-side machinery as in Corollary 2.12. Exploiting these affine linearized spaces to trace or parameterize the full nonlinear solution manifold is a natural subject for subsequent bifurcation and branch-following work, but is not part of the solver interface studied in this paper.

The previous cases can be summarized as a single preprocessing stage for boundary conditions.

Reduction of inhomogeneous boundary data

After the preprocessing steps above, including completion and the optional transformation TT, the boundary condition has the form

AΦ(a)+CΦ(c)=γ,det⁡(A+C)≠0.(52)A\Phi(a)+C\Phi(c)=\gamma,\qquad\det(A+C)\ne0. \tag*{(52)}

The inhomogeneous boundary data can then be removed exactly as in the original Starr–Rokhlin formulation. Set

Φb=(A+C)−1γ.(53)\Phi_b=(A+C)^{-1}\gamma. \tag*{(53)}

Then AΦb+CΦb=γA\Phi_b+C\Phi_b=\gamma, and writing Φ=Φ~+Φb\Phi=\widetilde{\Phi}+\Phi_b reduces the boundary condition to

AΦ~(a)+CΦ~(c)=0.(54)A\widetilde{\Phi}(a)+C\widetilde{\Phi}(c)=0. \tag*{(54)}

For a linear equation Φ′+p(x)Φ=f(x)\Phi'+p(x)\Phi=f(x), this only changes the right-hand side to

f~(x)=f(x)−p(x)Φb.(55)\widetilde{f}(x)=f(x)-p(x)\Phi_b. \tag*{(55)}

For a nonlinear equation Φ′=F(Φ,x)\Phi'=F(\Phi,x), one obtains the homogeneous-boundary problem

Φ~′=F(Φ~+Φb,x),AΦ~(a)+CΦ~(c)=0.(56)\widetilde{\Phi}'=F(\widetilde{\Phi}+\Phi_b,x),\qquad A\widetilde{\Phi}(a)+C\widetilde{\Phi}(c)=0. \tag*{(56)}

Algorithm 2.2 Unified boundary-condition preprocessing

Require: Boundary matrices A,C∈Rn×nA,C \in\mathbb{R}^{n \times n} and boundary data γ∈Rn\gamma\in\mathbb{R}^{n}.

Ensure: A family of full-rank completed boundary conditions and, when needed, an admissible transform for the simplest background Green’s function.

  1. Form B=[A C]B=[A\ C] and compute k=rank⁡(B)k=\operatorname{rank}(B).

  2. if k<nk<n then

    1. Compute orthonormal bases Q1Q_1 of R(B)R(B) and Q0Q_0 of R(B)⊥R(B)^\perp.

    2. Check compatibility: if Q0Tγ≠0Q_0^T\gamma\ne0, report that the boundary condition is inconsistent.

    3. Set Beff←[Q1TA Q1TC]B_{\mathrm{eff}} \leftarrow[Q_1^T A\ Q_1^T C] and compute an SVD basis WW for Row⁡(Beff)⊥⊂R2n\operatorname{Row}(B_{\mathrm{eff}})^\perp\subset\mathbb{R}^{2n}.

    4. Choose r=n−kr=n-k rows from WTW^T to form E=[Ea Ec]E=[E_a\ E_c], preferably minimizing the condition number of Bˉ\bar{B}.

    5. Set (A,C,γ)←(Aˉ,Cˉ,γˉ(η))(A,C,\gamma) \leftarrow(\bar{A},\bar{C},\bar{\gamma}(\eta)) with artificial datum η∈Rn−k\eta\in\mathbb{R}^{n-k}.

    6. end if

  3. if det⁡(A+C)≠0\det(A+C)\ne0 then

    1. Use the simplest background Green’s function directly.

    2. else

    3. Apply Algorithm 2.1 to construct TT with det⁡(AT(a)+CT(c))≠0\det(AT(a)+CT(c))\ne0.

    4. Transform the equation and boundary condition by (15)–(16).

    5. end if

Nonlinear equations

We now turn to the nonlinear TPBVP in (1). In view of Section 2.5, it suffices to state the homogeneous-boundary case. A similar integral equation can then be established.

Corollary 2.15. Assume that the fixed linear boundary conditions have been preprocessed as above and that the inhomogeneous boundary data have been lifted out, so that the simplest background Green’s function G‾0\overline{G}_0 in (11) is available. If FF is smooth, then Φ\Phi solves the nonlinear equation

Φ′(x)=F(Φ(x),x),A⋅Φ(a)+C⋅Φ(c)=0,(57)\begin{aligned} \Phi'(x) &= F(\Phi(x),x),\\ A \cdot\Phi(a) + C \cdot\Phi(c) &= 0, \tag*{(57)} \end{aligned}

if and only if

Φ(x)=∫acG‾0(x,t)σ(t) dt,(58)\Phi(x)=\int_a^c \overline{G}_0(x,t)\sigma(t)\,\mathrm{d}t, \tag*{(58)}

where σ\sigma is the solution of the integral equation

σ(x)=F(∫acG‾0(x,t)σ(t) dt,x).(59)\sigma(x)=F\left(\int_a^c \overline{G}_0(x,t)\sigma(t)\,\mathrm{d}t,x\right). \tag*{(59)}

The important point is that the unknown density σ\sigma satisfies a nonlinear second-kind equation: identity plus a compact nonlinear operator. This is the formulation on which Newton iteration, continuation, and adaptivity are built.

Fast linear solver and high-order discretization

Every Newton correction and every continuation correction in this paper reduces to a linear second-kind integral equation of the form

ξ(x)+q(x)∫acG0(x,t)ξ(t) dt=r(x),(60)\xi(x)+q(x)\int_a^c G_0(x,t)\xi(t)\,\mathrm{d}t=r(x), \tag*{(60)}

where qq is either the coefficient of a linear problem or the Jacobian of the nonlinear right-hand side along the current iterate. We solve (60) by the fast direct solver of Starr and Rokhlin for systems of two-point boundary value problems [11], together with the adaptive high-order discretization philosophy of Lee and Greengard [8]. We summarize the parts of the construction needed for the present nonlinear solver.

Let

P[ξ](x)=ξ(x)+q(x)∫acG0(x,t)ξ(t) dt.(61)P[\xi](x) = \xi(x) + q(x) \int_a^c G_0(x,t)\xi(t)\,\mathrm{d}t. \tag*{(61)}

Away from the diagonal the Green’s function can be written in rank-nn factorized form G0(x,t)=γl(x)γr(t)TG_0(x,t) = \gamma_l(x)\gamma_r(t)^{\mathsf T}. Hence, if the interval is split into two adjacent subintervals, the off-diagonal restrictions of PP have rank at most nn, while the two diagonal restrictions are again integral operators of the same type on the child intervals. Thus the matrix obtained after discretization has a hierarchically off-diagonal low-rank structure, which can be exploited directly at the operator level.

Consider first a single interval bisected into two halves. A block elimination of the resulting integral equation, together with the Sherman–Morrison–Woodbury formula for its rank-nn off-diagonal blocks, shows that the problem decouples: the unknown on each half satisfies a local integral equation of exactly the same form as (60), and the two local solutions are then joined through a small set of coupling coefficients. The global solve on the interval therefore reduces to two independent problems of the same type, at half the size.

Applying this reduction recursively yields the fast algorithm. Let the interval [a,c][a,c] be partitioned into NN subintervals, obtained for simplicity by recursive bisection, so that they are the leaves of a binary tree. On each leaf the local integral equation is solved independently. The coupling coefficients obey parent–child recursion relations: they are obtained by computing a few inner products of the local solutions at the leaves, followed by one upward and one downward sweep over the tree, after which the density is recovered on every leaf from its local solution and its coefficients. Concrete formulas are given in [11].

The same recursions extend to multiple right-hand sides. In the local solve stage the factorization of each leaf matrix is shared and simply applied to every right-hand side, so the dominant cost is unchanged; in the coefficient-passing stage the coupling vectors are augmented to matrices whose extra columns carry the right-hand sides and are advanced by the same parent–child relations. This gives a fast direct solver for multiple right-hand sides at minimal extra cost—precisely what the completion of § 2.3 requires.

We now describe the discretization of the local problems in this hierarchy. It is high order and naturally compatible with adaptivity. On each leaf interval we use a pp-point Chebyshev representation and a Nyström discretization based on Clenshaw–Curtis quadrature. Enforcing the local integral equation at the pp Chebyshev nodes and applying the Clenshaw–Curtis rule to the integral term yields the local dense system

(Inp+KI)ξI=rI,KI∈Rnp×np,(62)\left(I_{np} + K_I\right)\xi_I = r_I,\qquad K_I \in\mathbb{R}^{np\times np}, \tag*{(62)}

where KIK_I is the quadrature approximation of the Green’s-function operator on II. For fixed nn and pp, both the data stored per tree node and the cost of combining two children are bounded independently of the number of active nodes; consequently the total work scales as O(Nn3p)O(Nn^3p) and storage as O(Nn2p)O(Nn^2p) for NN discretization nodes.

Increasing pp gives arbitrary order accuracy for smooth data, and the adaptive strategy of § 5 changes NN by refining only the intervals where the local error indicator is large.

Finally, the dominant cost is the solution of the local equations at the leaves, and these equations are decoupled. After a refinement or coarsening step only the modified leaves require new local solves, while the rest of the tree is reused unchanged; adaptivity is therefore naturally inexpensive.

Newton’s iteration

Assume that F:Rn×[a,c]→RnF : \mathbb{R}^{n} \times[a,c] \to\mathbb{R}^{n} is continuously differentiable with respect to its first argument. After the boundary preprocessing and the reduction to homogeneous boundary conditions, the nonlinear BVP is written in density form as

N(σ)(x):=σ(x)−F((Kσ)(x),x)=0,(Kσ)(x)=∫acG0(x,t)σ(t) dt.(63)\mathcal{N}(\sigma)(x) := \sigma(x) - F((K\sigma)(x),x) = 0, \qquad(K\sigma)(x) = \int_{a}^{c} G_{0}(x,t)\sigma(t)\,\mathrm{d}t. \tag*{(63)}

The associated solution is Φ=Kσ\Phi= K\sigma. The Fréchet derivative of N\mathcal{N} at σi\sigma_i is

DN(σi)ξ=ξ(x)−D1F(Φi(x),x)(Kξ)(x),Φi=Kσi.(64)D\mathcal{N}(\sigma_i)\xi= \xi(x) - D_1F(\Phi_i(x),x)(K\xi)(x), \qquad\Phi_i = K\sigma_i. \tag*{(64)}

Thus Newton’s method computes the density correction ξi\xi_i from

ξi(x)−D1F(Φi(x),x)∫acG0(x,t)ξi(t) dt=F(Φi(x),x)−σi(x),(65)\xi_i(x) - D_1F(\Phi_i(x),x)\int_{a}^{c}G_0(x,t)\xi_i(t)\,\mathrm{d}t = F(\Phi_i(x),x) - \sigma_i(x), \tag*{(65)}

and updates

σi+1=σi+ξi,Φi+1=Kσi+1.(66)\sigma_{i+1} = \sigma_i + \xi_i, \qquad\Phi_{i+1} = K\sigma_{i+1}. \tag*{(66)}

Equation (65) is again a linear second-kind integral equation of the form (60), with q(x)=−D1F(Φi(x),x)q(x) = -D_1F(\Phi_i(x),x), where D1FD_1F denotes the Jacobian of FF with respect to its first argument. It is solved by the fast direct solver of § 2.5.

Equivalently, with δΦi=Kξi\delta\Phi_i = K\xi_i, equation (65) is the Newton correction for the differential residual,

δΦi′(x)−D1F(Φi(x),x)δΦi(x)=−Φi′(x)+F(Φi(x),x),AδΦi(a)+CδΦi(c)=0.(67)\delta\Phi_i'(x) - D_1F(\Phi_i(x),x)\delta\Phi_i(x) = -\Phi_i'(x) + F(\Phi_i(x),x), \qquad A\delta\Phi_i(a) + C\delta\Phi_i(c) = 0. \tag*{(67)}

The numerical method nonetheless solves the density equation (65): on each leaf it is discretized by the same local system (62), now with q=−D1F(Φi(⋅),⋅)q = -D_1F(\Phi_i(\cdot),\cdot), rather than by discretizing the differential operator (67) directly.

The standard Newton–Kantorovich theory applies to (63); see, for example, [2, 7, 5]. In particular, if σ~\widetilde{\sigma} is a solution, DN(σ~)D\mathcal{N}(\widetilde{\sigma}) is invertible, and the initial density σ0\sigma_0 is sufficiently close to σ~\widetilde{\sigma}, then the iterates remain in a neighborhood of σ~\widetilde{\sigma} and converge quadratically. In practice, this local nature of Newton’s method motivates the continuation strategy described in the next section.

Continuation strategy

Newton’s method is a local method: its fast convergence is obtained once the iterate lies in the basin of attraction of the desired solution. We therefore use continuation as a practical outer strategy: a difficult target problem is reached through a sequence of easier nearby BVPs, and the solution from one stage supplies the initial guess for the next. Let

N(σ)=0(68)\mathcal{N}(\sigma) = 0 \tag*{(68)}

denote the target nonlinear integral equation. A user-specified homotopy is a family of nonlinear equations

H(σ,s)=0,0≤s≤1,(69)\mathcal{H}(\sigma,s)=0,\qquad0\le s\le1, \tag*{(69)}

such that the problem at s=0s=0 is easy to solve and

H(σ,1)=N(σ).(70)\mathcal{H}(\sigma,1)=\mathcal{N}(\sigma). \tag*{(70)}

Typical choices include continuation in a physical parameter, continuation in boundary data, continuation in the forcing term, or continuation in the strength of the nonlinear term.

Strategy for adaptivity

The local mathematical justification is the standard implicit function theorem; see, e.g., [2, 1]. If there exists a smooth solution path σ(s)\sigma(s) and the linearized operator DσH(σ(s),s)D_{\sigma}\mathcal{H}(\sigma(s),s) is invertible along the path, then the solution can be continued locally in ss. At each step, a predictor provides an initial guess at the next parameter value and Newton’s method is used as a corrector. Each Newton correction has the same second-kind integral form as (65) and is solved by the fast adaptive direct linear solver described in § 2.5.

For boundary value problems, continuation often creates or reveals multiscale structure: as ss varies, boundary layers, transition layers, and oscillatory regimes may appear even when the starting problem is benign [2, 1]. In collocation or finite-difference methods this couples the continuation step size strongly to mesh adaptation. In the integral formulation every correction equation remains a second-kind equation and the adaptive tree refines and coarsens only where necessary, so the mesh tracks the evolving solution without accumulating refinement; the mechanism is described in § 5.

In the implementation used for the numerical examples, the continuation schedule is supplied by the user. If 0=s0<s1<⋯<sm=10=s_0<s_1<\cdots<s_m=1, then the solution at sjs_j is used as the initial guess for Newton iteration at sj+1s_{j+1}. A simple version of the procedure is given in Algorithm 5.1.

Algorithm 5.1 User-specified continuation with Newton correction

Require: Homotopy H(σ,s)\mathcal{H}(\sigma,s), parameter values 0=s0<s1<⋯<sm=10=s_0<s_1<\cdots<s_m=1, initial solution σ0\sigma_0 at s0s_0.

  1. for j=0,1,…,m−1j=0,1,\ldots,m-1 do

  2. Set the initial guess at sj+1s_{j+1} to be the solution at sjs_j.

  3. repeat

  4. Form the Newton correction equation for H(σ,sj+1)=0\mathcal{H}(\sigma,s_{j+1})=0.

  5. Solve the resulting linear second-kind integral equation by the fast adaptive solver.

  6. Update the density and the corresponding solution.

  7. until the nonlinear residual or Newton correction is below tolerance

  8. end for

  9. return the solution at sm=1s_m=1.

The fast adaptive integral-equation solver described here is the computational kernel that carries out the Newton and continuation corrections. Its well-conditioned formulation, linear complexity, arbitrary order accuracy, and automatic adaptivity are properties of the integral-equation substrate, and they are inherited without change by any outer continuation or bifurcation algorithm built on top of it: pseudo-arclength continuation, fold detection, nullspace computation, and branch switching add outer control logic without altering the kernel or its cost. The kernel and the outer continuation framework therefore operate at distinct levels, making the present contribution orthogonal to, and directly compatible with, techniques such as those in AUTO.

Strategy for adaptivity

The adaptive strategy follows the philosophy of Lee and Greengard [8] but is extended to the nonlinear case: local polynomial representations are inspected a posteriori, and the interval tree is refined or coarsened until local solutions on all leaf intervals are resolved. On each leaf interval II, each component of the density or solution is represented in a Chebyshev basis of order pp,

uj(x)∣I≈∑m=0p−1aj,mITm(x),j=1,…,n.(71)u_j(x)|_I \approx\sum_{m=0}^{p-1} a_{j,m}^I T_m(x), \qquad j=1,\ldots,n. \tag*{(71)}

For smooth functions, the decay of the Chebyshev coefficients provides a sharp and inexpensive resolution indicator; see, for example, the approximation theory viewpoint in [12]. In the implementation we use the Lee–Greengard tail quantity componentwise. If

uj(x)∣I≈∑m=0p−1aj,mITm(x),(72)u_j(x)|_I \approx\sum_{m=0}^{p-1} a_{j,m}^I T_m(x), \tag*{(72)}

then the monitor for component jj on interval II is

SI(j)=∣aj,p−2I∣+∣aj,p−1I−aj,p−3I∣.(73)S_I^{(j)} = \left|a_{j,p-2}^I\right| + \left|a_{j,p-1}^I-a_{j,p-3}^I\right|. \tag*{(73)}

For systems, refinement is triggered if any component exceeds its threshold, and coarsening is accepted when all component monitors are small. The tail monitor is more than a refinement heuristic: the following theorem shows that resolvedness of the density implies accuracy.

Theorem 6.1 (resolvedness implies accuracy, after [8]). Represent the density on each leaf II by a Chebyshev expansion of order pp with coefficients amIa_m^I, and suppose that, for every leaf II,

∣ap−2I∣≤ε2∥f~∥,∣ap−1I∣≤ε2∥f~∥,∥f−f~∥<ε∥f~∥.(74)\left|a_{p-2}^I\right| \leq\frac{\varepsilon}{2}\|\widetilde{f}\|,\qquad\left|a_{p-1}^I\right| \leq\frac{\varepsilon}{2}\|\widetilde{f}\|,\qquad\|f-\widetilde{f}\| < \varepsilon\|\widetilde{f}\|. \tag*{(74)}

Then the computed density σ^\widehat{\sigma} satisfies the relative error bound

∥σ−σ^∥∥σ∥≤κ(P)(∥P−P^∥+1)ε,(75)\frac{\|\sigma-\widehat{\sigma}\|}{\|\sigma\|} \leq\kappa(P)\left(\|P-\widehat{P}\|+1\right)\varepsilon, \tag*{(75)}

where κ(P)\kappa(P) is the condition number of the integral operator PP.

Remark 6.2. Theorem 6.1 shows that local resolvedness is a sufficient condition for accuracy, so the tail monitor of (73) inherits the same status. The estimate uses the fact that PP is a compact perturbation of the identity; it is not readily available when the differential operator is discretized directly, because that operator is unbounded. The same perturbation argument applies componentwise to systems and yields the analogous bound.

Numerical results

For linear problems, this is the direct system analogue of the Lee–Greengard adaptivity criterion. One could in principle maintain separate trees for different components of the vector solution, but this only changes the number of discretization points by a constant factor. For simplicity, we use a single tree and require all components to be resolved on every leaf. If one of the component monitors is too large, the interval is bisected. Coarsening is applied by merging sibling leaves when the merged representation is also resolved by the same tail criterion. The result may retain a small amount of over-refinement, but it avoids oscillatory refine–coarsen behavior and has been robust in the examples.

For nonlinear problems, adaptivity is inherited from the linear correction solver but is applied to the nonlinear state. At each Newton step, and at each continuation parameter value, the terminal mesh of the previous solve is used as the initial mesh for the next correction equation. Since the Newton update is σnew=σold+δσ\sigma_{\mathrm{new}} = \sigma_{\mathrm{old}} + \delta\sigma, the quantity that must be resolved is the updated density σnew\sigma_{\mathrm{new}}, not the correction alone. The monitors are therefore computed from σnew\sigma_{\mathrm{new}} using the same componentwise Lee–Greengard tail criterion, and refinement and coarsening are applied by the two-sided rule above. The outer adaptivity control stops when two consecutive resolved approximations agree in the mixed relative norm

ϱ=∥uprev−u∥2∥uprev+u∥2,(76)\varrho= \frac{\lVert u_{\mathrm{prev}}-u\rVert_2}{\lVert u_{\mathrm{prev}}+u\rVert_2}, \tag*{(76)}

with a fallback to ∥uprev−u∥2\lVert u_{\mathrm{prev}}-u\rVert_2 when the denominator is small. In contrast with the final mesh-doubling check used in some purely linear adaptive solvers, the nonlinear correction solve does not automatically double the terminal mesh after local convergence, which would propagate unnecessary refinement through Newton and continuation steps. Instead, the local Chebyshev tail monitors drive the mesh as the nonlinear iteration proceeds.

The resulting strategy is automatic: no a priori information is supplied by the user. The mesh is concentrated in physically active regions and remains coarse where the solution is smooth or nearly constant. A schematic version is given in Algorithm 6.1.

Algorithm 6.1 Adaptive refinement by Chebyshev tail estimates

Require: Current interval tree, Chebyshev order pp, tolerance ε\varepsilon.

  1. repeat

  2. Solve the current correction equation on the active tree.

  3. Form the quantity to be resolved: the density for a linear problem, or σnew=σold+δσ\sigma_{\mathrm{new}} = \sigma_{\mathrm{old}} + \delta\sigma for a nonlinear correction.

  4. for all leaf intervals II do

  5. Compute Chebyshev coefficients and component monitors SI(j)S_I^{(j)} from (73).

  6. if any component monitor exceeds its threshold then

  7. Mark II for bisection.

  8. end if

  9. end for

  10. Bisect all marked leaves and update the tree data.

  11. Merge sibling leaves whose combined representation is resolved by the same criterion.

  12. until the mixed relative change (76) is below ε\varepsilon and no leaf is marked for refinement

Numerical results

We now illustrate the performance of the method on a sequence of examples designed to test different aspects of the solver: adaptive resolution of boundary layers, robustness on long intervals, continuation through multiple solution branches, and singularly perturbed nonlinear behavior. Unless otherwise stated, the discretization order is fixed and the adaptive tree is generated automatically.

Shock-wave boundary layer and adaptive fast scaling

The first example is the viscous shock-wave problem used by Lee and Greengard [8] to illustrate adaptive refinement for a stiff scalar BVP,

ϵu′′(x)+2xu′(x)=0,−1≤x≤1,u(−1)=−1,u(1)=1,(77)\epsilon u''(x) + 2x u'(x) = 0,\qquad-1 \le x \le1,\qquad u(-1)=-1,\qquad u(1)=1, \tag*{(77)}

with ϵ=10−5\epsilon= 10^{-5}. The exact solution is

u(x)=erf⁡(x/ϵ)erf⁡(1/ϵ).(78)u(x) = \frac{\operatorname{erf}(x/\sqrt{\epsilon})}{\operatorname{erf}(1/\sqrt{\epsilon})}. \tag*{(78)}

Introducing the usual first-order variables

ϕ1=u,ϕ2=u′,(79)\phi_1 = u,\qquad\phi_2 = u', \tag*{(79)}

we obtain the system

ϕ1′=ϕ2,ϕ2′=−2xϵϕ2,ϕ1(−1)=−1,ϕ1(1)=1.(80)\phi_1' = \phi_2,\qquad\phi_2' = -\frac{2x}{\epsilon}\phi_2,\qquad\phi_1(-1)=-1,\qquad\phi_1(1)=1. \tag*{(80)}

This separated Dirichlet boundary condition is a simple but important case in which the matrix A+CA+C for the simplest background Green’s function is singular. The preprocessing step constructs an admissible boundary transform automatically. For this example the transform is especially benign: sampling T(x)T(x) on the interval gives max⁡xκ2(T(x))=1\max_x \kappa_2(T(x))=1 in our diagnostic, so the preprocessing removes the artificial singularity of A+CA+C without degrading the conditioning of the problem.

We first test the fixed-mesh direct solver. Starting from the two intervals [−1,0][-1,0] and [0,1][0,1], we manually bisect the two intervals adjacent to the layer at x=0x=0 and feed the resulting boundary-layer mesh to the nonadaptive system solver. The number of bisections ranges from 3 to 7. Table 7.1 reports the total number of discretization nodes NN, the total time T(N)T(N), the fraction of time spent in the local leaf solves, and the maximum error against the exact solution.

bisectionsintervalsNNT(N)T(N) (s)local fractionmax error
381280.0134660.4891.64×1021.64 \times10^{2}
4101600.0133450.5982.43×1012.43 \times10^{1}
5121920.0155010.6135.14×10−15.14 \times10^{-1}
6142240.0165770.6743.76×10−33.76 \times10^{-3}
7162560.0181320.6991.78×10−61.78 \times10^{-6}

Table 7.1. Fixed-mesh nonadaptive shock-wave solves. The local fraction is included explicitly because this stage is the dominant cost as the mesh is refined.

Figure 7.1 plots T(N)T(N) against NN. The measured time is approximately linear over this range, as expected for the direct solver with fixed system size and fixed Chebyshev order.

Figure 7.1. Fixed-mesh shock-wave solve time versus the number of discretization nodes. The dashed curve is a least-squares linear fit through the origin.

We next test the adaptive solver. Starting from only the two initial intervals [−1,0][-1,0] and [0,1][0,1], the adaptive run produces a final mesh with 28 intervals and maximum error 1.32×10−101.32 \times10^{-10}. The adaptive run takes 6.25×10−26.25 \times10^{-2} seconds. Running the nonadaptive solver once on this final adaptive mesh takes 2.78×10−22.78 \times10^{-2} seconds and gives the same error. Thus the ratio between the fully adaptive calculation and the direct solve on the final mesh is approximately

TadaptiveTfinal mesh≈2.29.(81)\frac{T_{\mathrm{adaptive}}}{T_{\mathrm{final\ mesh}}} \approx2.29. \tag*{(81)}

This is the expected behavior for an efficient adaptive strategy: the code finds the resolving mesh automatically at a cost only a small constant factor larger than a single solve on the final mesh, while requiring no a priori knowledge of the layer width.

A truly degenerate boundary condition

The next example isolates the completion procedure for genuinely rank-deficient boundary conditions while keeping the differential equation elementary. Consider the four-dimensional homogeneous system

u1′=u2,u2′=−u1,u3′=u4,u4′=−u3,0≤x≤1.(82)\begin{aligned} u_1' &= u_2, & u_2' &= -u_1, \\ u_3' &= u_4, & u_4' &= -u_3, \qquad0 \le x \le1. \tag*{(82)} \end{aligned}

with only two independent boundary conditions,

u1(0)=0,u3(0)=1.(83)u_1(0) = 0, \qquad u_3(0) = 1. \tag*{(83)}

Thus rank⁡[A C]=2<4\operatorname{rank}[A\ C] = 2 < 4. The exact solution set is the two-parameter affine family

u1(x)=η1sin⁡x,u2(x)=η1cos⁡x,u3(x)=cos⁡x+η2sin⁡x,u4(x)=−sin⁡x+η2cos⁡x,η1,η2∈R.(84)\begin{aligned} u_1(x) &= \eta_1 \sin x, & u_2(x) &= \eta_1 \cos x, \\ u_3(x) &= \cos x + \eta_2 \sin x, & u_4(x) &= -\sin x + \eta_2 \cos x, \qquad\eta_1,\eta_2 \in\mathbb{R}. \tag*{(84)} \end{aligned}

The full-space interface first completes the boundary condition, solves the particular problem and the two auxiliary homogeneous problems using a shared multiple-right-hand-side direct solve, and returns a particular solution together with two basis functions. We compare this with a non-shared implementation which applies the completed boundary conditions and calls the single-RHS solver independently for the particular datum and the two auxiliary data. The results are shown in Table 7.2. Both approaches recover the exact affine family to roundoff accuracy, but the shared multiple-RHS version is almost five times faster for this small test.

quantityvalue
nullity of boundary condition2
fast full-space time8.88×10−3 s8.88 \times10^{-3}\ \mathrm{s}
independent single-RHS time4.22×10−2 s4.22 \times10^{-2}\ \mathrm{s}
time ratio4.76
solution-space error4.44×10−164.44 \times10^{-16}
free-component basis determinant1

Table 7.2. Truly degenerate boundary condition example. The fast full-space interface shares the direct-solver factorization across the particular and auxiliary right-hand sides.

This confirms the practical value of the completion formulation in § 2.3: the solver can automatically process a rank-deficient boundary condition, return the affine solution space in the linear case, and exploit the direct solver’s multiple-right-hand-side structure rather than solving each completed problem independently.

Nonlinear mass-spring optimal control

The third example is a nonlinear optimal-control problem for a spring-mass system. It tests two features of the solver which are absent from the preceding linear examples: the use of Newton corrections for a genuinely nonlinear system, and automatic mesh refinement for a solution with sharp endpoint transitions on long time intervals. The spring force is

Fs(x)=−x−x3,(85)F_s(x) = -x - x^3, \tag*{(85)}

where x=0x = 0 is the unstretched position, and the scalar control force is denoted by u(t)u(t). The control problem is to minimize

J=12∫0T(x2+v2+u2) dt(86)J = \frac{1}{2}\int_{0}^{T}(x^2 + v^2 + u^2)\,\mathrm{d}t \tag*{(86)}

subject to

x′=v,v′=−x−x3+u,x(0)=1,v(0)=0,x(T)=0.75,v(T)=0.(87)\begin{aligned} x' &= v,\\ v' &= -x - x^3 + u,\\ x(0) &= 1,\quad v(0) = 0,\quad x(T) = 0.75,\quad v(T) = 0. \tag*{(87)} \end{aligned}

With adjoint variables λ\lambda and μ\mu, the Hamiltonian is

H=12(x2+v2+u2)+λv+μ(−x−x3+u).(88)H = \frac{1}{2}(x^2 + v^2 + u^2) + \lambda v + \mu(-x - x^3 + u). \tag*{(88)}

Eliminating the control by the optimality condition gives the first-order BVP

{x′=v,v′=−x−x3+u,λ′=−x+μ(1+3x2),μ′=−v−λ,x(0)=1,v(0)=0,x(T)=0.75,v(T)=0.(89)\begin{cases} x' = v,\\ v' = -x - x^{3} + u,\\ \lambda' = -x + \mu(1 + 3x^{2}),\\ \mu' = -v - \lambda,\\ x(0) = 1,\quad v(0) = 0,\quad x(T) = 0.75,\quad v(T) = 0. \tag*{(89)} \end{cases}

This is the system solved by the code, with the control recovered from the optimality condition inside the right-hand side evaluation.

The solution develops rapid transitions near the endpoints while remaining nearly flat over much of a long interval. We use order p=16p = 16 and the simple initial guess x≡v≡λ≡μ≡0x \equiv v \equiv\lambda\equiv\mu\equiv0. The resulting solution and adaptive mesh are shown in Figure 7.2. For T=200T = 200, the final mesh contains 30 subintervals, with refinement concentrated near the endpoint transition regions.

Solution of the nonlinear optimal-control BVP (7.13), showing position and control with adaptive subintervals

Figure 7.2. Solution of the nonlinear optimal-control BVP (89). Green vertical lines indicate adaptive subintervals.

The same algorithm also applies on much longer time intervals. We tested intervals from [0,20][0, 20] to [0,2.0×105][0, 2.0 \times10^{5}]; mesh counts and run times are reported in Table 7.3. The mesh count grows slowly compared with the length of the interval because most of the interior remains smooth and nearly constant.

intervalmesh intervalsruntime (s)
[0, 2.0×105][0,\ 2.0 \times10^{5}]4713.87
[0, 2.0×104][0,\ 2.0 \times10^{4}]389.406
[0, 2.0×103][0,\ 2.0 \times10^{3}]366.984
[0, 2.0×102][0,\ 2.0 \times10^{2}]305.609
[0, 20][0,\ 20]153.594

Table 7.3. Mesh counts and run times for the nonlinear mass-spring optimal-control problem on increasingly long time intervals.

Since no closed-form solution is available for this optimal-control system, we use a self-convergence check for the longest interval reported in the figure, T=200T = 200. The baseline computation starts from the two-interval initial mesh. We then take the adaptive terminal mesh, manually double every final subinterval once, and rerun the solver on this refined mesh. Comparing the two solutions on the same target grid gives

∥ybase−yref∥∞=1.21×10−12.(90)\lVert y_{\mathrm{base}} - y_{\mathrm{ref}} \rVert_{\infty} = 1.21 \times10^{-12}. \tag*{(90)}

The maximum differential residual ∥y′−F(y,t)∥∞\lVert y^{\prime} - F(y,t) \rVert_{\infty} on the target grid is 4.80×10−144.80 \times10^{-14}, and the boundary residual is 4.86×10−164.86 \times10^{-16}. Thus the adaptive nonlinear solve is self-converged and satisfies the differential and boundary equations to near machine precision.

With the default merge safety factor, the mesh can retain mild over-refinement. In Figure 7.2, for instance, the solution is nearly zero on a long interior interval, yet a few subintervals remain from earlier Newton refinements. This has little effect on the total cost in the present examples, but more aggressive coarsening is a possible improvement.

Elliptic Jacobi problem

This system was used in [11] to demonstrate the effectiveness of integral equation methods for systems. We revisit it here for a different purpose: the problem has multiple solution branches, and Newton iteration can be sensitive to the initial guess and mesh resolution. It therefore provides a useful test of the continuation and adaptive components of the present solver. Jacobi elliptic functions arise in, for example, the motion of a pendulum and satisfy the system

{sn′(x)=cn(x)⋅dn(x),cn′(x)=−sn(x)⋅dn(x),dn′(x)=−m⋅sn(x)⋅cn(x),sn(0)=0,cn(0)=1,dn(L⋅K)=1.(91)\begin{cases} sn^{\prime}(x) = cn(x) \cdot dn(x),\\ cn^{\prime}(x) = -sn(x) \cdot dn(x),\\ dn^{\prime}(x) = -m \cdot sn(x) \cdot cn(x),\\ sn(0) = 0,\quad cn(0) = 1,\quad dn(L \cdot K) = 1. \tag*{(91)} \end{cases}

where m∈[0,1]m \in[0,1] is fixed to be 1/21/2 in our experiments, and K=K(m)K = K(m) is the complete elliptic integral of the first kind,

K=K(m)=∫0π2dθ1−m⋅sin⁡2θ,K = K(m) = \int_{0}^{\frac{\pi}{2}} \frac{d\theta}{\sqrt{1 - m \cdot\sin^{2}\theta}},

LL is an even number.

Following [11], one natural initial guess is obtained from the case m=0m = 0, namely sn(x)=sin⁡(2πx/(4L))sn(x) = \sin(2\pi x/(4L)), cn(x)=cos⁡(2πx/(4L))cn(x) = \cos(2\pi x/(4L)), and dn(x)=0dn(x) = 0. With this initial guess, the present method solves (91) with m=1/2m = 1/2 to about 10−1210^{-12} accuracy; see Figure 7.4(a),(b). For larger LL, Newton’s method may fail if the initial mesh is too coarse. This sensitivity is related to multiple solution branches and a complicated basin of attraction. To see the source of nonuniqueness, consider the initial value problem

Numerical solutions for (7.15), showing six numerical solution plots

Figure 7.4. (a) Fine initial guess, L=4L = 4. (b) Fine initial guess, L=40L = 40. (c) Newton method, L=4L = 4, α≈1.21\alpha\approx1.21. (d) Continuation method, L=4L = 4, α≈1.04\alpha\approx1.04. (e) First continuation scheme, L=12L = 12. (f) Second continuation scheme, L=12L = 12. Numerical solutions for (91). All solved in 10−1210^{-12} precision. (a): Solution with fine initial guess, L=4L = 4; (b): Solution with fine initial guess, L=40L = 40; (c): Solution for L=4L = 4 without continuation, α≈1.21\alpha\approx1.21; (d): Solution for L=4L = 4 under continuation method, α≈1.04\alpha\approx1.04; (e): Solution for L=12L = 12 under the first continuation scheme; (f) Solution for L=12L = 12 under the second continuation scheme.

{sn′(x)=cn(x)⋅dn(x),cn′(x)=−sn(x)⋅dn(x),dn′(x)=−m⋅sn(x)⋅cn(x),sn(0)=0,cn(0)=1,dn(0)=α(α>m)(92)\begin{cases} sn^{\prime}(x) = cn(x) \cdot dn(x),\\ cn^{\prime}(x) = -sn(x) \cdot dn(x),\\ dn^{\prime}(x) = -m \cdot sn(x) \cdot cn(x),\\ sn(0) = 0,\quad cn(0) = 1,\quad dn(0) = \alpha\quad(\alpha> \sqrt{m}) \tag*{(92)} \end{cases}

Its solution can be expressed as sn~(x)=sn~m~(αx)\widetilde{sn}(x)=\widetilde{sn}_{\widetilde{m}}(\alpha x), cn~(x)=cn~m~(αx)\widetilde{cn}(x)=\widetilde{cn}_{\widetilde{m}}(\alpha x), and dn~(x)=αdn~m~(αx)\widetilde{dn}(x)=\alpha\widetilde{dn}_{\widetilde{m}}(\alpha x), with m~=m/α2\widetilde{m}=m/\alpha^2. Such a solution also satisfies the boundary value problem precisely when the boundary condition on dndn is met. Numerically, additional solutions appear as LL grows; see Figure 7.3.

Plots showing multiple solutions for L=4 and L=12

Figure 7.3. The plot has dn(0)dn(0) on the horizontal axis and dn(1)dn(1) on the vertical axis. A solution to the boundary value problem corresponds to a point where dn(1)=1dn(1)=1. Solutions for L=4L=4 and L=12L=12 are displayed in the figure.

We use continuation both to reduce the dependence on the initial guess and to probe different solution branches. In the experiments below, p=16p=16 and m=1/2m=1/2. For L=4L=4, the direct Newton iteration, the continuation method, and the trigonometric initial guess converge to different solutions, as shown in Figure 7.4(a),(c),(d). We do not attempt an exhaustive enumeration of all branches; the point is that different initial guesses and continuation paths can lie in different basins of attraction and therefore lead to distinct solutions, while the adaptive integral-equation solver can still resolve the resulting branches to high accuracy. This example illustrates why a reliable fast solver for the linearized correction equations is a useful computational foundation for subsequent bifurcation and branch-following calculations.

For L>4L>4, the trivial initial guess does not converge without continuation. To obtain solutions for L=12L=12, we tested two continuation schemes:

  • In the first approach, mm is continued from an initial value of 0 to 0.5 while holding KK fixed at K=K(12)K=K(\frac{1}{2});

  • In the second approach, the same continuation on mm is performed with KK varying, K=K(m)K=K(m).

Results are shown in Figure 7.4, (e) and (f).

Troesch equation

7.5. Troesch equation. Troesch’s problem is a classical nonlinear two-point boundary value problem with a sharp right boundary layer for large positive λ\lambda:

u′′(x)=λsinh⁡(λu(x)),u(0)=0,u(1)=1,x∈[0,1].(93)u''(x)=\lambda\sinh(\lambda u(x)),\qquad u(0)=0,\qquad u(1)=1,\qquad x\in[0,1]. \tag*{(93)}

We use the first-order formulation

ϕ1′=ϕ2,ϕ2′=λsinh⁡(λϕ1),ϕ1(0)=0,ϕ1(1)=1.(94)\phi'_1=\phi_2,\qquad\phi'_2=\lambda\sinh(\lambda\phi_1),\qquad\phi_1(0)=0,\qquad\phi_1(1)=1. \tag*{(94)}

The large-parameter regime is a demanding test for nonlinear BVP solvers. The regular solution develops an increasingly thin layer near x=1x=1, and direct use of standard collocation solvers such as MATLAB’s bvp4c with simple initial guesses is not reliable in this regime. Large-parameter Troesch computations are therefore often treated with carefully designed continuation, mesh selection, or problem-specific techniques; see, for example, [4, 13, 14].

Troesch equation

For this problem an analytic representation in terms of elliptic functions is available and can be evaluated to high precision. Let s=u∗′(0)>0s = u_*'(0) > 0, a=s/2a = s/2, and m=1−a2m = 1 - a^2. The first integral is

u∗′(x)2=s2+4sinh⁡2(λu∗(x)2).(95)u_*'(x)^2 = s^2 + 4\sinh^2\left(\frac{\lambda u_*(x)}{2}\right). \tag*{(95)}

The regular branch is given by

u∗(x)=2λarsinh⁡[a sc⁡(λx∣m)],u∗′(x)=scn⁡(λx∣m),(96)u_*(x) = \frac{2}{\lambda}\operatorname{arsinh}\left[a\,\operatorname{sc}(\lambda x \mid m)\right], \qquad u_*'(x) = \frac{s}{\operatorname{cn}(\lambda x \mid m)}, \tag*{(96)}

where sc⁡=sn⁡/cn⁡\operatorname{sc} = \operatorname{sn}/\operatorname{cn} and mm is the elliptic parameter. The boundary condition u∗(1)=1u_*(1) = 1 determines aa through

F(arctan⁡sinh⁡(λ/2)a∣1−a2)=λ,(97)F\left(\arctan\frac{\sinh(\lambda/2)}{a} \mathrel{\Big|} 1-a^2\right) = \lambda, \tag*{(97)}

where FF is the incomplete elliptic integral of the first kind. In the numerical comparisons below this scalar equation is solved in log⁡a\log a, and the reference solution is evaluated with mpmath using 100 decimal digits of working precision. Recomputing selected values at higher precision confirms at least 50 correct digits in the reference data.

Nonlinear Singularly Perturbed BVP

Let u^\hat{u} denote the numerical solution and u∗u_* the high-precision reference. For f=u^f = \hat{u} or u^′\hat{u}' and f∗=u∗f_* = u_* or u∗′u_*', we report

E2,rel(f)=(∫01∣f(x)−f∗(x)∣2 dx)1/2(∫01∣f∗(x)∣2 dx)1/2,E∞,mix(f)=max⁡i∣f(xi)−f∗(xi)∣1+∣f∗(xi)∣.(98)E_{2,\mathrm{rel}}(f) = \frac{\left(\int_0^1 \lvert f(x)-f_*(x)\rvert^2\,dx\right)^{1/2}}{\left(\int_0^1 \lvert f_*(x)\rvert^2\,dx\right)^{1/2}}, \qquad E_{\infty,\mathrm{mix}}(f) = \max_i \frac{\lvert f(x_i)-f_*(x_i)\rvert}{1+\lvert f_*(x_i)\rvert}. \tag*{(98)}

The maximum in the mixed norm is sampled on 10,000 equally spaced points; the term 1+∣f∗(xi)∣1+\lvert f_*(x_i)\rvert avoids an artificial blow-up where the exact solution is small. We also report the absolute derivative error at the left endpoint and the relative derivative error at the right endpoint,

E0,abs=∣vh(0)−u∗′(0)∣,E1,rel=∣vh(1)−u∗′(1)∣∣u∗′(1)∣,(99)E_{0,\mathrm{abs}} = \lvert v_h(0)-u_*'(0)\rvert, \qquad E_{1,\mathrm{rel}} = \frac{\lvert v_h(1)-u_*'(1)\rvert}{\lvert u_*'(1)\rvert}, \tag*{(99)}

where vhv_h is the second component of the computed first-order state.

We first compare direct Newton iteration at λ=20\lambda= 20 with a simple continuation path 10→2010 \to20, using tolerance 10−810^{-8} throughout. Both runs satisfy the internal Newton stopping criterion, but only the continuation run reaches the high-precision reference to nearly full accuracy; see Table 7.4.

MethodE2,rel(u)E_{2,\mathrm{rel}}(u)E2,rel(u′)E_{2,\mathrm{rel}}(u')E∞,mix(u)E_{\infty,\mathrm{mix}}(u)E∞,mix(u′)E_{\infty,\mathrm{mix}}(u')E0,absE_{0,\mathrm{abs}}E1,relE_{1,\mathrm{rel}}
Direct Newton9.69743×10−39.69743 \times10^{-3}1.22246×10−41.22246 \times10^{-4}1.35894×10−31.35894 \times10^{-3}1.03871×10−21.03871 \times10^{-2}2.94783×10−92.94783 \times10^{-9}1.85253×10−101.85253 \times10^{-10}
10→2010 \to201.31244×10−101.31244 \times10^{-10}2.04517×10−112.04517 \times10^{-11}3.79365×10−113.79365 \times10^{-11}3.01909×10−103.01909 \times10^{-10}2.38731×10−132.38731 \times10^{-13}1.24368×10−121.24368 \times10^{-12}

Table 7.4. Effect of continuation for λ=20\lambda= 20 with tolerance 10−810^{-8}. Maximum errors use the 10,000-point grid in (98); endpoint errors are defined in (99).

The direct run no longer behaves reliably when the tolerance is tightened to 10−910^{-9}, indicating convergence to a nearby numerical profile rather than to the regular branch at the requested accuracy. The continuation path supplies a more accurate initial state for the target parameter and removes this failure.

Table 7.5 reports the four tests on λ=10\lambda= 10, 2020, 3030, and 4040. We use direct Newton at λ=10\lambda= 10 and continuation on others; each sequence uses the target tolerance listed in the table at every stage.

λ\lambdaToleranceE2,rel(u)E_{2,\mathrm{rel}}(u)E2,rel(u′)E_{2,\mathrm{rel}}(u')E∞,mix(u)E_{\infty,\mathrm{mix}}(u)E∞,mix(u′)E_{\infty,\mathrm{mix}}(u')E0,absE_{0,\mathrm{abs}}E1,relE_{1,\mathrm{rel}}
1010−1210^{-12}2.92607×10−152.92607 \times10^{-15}8.32579×10−168.32579 \times10^{-16}6.00109×10−166.00109 \times10^{-16}2.13348×10−152.13348 \times10^{-15}5.93118×10−165.93118 \times10^{-16}1.51479×10−161.51479 \times10^{-16}
2010−910^{-9}4.42617×10−124.42617 \times10^{-12}2.45051×10−132.45051 \times10^{-13}3.91681×10−133.91681 \times10^{-13}1.21461×10−121.21461 \times10^{-12}2.39450×10−132.39450 \times10^{-13}1.30967×10−131.30967 \times10^{-13}
3010−510^{-5}1.65600×10−71.65600 \times10^{-7}9.95677×10−79.95677 \times10^{-7}1.04130×10−71.04130 \times10^{-7}1.98420×10−61.98420 \times10^{-6}1.00087×10−131.00087 \times10^{-13}1.01682×10−81.01682 \times10^{-8}
4010−410^{-4}5.91342×10−85.91342 \times10^{-8}2.84482×10−62.84482 \times10^{-6}3.05401×10−93.05401 \times10^{-9}7.97122×10−87.97122 \times10^{-8}1.15709×10−141.15709 \times10^{-14}2.21180×10−82.21180 \times10^{-8}

Table 7.5. Reference-solution errors for the four Troesch tests. The derivative approximation is the second physical state component vhv_h. The last two columns give the absolute derivative error at x=0x = 0 and relative derivative error at x=1x = 1.

For λ=30\lambda= 30 and 4040, the final adaptive meshes contain 162 and 1727 subintervals, respectively, with smallest lengths approximately 2−322^{-32} and 2−462^{-46}. The hardest case therefore drives the finest spacing close to the limits of double precision. The deterioration of the forward error in this regime is consistent with the severe conditioning of the large-parameter Troesch problem rather than with a failure to resolve the boundary layer.

Nonlinear Singularly Perturbed BVP

The final example is a nonlinear singularly perturbed BVP with boundary layers near both endpoints. The scalar equation is

εy′′=1−y2,−1≤x≤1,y(−1)=y(1)=0.(100)\varepsilon y^{\prime\prime} = 1-y^2,\qquad-1 \le x \le1,\qquad y(-1)=y(1)=0. \tag*{(100)}

We write it as the first-order system

{ϕ1′=ϕ2ϕ2′=(ϕ12−1)/ε(101)\begin{cases} \phi_1^{\prime}=\phi_2 \\ \phi_2^{\prime}=(\phi_1^2-1)/\varepsilon \tag*{(101)} \end{cases}

with boundary condition ϕ1(−1)=ϕ1(1)=0\phi_1(-1)=\phi_1(1)=0. As ε\varepsilon decreases, the solution develops increasingly sharp endpoint transitions. Starting Newton’s method from the zero initial guess fails for small ε\varepsilon, so we use continuation in ε\varepsilon. Figure 7.5 shows the solutions for ε=0.1,0.02,0.001,0.0001\varepsilon=0.1, 0.02, 0.001, 0.0001, computed sequentially to a tolerance of 10−1210^{-12}. The vertical lines show the adaptive mesh for one representative continuation stage; Table 7.6 reports the terminal grid after each continuation solve in the current run.

Solutions under different $\varepsilon$

Figure 7.5. Solutions of the nonlinear singularly perturbed problem (101) for different values of ε\varepsilon, computed by continuation.

continuation stageϵ\epsilonintervalshmin⁡h_{\min}
110−110^{-1}45.00×10−15.00 \times10^{-1}
22×10−22 \times10^{-2}62.50×10−12.50 \times10^{-1}
310−310^{-3}106.25×10−26.25 \times10^{-2}
410−410^{-4}141.56×10−21.56 \times10^{-2}

Table 7.6. Evolution of the terminal adaptive mesh along the continuation path for the nonlinear singular perturbation example. The largest interval remains hmax⁡=0.5h_{\max}=0.5 in these runs, while the smallest interval decreases as the endpoint layers sharpen.

This example also illustrates the interaction between continuation and adaptivity. Continuation reduces the number of Newton iterations required to reach the final state and therefore avoids the accumulation of unnecessary refinements from poor intermediate iterates. In this sense, a suitable continuation path improves both nonlinear convergence and mesh selection.

Conclusion

In this paper, we have presented a fast automatically adaptive solver for nonlinear two-point boundary value systems. The main idea is to formulate

Conclusion

the nonlinear problem as a nonlinear second-kind integral equation and to solve each Newton or continuation correction with a fast direct solver for the corresponding linear second-kind equation. A central message is that progress on fast direct integral-equation solvers for linear BVPs is not confined to linear problems: once the boundary formulation is completed and the linear solver is embedded in Newton, continuation, and adaptive refinement loops, its favorable properties are inherited by a nonlinear solver. The resulting method retains the well-conditioned nature of integral equations, high-order local Chebyshev discretization, linear complexity in the number of mesh points for fixed system dimension and local order, and automatic concentration of degrees of freedom near localized features.

The method is designed for the difficult regimes that motivate adaptive BVP solvers: boundary layers, rapid oscillations, long intervals with localized dynamics, singular perturbations, hypersensitive optimal-control systems, and problems whose boundary conditions are degenerate for the simplest background Green’s function. The boundary-condition preprocessing makes the formulation applicable to general first-order systems, including high-order scalar equations after conversion to system form. The numerical examples demonstrate high accuracy with strongly nonuniform meshes selected automatically.

The next step is to use the solver as a computational kernel for bifurcation and solution-branch exploration. The continuation framework already separates the path-following logic from the fast linearized solves, which makes it suitable for detecting multiple solutions and following branches through parameter space. Further work will focus on robust Newton globalization, branch switching, and eventually a fast robust method for the computation of folds and solution branches.

Acknowledgements. We would like to thank Leslie Greengard, Charles Epstein, and Manas Rachh for many helpful discussions. The authors were supported in part by National Key Research and Development Program of China under grant 2023YFA1008902, and in part by the National Natural Science Foundation of China under grant 12301515.

References

  1. [1]Eugene L. Allgower and Kurt Georg. Introduction to Numerical Continuation Methods. Society for Industrial and Applied Mathematics, 2003.DOI
  2. [2]Uri M. Ascher, Robert M. M. Mattheij, and Robert D. Russell. Numerical Solution of Boundary Value Problems for Ordinary Differential Equations. Society for Industrial and Applied Mathematics, 1995.DOI
  3. [3]G. A. Bliss. A boundary value problem for a system of ordinary linear differential equations of the first order. Transactions of the American Mathematical Society, 28:561–589, 1926.
  4. [4]Shih-Hsiang Chang. A variational iteration method for solving troesch’s problem. Journal of Computational and Applied Mathematics, 234(10):3043–3047, 2010.DOI
  5. [5]Philippe G. Ciarlet and Cristinel Mardare. On the newton–kantorovich theorem. Analysis and Applications, 10(03):249–269, 2012.DOI
  6. [6]L. Greengard and V. Rokhlin. On the numerical solution of two-point boundary value problems. Communications on Pure and Applied Mathematics, 44(4):419–452, June 1991.
  7. [7]Herbert B. Keller. Numerical Solution of Two Point Boundary Value Problems. Society for Industrial and Applied Mathematics, 1976.
  8. [8]J. Y. Lee and L. Greengard. A fast adaptive numerical method for stiff two-point boundary value problems. SIAM Journal on Scientific Computing, 18(2), 03 1997.DOI
  9. [9]William Leeb and Vladimir Rokhlin. On the numerical solution of fourth-order linear two-point boundary value problems. SIAM Journal on Scientific Computing, 42(3):A1505–A1531, 2020.arxiv.org/abs/1711.05354
  10. [10]Per-Gunnar Martinsson and Vladimir Rokhlin. A fast direct solver for boundary integral equations in two dimensions. Journal of Computational Physics, 205(1):1–23, 2005.
  11. [11]Page Starr and Vladimir Rokhlin. On the numerical solution of two-point boundary value problems ii. Communications on Pure and Applied Mathematics, 47:1117–1159, 1994.DOI
  12. [12]Lloyd N. Trefethen. Approximation Theory and Approximation Practice. Society for Industrial and Applied Mathematics, 2013.
  13. [13]Hector Vazquez-Leal, Yasir Khan, Guillermo Fernandez Anaya, Agustin Herrera-May, Arturo Sarmiento-Reyes, Uriel F. UrielFobello-Nino, Victor-M. Jimenez-Fernandez, and Dennis Pereyra Diaz. A general solution for troesch’s problem. Mathematical Problems in Engineering, 2012, 2012.
  14. [14]Maha Youssef and Gerd Baumann. Troesch’s problem solved by sinc methods. Mathematics and Computers in Simulation, 162:31–44, 2019.DOI

Paper details

vlnc:W_eqmm2mtq
Version
v1 · latest
Published
Fresh — added to the Hub within the last 30 days
Added
License
CC BY 4.0
Usage

views · 0

downloads · 0

A view counts once per browser per day, a download each time the PDF is requested.

  • Mathematics

Not recorded for this paper

View statement
Looking for related papers…
Contents