Next Article in Journal
A Fuzzy Random Survival Forest for Predicting Lapses in Insurance Portfolios Containing Imprecise Data
Next Article in Special Issue
Generalized Thermoelastic Interaction in Orthotropic Media under Variable Thermal Conductivity Using the Finite Element Method
Previous Article in Journal
Are COVID-19-Related Economic Supports One of the Drivers of Surge in Bitcoin Market? Evidence from Linear and Non-Linear Causality Tests
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Approximate Solution of Two Dimensional Disc-like Systems by One Dimensional Reduction: An Approach through the Green Function Formalism Using the Finite Elements Method

by
Alejandro Ferrero
1,* and
Juan Pablo Mallarino
2
1
Departamento de Ciencias Básicas, Universidad Católica de Colombia, Bogotá 110231, Colombia
2
Facultad de Ciencias—Laboratorio Computacional HPC, Universidad de los Andes-Bogotá, Bogotá 111711, Colombia
*
Author to whom correspondence should be addressed.
Mathematics 2023, 11(1), 197; https://doi.org/10.3390/math11010197
Submission received: 17 October 2022 / Revised: 5 November 2022 / Accepted: 9 November 2022 / Published: 30 December 2022
(This article belongs to the Special Issue Recent Advances in Finite Element Methods with Applications)

Abstract

:
We present a comprehensive study for common second order PDE’s in two dimensional disc-like systems and show how their solution can be approximated by finding the Green function of an effective one dimensional system. After elaborating on the formalism, we propose to secure an exact solution via a Fourier expansion of the Green function, which entails solving an infinitely countable system of differential equations for the Green–Fourier modes that in the simplest case yields the source-free Green distribution. We present results on non separable systems—or such whose solution cannot be obtained by the usual variable separation technique—on both annulus and disc geometries, and show how the resulting one dimensional Fourier modes potentially generate a near-exact solution. Numerical solutions will be obtained via finite differentiation using Finite Difference Method (FDM) or Finite Element Method (FEM) with the three-point stencil approximation to derivatives. Comparing to known exact solutions, our results achieve an estimated numerical relative error below 10 6 . Solutions show the well-known presence of peaks when r = r and a smooth behavior otherwise, for differential equations involving well-behaved functions. We also verified how the Green functions are symmetric under the presence of a “weight function”, which is guaranteed to exist in the presence of a curl-free vector field. Solutions of non-homogeneous differential equations are also shown using the Green formalism and showing consistent results.

1. Introduction

In the present work, we elaborate on the FEM for solving complex two-dimensional partial differential equations (DE) using a Green function construction. Green’s method has been employed extensively in physics for solving Laplace’s equation and associates in a cornucopia of areas, such as Quantum and Statistical Mechanics. In quantum mechanics, for example, the method of non-equilibrium Green’s functions (NEGF) has been used to study the Brownian motion of a quantum oscillator [1], quantum thermal transport [2,3], electron transport through single and two levels of interacting quantum dot [4], derive quantum kinetic equations [5,6], study hadronic physics [7], among others. In statistical mechanics, some of the applications of the Green functions include the predictions of some observables [8], help to describe 1D hydrodynamic models [9], finding electrical properties of some physical systems [10,11], study non-extensive statistical mechanics with new normalized q-expectation values [12], as well as time- and ensemble-average statistical mechanics of the Gaussian network model [13], and so much more. Even the Green functions are used in quantum field theory to describe the propagators of quantum fields in the perturbative regime.
Not only are Green functions useful to solve systems described by inhomogeneous differential equations, but they can also be used to describe thermodynamic properties. For instance, the density and correlations of particles immersed in two-dimensional two component plasmas at certain temperatures can be described by sets of Green functions [14,15,16]. The calculation of the energy gap in the one-dimensional Hubbard model can also be approached by means of the Green function formalism [17]. From a mathematical and more fundamental perspective, the Green functions and domains with uniformly rectifiable boundaries of all dimensions have been approximated [18]; an analysis of extra critical points of Green functions on Flat Tori has also been performed, in which their minimality has been emphazised [19].
In order to study how an inhomogenous partial DE can be solved by the method we propose, we start defining a differential operator
L ^ { r } = ( { r } + f ( r ) ) · ( { r } ) + g ( r ) ,
acting on a scalar field, denoted by □, in R d , with d the dimension of the system—i.e., r R d . This operator is known in other contexts as the Liouville operator; via this definition, we often describe the evolution of a relevant quantity ψ by means of the equation t ψ ( r , t ) L ^ ψ ( r , t ) = 0 as it is the case of the wave function in quantum mechanics. For example, in the diffusion phenomenon the functions take the form f ( r , t ) = D ( r , t ) and g ( r ) = 0 , and for the Helmholtz equation f ( r , t ) = 0 and g ( r ) = m 2 , with m a constant.
Finding solutions to the latter has motivated the development of numerical methods that grow in number and complexity. For instance, using Restricted Boltzmann Machines we can engineer an artificial neural network that is able to accurately sample the probability distribution for quantum statistical systems [20,21]. However, some effort can be made from a mathematical point of view prior to implementing a full scale numerical calculation.
Green’s function—or more precisely, distribution—is perhaps the most interesting artifact of a huge bag of tricks that we have when facing differential equations. Its power relies on the possibility of inverting the differential operator L ^ to solve the inhomogeneous equation
L ^ ψ ( r ) = ϕ ( r ) ,
with ψ ( r ) and ϕ ( r ) two scalar functions. Hinting that its existence, the Green Distribution, is conditioned by some properties of L ^ .
A disadvantage of the Green methodology is the duplication of degrees of freedom, encouraging researchers to find ψ ( r ) directly. Our aim is not to develop a generalized theory for an arbitrary problem and number of dimensions. Despite this, we can look into the consequences of breaking down one dimension by focusing on the simple two-dimensional case.
Two-dimensional systems are of great interest in statistical mechanics [14,15,16], material sciences [22,23,24], quantum computing [25,26], high-energy physics [27,28], ionic fluids [29], theoretical mathematics [30,31], and many others.
The outline of the paper is as follows. We first remind some relevant known results for the Green’s function construction in Section 2 prior to presenting the strategy to move from 2D to 1D in Section 2.4. We lay out a clever geometric interpretation of the result in Section 2.1 followed by a connection to a relevant theory for Hilbert Space functions in Section 2.3. Consequently, we next discuss its implications towards finding the Green function using FDM in Section 3. We then present some mathematical results that include the solution of certain well known systems for testing purposes and the implementation of the method in a non-separable 2D system in Section 4; a discussion of such results and an explanation of how the algorithm can be adapted to solve the heat diffusion problem in thermal equilibrium is stated in Section 5. Finally, we wrap up the conclusions in Section 6. Intermediate calculations and numerical details are left for further inspection in appendices.

2. Framework and Methodology

We start studying the Green function formalism by postulating the convolution identity from the Dirac distribution,
ψ ( r ) = r ψ ( r ) δ ( r r ) w ( r , r ) d r ,
with w ( r , r ) a weight function properly defined by two conditions; the first of which w ( r , r ) = 1 . Now by defining G ( r , r ) as,
L ^ { r } G ( r , r ) = δ ( r r ) ,
with δ ( r r ) = δ ( r r ) the R d Dirac delta distribution, then,
ψ ( r ) = r ψ ( r ) L ^ { r } G ( r , r ) w ( r , r ) d r .
The second condition over w ( r , r ) will be determined in such a way that L ^ is self-adjoint (Hermitian), or equivalently
r ψ ( r ) L ^ { r } G ( r , r ) w ( r , r ) d r = r L ^ { r } ψ ( r ) G ( r , r ) w ( r , r ) d r + b . c . ,
with added Dirichlet or Neumann boundary conditions (b.c.). Direct substitution into Equation (5), using Equation (2), yields
ψ ( r ) = r G ( r , r ) ϕ ( r ) w ( r , r ) d r + b . c . .

2.1. On the Nature of w ( r , r ) , and L ^ 1

This former known result deserves a more delicate look, particularly, on the existence of the weight function, and how previous solution relates with the usual convolution theorem ψ ( r ) = r G ( r , r ) ϕ ( r ) d r + b . c . As mentioned, an appropriate choice for the weight function ensures that Equation (5) reproduces Equation (7). This is performed by using the Green’s and Divergence theorem in Equation (5) to perform an integration by parts. After simplifications, we realize that by choosing the weight function, such that { r } w ( r , r ) w ( r , r ) f ( r ) = 0 (See Appendix A for further details) we ensure that the operator is self-adjoint! This is essential to Green’s method. Hence, if no weight function exists, we might be forced to use other analytical and/or numerical procedures in order to find ψ . For that matter, the range of problems that we aim to analyze is narrowed down to the few ones satisfying the aforementioned condition; despite this, a great many of this subset are of special interest for mathematics and physics.
Assuming w ( r , r ) exists we are able to incorporate the premise for Equation (7) yielding exactly,
ψ ( r ) = r G ( r , r ) ϕ ( r ) w ( r , r ) d r + r w ( r , r ) ψ ( r ) { r } G ( r , r ) G ( r , r ) { r } ψ ( r ) · n d S .
Notice how the second term depends on ψ ( r ) ’s boundary conditions. By choosing identical conditions and trivial values for the Green distribution function at the boundaries ( G = 0 for Dirichlet or G = 0 for Neumann) we are capable of solving an infinite number of similar boundary value problems.
The discussion for the existence of the weight function can be answered mathematically. Given the relationship required, the weight is defined as w ( r , r ) exp [ γ ( r , r ) ] , yielding { r } γ ( r , r ) = f ( r ) . Considering that the curl of the gradient of any scalar function is trivial then γ ( r , r ) exists if, and only if, × f = 0 , which means that f must be a conservative vector field! Within this view, γ ( r , r ) represents the scalar potential associated with a force. Anticipating this last restriction, the solution for γ ( r , r ) is independent of a path that simply connects r to r yielding,
w ( r , r ) e γ ( r ) e γ ( r ) = 1 w ( r , r ) ,
reflecting on the symmetry of the distribution as it will be shown later. Finally, we are ready to define the inverse operator of L ^ as
L ^ { r } 1 = r G ( r , r ) ( r ) w ( r , r ) d r ,
conditioned by the boundary-value problem, which in turn defines G ( r , r ) from Equation (4).
There is one last piece of the puzzle to be resolved and it is related to the symmetry of the Green function distribution. Let us evaluate L ^ { r } G ( r , r ) —i.e., the operator acting on the second variable. Direct application of L ^ { r } on Equation (8), using Equation (2),
ϕ ( r ) = r L ^ { r } { G ( r , r ) w ( r , r ) } ϕ ( r ) d r + L ^ { r } { b . c . } ,
hints how this operator appears to work and leads us to anticipate the convolution of a Dirac distribution. Indeed this is true. To clarify, here we exchanged integral and Liouville operators because they are acting on separate variables, and the weight and Green functions (except at r = r ) are differentiable.
This conjecture can be proved from the following statement: two separate problems with different boundary values and identical inhomogeneous differential equation—Equation (2)—share the same Green function distribution and satisfy Equation (11); therefore, by comparing equations for any two cases leads to L ^ { r } { b . c . } = 0 because we can always choose convenient trivial boundary values (i.e., b . c . = 0 ) in one case. Consequently,
L ^ { r } { G ( r , r ) w ( r , r ) } δ ( r r ) ,
an equality that bears meaning in the sense of the distributions. These final result unravels the symmetry of the Green distribution function via the weight function, i.e.,
G ( r , r ) = G ( r , r ) w ( r , r ) .
An interesting question now arises, and it is related to the possibility of using Equation (13) to drop the weight function out of the equation. This operation, with the addition of the relation { r } w ( r , r ) = w ( r , r ) f ( r ) , leads to,
ψ ( r ) = r G ( r , r ) ϕ ( r ) d r + r ψ ( r ) { r } G ( r , r ) G ( r , r ) ψ ( r ) f ( r ) + { r } ψ ( r ) · n d S .
Notice that for Neumann boundary conditions (NBC), unlike Dirichlet (DBC), both ψ ( r ) and its derivative—at the boundaries—are necessary. Ergo, Equation (14) is inconvenient for NBC unless either ψ vanishes or f ( r ) = 0 . In such a case, it deems necessary to use the version that incorporates weight function.
Actually, the vector field f does not appear in some of the Liouville operators used in physics. For instance, the Green function associated with the electrostatic field satisfies the relation 2 G ( r , r ) = 4 π δ ( r r ) —the irrelevant factor of 4 π appears by convenience. The static regime of the Klein Gordon equation—which also leads to the Yukawa potential—also follows a similar behavior, as its associated Green function in 2D is K 0 ( μ r ) , satisfying the DE ( 2 μ 2 ) G ( r ) = 2 π δ ( r ) [32]. Clearly, f is absent in both systems.
Yet, the DEs describing the behavior of other physical systems, such as the driven damped harmonic oscillator, (the one-dimensional driven damped harmonic oscillator is modeled by the DE m x ¨ + b x ˙ + k x = F ( t ) . The damping constant b plays the role of f in this one dimensional system. Although the time t is the relevant variable describing this system (instead of the position x), the one dimensional formalism we describe is analog to this model.) the diffusion equation at thermal equilibrium with an anisotropic diffusion coefficient, and the electrostatic potential in the presence of anisotropic media, include the existence of a vector field f —see Section 4 for more details about the first system.
Surprisingly, any dependence on the weight function in Equation (14) has vanished. As previously stated, the weight function can only be defined when f is a conservative field. Then, an important question now arises: is Equation (14) still valid for non-conservative vector fields? This in a fundamental question that can be addressed in a future work. Since the main purpose is to present a compact and rigorous algorithm to solve the Green function in 2D space, we will restrict our analysis to only the supported cases.

2.2. Boundary Conditions

As previously stated, the Green function conveniently inherits identical types of conditions as the target function ψ at the boundaries. These can be summarized as,
DBC : G ( r , r ) | r at R ext / int = 0 ,
NBC : r G ( r , r ) | r at R ext / int = 0 .
However, there are two hidden additional conditions that must be satisfied enforced by the presence of Dirac’s distribution. The rationale behind this is that without them G = 0 will be a solution to the Green function for the simple boundary value problem. Although this is directly visible for Dirichlet, notice that it also applies for Neumann’s case. The added restrictions appear at the artificial boundary r = r implying continuity of G and discontinuity of the local derivative. Both are essential to secure a non-zero solution. Continuity is often regarded considering that the Green distribution is still a function and its derivatives up to second order exist in the classical sense of the DE everywhere except at r = r . Though there is a stronger argument that stems from the fact that the annulus and the disc are Lipschitz domains [33], in DE it always results convenient to decide what do we take as an acceptable solution to any problem, which is our particular case here.
Turning to the plane r = r , conditions are derived directly from Equation (4) by integrating over r inside the volume delimited by the surface S δ enclosing r such that it is contained inside a vicinity— V δ —of r (see right of Figure 1 for an artistic view). Using the divergence theorem, the condition simplifies to,
lim δ 0 S δ { r } G ( r , r ) · n ^ d S = 1 ,
where we have kept the leading contributing term while taking the limit. For the one dimensional case, it yields the relation G ( r > , r ) G ( r < , r ) = 1 .

2.3. Connection with the Sturm–Liouville Problem

The weight function, if existent, is able to transform the Liouville operator into a self-adjoint differential operator. Notice that action of w ( r , r ) on Equation (1),
w ( r , r ) L ^ { r } = { r } · w ( r , r ) { r } + w ( r , r ) g ( r ) ,
yields the otherwise known Sturm–Liouville form for Partial Differential Equations (PDE)’s. Namely, the Sturm–Liouville differential operator reads then as,
L ^ { r } SL = w ( r , r ) L ^ { r } .
Consequently, operating onto the Green distribution function gives equal results for both operators, i.e., L ^ { r } SL G ( r , r ) = δ ( r r ) .
This last result connects the Sturm–Liouville problem with null eigenvalues and the Green function distribution problem where the former is the solution to the first strictly when r r under either Dirithlet or Neumann boundary conditions. Resulting from this, G ( r , r ) is continuous everywhere and differentiable at r r ; the behavior of its derivative at r = r is dictaminated by the Liouville operator in the domain of the problem and specified by the Dirac Delta distribution.

2.4. Moving from 2D to 1D: The Infinite Coupling

As noted before, let us elaborate on the simplest scenario where a reduction in the dimension of the problem significantly improves our chances of procuring a general solution. Assume we would like to find the two-dimensional Green function in accordance with Equation (4). Taking advantage of the completeness of the Fourier infinite expansion of any periodic function, we propose to solve the two-dimensional DE in polar coordinates; the dimensional reduction occurs due to the periodicity in θ that does not take place in Cartesian coordinates.
Although the Laplace operator in polar coordinates is known to be separable in the variables r and θ , the introduction of the additional terms in Equation (1), as already mentioned, may lead to a DE that cannot be split conveniently. Equation (4) is then given by,
2 r 2 + 1 r r + 1 r 2 2 θ 2 + f r ( r , θ ) r + f θ ( r , θ ) 1 r θ + g ( r , θ ) G ( r , r ) = δ ( r r ) ,
where convenient periodic conditions that must be satisfied suggests we should expand the Green function distribution in Fourier modes. Tentatively, we can resort to a Fourier expansion of the form λ e i λ ( θ θ ) G λ , where
f ( r , θ ) = μ Z f μ ( r ) e i μ θ ; f μ ( r ) = 1 2 π 0 2 π f ( r , θ ) e i μ θ d θ ,
to match the delta distribution expansion—i.e., δ ( r r ) = 1 2 π r δ ( r r ) λ e i λ ( θ θ ) —but since we cannot guarantee that the G λ coefficients are θ -independent (only under proper angular symmetry conditions) then we will assume G ( r , r ) expands as,
G ( r , r ) = 1 2 π λ Z e i λ θ G λ ( r , r , θ ) .
With that in mind and multiplying Equation (20) by r 2 to avoid divergences at r = 0 ,
λ Z e i λ θ r 2 d 2 d r 2 + r ( 1 + r f r ) d d r + ( λ 2 + i λ r f θ + r 2 g ) G λ = λ Z e i ( λ λ ) θ r δ ( r r ) .
Notice how we cannot obtain a solution because there remains a residual dependence of θ in functions f and g. Despite this, a simplification can be manufactured when they are replaced by their Fourier series form before integrating on θ over a full period. This step yields our master equation where we deduce that the G λ ( r , r , θ ) modes satisfy the DE (we have dropped out the dependencies of all functions on r, θ , r , and θ facilitating a comprehensible reading),
r 2 G λ + r G λ λ 2 G λ + μ Z r 2 f r μ G λ μ + μ Z i r ( λ μ ) f θ μ + r 2 g μ G λ μ = r δ ( r r ) e i λ θ .
This final result shows we have accomplished to reduce the rank of the effective Green function to solve at the expense of requiring a countable large number of these Green modes. It is remarkable how the dependence on θ is delegated to a quasi-negligible term at the right hand side of the equation. We will develop this argument further in the following sections.
This formulation represents an infinitely coupled system of linear differential equations that unsurprisingly contains the solution to the Green function for the classical source-free wave function; the structure of functions f and g defines the strength of the entanglement of Green’s free wave modes appearing in the rate at which the Fourier coefficients—functions—go to zero with increasing mode frequency. For simplicity, we opt to recall Green’s Fourier modes as λ -modes, and f and g’s modes as μ -modes suggested by the indexes employed in the equation above.

2.5. More on Boundary Conditions of the λ -Modes

One last effort must be made to explain how boundary conditions are inherited along the free-wave modes. The key to this understanding depends on the geometry of the problem and the originating expansion from Equation (21); we can identify two cases for disc-like systems: the annulus and the disc. Other geometries will be studied in a future work. For the annulus, either under Dirichlet or Neumann boundary conditions, the function or its derivative must vanish at the boundaries. This can be met if all modes preserve the vanishing values at both inner and outer boundaries—under uniform convergence. In doing so, we guarantee to meet all requisites for the Green function and a solution is obtained. Conversely, preserving boundary conditions for the disc is not trivial because we do not have one but two boundaries (the second at r 0 + ). Due to the oscillating behavior of e i λ θ with θ at r 0 + , all λ 0 modes must vanish at the origin to ensure continuity of the Green distribution function. This can be enforced examining Equation (23) as r 0 + . Discontinuity due to the source at r = r may be neglected for now to realize that we can, while approaching the origin, consider the behavior of each r 0 , r 1 , and r 2 terms independently. We draw then conveniently,
r 0 λ 2 G λ = r 0 0 ,
r 1 G λ + i μ Z ( λ μ ) f θ μ G λ μ = r 0 0 ,
r 2 G λ + μ Z f r μ G λ μ + μ Z g μ G λ μ = r 0 0 ,
where we can choose, via r 0 terms, that G λ = 0 λ 0 and G 0 0 . Plugging this sequentially into r 1 and r 2 terms hints G λ = 0 and G λ = 0 ( λ 0 ) assuming that lim r 0 f θ μ G λ μ = 0 and lim r 0 f r μ G λ μ = 0 lim r 0 g μ G λ μ = 0 (with the exception of λ = 0 where the μ = 0 term remains, thus we will choose G λ = g 0 G 0 ), respectively.
This is supported from continuity of g ( r ) everywhere in the disc and from the definition of f ( r ) , where limited by the existence of w ( r , r ) , as the gradient of a scalar function. If such functions, γ ( r ) , where to be free of pathologies and differentiable everywhere in the disc (including the origin) then lim r 0 f r λ = 0 and lim r 0 f θ λ = 0 for λ 0 . It remains to say, that in order to fulfill all above conditions we will require that f θ 0 and f r 0 are finite as r 0 + . Looking under the hood of these assumptions, note that consequently the 0-mode has a logarithmic divergence when r = 0 , i.e., G 0 r 0 log r .
In summary, the conditions for the disc at the origin are the following two only for r > 0 (see Section 3 for numerical details)
G λ ( 0 + , r , θ ) = 0 λ 0 ,
G λ ( 0 + , r , θ ) = 0 λ .
Exceptions and particularities emerging from the specific form of functions f and g must be taken into account when detailing the boundary conditions and may alter the relationships obtained above.
This relationship has to be completed with the resulting relationship at the artificial boundary r = r obtained when using a complementary surface S ϵ corresponding to an open ring of ϵ > 0 thickness—see left Figure 1 and Equation (17). This gives,
r lim ϵ 0 0 2 π r G ( r , r ) > r G ( r , r ) < d θ = 1 .
which entails the radial averaged contribution. We have eliminated angular contributions by selecting the convenient contour S ϵ suggesting a pathway to extend it to the λ -modes. Direct substitution of Equation (21) along with a convenient choice of unity—inspired by Equation (23)—gives us ultimately,
r G λ ( r > , r , θ ) G λ ( r < , r , θ ) = e i λ θ ,
where primes denote partial derivatives with respect to the first argument at both left (<) and right (>) hand sides of r . Substituting this relationship in the differential equation, we obtain a similar relationship for the second derivatives, essential to the numerical method, as follows,
( r ) 2 [ G λ ( r > , r , θ ) G λ ( r < , r , θ ) ] = e i λ θ 1 + r f r ( r , θ ) .
For the disc, the r = 0 case must be clarified. In polar coordinates, Dirac’s distribution is best described as absent of angular dependence, which entails that for all λ -modes except λ = 0 it is exactly zero. Therefore, the boundary at the origin for each λ -mode is dictated by symmetry except for λ = 0 . This last, carries the logarithmic divergence. This means that conditions for non-zero modes are unchanged. For the zero mode and due to symmetry G 0 | r 0 + = G 0 | r 0 and G 0 | r 0 + = G 0 | r 0 ; however, due to the divergence a cut-off must be set in place. Such a choice of cut-off will be discussed later.

3. Finite Differences Method, FDM, or FEM on a Regular Grid

The FDM, or uniform mesh FEM, has been used extensively in the literature to find approximate solutions for many physical systems and its stability makes it a suitable candidate to obtain a numerical Green distribution function. Some examples include the one-dimensional Schrödinger equation [34], the Poisson equation for Electrodynamics [35], the Euler equations of inviscid fluid flow [36], solutions to 1D and 2D Burgers’ equation [37], and the time-fractional diffusion equation [38]. From the mathematical perspective, the same method has been implemented to solve elliptic, hyperbolic and parabolic partial DEs on irregular meshes [39], with interfaces [40], or in finding optimal algorithms on non-trivial meshes [41].
Orchestrating an exact solution to Equation (23) is virtually not possible. There are four cases where an analytical approach can be attempted: two cases where either f or g are zero, requiring to find a base of G λ ’s that can decouple the system—hence, a diagonalization—the unique case where the same base applies to both coupling matrices accompanying G λ and G λ , and the trivial free-wave ( f and g zero). Excluding the latter, finding this diagonalizing operator for the first three cases will be addressed in a future study.
Therefore, we will compute a numerical solution where we approximate the operator with finite differentiation (the finite difference method—FDM or FEM for a regular grid) and bind expansions to include all relevant Green and function modes up to a calculated cut-off; maximum and minimum modes will be chosen, respectively, for λ - and μ -modes symmetrically as | λ | L and | μ | M considering that M L for reasons that will be clarified afterwards.
Since the Green function is twice differentiable, when r r , its Fourier series converges uniformly and its coefficients decay at least as λ 2 , conditioned by equally well-behaved functions f and g. Then, a possible educated choice of L is the minimum integer such that the sum of 1 / k 2 up to L exceeds π 2 6 p , with p a percentage of accuracy; for example, to achieve at most 1 % of estimation error we require L > 60 .
Numerical details and calculations performed henceforth are presented solely for the 3-point stencil. The strategy for the implementation of more accurate approximations will only be mentioned and briefly discussed; their details will be left for the reader to carry them out. Other minor and major details regarding the procedure will be addressed in future works.

3.1. A Large Matrix Equation

The Finite Differences Method (FDM) or Finite Elements Method (FEM) with uniform grid is a simple approach to computing derivatives of functions at a point by using Taylor expansions on a discretized mesh. (The choice of whether dissecting uniformly or non-uniformly is highly dependable on the problem. For example, if we were interested in fracture dynamics we would prefer a non-uniform grid to model complex material topologies.) In doing so, a derivative will rely on knowledge of the values of the function in neighboring sites. Such is the art of computing derivatives. The number of neighboring sites to be taken into consideration determines the degree of which the function approaches to the point value. For instance, in the so called three-point stencil (the site in question and its two adjacent neighbors), the first and second derivatives are accurate up to order square of the mesh size.
Going back to our problem in Equation (23), we turn to a simply redefined one dimensional DE for a sketch of the forthcoming operations. The left hand side reads rewritten as,
P r d 2 d r 2 G λ ( r , r , θ ) + μ Z Q μ r d d r G λ μ ( r , r , θ ) + μ Z R λ , μ r G λ μ ( r , r , θ ) .
In transforming the continuous variables r and r into a discrete equally-spaced mesh of size h, we will adopt matrix notation for variables and functions; ergo, for N partitions defining N + 1 points h = ( R ext R int ) / N in a disc-like geometry. For clarity, we summarize notation changes in Table 1. This procedure applied over the aforementioned equation gives for r r ,
P j 1 h 2 η A | j a η | j ( 2 ) G λ | θ j + η , k + μ Z Q μ j 1 h η A | j a η | j ( 1 ) G λ μ | θ j + η , k + μ Z R λ , μ j G λ μ | θ j , k + O ( h ξ ) ,
with ξ the order of approximation, A | j the set of neighbor site indices, and a η | j ( n ) the respective coefficient (namely the finite difference coefficient included into a matrix representation A ( n ) —see Appendix B) of the η -th neighbor required to compute the n-th derivative up to a predetermined order of accuracy [42]; in the three-point stencil case, ξ = 2 . Both sets of neighbor indices and coefficients depend on the information of the site j under inspection; if, for example, we are at or near an interface, boundary, or discontinuity, then the strategy for choosing neighbors may differ; we might be interested in computing derivatives using only points in regions where it makes sense.
With some reorganization, the generated discrete DE can be regarded as a matrix multiplication. To see this, first we realize that by understanding G λ | θ j , k as the ( j , k ) -th element of a constructed matrix G λ | θ —of size N + 1 × N + 1 —we can envision a column matrix vector G θ that contains all λ -modes, or all of { G λ | θ λ Z } , where all operations from the previous complex array equation are condensed into an equally conceived matrix U multiplying G θ . The following is a view of G θ ,
G θ = G L | θ G 1 | θ G 0 | θ G 1 | θ G L | θ , with G λ | θ = G λ | θ 0 , 0 G λ | θ 0 , 1 G λ | θ 0 , N 1 G λ | θ 0 , N G λ | θ 1 , 0 G λ | θ 1 , 1 G λ | θ 1 , N 1 G λ | θ 1 , N G λ | θ N 1 , 0 G λ | θ N 1 , 1 G λ | θ N 1 , N 1 G λ | θ N 1 , N G λ | θ N , 0 G λ | θ N , 1 G λ | θ N , N 1 G λ | θ N , N .
In principle, both matrices are infinitely large but for practical terms they will be truncated on both λ - and μ -modes, as mentioned in the previous section. Despite this numerical simplification that will be carried out in the numerical analysis, the infinite matrix U has a well-defined structure, as will be detailed in Section 3.2.
Finally, the terms to the right of Equation (23) vanish for all r r leading us to believe that if U is invertible then the solution to the discrete Green function G θ is identically zero. However, attention should be paid at r = r for its effect discards the trivial solution. Along with the other geometrical boundary conditions the problem will now have a unique solution. These boundary conditions will be addressed in Section 3.3.

3.2. Infinite Matrix U

To understand the structure of U we turn to the set of operations for a particular λ -mode. Seeing as U is infinite we may encode rows by the integer value of the mode being solved and columns by the value of the mode being correlated. Thus taking row λ from U ,
U λ G θ = , 1 h Q μ + R λ , μ column λ μ , , , M , , 3 , 2 , 1 μ | 1 h 2 P + 1 h Q 0 + R λ , 0 column λ μ = 0 , , 1 h Q μ + R λ , μ column λ μ , | μ 1 , 2 , , M , = G λ μ | θ } row λ μ G λ | θ } row λ G λ μ | θ } row λ μ ,
with the following definitions for matrices P , Q μ , R λ , μ ,
P = P 0 0 0 0 P 1 0 0 0 P N × A ( 2 ) ,
Q μ = Q μ 0 0 0 0 Q μ 1 0 0 0 Q μ N × A ( 1 ) ,
R λ , μ = R λ , μ 0 0 0 0 R λ , μ 1 0 0 0 R λ , μ N .
One last remark on matrix U is that the density of non-zero entries is at most 3 / N for the three-point stencil. For sufficiently large N, it will become essential to find a way to manage such sparsity for all speed-ups, data-compression, and efficiency in memory footprint.

3.3. Discrete Boundary Conditions

Using conditions detailed thoroughly in Section 2.2 and at end of Section 2.4 we are now in capacity of parameterizing the values of G λ | θ j , k . This parametrization should further reflect the behavior of the δ -function. The following are the conditions for the 3-point stencil: (i.) at r = R ext ,
G λ | θ N , k = 0 for   DBC ;
G λ | θ N + 1 , k G λ | θ N 1 , k = 0 for   NBC ,
(ii.) at R int for the annulus,
G λ | θ 0 , k = 0 for   DBC ;
G λ | θ 1 , k G λ | θ 1 , k = 0 for   NBC ,
(iii.) for the disc at R int (disregarding G λ = 0 for now),
G 0 | θ 1 , k G 0 | θ 1 , k = 0 λ = 0 ,
G λ | θ 0 , k = 0 λ 0 ,
and, finally, (iv.) at the interface r = r the condition reads,
G λ | θ k > + 1 , k G λ | θ k > 1 , k G λ | θ k < + 1 , k G λ | θ k < 1 , k = 2 h r k e i λ θ .
Here we have adopted the subscript convention of < , > to refer to points to the left and right of the site of derivative evaluation. Note how all equations above reference and highlight a few fictitious points. The mesh points that lay outside or beyond the valid grid are G λ | θ N + 1 , k , G λ | θ 1 , k , G λ | θ k < + 1 , k , and G λ | θ k > 1 , k . These spurious terms must be dealt with and simplified in order to be able to incorporate readily all conditions.

3.4. A Non-Trivial Matrix Equation and a Solution

We will now show the explicit matrix equation associated with the conditions described above. As mentioned, they depend on the degree of accuracy that we choose, or equivalently, the stencil. We will describe the procedure for the three-point stencil and further discuss how to generalize for higher orders of approximation.
With the boundary relationships in mind, here in Equations (37), (39), (41) and (43), Equation (23) (multiplied by h 2 ) equates partially to zero (when r r ) as,
2 P j G λ | θ j , k P j ( G λ | θ j + 1 , k + G λ | θ j 1 , k ) h 2 μ R λ , μ j G λ μ | θ j , k h 2 μ Q μ j ( G λ μ | θ j + 1 , k G λ μ | θ j 1 , k ) = 0 ,
where via Equation (43) the latter can be used to simplify both spurious terms (appearing at r = r ) G λ | θ k < + 1 , k and G λ | θ k > 1 , k . After crossing out these terms by iterative substitution we obtain a generalized expression for the above valid for almost every point in the grid. The general discrete equation yields for r > 0 ,
2 P j G λ | θ j , k P j ( G λ | θ j + 1 , k + G λ | θ j 1 , k ) h 2 μ Q μ j ( G λ μ | θ j + 1 , k G λ μ | θ j 1 , k ) h 2 μ R λ , μ j G λ μ | θ j , k = h r j δ j , k e i λ θ 1 h 2 4 ( r k ) 2 [ 1 + r k f r ( r k , θ ) ] 2 1 δ λ , 0 ,
where the new term that accounts for the boundary condition at r = r has appeared. Due to the absence of a left-hand limit as r = 0 , according to Equation (43), this term is exactly h r j δ j , k e i λ θ at the origin. Actually, this condition holds for the mode λ = 0 in general due to translational invariance—this invariance is clearly absent for the other modes. The terms composing the right-hand side of last equation can be viewed as of order of mesh-size or order of radial distance from the origin as follows,
1.
h 3 4 f r ( r k , θ ) , a surprising third order correction due to the vector field appearing after substituting the interface difference in derivatives.
2.
h r k = h R int + h 2 k , the leading order that substituted yields a first order constant term and a second order increasing term.
3.
h 3 4 1 r k = h 3 4 1 R int + h k , a negative term significant closer to the origin. As expected, the behavior of the discrete version near zero validates our previous choice of boundary condition for the disc.
4.
For r = 0 , we must implement a cut-off such that r 0 = ϵ > 0 instead of zero to avoid numerical divergences. The choice for ϵ will be discussed below.
Because the error in the differential equation is of O ( h 4 ) , we should incorporate all terms to the calculation. However, we will neglect the higher order term—first term—since this will simplify our calculations of ψ ( r ) .
This final expression is valid everywhere including the controversial j = 0 , N points, where either Dirichlet or Neumann conditions complete Equation (44) at the borders. In those two cases, substitutions must take place following Equations (37), (39) and (41). After replacements, and due to the nature of derivative calculation in the three-point stencil, rows from U corresponding to exterior and interior borders are modified. See the substitution rules in Table 2 and Table 3.
We now define our complete matrix system as U · G θ = h V · E θ . Among other things, the right-hand side accounts for the contribution of Dirac’s distribution. The two additional definitions appearing correspond to first a distance parameter generalized into α λ j , a new object that incorporates the boundary conditions at both j = 0 and j = N . Notice, for instance, that keeping the term r j at every point does not explain the vanishing of the Green function at the boundaries when DBC are considered, neither does it describe the correct behavior at r = 0 for a disk. Actually, when the last condition is considered, an ultraviolet cut-off ϵ —such that ϵ 0 —must be introduced to avoid divergences, as seen in previous works [14,15,16]. Such a cut-off is not surprising, as the 2D Green distribution has a natural divergence at r = r and a logarithmic behavior near the origin when r = 0 . Although the appearance of this divergence can easily be visualized after studying the behavior of Equation (44) at j = 0 for the mode λ = 0 in a disk, its existence at any point—also for an annulus—is guaranteed by the infinite number of λ -modes that must be summed up to obtain an exact solution. Therefore, it is not surprising that ϵ and h are related—see Section 4 for more details.
Matrix terms are written as,
V λ , μ j , k = α λ j δ λ , μ δ j , k ,
E λ | θ j , k = e i λ θ δ j , k ,
and the solution to the λ -modes matrix G θ is,
G θ = h A · E θ ,
where we have defined A = U 1 · V assuming that U is invertible.
Matrix A was declared because it has interesting symmetry properties that will be discussed in the next section. Table 2, Table 3, Table 4 and Table 5 outline how to fill the matrix elements of the objects we have described.

3.5. The Parameter α and the Symmetry of A

A closed relation can be found for the matrix describing the entire Green function. Using the results from previous section, it is
G θ , θ j , k = h 2 π λ , μ e i λ θ e i μ θ A λ , μ j , k ,
where A λ , μ j , k = [ U 1 ] λ , μ j , k α μ k . As previously mentioned, the parameter α λ k generalizes the radial parameter r k , including the boundary conditions. On the other hand, it is worthwhile to state the symmetry conditions that A satisfies (a more detailed derivation can be found in Appendix D; z ¯ denotes the complex conjugate of z.)
Im A 0 , 0 j , k = 0 ,
A λ , 0 j , k = A λ , 0 j , k ¯ , A 0 , μ j , k = A 0 , μ j , k ¯ ,
A λ , μ j , k = A λ , μ j , k ¯ , A λ , μ j , k = A λ , μ j , k ¯ .
Using Table 5, it is easy to see that the matrix elements [ U 1 ] λ , μ j , k satisfy the same symmetry properties.

3.6. The Algorithm

The algorithm for a numerical solution can be summarized as follows:
1.
The values of L and M are determined according to the required level of approximation.
2.
We fill all elements described in Table 1; the matrix elements U λ , μ j , k are filled by blocks using the rules shown in Table 2, Table 3 and Table 4. Matrix elements α λ j are also filled according to Table 5.
3.
Matrix U is inverted and so matrix A is computed.
4.
The Green function is computed according to Equation (48).
Using previous results, we can deduce a closed form for ψ ( r ) for both DBC and NBC using the conventions stated in Equations (8) and (14). Although there are many ways to perform the integrals stated in previous equations, and the reader can choose the method that he or she prefers, a sketch of these solutions, using the trapezoid rule, is shown in Appendix F and Appendix G.

3.7. Particular Cases and Properties

We will analyze some particular cases that can be deduced from the procedure explained above. We will start focusing on the one-dimensional case.
  • One-Dimensional Case
The analysis of a Green function in one dimension requires an appropriate definition of a general DE obeyed by the Green function G ( x , x ) . Unfortunately, a direct analysis of the results by studying Equation (23) is not straightforward due to the clear differences between the Laplacians in Cartesian and polar coordinates. Let us imagine a general second order DE of the form L x ψ ( x ) = ϕ ( x ) , where the Green function satisfies the relation
L x G ( x , x ) = P ( x ) d 2 G d x 2 + Q ( x ) d G d x + R ( x ) G = β δ ( x x ) .
The function P ( x ) might not be necessary, as it can be eliminated by division, but its inclusion allows us to have a more general analysis. The constant therm β seems clumsily placed, as its value is usually 1. Nonetheless, some formalisms define the Green function by means of the operator L x G ( x , x ) = δ ( x x ) , thus introducing a change of sign that can be contemplated in our study.
By following a similar analysis as that shown above, we can deduce an appropriate recurrence relation for Equation (52), which is
( 2 P j h 2 R j ) G j , k ( P j + h 2 Q j ) G j + 1 , k ( P j h 2 Q j ) G j 1 , k = h β δ j , k .
Having confined the system within the domain x [ x 0 , x N ] , our step size is now h = ( x N x 0 ) / N .
From this point on, we can apply the results obtained for the two-dimensional problem in this study. Notice that, in the absence of modes that account for the angular dependence, we can always say that A λ , μ j , k = A λ , μ j , k δ λ , 0 δ μ , 0 . Therefore, Equation (48) becomes
G j k = h A j , k , where A j , k = [ U 1 ] j , k α k
and α k accounts for the boundary conditions. By making the association x j = x 0 + h j , the elements described in Equation (54), for 1 j N 1 , are now filled using the following rules:
1.
U j , j = 2 P j h 2 R j .
2.
U j , j ± 1 = P j h 2 Q j .
3.
U 0 , 0 = U N , N = 1 for DBC. For NBC: U 0 , 0 = 2 q 0 h 2 b 0 , U N , N = 2 P N h 2 R N , U 0 , 1 = 2 P 1 and U N , N 1 = 2 P N 1 .
4.
α j = β .
5.
α 0 = α N = 0 for DBC. For NBC: α 0 = β and α N = β .
The weight function, which guarantees the symmetry condition G k j = w j k G j k takes the form
w ( x , x ) = e U ( x ) e U ( x ) , U ( z ) = 1 P ( z ) exp z 0 z Q ( y ) P ( y ) d y ,
where z 0 is an irrelevant constant. Solutions for ψ ( x ) with both DBC and NBC using the trapezoid rule as method of integration are shown in Appendix G.
  • Monopole-like Case
This takes place when both f ( r ) and g ( r ) have no significant angular dependence, so the mode μ = 0 is their only relevant contribution; this implies that Q μ j = R λ , μ j = 0 for μ 0 . The off-diagonal matrices U λ , λ μ j , k thus vanish—this leads to a block diagonal U matrix—and so the system becomes separable in the radial and angular variables. Having now the relation A λ , μ j , k = A λ , μ j , k δ λ , μ , Equation (48) reduces to
G θ θ j k = h 2 π λ e i λ ( θ θ ) A λ , λ j , k .
Notice that each mode can now be solved independently.

3.8. Beyond the Three-Point Stencil

As mentioned, we only showed an explicit analysis for a three-point stencil approximation. This method can be generalized to include the contribution of more neighbors in the derivative terms, i.e., higher order stencils that provide more accurate degrees of approximation in h. In spite of its simplicity, the three-point stencil has the great advantage that the spurious terms that arise from the boundary conditions can be eliminated in a simple fashion.
The description of the system with a five-point stencil, for instance, will increase the amount of terms different from zero in U —for example, terms of form U λ , λ μ j , j ± 2 will provide non-zero contributions. Having a higher degree of approximation, that demands the inclusion of more non-trivial matrix terms, the grid size can be reduced. Although there is no guarantee that the inversion process is optimized in time when the contributions of more neighbors are included, as the matrices are highly sparse, there is a clear optimization of memory storage.
Yet a great disadvantage that higher stencils inherit is the elimination of the spurious terms that come from the boundary conditions. For instance, when we deal with the condition at j = k ( r = r ), Equation (43) will include more coefficients outside the grid, so the recurrence relation that is obtained will not be able to eliminate all of them—at least, using the same procedure we implemented. Therefore, a different approach must be performed. A possible solution could be expanding the derivatives around a point different from the center, so avoiding the spurious terms; this process is studied in detail in [42]. Nonetheless, this could be discussed in a future study.

4. Numerical Results

We will use the formalism described above to solve some particular examples. This section is particularly focused on presenting our results; such results will be discussed in the following section. Three examples will be presented.
  • Example 1: a one-dimensional case
As a first example, let us study a one-dimensional system with a known analytical solution, useful to test the formalism we have described. Let us suppose we want to solve the DE in the domain [ 0 , 4 ]
x 2 ψ ( x ) + x ψ ( x ) + ( x 2 4 ) ψ ( x ) = J 4 ( x ) ,
where J n ( x ) and Y n ( x ) are the Bessel functions of first and second kind of order n. Using Equation (55), we can easily deduce that w ( x , x ) = x / x .
The conditions ψ 0 = 0 and ψ N = 2 (Dirichlet), lead to the analytical solution,
ψ ( x ) DBC = 1 24 J 2 ( 4 ) [ J 2 ( x ) 48 2 J 4 ( 4 ) + + π x J 2 ( 4 ) J 4 ( x ) Y 1 ( x ) π x J 2 ( 4 ) J 1 ( x ) J 4 ( x ) Y 2 ( x ) ] .
Conversely, with conditions f 0 = 0 and f N = 2 (Neumann), the analytical solution yields,
ψ ( x ) NBC = 1 C ( x ) [ 2 J 0 ( 4 ) + 3 J 1 ( 4 ) x ( x 2 24 ) J 0 ( x ) 8 ( x 2 6 ) J 1 ( x ) + x 3 J 2 ( x ) 96 + 2 J 0 ( 4 ) 3 J 1 ( 4 ) ] ,
with C ( x ) = 24 x 3 J 1 ( 4 ) J 3 ( 4 ) .
Analytical and numerical results are compared for both cases in Figure 2 and Table 6—see Equations (A25a) and (A25b) for explicit expressions using a numerical approach.
  • Example 2: the two-dimensional Helmholtz equation with imaginary wave number
We now shift our attention to solve a two-dimensional system. Let us consider the DE
( 2 m 2 ) G ( r , r ) = δ ( r r ) .
In the absence of the vector field f ( r ) , we conclude that w ( r , r ) = 1 ; besides, the system is separable in the radial and angular coordinates. The solution to last equation confined in a large disc of radius r N = R ext with Dirichlet boundary conditions can be found analytically. For θ = θ and different values of r , solutions are presented in Figure 3.
Last numerical result will now be used to solve a non-homogeneous equation of the form ( 2 m 2 ) ψ ( r ) = ϕ ( r ) , whose general solution is provided in Appendix G with r 0 = R int = 0 .
Now, let us consider ϕ ( r ) to be a function defined over a disc of radius R = 10 and study the two following cases:
(a)
ψ ( a ) ( r , θ ) , with ϕ ( r ) = 1 10 r sin θ , and ψ ( R , θ ) = 2 .
(b)
ψ ( b ) ( r , θ ) , with ϕ ( r ) = r 1 / 2 , 0 θ < π r 1 / 2 , π θ < 2 π , and
ψ ( R , θ ) = 1 , 0 θ < π 1 , π θ < 2 π .
Solutions to ψ ( a ) ( r , θ ) and ψ ( b ) ( r , θ ) for some angles are shown in Figure 4 and Figure 5, respectively.
It is important to mention that Equation (60) is a particular case of a DE that describes the behavior of a two-dimensional two-component plasma in thermal equilibrium at a fixed temperature in the absence of an external electric field. Here the function ψ ( r ) is naturally identified with G ( r , r ) (actually, a Green function), which generates the n-body correlation functions of the system. When the plasma is confined in a disc (or annulus) and it is subjected to an external field, E ( r ) , the system can be solved numerically with the presented method, once the identifications g ( r ) = m 2 E 2 ( r ) , f x ( r ) = 2 i E y ( r ) , and f y ( r ) = 2 i E x ( r ) are performed; more details can be found in [14,15,16].
  • Example 3: a pedagogical example
Now let us apply the same formalism to solve another two-dimensional problem. Let us suppose that we want to find the Green function associated with the two-dimensional DE [ + Z ( r ) ] · ψ ( r ) = ϕ ( r ) , where Z ( x , y ) = 2 x 2 y 2 . After transforming the system to polar coordinates, we can see that f r = r 3 ( 1 cos 4 θ ) and f θ = r 3 sin 4 θ . The elements defined in Table 1 now become
Q μ j = r j δ 0 , μ + ( r j ) 5 δ 0 , μ 1 2 ( δ 4 , μ + δ 4 , μ ) ,
R λ , μ j = λ 2 δ 0 , μ + 1 2 ( r j ) 4 ( λ μ ) ( δ 4 , μ δ 4 , μ ) .
The system will be confined in an annulus or internal radius R int = 1 and external radius R ext = 2 . Figure 6 shows the Green function for DBC and some particular parameters but different values of L. Figure 7 shows the results for different parameters under NBC.

5. Discussion

It is worthwhile to discuss the results found in the previous section. We will analyze the three examples presented above in respective order followed by an explanation on how the method can be adapted to solve the diffusion equation.
Example 1.
In the one-dimensional case it is interesting to contrast the numerical solutions shown in Figure 2 using the weight function and the one that arises without the weight function formalism—performing the replacement w j k G j k G k j (graphs that illustrate the results using the weight function were not shown, but comparisons will be given. Interestingly, from Table 6, we conclude that the introduction of the weight function leads to a more accurate result in this case. Notice that the use of a modest grid sizes ( 32 N 512 ) leads to very accurate results.
Example 2.
This two-dimensional example has an analytical solution. Adapting the result found in [16], we deduce that the Green function associated with Equation (60) is
G ( r , r ) = m 2 2 π λ e i λ ( θ θ ) I λ ( m r < ) K λ ( m r > ) t λ ( R ) I λ ( m r ) I λ ( m r ) ,
where r > and r < are the maximum and minimum between r and r , I λ ( x ) and K λ ( x ) are the well-known modified Bessel function of the second kind and t λ ( R ) = K λ ( m R ) I λ ( m R ) . Taking a look at Equation (62), we deduce that the Green function diverges—many distributions are formally infinite. Actually, the first term of previous sum can be reduced to m 2 2 π K 0 ( m | r r | ) .
Notice that the Green function diverges logarithmically, in the limit r r , as K 0 ( x ) x 0 ln ( 2 / x ) γ , with γ the Euler Mascheroni constant. A cut-off s, which represents a minimum separation distance between r and r [14], is usually introduced to address this divergence. In turn, s might be related to L and ϵ .
We now implement the numerical analysis to verify last solution noticing that P j = ( r j ) 2 , Q μ j ( r ) = α j = r j δ μ , 0 , and R λ , μ j = ( λ 2 + m 2 P j ) δ μ , 0 .
The following step is determining an appropriate value for ϵ . From Figure 3, we see that the solution for a fixed value of r shows a peak at r = r . As we sum up all modes the magnitude of the height of the peaks must be infinite. However, the introduction of L guarantees the peaks to be finite. The height of the peak at r = r = 0 is associated with ϵ , as the functions K λ ( r ) diverge at r = 0 . The cut-off ϵ is chosen in such way that the height of the peaks in the neighborhood of r = r = 0 —i.e., | r r | = O ( h ) —are close enough. We found that for N 2 7 , ϵ 0.25 h . Surprisingly, we found that ϵ does not depend on L for large enough L.
We recall that this is an approximation; the exact solution for the distribution is found in the limits ϵ 0 and L . In addition to the graphical comparison between the numerical and analytical results already shown in Figure 3, Table 7 also presents numerical details that ratify the accuracy of our results.
Regarding the inhomogeneous solutions shown in Figure 4 and Figure 5, we do not have an analytical solution to test the algorithm; however, results show to be consistent. Particularly, the function ψ ( a ) ( r , θ ) shows maxima for similar values of r—the value of such maxima gradually decreases with the angular direction; interestingly, the location of the critical points seems to occur for approximately the same value of r. Since ϕ ( r ) obeys a diffusion equation, this suggests that the concentration of the analyzed quantity shows maximum (or minimum) values at a certain radial location; this critical concentration, nonetheless, is favored for larger angles—this is consistent because of the non-homogeneous function ϕ ( r ) = 1 10 r sin θ that has been chosen. As expected, ψ ( a ) ( r , θ ) take the required values at the borders for every angle. On the other hand, ψ ( b ) ( r , θ ) presents the same solution for two sets of angles: 0 θ < π and π θ < 2 π , which is expected due to the form chosen for ϕ ( r ) —notice that the only difference between such two sets of conditions is a global sign; this difference is clearly reflected in Figure 5. Interestingly, ϕ ( r ) is finite at r = 0 , in spite of the clear divergence of ϕ ( r ) at this value. However, such difference is weak enough as it goes like r 1 / 2 . Like in previous example, the presence of a critical point is evident.
Example 3.
Notice from Figure 6 how the Green functions become zero at the borders and their derivatives present a discontinuity at r = r . As expected, the larger L, the larger the magnitude of the value at that point; however, this value decreases as | θ θ | increases; under this condition, the behavior of the Green function is smoother, but it seems to be too much more sensitive respect to the value of L. Interestingly, for the parameters that have been analyzed, the Green function only shows a “mirror symmetry” respect to r as θ = θ = 0 . For NBC, as illustrated in Figure 7, something similar happens. However, the derivatives at the borders are now the ones which tend no be zero. Although this is clear as r 2 , the asymptotic behavior toward zero close to the inner border can be appreciated. The values of the Green function at the border, however, clearly differ for different parameters. Similarly to the case where DBC where analyzed, the “mirror symmetry” around r is also absent (also when θ = θ = 0 ); the variation of the Green function is also larger as θ θ , showing sharper peaks.
When using the Green function to solve a particular inhomogeneous equation, it is clear that × f = 0 , so the weight function exists. It is
w ( r , r ) = e 1 4 r 4 ( 1 cos 4 θ ) e 1 4 r 4 ( 1 cos 4 θ ) = λ w λ ( r ) e i λ θ w ( r ) ,
whose only non-vanishing modes in discrete coordinates are given by the relation w 4 λ j = ( 1 ) λ e 1 4 ( r j ) 4 I λ ( 1 4 ( r j ) 4 ) . Although we are not interested in finding ψ ( r ) for a particular boundary problem, all the steps are carried out to accomplish this goal.
  • The Stationary Diffusion Equation
It is worthwhile to describe how our formalism can be adapted to solve the diffusion equation at “thermal” equilibrium. Let ψ ( r ) and D ( r ) represent the density of the diffusion material and the anisotropic diffusion coefficient, respectively. In the stationary regime, ψ ( r ) satisfies the DE
D ( r ) 2 ψ ( r ) + D ( r ) · ψ ( r ) = 0 .
Although Equation (64) does not have the standard form shown in Equation (2), after dividing Equation (64) by D ( r ) and defining f ( r ) as f ( r ) = 1 D ( r ) D ( r ) , the standard form can be obtained. (The diffusion coefficient is assumed to be well-behaved within the annulus or disc. However, f can have poles within the same domain.) The weight function is now guaranteed to exist, as × f = 1 D 2 D × D + 1 D × D = 0 . Actually, w ( r , r ) = D ( r ) D ( r ) .
The viability of our method to solve Equation (64) depends on the particular form of the diffusion coefficient. The following possibilities may arise: (a) f has no poles in the two dimensional domain; (b) f has a divergence in r = 0 that can be eliminated once f is multiplied by r; (c) the divergence at r = 0 —or any other radial divergence—previously discussed still persists after multiplication by r; and (d) D 1 has poles for some θ [ 0 , 2 π ) .
The cases (a) and (b) can be solved with the regular procedure we have described; the modes f r μ and f θ μ are well-behaved and so the elements Q μ j and R λ , μ j defined in Table 1 exist. The possibility stated in (c) demands a redefinition of f to eliminate any possible radial divergence; however, this redefinition does not guarantee the existence of the weight function. The situation described in (d) is problematic, as some of the modes f r μ and f θ μ are divergent. The last situation is alleviated by working with the original DE, Equation (64); nonetheless, the process that we must follow to solve a system whose mathematical form differs from Equation (2) has not been described in this work.
Similar analysis can be performed as we deal with the Poisson’s equation associated with electrostatic potential in an anisotropic media, among others.

6. Conclusions

In this paper we have analyzed the Green function formalism and studied under which conditions such mechanisms can be used to obtain the solution of an inhomogeneous DE. We consider that the main contribution of this research has been the proposition of a numeric algorithm to solve a family of partial differential equations for two-dimensional systems in polar coordinates, the Green function formalism was used for this purpose.
After decomposing the Green function as a sum of Fourier modes, an infinite set of coupled second order DE for the radial variable is found. Although such set decouples when the initial DE is separable in the radial and angular variables, the coupling in the modes arises as the vector field f ( r ) and the scalar function g ( r ) are expressed as a sum of Fourier modes. The presented analysis allows us to state the following highlights: (a) we found that there exists a function, which we called the weight function, that makes the Liouville operator self-adjoint. This function also defines the symmetry properties of the Green function (how it is transformed under the exchange of r and r ) and is guaranteed to exist as × f = 0 ; (b) a non-separable DE in r and θ leads to a large matrix system that is non-diagonal by blocks; (c) there exist a natural diverge due to the usual properties of the Dirac Delta distribution; however, this divergence can by absorbed only in the λ = 0 -mode; and (d) the λ -modes satisfy DBC at r = 0 for a disk geometry.
An algorithm to solve the Green function associated with a general class of Liouville operator was solved using a FEM. We used a simple three-point stencil approach to approximate the solution and focused on both Dirichlet and Neumann boundary conditions. A set of approximations was made, which included a truncation of the infinite number of modes, a minimum distance when the system is confined in a disc, and the discard of the term h 3 4 f r ( r k , θ ) . Although the first two approximations are well-justified because the Green function has a natural divergence, the last one was performed by convenience (anyway, it provides a very small contribution).
The algorithm was verified by comparing with known results and obtaining very small percentage errors. An additional example whose solution cannot be found by means of the regular algorithms was shown.
We consider that the presented method is a useful attempt to solve Green functions of operators whose radial and angular variables cannot be separated. However, we expect this algorithm can be improved by other authors in the future to obtain more accuracy without the need of creating huge matrix systems, which demand large storage memory and computational time. Some of the improvements may include the implementation of the method for higher order stencils, an optimized calculation either mathematically or numerically of ϵ , simplified formulas for the calculation of ψ ( r ) or “on the go” algorithms that do not require the inversion of the matrix or the storage of temporal information.

Author Contributions

A.F. was in charge of writing the article, developing the introduction and the main steps of the methodology, working on the numerical codes, and obtaining the results. Additionally, he proposed the project that did lead to the realization of this work. J.P.M. made relevant corrections and suggestions to the main document, proved some of the equations that are stated, help to consolidate the numerical codes, and gave some ideas to extend this work to future research projects. All authors have read and agreed to the published version of the manuscript.

Funding

This work was funded by Universidad Católica de Colombia and Universidad de los Andes. The authors would like to thank both institutions for their support.

Data Availability Statement

Not applicable.

Conflicts of Interest

The authors declare no conflict of interest.

Abbreviations

The following abbreviations are used in this manuscript: Finite Elements Metyhod (FEM), Finite Difference Method (FDM), Diichlet Boundary Conditions (DBC), Neumann Boundary Conditions (NBC), Differential Equation (DE), Boundary Conditions (b.c.), Partial Differential Equations (PDE).

Appendix A. Deduction of the Weight Function

The relation obeyed by the weight function that makes the Liouville operator self-adjoint can be deduced by performing a direct substitution of Equation (1) into (5) and using Green’s: V ϕ ( 2 ψ ) d r = V ψ ( 2 ϕ ) d r + V ϕ ( ψ ) ψ ( ϕ ) · n d S and the Divergence: V a · ( ψ ) d r = V ψ a · n d S V ψ ( · a ) d r theorems. After writing it conveniently, the result of this operation is
ψ ( r ) = r G ( r , r ) [ w ( r , r ) { r } 2 ψ ( r ) + { r } w ( r , r ) · { r } ψ ( r ) + w ( r , r ) g ( r ) ψ ( r ) ] d r + r { { r } w ( r , r ) w ( r , r ) f ( r ) · { r } ψ ( r ) + { r } · { r } w ( r , r ) w ( r , r ) f ( r ) ψ ( r ) } d r + r [ w ( r , r ) ψ ( r ) { r } G ( r , r ) G ( r , r ) { r } ψ ( r ) G ( r , r ) ψ ( r ) { r } w ( r , r ) w ( r , r ) f ( r ) ] · n d S .
Notice that under the choice { r } w ( r , r ) w ( r , r ) f ( r ) = 0 , last equation transforms into Equation (8).

Appendix B. Finite Elements Method, Matrix Elements

The elements of matrices A ( n ) introduced in Section 3.1 depend on the required level of accuracy and the central site η that we choose; a general algorithm to deduce such elements is shown in [42]. In the simplest case, as we choose η = 0 as the central point in conjunction with the two closets neighbors—three-point stencil approximation—we have the following relations [42,43]
A ( 1 ) = 0 1 0 0 0 0 1 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 0 0 0 0 1 0 1 0 0 0 0 1 0 N + 1 × N + 1 ,
A ( 2 ) = 2 1 0 0 0 0 1 2 1 0 0 0 0 1 2 0 0 0 0 0 0 2 1 0 0 0 0 1 2 1 0 0 0 0 1 2 N + 1 × N + 1 .
Notice how the matrices A ( n ) must be truncated at the boundaries; this is a natural consequence of the FEM, coming from the boundary conditions.

Appendix C. Derivatives at the Boundaries for DBC

If the Green function is used to find a non-homgeneous function with DBC, the derivatives of the Green function at the borders are needed—see Equations (8) and (14). Combining Equation (44) with the boundary conditions stated in Equations (37), (39), (41) and (43), we deduce the following two relations ( j = 0 and j = N refer to the two possible boundaries)
G θ , θ ( 0 , N ) , k = 1 2 π λ , μ e i λ θ e i μ θ B λ , μ ( 0 , N ) , k , where B λ , μ ( 0 , N ) , k = P 0 , N ν S ( 0 , N ) λ , ν 1 A ν , μ ( 1 , N 1 ) , k .
The matrix elements associated with S ( 0 , N ) are S λ , λ ( 0 , N ) = P 0 , N h 2 Q 0 0 , N and S λ , λ μ ( 0 , N ) = h 2 Q μ 0 , N . Since ψ is known at the boundaries, the derivatives G θ , θ 0 , 0 and G θ , θ N , N are irrelevant; additionally, a disk only requires the calculation of G θ , θ N , k . The symmetric elements G θ , θ j ( 0 , N ) can be found similarly, in terms of the transpose elements B λ , μ j , ( 0 , N ) , which are defined according to last expression by performing the index change and transposition A ν , μ ( 1 , N 1 ) , k A ν , μ j , ( 1 , N 1 ) . In one dimension the derivatives are G ( 0 , N ) k = P 0 , N A ( 1 , N 1 ) , k P 0 , N h 2 Q 0 , N .

Appendix D. Symmetry Properties of Some Matrix Elements

Expanding Equation (48) to eliminate the negative modes, we can write the Green function as
G θ , θ j , k = h 2 π [ A 0 , 0 j , k + λ 1 A λ , 0 j , k + A λ , 0 j , k cos ( λ θ ) + i A λ , 0 j , k + A λ , 0 j , k sin ( λ θ ) = + μ 1 A 0 , μ j , k + A 0 , μ j , k cos ( μ θ ) + i A 0 , μ j , k A 0 , μ j , k sin ( μ θ ) = + λ , μ 1 { A λ , μ j , k + A λ , μ j , k + A λ , μ j , k + A λ , μ j , k cos ( λ θ ) cos ( μ θ ) = + i A λ , μ j , k + A λ , μ j , k A λ , μ j , k A λ , μ j , k sin ( λ θ ) cos ( μ θ ) = + i A λ , μ j , k A λ , μ j , k + A λ , μ j , k A λ , μ j , k cos ( λ θ ) sin ( μ θ ) = + A λ , μ j , k A λ , μ j , k A λ , μ j , k + A λ , μ j , k sin ( λ θ ) sin ( μ θ ) } ] .
Since the Green function must be real for real Liouville operators, we demand that the imaginary contributions of last expression must vanish. Hence, we have the restrictions stated in Equation (49).

Appendix E. Expansion of the Green Function as Sines and Cosines

This expansion allows us to write the Green function as a sum of real elements, explicitly showing that the Green function is real. Using the properties stated in Equation (49) into Equation (A5), we find that
G θ θ j k = h 2 π Re A 0 , 0 j , k h π λ 1 [ Re A λ , 0 j , k cos ( λ θ ) + Re A 0 , λ j , k cos ( λ θ ) Im A λ , 0 j , k sin ( λ θ ) + Im A 0 , λ j , k sin ( λ θ ) ] h π λ , μ 1 Re A λ , μ j , k cos ( λ θ μ θ ) + Re A λ , μ j , k cos ( λ θ + μ θ ) + h π λ , μ 1 Im A λ , μ j , k sin ( λ θ μ θ ) + Im A λ , μ j , k sin ( λ θ + μ θ ) .
In the presence of angular symmetry, A λ μ j k = A λ μ j k δ λ μ , so last equation reduces to
G θ θ j k = h 2 π Re A 0 , 0 j , k h π λ 1 Re A λ , λ j , k cos [ λ ( θ θ ) ] Im A λ , λ j , k sin [ λ ( θ θ ) ] .

Appendix F. Computation of ψ(r) as an Exponential Expansion

In this section, we will derive expressions for Equations (8) and (14) for both DBC and NBC. Although both approaches must lead to the same results, it is worthwhile to show how both relations can be found through the formalism we have described.
For convenience, we will split ψ ( r , θ ) into a volume (V) and surface (S) contribution—the volume contribution is the term containing the integral over r in Equations (8) and (14); the surface contribution is the one containing the integral over the closed surface r in the same equations. For DBC and NBC, ψ can be written in discrete coordinates as
( ψ θ j ) DBC = ( ψ θ j ) V + ( ψ θ j ) S DBC ,
( ψ θ j ) NBC = ( ψ θ j ) V + ( ψ θ j ) S NBC .
There are many ways to evaluate numerically an integral. We will use one of the simplest, however, very efficient, ways to do so, the so called trapezoid rule. Due to the discretization we have used, this rule will be applied to evaluate the the radial integrals, appearing in the volume contributions; the integrals over angular coordinates will be evaluated directly using the Fourier expansions of the functions involved.
  • Using the weight function
Having adopted the convention described in Equation (8), we start performing a Fourier expansions of the external field: ϕ ( r ) ϕ θ k = λ ϕ λ k e i λ θ , the weight function: w ( r , r ) w θ k w ( r j , θ ) = 1 w ( r j , θ ) λ w λ k e i λ θ —and something similar for the boundary conditions ψ θ ( 0 , N ) and ψ θ ( 0 , N ) . Now, we will define the function
ξ w ( k , M k , j , η k , θ ) = 1 2 π 0 2 π d θ λ , μ e i λ θ M λ , μ k , j e i μ θ ν η ν k e i ν θ ρ w ρ k e i ρ θ = λ , μ , ν e i μ θ M λ , μ k , j η ν k w λ ν k .
This definition will be used to define the volume- and surface-terms.
Since the volume-term can be written as r 0 r N r d r 0 2 π w ( r , r ) G ( r , r ) ϕ ( r ) d θ ( r 0 = R int , r N = R ext ), we can say that
( ψ θ j ) V = h 2 w ( r j , θ ) [ k = 1 N 1 r k ξ w ( k , A k , j , ϕ k , θ ) + 1 2 r 0 ξ w ( 0 , A 0 , j , ϕ 0 , θ ) + 1 2 r N ξ w ( N , A N , j , ϕ 0 , θ ) ] .
The surface-term arising in DBC is written as r 0 2 π w ( r , r ) ψ ( r ) r G ( r , r ) d θ | r 0 r N . Similarly as shown above, in discrete coordinates it is given by
( ψ θ j ) S DBC = 1 w ( r j , θ ) r N ξ w ( N , B N , j , ψ N , θ ) r 0 ξ w ( 0 , B 0 , j , ψ 0 , θ ) .
Finally, the surface-term r w ( r , r ) G ( r , r ) { r } ψ ( r ) · n d S that appears in NBC can now be expanded in the form r 0 2 π w ( r , r ) G ( r , r ) r ψ ( r ) d θ | r 0 r N ; it now becomes
( ψ θ j ) S NBC = h w ( r j , θ ) r N ξ w ( N , A N , j , ψ N , θ ) r 0 ξ w ( 0 , A 0 , j , ψ 0 , θ ) .
Remark A1.
The matrix elements of matrices A and B ( 0 , N ) are given by Equations (48) and Equation (A4), respectively—the indices associated to the position in the blocks have been omitted by convenience. The function ψ θ j is defined in the interval 1 j N 1 ; in DBC the terms ψ θ 0 and ψ θ N are given, in NBC the function at the borders is not accurate enough due to the discontinuity of the Green function at the borders.
  • Using no weight function
When we adapt the convention stated in Equation (14), Equations (A10)–(A12) are slightly modified. We now define the function ξ as
ξ ( k , M j , k , η k , θ ) = 0 2 π d θ 2 π λ , μ e i λ θ M λ , μ j , k e i μ θ ν η ν k e i ν θ = λ , μ e i λ θ M λ , μ j , k η μ k .
We can now conclude that
( ψ θ j ) V = h 2 k = 1 N 1 [ r k ξ ( k , A j , k , ϕ k , θ ) + 1 2 r 0 ξ ( 0 , A j , 0 , ϕ 0 , θ )
+ 1 2 r N ξ ( N , A j , N , ϕ N , θ ) ] ,
( ψ θ j ) S DBC = r N ξ ( N , B j , N , ψ N , θ ) r 0 ξ ( 0 , B j , 0 , ψ 0 , θ ) , ( ψ θ j ) S NBC = h r N ξ ( N , A j , N , f r N , θ ) + ξ ( N , A j , N , ψ N , θ )
= h r 0 ξ ( 0 , A j , 0 , f r 0 , θ ) + ξ ( 0 , A j , 0 , ψ 0 , θ ) .

Appendix G. Computation of the Inhomogeneous Function as Expansion of Trigonometric Functions

It is now useful to expand the relations shown in previous section as trigonometric functions. Although the expressions found are much longer, this allows us to use the symmetry properties, Equation (49), to get rid of irrelevant terms and explicitly express ψ ( r ) as a real function. In addition, the exponential expansion defined in Appendix F might introduce some spurious imaginary contributions, which may arise by as a consequence of the truncating process of matrix U —the complex conjugate counterparts of some modes may be discarded in this process. Taking advantage of the definitions used in Appendix F, Equations (A10) to (A12) are still valid when we adopt the convention stated in Equation (8); similarly, when the convention Equation (14) is adopted, Equations (A14) to (A17) are also valid. Now, we only need to expand ξ w and ξ eliminating the negative complex modes to express them as sum of real modes. By doing so, Equation (A9) becomes
ξ w ( k , M k , j , η k , θ ) = Re M 0 , 0 k , j Re η 0 k Re w 0 k + 2 λ 1 Re η 0 k Re M 0 , 0 k , j X λ k + Y λ k , j + 2 λ 1 Re η 0 k Re w 0 k Re M 0 , λ k , j cos ( λ θ ) + Im M 0 , λ k , j sin ( λ θ ) + 4 λ , μ 1 X μ k Re M 0 , λ k , j cos ( λ θ ) + Im M 0 , λ k , j sin ( λ θ ) + 2 λ , μ 1 Re η 0 k Re w λ k M ( + ) λ , μ ( 1 ) k , j + Im w λ k M ( + ) λ , μ ( 2 ) k , j cos ( μ θ ) 2 λ , μ 1 Re η 0 k Im w λ k M ( ) λ , μ ( 1 ) k , j Re w λ k M ( ) λ , μ ( 2 ) k , j sin ( μ θ ) + 2 λ , μ 1 Re η μ k Re M λ , 0 k , j w + ( λ , μ ) ( 1 ) k + Im M λ , 0 k , j w + ( λ , μ ) ( 2 ) k + 2 λ , μ 1 Im η μ k Re M λ , 0 k , j w ( λ , μ ) ( 2 ) k Im M λ , 0 k , j w ( λ , μ ) ( 1 ) k + 2 λ , μ , ν 1 M ( + ) λ , μ ( 1 ) k , j Z ( λ , ν ) ( 1 ) k + Z ( λ , ν ) ( 2 ) k + M ( + ) λ , μ ( 2 ) k , j Z ( λ , ν ) ( 3 ) k + Z ( λ , ν ) ( 4 ) k cos ( μ θ ) + 2 λ , μ , ν 1 M ( ) λ , μ ( 2 ) k , j Z ( λ , ν ) ( 1 ) k + Z ( λ , ν ) ( 2 ) k M ( ) λ , μ ( 1 ) k , j Z ( λ , ν ) ( 3 ) k Z ( λ , ν ) ( 4 ) k sin ( μ θ ) ,
where we used the definitions
X λ k = Re η λ k Re w λ k + Im η λ k Im w λ k
Y λ k , j = Re M λ , 0 k , j Re w λ k + Im M λ , 0 k , j Im w λ k ;
M ( ± ) λ , μ ( 1 ) k , j = Re M λ , μ k , j ± Re M λ , μ k , j , M ( ± ) λ , μ ( 2 ) k , j = Re M λ , μ k , j ± Re M λ , μ k , j ;
w ± ( λ , ν ) ( 1 ) k = Re w λ + ν k ± Re ( w λ ν k ) , w ± ( λ , ν ) ( 2 ) k = Im w λ + ν k ± Im ( w λ ν k ) ; Z ( λ , ν ) ( 1 ) k = Re η ν k w + ( λ , ν ) ( 1 ) k , Z ( λ , ν ) ( 2 ) k = Im η ν k w ( λ , ν ) ( 2 ) k ,
Z ( λ , ν ) ( 3 ) k = Re η ν k w + ( λ , ν ) ( 2 ) k , Z ( λ , ν ) ( 4 ) k = Im η ν k w ( λ , ν ) ( 1 ) k .
Similarly, Equation (A13) is now written as
ξ ( k , M j , k , η k , θ ) = Re M 0 , 0 j , k Re η 0 k + = 2 λ 1 R λ j , k + Re η 0 k Re M λ , 0 j , k cos ( λ θ ) Im M λ , 0 j , k sin ( λ θ ) + = 2 λ , μ 1 M ( + ) λ , μ ( 1 ) j , k Re η μ k M ( ) λ , μ ( 2 ) j , k Im η μ k cos ( λ θ ) = 2 λ , μ 1 M ( + ) λ , μ ( 2 ) j , k Re η μ k + M ( ) λ , μ ( 1 ) k , j Im η μ k sin ( λ θ ) ,
with R λ j , k = Re M 0 , λ j , k Re η λ k Im M 0 , λ j , k Im η λ I k .
  • The one-dimensional case
The function ψ , satisfying the equation L x ψ ( x ) = ϕ ( x ) , where L x is defined according to Equation (52), can be found by means of the relations below. For DBC with either weight function or not
ψ j = h 2 k = 1 N 1 w k , j A k , j ϕ k + 1 2 w 0 , j A 0 , j ϕ 0 + 1 2 w N , j A N , j ϕ N = + P N w N , j ψ N A N 1 , j 1 + h 2 1 Q N + P 0 w 0 , j ψ 0 A 1 , j 1 h 2 1 Q 0 ;
= h 2 k = 1 N 1 A j , k ϕ k + 1 2 A j , 0 ϕ 0 + 1 2 A j , N ϕ N + q N ψ N A j , N 1 1 + h 2 1 Q N + P 0 ψ 0 A j , 1 1 h 2 1 Q 0 .
For NBC
ψ j = h 2 k = 1 N 1 w k , j A k , j ϕ k + 1 2 w 0 , j A 0 , j ϕ 0 + 1 2 w N , j A N j ϕ N + h P k w k , j ψ k A k , j | k = 0 N ;
= h 2 k = 1 N 1 A j , k ϕ k + 1 2 A j , 0 ϕ 0 + 1 2 A j , N ϕ N + h P k A j , k ψ k + ψ k f k | k = 0 N .

Appendix H. Notation and List of Used Parameters

Table A1 shows a list of most parameters that have been used in this document specifying their notation
Table A1. Notation used in this document. For additional information, please see Table 1.
Table A1. Notation used in this document. For additional information, please see Table 1.
ParameterNotationParameterNotation
Liouville operator L ^ { r } Arbitrary scalar field
Vector field f ( r ) Scalar field g ( r )
Unknown scalar function ψ ( r ) Non-homogeneous scalar function ϕ ( r )
Green function G ( r , r ) Weight function w ( r , r )
Internal radius R int , r 0 External radius R ext , r N
Polar coordinates r , θ , r , θ Fourier modesIndexed by λ or μ
Min. radius ϵ (cutoff)Max. Fourier modeL (cutoff)
Grid sizehMatrix sizeN
Full “Green matrix” G θ Blocks of G θ G λ | θ
Convenient matrices P , Q μ , R λ , μ Matrix to be inverted U
Temporary matrices V , E θ , A = U 1 · V Matrices used in FEM A ( n )

References

  1. Schwinger, J. Brownian motion of a quantum oscillator. J. Math. Phys. 1961, 2, 407–432. [Google Scholar] [CrossRef]
  2. Wang, J.S.; Agarwalla, B.K.; Li, H.; Thingna, J. Nonequilibrium green’s function method for quantum thermal transport. Front. Phys. 2014, 9, 673–697. [Google Scholar] [CrossRef] [Green Version]
  3. Foster, S.; Neophytou, N. Effectiveness of nanoinclusions for reducing bipolar effects in thermoelectric materials. Comput. Mater. Sci. 2019, 164, 91–98. [Google Scholar] [CrossRef] [Green Version]
  4. Moulhim, A.; Tripathi, B.; Kumar, M. Nonequilibrium green function technique for analyzing electron transport through single and two levels of interacting quantum dot. Phys. Scr. 2021, 96, 125802. [Google Scholar] [CrossRef]
  5. Kadanoff, L.P.; Baym, G. Quantum Statistical Mechanics: Green’s Function Methods in Equilibrium and Nonequilibrium Problems; W. A. Benhamin, Inc. XI: New York, NY, USA, 1962; p. 203. [Google Scholar]
  6. Hidaka, Y.; Pu, S.; Wang, Q.; Yang, D. Foundations and applications of quantum kinetic theory. Prog. Part. Nucl. Phys. 2022, 127, 103989. [Google Scholar] [CrossRef]
  7. Alkofer, R.; von Smekal, L. The infrared behaviour of qcd green’s functions: Confinement, dynamical symmetry breaking, and hadrons as relativistic bound states. Phys. Rep. 2001, 353, 281–465. [Google Scholar] [CrossRef]
  8. Lucarini, V. Revising and extending the linear response theory for statistical mechanical systems: Evaluating observables as predictors and predictands. J. Stat. Phys. 2018, 173, 1698–1721. [Google Scholar] [CrossRef] [Green Version]
  9. Chen, Z.; de Gier, J.; Hiki, I.; Sasamoto, T. Exact confirmation of 1d nonlinear fluctuating hydrodynamics for a two-species exclusion process. Phys. Rev. Lett. 2018, 120, 240601. [Google Scholar] [CrossRef] [Green Version]
  10. Brevik, I.; Parashar, P.; Shajesh, K.V. Casimir force for magnetodielectric media. Phys. Rev. A 2018, 98, 032509. [Google Scholar] [CrossRef] [Green Version]
  11. Xu, F.; Wang, J. Statistical properties of electrochemical capacitance in disordered mesoscopic capacitors. Phys. Rev. B 2014, 89, 245430. [Google Scholar] [CrossRef]
  12. Lenzi, E.; Mendes, R.; Rajagopal, A. Green functions based on tsallis nonextensive statistical mechanics: Normalized q-expectation value formulation. Phys. Stat. Mech. Its Appl. 2000, 286, 503–517. [Google Scholar] [CrossRef]
  13. Lapolla, A.; Vossel, M.; Godec, A. Time- and ensemble-average statistical mechanics of the Gaussian network model. J. Phys. Math. Theor. 2021, 54, 355601. [Google Scholar] [CrossRef]
  14. Cornu, F.; Jancovici, B. The electrical double layer: A solvable model. J. Chem. Phys. 1989, 90, 2444–2452. [Google Scholar] [CrossRef] [Green Version]
  15. Ferrero, A.; Téllez, G. Two-dimensional two-component plasma with adsorbing impurities. J. Stat. Phys. 2007, 129, 759–786. [Google Scholar] [CrossRef] [Green Version]
  16. Ferrero, A.; Téllez, G. Screening of an electrically charged particle in a two-dimensional two-component plasma at γ=2. J. Stat. Mech. Theory Exp. 2014, 2014, P11021. [Google Scholar] [CrossRef] [Green Version]
  17. Joost, J.P.; Schlünzen, N.; Hese, S.; Bonitz, M.; Verdozzi, C.; Schmitteckert, P.; Hopjan, M. Löwdin’s symmetry dilemma within Green functionstheory for the one-dimensional Hubbard model. Contrib. Plasma Phys. 2021, 62, e202000220. [Google Scholar]
  18. David, G.; Mayboroda, S. Approximation of Green functions and domains with uniformly rectifiable boundaries of all dimensions. Adv. Math. 2022, 410, 108717. [Google Scholar] [CrossRef]
  19. On the Minimality of Extra Critical Points of Green Functions on Flat Tori. Int. Math. Res. Not. 2017, 18, 5591–5608.
  20. Nomura, Y.; Darmawan, A.S.; Yamaji, Y.; Imada, M. Restricted boltzmann machine learning for solving strongly correlated quantum systems. Phys. Rev. B 2017, 96, 205152. [Google Scholar] [CrossRef] [Green Version]
  21. Salazar, D.S.P. Nonequilibrium thermodynamics of restricted boltzmann machines. Phys. Rev. E 2017, 96, 022131. [Google Scholar] [CrossRef] [Green Version]
  22. Novoselov, K.S.; Geim, A.K.; Morozov, S.V.; Jiang, D.; Zhang, Y.; Dubonos, S.V.; Grigorieva, I.V.; Firsov, A.A. Electric field effect in atomically thin carbon films. Science 2004, 306, 666–669. [Google Scholar] [CrossRef] [PubMed] [Green Version]
  23. Fiori, G.; Bonaccorso, F.; Iannaccone, G.; Palacios, T.; Neumaier, D.; Seabaugh, A.; Banerjee, S.; Colombo, L. Electronics based on two-dimensional materials. Nat. Nanotechnol. 2014, 9, 768–779. [Google Scholar] [CrossRef] [PubMed]
  24. Schwierz, F.; Pezoldt, J.; Granzner, R. Two-dimensional materials and their prospects in transistor electronics. Nanoscale 2015, 7, 8261–8283. [Google Scholar] [CrossRef] [PubMed] [Green Version]
  25. Sterling, R.; Rattanasonti, H.; Weidt, S.; Lake, K.; Srinivasan, P.; Webster, S.; Kraft, M.; Hensinger, W. Fabrication and operation of a two-dimensional ion-trap lattice on a high-voltage microchip. Nat. Commun. 2014, 5, 3637. [Google Scholar] [CrossRef] [PubMed] [Green Version]
  26. Flindt, C.; Mortensen, N.A.; Jauho, A.-P. Quantum computing via defect states in two-dimensional antidot lattices. Nano Lett. 2005, 5, 2515–2518. [Google Scholar] [CrossRef] [Green Version]
  27. Sugino, F. Super yang-mills theories on the two-dimensional lattice with exact supersymmetry. JHEP 2004, 403. [Google Scholar] [CrossRef] [Green Version]
  28. Saraví, R.G.; Schaposnik, F.; Solomin, J. Path-integral formulation of two-dimensional gauge theories with massless fermions. Nucl. Phys. B 1981, 185, 239–253. [Google Scholar] [CrossRef]
  29. Perera, A.; Urbic, T. Clustering in complex ionic liquids in two dimensions. J. Mol. Liq. 2018, 265, 307–315. [Google Scholar] [CrossRef] [Green Version]
  30. Rañada, M.F.; Santander, M. Superintegrable systems on the two-dimensional sphere s2 and the hyperbolic plane h2. J. Math. Phys. 1999, 40, 5026–5057. [Google Scholar] [CrossRef]
  31. Kalnins, E.G.; Kress, J.M.; Miller, W. Second-order superintegrable systems in conformally flat spaces. i. two-dimensional classical structure theory. J. Math. Phys. 2005, 46, 053509. [Google Scholar] [CrossRef] [Green Version]
  32. Speight, J.M. Static intervortex forces. Phys. Rev. D 1997, 55, 3830–3835. [Google Scholar] [CrossRef] [Green Version]
  33. Mitrea, D.; Mitrea, I. On the regularity of green functions in lipschitz domains. Commun. Partial. Differ. Equ. 2010, 36, 304–327. [Google Scholar] [CrossRef]
  34. Truhlar, D.G. Finite difference boundary value method for solving one-dimensional eigenvalue equations. J. Comput. Phys. 1972, 10, 123–132. [Google Scholar] [CrossRef]
  35. Jomaa, Z.; Macaskill, C. The embedded finite difference method for the poisson equation in a domain with an irregular boundary and dirichlet boundary conditions. J. Comput. Phys. 2005, 202, 488–506. [Google Scholar] [CrossRef]
  36. Steger, J.L. Coefficient matrices for implicit finite difference solution of the inviscid fluid conservation law equations. Comput. Methods Appl. Mech. Eng. 1978, 13, 175–188. [Google Scholar] [CrossRef]
  37. Ozis, T.; Aksan, E.; Özdeş, A. A finite element approach for solution of burgers’ equation. Appl. Math. Comput. 2003, 139, 417–428. [Google Scholar]
  38. Lin, Y.; Xu, C. Finite difference/spectral approximations for the time-fractional diffusion equation. J. Comput. Phys. 2007, 225, 1533–1552. [Google Scholar] [CrossRef]
  39. Izadian, J.; Ranjbar, N.; Jalili, M. The generalized finite difference method for solving elliptic equation on irregular mesh. World Appl. Sci. J. 2013, 21, 95–100. [Google Scholar]
  40. Jo, G.; Kwak, D. Geometric multigrid algorithms for elliptic interface problems using structured grids. Numer. Algorithms 2018, 81, 211–235. [Google Scholar] [CrossRef]
  41. Kwak, D.Y.; Kwon, H.J.; Lee, S. Multigrid algorithm for cell centered finite difference on triangular meshes. Appl. Math. Comput. 1999, 105, 77–85. [Google Scholar] [CrossRef]
  42. Fornberg, B. Generation of finite difference formulas on arbitrarily spaced grids. Math. Comput. 1988, 51, 699–706. [Google Scholar] [CrossRef]
  43. Forsythe, G.; Wasow, W. Finite Difference Methods for Partial Differential Equations: Applied Mathematics Series; Literary Licensing, LLC: Whitefish, MT, USA, 2013. [Google Scholar]
Figure 1. Contours used in the path integration: to the left S ϵ and S δ to the right. The radius and thickness are chosen purposely as δ < ϵ / 2 to take the ϵ 0 limit.
Figure 1. Contours used in the path integration: to the left S ϵ and S δ to the right. The radius and thickness are chosen purposely as δ < ϵ / 2 to take the ϵ 0 limit.
Mathematics 11 00197 g001
Figure 2. Left: solution to the DE given by Equation (57) with the initial conditions ψ ( 0 ) = 0 and ψ ( 4 ) = 2 . Right: solution to the DE given by Equation (57) with the initial conditions ψ ( 0 ) = 0 and ψ ( 4 ) = 2 . Table 6 analyzes the accuracy of the numerical solutions. Note: we made x 0 = 10 6 to avoid numerical divergences at x = 0 .
Figure 2. Left: solution to the DE given by Equation (57) with the initial conditions ψ ( 0 ) = 0 and ψ ( 4 ) = 2 . Right: solution to the DE given by Equation (57) with the initial conditions ψ ( 0 ) = 0 and ψ ( 4 ) = 2 . Table 6 analyzes the accuracy of the numerical solutions. Note: we made x 0 = 10 6 to avoid numerical divergences at x = 0 .
Mathematics 11 00197 g002
Figure 3. Solution to Equation (60) using the numerical solution explained in Section 3 (continuous gray lines) and using Equation (62) (black dashed lines) for θ = θ and different values of r . We have chosen in all cases units such that m = 1 . We also used L = 80 for both cases. In the numerical solutions N = 4096 and ϵ = 0.25 h , in the analytical solution s = 0.15 h . The values of the minima and the mean square error (MSE) are shown in Table 7.
Figure 3. Solution to Equation (60) using the numerical solution explained in Section 3 (continuous gray lines) and using Equation (62) (black dashed lines) for θ = θ and different values of r . We have chosen in all cases units such that m = 1 . We also used L = 80 for both cases. In the numerical solutions N = 4096 and ϵ = 0.25 h , in the analytical solution s = 0.15 h . The values of the minima and the mean square error (MSE) are shown in Table 7.
Mathematics 11 00197 g003
Figure 4. Solution to ψ ( a ) ( r , θ ) for different values of θ in units in which m = 1 . We used N = 256 .
Figure 4. Solution to ψ ( a ) ( r , θ ) for different values of θ in units in which m = 1 . We used N = 256 .
Mathematics 11 00197 g004
Figure 5. Solution to ψ ( b ) ( r , θ ) for different values of θ in units in which m = 1 . The continuous line shows the solution for θ = { π 12 , π 6 , π 4 , π 2 } , the dotted line for θ = { π 12 , π 6 , π 4 , π 2 } . We used N = 256 and L = 80 .
Figure 5. Solution to ψ ( b ) ( r , θ ) for different values of θ in units in which m = 1 . The continuous line shows the solution for θ = { π 12 , π 6 , π 4 , π 2 } , the dotted line for θ = { π 12 , π 6 , π 4 , π 2 } . We used N = 256 and L = 80 .
Mathematics 11 00197 g005
Figure 6. Solution to G ( r , r ) with DBC, as given in example 3 for different values. We set h = 1 256 . We made L = 15 in the left plot and L = 30 in the right one.
Figure 6. Solution to G ( r , r ) with DBC, as given in example 3 for different values. We set h = 1 256 . We made L = 15 in the left plot and L = 30 in the right one.
Mathematics 11 00197 g006
Figure 7. Solution to G ( r , r ) with NBC, as given in example 3 for different values. We set h = 1 256 and made L = 40 .
Figure 7. Solution to G ( r , r ) with NBC, as given in example 3 for different values. We set h = 1 256 and made L = 40 .
Mathematics 11 00197 g007
Table 1. A summary on the change of notation from continuous to discrete form. We have r 0 = R int and j { 0 , 1 , 2 , , N } .
Table 1. A summary on the change of notation from continuous to discrete form. We have r 0 = R int and j { 0 , 1 , 2 , , N } .
Variable or FunctionEquivalent Array
r and r r j = r 0 + h j ,
G λ ( r , r , θ ) G λ | θ j , k = G λ ( r j , r k , θ )
P r r 2 P j = P r j
Q μ r r 2 f r μ ( r ) + r δ 0 , μ Q μ j = Q μ r j
R λ , μ r r 2 g μ ( r ) λ 2 δ 0 , μ + i r ( λ μ ) f θ μ ( r ) R λ , μ j = R λ , μ r j
Table 2. Non-vanishing matrix elements of U for 1 j N 1 for an annulus and a disc.
Table 2. Non-vanishing matrix elements of U for 1 j N 1 for an annulus and a disc.
Mode U λ , λ j , j U λ , λ j , j ± 1 U λ , λ μ j , j U λ , λ μ j , j ± 1
λ 2 P j h 2 R λ , 0 j P j h 2 Q 0 j h 2 R λ , μ j h 2 Q μ j
Table 3. Non-vanishing matrix elements of matrix U that define DBC (D) and NBC (N) for an annulus. N/A specifies those elements that lay outside U .
Table 3. Non-vanishing matrix elements of matrix U that define DBC (D) and NBC (N) for an annulus. N/A specifies those elements that lay outside U .
Modej U λ , λ j , j U λ , λ j , j + 1 U λ , λ j , j 1 U λ , λ μ j , j
(D) λ 0 , N 10, N/AN/A, 00
(N) λ 0 2 P 0 h 2 R λ , 0 0 2 P 1 N/A h 2 R λ , μ 0
(N) λ N 2 P N h 2 R λ , 0 N N/A 2 P N 1 h 2 R λ , μ N
Table 4. Non-vanishing matrix elements of matrix U that define DBC (shown above) and NBC (shown below) for a disc. N/A specifies those elements that lay outside U .
Table 4. Non-vanishing matrix elements of matrix U that define DBC (shown above) and NBC (shown below) for a disc. N/A specifies those elements that lay outside U .
Modej U λ , λ j , j U λ , λ j , j + 1 U λ , λ j , j 1 U λ , λ μ j , j
λ = 0 0 2 h 2 g 0 0 2 N/A0
λ = 0 N1N/A00
λ 0 0 , N 10, N/AN/A, 00
λ = 0 0 2 h 2 g 0 0 2 N/A0
λ N 2 P N h 2 R λ , 0 N N/A 2 P N 1 h 2 R λ , μ N
λ 0 010N/A0
Table 5. Elements α λ j that define DBC and NBC for an annulus (A) and a disc (D).
Table 5. Elements α λ j that define DBC and NBC for an annulus (A) and a disc (D).
Modej α λ j (DBC) α λ j (NBC)Geom.
λ = 0 0 ϵ 1 ϵ 1 (D)
λ = 0 00 r 0 (A)
λ = 0 1 j N 1 r j r j (A, D)
λ = 0 N0 r N (A, D)
λ 0 000(D)
λ 0 00 r 0 h 2 4 r 0 (A)
λ 0 1 j N 1 r j h 2 4 r j r j h 2 4 r j (A, D)
λ 0 N0 r N h 2 4 r N (A, D)
Table 6. Analysis of the accuracy of the two numerical solutions to Equation (57). The first two blocks use the conditions ψ ( 0 ) = 0 and ψ ( 4 ) = 2 and show the value of the maximum—exact value ψ m a x DBC = 2.6524822 , its percentage error (PE) (from 0 t 100%), and mean square error (MSE) of the function along the domain [ 0 , 4 ] ; the first block uses the weight function, the second one does not. The block below shows something similar for the conditions ψ ( 0 ) = 0 and ψ ( 4 ) = 4 and focus on the global minimum—exact value ψ m i n NBC = 3.88574186 using the weight function—remember that for NBC the formalism with the weight function is required.
Table 6. Analysis of the accuracy of the two numerical solutions to Equation (57). The first two blocks use the conditions ψ ( 0 ) = 0 and ψ ( 4 ) = 2 and show the value of the maximum—exact value ψ m a x DBC = 2.6524822 , its percentage error (PE) (from 0 t 100%), and mean square error (MSE) of the function along the domain [ 0 , 4 ] ; the first block uses the weight function, the second one does not. The block below shows something similar for the conditions ψ ( 0 ) = 0 and ψ ( 4 ) = 4 and focus on the global minimum—exact value ψ m i n NBC = 3.88574186 using the weight function—remember that for NBC the formalism with the weight function is required.
Func. ψ N = 32 ψ N = 128 ψ N = 512
ψ m a x DBC 2.6510 2.6526 2.6525
PE 5.6550 × 10 2 3.7700 × 10 3 1.9221 × 10 4
MSE 3.2824 2.6156 × 10 9 1.0287 × 10 11
ψ m a x DBC 2.7372 2.6736 2.6577
PE 3.1939 7.9615 × 10 1 1.9671 × 10 1
MSE 3.4935 2.1177 × 10 4 1.3148 × 10 5
ψ m i n NBC 3.8852 3.8853 3.8856
PE 1.4438 × 10 2 1.2060 × 10 2 3.1806 × 10 3
MSE 1.6316 × 10 3 2.3096 × 10 5 3.5993 × 10 7
Table 7. Values of the minima shown in Figure 3 for the numerical solution (NS) and analytical solution (AS). PE means percentage error (from 0 to 100 % ) and MSE is the mean square error.
Table 7. Values of the minima shown in Figure 3 for the numerical solution (NS) and analytical solution (AS). PE means percentage error (from 0 to 100 % ) and MSE is the mean square error.
Values of the Minima
G ( r , r ) r = 0 r = 1.172 r = 3.516 r = 7.031
NS 1.288 0.783 0.609 0.498
AS 1.2778 0.7835 0.6087 0.4984
PE 0.8263 3.566 × 10 2 5.148 × 10 3 1.603 × 10 3
MSE 3.629 × 10 8 1.343 × 10 10 5.053 × 10 12 6.379 × 10 13
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Ferrero, A.; Mallarino, J.P. Approximate Solution of Two Dimensional Disc-like Systems by One Dimensional Reduction: An Approach through the Green Function Formalism Using the Finite Elements Method. Mathematics 2023, 11, 197. https://doi.org/10.3390/math11010197

AMA Style

Ferrero A, Mallarino JP. Approximate Solution of Two Dimensional Disc-like Systems by One Dimensional Reduction: An Approach through the Green Function Formalism Using the Finite Elements Method. Mathematics. 2023; 11(1):197. https://doi.org/10.3390/math11010197

Chicago/Turabian Style

Ferrero, Alejandro, and Juan Pablo Mallarino. 2023. "Approximate Solution of Two Dimensional Disc-like Systems by One Dimensional Reduction: An Approach through the Green Function Formalism Using the Finite Elements Method" Mathematics 11, no. 1: 197. https://doi.org/10.3390/math11010197

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop