Skip to main content

PETSc for Python

Project description

Python bindings for PETSc.


If you have a working MPI implementation and the mpicc compiler wrapper is on your search path, it highly recommended to install mpi4py first:

$ pip install mpi4py

Ensure you have NumPy installed:

$ pip install numpy

and finally:

$ pip install petsc petsc4py

You can also install the in-development version of petsc4py with:

$ pip install Cython numpy mpi4py
$ pip install --no-deps git+
$ pip install --no-deps git+


$ pip install Cython numpy mpi4py
$ pip install --no-deps
$ pip install --no-deps


If PETSc for Python been significant to a project that leads to an academic publication, please acknowledge that fact by citing the project.

  • L. Dalcin, P. Kler, R. Paz, and A. Cosimo, Parallel Distributed Computing using Python, Advances in Water Resources, 34(9):1124-1139, 2011.
  • S. Balay, S. Abhyankar, M. Adams, J. Brown, P. Brune, K. Buschelman, L. Dalcin, A. Dener, V. Eijkhout, W. Gropp, D. Karpeyev, D. Kaushik, M. Knepley, D. May, L. Curfman McInnes, R. Mills, T. Munson, K. Rupp, P. Sanan, B. Smith, S. Zampini, H. Zhang, and H. Zhang, PETSc Users Manual, ANL-95/11 - Revision 3.14, 2020.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for petsc4py, version 3.14.1
Filename, size File type Python version Upload date Hashes
Filename, size petsc4py-3.14.1.tar.gz (2.1 MB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page