Abstract
Psydac is a Python 3 library for the solution of partial differential equations, which combines the convenience of a domain specific language with the speed of a high-performance parallel engine. Its main focus is on isogeometric analysis using tensor-product B-spline finite elements; to this end it uses an optimized sparse format called 'stencil matrix', which drastically reduces memory storage compared to the popular CSR/CSC formats. It supports multi-patch mapped geometries, and finite element exterior calculus. It can distribute each domain patch across many MPI processes, with multiple OpenMP threads operating in each block. The users of Psydac define a weak form of the model equations through SymPDE, an extension of Sympy that provides the mathematical expressions and checks their semantic validity. Simple mappings can be defined analytically, and multi-patch NURBS geometries can be imported from file. Once a finite element discretization is chosen, Psydac maps abstract concepts onto concrete objects, the basic building blocks being MPI-distributed vectors and matrices. Python code is automatically generated for the model-specific operations, namely matrix and vector assembly, and user-defined diagnostics. Finally, Psydac accelerates all computationally intensive operations using Pyccel, a transpiler which converts Python code to either C or Fortran. We present the library design, the typical usage workflow, the user interface for a simple 2D example, and the parallel scaling results in a large 3D simulation. In addition we show a few complex applications in fluid dynamics and electromagnetism, where the accuracy of the solver is verified against manufactured and reference solutions.
Talk to us
Join us for a 30 min session where you can share your feedback and ask us any queries you have
Disclaimer: All third-party content on this website/platform is and will remain the property of their respective owners and is provided on "as is" basis without any warranties, express or implied. Use of third-party content does not indicate any affiliation, sponsorship with or endorsement by them. Any references to third-party content is to identify the corresponding services and shall be considered fair use under The CopyrightLaw.