A Monte Carlo-based Poisson's equation solver parallelized with Coarray Fortran

Authors: NEVSAN ŞENGİL, ÖZGÜR TÜMÜKLÜ, MEHMET CEVDET ÇELENLİGİL

Abstract: Poisson's equation is found in many scientific problems, such as heat transfer and electric field calculations. Although many different techniques are involved in solving Poisson's equation, we focused on the Monte Carlo method (MCM). We preferred the MCM not only because of its simple algorithm but also for its excellent parallel efficiency. Parallelization is one of the most effective techniques for reducing computation time. Among many parallelization paradigms, such as OpenMP (open multiprocessing), MPI (message passing interface), and PGAS (partitioned global address space), we adopted the PGAS-based Coarray Fortran (CAF). In this paper, we demonstrated that parallelization of Poisson's equation solver with CAF was quite painless. After parallelization, we solved Poisson's equation for a nonrectangular domain. We started with a workstation that consisted of 8 cores and we continued with a Cray supercomputer of up to 512 cores. The results of the parallel solvers were validated using exact solutions. We demonstrated that the error was less than 1.6%. Additionally, solution times and speedups of the CAF-based solver were compared with a solver that utilized MPI or OpenMP. OpenMP was not able to compete against CAF and MPI because of the "while" loop restriction. The CAF-based solver performed slightly better (7.5%) than the MPI provided that core numbers were between 2 and 32. However, CAF and MPI performed similarly for higher numbers of cores.

Keywords: Poisson's equation, Monte Carlo methods, Coarray Fortran, message passing interface, OpenMP

Full Text: PDF