mufem documentation¶
Introduction¶
mufem (pronounced /ˈmjuːfɛm/) is a finite-element simulation code for electromagnetics and photonics, and their coupled multi-physics problems. It is for industrial engineering applications. The electromagnetic models include electrostatics, magnetostatics, time-domain and time-harmonic magnetics, and time-harmonic Maxwell problems. mufem also couples thermal and structural physics where they are necessary.
mufem is a Python library. You use it to set up and run simulations, from quick parameter sweeps to design optimization and large multi-physics campaigns. It uses the MFEM finite-element framework. mufem has no GUI. External tools such as gmsh and ParaView do the mesh generation and visualization.
mufem is free for academic and commercial use. Refer to Licensing.
Why mufem¶
Python-native
Set up, run, and post-process simulations with a Python API. Use it for parametric sweeps, optimization, and agentic workflows.
Multi-physics
Model electromagnetic, thermal, and structural physics and their interactions in one framework.
Advanced discretization
High-order finite elements from MFEM on curved, unstructured, non-conformal, and Cartesian meshes.
GPU-accelerated
Parallel CPU and GPU solvers, from a laptop to a large cluster. Cluster and GPU runs need a paid tier. Refer to Licensing.
Validated
Continuous tests against benchmark suites and published experimental, analytical, and reference results.
Free
The Community tier is free for academic and commercial use, with no license fees.
mufem has many examples and validation cases. These include the Compumag TEAM benchmarks, induction-heating studies, motor and transformer sector models, and other reference problems from the electromagnetics, thermal, and structural literature. You can find them at github.com/Raiden-Numerics/mufem.
Do you use an AI assistant? A simulation is only a Python script, so an AI coding assistant can set one up for you.
For questions, support, or feature requests please create a GitHub issue or write us an email at info@raiden-numerics.com.
Getting started¶
Framework¶
Models¶
Electromagnetics:
- Overview
- Electrostatics Model
- Time-Domain Magnetic Model
- Time-Harmonic Magnetic Model
- Time-Harmonic Maxwell Model
- Excitation Coil Model
Mechanical:
Service: