Skip to main content

phiFEM: a convenience package for using $\varphi$-FEM with FEniCSx

This package provides convenience tools that help with the implementation of $\varphi$-FEM schemes in the FEniCSx computation platform.

$\varphi$-FEM (or phiFEM) is an immersed boundary finite element method leveraging levelset functions to avoid the use of any non-standard finite element spaces or non-standard quadrature rules near the boundary of the domain. More information about $\varphi$-FEM can be found in the various publications (see e.g. 1 and 2).

phiFEM Pypi webpage

Prerequisites

Usage

We recommend to use phiFEM inside the dolfinx container (e.g. ghcr.io/fenics/dolfinx/dolfinx:stable).

  • Launch the dolfinx container in interactive mode using, e.g. Docker (see the docker documentation for the meaning of the different arguments):
    docker run -ti -v $(pwd):/home/dolfinx/shared -w /home/dolfinx/shared dolfinx/dolfinx:stable
    
  • Inside the container install the phiFEM package with pip:
    pip install phifem
    

Run the demos

The demos can be found on the phiFEM Github repository. To run the demos you'll need to clone the repository and launch the docker container using the above command. Inside the container navigate the demo directory and e.g. run the weak-dirichlet demo:

cd demo/weak-dirichlet/flower
python main bg

Remark: The interface-elasticity demo requires the polars python library (pip install polars).

Run the tests

To run the tests, follow the steps 1 to 3 to run the demos and inside the container:

cd tests
pytest

License

phiFEM is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License along with phiFEM. If not, see http://www.gnu.org/licenses/.

Logo credit

Frédérique Lecourtier (https://mimesis.inria.fr/members/frederique-lecourtier/)

  1. M. DUPREZ and A. LOZINSKI, $\varphi$-FEM: A finite element method on domains defined by level-sets, SIAM J. Numer. Anal., 58 (2020), pp. 1008-1028, https://epubs.siam.org/doi/10.1137/19m1248947 ↩

  2. S. COTIN, M. DUPREZ, V. LLERAS, A. LOZINSKI, and K. VUILLEMOT, $\varphi$-FEM: An efficient simulation tool using simple meshes for problems in structure mechanics and heat transfer, Partition of Unity Methods, (2023), pp. 191-216, https://www.semanticscholar.org/paper/%CF%86-FEM%3A-an-efficient-simulation-tool-using-simple-in-Cotin-Duprez/82f2015ac98f66af115ae57f020b0b1a45c46ad0. ↩

Metadata

Release files for phiFEM 0.5.11

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for phiFEM 0.5.11
File Size Uploaded Provenance Actions
phifem-0.5.11.tar.gz 75.6 MB Without provenance Details for phifem-0.5.11.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for phiFEM 0.5.11
File Interpreter ABI Platform Actions
phifem-0.5.11-py3-none-any.whl Python 3 none any Details for phifem-0.5.11-py3-none-any.whl

Total release size: 75.6 MB

Release files / phifem-0.5.11.tar.gz

Download URL phifem-0.5.11.tar.gz
Size 75.6 MB
Tags Source
SHA-256 checksum
How to use checksums
84f3c59cad92003eae7d682adda420a5ad62038b7d26af29b411d04fcc0c841e
BLAKE2b-256 checksum
How to use checksums
48bbeb6916bb305a605880f8e387227f5d5793a4ddba140b9c726f235c21b8c5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.9

Release files / phifem-0.5.11-py3-none-any.whl

Download URL phifem-0.5.11-py3-none-any.whl
Size 29.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
0e37bf99c861adfe1eeaea49b28827db772d0d9fee121642c98b3cf71a5afbf5
BLAKE2b-256 checksum
How to use checksums
31796a69f383de2b4eaff1f3da795ba4710000ec8f75e200b4295e35d21da12c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.9

Security for phiFEM 0.5.11

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.5.11 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page