A Matlab-based finite-difference numerical solver for the Poisson equation for a rectangle and a disk in two dimensions, and a spherical domain in three dimensions, is presented. The solver is optimized for handling an arbitrary combination of Dirichlet and Neumann boundary conditions, and allows for full user control of mesh refinement. The solver routines utilize effective and parallelized sparse vector and matrix operations. Computations exhibit high speeds, numerical stability with respect to mesh size and mesh refinement, and acceptable error values even on desktop computers. Program summaryProgram title: FDMRP 1.0Catalogue identifier: AENQ_v1_0Program summary URL:http://cpc.cs.qub.ac.uk/summaries/AENQ_v1_0.htmlProgram obtainable from: CPC Program Library, Queen’s University, Belfast, N. IrelandLicensing provisions: GNU General Public License v3.0No. of lines in distributed program, including test data, etc.: 102793No. of bytes in distributed program, including test data, etc.: 369378Distribution format: tar.gzProgramming language: Matlab 2010a.Computer: PC, Macintosh.Operating system: Windows, OSX, Linux.RAM: 8GB (8,589,934,592 bytes)Classification: 4.3.Nature of problem: To solve the Poisson problem in a standard domain with “patchy surface”-type (strongly heterogeneous) Neumann/Dirichlet boundary conditions.Solution method: Finite difference with mesh refinement.Restrictions: Spherical domain in 3D; rectangular domain or a disk in 2D.Unusual features: Choice between mldivide/iterative solver for the solution of large system of linear algebraic equations that arise. Full user control of Neumann/Dirichlet boundary conditions and mesh refinement.Running time: Depending on the number of points taken and the geometry of the domain, the routine may take from less than a second to several hours to execute.
Read full abstract