Skip to main content

A finite volume PDE solver in Python

Project description

Tests Documentation nix
GitHub PyPI CondaForge Binder
gitter OpenHub

FiPy is an object oriented, partial differential equation (PDE) solver, written in Python, based on a standard finite volume (FV) approach. The framework has been developed in the Materials Science and Engineering Division (MSED) and Center for Theoretical and Computational Materials Science (CTCMS), in the Material Measurement Laboratory (MML) at the National Institute of Standards and Technology (NIST).

The solution of coupled sets of PDEs is ubiquitous to the numerical simulation of science problems. Numerous PDE solvers exist, using a variety of languages and numerical approaches. Many are proprietary, expensive and difficult to customize. As a result, scientists spend considerable resources repeatedly developing limited tools for specific problems. Our approach, combining the FV method and Python, provides a tool that is extensible, powerful and freely available. A significant advantage to Python is the existing suite of tools for array calculations, sparse matrices and data rendering.

The FiPy framework includes terms for transient diffusion, convection and standard sources, enabling the solution of arbitrary combinations of coupled elliptic, hyperbolic and parabolic PDEs. Currently implemented models include phase field BoettingerReview:2002 ChenReview:2002 McFaddenReview:2002 treatments of polycrystalline, dendritic, and electrochemical phase transformations, as well as drug eluting stents Saylor:2011p2794, reactive wetting PhysRevE.82.051601, photovoltaics Hangarter:2011p2795 and a level set treatment of the electrodeposition process NIST:damascene:2001.

The latest information about FiPy can be found at http://www.ctcms.nist.gov/fipy/.

See the latest updates in the Change Log.

Even if you don’t read manuals…

…please read Installation, Using FiPy and Frequently Asked Questions, as well as examples.diffusion.mesh1D.

Download and Installation

Please refer to Installation for details on download and installation. FiPy can be redistributed and/or modified freely, provided that any derivative works bear some notice that they are derived from it, and any modified versions bear some notice that they have been modified.

Support

We offer several modes to communicate with the FiPy developers and with other users.

We welcome collaborative efforts on this project.

Conventions and Notation

FiPy is driven by Python script files than you can view or modify in any text editor. FiPy sessions are invoked from a command-line shell, such as tcsh or bash.

Throughout, text to be typed at the keyboard will appear like this. Commands to be issued from an interactive shell will appear:

$ like this

where you would enter the text (”like this”) following the shell prompt, denoted by “$”.

Text blocks of the form:

>>> a = 3 * 4
>>> a
12
>>> if a == 12:
...     print "a is twelve"
...
a is twelve

are intended to indicate an interactive session in the Python interpreter. We will refer to these as “interactive sessions” or as “doctest blocks”. The text “>>>” at the beginning of a line denotes the primary prompt, calling for input of a Python command. The text “...” denotes the secondary prompt, which calls for input that continues from the line above, when required by Python syntax. All remaining lines, which begin at the left margin, denote output from the Python interpreter. In all cases, the prompt is supplied by the Python interpreter and should not be typed by you.

🚩 Warning

Python is sensitive to indentation and care should be taken to enter text exactly as it appears in the examples.

When references are made to file system paths, it is assumed that the current working directory is the FiPy distribution directory, referred to as the “base directory”, such that:

examples/diffusion/steadyState/mesh1D.py

will correspond to, e.g.:

/some/where/FiPy-X.Y/examples/diffusion/steadyState/mesh1D.py

Paths will always be rendered using POSIX conventions (path elements separated by “/”). Any references of the form:

examples.diffusion.steadyState.mesh1D

are in the Python module notation and correspond to the equivalent POSIX path given above.

We may at times use a

📝 Note

to indicate something that may be of interest

or a

🚩 Warning

to indicate something that could cause serious problems.

Project details


Download files

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

Source Distribution

fipy-4.0.2.tar.gz (10.7 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

fipy-4.0.2-py3-none-any.whl (441.1 kB view details)

Uploaded Python 3

File details

Details for the file fipy-4.0.2.tar.gz.

File metadata

  • Download URL: fipy-4.0.2.tar.gz
  • Upload date:
  • Size: 10.7 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.3

File hashes

Hashes for fipy-4.0.2.tar.gz
Algorithm Hash digest
SHA256 b14dfb5eab0b78704eaac711aff2f6d354894f82efadab561bf420a14dcfb823
MD5 89a9a362f3ceee378e0939b3db5a49d2
BLAKE2b-256 a1ebafd81cd3d4c9e2f654b33dd3ad8cabd956f572562978e715c49e717c7c2b

See more details on using hashes here.

File details

Details for the file fipy-4.0.2-py3-none-any.whl.

File metadata

  • Download URL: fipy-4.0.2-py3-none-any.whl
  • Upload date:
  • Size: 441.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.3

File hashes

Hashes for fipy-4.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 a3b489472bf1426c419e018184e41a0ae451c441b9fe324dcb48e96905a9d2a3
MD5 3d1d72cc6a6a5c9489ab359ebf31f52e
BLAKE2b-256 0b8f1a160094c88fa27eabc2f04e64a155df8b24118e7326e78d1f786b7ba47f

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page