Abstract
In this paper, we present a simple and accurate adaptive time-stepping algorithm for the Allen–Cahn (AC) equation. The AC equation is a nonlinear partial differential equation, which was first proposed by Allen and Cahn for antiphase boundary motion and antiphase domain coarsening. The mathematical equation is a building block for modelling many interesting interfacial phenomena such as dendritic crystal growth, multiphase fluid flows, and motion by mean curvature. The proposed adaptive time-stepping algorithm is based on the Runge–Kutta–Fehlberg method, where the local truncation error is estimated by using fourth- and fifth-order numerical schemes. Computational experiments demonstrate that the proposed time-stepping technique is efficient in multiscale computations, i.e., both the fast and slow dynamics.
1. Introduction
We present a simple and accurate adaptive time-stepping algorithm for the Allen–Cahn (AC) equation [1–3]: where is a bounded domain, is a compositional field, , and is a positive constant. The AC equation can be derived as the -gradient flow of the following Ginzburg–Landau energy functional:
The AC equation was first proposed by Allen and Cahn, which was introduced as a phenomenological model for antiphase domain coarsening in a binary alloy. The AC equation and its various modified equations are used to deal with a wide range of problems, such as its phase transition [1], motion by mean curvature [4, 5], image study [6, 7], two-phase fluid flows [8], and crystal growth [9, 10]. To understand the dynamics of the AC equation and apply it to model scientific phenomena, it is essential to develop effective and accurate numerical methods for the AC equation. In general, if we use a small uniform time step, then the fast dynamics can be accurately captured. However, the computational cost is high. On the other hand, if we use a large time step, then we can save the computational cost with less accurate numerical results.
Therefore, an adaptive time-stepping technique is needed in numerical simulations of the AC equation because it has multiple time scales. There are several studies on time stepping [11, 12]. In [13], the author presented the high-order time-adaptive method for solving the AC equation and showed the computational superiority that traditional methods do not have in solving the equation. Guillén-González and Tierra [14] developed an adaptive time-stepping technique based on a residual of the discrete energy law at each time step. Its fastness and efficiency were confirmed through various numerical experiments. Fu and Yang [15] presented an example of using adaptive time stepping to show unconditional energy stability. Fast and efficient computing results are slightly different from the result using one small time step. Karasözen et al. [16] studied the numerical solutions of the AC equation with constant or degenerate mobility and polynomial or logarithmic free energy function. To reduce computational time, an adaptive time step size method was applied, which is based on a local error estimator. They used the backward Euler method and the second-order average vector field (AVF) method to compute the local error estimator. Liao et al. [17] presented a second-order backward differentiation formula (BDF2) with a variable time step for the AC equation. In [18], the author obtained a solution for the time-dependent AC equation on surfaces using an explicit time splitting scheme. An adaptive finite element method (FEM) for the AC equation was developed in [19], which is based on a second-order accurate unconditionally stable FEM and a superconvergent cluster recovery- (SCR-) based error estimation. To show the effectiveness and robustness of their proposed method, various numerical tests were carried out. In [20, 21], the implicit integration factor (IIF) type methods were employed to numerically solve the space-fractional reaction-diffusion equations including the AC equation. Zhu [22] developed stable and effective exponential Runge–Kutta methods for parabolic equations such as the AC equation, which is easy to adopt the adaptive time step technique.
The adaptive time-stepping strategy has also been applied to the modified AC equations. Fast explicit operator splitting spectral method was presented with a new adaptive time-stepping algorithm to solve the fractional nonlocal AC equation [23]. The fractional-in-space phase-field models were addressed including the AC equation in [24], applying the implicit-explicit (IMEX) methods as temporal discretization. With the adaptive time-stepping algorithm based on the difference between the first-order and second-order IMEX methods, they reduced the computational costs. Recently, the adaptive time-stepping strategy was also applied to the second-order maximum principle preserving scheme and was proposed to solve the time-fractional AC equations in [25]. In particular, the strategy is chosen to capture the early rapid changes in the performance of long-term simulations. In [26], thanks to these advantages, the adaptive time-stepping strategy was adopted considering two fast time-stepping methods for the time-fractional AC equation. Moreover, the authors [27] proposed a variable time step BDF2 scheme for the fractional AC equation, which is energy stable and preserves maximum bound. Therefore, it is proved that the adaptive time-stepping algorithm is useful when we consider the local or nonlocal AC equations. In addition, there are many existing works on the adaptive time stepping for a variety of local and nonlocal phase-field models: the Cahn–Hilliard equation [28], molecular beam epitaxy (MBE) model [29, 30], phase-field crystal model [31], and so on.
The main purpose of the paper is to propose a simple and accurate adaptive time-stepping algorithm for the AC equation. Our proposed algorithm is based on the Runge–Kutta–Fehlberg (RKF) method [32], where the fourth- and fifth-order numerical schemes are used for the local truncation error estimation.
The contents of this paper are summarized as follows. In Section 2, the proposed numerical solution algorithm is presented. In Section 3, numerical results using the proposed method are shown. Conclusions are made in Section 4.
2. Numerical Solution
For simplicity of notation, we rewrite Equation (1) as where . In this section, we describe the AC equation in a three-dimensional domain . Let us discretize the domain by a regular Cartesian grid with spatial step , where , , and are positive integers. That is, . Let be the approximation of , where is a time step, is the final time, is the total number of time steps, and is a nonnegative integer. We define the discrete maximum norm as
To solve Equation (3), we adopt an explicit RKF method. Due to the explicit scheme, the linear term in the AC Equation (1) restricts the time step for stability of the numerical solution as , where is spatial dimension. However, the time step restriction is not severe in the case of the second-order partial differential equations, and sufficiently small time steps should be taken for numerical solutions with higher accuracy [33, 34]. Therefore, we take as the maximum time step size. Let be the discrete AC operator, where . Here, the homogeneous Neumann boundary condition [35] is used. Given final time , tolerance , current time , time step , and numerical solution at , the RKF method is as follows. The computation for the numerical solution is repeated for and . Let us define the coefficient equations:
Let be an approximation for the local truncation error of the RKF method. The detailed explanation of the coefficient calculation, i.e., , and the local truncation error given by Equation (6) can be found in [36].
If , then set and
Otherwise, i.e., , then we do not update time and repeat the computation using a new time step. To bound truncation error produced by applying the th-order method with a new time step size by , we choose so that [36], that is,
Then, we can take satisfying (8) with as follows:
Next, we set a new time step as follows:
Finally, we set , and if , then set .
3. Numerical Results
In this section, numerical experiments in two- and three-dimensional (2D and 3D) spaces are performed to confirm the basic properties of the AC equation and to investigate the effect of the adaptive time-stepping technique.
3.1. Shrinking Circle and Sphere
As , the zero level set of moves according to motion by mean curvature [5]. Given a circle in 2D space and a sphere in 3D space, we observe that their radii decrease over time. First, we consider a circle with the initial radius . The radius is the analytic solution at time [33]. The initial condition is given as on the computational domain with mesh. The space step size , -, and an initial radius are used. We consider the effects of grid sizes and on the dynamics of the AC equation. Figure 1(a) shows the zero level contours with and . Here, the arrow indicates the direction of temporal evolution. Figure 1(b) shows the temporal evolution of the radius with different grid sizes up to time . Here, is fixed. As the number of grid points increases, we can observe the convergence of the numerical solutions to the analytic solution . Figure 1(c) shows the temporal evolution with different values of . Here, are used and the final time is . As shown in Figure 1(c), too small and too large values of decreases and increases the evolution of the interface, respectively. This is because the numerical spatial resolution is too low and the curvature is too large to capture the detailed structure compared to .

(a)

(b)

(c)
We conduct the similar simulation with a sphere in 3D space. Let be the initial radius of the sphere, then the radius is the analytic solution at time [33]. The initial condition is given as on the computational domain with mesh. The space step size , -, and the initial radius are used. Figures 2(a)–2(c) show the temporal evolution of sphere with and . Figure 2(d) represents the effect of grid size. Here, value is fixed to . It is observed that the larger grid size, the closer the numerical solution is to the analytic solution. Figure 2(e) illustrates the effect of value on the dynamics of the AC equation. Here, are used, and the numerical solution with agrees well with the analytic solution.

(a)

(b)

(c)

(d)

(e)
3.2. Comparison with Previous Results
In this section, we compare our numerical results with previous studies for the AC equation [37]. We consider a square shape as an initial condition, on 2D domain with and homogeneous Neumann boundary conditions on the boundaries of domain . Figure 3 shows snapshots in 2D with square shape as initial condition (13) at time , , , and from left to right. The initial square shape transforms into a circular shape over time under the effect of the AC equation dynamics. Then, we compute the shrinking area of due to the motion by mean curvature and compare it with the theoretical area using the solution at a reference time . We can find theoretical area using analytic solution [33]. We obtain reference area and reference radius at as

(a)

(b)

(c)

(d)
Using , we obtain theoretical area as . Figure 4 compares the theoretical area with numerical one. From the computational results as shown in Figures 3 and 4, our test results are accurate and consistent with the results from the reference test [37].

3.3. Traveling Wave Solutions
Let us consider traveling wave solutions of Equation (1) with an initial condition on 2D domain . Then, its closed-form solution on the infinite domain is where is the speed of the traveling wave [38]. Figure 5 shows the initial condition (dotted line); and the computational results with -, -, and - with the exact solution at time . Here, , , and are used. In this case of the traveling wave solution, the results are almost independent of the tolerance values because it has simple unique time scale.

3.4. Effect of
Let us consider the effect of on the size of the time step. The initial conditions are on the domain . We use , , and . Figure 6(a) shows the temporal evolution of the zero level contours of with -. Numerical tests are conducted to observe the changes in the time step over time as shown in Figure 6(b) according to the different tolerance values . When a relative large tolerance is used, the time step is except the early times where there are sharp corners. However, when a small tolerance is used, the time step varies adaptively. It takes small time steps at not only the early times but also the later times with large curvature of interface. Figure 6(d) shows the temporal evolution of the discrete total energy with different tolerance values. We can confirm the total energies decrease for all cases. Here, the discrete total energy is defined as where and we have used the homogeneous Neumann boundary condition. In Figure 6(d), the maximum and minimum values of are given. It is observed that the numerical solutions are bounded in .

(a)

(b)

(c)

(d)
Next, we consider another initial condition with the same parameters and domain as the above test:
With -, the zero level contours of over time are shown in Figure 7(a). As mentioned above, according to the property of the AC equation called motion by mean curvature, the evolution is fast for large curvatures, i.e., small radii. On the other hand, for large radii, curvatures are small and their evolution is slow. In Figure 7(b), the changes in the time step are shown with different tolerance values. Figures 7(c) and 7(d) show the discrete total energy and the maximum and minimum values of according to different tolerance values, respectively. Therefore, the total energies decrease and the numerical solutions are bounded in . In addition, in Figure 7(d), we compare the numerical results obtained from the proposed method and an explicit Euler method with . Both are explicit methods; however, when adopting the proposed method, we can use a slightly larger than the explicit Euler method. Let us assume that the initial condition (19) is given with a single time step, not the adaptive time step. With a large time step, we might miss capturing fast dynamics, whereas using a small time step to capture the fast dynamics is inefficient in terms of overall computational cost. For this reason, therefore, our proposed method using multitime steps has an advantage.

(a)

(b)

(c)

(d)
3.5. Shrinking Spirals
We simulate a shrinking test with a 2D spiral shape. Figure 8(a) shows the initial condition which is a spiral shape expressed as a filled zero contour in 2D. The initial value of is in the inside of spiral and otherwise on the computational domain . Other parameters are , , and . In Figures 8(a)–8(d), the results show the phenomenon that the interface is evolved according to the motion by mean curvature. From left to right, the evolutionary times are and . Here, we set -. Figure 8(e) shows the temporal evolution of the adaptive time step sizes according to three different tolerance -, -, and -.

(a)

(b)

(c)

(d)

(e)
Next, we make a 3D spiral shape on the computational domain and simulate a similar shrinking test. The initial condition is shown in Figure 9(a). Initial value of is defined as in the inside of the spiral and otherwise . We use the parameters as , , and . Figures 9(b)–9(d) illustrate that the spiral shape is shrinking by motion by mean curvature. Here, -. Figure 9(e) shows the temporal evolution of the adaptive time step sizes according to three different tolerance -, -, and -.

(a)

(b)

(c)

(d)

(e)
4. Conclusion
In this study, we presented a simple and accurate adaptive time-stepping algorithm for the AC equation. The proposed adaptive time-stepping algorithm was based on the Runge–Kutta–Fehlberg method, where the local truncation error was estimated using fourth- and fifth-order numerical schemes. Computational experiments demonstrated that the proposed time-stepping technique was efficient in multiscale computations, i.e., both the fast and slow dynamics. In future work, we will apply finite element version such as [39].
Data Availability
All the data used to support the findings of this study are available from the corresponding author upon request.
Conflicts of Interest
The authors declare that there are no conflicts of interest regarding the publication of this paper.
Acknowledgments
The corresponding author (J. Kim) expresses thanks for the support from the BK21 FOUR program.