High-Order Finite Difference Method for Helmholtz Equation in Polar Coordinates ()
1. Introduction
Helmholtz equation has attracted much attention in many fields such as electromagnetic cavity scattering problems [1] , wave propagation [2] and acoustic problems [3] . Many methods have been proposed to solve the Helmholtz equation in general Cartesian coordinates, such as finite difference method [4] , finite element method [5] and other methods [6] . This equation is important for both theory and applications. Its theoretical significance has a variable coefficient under the first derivative, which renders the existing fourth-order compact finite difference methods inapplicably. From the standpoint of applications, the Helmholtz equation in polar coordinates appears in many scattering problems.
In general Cartesian coordinates, high-order methods for solving the Helmholtz equation have been well developed since the accuracy is related to the amount of the grid points with the wave number increases. Manohar et al. [7] proposed second- and sixth-order finite difference schemes for solving the Helmholtz equation which requires the derivatives and much computational cost. Nabavi et al. [8] further developed a compact nine-point sixth-order finite difference scheme and obtained a sixth-order approximation for the Neumann boundary condition. Sutmann [9] developed a new compact sixth-order finite difference scheme of sixth-order for three-dimensional Helmholtz equations.
In polar coordinates, the symmetric problem can be described more concisely. A finite difference method was proposed to solve the parabolic equation in polar coordinates in [10] . Britt et al. [11] constructed a high-order compact difference scheme for the Helmholtz equation. Su et al. [12] proposed a fourth-order method for solving Helmholtz equation with discontinuous wave number and Dirichlet boundary condition. A novel compact scheme based on finite difference discretizations and geometric grid has been developed to solve two-dimensional mildly non-linear elliptic equations in polar co-ordinate constituting singular terms [13] .
The existed works didn’t discuss the Neumann boundary condition and the sparsity of the coefficient matrix. In this paper, we develop a fourth-order scheme for the Helmholtz equation in polar coordinates with Dirichlet and Neumann boundary conditions. The sparse matrix form of the linear system is derived. With the help of the sparsity of the coefficient matrix of the linear system, the computational cost is remarkably reduced. Moreover, we give the approximation for the Neumann boundary condition. The feasibility and the order of method are verified by the Helmholtz equation with Dirichlet and Neumann boundary condition.
The paper is outlined as follows. In Section 2, a fourth-order finite difference scheme and the sparse matrix form for the Helmholtz equation in polar coordinates are derived. In Section 3, the approximation for the boundary condition is obtained. Two numerical experiments of the high-order algorithm are presented in Section 4. The paper is concluded in Section 5.
2. Fourth-Order Finite Difference Scheme
2.1. Fourth-Order Approximation
We consider the following two-dimensional Helmholtz equation in polar coordinates
(1)
where k is the wave number, D is a given region and f is a known function. For convenience, we rewrite the above equation as
(2)
(3)
Define a uniform mesh on the region
.
,
.
denotes the fourth-order solution of u at point
.
First, we employ a fourth-order approximation on the left side of Equation (2) and obtain
(4)
where
Then approximating the derivatives of u with the second-order accuracy by central differences, we have
(5)
By substituting Equation (5) into Equation (4), we can obtain a nine-point stencil approximation for
.
We now turn to the fourth-order approximation for the left side of Equation (3). Applying a standard central difference operator to the left item of Equation (3), we have
(6)
and the error
(7)
Differentiating both sides of (3) with respect to
and combing (7), we have
(8)
Similarly, all derivatives of
with respect to
can be approximated as follows
(9)
By substituting Equation (9) into Equation (8), the fourth-order finite difference scheme for
is obtained.
Therefore, combing Equation (4) and Equation (8), we have the overall fourth-order finite difference form for the Helmholtz equation in polar coordinates
(10)
Replacing the derivatives of
and
by Equations (5) and (9), we can derive
(11)
For simplicity, we rewrite the above Equation (11) in the following form
(12)
where
2.2. The Sparse Matrix Form of the Scheme
The relationship between the nine points can be illustrated in three parts in matrix form
, which represent the horizontal, vertical, diagonal relationships respectively,
(13)
where
and
denotes the Kronecker product,
is the
identity matrix. F is the right side item containing
and the boundary conditions which will be discussed in the following section.
3. Boundary Condition
Implementation of Dirichlet boundary conditions at
,
is straightforward. And the right side item of Equation (13) can be written as
(14)
where
and
are vectors in
dimensions.
Implementation of the Dirichlet boundary conditions at
,
is more complicated. We consider the following Neumann boundary condition and it can be extended to the general cases
(15)
where
is a constant,
is a given function.
The ghost points are utilized to derive the difference scheme on the boundary can be written as
(16)
Therefore, the Neumann boundary condition can be approximated as
(17)
We can obtain
(18)
where
(19)
Substituting j for
in Equation (12) gives
(20)
where
Combining Equations (18) and (20), we can eliminate
and obtain
(21)
Therefore, collaborating Equations (13) and (21), the global system can be written as follows
(22)
where
We can observe the sparsity of the global system of the Helmholtz equation with the Neumann boundary condition in Figure 1.
4. Numerical Experiments
4.1. Example 1
We first consider the problem with Dirichlet boundary condition in polar coordinates as follows
(23)
and the exact solution is
.
As we can see from Figure 2 and Figure 3, the numerical solution derived by the proposed method is highly consistent with the exact solution. Moreover, we depict the numerical solution in Cartesian coordinates in the right side of Figure 3. Furthermore, in order to test the computational order of the proposed method, we give the error between the numerical solution and the exact solution with different grid points and k in Table 1 and Table 2. The order is calculated by the following equation
It can be clearly seen from Table 1 and Table 2 that the finite difference scheme can reach the fourth-order when the wavenumber k is relatively small. As the mesh is refined and the number of grid points increases, the error becomes smaller and the accuracy tends to be fourth-order and gradually stabilized. When the wavenumber k increases, the error becomes oscillatory. Table 3
Figure 1. The sparsity of the global system with Neumann boundary condition.
Figure 2. The numerical solution (left) and the exact solution with
and
.
Figure 3. The error inside the region (left) and the numerical solution in Cartesian coordinates (right) with
and
.
Table 1. The errors and order of the proposed method with
and
.
Table 2. The errors and order of the proposed method with
and
.
Table 3. Computational time (s) for solving the Helmholtz equation with
.
gives the comparison of the computational time(s) for solving the Helmholtz equation in polar coordinates, where Method I and Method II denote methods with and without the utilization of the sparsity of the coefficient matrix of the linear system. It can be observed that with the help of the sparsity of the coefficient matrix of the linear system, the computational cost is remarkably reduced.
4.2. Example 2
This example is a Helmholtz equation in polar coordinates with Neumann boundary condition
(24)
and the exact solution is
. As we can see from Figures 4-6 that the
Figure 4. The numerical solution (left) and the exact solution with
and
.
Figure 5. The error inside the region (left) and the error on the top boundary (right) with
and
.
Figure 6. The numerical solution in Cartesian coordinates.
numerical solution is well agreed with the exact solution with
and
.
5. Conclusion
In this paper, we propose a high-order fast algorithm for solving the two-dimensional Helmholtz equation with Dirichlet and Neumann boundary conditions in polar coordinates. We develop a fourth-order accurate compact finite difference approximation to the Helmholtz equation. The sparse matrix form for the Helmholtz equation in polar coordinates is obtained which improves the efficiency for the computation process. Two numerical experiments have demonstrated the validity of the fourth-order algorithm.
Acknowledgements
This research was supported by the Fundamental Research Funds for the Central Universities (No. 2018MS129).