摘要:We present an OpenFOAM implementation of a finite volume formulation for magnetostatics. The code computes the magnetic field distributions in discontinuous using a multi-region approach. The regions are coupled through a new base boundary condition which allows arbitrary permeability and magnetization discontinuities. The underlying mathematical formultion is based on a variant of the classical vector potential formulation. We benchmark the solver against finite element solutions through several numerical experiments to show its remarkable performance.