PhiFlow is a Python library for differentiable physics simulation, primarily targeting fluid dynamics, particle systems, and PDE-based optimization. It provides a unified field abstraction (CenteredGrid, StaggeredGrid, PointCloud, Mesh) with automatic resampling and boundary handling, enabling seamless integration with machine learning workflows. The library supports multiple backends (NumPy, PyTorch, TensorFlow, JAX) and features a rich geometry module, physics solvers (advection, diffusion, incompressible flow, SPH, waves), and visualization tools. While its core abstractions are clean and well-tested, the codebase exhibits some technical drift due to deprecated API surface, large monolithic Dash-based web UI, and heavy reliance on the external phiml tensor library. Nonetheless, it is actively maintained with extensive test coverage and a growing research community.
PyMFEM provides Python bindings for the MFEM finite element library, enabling finite element simulations (PDE solvers) from Python. The architecture consists of SWIG-generated wrapper modules for serial (`mfem.ser`) and parallel MPI (`mfem.par`) execution, built on top of the C++ MFEM library. Key entry points include the core modules (`mfem.ser`, `mfem.par`), a suite of 30+ example scripts covering Laplace, elasticity, Maxwell, Navier-Stokes, and more, and miniapps for specialized applications (DPG, multidomain, field interpolation). The system supports JIT-compiled coefficients via Numba, complex-valued solvers via CHypre, and GPU backends (CUDA, libCEED). While primarily a software library, it has a strong research character due to its advanced numerical methods (DPG, fractional PDEs, topology optimization) and extensive example set that serves as both documentation and validation.
This repository provides a header-only C++ library with Python bindings for solving partial differential equations (PDEs) using Monte Carlo methods, specifically Walk on Spheres (WoS) and Walk on Stars (WoS★) algorithms. It supports Laplace, Poisson, and screened Poisson equations with Dirichlet, Neumann, and Robin boundary conditions in 2D and 3D. The library includes variance reduction techniques (Boundary Value Caching, Reverse Walk on Stars) and handles exterior problems via the Kelvin transform. It is designed for grid-free PDE solving, relying on geometric queries (via FCPW BVH or SDF grids) rather than volume meshing. The codebase is research-oriented, with clear reference implementations and citations to foundational papers, but includes many TODO comments and incomplete optimizations. The architecture is modular with template-based dimension and value type abstraction, making it adaptable but also complex. Demo applications in C++ and Python illustrate usage on model problems with JSON configuration and image output.