1 Introduction

Phase-field models have emerged as a powerful computational approach to modeling and predicting mesoscale morphological and microstructure evolution in materials [7]. Many phase-field equations are given by gradient flows for energy functionals [6, 28]. One example is for the Ginzburg–Landau energy functional:

$$\begin{aligned} {\mathcal {E}} (\phi ) = \int _\varOmega \left( F(\phi ) + \frac{\epsilon ^2}{2} |\nabla \phi |^2 \right) d\mathbf{x}, \end{aligned}$$
(1)

where \(\varOmega \) is a domain in \({\mathbb {R}}^d~(d=1,2,3)\), \(\phi \) is the order parameter, \(F(\phi ) = \frac{1}{4} (\phi ^2-1)^2\), and \(\epsilon >0\) is a constant related to the interfacial thickness. We assume the zero Neumann boundary condition for \(\phi \): \(\nabla \phi \cdot \mathbf{n} = 0\) on \(\partial \varOmega \), where \(\mathbf{n}\) is a unit normal vector to \(\partial \varOmega \). The \(L^2\)-gradient flow for (1) is the Allen–Cahn (AC) equation [1]. Because the AC equation is of gradient type, it is easy to see that (1) is nonincreasing in time. However, the AC equation does not conserve the total mass and the conservative AC (CAC) equation was introduced by adding a nonlocal Lagrange multiplier to the AC equation [22]:

$$\begin{aligned} \frac{\partial \phi }{\partial t} = - \frac{\delta {\mathcal {E}}}{\delta \phi } + \frac{1}{|\varOmega |} \int _\varOmega f(\phi ) \, d\mathbf{x} = - \left( f(\phi ) - \epsilon ^2 \varDelta \phi \right) + \frac{1}{|\varOmega |} \int _\varOmega f(\phi ) \, d\mathbf{x}, \end{aligned}$$
(2)

where \(\frac{\delta }{\delta \phi }\) denotes the variational derivative and \(f(\phi )=F'(\phi )\). The CAC equation (2) satisfies mass conservation and energy dissipation property:

$$\begin{aligned} \frac{d}{dt} \int _\varOmega \phi \, d\mathbf{x} = \int _\varOmega \frac{\partial \phi }{\partial t} \, d\mathbf{x} = - \int _\varOmega \left( f(\phi ) - \epsilon ^2 \varDelta \phi \right) d\mathbf{x} + \int _\varOmega f(\phi ) \, d\mathbf{x} = 0 \end{aligned}$$

and

$$\begin{aligned} \frac{d{\mathcal {E}} }{dt}= & {} \int _\varOmega \frac{\delta {\mathcal {E}}}{\delta \phi } \frac{\partial \phi }{\partial t} \, d\mathbf{x} = \int _\varOmega \left( -\frac{\partial \phi }{\partial t} + \frac{1}{|\varOmega |} \int _\varOmega f(\phi ) \, d\mathbf{x} \right) \frac{\partial \phi }{\partial t} \, d\mathbf{x} \\= & {} - \int _\varOmega \left( \frac{\partial \phi }{\partial t} \right) ^2 d\mathbf{x} + \frac{1}{|\varOmega |} \int _\varOmega f(\phi ) \, d\mathbf{x} \int _\varOmega \frac{\partial \phi }{\partial t} \, d\mathbf{x} = - \int _\varOmega \left( \frac{\partial \phi }{\partial t} \right) ^2 d\mathbf{x} \le 0. \end{aligned}$$

We note that there are many versions of the CAC equation [5, 13, 14, 16, 31] and they conserve the mass but do not comply with energy properties.

While the total mass is conserved precisely, the extra nonlocal term causes difficulties for developing accurate and stable numerical methods for Eq. (2). There are various related works [4, 11, 15, 18, 20, 23, 24, 27, 29, 32] but most of them have only first-order time accuracy or are unable to prove energy stability except [11, 15, 20, 27, 29]. In [11], Hong et al. developed arbitrarily high order structure-preserving algorithms by combining the concept of energy quadratization and the Runge–Kutta (RK) method. Jing et al. [15] presented Crank–Nicolson formulas based on the energy quadratization strategy and Sun et al. [27] presented error estimates for the formulas. In [20], Okumura proposed a stable and structure-preserving scheme based on the discrete variational derivative method. Yang [29] constructed a second-order backward differentiation formula based on the invariant energy quadratization idea. The aim of this paper is to present a high-order energy stable scheme for Eq. (2), which is based on the convex splitting idea [8,9,10, 30]. In [26], we developed the specially designed implicit–explicit RK tables which make the implicit–explicit RK method [2, 17, 21] have both high-order time accuracy and unconditional energy stability for gradient flow problems. In order to apply the CSRK scheme in [26] to Eq. (2), we first need to convexly split not only the term corresponding to the AC equation but also the nonlocal term. We use a clever choice of the convex splitting for the nonlocal term to achieve numerically exact mass conservation. Since Eq. (2) is beyond the scope of Ref. [26], we also need to prove the proposed scheme is unconditionally energy stable, even with the same RK tables. Note that the unconditional energy stability in Theorem 2 requires the mass conservation proved in Theorem 1.

This paper is organized as follows. In Sect. 2, we propose the high-order convex splitting scheme and prove its mass conservation, unconditional unique solvability, and unconditional energy stability. In Sect. 3, we present numerical examples showing the accuracy and energy stability of the proposed scheme. Finally, conclusions are drawn in Sect. 4.

2 High-order Convex Splitting Scheme

In this section, we present a high-order convex splitting scheme for the CAC equation (2). The scheme is based on the observations that (i) the energy functional (1) can be split into convex and concave parts:

$$\begin{aligned} {{\mathcal {E}}}(\phi ) = {{\mathcal {E}}}_c(\phi ) - {\mathcal E}_e(\phi ) = \int _\varOmega \left( F_c(\phi ) + \frac{\epsilon ^2}{2} |\nabla \phi |^2 \right) d\mathbf{x} - \int _\varOmega F_e(\phi ) \, d\mathbf{x}, \end{aligned}$$
(3)

and then the convexity of \({{\mathcal {E}}}_c(\phi )\) and \({{\mathcal {E}}}_e(\phi )\) yields the following inequality:

$$\begin{aligned} {{\mathcal {E}}}(\phi ) - {{\mathcal {E}}}(\psi ) \le \left( f_c(\phi ) - \epsilon ^2 \varDelta \phi - f_e(\psi ), \phi - \psi \right) , \end{aligned}$$

where \(F_c(\phi ) = \frac{1}{4} \phi ^4 + \frac{1}{4}\), \(F_e(\phi ) = \frac{1}{2} \phi ^2\), \(f_c(\phi ) = F_c'(\phi )\), \(f_e(\phi ) = F_e'(\phi )\), and \(( \cdot , \cdot )\) denotes the \(L^2\)-inner product with respect to \(\varOmega \); and (ii) order of time accuracy of implicit–explicit scheme can be improved by combining with the RK method [26].

Applying the convex splitting (3) to Eq. (2), we have

$$\begin{aligned} \phi ^{n+1}= & {} \phi ^n - \varDelta t \left( f_c(\phi ^{n+1}) - \epsilon ^2 \varDelta \phi ^{n+1} - \frac{1}{|\varOmega |} \left( f_c(\phi ^{n+1}), \mathbf{1} \right) \right. \\&\left. - \left( f_e(\phi ^n) - \frac{1}{|\varOmega |} \left( f_e(\phi ^n), \mathbf{1} \right) \right) \right) , \end{aligned}$$

but it is first-order accurate in time. In order to improve its order of time accuracy, we combine with an s-stage implicit–explicit RK method [2]: let \(\phi ^{(0)} = \phi ^n\), for \(i=1,\ldots ,s\),

$$\begin{aligned} \phi ^{(i)}= & {} \phi ^{(0)} - \varDelta t \sum _{j=1}^{i} \left( a_{ij} \left( f_c(\phi ^{(j)}) - \epsilon ^2 \varDelta \phi ^{(j)} - \frac{1}{|\varOmega |} \left( f_c(\phi ^{(j)}), \mathbf{1} \right) \right) \right. \\&\left. - {{\hat{a}}}_{i,j-1} \left( f_e(\phi ^{(j-1)}) - \frac{1}{|\varOmega |} \left( f_e(\phi ^{(j-1)}), \mathbf{1} \right) \right) \right) , \end{aligned}$$

where \(a_{ij}\) and \({{\hat{a}}}_{i,j-1}\) are RK coefficients, and then

$$\begin{aligned} \phi ^{n+1} = \phi ^{(s)} \end{aligned}$$

by using the stiffly accurate condition. Using the resemble condition (\(a_{ij}={{\hat{a}}}_{i,j-1}=r_{ij}\)), we have the following s-stage high-order convex splitting scheme for Eq. (2):

$$\begin{aligned} \phi ^{(i)} = \phi ^{(0)} - \varDelta t \sum _{j=1}^{i} r_{ij} \left( f_c(\phi ^{(j)}) - \epsilon ^2 \varDelta \phi ^{(j)} - f_e(\phi ^{(j-1)}) - \beta ^{(j)} \right) , \end{aligned}$$
(4)

where

$$\begin{aligned} \beta ^{(i)} = \frac{1}{|\varOmega |} \left( f_c(\phi ^{(i)}) - f_e(\phi ^{(i-1)}), \mathbf{1} \right) \end{aligned}$$

for \(i=1,\ldots ,s\). Applying the convex splitting (3) to not only the term corresponding to the AC equation but also the Lagrange multiplier \(\beta \) yields the following theorem.

Theorem 1

The scheme (4) with \(r_{ii} \ge 0\) for \(i=1,\ldots ,s\) is uniquely solvable for any time step \(\varDelta t>0\). Moreover, the scheme is mass conserving.

Proof

Equation (4) can be rewritten as follows:

$$\begin{aligned} \phi ^{(i)} = \phi ^{(0)} - r_{ii} \varDelta t \left( f_c(\phi ^{(i)}) - \epsilon ^2 \varDelta \phi ^{(i)} - \frac{1}{|\varOmega |} \left( f_c(\phi ^{(i)}), \mathbf{1} \right) \right) - \varDelta t H^{(i)}, \end{aligned}$$

where

$$\begin{aligned} H^{(i)}= & {} r_{ii} \left( -f_e(\phi ^{(i-1)}) + \frac{1}{|\varOmega |} \left( f_e(\phi ^{(i-1)}), \mathbf{1} \right) \right) \nonumber \\&+ \sum _{j=1}^{i-1} r_{ij} \left( f_c(\phi ^{(j)}) - \epsilon ^2 \varDelta \phi ^{(j)} - f_e(\phi ^{(j-1)}) - \beta ^{(j)} \right) \end{aligned}$$
(5)

for \(i=1,\ldots ,s\). We consider the following functional for \(\phi \) defined in the constraint space \((\phi ,\mathbf{1})=(\phi ^{(0)},\mathbf{1})\),

$$\begin{aligned} {\mathcal {I}}(\phi ) = \frac{1}{2} \Vert \phi - \phi ^{(0)} \Vert ^2 + r_{ii} \varDelta t {{\mathcal {E}}}_c(\phi ) + \varDelta t \left( H^{(i)}, \phi \right) . \end{aligned}$$

From the convexity of \({{\mathcal {E}}}_c(\phi )\), it is easy to show that \({\mathcal {I}}(\phi )\) with \(r_{ii} \ge 0\) has a unique minimizer if and only if it solves

$$\begin{aligned} \left. \frac{d {\mathcal {I}} (\phi + \eta \psi )}{d\eta } \right| _{\eta =0}= & {} \left( \phi - \phi ^{(0)}, \psi \right) + r_{ii} \varDelta t \left( \frac{\delta {{\mathcal {E}}}_c(\phi )}{\delta \phi } , \psi \right) + \varDelta t \left( H^{(i)}, \psi \right) \nonumber \\= & {} \left( \phi - \phi ^{(0)} + r_{ii} \varDelta t \left( f_c(\phi ) - \epsilon ^2 \varDelta \phi \right) + \varDelta t H^{(i)}, \psi \right) = 0 \end{aligned}$$
(6)

for any \(\psi \) with \((\psi ,\mathbf{1})=0\). Since 1 is in the null space of the inner product with \(\psi \), the solution of (6) can be rewritten as follows:

$$\begin{aligned} \phi = \phi ^{(0)} - r_{ii} \varDelta t \left( f_c(\phi ) - \epsilon ^2 \varDelta \phi \right) - \varDelta t H^{(i)} + \chi \mathbf{1}. \end{aligned}$$

Using the constraint \((\phi ,\mathbf{1})=(\phi ^{(0)},\mathbf{1})\) and \(\left( \varDelta \phi , \mathbf{1}\right) = \left( H^{(i)}, \mathbf{1}\right) = 0\), we have \(\chi = \frac{r_{ii} \varDelta t}{|\varOmega |} \left( f_c(\phi ) , \mathbf{1}\right) \).

We close the whole proof of the theorm by justifing any solution of (4) satisfies the mass conservation. From Eq. (4), we have

$$\begin{aligned} \left( \phi ^{(i)} - \phi ^{(0)}, \mathbf{1} \right)= & {} - \varDelta t \sum _{j=1}^{i} r_{ij} \left( f_c(\phi ^{(j)}) - \epsilon ^2 \varDelta \phi ^{(j)} - f_e(\phi ^{(j-1)}) - \beta ^{(j)}, \mathbf{1} \right) \\= & {} - \varDelta t \sum _{j=1}^{i} r_{ij} \left( \left( f_c(\phi ^{(j)}) - f_e(\phi ^{(j-1)}), \mathbf{1} \right) - |\varOmega | \beta ^{(j)} \right) = 0, \end{aligned}$$

where \(\left( \varDelta \phi ^{(j)}, \mathbf{1} \right) = \int _{\partial \varOmega } \nabla \phi ^{(j)} \cdot \mathbf{n} \, ds - \int _\varOmega \nabla \phi ^{(j)} \cdot \nabla \mathbf{1} \, d\mathbf{x} = 0\) is given by the zero Neumann boundary condition for \(\phi ^{(j)}\). \(\square \)

Before proving the energy stability of the scheme (4), we define an \(s \times s\) matrix \(\mathbf{R}\) as \(\mathbf{R}_{ij} = r_{ij}\) for \(j \le i\) and \(\mathbf{R}_{ij} = 0\) for \(j > i\), and an \(s \times s\) matrix \({\widetilde{\mathbf{R}}}\) as \({\widetilde{\mathbf{R}}}_{ij} = {\tilde{r}}_{ij} = r_{ij} - r_{i-1,j}\) with \(r_{0j} = 0\).

Theorem 2

Suppose that \({\widetilde{\mathbf{R}}}\) is positive definite. The scheme (4) with \(r_{ii} \ge 0\) for \(i=1,\ldots ,s\) is unconditionally energy stable, meaning that for any \(\varDelta t > 0\),

$$\begin{aligned} {{\mathcal {E}}}(\phi ^{n+1}) \le {{\mathcal {E}}}(\phi ^n). \end{aligned}$$

Proof

From the convexity of \({{\mathcal {E}}}_c(\phi )\) and \({{\mathcal {E}}}_e(\phi )\), we have

$$\begin{aligned} {{\mathcal {E}}}(\phi ^{n+1}) - {{\mathcal {E}}}(\phi ^n)= & {} \sum _{i=1}^{s} \left( {{\mathcal {E}}}(\phi ^{(i)}) - {\mathcal E}(\phi ^{(i-1)}) \right) \\\le & {} \sum _{i=1}^{s} \left( f_c(\phi ^{(i)}) - \epsilon ^2 \varDelta \phi ^{(i)} - f_e(\phi ^{(i-1)}) , \phi ^{(i)} - \phi ^{(i-1)} \right) . \end{aligned}$$

Let \(\mu ^{(i)} = f_c(\phi ^{(i)}) - \epsilon ^2 \varDelta \phi ^{(i)} - f_e(\phi ^{(i-1)})\) for \(i=1,\ldots ,s\). Since \(\left( \phi ^{(i)}, \mathbf{1} \right) = \left( \phi ^{(0)}, \mathbf{1} \right) \) for \(i=1,\ldots ,s\) by Theorem 1, we obtain

$$\begin{aligned} {{\mathcal {E}}}(\phi ^{n+1}) - {{\mathcal {E}}}(\phi ^n)\le & {} \sum _{i=1}^{s} \left( \mu ^{(i)} - \beta ^{(i)} , \phi ^{(i)} - \phi ^{(i-1)} \right) + \sum _{i=1}^{s} \beta ^{(i)} \left( \mathbf{1} , \phi ^{(i)} - \phi ^{(i-1)} \right) \\= & {} -\varDelta t \sum _{i=1}^{s} \left( \mu ^{(i)} - \beta ^{(i)}, \sum _{j=1}^{i} (r_{ij}-r_{i-1,j}) (\mu ^{(j)}- \beta ^{(j)})\right. \\&\left. + r_{i-1,i} (\mu ^{(i)} - \beta ^{(i)}) \right) \\= & {} -\varDelta t \sum _{i=1}^{s} \left( \mu ^{(i)} - \beta ^{(i)}, \sum _{j=1}^{i} {\tilde{r}}_{ij} (\mu ^{(j)} - \beta ^{(j)}) \right) . \end{aligned}$$

Let \(\varvec{\nu }= (\mu ^{(1)} - \beta ^{(1)}, \ldots , \mu ^{(s)} - \beta ^{(s)})^T\). Since \({\widetilde{\mathbf{R}}}\) is positive definite,

$$\begin{aligned} {{\mathcal {E}}}(\phi ^{n+1}) - {{\mathcal {E}}}(\phi ^n) \le - \varDelta t \int _\varOmega \varvec{\nu }^T \, {\widetilde{\mathbf{R}}} \, \varvec{\nu }\, d\mathbf{x} \le 0. \end{aligned}$$

It follows that \({{\mathcal {E}}}(\phi ^{n+1}) \le {{\mathcal {E}}}(\phi ^n)\). \(\square \)

3 Numerical Experiments

3.1 Numerical Implementation

The s-stage high-order convex splitting scheme (4) can be rewritten as follows:

$$\begin{aligned} \phi ^{(i)} + r_{ii} \varDelta t \left( f_c(\phi ^{(i)}) - \epsilon ^2 \varDelta \phi ^{(i)} - \frac{1}{|\varOmega |} \left( f_c(\phi ^{(i)}), \mathbf{1} \right) \right) = \phi ^{(0)} - \varDelta t H^{(i)}, \end{aligned}$$
(7)

where \(H^{(i)}\) is defined in (5) for \(i=1,\ldots ,s\). The nonlinearity in Eq. (7) comes from \(f_c(\phi ^{(i)})\) and this can be handled using a Newton-type linearization [3, 12, 19, 25]

$$\begin{aligned} f_c(\phi ^{(i-1,m+1)}) \approx f_c(\phi ^{(i-1,m)}) + f_c'(\phi ^{(i-1,m)}) (\phi ^{(i-1,m+1)}-\phi ^{(i-1,m)}) \end{aligned}$$

for \(m=0,1,\ldots \). We then develop a Newton-type fixed point iteration method as

$$\begin{aligned}&\left[ \mathbf{I} + r_{ii} \varDelta t \left( f_c'(\phi ^{(i-1,m)}) - \epsilon ^2 \varDelta - \frac{1}{|\varOmega |} \left( f_c'(\phi ^{(i-1,m)}), \cdot \right) \right) \right] \phi ^{(i-1,m+1)} \nonumber \\&\quad = \phi ^{(0)} - \varDelta t H^{(i)} - r_{ii} \varDelta t \left( g(\phi ^{(i-1,m)}) - \frac{1}{|\varOmega |} \left( g(\phi ^{(i-1,m)}), \mathbf{1} \right) \right) , \end{aligned}$$
(8)

where \(\left( f_c'(\phi ^{(i-1,m)}), \cdot \right) \phi := \left( f_c'(\phi ^{(i-1,m)}), \phi \right) \), \(g(\phi ) := f_c(\phi ) - f_c'(\phi ) \phi \), and \(\phi ^{(i-1,0)} = \phi ^{(i-1)}\), and we set

$$\begin{aligned} \phi ^{(i)}=\phi ^{(i-1,m+1)} \end{aligned}$$

if a relative \(l_2\)-norm of the consecutive error \(\frac{\left\| \phi ^{(i-1,m+1)}-\phi ^{(i-1,m)} \right\| }{\left\| \phi ^{(i-1,m)} \right\| }\) is less than a tolerance tol. In this paper, the biconjugate gradient (BICG) method is used to solve the system (8) and we use the following preconditioner P to accelerate the convergence speed of the BICG algorithm:

$$\begin{aligned} P = \mathbf{I} + r_{ii} \varDelta t \left( - \epsilon ^2 \varDelta \right) . \end{aligned}$$

The stopping criterion for the BICG iteration is that the relative residual norm is less than tol.

Fig. 1
figure 1

Relative \(l_2\)-errors of \(\phi (x,3)\) using the first-, second-, and third-order schemes for \(16,24,\ldots ,256\) grid points and \(\varDelta t=2^{-6}, 2^{-5}, \ldots , 1\). Here, \(\epsilon =0.01\).

In order to have high-order time accuracy, unconditional unique solvability, and unconditional energy stability, it is required that \(r_{ii} \ge 0\) for \(i=1,\ldots ,s\) and \({\widetilde{\mathbf{R}}}\) is positive definite. To this end, we use the following matrices \(\mathbf{R}\) [26]:

$$\begin{aligned} \mathbf{R}= & {} \left( \, 1 \, \right) \quad \text {for the first-order scheme},\end{aligned}$$
(9)
$$\begin{aligned} \mathbf{R}= & {} \left( \begin{array}{rrr} \frac{2}{3} &{} \, 0 &{} \, 0 \\ -\frac{7}{12} &{} \, \frac{2}{3} &{} \, 0 \\ -\frac{1}{3} &{} \, \frac{2}{3} &{} \, \frac{2}{3} \end{array} \right) \quad \text {for the second-order scheme}, \end{aligned}$$
(10)

and

$$\begin{aligned} \mathbf{R} = \left( \begin{array}{cccccc} \frac{1}{2} &{} \, 0 &{} \, 0 &{} \quad 0\quad &{} \quad 0 \quad &{} \quad 0 \quad \\ \frac{1}{2} &{} \, \frac{1}{2} &{} \, 0 &{} \, 0 &{} \, 0 &{} \, 0 \\ -\frac{1}{10} &{} \, \frac{1}{10} &{} \, \frac{1}{2} &{} \, 0 &{} \, 0 &{} \, 0 \\ \tfrac{13252051}{50981620} &{} -\tfrac{100507933}{407852960} &{} \tfrac{19290953}{81570592} &{} \, \frac{1}{2} &{} \, 0 &{} \, 0 \\ \tfrac{401851541}{5098162000} &{} -\tfrac{20327867}{637270250} &{} -\tfrac{200790581}{1019632400} &{} \, \frac{1}{20} &{} \, \frac{1}{2} &{} \, 0 \\ \tfrac{3217}{14300} &{} -\tfrac{703}{7150} &{} -\tfrac{6359}{42900}&{} -\tfrac{4556}{10725} &{} \tfrac{406}{429} &{} \, \frac{1}{2} \\ \end{array} \right) \end{aligned}$$
(11)

for the third-order scheme. The positive definiteness of \({\widetilde{\mathbf{R}}}\) is easily seen by showing eigenvalues of \(\frac{1}{2} ({\widetilde{\mathbf{R}}} + {\widetilde{\mathbf{R}}}^T)\) are all positive. The eigenvalues of \(\frac{1}{2} ({\widetilde{\mathbf{R}}} + {\widetilde{\mathbf{R}}}^T)\) are 1 for (9), \(\frac{2}{3} - \frac{\sqrt{26}}{8}\), \(\frac{2}{3}\), and \(\frac{2}{3} + \frac{\sqrt{26}}{8}\) for (10), and approximately 0.0063, 0.1105, 0.3582, 0.5722, 0.9225, and 1.0303 for (11). We note that the matrices \(\mathbf{R}\) are available up to order 3 and the existence of the matrix \(\mathbf{R}\) of order higher than 3 is an open question.

And we use the Fourier spectral method [19, 25] for the spatial discretization and the discrete cosine transform in MATLAB is applied for the whole numerical simulations to solve the CAC equation with the zero Neumann boundary condition.

3.2 Convergence Test

We demonstrate the convergence of the proposed schemes with an initial condition

$$\begin{aligned} \phi (x,0) = 0.02\cos (4\pi x)+0.04\cos (7\pi x) \end{aligned}$$

on \(\varOmega =[0,1]\). We set \(\epsilon =0.01\) and \(tol = 10^{-8} \varDelta t\), and compute \(\phi (x,t)\) for \(0 < t \le 10\). In order to show spatial accuracy of the numerical solution, simulations are performed by varying the number of grid points \(16,24,\ldots ,256\). Figure 1 shows the relative \(l_2\)-errors of \(\phi (x,3)\) using the first-, second-, and third-order schemes for various numbers of grid points and time steps. Here, the errors are computed by comparison with the numerical solution using the third-order scheme, 512 grid points, and \(\varDelta t = 2^{-8}\). As we can see in Fig. 1, the spatial convergence of the scheme under grid refinement is evident and 128 grid points (\(\varDelta x=\frac{1}{128}\)) give sufficient spatial accuracy.

Fig. 2
figure 2

a Evolution of \({{\mathcal {E}}}(t)\) for the reference solution with \(\epsilon =0.01\) and \(\varDelta x=\frac{1}{128}\). b Relative \(l_2\)-errors of \(\phi (x,3)\) for \(\varDelta t=2^{-6}, 2^{-5}, \ldots , 1\)

Fig. 3
figure 3

Evolution of \(\int _\varOmega (\phi (x,t)-\phi (x,0)) \, dx\) using the first-, second-, and third-order schemes with different time steps

Fig. 4
figure 4

Number of nonlinear and BICG iterations for the first-, second-, and third-order schemes with different time steps

Next, to estimate the convergence rate with respect to \(\varDelta t\), simulations are performed by fixing \(\varDelta x=\frac{1}{128}\) and varying \(\varDelta t=2^{-6}, 2^{-5}, \ldots , 1\). We take the quadruply over-resolved numerical solution using the third-order scheme as the reference solution. Figure 2a, b show the evolution of \({{\mathcal {E}}}(t)\) for the reference solution and the relative \(l_2\)-errors of \(\phi (x,3)\) (this time is indicated by a dashed line in Fig. 2a) for various time steps, respectively. Here, the errors are computed by comparison with the reference solution. And Fig. 3 shows the evolution of \(\int _\varOmega (\phi (x,t)-\phi (x,0)) \, dx\) using the first-, second-, and third-order schemes with different time steps. It is observed that the proposed scheme gives desired order of accuracy in time and conserves the total mass.

And, to show the robustness of the nonlinear solver, we count the number of nonlinear and BICG iterations (see Fig. 4). Here, we regard the number of BICG iterations at each time level as the averaged number of BICG iterations for the nonlinear iterations at each time level. For the first-order scheme, 2–5 nonlinear iterations were involved in proceeding to the next time level and we believe that such a fast iterative convergence can be achieved since the successive iteration (8) is a Newton-type fixed point iteration method. And numbers of nonlinear iterations of the (three-stage) second- and (six-stage) third-order schemes are about three and six times more than that of the (one-stage) first-order scheme, respectively. These results indicate that the number of nonlinear iterations is almost linear with respect to the number of stages. Furthermore, the BICG algorithm converges in a small number of iterations by using the preconditioner.

Fig. 5
figure 5

Evolution of \({{\mathcal {E}}}(t)\) using the first-, second-, and third-order schemes with different time steps

Fig. 6
figure 6

Evolution of \(\phi (x,y,t)\) using the third-order scheme with \(\epsilon =0.01\), \(\varDelta x=\varDelta y=\frac{1}{128}\), and \(\varDelta t=t_f/2^{15}\)

Fig. 7
figure 7

Evolution of \(\phi (x,y,z,t)\) and \({{\mathcal {E}}}(t)\) using the third-order scheme with \(\epsilon =0.01\), \(\varDelta x=\varDelta y=\varDelta z=\frac{1}{64}\), and \(\varDelta t=\frac{1}{4}\). In each snapshot, the yellow, green, and blue regions indicate \(\phi =0.3\), 0, and \(-0.3\), respectively

3.3 Energy Stability of the Proposed Scheme

In order to investigate the energy stability of the proposed scheme, we take an initial condition as

$$\begin{aligned} \phi (x,y,0)= & {} 0.9 \left( 1 + \tanh \left( \frac{0.1-\sqrt{(x-0.25)^2+(y-0.25)^2}}{\sqrt{2} \epsilon } \right) \right. \\&\left. + \tanh \left( \frac{0.15-\sqrt{(x-0.57)^2+(y-0.57)^2}}{\sqrt{2} \epsilon } \right) \right) + \text {rand} \end{aligned}$$

on \(\varOmega =[0,1] \times [0,1]\), where \(\text {rand}\) is a random number between \(-0.1\) and 0.1 at the grid points. We use \(\epsilon =0.01\), \(\varDelta x=\varDelta y=\frac{1}{128}\), and \(tol=10^{-10}\), and compute \(\phi (x,y,t)\) for \(0 < t \le t_f=300\). Figure 5 shows the evolution of \({{\mathcal {E}}}(t)\) using the first-, second-, and third-order schemes with different time steps. All the energy curves are nonincreasing in time even for sufficiently large time steps. Figure 6 shows the evolution of \(\phi (x,y,t)\) using the third-order scheme with \(\varDelta t=t_f/2^{15}\).

3.4 Spinodal Decomposition

We simulate the spinodal decomposition on \(\varOmega =[0,1] \times [0,1] \times [0,1]\) with \(\epsilon =0.01\), \(\varDelta x=\varDelta y=\varDelta z=\frac{1}{64}\), \(\varDelta t=\frac{1}{4}\), \(tol=10^{-10}\), and the third-order scheme. An initial condition is \(\phi (x,y,z,0)=\text {rand}\), where \(\text {rand}\) is a random number between \(-0.1\) and 0.1 at the grid points. Figure 7 shows the evolution of \(\phi (x,y,z,t)\) and \({{\mathcal {E}}}(t)\). We observe that the randomly perturbed homogeneous state evolves to many small structures and then to an irregular and interconnected structure as the energy is dissipated in time.

4 Conclusions

We developed first-, second-, and third-order energy stable schemes for the CAC equation with a nonlocal Lagrange multiplier by applying the convex splitting to not only the term corresponding to the AC equation but also the Lagrange multiplier, and employing the specially designed implicit–explicit RK tables. As a result, the schemes were mass conserving, accurate, unconditionally uniquely solvable, and unconditionally energy stable. We confirmed that the proposed schemes give desired order of accuracy in time and are unconditionally energy stable. And we performed the long time simulation for the phase separation process.