Abstract
In this paper, we are concerned with energy-conserving methods for Poisson problems, which are effectively solved by defining a suitable generalization of HBVMs, a class of energy-conserving methods for Hamiltonian problems. The actual implementation of the methods is fully discussed, with a particular emphasis on the conservation of Casimirs. Some numerical tests are reported, in order to assess the theoretical findings.
Similar content being viewed by others
Avoid common mistakes on your manuscript.
1 Introduction
A Poisson problem is in the form
where H(y) is a scalar function, usually called the Hamiltonian. For sake of simplicity, hereafter both H(y) and B(y) will be assumed suitably regular. From the skew-symmetry of B(y) one easily deduces that H(y) is a constant of motion, since, along the solution of (1),
due to the skew-symmetry of B(y). Possible additional invariants of (1) are its Casimirs, namely scalar functions C(y) for which
holds true for all y. When matrix B(y) is constant, as in the case of Hamiltonian problems,
energy conservation can be obtained by solving problem (3) via HBVMs, a class of energy-conserving Runge-Kutta methods for Hamiltonian problems (see, e.g., [7, 8, 11, 12] and the monograph [5], see also the recent review paper [6]). Nevertheless, in the case where the problem is not Hamiltonian, HBVMs are no more energy-conserving. This motivates the present paper, where an energy-conserving variant of HBVMs for Poisson problems is derived and analyzed.
The numerical solution of Poisson problems has been tackled by following many different approaches (see, e.g., [20, Chapter VII] and references therein). More recently, it has been considered in [19], where an extension of the AVF method [22] is proposed, and in [1, 3], where a line integral approach has been used instead. Functionally fitted methods have been proposed in [21, 24,25,26]. In this paper we further pursue the line integral approach to the problem, which will provide an energy-conserving variant of HBVMs for solving (1).
With this premise, the structure of the paper is the following: in Section 2 we describe the new framework, in which the methods will be derived; in Section 3 we provide the final shape of the method, while in Section 4 its actual implementation is studied; in Section 5 we present a few numerical tests confirming the theoretical findings; at last, in Section 6 we give some concluding remarks.
2 The new framework
As anticipated above, the framework that we shall use to derive and analyze the methods is that of the so-called line integral methods, namely methods where the conservation properties are derived by the vanishing of a corresponding line integral [5, 6]. Such methods have been largely investigated in the case of Hamiltonian problems, providing their major instance given by Hamiltonian Boundary Value Methods (HBVMs). The analysis will strictly follow that in [11] and [17]. To begin with, let us consider problem (1) on the interval [0,h],
In fact, since we shall speak about a one-step method, it suffices to analyze its first step of application, with h the time-step. Next, let us consider the orthonormal Legendre polynomial basis {Pj}j≥ 0 on the interval [0,1],
with δij the Kronecker symbol, and the following expansions for the functions at the right-hand side in (4):
The following properties hold true.
Lemma 1
Assume \(\psi :[0,h]\rightarrow V\), with V a vector space, admit a Taylor expansion at 0. Then, for all \(j=0,1,\dots \):
Proof
By the hypotheses on ψ, one has:
Consequently, for all \(i=0,\dots ,j\), by virtue of (5) it follows that:
□
Corollary 1
With reference to (6), for any suitably regular path \(\sigma :[0,h]\rightarrow \mathbb {R}^{m}\) one has:
Proof
Immediate from Lemma 1, by taking into account (6).□
We also state, without proof, the following straightforward property, deriving from the skew-symmetry of B.
Lemma 2
With reference to (6), for any path \(\sigma :[0,h]\rightarrow \mathbb {R}^{m}\) one has:
Taking into account (6), the right-hand side in (4) can be rewritten as:
from which one obtains that the solution of (4) can be formally written as:
In particular, by considering (5) and that P0(c) ≡ 1, from which \({{\int \limits }_{0}^{1}}P_{i}(x)\mathrm {d} x=\delta _{i0}\), one has:
In order to obtain a polynomial approximation of degree s to y, it suffices to truncate the two infinite series in (9) after s terms:
with ρij(σ) and γj(σ) defined according to (6) by formally replacing y by σ. Consequently, (10) becomes
providing the approximation
in place of (11).
2.1 Interpretation of σ
We now provide an interesting interpretation of the polynomial approximation σ. For this purpose, let us rewrite (9), by taking into account (6), as follows:
as is expected. In a similar way, we can rewrite (12) as:
having denoted by \(\left [\cdot \right ]_{s}\) the best approximation in πs− 1 (i.e., [⋅]s is the best polynomial approximation of degree s − 1) of the function in argument. This fact provides a noticeable interpretation of the polynomial approximation σ, which is the solution of the initial value problem
equivalent to (12). Thus, the vector field of (15) is defined by a double projection procedure onto the finite dimensional vector space πs− 1 which involves, in turn, the vector fields ∇H(σ(ch)) and \(B(\sigma (ch))\left [\nabla H(\sigma (ch))\right ]_{s}\), respectively.
2.2 Analysis
We now analyze the method (12)–(14). The following result then holds true, stating that the method is energy-conserving.
Theorem 1
H(y1) = H(y0).
Proof
In fact, by virtue of (1), (6), and (12)–(14) one has, by using the standard line integral argument:
where the last equality follows from (8).□
Concerning the accuracy of the new approximation, the following result holds true.
Theorem 2
Let y1 be defined according to (12)–(14). Then, y1 − y(h) = O(h2s+ 1).Footnote 1
Proof
Let y(t) ≡ y(t,ξ,η) denote the solution of the initial value problem (see (1))
Moreover, let us denote
also recalling that
Then, by taking into account Lemma 1 and Corollary 1, and setting
one has:
□
At last, we observe that, since the procedure (12)–(14) is equivalent to defining the path σ that joins σ(0) = y0 to σ(h) = y1, then the same procedure, when started at y0 and going forward provides y1 and, when started from y1 and going backward, brings back to y0. In other words, the following result holds true.
Theorem 3
The procedure (12)–(14) is symmetric.
Proof
This result comes as an easy consequence of Theorem 11, where the analogous property for the full discretized method is shown. □
Remark 1
We conclude this section emphasizing that, when problem (1) is Hamiltonian, i.e., in the form (3), then matrix B(y) ≡ J is constant, and therefore (see (6)) ρij(σ) = δijJ. Consequently, (13) becomes
which (see [6, 8, 10]) is the so-called master functional equation defining the class of energy-conserving methods named Hamiltonian Boundary Value Methods (HBVMs). Consequently, when the problem is Hamiltonian, then the procedure (12)–(14) reduces to the HBVM\((\infty ,s)\) method in [8].
2.3 Conservation of Casimirs
In this section, we study the required modifications, in order to conserve Casimirs, i.e., functions satisfying (2). For sake of simplicity, we shall consider the simpler case of one Casimir, but multiple ones can be handled by slightly adapting the arguments, as is sketched at the end of the section. To begin with, for the original problem (4), and its equivalent formulation (9), one has:
having set
the i-th Fourier coefficient of the gradient of the Casimir, with the last equality following from Lemma 1. Clearly, again from (2), one derives, by taking into account (12):
In order to recover the conservation of Casimirs, we shall use a strategy akin to that used in [18] for HBVMs (see also [4]), i.e., suitably perturbing some of its coefficients. In more details, let us consider the following modified polynomial in place of (12):Footnote 2
with \(\tilde {B}^{\top }=-\tilde {B}\ne O\) an arbitrary skew-symmetric matrix. As is usual, the new approximation will be y1 := σα(h). In other words, we have considered the following perturbed coefficient:
in place of ρ00(σ) in (12). The following result holds true.
Theorem 4
Assume that \(\pi _{0}(\sigma _{\alpha })^{\top } \tilde {B}\gamma _{0}(\sigma _{\alpha })\ne 0\). Then the Casimir C(y) is conserved, provided that
Moreover, α = O(h2s).
Proof
In fact, by repeating similar steps as in (19), and replacing σ by σα, as defined in (20), one obtains:
provided that (21) holds true. The statement is completed by observing that the numerator is O(h2s), whereas, the denominator is O(1). \(\Box {~}\)
We now prove that the results of Theorems 1 and 2 continue to hold for the polynomial (20).
Theorem 5
For any α: H(σα(h)) = H(σα(0)).
Proof
Following similar steps as in the proof of Theorem 1, one has:
due to the fact that \(\tilde {B}\) is skew-symmetric, independently of the considered value of the parameter α.□
Theorem 6
Assume that the parameter α in (20) is chosen according to (21). Then,
Proof
Repeating similar steps as those in the proof of Theorem 2 (and using the same notation), and taking into account (20), one arrives at:Footnote 3
□
Remark 2
We observe that the modified polynomial σα in (20) is the solution of the approximate perturbed ODE-IVPs:
where the parameter α is such that C(σα(h)) = C(σα(0)). Clearly, when α = 0, one recovers the problem (15) defining σ.
We end this section by sketching the case when we have r independent Casimirs, so that \(C:\mathbb {R}^{m}\rightarrow \mathbb {R}^{r}\). In such a case, the notation introduced above formally still holds true, with the following differences:
-
The Fourier coefficients (see (18)) \(\pi _{i}(u_{\alpha })\in \mathbb {R}^{m\times r}\), \(i=0,\dots ,s-1\);
-
The polynomial (20) now becomes
$$ \dot \sigma_{\alpha}(ch) = {\sum}_{i,j=0}^{s-1} P_{i}(c)\rho_{ij}(\sigma_{\alpha}) \gamma_{j}(\sigma_{\alpha}) - {\sum}_{\ell=1}^{r}\alpha_{\ell} \tilde{B}_{\ell}\gamma_{0}(\sigma_{\alpha}), \qquad c\in[0,1], \qquad \sigma_{\alpha}(0)=y_{0}, $$(23)having set \(\alpha =\left (\alpha _{1}, \dots , \alpha _{r}\right )^{\top }\) and with \(\tilde {B}_{i}^{\top }=-\tilde {B}_{i}\), \(i=1,\dots ,r\), arbitrary skew-symmetric matrices such that
$$ M:= \left[ \pi_{0}(\sigma_{\alpha})^{\top} \tilde{B}_{1}\gamma_{0}(\sigma_{\alpha}), \dots, \pi_{0}(\sigma_{\alpha})^{\top} \tilde{B}_{r}\gamma_{0}(\sigma_{\alpha})\right]\in\mathbb{R}^{r\times r} $$(24)is nonsingular;
-
The vector α, providing the conservation of all Casimirs, is given by (compare with (21))
$$ \alpha = M^{-1} {\sum}_{i,j=0}^{s-1} \pi_{i}(\sigma_{\alpha})^{\top} \rho_{ij}(\sigma_{\alpha})\gamma_{j}(\sigma_{\alpha}). $$(25)
3 Discretization
The procedure (12)–(14) described in the previous section is not yet a ready to use numerical method. In fact, in order for this to happen, the integrals γj(σ),ρij(σ), \(i,j=0,\dots ,s-1\), defined in (6) need to be conveniently computed or approximated. For this purpose, as it has been done in the case of HBVMs [8], we shall use a Gauss-Legendre quadrature formula of order 2k, i.e., the interpolatory quadrature rule based at the zeros of Pk(c), with abscissae and weights (ci,bi), for a convenient value k ≥ s. In so doing, we shall in general obtain a new polynomial approximation u ∈πs, in place of σ as defined in (12)–(13):
Consequently, the new approximation to y(h) will be given by
which is the discrete counterpart of (14).
It is worth mentioning that, in a similar way as done in Section 2.1 for the polynomial σ, for u one obtains, by virtue of (26):
having set \([\cdot ]_{s}^{(2k)}\) the approximate best approximation in πs− 1 obtained by using a quadrature of order 2k for approximating the involved integrals.Footnote 4 Consequently (compare with (15)), the polynomial u is the solution of the initial value problem:
Remark 3
We observe that the polynomial approximation defined by the problem
corresponds to that provided by the methods in [19], when the Gauss-Legendre abscissae are used, and to the methods in [26, Definition 3.2], upon selecting the derivative space as πs− 1. Similarly, some of the methods in [1] provide the approximation
Remark 4
When in (28) B(σ(ch)) ≡ J, a constant skew-symmetric matrix, we derive the polynomial approximation provided by a HBVM(k,s) method:
3.1 Analysis
As was done in Section 2.2 for the continuous procedure, let us now analyze the fully discrete method (26)–(27). To begin with, the following straightforward result holds true.
Theorem 7
If
and, consequently, with reference to (26) and (13), one has u ≡ σ.
Proof
In fact, if B is a polynomial of degree μ and H a polynomial of degree ν, the integrand defining ρij(u) has at most degree μs + 2s − 2, whereas that defining γj(u) has at most degree νs − 1. Consequently, these degrees do not exceed 2k − 1, when (30) holds true. As a result, the quadrature is exact, so that (31) is valid and, therefore, u ≡ σ.□
Consequently, when (30) hold true, the method is energy-conserving and has order 2s, as stated by Theorems 1 and 2, respectively.
Concerning energy conservation, the following additional result holds true, in the case where only H is a polynomial.
Theorem 8
If
then H(y1) = H(y0).
Proof
In fact, in such a case \(\gamma _{j}(u)=\hat \gamma _{j}(u)\), \(j=0,\dots ,s-1\), and the proof of Theorem 1 continues formally to hold, upon replacing σ with u, and ρij with \(\hat \rho _{ij}\), due to the fact that (compare with (8))
□
When (31) does not hold true, there is a quadrature error that, upon regularity assumptions, can be easily seen to be given by (see (6)):
Nonetheless, also in this case it is straightforward to verify that (compare with (7)),
Consequently, with reference to the approximation y1 defined in (27), the following result is easily obtained, when (32) is not valid.
Theorem 9
∀k ≥ s : H(y1) = H(y0) + O(h2k+ 1).
Proof
In fact, using arguments similar to those used in the proof of Theorem 1, one has, by taking into account (33)–(35):
□
Concerning the accuracy of the approximation (27), the following result, stating that the convergence order of Theorem 2 is retained, holds true.
Theorem 10
∀k ≥ s : y1 − y(h) = O(h2s+ 1).
Proof
By using arguments and notations similar to those used in the proof of Theorem 2, one has, by taking into account (34) and that k ≥ s:
Concerning the latter sum, one has:
and, consequently, the statement follows.□
Remark 5
By taking into account the results of Theorems 7 and 9, it follows that, by choosing k large enough, one obtains either an exact conservation of the Hamiltonian function, in the polynomial case, or a practical conservation, in the non polynomial case. In fact, as it has been also observed for HBVMs [11], in the latter case it is enough to choose k large enough so that the Hamiltonian error falls within the round-off error level of the finite precision arithmetic used in the simulation.
It is worth mentioning that a result similar to that of Theorem 3 holds true for the fully discrete method.
Theorem 11
The method (26)–(27) is symmetric, provided that the abscissae of the quadrature satisfy Footnote 5
Proof
Symmetry of a given one-step method y1 = Φh(y0) applied to an initial value problem \(y^{\prime }=f(y)\) with y(0) = y0, means that \({\Phi }_{h}^{-1}={\Phi }_{-h}\) that is, applying the method to the state vector y1, but with the direction of time reversed, yields the initial state vector y0, independently of the choice of the initial value y0. In our context, with reference to (26)–(27), Φh is defined by
where \(\hat \rho _{ij}\) and \(\hat \gamma _{j}\) are the solutions of the nonlinear system
We can obtain the explicit formulation of \(\bar y_{0}={\Phi }_{-h}(y_{1})\) by introducing in (37)–(38) the following substitutions: y1 in place of y0 and − h in place of h. In so doing, we arrive at the method defined as
where the unknown quantities \(\bar \rho _{ij}\) and \(\bar \gamma _{j}\) satisfy the following nonlinear system
and we want to show that \(\bar y_{0}=y_{0}\). To this end, we introduce the following variables:
Exploiting the symmetry property of Legendre polynomials, (− 1)jPj(c) = Pj(1 − c), from the first equation in (38) we get
Introducing the change of variables τ = 1 − x, transforms the latter integral as
Exploiting the symmetry assumption (36), which in turn implies symmetric weights, bk−i+ 1 = bi, \(i=1,\dots ,k\), we finally get
The same flow of computation may be employed on the second equation in (38) to see that
We then realize that \(\gamma _{j}^{\ast }\) and \(\rho ^{\ast }_{ij}\) satisfy the very same nonlinear system (40) governing the quantities \(\bar \gamma _{j}\) and \(\bar \rho _{ij}\). Thus we may conclude that
and hence from (39),
□
In the limit case when \(k\rightarrow \infty \), since the Gauss-Legendre quadrature formule are convergent, we are led back to the symmetry property of the original non-discretized procedure (12)–(14) that we anticipated in Theorem 3.
We conclude this section by emphasizing that, when problem (1) is in the form (3), then (see (26)) \(\hat \rho _{ij}(\sigma ) = { \delta _{ij}}J\) and, consequently, the polynomial approximation u becomes
which is equivalent to (29). As anticipated in Remark 4, this equation (see, e.g., the monograph [5] or the review paper [6, Section 2.2]) defines a Hamiltonian Boundary Value Method with parameters k and s, in short HBVM(k,s). Moreover, also Theorems 7–10 exactly describe, in the case of problem (3), their conservation and accuracy properties. For this reason, the methods here presented can be regarded as a generalization of HBVMs for solving Poisson problems and, therefore, this fact, motivates the following definition.
Definition 1
We shall refer to the method (26)–(27) as to a PHBVM(k,s) method.
3.2 Conservation of Casimirs
This section is devoted to the conservation of Casimirs for the discrete PHBVM(k,s) method (26)–(27), following similar steps as those in Section 2.3. For this purpose, it is convenient to define the approximate Fourier coefficients, for k ≥ s, which we assume hereafter:
The following straightforward result is reported without proof.
Lemma 3
Assume that σ ∈πs. Then, with reference to (18), for all \(i=0,\dots ,s-1\), one has:
Next, let us consider the following perturbed polynomial, in place of the polynomial u in (26),
with \(\tilde {B}^{\top }=-\tilde {B}\ne O\) an arbitrary matrix, and (compare with (21))
Theorem 12
If
Then (see (26), (6)), (18), and (41)
and, consequently, with reference to (42) and (20), one has uα ≡ σα.
Differently, by setting y1 := uα(h) the new approximation, Theorems 8, 9, 10, and 11 continue formally to hold. Moreover, the following result holds true.
Theorem 13
With reference to (42)–(43), one has:
Proof
By taking into account Lemma 3, one obtains:
In case C ∈πν with ν ≤ 2k/s, then, by virtue of Lemma 3, \(\pi _{i}(u_{\alpha })=\hat \pi _{i}(u_{\alpha })\) and, consequently, (∗) = 0 because of (43). Conversely, again from Lemma 3, one has:
□
Remark 6
From the arguments here exposed, one deduces that when using a finite precision arithmetic, a (at least) practical conservation of both the Hamiltonian and the Casimirs can be obtained, by choosing k large enough.
Definition 2
Following [18], we name enhanced PHBVM(k,s), in short EPHBVM(k,s), the method defined by (42)–(43).
Following Remark 2, the polynomial uα defined by an EPHBVM(k,s) method is the solution of the ODE-IVP (compare with (22)):
Clearly, when α = 0 one retrieves the problem (28) defining the polynomial approximation of the PHBVM(k,s) method.
Remark 7
From the results of Theorems 8, 9, and 13, one deduces the clear advantage of choosing values of k suitably larger than s, in order to obtain a suitable conservation of non-quadratic Hamiltonians and/or Casimirs. This fact will be duly confirmed in the numerical tests. Moreover, this is not a serious drawback, from the point of view of the computational cost, since, as we shall see in the next section, the discrete problem to be solved will always have (block) dimension s, independently of k.Footnote 6
4 The discrete problem
In this section we deal with the efficient solution of the discrete problem generated by the PHBVM(k,s) method (26). For this purpose, we observe that only the values Yℓ := u(cℓh), \(\ell =1,\dots ,k\), are actually needed. Consequently, (26) can be re-written as:
where, for sake of brevity, we have omitted the argument u for \(\hat \gamma _{j}\) and \(\hat \rho _{ij}\), as was already done in (37)–(38). The (46) can be cast in matrix form by defining the block vectors and matrices
and
In fact, by also setting hereafter Ir the identity of dimension r, we can rewrite (46) as:
where
As is clear, the discrete problem (49) can be further reformulated in terms of the product of the Fourier coefficients \(\hat \rho _{ij}\) and \(\hat \gamma _{j}\). In fact, by setting
the first equation in (49) becomes
whereas, multiplying side by side the third by the second gives
Consequently, by substituting the right-hand side of (51) in the right-hand side of (52), provides the new discrete problem:
Moreover, computing the vector ϕ in (50) allows us to obtain the new approximation (27) as:
Remark 8
In case where the problem (1) is in the form (3), one has that \({\mathscr{B}}(Y)=I_{s}\otimes J\). Consequently, considering that
the discrete problem (53) reduces to:
This latter problem is exactly that generated by a HBVM(k,s) method applied for solving (3) [9]. We observe, however, that while the original HBVM(k,s) method is actually a k-stage Runge-Kutta method with Butcher tableau (see (48))
this is no more the case for the generalization defined by (49).
Remark 9
In the case k = s, one has that \(\mathcal {P}_{s}\mathcal {P}_{s}^{\top }{\Omega }=I_{s}\). Consequently, (53) becomes, by using the notation (16),
This, in turn, is equivalent to the application of the s-stage Gauss method to the problem (1) (see, e.g., [9]).
Instead, in the case k > s, the discrete problem (53) is equivalent to the application of the HBVM(k,s) method to the problem (see (28)),
in place of (1). This application , in turn, provides the polynomial approximation (28).
We observe that the formulation (53) naturally induces a straightforward iterative procedure for solving the discrete problem,
for which the initial approximation ϕ0 = 0 can be conveniently used. It is also possible to use the simplified Newton iteration for solving (53) which, taking into account (48), (54), and that (see, e.g., [5])
takes the form:
with \(F^{\prime }\) the Jacobian of F (see (16)). Nevertheless, the iteration (57) requires the factorization of a matrix having size s times larger than that of problem (1), which can be costly, when s and/or m are large. Consequently, it is much more effective to resort to a blended iteration for solving (53) (see, e.g., [9], we also refer to [13] for a more detailed analysis of blended methods). In the present case, this latter iteration, considering the matrix Xs defined in (56), denoting σ(Xs) its spectrum, and setting
assumes the form:
Consequently, only the matrix Λ in (58), having the same size as that of the continuous problem (1), needs to be factored. This fact is a common feature, in the many instances where the blended iteration can be used. For this reason, in such cases, it turns out to be extremely efficient (see, e.g., [2, 14,15,16, 23]).
Remark 10
In the practical use of the methods, it is customary to choose the parameter k, related to the order of the quadrature, so that the discretization error falls within the round-off error level. Nevertheless, round-off errors are unavoidable, as are iteration errors in (55) or (59). This may cause a small numerical drift in the invariants,Footnote 7 even in the case where the quadrature is exact. This phenomenon has been duly studied in [5, Chapter 4.3], where a simple correction procedure is given to avoid this problem. The same procedure can be conveniently used in this setting, too. The reader is referred to the above reference for full details.
4.1 Conservation of Casimirs
In this section we sketch the implementation of EPHBVM(k,s) methods described in Section 3.2. For this purpose, besides the vector ϕ defined in (50), we need to define the block vector
with the approximate Fourier coefficients (41) of the gradient of the Casimir.Footnote 8 In so doing, the discrete problem generated by an EHBVM(k,s) method becomes:
and the new approximation given by
We conclude this section by mentioning that, in case of multiple Casimirs, the discrete problem (61) can be readily generalized, by considering discrete counterparts of (24)–(25).
5 Numerical tests
In this section we present a couple of numerical tests concerning the solution of Lotka-Volterra problems, with the last one possessing a Casimir. The numerical tests have been carried out on a 3GHz Intel Xeon W10 core computer with 64GB of memory running Matlab 2020a.
Example 1
We consider the following Lotka-Volterra problem:
with
whose solution, which is periodic of period T ≈ 4.633434168477889, is depicted in Fig. 1. At first, we solve the problem on one period with time-step h = T/n, by using the following methods:
-
The s-stage Gauss method, s = 1,2,3;
-
The PHBVM(4,s), s = 1,2, and PHBVM(6,3) methods, which become soon energy-conserving, as the value of n is increased.
The obtained results are summarized in Table 1, where we have denoted by ey and eH the error in the solution and in the Hamiltonian after one period, respectively. Their numerical rate of convergence is also reported, along with the mean blended iterations (58)–(59) per time-step (it), in order to obtain convergence within full machine accuracy, and the execution time in sec. From the listed results, one infers that:
-
As is striking clear, the higher order methods are much more efficient than the lower order ones, especially when a high accuracy is required;
-
The theoretical rate of convergence for both the solution and the Hamiltonian errors is that we expected (for PHBVMs, until the Hamiltonian error falls within the round-off error level);
-
For a fixed time-step h, the numerical solutions provided by the Gauss methods and by the corresponding PHBVM method have a comparable accuracy, despite the negligible Hamiltonian error of these latter methods;
-
The execution times of the PHBVM methods are about double than those of the corresponding Gauss methods, even though the mean number of blended iterations per time-step is practically the same (this latter, decreasing with the time-step h, and slightly increasing with s).
As a result, one would conclude that the conservation of the Hamiltonian apparently gains no practical advantage. However, this conclusion is readily confuted if we look at the error growth in the Hamiltonian and in the solution. In fact, in Fig. 2 there is the plot of the Hamiltonian error (left plot) and the solution error (right plot) by using the 3-stage Gauss method and the PHBVM(6,3) method with time-step h = T/100 over 100 periods. As one may see, now it is clear that the 3-stage Gauss method exhibits a numerical drift in the energy, unlike PHBVM(6,3). As a result, this latter method exhibits a linear error growth, whereas the former one has a quadratic error growth.
Example 2
The second example, taken from [20], is given by:
with
whose solution, which is periodic of period T ≈ 2.143610709155912, is depicted in Fig. 3.
At first, we compare the same methods used for the previous example, again with time-step h = T/n. The obtained results for the s-stage Gauss and PHBVM methods are listed in Table 2: the conclusions that one can derive from them are similar to those driven from Table 1 for the previous example, with the additional remark that now the Casimir C(y) is not conserved.Footnote 9 This fact, in turn, produces the results depicted in the two plots in Fig. 4, concerning the application of the Gauss-3 and PHBVM(6,3) methods for solving the problem with time-step h = T/100 over 100 periods. From the two plots, one infers that both methods exhibit a drift in the Casimir, whereas only Gauss-3 exhibits a drift in the Hamiltonian, too (left plot); however, both methods exhibit a quadratic error growth in the solution, despite the fact that PHBVM(6,3) conserves the Hamiltonian. For this reason, in Table 3 we list the obtained results by using the EHBVM(4,1), EHBVM(4,2), and EHBVM(6,3) methods for solving problem (63), by using the same time-steps considered for obtaining the results of Table 2. As one may see, now the conservation of the Casimir is soon obtained, as the time-step is decreased, besides that of the Hamiltonian, with a computational cost perfectly comparable to that of the corresponding PHBVM method. The conservation of both invariants, in turn, allows to recover a linear error growth in the numerical solution, as is shown in the plot of Fig. 5.
6 Conclusions
In this paper we have presented a class of energy-conserving line integral methods for Poisson problems. In the case where the problem is Hamiltonian, these methods reduce to the class of Hamiltonian Boundary Value Methods (HBVMs), which are energy-conserving methods for such problems. Consequently, the new methods can be regarded as an extension of HBVMs for Poisson (not Hamiltonian) problems, which we called PHBVMs. Moreover, a further enhancement of such methods (EPHBVMs) allows to obtain the conservation of Casimirs, too. A thorough analysis of the methods has been carried out, confirmed by a couple of numerical tests. As a further direction of investigation, we mention the study of the application of the methods for solving highly oscillatory Poisson problems, similarly as done with HBVMs in the Hamiltonian case [27,28,29].
Change history
18 July 2022
Missing Open Access funding information has been added in the Funding Note.
Notes
I.e., the approximation procedure has order of convergence 2s.
Here, we take into account that P0(c) ≡ 1.
For sake of brevity, we skip here some of the intermediate passages, which are identical to those used in the proof of Theorem 2.
I.e., \(\lim _{p\rightarrow \infty } [\cdot ]_{s}^{(p)} = [\cdot ]_{s}\).
This is, in fact, the case, for the Gauss-Legendre quadrature abscissae.
This latter feature is inherited, in turn, from the original methods, HBVM(k,s) and EHBVM(k,s) for Hamiltonian problems.
Usually, this is a very small drift, of the order of the machine epsilon per step.
As before, for sake of brevity we now omit the argument uα of the approximate Fourier coefficients.
In Table 2eC denotes the error in the Casimir.
References
Brugnano, L., Calvo, M., Montijano, J.I., Rández, L.: Energy preserving methods for Poisson systems. J. Comput. Appl. Math. 236, 3890–3904 (2012)
Brugnano, L., Frasca Caccia, G., Iavernaro, F.: Efficient implementation of Gauss collocation and Hamiltonian Boundary Value Methods. Numer. Algorithms 65, 633–650 (2014)
Brugnano, L., Gurioli, G., Iavernaro, F.: Analysis of energy and QUadratic invariant preserving (EQUIP) methods. J. Comput. Appl. Math. 335, 51–73 (2018)
Brugnano, L., Iavernaro, F.: Line integral methods which preserve all invariants of conservative problems. J. Comput. Appl. Math. 236, 3905–3919 (2012)
Brugnano, L., Iavernaro, F.: Line Integral Methods for Conservative Problems. Chapman and Hall/CRC, Boca Raton (2016)
Brugnano, L., Iavernaro, F.: Line integral solution of differential problems. Axioms 7(2), article n. 36 (2018). https://doi.org/10.3390/axioms7020036
Brugnano, L., Iavernaro, F., Trigiante, D.: Hamiltonian BVMs (HBVMs): A family of “drift-free” methods for integrating polynomial Hamiltonian systems. AIP Conf. Proc. 1168, 715–718 (2009)
Brugnano, L., Iavernaro, F., Trigiante, D.: Hamiltonian boundary value methods (energy preserving discrete line integral methods). JNAIAM J. Numer. Anal. Ind. Appl. Math. 5(1–2), 17–37 (2010)
Brugnano, L., Iavernaro, F., Trigiante, D.: A note on the efficient implementation of Hamiltonian BVMs. J. Comput. Appl. Math. 236, 375–383 (2011)
Brugnano, L., Iavernaro, F., Trigiante, D.: The lack of continuity and the role of infinite and infinitesimal in numerical methods for ODEs: the case of symplecticity. Appl. Math. Comput. 218, 8056–8063 (2012)
Brugnano, L., Iavernaro, F., Trigiante, D.: A simple framework for the derivation and analysis of effective one-step methods for ODEs. Appl. Math. Comput. 218, 8475–8485 (2012)
Brugnano, L., Iavernaro, F., Trigiante, D.: Analisys of Hamiltonian Boundary Value Methods (HBVMs): a class of energy-preserving Runge-Kutta methods for the numerical solution of polynomial Hamiltonian systems. Commun. Nonlinear Sci. Numer. Simul. 20, 650–667 (2015)
Brugnano, L., Magherini, C.: Blended implementation of block implicit methods for ODEs. Appl. Numer. Math. 42, 29–45 (2002)
Brugnano, L., Magherini, C.: The BiM code for the numerical solution of ODEs. J. Comput. Appl. Math. 164-165, 145–158 (2002)
Brugnano, L., Magherini, C.: Blended implicit methods for the numerical solution of DAE problems. J. Comput. Appl. Math. 189, 34–50 (2006)
Brugnano, L., Magherini, C.: Recent advances in linear analysis of convergence for splittings for solving ODE problems. Appl. Numer. Math. 59, 542–557 (2009)
Brugnano, L., Montijano, J.I., Rández, L.: High-order energy-conserving line integral methods for charged particle dynamics. J. Comput. Phys. 396, 209–227 (2019)
Brugnano, L., Sun, Y.: Multiple invariants conserving Runge-Kutta type methods for Hamiltonian problems. Numer. Algorithms 65, 611–632 (2014)
Cohen, D., Hairer, E.: Linear energy-preserving integrators for Poisson systems. BIT Numer. Math. 51, 91–101 (2011)
Hairer, E., Lubich, C., Wanner, G.: Geometric Numerical Integration, 2nd edn. Springer, Berlin (2006)
Miyatake, Y.: A derivation of energy-preserving exponentially-fitted integrators for Poisson systems. Comput. Phys. Commun. 187, 156–161 (2015)
Quispel, G.R.W., McLaren, D.I.: A new class of energy-preserving numerical integration methods. J. Phys. A 41(4), 045206 (2008)
Wang, B., Meng, F., Fang, Y.: Efficient implementation of RKN-type Fourier collocation methods for second-order differential equations. Appl. Numer. Math. 119, 164–178 (2017)
Wang, B., Wu, X.: Functionally-fitted energy-preserving integrators for Poisson systems. J. Comput. Phys. 364, 137–152 (2018)
Wang, B., Wu, X: Geometric Integrators for Differential Equations with Highly Oscillatory Solutions. Springer Nature Singapore Pte Ltd (2021)
Mei, L., Huang, L., Wu, X.: A unified framework for the study of high-order energy-preserving integrators for solving Poisson systems. J. Comput. Phys. https://doi.org/10.1016/j.jcp.2021.110822
Brugnano, L., Montijano, J.I., Rández, L.: On the effectiveness of spectral methods for the numerical solution of multi-frequency highly-oscillatory Hamiltonian problems. Numer. Algorithms 81, 345–376 (2019)
Brugnano, L., Iavernaro, F., Montijano, J.I., Rández, L.: Spectrally accurate space-time solution of Hamiltonian PDEs. Numer. Algorithms 81, 1183–1202 (2019)
Amodio, P., Brugnano, L., Iavernaro, F.: Analysis of spectral Hamiltonian boundary value methods (SHBVMs) for the numerical solution of ODE problems. Numer. Algorithms 83, 1489–1508 (2020)
Acknowledgements
The authors wish to thank the reviewers for their suggestions and for carefully reading the manuscript.
Funding
Open access funding provided by Università degli Studi di Firenze within the CRUI-CARE Agreement.
Author information
Authors and Affiliations
Corresponding author
Ethics declarations
Conflict of interest
The authors declare no competing interests.
Additional information
Data availability
All data generated or analyzed during this study are included in this published article.
Publisher’s note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Rights and permissions
Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if changes were made. The images or other third party material in this article are included in the article's Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article's Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit http://creativecommons.org/licenses/by/4.0/.
About this article
Cite this article
Amodio, P., Brugnano, L. & Iavernaro, F. Arbitrarily high-order energy-conserving methods for Poisson problems. Numer Algor 91, 861–894 (2022). https://doi.org/10.1007/s11075-022-01285-z
Received:
Accepted:
Published:
Issue Date:
DOI: https://doi.org/10.1007/s11075-022-01285-z