An Adaptive Local Iterative Method for Fast Calculation of Electrostatic Interactions between Charged Polymers in Dielectric Inhomogeneous System

The motion of charged polymers in the 3D dielectric inhomogeneity system is investigated using a hybrid simulation approach that combines a finite difference method with a Brownian dynamics model (FD‐BD) for the polymer chain. The interface difference scheme of the two‐dielectric model is first derived to achieve a smooth extension of the electrostatic potential values and it is verified that it has a second‐order convergence order. In addition, it is displayed that the local iteration method greatly accelerates the efficiency of calculating the electrostatic interaction forces. However, it is found that the computational efficiency improvement of the traditional local iteration is less significant (about three times) for polymer simulations such as 3D diagonal type. Therefore, a new strategy, the banded local iteration method, is proposed and the simulation results demonstrate that it can better adapt the effects of the deformation of the polymer during its motion, where the computational efficiency is increased by 29 times at most, while the relative error is controlled to less than 5.15e−4. The work can be helpful for accelerating the solution of electrostatic forces under dielectric inhomogeneity, and confer new insights into the optimization of iteration for polymer chains with different geometries in large electrostatic systems.


Introduction
Electrostatic interactions between the charged polymer and biomolecule-solvent environment play an important role in many biological processes, since many diffusing molecules of interest in biological systems carry charges. [1][2][3][4][5][6][7] It is well known that when the dielectric value in an electrolyte solution is represented by the segmental dielectric function, this belongs to the research category of dielectric inhomogeneity, which helps us understand the structure, function and dynamics of biomolecules, etc. In the experiment investigating phase separation of block copolymers, when the dielectric inhomogeneity is considered, the ions added to the solution tend to be enriched in the high dielectric constant components, thereby promoting phase separation, which is beyond the original cognition. [8][9][10][11] Furthermore, a particularly interesting aspect of this work is the consideration of the dependence of the dielectric coefficient on the electric field strength in electrolyte solutions, since the solvent dipole is highly oriented under a large electric field and thus affects the dielectric distribution. [12,13] The heterogeneity of the dielectric coefficient dramatically affects the structure of the bilayer region and charge transfer. Therefore, understanding the dielectric properties of solvents is essential for the accurate characterization of biomolecules in molecular level research, which can reasonably explain the electrophoresis of charged colloids in high-valent salt solutions presenting charge reversal and the ability of ions to promote the phase separation of block copolymers. In such a dielectric inhomogeneous system, a key challenge is how to solve electrostatic interactions quickly. For instance, the biomolecule-solvent two medium model is a classical dielectric inhomogeneity system. [14] Obviously, since electrolyte solution systems contain biomolecules that usually dissociate a huge number of charged particles, calculating the electrostatic interactions of this system is an extremely time-consuming task. A priori, for an N-particle system, using traditional methods [15][16][17][18] (e.g., Ewald summation, particleparticle particle-mesh, Coulomb force formula, etc.) to calculate these interactions would seem to require O(N 2 ) operations. We also need to recognize that in systems governed by the Poisson equation under dielectric inhomogeneity, the electrostatic forces on atom are not simply the product of electrostatic field E at the atom and the atomic charge q. However, these computational efforts may consume a lot of computer memory, especially when sufficient statistical sampling requires hundreds of thousands of simulations or a single simulation for extremely long time. Therefore, there is an urgent need for an efficient method to save computing time. In the past decades, these challenges have been addressed by classical numerical methods (e.g., finite difference method (FDM), finite element method (FEM)) as well as through popular linear or nonlinear iterative methods Adv. Theory Simul. 2023, 6,2200776 (e.g., successive over-relaxation, conjugate gradient method, and multigrid method). [19][20][21][22] Among them, FDM is widely favored by researchers due to its theoretical simplicity and convenience in dealing with regular boundaries, while optimization efficiency and accuracy are two core problems for FDM research. A large number of excellent works have appeared one after another in this field. [23][24][25][26][27][28] In this study, we develop a hybrid approach to combine the advantages of Brownian dynamics and finite difference methods in the same simulation. [29,30] In this way, the calculation of electrostatic interactions is converted into the problem of solving the 3D Poisson equation under a dielectric inhomogeneous system in numerical techniques. The partial differential equations of this system are well defined at boundary and interface conditions. It can be solved approximately by the finite difference method as a sparse linear matrix problem. Consequently, it is feasible to adopt it for the electrostatic calculations of large-scale biomolecular systems. In addition, another challenge for us is to deal with the molecular interface problem accurately and efficiently to achieve a smooth extension of the potential values over different dielectric regions. The main difficulties include three points: 1) the complex geometric configuration of the molecular surface; 2) the dielectric coefficient and electric field are discontinuous across the molecular interface; 3) the existence of singular sources. Recently, Egan [31] introduced a second-order exact geometric discretization of point charge sources to solve the Poisson equation. In order to deal with the boundary conditions of the Poisson problem on irregular domain, Towers [32] developed a central difference discretization of the Dirac-delta function representing the singular source at the interface. Moreover, some works have been dedicated to the study of the regularization in the setting of smoothly varying dielectric functions on diffuse interfaces and complex structures, of which four regularization methods based on Green's function are the most prevalent.
The first approach decomposes the numerical solution into two fractions over the entire computational domain: the singular component (Green's function) and the residual component (the regular component). Despite the lack of accuracy, this scheme is one of the pioneering works in the field and many other subsequence works are motivated by it. [33,34] Chern et al. [35] proposed the second method: a regular format separation for the solution, which treats the regular and singular parts of the solution separately. This decomposition method has been applied to the subsequent finite element methods of Lu and Zhou et al. [36,37] The third method was proposed and explored in Xie's work. [38] This scheme divides the electrolyte solution into three parts over the entire region, which is applied to solvents that contain any number of ionic species. However, Xie's and Chern's schemes are both of finite element aspect. The fourth method, matched interface and boundary (MIB) technique based on finite difference, was proposed by Zhou and Wei et al. [39][40][41][42][43][44][45] The MIB method to smoothly extend the both sides of the interface by means of fictitious domains, then obtains a central finite difference scheme with high-order accuracy repeatedly utilizing the interface conditions. However, in order to numerically solve the dynamic processes of electrostatic forces into the typical Brownian dynamics simulations of molecular conjugation or dissociation, which may involve millions or even tens of millions of time steps, the existing numerical methods are difficult to load such a large calculation amount. This means that it is necessary to find a new approach to avoid expensive computational costs and to ensure the accuracy of millions or even more calculations. In our previous work, we have proposed an optimization strategy that substantially improves the iteration speed and have used the method to calculate electrostatic interactions in the dielectric homogeneous system with excellent accuracy. [46] In this paper, the motion of charged polymers in a twodielectric model was simulated using finite difference scheme and simple yet effective interface treatment. We propose an iteration optimization strategy for large charged systems and further optimize the algorithm according to the shape of the polymer, which greatly improves the computational efficiency and saves a substantial CPU time. The rest of this paper is organized as follows. Section 2 presents the simulation model and the calculation scheme of interface problem, and proposes the corresponding algorithmic optimization strategy. In Section 3, we first verify the viability of the SOR global iteration method based on the FDM for the calculation of electrostatic forces. In addition, we are devoted to discussing the effects of the parameters in the "local iteration" on the computational speed and accuracy. The computational efficiency and adaptability of the banded local iteration method are further validated extensively. Finally, we draw some conclusions, and provide brief overview and some prospections in Section 4.

The Biomolecule-Solvent and Polymer Model
We construct a coarse-grained computational model for the movement of the charged polymers in a solvated biomolecular system, which can be described by the Poisson-Boltzmann equation (PBE) or viewed as a Poisson equation carrying a series of singular charge sources. As shown in Figure 1, the computational domain Ω is separated by the molecular surface Γ into the solute (biomolecule) region Ω m and the solvent region Ω s , that is, The boundary of the entire domain is Ω. In continuum models, biomolecules are usually approximated as homogeneous dielectrics, and the relative permittivity is taken to be between 1 and 20 (here set it as 1). In our simulations, in order to capture some important physical properties of biological systems more accurately and to further improve the quality of the classical Poisson model in electrostatic models, the dielectric value of the solvent region is replaced by a dielectric function dependent on the electric field strength. [47] The dielectric coefficient of the whole computational domain is a piecewise constant function given as where m is the biomolecule region dielectric constant (the interface dielectric constants are assigned as the harmonic average of the solvent and solute dielectric constants), n is the optical refractive index, N 0 is the number of molecules per unit volume, is the dipole moment of the water molecule, 0 is the vacuum dielectric constant, and E is the field strength. L(x) denotes the usual Langevin function, and are numerical factors, T and k B represent the absolute temperature and Boltzmann constant, respectively. In our numerical implementation, the molecular parameters at T = 300 K have values as following, n = 1.33, N 0 = 3.334 × 10 28 m −3 , = 2.1 D, = 28∕3 √ 73, = √ 73∕6. In the biomolecular region, the charge distribution is usually fixed because the charged particles are bound by chemical bonds and are not easily affected by the surrounding electrostatic field. For the solvent region, however, the charged particles (Na + , Cl − , K + , Mg 2+ , etc.) in the solution will change their spatial positions frequently due to the influence of the surrounding electrostatic field and the collision effect of the particles. Therefore, we use a probabilistic approach to quantitatively describe the distribution of charged particles in solvent. By Gauss's law, the system of equations for the electrostatic potential u(r) of the model is expressed as [u] Γ = 0, r ∈ Γ (4) where m (r) can be expressed by the sum of a series of Dirac-Delta functions, which are redistributed to their neighboring grid points with appropriate interpolation formats. Thus the secondorder or higher-order numerical accuracy at Cartesian grid points is realized. s (r) denotes the charge density distribution func- Clearly, both (r) and u have unit m − 2 due to C 2 ∕(FJ) = 1. Hence, the both sides of each equation of (2) have the same unit m −2 , which can be removed from the both sides of each equation to make (2) become dimensionless. The solution u of the Poisson model is called the dimensionless electrostatic potential. When u is found, the electrostatic potential Φ can be simply said to have a value of u in units k B T∕e c . Equations (4) and (5) are the interface jump conditions across the molecular surface with as the outer normal direction, where u = u is the directional derivative in . Mathematically, the uniqueness of the solution is ensured by jump conditions. Physically, these conditions are necessary for the continuity of the electrostatic potential and its fluxes across the interface. Here, for grid-based approach, the computational domain Ω is still assumed as a cube. As shown in Figure 2, we fix the electric potential on the left side of the simulation box as U and further get a Dirichlet boundary condition imposed on Ω.
We put a polymer into the domain Ω, which is modeled as a conventional bead-spring chain consisting of N beads connected via the finitely extensible nonlinear elastic (FENE) potential [48] U FENE (r) = −0.5k b b 2 ln(1 − r 2 ∕b 2 ) the excluded volume interactions between the beads are considered through the Lennard-Jones (LJ) potential [49][50][51] U LJ (r) = 4 [( ∕r) 12 − ( ∕r) 6 ] + , r ≤ 2 1∕6 where r and b are the bead-bead distance and the maximum bead-bead separation distance between consecutive beads along the polymer chain, k b denotes the spring constant. represents the strength of the LJ potential, is used as the unit of length in this work and is the collision diameter of the LJ potential. Additionally, the charge of beads in the polymer is assumed to be q. The Poisson equation is solved with the interface and boundary potential conditions to compute the electrostatic interactions between charged beads. Hence, the Brownian dynamics can be applied to simulate the diffusion of charged polymers, including a noise term and a friction term. After specifying the interaction potentials, the BD equation of motion for particle i iṡ where U i denotes the sum of all the interaction potentials discussed above, is the friction coefficient. ⃗ f i (t) represents the random force associated with through the fluctuation dissipa- where I is the unit tensor. The equation of motion of the charged polymer is integrated based on the time step Δt. In our model, we present our results in reduced units, which result in a unit of the time as t = t * ( ∕m 2 ) 1∕2 , the charge as q = q * ∕(4 0 ) 1∕2 , and the electric field as E = E * (4 0 ) 1∕2 ∕ . Where , and m denote the units of length, energy and mass, respectively. We assume that = = m = 1 and the temperature is k B T = 1.0, and the friction coefficient is set as = 0.5Δt −1 . Additionally, the dimensionless parameters of the polymer are fixed as k b = 30 and b = 1.5, the charge of beads in the polymer is q = 10, and the time step is chosen as Δt = 0.0002. We fix the size of the simulation box as L = 80 , the electric potential of left surface as U = 4.

Improved Interface Computation Scheme
This work mainly focuses on the fast solution of electrostatic interactions between charged particles in polymers with an applied electric field under the dielectric inhomogeneous system. While considering a uniform Cartesian mesh division of the domain Ω, the standard finite difference format loses its designed convergence around the interface. Hence the interface jump condition must be used to recover the accuracy. In order to achieve a smooth extension of the electric potential values, it is necessary to derive the computational expressions of the molecular interface, which is crucial for the situations where the interface intersects or does not intersect with the grid nodes. For this purpose, we divide all grid points into two categories: regular and irregular grid points. An irregular grid point is defined as a node in the standard finite difference format containing grid points that span the interface, that is, at least one of its six neighboring points is from different region. Otherwise, the points far from the interface Γ are regular points, performing the standard 7-point central difference to discretize Equations (2) and (3). As shown in Figure 3, the blue and orange solid dots represent irregular points from the solute and solvent regions, respectively. The green and pink dots represent interface points that intersect and do not intersect with grid nodes, respectively. In our scheme, the difference format of irregular points is derived first, and then the computational format of interface points obtained by discretizing the interface conditions is substituted to modify the finite difference approximation of irregular points.
For the electrostatic equations in 3D space with irregular dielectric interfaces, there are two interface conditions at any direction along the interface. In this way, the continuity of the potential flux Equation (5) is directed toward the normal direction . At a given intersection point, it is convenient to introduce a coordinate transformation from ( , , ) to (x, y, z), where and are the tangential and subnormal directions, respectively. Thus, the flux continuity condition Equations (4) and (5) are projected locally into the Cartesian grid [ u ] = s (u s x cos cos + u s y cos sin + u s z sin ) − m (u m x cos cos + u m y cos sin + u m z sin ), (12) where denotes the angle between and its projection on x-y plane while is the angle between this projection and x-direction. u s x and u m x denote the first order derivatives in the x direction from different regions, respectively. In a uniform grid, the interface either intersects or does not intersect with the grid points.

www.advtheorysimul.com
We first discuss the case where the interface intersects the grid points. At this time, all the irregular points use the successive over-relaxation (SOR) iteration scheme with standard 7-point difference where i, j and k denote the node position in the discretized grid, h is the grid spacing in the x, y, and z directions, the superscript n and n+1 represent the current iteration step and next iteration step, respectively. is the relaxation factor. It is possible to estimate numerically the optimal value of the parameter in the SOR method in some cases. [28] For instance, the optimal relaxation factor can be obtained according to the dimensions of the computational domain for both solvent and solute, that is, where L min is the minimum grid number of the simulation box in three directions. For the irregular points u i,j,k in Equation (13), we assume that one of its six adjacent nodes, u i,j+1,k , is an interface point, then we need to combine Equations (5) and (12) to derive the interface point formula rather than use its value directly, according to the above equation, we will replace the interface point u i,j+1,k in Equation (13) with the following formula with T 1 = cos cos , T 2 = cos sin , and T 3 = sin . In addition, in the situation where the interface does not intersect with the grid points, the standard 7-point difference scheme is no longer used for irregular points. We combine the mesh division and the geometry of biomolecule to identify the nodes involving interface in six directions, further deriving a 7-point difference scheme containing the interface points. We use a secondorder accuracy approximation for 2 u x 2 , 2 u y 2 , and 2 u z 2 , which means that an additional point is needed in the direction involving the interface point to compensate for the loss of accuracy due to the interface. As shown in Figure 4, u i,j,k has an interface point u b,j,k among the difference points in the x-direction, then an additional difference point u i+2,j,k should be added. Using Taylor expansion and after algebraic operations, 2 u x 2 can be discretized by u b,j,k , u i,j,k , u i+1,j,k , and u i+2,j,k , and its second-order accuracy expression is In order to obtain a second-order accuracy approximation for 2 u y 2 and 2 u z 2 , a similar process must be performed. In Figure 4, taking the x and y directions involving the difference points as an example. After discretizing the Poisson equation, we will obtain the SOR iteration format of u i,j,k Adv. Theory Simul. 2023, 6, 2200776 where and denote the distance ratios of u i,j,k to the interface points in the x and y directions, respectively. Furthermore, the modified finite difference approximation at irregular points maintains second-order accuracy, provided that the interface point expressions are accurately estimated. Therefore, the interface points u b,j,k and u i,f,k have their special expressions in the above computational format. Inspired by Zhou, [41] we use a linear combination of the interface jump conditions to eliminate any two first-order derivatives that are not easily approximated, which two are eliminated depends on the molecular geometry. A specific example is discussed to further illustrate the expression for the interface point B according to Figure 4. We will keep u m x and u s x to generate the jump condition along the x-direction. In the y-direction, it is more difficult to calculate u m y at (b, j, k) than u s y . In the z-direction, computing u m z at (b, j, k) is more difficult than computing u s z . Therefore, u m y and u m z will be eliminated by Equations (10)- (12) in interface format where the superscripts m and s represent the molecular region and the solvent region, respectively. u x , u y , and u z are the derivative of the electric potential, which are defined in the normal direction at the dielectric interface. Then, through approximating the remaining four first-order derivatives, we obtain the expres- where C s x = s cos cos + m tan sin cos + m sin tan Note that the auxiliary points u b,j−1,k and u b,j,k+1 are not grid nodes in the above equation, which can be calculated by interpolating points on the same horizontal line in the same region. For example, we interpolate u b,j−1,k with u i−2,j−1,k , u i−1,j−1,k and u i,j−1,k , and then substitute these interpolations back into the above interface point expression. In addition, these solutions can be extended to more complicated macromolecular (solute) shapes.
For the discretized Poisson equation, a successive overrelaxation iteration (SOR) stabilized solver is adopted to solve the linear system. The maximum numerical error is measured, in terms of the discrete L ∞ norm where r i is the regular grid points in solvent and solute region (use standard 7-point differential scheme) or the irregular grid points near the interface (use new interface scheme), and the total number is denoted as N. Here, u exa (r i ) and u num (r i ) are the exact solution and the numerical solution, respectively. We are interested in examining the performance of the proposed method on the interface by comparing it with the standard 7-point differential scheme.
We conducted a number of numerical experiments to examine the performance of the proposed new computational scheme near the interface, with particular attention to the order of convergence. As shown in Table 1, the grid spacing h = 0.01 is set as the exact solution (there is no exact solution since the right-hand side function of the model equation is obtained from the random motion of the polymer and has no fixed form). Through solving Equations (2) and (3), we report the electrostatic potential error e u and its convergence order regarding the grid refinement. As can be seen from Table 1, the new computational format achieves very similar results to the traditional format in terms of electric potential. The numerical results indicate that the convergence in electric potential error e u is second order. As far as the poten- tial value is concerned, the results obtained at coarse grid (e.g., h = 1.0) are very close to that at the exact solution (i.e., fine grid h = 0.01).

Proposed and Optimized Local Iteration Strategy
Above interface treatment scheme lays the basic framework for solving elliptic interface problems. Solving the differential discretized system of equations using SOR iteration indeed has certain advantages. While in Brownian dynamics, one usually need to compute millions or even tens of millions of time steps, which means that the calculation of electrostatic interactions will take a lot of time. Actually, the charged particles in polymer tend to occupy only a small region in simulation box, and the spatial distribution of electrostatic potential changes little due to the small perturbation in dielectric and charge distributions at each step during such simulations. Especially when an electric field was applied, we find that the value of electric potential hardly changes within a certain time interval for grid nodes that are far from the charged polymer. This result suggests that in a short simulation time, one can save most of the iteration time if we only calculate the electric potential of grids near the charged polymer. The electric potential for other grids is fixed and updated after several steps. Overall, we can save substantial insignificant iteration time by using local iteration instead of global iteration while without much compromise in accuracy. Three important parameters need to be introduced here to ensure that the local iteration method can improve the computational efficiency while also guaranteeing a certain accuracy. As shown in Figure 5, we first locate the spatial location of the beads in polymer and enclose them with a minimal cubic basal box (A 1 B 1 C 1 D 1 ). Then, from six sides of the basal box, we extend outward the grid of L w units to form a "local box." Once the "local box" exceeds the boundary of the domain Ω in a certain direction, it will not further extend. Additionally, the parameter d step is defined as the step interval between the first global iteration and the next global iteration. We also set a warning value (L d ), which is considered as the threshold for updating the local iteration area. When the nearest distance between the basal box and the "local box" is equal to the warning value, the "local box" will be re-divided based on current position of basal box.
In fact, we can further optimize the local iteration method for polymers with special shapes. If the polymer is clustered on a certain plane (e.g., x-y, x-z, y-z), then local iteration can maximize its advantages. However, when the polymer is diagonal or dispersed in 3D space, the efficiency of the speedup is dramatically reduced. To address the adverse effects of these shape characteristics, we propose an adaptive banded local iteration strategy and expect that this approach will save a significant amount of computational expense and further improve computational efficiency. As shown in Figure 5, the banded iteration area is marked in green. The previous local iteration method is called traditional local iteration (TLI) method, [46] and the new adaptive local iteration strategy is called banded local iteration (BLI) method. Importantly, it is quite common for polymers to overlap domains in molecular simulations. In response, our algorithm is also able to accurately locate the banded local iterative regions.
In our model, a new interface format is derived using a Cartesian grid, a standard finite difference scheme, and the lowest order interface jump condition. Then, the format is combined with a local iteration method to solve the elliptic equations with discontinuity coefficients and relatively smooth interfaces to simulate the movement of the polymer. We are more concerned with the performance of the local iteration algorithm under dielectric inhomogeneity rather than with how to handle interface problems with singularities. Since there has been a lot of work on the explicit interface treatment of geometric singularities, which is not the focus of this paper. Therefore, we only calculate two molecular examples with different geometrical features and classify them into two categories: molecular interfaces and grid nodes all intersect (called prism example) and partially intersect (the solute shape similar to peanut, called ellipsoid example). In different molecular configurations, we simulated three cases (as shown in Figure 6) in which the same shape of polymer was put at three different initial positions: the solvent region, the intra-molecular region, and the junction of solvent and biomolecule, respectively. Finally, we enumerate two polymers with special shapes, and compare the numerical results of traditional local iteration and banded local iteration in two different molecular configuration computational domains.

Results and Discussion
In the numerical experiments, all codes were written in Matlab 2017b and run on PC with Intel Core i5-7500 CPU (3.40 GHz) and 8 GB RAM. At first, independent effects of three parameters (L w , d step , and L d ) on the computational speed and accuracy are briefly discussed. Additionally, we mainly focus on three aspects of simulations: the polymer motion at different positions in computational domain, the intersection of molecular interface with grid points (i.e., molecular shape), and the shape of the polymers. In order to make the results clearer and more universal, we will use the relative values, that is, RL w = 2 × L w ∕L, RS = d step ∕Step, RL d = L d ∕L w . For example, a local box is formed by extending L w units in six directions from the center of the basal box, thus RL w portrays the relative size of the local box well. When RL w = 100%, whether the "local box" completely covers the simulation box depends on the initial position of the charged beads in a polymer.
Benchmarked with SOR global iteration solution, both terms of accuracy and computational efficiency are investigated for the local iteration method through 3D simulation. In terms of accuracy, we report the electric potential error and the error in the ultimate position of charged particles because the final objective is to simulate the motion of charged particles, which needs an accurate calculation of the spatial potential distribution and ultimate position of the polymer. Therefore, the relative error of potential and relative position error of charged particles are defined as follows where Θ RMS denotes the root mean square sign, the overall similarity of the polymer conformation is checked by calculating the RMS (root mean square) deviations of all charged particle positions and spatial electric potential. U global and U local represent the potential distribution at each charged particles in the global iteration and the local iteration, respectively. Pos initial , Pos global , and Pos local denote the 3D spatial coordinates of charged particles in the initial, global iteration and local iteration, respectively, and the displacement distance of each particle is expressed by the absolute value of the difference between them. In terms of computational speed, the CPU times of global iteration (denoted as t G ) and local iteration (denoted as t L ) were recorded and compared.
In previous work, [46] we chose a simulation time of 10 000 time steps, which was long enough to test the stability of the simula- tion results. However, the global iteration simulation under dielectric inhomogeneity takes a lot of CPU time, so that we set the total step number of motion Step = 1000 in all simulations. In order to verify the validity of the SOR global iteration method based on a finite difference scheme (with a grid spacing h = 1), we compare it with existing conventional algorithms for calculating electrostatic forces. In particular, the Coulomb formulation, an exact method for solving electrostatic interactions, will be used to evaluate the validity of our proposed numerical method. During the simulation, we use the global iteration method and Coulomb's formula in the section of solving for the electrostatic force respectively, while keeping the settings consistent in all other sections, and then record the CPU time and numerical results such as particle position and spatial potential. We display the CPU time as a function of the number of charged particles (Num) for these two methods in Figure 7. The comparison results indicates that as the number of charged particles increases, the CPU time of these two methods both exhibits an increase. However, the SOR method is different from the Coulomb formula for solving the electrostatic force directly, which is insensitive to the increases in Num. Obviously, as the number of particles increases, the SOR global iteration only increases the workload of interpolating more charges to nearby nodes, which can even be ignored compared with time-consuming iteration loop. On the contrary, with increasing number of particles, the CPU time of the Coulomb formula increases significantly. The numerical results indicate that the SOR method is more suitable for large-scale charged particle system. This conclusion is supported by the results in the inset of Figure 7, where the computational efficiency of the global iteration gradually outperforms the Coulomb formula when Num > 400. As Num continues to increase, the computational efficiency advantage of the global iteration becomes more pronounced, and it is nine times more efficient than the Coulomb formula when Num = 1500. In general, the calculation complexity of the Coulomb formula is O(N 2 ),  while the calculation complexity of a single iteration of the SOR global iteration method with optimal relaxation parameters is between O (NlnN) and O(NlgN). Theoretically, there is a significant difference in computational effort between the two methods, and Figure 7 should show a corresponding CPU time difference. In fact, the iteration method requires a loop of iterations until the convergence criterion is satisfied. We assume that a complete loop process requires the implementation of n iterations, then the total computational effort to compute the single electrostatic force needs to be multiplied by a factor n. In addition, using the results of the Coulomb formula as a benchmark, Table 2 shows the root mean square deviation of the charged particle position and electric potential for global iteration method. We find that as NUM increases, both RE U and RE Pos increase. In the RE U term, as Num increases from 100 to 1500, the error increases by only about 1.12e−3. In the RE Pos term, although the error increases from 6.66e−4 to 1.05e−3, we can observe that the increase in error is not significant when Num > 1000. Overall, the two errors are controlled to be below 3.16e−3 and 1.05e−3, respectively, both in the 1e−3 magnitude, which is an acceptable error range for the experiment. Therefore, it is a feasible scheme to apply a global SOR iteration method based on a finite difference format to solve the electrostatic force and thus simulate charged polymer motion.
In Figures 8 and 9, parts (a) and (b), we display CPU time t and the relative error as a function of RL w (the length ratio of "local box" to "global box"), respectively, where the relative error is divided into two parts with the relative error of electrostatic potential (RE U ) and the relative error of the final position of the beads (RE Pos ). Meanwhile, the dimension of simulation box was set as L = 80 with grid spacing h = Δx = Δy = Δz = 1, which means that the total number of grid nodes is 81 × 81 × 81. The number Figure 9. The case of polymer in internal region of the solute: a) CPU time t and b) the relative error of electrostatic potential RE U as a function of the length ratio between "local box" and "global box" (RL w ). The relative distance between charged polymer and boundary is set as RL d = 80%. RS represents relative global iteration step interval, and t G in (a) represents the global iteration time. The inset of (b) shows the relative error of the final position of the charged particles (RE Pos ) as a function of the relative size of local box (RL w ).
of charged particles in polymer is set as Num = 500 (the FDM method has significant advantages for handling electrostatic interactions containing large numbers of charged particles), the relative distance between charged beads and boundary RL d = 80%. And the value of relative global iteration step interval RS is set as 10% and 25% in simulations to explore the impact of update frequency of global iteration on the computational speed and accuracy. After verification, we find that the increasing RL d is beneficial to reduce RE U , while the CPU time only slightly increases at the same time. Therefore, we uniformly set RL d in all the examples to 80%. Under these conditions, we calculate t G , t L , RE U , and RE Pos of the two numerical examples of prismatic and ellipsoidal biomolecules, in which the numerical results of different examples are represented by different colored lines. Based on these two examples, we constructed three cases as shown in Figures 8  and 9.
Initially, as shown in Figure 6, we put the polymer chain in solvent area and the charged particles of the polymer chain are under electrostatic interaction, elastic force and repulsive force to obtain an equilibrium conformation (case 1). For the solvent region, real-time updating of the dielectric value everywhere in the solvent area may spend more computing costs because the dielectric value is not a constant but as a function of the electric field strength, which implies that the calculation of electrostatic interaction will consume more CPU time. However, these calculation costs are necessary since the dielectric response can accurately capture certain characteristics of the biological process. As shown in Figure 8a, with the decrease of RL w , the CPU time decreases. Obviously, reducing the local iteration domain means saving a part of the iteration time. In addition, the computational expense of iteration increases with the decrease of RS. In other words, as the RS decreases, the frequency of global iteration increases and the cumulative error decreases, which further leads to the increase of total CPU time and the decrease of RE U . These results imply that a smaller RL w and a larger RS are beneficial to improve calculation efficiency. Under the same conditions, the ellipsoid group reported significantly more CPU time than the prismatic group. There are two main reasons: in the program of ellipsoid example, it is necessary to open up an independent space to store the information of interface values that do not in-www.advancedsciencenews.com www.advtheorysimul.com tersect with nodes. Otherwise, the calculation format of these interface points is more complicated. As the local box continually expands, we find that the t L of both prismatic and ellipsoid examples are approximately equal to t G when RL w = 90%, because the smallest basal box occupies part of the computational domain. It's worth noting that during RL w increasing from 35% to 60%, a significant increase in the CPU time was recorded. According to the preliminary analysis, when RL w < 35%, the local iteration is only performed in the solvent area. With the successive increase of RL w , the local iteration range further covers the molecular (solute) area. As a result, the computational complexity of nodes near the molecular interface significantly increases the CPU time. When RL w > 60%, the local iteration area completely covers the entire biomolecule, and this trend stabilizes. Besides, the results of RE Pos illustrate the relative error of the polymer translocation, where the RE Pos and RE U share a similar change trend. As shown in Figure 8b, RE U and RE Pos decrease with the increase of RL w . These results indicate that choosing a larger RL w gets closer to the global solution. We find that the RE U has dropped by an order of magnitude when RL w ≈ 18%. Moreover, we also find that there is a difference in RE U between the two examples. The reason for this phenomenon is that the ellipsoid calculation example compensate the loss of accuracy by repeatedly using the interface conditions and adding iteration nodes near the interface. Importantly, when RL w = 7.5% and RS = 25%, the single most striking observation to emerge from the data comparison was the calculation speed of the two examples is increased by 20 and 17 times respectively, and the RE U is controlled below 3.2e−4.
Besides, we also put the polymer chain in solute area and observed its motion and the performance of local iteration method (case 2). The results in Figure 9a show that CPU time decreases with the decrease of RL w . At the same time, a decreasing RS also induces the decrease of CPU time under the same RL w . As shown in Figure 9b, with the increase of RL w , the RE U first decreases rapidly, then remains unchanged. In the inset of Figure 9b shows the relative position error (RE Pos ) as a function of RL w , which decreases as RL w increases. In fact, if RL w is large enough the error will be almost negligible. These situations are very similar to case 1, which is exactly what we expected. Consequently, we can get a conclusion that the local iteration algorithm is not affected by the spatial position of the polymer, which reflects its stability. Interestingly, we find that when RL w < 50%, cases 1 and 2 presented large differences in CPU time. Theoretically, as long as the local box does not contact with the molecular interface, the node values in the local iterative domain are calculated by the standard 7-point center difference scheme. However, because the molecular volume is only 1.5% of the computational domain and the large number of charged beads in polymer located inside the biomolecule has occupied almost the entire biomolecule (Num = 500), it drives the local box to contact the molecular interface prematurely (in case 2). Therefore, the computational amount of case 2 is much higher than that of case 1 even in the initial stage of RL w increase. In a way, the acceleration effect of local iteration in case 2 is not as good as that in cases 1 and 3.
In fact, as shown in Figure 6, setting the polymer chain at the junction of solute and solvent area is another important situation for exploring the molecular behavior on singlemolecule Figure 10. The case where the polymer is located at the solute-solvent junction: a) CPU time t and b) the relative error of electrostatic potential RE U as a function of the length ratio between "local box" and "global box" (RL w ). The relative distance between charged polymer and boundary is set as RL d = 80%. RS represents relative global iteration step interval, and t G in (a) represents the global iteration time. The inset of (b) shows the relative error of the final position of the charged particles (RE Pos ) as a function of the relative size of local box (RL w ).
level, which takes charged polymer intersected vesicles as prototype (case 3). Fast calculation of electrostatic potential provides convenience for applications of vesicles in pharmaceutical and physiological processes. As shown in Figure 10a, with the increase of RL w , the CPU time first increases rapidly, and then the rate of increase becomes slower. Similarly, Figure 10b shows that RE U decreases with the decrease in RS for the same RL w , which indicates that increasing the frequency of global iteration can significantly reduce the accumulation of errors. When RL w = 37%, the CPU time of the ellipsoid example gradually draws a significant gap with the prism example. It is also at this stage that the growth in CPU time becomes stable. Overall, the result of case 3 is very similar to the other two cases, which is consistent with our expectations. While, the CPU time of case 3 first increases rapidly and then increases slowly, opposite to cases 1. Through analysis, we find that this has a great relationship with the region contained in local iteration box. When the polymer spans two regions, no matter how small the local box, the initial calculation will always involve interface nodes, leading to more difficult iterative solution. Additionally, in the process of polymer movement, free moving ions are distributed on the left, while fixed charges are distributed in the solute region on the right, which further increases the computational cost. Even though the calculation speed decreases slightly, when RL w = 7.5% and RS = 25%, the computation efficiency still increased by 8.2 times compared to the global iteration in the ellipsoid numerical example.
In order to further investigate our analysis in detail, we combine the results of the three position cases of the two calculation examples and shown them in Figures 11a and 11b, respectively. The left axis and right axis denote CPU time t and the relative potential error (RE U ) as a function of RL w , respectively. First, with the increase of RL w , the CPU time increases. Meanwhile, the decrease of RS is also an important factor for the increase of CPU time. We find that t G is almost equal for the three cases in the same numerical example (e.g., ellipsoid example is about 41 000 s), this indicates that the global iteration time is independent of the polymer placement and is only related to the molecular conformation. Furthermore, by comparing the simulation results of Figure 11a,b, it clearly implies that t G of the ellipsoid example is always large than the prismatic example under same conditions. Accordingly, it is further verified that the CPU time of the global iteration only depends on the calculation format and has no relationship with the position of the polymer. We know that the potential value around the molecular interface is the major calculation consumption in the dielectric inhomogeneous system. It also explains that the CPU time of the dielectric inhomogeneity is much more than the dielectric homogeneity in global iteration. When the curves of all cases are plot in figure, we can clearly observe some differences, the overall trend of the connection between RL w and CPU time is very similar, but the computational efficiency changes at different RL w (note that the difference mentioned above is not related to the numerical example, but only to the spatial location of the polymer, thus the two diagrams are described uniformly): i) for case 1, the computational efficiency is greatly improved in the initial stage, and the CPU time increases slowly. When RL w > 35%, the CPU time increases suddenly and rapidly, ii) in case 2, the rate of the change in computational speed is different from that of case 1 (RL w = 25%), because the solute region is smaller than the solvent region. When the local iteration domain is expanding, case 2 covers the interface area earlier than case 1. Undoubtedly, the calculation of the potential value around the interface occupies most of the CPU time. Hence, the CPU time grows rapidly when RL w = 7.5-25% and then increases slowly. iii) As expectation, this is further verified in case 3, which shows a similar phenomenon to case 2. In the RL w < 37% stage, the CPU time increases rapidly, which is not only related to the current position of the polymer (the junction between solute and solvent), but also has a certain relationship with the direction of polymer movement. The polymer moves toward the interior of the biomolecule under the action of the applied electric field force and the electrostatic force in the electrolyte solution, so that the speed of the local box covering the molecular region becomes faster. Until the critical value 37% is exceeded, the molecular region is completely covered. As RL w increases continuously, the local box expands the number of nodes in the solvent region, so that the increase rate of CPU time gradually slows down.
Additionally, as shown in Figure 11a,b, with the increase of RL w and the decrease of RS, the value of RE U decreases significantly. However, the RL w -RE U function curves of the three cases seem to have some differences. In the discussion of interface point calculation format, we construct a high-precision discrete difference scheme via adding differential nodes. Therefore, we consider that the major error originates from the solute and solvent region (7-point center difference scheme) rather than the region around the interface (high-precision difference scheme). And we also infer that this is opposite to the change trend of CPU time. Numerical results prove that the initial error of case 3 is the largest, because the polymer is originally located at the solutesolvent junction. The electric potential in the region of major error source is not updated for a period of time, which will lead to an error propagation effect and increase RE U . For cases 1 and 2, the smaller RL w makes the local box only work in the solvent or solute region, so that error propagation in the solvent or solute region is blocked. Theoretically, according to current simulation data, we can explore the optimal parameter selection for each numerical example, that is, the intersection of the same set of curves, which is marked as solid circle symbol in Figure 11. Obviously, the optimum point does not have the best acceleration effect, but it is the most cost-effective situation, which is a good balance between computational efficiency and accuracy. For example, in case 1 of the ellipsoid example (Figure 11a), the optimal parameters of the ellipsoid example are RL w = 28%, RS = 25%, RL d = 80%. Certainly, if test more parameter combinations, you may get a better parameter group. In addition, in both Figure 11a,b under the same case, even different RS are selected, the optimal parameters almost remain within a certain interval. For instance, in case 1 of Figure 11b, RL w = 15-20% is the optimal choice, while in case 3, the optimal RL w takes the value between 19% and 23%.
As noted above, we now examine the performance of the local iteration method for simulating the motion of charged polymer under two different shape of solute molecular models. Generally, one find that local iteration performs well when the type of the polymer is clustered or planar. However, once the shape of the polymer is scattered or diagonal, the effect of local iteration will be greatly reduced. This causes certain challenges to the universality of our algorithm. In addition, the computational difficulties caused by the special iteration scheme of the nodes around molecular interface bring another challenge to the total CPU time. Therefore, in order to improve the local iteration method, we learn from the original optimization ideas of the traditional local iteration (TLI) to further reduce unimportant iterations time. We do this by constructing a compact base box that tightly wraps the polymer. That is, the configuration of the initial base box is the same as the polymer shape, which minimizes the unnecessary iteration area. Another advantage of this approach is that even the shape of the polymer is constantly changing as it moves, the adaptive banded local iteration (BLI) can locate the current shape of the polymer in real time, and expand RL w units in six directions to form local box. Note that we cancel the warning value RL d in the BLI method, because many numerical experiments show that it does not spend much time to re-divide the local box frequently.
Finally, we simulate two polymers of different shapes under two models with different molecular structures, using a banded local iterative approach. Figure 12a,b display the CPU time (t) as a function of the relative length of the local box (RL w ) at the relative global iteration step interval RS = 25%. With the decrease in RL w , the iteration domain reduce, which results in a decrease in CPU time. On the other hand, RE U decreases with increasing RL w . In terms of error, when RL w < 25%, the RE U of the ellipsoid nu- Figure 12. a,b) The left axis and right axis denote CPU time t and the relative potential error RE U as a function of the relative size of local box (RL w ), respectively. Marked the CPU time and error for the equal conditions with a same color line, where the solid represents the CPU time and the hollow represents the RE U , and the intersection point is defined as the optimal parameter point for this group (mark with solid circle). The inset is sketched a simple 3D coarse-grained model of the polymer. (a) simulates a diagonal type polymer, and set it at the junction of solute and solvent, (b) simulates a scattered type polymer, and put it on the solute region. merical example is always lower than that of the prism example. This result coincides with our aim to construct a high-precision differential scheme by adding differential nodes at the disjoint interface points. Surprisingly, compared to global iteration, BLI method has better acceleration efficiency than TLI method, accompanied by a decrease in accuracy. As shown in Figure 12a, we first consider a diagonal type of polymer (3D), in which the position of the polymer is at the intersection of the solute and solvent. The effects of BLI method on CPU time and accuracy in different numerical examples are evaluated. In this situation, we only increase the simulation efficiency of the TLI method by about three times compared to that of the global iteration due to the limitations of its strategy and polymer shape. As from the inset of Figure 12a, we can imagine the diagonal polymer as a 3D diagonal matrix with a large number of "zero elements," and try to get faster computation speed by cutting these unnecessary nodes. In Figure 12a, we observe that the computation speed of BLI method is ≈ 25 times faster than the global iteration (t G is about 34000-42000 s). Now, the TLI method takes almost nine times as much CPU time as the BLI method. We also focus on the variation in error. Under the same conditions, the error of the BLI method is higher than that of the TLI method, but is still in the same order of magnitude (10 −4 ), which demonstrates that the BLI has a higher benefit. Moreover, we wanted to verify the performance of the BLI method with a polymer of scattered type, which is also put in the solute region (similar to case 2). We can see the powerful acceleration advantage of BLI method in Figure 12b. When RL w = 7.5%, the computational efficiency improves 29 times over the TLI method, reaching a peak. At the same time, RE U increases from 2.48e−4 to 5.15e−4. We find that the computational efficiency of BLI method can be increased by at least 3.3 times, while the TLI method can only improve the computational efficiency at most 2.8 times, which shows that the BLI method indeed improves the computational efficiency. Otherwise, the results demonstrate that BLI method not only improve the simulation efficiency for polymers with special shapes, but also for case 2 in Figure 9 (where the performance of TLI method is not excellent, only 5.6 times at most). By reducing the iteration area, the local box contacts the interface more slowly and results in improved simulation efficiency.
We further extract the optimal parameters from two examples, which can be seen from Figure 12a,b. The current numerical results show that the optimal banded local box size is RL w = 34% in the prismatic example and RL w = 32% in the ellipsoid example for simulating the motion of diagonal polymers. Furthermore, when the shape of the polymer is scattered, the optimal band local box relative size is selected as 34% and 30%, respectively. By comparing and analyzing Figure 12a,b, we find that for the polymer of different shapes, if use the same local iteration algorithm, the optimal parameter ranges are very similar. When the TLI method is used, the optimal RL w is ≈ 30% to 34%. However, for the BLI method, setting RL w = 10-15% can achieve the best balance between computational precision and computational cost. This simulation result implies that the distribution interval of the optimal parameters appeared to be unaffected by the shape of the polymer and is more related to the type of local iteration method.

Conclusions
In this work, using a hybrid simulation approach that combines a finite difference method and a Brownian dynamics model (FD-BD) for the polymer, we study the diffusion of charged polymers in the dielectric inhomogeneity system. We believe that further optimization of the hybrid FE-BD approach might include the following. Perhaps the main difficulty is need to solve an equation based on a discontinuous medium in the entire domain, that is, the Poisson equation with variable dielectric coefficient. We propose a new computational scheme based on FDM with second-order accuracy and effectively handles with the interface problem posed by such equations, achieving a smooth transition of the potential value from one region to another. The numerical results show that the improved scheme has a second order of convergence. In addition, we validate the validity of the global SOR iteration method based on the improved interface scheme. It is an excellent numerical tool for simulating charged polymer motion since its computational efficiency is better than the traditional Coulomb formula. However, in simulations that involve millions or even tens of millions of time steps, such computational efficiency is far from adequate. In order to avoid the iterative section to occupy too much CPU resources, the local iteration method is used to accelerate this process. In the simulations, we modeled numerical examples of two different biomolecule configurations (ellipsoid and prism) and put the polymer of same shape in the solvent region, the solute (biomolecule) region, and the solute-solvent interface, respectively. As expected, we find that both the decrease in RL w and the increase in RS can significantly reduce CPU time and thus improve computational efficiency, while the corresponding cost is the increase in error. We also find that although the overall trends of computational efficiency is very similar for the three cases, they exhibit slight differences in the inflection points of the magnitude changes: as local box continues to expand, computational efficiency is expressed as the solvent region > the interface > the internal region of solute in the early stages, while in the late stage, the internal region of solute > the interface > the solvent region. In general, the variation in the magnitude of computational efficiency depends on the rate at which the local box covers the molecular interface. In addition, our simulation results demonstrate that the error of local www.advancedsciencenews.com www.advtheorysimul.com iteration method increases as the distance between the polymer and the molecular interface decreases.
We further discuss the optimal parameter sets in the numerical experiments of this paper, which are chosen by combining both computational speed and accuracy for the sake of reasonableness. For example, RL w = 28%, RS = 25%, RL d = 80% are the optimal set of parameters for case 1 in the ellipsoid numerical example, where the computational efficiency is improved by 4.5 times compared to the global iteration, and RE U is controlled below 9.5e−5. Importantly, in all cases of the ellipsoidal example, RL w is basically concentrated between 10% and 28% to ensure the best results of simulation, while in the prismatic example it takes values from 12% to 23%. Accordingly, the optimal parameters are determined based on different examples. In this way, the local iteration method effectively solves the computational complexity of global iteration in the dielectric inhomogeneous system, which saves a significant amount of CPU time.
However, we observe that the traditional local iteration (TLI) method does not have significant acceleration effect for the polymers of two particular shapes. Therefore, we propose the banded local iteration (BLI) method, which is better adapted to the effects of deformation of the polymer during motion. Our results indicate that the BLI method additionally improves the computational efficiency over the TLI method. In particular, when the polymer shape is scattered, the BLI method improves the computational efficiency by a factor of 29 over the global iteration, which is much higher than that of the TLI method (4.5 times). We hope this work can be helpful for accelerating the solution of electrostatic interaction forces under dielectric inhomogeneity, and provide theoretical guidance for the optimization of iterations for polymer chains with different geometries in large electrostatic systems (containing a large number of charged particles or huge computational domain). Furthermore, we intend to study the performance comparison of local iteration method and P3M, Ewald summation in high concentration salt solution in our further work. In future studies, it would be very fascinating to understand the motion of charged particles under the dielectric inhomogeneous system from a different angle, for example, by searching the energy minimum of the system to achieve a mutual equilibrium, which will help us to solve more complex molecular with singularities.